diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/about.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/about.json new file mode 100644 index 0000000000000000000000000000000000000000..a28deb9723495eb8262cc051d2797c986f1dc5ae --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/about.json @@ -0,0 +1,252 @@ +{ + "channels": [ + "https://conda.anaconda.org/conda-forge" + ], + "conda_build_version": "26.3.0", + "conda_version": "26.3.2", + "dev_url": "https://github.com/pypa/pip", + "doc_url": "https://pip.pypa.io/en/stable/", + "env_vars": { + "CIO_TEST": "" + }, + "extra": { + "copy_test_source_files": true, + "final": true, + "flow_run_id": "github_25339731494", + "recipe-maintainers": [ + "jakirkham", + "msarahan", + "pelson", + "ocefpaf", + "mingwandroid" + ], + "remote_url": "https://github.com/conda-forge/pip-feedstock", + "sha": "d72fbbb5615e4e2684b93aa5b2c620d394032b42" + }, + "home": "https://pip.pypa.io/en/stable/", + "identifiers": [], + "keywords": [], + "license": "MIT", + "license_family": "MIT", + "license_file": "LICENSE.txt", + "root_pkgs": [ + "xz 5.8.3 ha02ee65_0", + "importlib_resources 7.1.0 pyhd8ed1ab_0", + "openssl 3.6.2 h35e630c_0", + "keyring 25.7.0 pyha804496_0", + "libcurl 8.20.0 hcf29cc6_0", + "annotated-doc 0.0.4 pyhcf101f3_0", + "yaml-cpp 0.8.0 h59595ed_0", + "h11 0.16.0 pyhcf101f3_1", + "libstdcxx 15.2.0 h934c35e_18", + "zstandard 0.25.0 py312h5253ce2_1", + "libmsgpack-c 6.1.0 h54a6638_6", + "typing-inspection 0.4.2 pyhcf101f3_2", + "httpx 0.28.1 pyhd8ed1ab_0", + "pybind11-abi 11 hc364b38_1", + "reproc 14.2.7.post0 hb03c661_0", + "idna 3.13 pyhcf101f3_0", + "psutil 7.2.2 py312h5253ce2_0", + "zstd 1.5.7 hb78ec9c_6", + "hyperframe 6.1.0 pyhd8ed1ab_0", + "markupsafe 3.0.3 py312h8a5da7c_1", + "python-dotenv 1.2.2 pyhcf101f3_0", + "nlohmann_json-abi 3.12.0 h0f90c79_1", + "perl 5.32.1 7_hd590300_perl5", + "tk 8.6.13 noxft_h366c992_103", + "referencing 0.37.0 pyhcf101f3_0", + "pcre2 10.47 haa7fec5_0", + "pysocks 1.7.1 pyha55dd90_7", + "fmt 12.1.0 hff5e90c_0", + "py-lief 0.17.6 py312h1289d80_0", + "xorg-libxdmcp 1.1.5 hb03c661_1", + "mdurl 0.1.2 pyhd8ed1ab_1", + "setuptools 82.0.1 pyh332efcf_0", + "jaraco.classes 3.4.0 pyhcf101f3_3", + "pthread-stubs 0.4 hb9d3cd8_1002", + "liblzma 5.8.3 hb03c661_0", + "yaml 0.2.5 h280c20c_3", + "jeepney 0.9.0 pyhd8ed1ab_0", + "bzip2 1.0.8 hda65f42_9", + "annotated-types 0.7.0 pyhd8ed1ab_1", + "lzo 2.10 h280c20c_1002", + "libarchive 3.8.7 gpl_hc2c16d8_100", + "libuuid 2.42 h5347b49_0", + "truststore 0.10.4 pyhcf101f3_0", + "mbedtls 3.6.3.1 h5888daf_0", + "simdjson 4.6.3 hb700be7_0", + "libgomp 15.2.0 he0feb66_18", + "ca-certificates 2026.4.22 hbd8a1cb_0", + "conda-package-handling 2.4.0 pyh7900ff3_2", + "ruamel.yaml 0.18.17 py312h5253ce2_2", + "jsonpointer 3.1.1 pyhcf101f3_0", + "pyyaml 6.0.3 py312h8a5da7c_1", + "packaging 26.2 pyhc364b38_0", + "git 2.53.0 pl5321h6d3cee1_0", + "typing-extensions 4.15.0 h396c80c_0", + "requests-toolbelt 1.0.0 pyhd8ed1ab_1", + "libsqlite 3.53.0 hf4e2dac_0", + "libxml2 2.15.3 h49c6c72_0", + "rattler-build 0.64.1 ha759004_0", + "libmamba 2.6.0 hd28c85e_0", + "libsolv 0.7.37 h9463b59_0", + "libpng 1.6.58 h421ea60_0", + "tomli 2.4.1 pyhcf101f3_0", + "xorg-libxau 1.0.12 hb03c661_1", + "semver 3.0.4 pyhcf101f3_1", + "pillow 12.2.0 py312h50c33e8_0", + "c-ares 1.34.6 hb03c661_0", + "libmambapy 2.6.0 py312h5ee1301_0", + "pkginfo 1.12.1.2 pyhd8ed1ab_0", + "backports.tarfile 1.2.0 pyhcf101f3_2", + "libgcc-ng 15.2.0 h69a702a_18", + "wheel 0.47.0 pyhd8ed1ab_0", + "tomlkit 0.14.0 pyha770c72_0", + "jinja2 3.1.6 pyhcf101f3_1", + "distro 1.9.0 pyhd8ed1ab_1", + "libglib 2.88.1 h0d30a3d_1", + "ncurses 6.6 hdb14827_0", + "libxml2-16 2.15.3 hca6bf5a_0", + "h2 4.3.0 pyhcf101f3_0", + "pip 26.0.1 pyh8b19718_0", + "importlib-metadata 8.8.0 pyhcf101f3_0", + "conda-build 26.3.0 pyh31ec981_1", + "libnsl 2.0.1 hb9d3cd8_1", + "typer 0.25.1 pyhcf101f3_0", + "attrs 26.1.0 pyhcf101f3_0", + "libffi 3.5.2 h3435931_0", + "pycosat 0.6.6 py312h4c3975b_3", + "dbus 1.16.2 h24cb091_1", + "msgpack-python 1.1.2 py312hd9148b4_1", + "ripgrep 15.1.0 hdab8a38_0", + "defusedxml 0.7.1 pyhd8ed1ab_0", + "frozendict 2.4.7 py312h4c3975b_0", + "filelock 3.29.0 pyhd8ed1ab_0", + "libstdcxx-ng 15.2.0 hdf11a46_18", + "lerc 4.1.0 hdb68285_0", + "soupsieve 2.8.3 pyhd8ed1ab_0", + "jaraco.functools 4.4.0 pyhcf101f3_1", + "python 3.12.13 hd63d673_0_cpython", + "libxcb 1.17.0 h8a09558_0", + "libnghttp2 1.68.1 h877daf1_0", + "liblief 0.17.6 hecca717_0", + "libssh2 1.11.1 hcf80075_0", + "su-exec 0.2 h166bdaf_1003", + "jsonpatch 1.33 pyhd8ed1ab_1", + "anaconda-cli-base 0.8.2 pyhc364b38_0", + "tini 0.19.0 h166bdaf_1", + "charset-normalizer 3.4.7 pyhd8ed1ab_0", + "archspec 0.2.5 pyhd8ed1ab_0", + "backports 1.0 pyhd8ed1ab_5", + "libexpat 2.8.0 hecca717_0", + "jsonschema 4.26.0 pyhcf101f3_0", + "evalidate 2.0.5 pyhe01879c_0", + "anaconda-client 1.14.1 pyhcf101f3_0", + "rpds-py 0.30.0 py312h868fb18_0", + "jsonschema-specifications 2025.9.1 pyhcf101f3_0", + "conda-libmamba-solver 26.4.1 pyhd8ed1ab_0", + "krb5 1.22.2 ha1258a1_0", + "xz-tools 5.8.3 hb03c661_0", + "pluggy 1.6.0 pyhf9edf01_1", + "python-dateutil 2.9.0.post0 pyhe01879c_2", + "brotli-python 1.2.0 py312hdb49522_1", + "keyutils 1.6.3 hb9d3cd8_0", + "libedit 3.1.20250104 pl5321h7949ede_0", + "pydantic 2.13.3 pyhcf101f3_0", + "pydantic-core 2.46.3 py312h868fb18_0", + "more-itertools 11.0.2 pyhcf101f3_0", + "jupyter_core 5.9.1 pyhc90fa1f_0", + "patchelf 0.17.2 h58526e2_0", + "platformdirs 4.9.6 pyhcf101f3_0", + "icu 78.3 h33c6efd_0", + "click 8.3.3 pyhc90fa1f_0", + "pyjwt 2.12.1 pyhcf101f3_0", + "libmamba-spdlog 2.6.0 hf859cbd_0", + "sniffio 1.3.1 pyhd8ed1ab_2", + "six 1.17.0 pyhe01879c_1", + "readchar 4.2.2 pyhcf101f3_0", + "python-libarchive-c 5.3 pyhe01879c_1", + "pytz 2026.2 pyhcf101f3_0", + "pygments 2.20.0 pyhd8ed1ab_0", + "openjpeg 2.5.4 h55fea9a_0", + "mamba 2.6.0 hf80e505_0", + "lcms2 2.19 h0c24ade_0", + "exceptiongroup 1.3.1 pyhd8ed1ab_0", + "rich 15.0.0 pyhcf101f3_0", + "cpp-expected 1.3.1 h171cf75_0", + "anyio 4.13.0 pyhcf101f3_0", + "python-fastjsonschema 2.21.2 pyhe01879c_0", + "pixi 0.67.2 ha759004_0", + "markdown-it-py 4.0.0 pyhd8ed1ab_0", + "typing_extensions 4.15.0 pyhcf101f3_0", + "cffi 2.0.0 py312h460c074_1", + "conda 26.3.2 py312h7900ff3_1", + "libdeflate 1.25 h17f619e_0", + "libjpeg-turbo 3.1.4.1 hb03c661_0", + "libiconv 1.18 h3b78370_2", + "libgcc 15.2.0 he0feb66_18", + "libfreetype 2.14.3 ha770c72_0", + "conda-package-streaming 0.12.0 pyhd8ed1ab_0", + "ld_impl_linux-64 2.45.1 default_hbd61a6d_102", + "httpcore 1.0.9 pyh29332c3_0", + "pycparser 2.22 pyh29332c3_1", + "libwebp-base 1.6.0 hd42ef1d_0", + "libev 4.33 hd590300_2", + "reproc-cpp 14.2.7.post0 hecca717_0", + "boltons 25.0.0 pyhd8ed1ab_0", + "_libgcc_mutex 0.1 conda_forge", + "zlib-ng 2.3.3 hceb46e0_1", + "readline 8.3 h853b02a_0", + "zipp 3.23.1 pyhcf101f3_0", + "beautifulsoup4 4.14.3 pyha770c72_0", + "urllib3 2.6.3 pyhd8ed1ab_0", + "patch 2.8 hb03c661_1002", + "requests 2.33.1 pyhcf101f3_1", + "jaraco.context 6.1.2 pyhcf101f3_0", + "secretstorage 3.4.1 py312h7900ff3_0", + "menuinst 2.4.2 py312h7900ff3_0", + "cryptography 47.0.0 py312ha4b625e_0", + "libxcrypt 4.4.36 hd590300_1", + "hpack 4.1.0 pyhd8ed1ab_0", + "nbformat 5.10.4 pyhd8ed1ab_1", + "libfreetype6 2.14.3 h73754d4_0", + "ruamel.yaml.clib 0.2.15 py312h5253ce2_1", + "libtiff 4.7.1 h9d88235_1", + "_openmp_mutex 4.5 20_gnu", + "pydantic-settings 2.14.0 pyhcf101f3_1", + "chardet 7.4.3 pyhcf101f3_0", + "conda-index 0.11.0 pyhd8ed1ab_0", + "shellingham 1.5.4 pyhd8ed1ab_2", + "tqdm 4.67.3 pyh8f84b5b_0", + "libzlib 1.3.2 h25fd6f3_2", + "traitlets 5.14.3 pyhd8ed1ab_1", + "spdlog 1.17.0 hab81395_1", + "anaconda-auth 0.14.2 pyhd8ed1ab_0", + "tzdata 2025c hc9c84f9_1", + "xz-gpl-tools 5.8.3 ha02ee65_0", + "certifi 2026.4.22 pyhd8ed1ab_0", + "liblzma-devel 5.8.3 hb03c661_0", + "pkce 1.0.3 pyhd8ed1ab_1", + "colorama 0.4.6 pyhd8ed1ab_1", + "python_abi 3.12 8_cp312", + "lz4-c 1.10.0 h5888daf_1", + "backports.zstd 1.4.0 py312h90b7ffd_0", + "joblib 1.5.3 pyhd8ed1ab_0", + "deprecated 1.3.1 pyhd8ed1ab_1", + "wrapt 2.1.2 py312h4c3975b_0", + "conda-oci-mirror 0.2.3 pyhd8ed1ab_1", + "conda-env 2.6.0 1", + "jq 1.8.1 h73b1eb8_0", + "pynacl 1.6.2 py312h587e1b2_1", + "conda-forge-metadata 0.13.0 pyhcf101f3_0", + "shyaml 0.6.2 pyhd3deb0d_0", + "rattler-build-conda-compat 1.4.14 pyhd8ed1ab_0", + "pygithub 2.9.1 pyhd8ed1ab_0", + "conda-forge-ci-setup 4.24.3 py312hef7310e_100", + "oras-py 0.1.14 pyhd8ed1ab_0", + "oniguruma 6.9.10 hb9d3cd8_0", + "libsodium 1.0.21 h280c20c_3" + ], + "summary": "PyPA recommended tool for installing Python packages", + "tags": [] +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/files b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/files new file mode 100644 index 0000000000000000000000000000000000000000..d17852d68e4e74204269d655ea90495f116c3384 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/files @@ -0,0 +1,468 @@ +site-packages/pip-26.1.1.dist-info/INSTALLER +site-packages/pip-26.1.1.dist-info/METADATA +site-packages/pip-26.1.1.dist-info/RECORD +site-packages/pip-26.1.1.dist-info/REQUESTED +site-packages/pip-26.1.1.dist-info/WHEEL +site-packages/pip-26.1.1.dist-info/direct_url.json +site-packages/pip-26.1.1.dist-info/entry_points.txt +site-packages/pip-26.1.1.dist-info/licenses/AUTHORS.txt +site-packages/pip-26.1.1.dist-info/licenses/LICENSE.txt +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/cachecontrol/LICENSE.txt +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/certifi/LICENSE +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/distlib/LICENSE.txt +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/distro/LICENSE +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/idna/LICENSE.md +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/msgpack/COPYING +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE.APACHE +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE.BSD +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/pkg_resources/LICENSE +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/platformdirs/LICENSE +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/pygments/LICENSE +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/pyproject_hooks/LICENSE +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/requests/LICENSE +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/resolvelib/LICENSE +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/rich/LICENSE +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/tomli/LICENSE +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/tomli_w/LICENSE +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/truststore/LICENSE +site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/urllib3/LICENSE.txt +site-packages/pip/__init__.py +site-packages/pip/__main__.py +site-packages/pip/__pip-runner__.py +site-packages/pip/_internal/__init__.py +site-packages/pip/_internal/build_env.py +site-packages/pip/_internal/cache.py +site-packages/pip/_internal/cli/__init__.py +site-packages/pip/_internal/cli/autocompletion.py +site-packages/pip/_internal/cli/base_command.py +site-packages/pip/_internal/cli/cmdoptions.py +site-packages/pip/_internal/cli/command_context.py +site-packages/pip/_internal/cli/index_command.py +site-packages/pip/_internal/cli/main.py +site-packages/pip/_internal/cli/main_parser.py +site-packages/pip/_internal/cli/parser.py +site-packages/pip/_internal/cli/progress_bars.py +site-packages/pip/_internal/cli/req_command.py +site-packages/pip/_internal/cli/spinners.py +site-packages/pip/_internal/cli/status_codes.py +site-packages/pip/_internal/commands/__init__.py +site-packages/pip/_internal/commands/cache.py +site-packages/pip/_internal/commands/check.py +site-packages/pip/_internal/commands/completion.py +site-packages/pip/_internal/commands/configuration.py +site-packages/pip/_internal/commands/debug.py +site-packages/pip/_internal/commands/download.py +site-packages/pip/_internal/commands/freeze.py +site-packages/pip/_internal/commands/hash.py +site-packages/pip/_internal/commands/help.py +site-packages/pip/_internal/commands/index.py +site-packages/pip/_internal/commands/inspect.py +site-packages/pip/_internal/commands/install.py +site-packages/pip/_internal/commands/list.py +site-packages/pip/_internal/commands/lock.py +site-packages/pip/_internal/commands/search.py +site-packages/pip/_internal/commands/show.py +site-packages/pip/_internal/commands/uninstall.py +site-packages/pip/_internal/commands/wheel.py +site-packages/pip/_internal/configuration.py +site-packages/pip/_internal/distributions/__init__.py +site-packages/pip/_internal/distributions/base.py +site-packages/pip/_internal/distributions/installed.py +site-packages/pip/_internal/distributions/sdist.py +site-packages/pip/_internal/distributions/wheel.py +site-packages/pip/_internal/exceptions.py +site-packages/pip/_internal/index/__init__.py +site-packages/pip/_internal/index/collector.py +site-packages/pip/_internal/index/package_finder.py +site-packages/pip/_internal/index/sources.py +site-packages/pip/_internal/locations/__init__.py +site-packages/pip/_internal/locations/_distutils.py +site-packages/pip/_internal/locations/_sysconfig.py +site-packages/pip/_internal/locations/base.py +site-packages/pip/_internal/main.py +site-packages/pip/_internal/metadata/__init__.py +site-packages/pip/_internal/metadata/_json.py +site-packages/pip/_internal/metadata/base.py +site-packages/pip/_internal/metadata/importlib/__init__.py +site-packages/pip/_internal/metadata/importlib/_compat.py +site-packages/pip/_internal/metadata/importlib/_dists.py +site-packages/pip/_internal/metadata/importlib/_envs.py +site-packages/pip/_internal/metadata/pkg_resources.py +site-packages/pip/_internal/models/__init__.py +site-packages/pip/_internal/models/candidate.py +site-packages/pip/_internal/models/direct_url.py +site-packages/pip/_internal/models/format_control.py +site-packages/pip/_internal/models/index.py +site-packages/pip/_internal/models/installation_report.py +site-packages/pip/_internal/models/link.py +site-packages/pip/_internal/models/release_control.py +site-packages/pip/_internal/models/scheme.py +site-packages/pip/_internal/models/search_scope.py +site-packages/pip/_internal/models/selection_prefs.py +site-packages/pip/_internal/models/target_python.py +site-packages/pip/_internal/models/wheel.py +site-packages/pip/_internal/network/__init__.py +site-packages/pip/_internal/network/auth.py +site-packages/pip/_internal/network/cache.py +site-packages/pip/_internal/network/download.py +site-packages/pip/_internal/network/lazy_wheel.py +site-packages/pip/_internal/network/session.py +site-packages/pip/_internal/network/utils.py +site-packages/pip/_internal/network/xmlrpc.py +site-packages/pip/_internal/operations/__init__.py +site-packages/pip/_internal/operations/build/__init__.py +site-packages/pip/_internal/operations/build/build_tracker.py +site-packages/pip/_internal/operations/build/metadata.py +site-packages/pip/_internal/operations/build/metadata_editable.py +site-packages/pip/_internal/operations/build/wheel.py +site-packages/pip/_internal/operations/build/wheel_editable.py +site-packages/pip/_internal/operations/check.py +site-packages/pip/_internal/operations/freeze.py +site-packages/pip/_internal/operations/install/__init__.py +site-packages/pip/_internal/operations/install/wheel.py +site-packages/pip/_internal/operations/prepare.py +site-packages/pip/_internal/pyproject.py +site-packages/pip/_internal/req/__init__.py +site-packages/pip/_internal/req/constructors.py +site-packages/pip/_internal/req/pep723.py +site-packages/pip/_internal/req/req_dependency_group.py +site-packages/pip/_internal/req/req_file.py +site-packages/pip/_internal/req/req_install.py +site-packages/pip/_internal/req/req_set.py +site-packages/pip/_internal/req/req_uninstall.py +site-packages/pip/_internal/resolution/__init__.py +site-packages/pip/_internal/resolution/base.py +site-packages/pip/_internal/resolution/legacy/__init__.py +site-packages/pip/_internal/resolution/legacy/resolver.py +site-packages/pip/_internal/resolution/resolvelib/__init__.py +site-packages/pip/_internal/resolution/resolvelib/base.py +site-packages/pip/_internal/resolution/resolvelib/candidates.py +site-packages/pip/_internal/resolution/resolvelib/factory.py +site-packages/pip/_internal/resolution/resolvelib/found_candidates.py +site-packages/pip/_internal/resolution/resolvelib/provider.py +site-packages/pip/_internal/resolution/resolvelib/reporter.py +site-packages/pip/_internal/resolution/resolvelib/requirements.py +site-packages/pip/_internal/resolution/resolvelib/resolver.py +site-packages/pip/_internal/self_outdated_check.py +site-packages/pip/_internal/utils/__init__.py +site-packages/pip/_internal/utils/_jaraco_text.py +site-packages/pip/_internal/utils/_log.py +site-packages/pip/_internal/utils/appdirs.py +site-packages/pip/_internal/utils/compat.py +site-packages/pip/_internal/utils/compatibility_tags.py +site-packages/pip/_internal/utils/datetime.py +site-packages/pip/_internal/utils/deprecation.py +site-packages/pip/_internal/utils/direct_url_helpers.py +site-packages/pip/_internal/utils/egg_link.py +site-packages/pip/_internal/utils/entrypoints.py +site-packages/pip/_internal/utils/filesystem.py +site-packages/pip/_internal/utils/filetypes.py +site-packages/pip/_internal/utils/glibc.py +site-packages/pip/_internal/utils/hashes.py +site-packages/pip/_internal/utils/logging.py +site-packages/pip/_internal/utils/misc.py +site-packages/pip/_internal/utils/packaging.py +site-packages/pip/_internal/utils/pylock.py +site-packages/pip/_internal/utils/retry.py +site-packages/pip/_internal/utils/subprocess.py +site-packages/pip/_internal/utils/temp_dir.py +site-packages/pip/_internal/utils/unpacking.py +site-packages/pip/_internal/utils/urls.py +site-packages/pip/_internal/utils/virtualenv.py +site-packages/pip/_internal/utils/wheel.py +site-packages/pip/_internal/vcs/__init__.py +site-packages/pip/_internal/vcs/bazaar.py +site-packages/pip/_internal/vcs/git.py +site-packages/pip/_internal/vcs/mercurial.py +site-packages/pip/_internal/vcs/subversion.py +site-packages/pip/_internal/vcs/versioncontrol.py +site-packages/pip/_internal/wheel_builder.py +site-packages/pip/_vendor/README.rst +site-packages/pip/_vendor/__init__.py +site-packages/pip/_vendor/cachecontrol/LICENSE.txt +site-packages/pip/_vendor/cachecontrol/__init__.py +site-packages/pip/_vendor/cachecontrol/_cmd.py +site-packages/pip/_vendor/cachecontrol/adapter.py +site-packages/pip/_vendor/cachecontrol/cache.py +site-packages/pip/_vendor/cachecontrol/caches/__init__.py +site-packages/pip/_vendor/cachecontrol/caches/file_cache.py +site-packages/pip/_vendor/cachecontrol/caches/redis_cache.py +site-packages/pip/_vendor/cachecontrol/controller.py +site-packages/pip/_vendor/cachecontrol/filewrapper.py +site-packages/pip/_vendor/cachecontrol/heuristics.py +site-packages/pip/_vendor/cachecontrol/py.typed +site-packages/pip/_vendor/cachecontrol/serialize.py +site-packages/pip/_vendor/cachecontrol/wrapper.py +site-packages/pip/_vendor/certifi/LICENSE +site-packages/pip/_vendor/certifi/__init__.py +site-packages/pip/_vendor/certifi/__main__.py +site-packages/pip/_vendor/certifi/cacert.pem +site-packages/pip/_vendor/certifi/core.py +site-packages/pip/_vendor/certifi/py.typed +site-packages/pip/_vendor/distlib/LICENSE.txt +site-packages/pip/_vendor/distlib/__init__.py +site-packages/pip/_vendor/distlib/compat.py +site-packages/pip/_vendor/distlib/resources.py +site-packages/pip/_vendor/distlib/scripts.py +site-packages/pip/_vendor/distlib/t32.exe +site-packages/pip/_vendor/distlib/t64-arm.exe +site-packages/pip/_vendor/distlib/t64.exe +site-packages/pip/_vendor/distlib/util.py +site-packages/pip/_vendor/distlib/w32.exe +site-packages/pip/_vendor/distlib/w64-arm.exe +site-packages/pip/_vendor/distlib/w64.exe +site-packages/pip/_vendor/distro/LICENSE +site-packages/pip/_vendor/distro/__init__.py +site-packages/pip/_vendor/distro/__main__.py +site-packages/pip/_vendor/distro/distro.py +site-packages/pip/_vendor/distro/py.typed +site-packages/pip/_vendor/idna/LICENSE.md +site-packages/pip/_vendor/idna/__init__.py +site-packages/pip/_vendor/idna/codec.py +site-packages/pip/_vendor/idna/compat.py +site-packages/pip/_vendor/idna/core.py +site-packages/pip/_vendor/idna/idnadata.py +site-packages/pip/_vendor/idna/intranges.py +site-packages/pip/_vendor/idna/package_data.py +site-packages/pip/_vendor/idna/py.typed +site-packages/pip/_vendor/idna/uts46data.py +site-packages/pip/_vendor/msgpack/COPYING +site-packages/pip/_vendor/msgpack/__init__.py +site-packages/pip/_vendor/msgpack/exceptions.py +site-packages/pip/_vendor/msgpack/ext.py +site-packages/pip/_vendor/msgpack/fallback.py +site-packages/pip/_vendor/packaging/LICENSE +site-packages/pip/_vendor/packaging/LICENSE.APACHE +site-packages/pip/_vendor/packaging/LICENSE.BSD +site-packages/pip/_vendor/packaging/__init__.py +site-packages/pip/_vendor/packaging/_elffile.py +site-packages/pip/_vendor/packaging/_manylinux.py +site-packages/pip/_vendor/packaging/_musllinux.py +site-packages/pip/_vendor/packaging/_parser.py +site-packages/pip/_vendor/packaging/_structures.py +site-packages/pip/_vendor/packaging/_tokenizer.py +site-packages/pip/_vendor/packaging/dependency_groups.py +site-packages/pip/_vendor/packaging/direct_url.py +site-packages/pip/_vendor/packaging/errors.py +site-packages/pip/_vendor/packaging/licenses/__init__.py +site-packages/pip/_vendor/packaging/licenses/_spdx.py +site-packages/pip/_vendor/packaging/markers.py +site-packages/pip/_vendor/packaging/metadata.py +site-packages/pip/_vendor/packaging/py.typed +site-packages/pip/_vendor/packaging/pylock.py +site-packages/pip/_vendor/packaging/requirements.py +site-packages/pip/_vendor/packaging/specifiers.py +site-packages/pip/_vendor/packaging/tags.py +site-packages/pip/_vendor/packaging/utils.py +site-packages/pip/_vendor/packaging/version.py +site-packages/pip/_vendor/pkg_resources/LICENSE +site-packages/pip/_vendor/pkg_resources/__init__.py +site-packages/pip/_vendor/platformdirs/LICENSE +site-packages/pip/_vendor/platformdirs/__init__.py +site-packages/pip/_vendor/platformdirs/__main__.py +site-packages/pip/_vendor/platformdirs/android.py +site-packages/pip/_vendor/platformdirs/api.py +site-packages/pip/_vendor/platformdirs/macos.py +site-packages/pip/_vendor/platformdirs/py.typed +site-packages/pip/_vendor/platformdirs/unix.py +site-packages/pip/_vendor/platformdirs/version.py +site-packages/pip/_vendor/platformdirs/windows.py +site-packages/pip/_vendor/pygments/LICENSE +site-packages/pip/_vendor/pygments/__init__.py +site-packages/pip/_vendor/pygments/__main__.py +site-packages/pip/_vendor/pygments/console.py +site-packages/pip/_vendor/pygments/filter.py +site-packages/pip/_vendor/pygments/filters/__init__.py +site-packages/pip/_vendor/pygments/formatter.py +site-packages/pip/_vendor/pygments/formatters/__init__.py +site-packages/pip/_vendor/pygments/formatters/_mapping.py +site-packages/pip/_vendor/pygments/lexer.py +site-packages/pip/_vendor/pygments/lexers/__init__.py +site-packages/pip/_vendor/pygments/lexers/_mapping.py +site-packages/pip/_vendor/pygments/lexers/python.py +site-packages/pip/_vendor/pygments/modeline.py +site-packages/pip/_vendor/pygments/plugin.py +site-packages/pip/_vendor/pygments/regexopt.py +site-packages/pip/_vendor/pygments/scanner.py +site-packages/pip/_vendor/pygments/sphinxext.py +site-packages/pip/_vendor/pygments/style.py +site-packages/pip/_vendor/pygments/styles/__init__.py +site-packages/pip/_vendor/pygments/styles/_mapping.py +site-packages/pip/_vendor/pygments/token.py +site-packages/pip/_vendor/pygments/unistring.py +site-packages/pip/_vendor/pygments/util.py +site-packages/pip/_vendor/pyproject_hooks/LICENSE +site-packages/pip/_vendor/pyproject_hooks/__init__.py +site-packages/pip/_vendor/pyproject_hooks/_impl.py +site-packages/pip/_vendor/pyproject_hooks/_in_process/__init__.py +site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py +site-packages/pip/_vendor/pyproject_hooks/py.typed +site-packages/pip/_vendor/requests/LICENSE +site-packages/pip/_vendor/requests/__init__.py +site-packages/pip/_vendor/requests/__version__.py +site-packages/pip/_vendor/requests/_internal_utils.py +site-packages/pip/_vendor/requests/adapters.py +site-packages/pip/_vendor/requests/api.py +site-packages/pip/_vendor/requests/auth.py +site-packages/pip/_vendor/requests/certs.py +site-packages/pip/_vendor/requests/compat.py +site-packages/pip/_vendor/requests/cookies.py +site-packages/pip/_vendor/requests/exceptions.py +site-packages/pip/_vendor/requests/help.py +site-packages/pip/_vendor/requests/hooks.py +site-packages/pip/_vendor/requests/models.py +site-packages/pip/_vendor/requests/packages.py +site-packages/pip/_vendor/requests/sessions.py +site-packages/pip/_vendor/requests/status_codes.py +site-packages/pip/_vendor/requests/structures.py +site-packages/pip/_vendor/requests/utils.py +site-packages/pip/_vendor/resolvelib/LICENSE +site-packages/pip/_vendor/resolvelib/__init__.py +site-packages/pip/_vendor/resolvelib/providers.py +site-packages/pip/_vendor/resolvelib/py.typed +site-packages/pip/_vendor/resolvelib/reporters.py +site-packages/pip/_vendor/resolvelib/resolvers/__init__.py +site-packages/pip/_vendor/resolvelib/resolvers/abstract.py +site-packages/pip/_vendor/resolvelib/resolvers/criterion.py +site-packages/pip/_vendor/resolvelib/resolvers/exceptions.py +site-packages/pip/_vendor/resolvelib/resolvers/resolution.py +site-packages/pip/_vendor/resolvelib/structs.py +site-packages/pip/_vendor/rich/LICENSE +site-packages/pip/_vendor/rich/__init__.py +site-packages/pip/_vendor/rich/__main__.py +site-packages/pip/_vendor/rich/_cell_widths.py +site-packages/pip/_vendor/rich/_emoji_codes.py +site-packages/pip/_vendor/rich/_emoji_replace.py +site-packages/pip/_vendor/rich/_export_format.py +site-packages/pip/_vendor/rich/_extension.py +site-packages/pip/_vendor/rich/_fileno.py +site-packages/pip/_vendor/rich/_inspect.py +site-packages/pip/_vendor/rich/_log_render.py +site-packages/pip/_vendor/rich/_loop.py +site-packages/pip/_vendor/rich/_null_file.py +site-packages/pip/_vendor/rich/_palettes.py +site-packages/pip/_vendor/rich/_pick.py +site-packages/pip/_vendor/rich/_ratio.py +site-packages/pip/_vendor/rich/_spinners.py +site-packages/pip/_vendor/rich/_stack.py +site-packages/pip/_vendor/rich/_timer.py +site-packages/pip/_vendor/rich/_win32_console.py +site-packages/pip/_vendor/rich/_windows.py +site-packages/pip/_vendor/rich/_windows_renderer.py +site-packages/pip/_vendor/rich/_wrap.py +site-packages/pip/_vendor/rich/abc.py +site-packages/pip/_vendor/rich/align.py +site-packages/pip/_vendor/rich/ansi.py +site-packages/pip/_vendor/rich/bar.py +site-packages/pip/_vendor/rich/box.py +site-packages/pip/_vendor/rich/cells.py +site-packages/pip/_vendor/rich/color.py +site-packages/pip/_vendor/rich/color_triplet.py +site-packages/pip/_vendor/rich/columns.py +site-packages/pip/_vendor/rich/console.py +site-packages/pip/_vendor/rich/constrain.py +site-packages/pip/_vendor/rich/containers.py +site-packages/pip/_vendor/rich/control.py +site-packages/pip/_vendor/rich/default_styles.py +site-packages/pip/_vendor/rich/diagnose.py +site-packages/pip/_vendor/rich/emoji.py +site-packages/pip/_vendor/rich/errors.py +site-packages/pip/_vendor/rich/file_proxy.py +site-packages/pip/_vendor/rich/filesize.py +site-packages/pip/_vendor/rich/highlighter.py +site-packages/pip/_vendor/rich/json.py +site-packages/pip/_vendor/rich/jupyter.py +site-packages/pip/_vendor/rich/layout.py +site-packages/pip/_vendor/rich/live.py +site-packages/pip/_vendor/rich/live_render.py +site-packages/pip/_vendor/rich/logging.py +site-packages/pip/_vendor/rich/markup.py +site-packages/pip/_vendor/rich/measure.py +site-packages/pip/_vendor/rich/padding.py +site-packages/pip/_vendor/rich/pager.py +site-packages/pip/_vendor/rich/palette.py +site-packages/pip/_vendor/rich/panel.py +site-packages/pip/_vendor/rich/pretty.py +site-packages/pip/_vendor/rich/progress.py +site-packages/pip/_vendor/rich/progress_bar.py +site-packages/pip/_vendor/rich/prompt.py +site-packages/pip/_vendor/rich/protocol.py +site-packages/pip/_vendor/rich/py.typed +site-packages/pip/_vendor/rich/region.py +site-packages/pip/_vendor/rich/repr.py +site-packages/pip/_vendor/rich/rule.py +site-packages/pip/_vendor/rich/scope.py +site-packages/pip/_vendor/rich/screen.py +site-packages/pip/_vendor/rich/segment.py +site-packages/pip/_vendor/rich/spinner.py +site-packages/pip/_vendor/rich/status.py +site-packages/pip/_vendor/rich/style.py +site-packages/pip/_vendor/rich/styled.py +site-packages/pip/_vendor/rich/syntax.py +site-packages/pip/_vendor/rich/table.py +site-packages/pip/_vendor/rich/terminal_theme.py +site-packages/pip/_vendor/rich/text.py +site-packages/pip/_vendor/rich/theme.py +site-packages/pip/_vendor/rich/themes.py +site-packages/pip/_vendor/rich/traceback.py +site-packages/pip/_vendor/rich/tree.py +site-packages/pip/_vendor/tomli/LICENSE +site-packages/pip/_vendor/tomli/__init__.py +site-packages/pip/_vendor/tomli/_parser.py +site-packages/pip/_vendor/tomli/_re.py +site-packages/pip/_vendor/tomli/_types.py +site-packages/pip/_vendor/tomli/py.typed +site-packages/pip/_vendor/tomli_w/LICENSE +site-packages/pip/_vendor/tomli_w/__init__.py +site-packages/pip/_vendor/tomli_w/_writer.py +site-packages/pip/_vendor/tomli_w/py.typed +site-packages/pip/_vendor/truststore/LICENSE +site-packages/pip/_vendor/truststore/__init__.py +site-packages/pip/_vendor/truststore/_api.py +site-packages/pip/_vendor/truststore/_macos.py +site-packages/pip/_vendor/truststore/_openssl.py +site-packages/pip/_vendor/truststore/_ssl_constants.py +site-packages/pip/_vendor/truststore/_windows.py +site-packages/pip/_vendor/truststore/py.typed +site-packages/pip/_vendor/urllib3/LICENSE.txt +site-packages/pip/_vendor/urllib3/__init__.py +site-packages/pip/_vendor/urllib3/_base_connection.py +site-packages/pip/_vendor/urllib3/_collections.py +site-packages/pip/_vendor/urllib3/_request_methods.py +site-packages/pip/_vendor/urllib3/_version.py +site-packages/pip/_vendor/urllib3/connection.py +site-packages/pip/_vendor/urllib3/connectionpool.py +site-packages/pip/_vendor/urllib3/contrib/__init__.py +site-packages/pip/_vendor/urllib3/contrib/emscripten/__init__.py +site-packages/pip/_vendor/urllib3/contrib/emscripten/connection.py +site-packages/pip/_vendor/urllib3/contrib/emscripten/emscripten_fetch_worker.js +site-packages/pip/_vendor/urllib3/contrib/emscripten/fetch.py +site-packages/pip/_vendor/urllib3/contrib/emscripten/request.py +site-packages/pip/_vendor/urllib3/contrib/emscripten/response.py +site-packages/pip/_vendor/urllib3/contrib/pyopenssl.py +site-packages/pip/_vendor/urllib3/contrib/socks.py +site-packages/pip/_vendor/urllib3/exceptions.py +site-packages/pip/_vendor/urllib3/fields.py +site-packages/pip/_vendor/urllib3/filepost.py +site-packages/pip/_vendor/urllib3/http2/__init__.py +site-packages/pip/_vendor/urllib3/http2/connection.py +site-packages/pip/_vendor/urllib3/http2/probe.py +site-packages/pip/_vendor/urllib3/poolmanager.py +site-packages/pip/_vendor/urllib3/py.typed +site-packages/pip/_vendor/urllib3/response.py +site-packages/pip/_vendor/urllib3/util/__init__.py +site-packages/pip/_vendor/urllib3/util/connection.py +site-packages/pip/_vendor/urllib3/util/proxy.py +site-packages/pip/_vendor/urllib3/util/request.py +site-packages/pip/_vendor/urllib3/util/response.py +site-packages/pip/_vendor/urllib3/util/retry.py +site-packages/pip/_vendor/urllib3/util/ssl_.py +site-packages/pip/_vendor/urllib3/util/ssl_match_hostname.py +site-packages/pip/_vendor/urllib3/util/ssltransport.py +site-packages/pip/_vendor/urllib3/util/timeout.py +site-packages/pip/_vendor/urllib3/util/url.py +site-packages/pip/_vendor/urllib3/util/util.py +site-packages/pip/_vendor/urllib3/util/wait.py +site-packages/pip/_vendor/vendor.txt +site-packages/pip/py.typed diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/git b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/git new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/hash_input.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/hash_input.json new file mode 100644 index 0000000000000000000000000000000000000000..ffc0b19ad326fbe4d39c69d5d0686745f876e215 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/hash_input.json @@ -0,0 +1,4 @@ +{ + "channel_targets": "conda-forge main", + "with_setuptools_wheel": "true" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/index.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/index.json new file mode 100644 index 0000000000000000000000000000000000000000..7eb2ff750038fe3d710771d679544b3775cd34e6 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/index.json @@ -0,0 +1,18 @@ +{ + "arch": null, + "build": "pyh8b19718_0", + "build_number": 0, + "depends": [ + "python >=3.10,<3.13.0a0", + "setuptools", + "wheel" + ], + "license": "MIT", + "license_family": "MIT", + "name": "pip", + "noarch": "python", + "platform": null, + "subdir": "noarch", + "timestamp": 1777924080196, + "version": "26.1.1" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/link.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/link.json new file mode 100644 index 0000000000000000000000000000000000000000..3d9230e37f598179040248068fb665e2e8f8c760 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/link.json @@ -0,0 +1,10 @@ +{ + "noarch": { + "entry_points": [ + "pip = pip._internal.cli.main:main", + "pip3 = pip._internal.cli.main:main" + ], + "type": "python" + }, + "package_metadata_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/paths.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/paths.json new file mode 100644 index 0000000000000000000000000000000000000000..068b833bdfd49c04eaf957a9c58681c2050b48d4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/paths.json @@ -0,0 +1,2813 @@ +{ + "paths": [ + { + "_path": "site-packages/pip-26.1.1.dist-info/INSTALLER", + "path_type": "hardlink", + "sha256": "d0edee15f91b406f3f99726e44eb990be6e34fd0345b52b910c568e0eef6a2a8", + "size_in_bytes": 5 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/METADATA", + "path_type": "hardlink", + "sha256": "da0f42ad05399a98efecfbfaf3176d29120f6712425501f7eb34c6f6cdf1aad9", + "size_in_bytes": 4566 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/RECORD", + "path_type": "hardlink", + "sha256": "e68380131f84450f99331db9b0e2b0158570d029838f5a485461d48c5e14bfc1", + "size_in_bytes": 67546 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/REQUESTED", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/WHEEL", + "path_type": "hardlink", + "sha256": "1b68144734c4b66791f27add5d425f3620775585718a03d0f9b110ba3a4d88db", + "size_in_bytes": 82 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/direct_url.json", + "path_type": "hardlink", + "sha256": "65ad35d7d76dfb917d47240a137ee67e8861c81420666ed0b205825c259b21bc", + "size_in_bytes": 99 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/entry_points.txt", + "path_type": "hardlink", + "sha256": "5617fcb34218817dfb9ad778bc62fbdc13dcc5d2a7a9e0853f3079f9ddf4c7ca", + "size_in_bytes": 84 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/AUTHORS.txt", + "path_type": "hardlink", + "sha256": "b04d1b704ffd3cc4650f3cdbfaaf1b8df84a5d84c4426dc8c4b2cc0ebda77c93", + "size_in_bytes": 11852 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/LICENSE.txt", + "path_type": "hardlink", + "sha256": "634300a669d49aeae65b12c6c48c924c51a4cdf3d1ff086dc3456dc8bcaa2104", + "size_in_bytes": 1093 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/cachecontrol/LICENSE.txt", + "path_type": "hardlink", + "sha256": "86eeee87be2a43f3ff1f56496f451f69243926f025fedbb033666c304c4c161b", + "size_in_bytes": 558 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/certifi/LICENSE", + "path_type": "hardlink", + "sha256": "e93716da6b9c0d5a4a1df60fe695b370f0695603d21f6f83f053e42cfc10caf7", + "size_in_bytes": 989 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/distlib/LICENSE.txt", + "path_type": "hardlink", + "sha256": "808e10c8a6ab8deb149ff9b3fb19f447a808094606d712a9ca57fead3552599d", + "size_in_bytes": 14531 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/distro/LICENSE", + "path_type": "hardlink", + "sha256": "cb5e8e7e5f4a3988e1063c142c60dc2df75605f4c46515e776e3aca6df976e14", + "size_in_bytes": 11325 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/idna/LICENSE.md", + "path_type": "hardlink", + "sha256": "b7a336abf3b04e180ec065cdd16e705d079e1cc7a14f910aa6e9187f36b9cd87", + "size_in_bytes": 1541 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/msgpack/COPYING", + "path_type": "hardlink", + "sha256": "492dedba85da5872f78e6091bcd1fea474d660d35acb4dee964b8aab3f007427", + "size_in_bytes": 614 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE", + "path_type": "hardlink", + "sha256": "cad1ef5bd340d73e074ba614d26f7deaca5c7940c3d8c34852e65c4909686c48", + "size_in_bytes": 197 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE.APACHE", + "path_type": "hardlink", + "sha256": "0d542e0c8804e39aa7f37eb00da5a762149dc682d7829451287e11b938e94594", + "size_in_bytes": 10174 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE.BSD", + "path_type": "hardlink", + "sha256": "b70e7e9b742f1cc6f948b34c16aa39ffece94196364bc88ff0d2180f0028fac5", + "size_in_bytes": 1344 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/pkg_resources/LICENSE", + "path_type": "hardlink", + "sha256": "86da0f01aeae46348a3c3d465195dc1ceccde79f79e87769a64b8da04b2a4741", + "size_in_bytes": 1023 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/platformdirs/LICENSE", + "path_type": "hardlink", + "sha256": "29e0fd62e929850e86eb28c3fdccf0cefdf4fa94879011cffb3d0d4bed6d4db6", + "size_in_bytes": 1089 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/pygments/LICENSE", + "path_type": "hardlink", + "sha256": "a9d66f1d526df02e29dce73436d34e56e8632f46c275bbdffc70569e882f9f17", + "size_in_bytes": 1331 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/pyproject_hooks/LICENSE", + "path_type": "hardlink", + "sha256": "1b22b049b5267d6dfc23a67bf4a84d8ec04b9fdfb1a51d360e42b4342c8b4154", + "size_in_bytes": 1081 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/requests/LICENSE", + "path_type": "hardlink", + "sha256": "09e8a9bcec8067104652c168685ab0931e7868f9c8284b66f5ae6edae5f1130b", + "size_in_bytes": 10142 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/resolvelib/LICENSE", + "path_type": "hardlink", + "sha256": "f388fd38cad13112c1dc0f669bbe80e7f84541edbafb72f3030d2ca7642c3c9d", + "size_in_bytes": 751 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/rich/LICENSE", + "path_type": "hardlink", + "sha256": "deed7c17a4318158190a3ea239cc879a5a50271cebb98ae7025f48fbe58dca15", + "size_in_bytes": 1056 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/tomli/LICENSE", + "path_type": "hardlink", + "sha256": "b80816b0d530b8accb4c2211783790984a6e3b61922c2b5ee92f3372ab2742fe", + "size_in_bytes": 1072 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/tomli_w/LICENSE", + "path_type": "hardlink", + "sha256": "b80816b0d530b8accb4c2211783790984a6e3b61922c2b5ee92f3372ab2742fe", + "size_in_bytes": 1072 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/truststore/LICENSE", + "path_type": "hardlink", + "sha256": "33be7b7e8fa4fd19b1760e1a8ed8a668bdab852c91b692dd41424bcb725a9fca", + "size_in_bytes": 1086 + }, + { + "_path": "site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/urllib3/LICENSE.txt", + "path_type": "hardlink", + "sha256": "130e3a64d5fdd5d096a752694634a7d9df284469de86e5732100268041e3d686", + "size_in_bytes": 1093 + }, + { + "_path": "site-packages/pip/__init__.py", + "path_type": "hardlink", + "sha256": "0fe48a0e72579d94957706f83d3ac2fd47716f72f4cddb201909c0be173526a2", + "size_in_bytes": 355 + }, + { + "_path": "site-packages/pip/__main__.py", + "path_type": "hardlink", + "sha256": "ace651b6b5e30c1cd8db89e26b14e777d6471d62fb07411ac1574ba09de723a7", + "size_in_bytes": 874 + }, + { + "_path": "site-packages/pip/__pip-runner__.py", + "path_type": "hardlink", + "sha256": "ef6d0cb7a874ed471ee76bfcd04385fff2586aea0bc3d6fb3dfb3fe41f758ac8", + "size_in_bytes": 1451 + }, + { + "_path": "site-packages/pip/_internal/__init__.py", + "path_type": "hardlink", + "sha256": "4bb8bd0e7f5a4994b4306fb65abbdeddd57d4c898fcef427e638e1a7db7fb9fd", + "size_in_bytes": 511 + }, + { + "_path": "site-packages/pip/_internal/build_env.py", + "path_type": "hardlink", + "sha256": "5e980e2254d02e0cf73ef0d3da7ee3d8dcd7feb54564b0881bbb7b6f675d85c3", + "size_in_bytes": 21911 + }, + { + "_path": "site-packages/pip/_internal/cache.py", + "path_type": "hardlink", + "sha256": "9cc878f18bf7caed474b5c8276c728baee81e81e7360159d57a6e1aacee02fe1", + "size_in_bytes": 10345 + }, + { + "_path": "site-packages/pip/_internal/cli/__init__.py", + "path_type": "hardlink", + "sha256": "22a83fb4a03bef55ee30ed4fe2dfec0c79d228fce451bf43d03aae9c09b0fe4a", + "size_in_bytes": 131 + }, + { + "_path": "site-packages/pip/_internal/cli/autocompletion.py", + "path_type": "hardlink", + "sha256": "646d9c334de795c36bb3e586fd21535b8ea2b31f6cd86a399540fff3e8afef4a", + "size_in_bytes": 7193 + }, + { + "_path": "site-packages/pip/_internal/cli/base_command.py", + "path_type": "hardlink", + "sha256": "fa826ce6529a3c3d915c1b81c817cabee9806b55cd615b61bf43e6d115f01a00", + "size_in_bytes": 9579 + }, + { + "_path": "site-packages/pip/_internal/cli/cmdoptions.py", + "path_type": "hardlink", + "sha256": "c5b4d2c38d29898cdeba1a9d1b8716b7198fb61875c9ed1a1b3d1fcaa88d306f", + "size_in_bytes": 37592 + }, + { + "_path": "site-packages/pip/_internal/cli/command_context.py", + "path_type": "hardlink", + "sha256": "926bb711665b7c17a06b5a036a69c625303f51a7a384840db8c8f609598c5eed", + "size_in_bytes": 817 + }, + { + "_path": "site-packages/pip/_internal/cli/index_command.py", + "path_type": "hardlink", + "sha256": "3d370a49df89ddb51a9730cef6436f6779841a22578b1df64387cfc24c525c87", + "size_in_bytes": 7094 + }, + { + "_path": "site-packages/pip/_internal/cli/main.py", + "path_type": "hardlink", + "sha256": "9630d0064bc1b42f314e339d6faac3273254362d6cf8f9d547f5b90be32ad039", + "size_in_bytes": 3137 + }, + { + "_path": "site-packages/pip/_internal/cli/main_parser.py", + "path_type": "hardlink", + "sha256": "623cc9023a9fefc01136c2e59c94fd97a7cd6e9c833c903e6ab3885d8b0ae489", + "size_in_bytes": 4403 + }, + { + "_path": "site-packages/pip/_internal/cli/parser.py", + "path_type": "hardlink", + "sha256": "108144c6b597ff59eb97521bfbe18ea2bef4598a8bb5db870727a76f5bbdc47e", + "size_in_bytes": 13827 + }, + { + "_path": "site-packages/pip/_internal/cli/progress_bars.py", + "path_type": "hardlink", + "sha256": "216d4f1f99f614fa940533fb50b43962efb0c8d34ef57198de0d4f4f844cbb8e", + "size_in_bytes": 4706 + }, + { + "_path": "site-packages/pip/_internal/cli/req_command.py", + "path_type": "hardlink", + "sha256": "2a60a9a6791fecce92bc9215addb349e0f371c5319db3e18ea9835c829f28c33", + "size_in_bytes": 17484 + }, + { + "_path": "site-packages/pip/_internal/cli/spinners.py", + "path_type": "hardlink", + "sha256": "109cd921937252d2658e9dfe5a372cc88aeac56f8752c7d6ce1b96f389ff4eac", + "size_in_bytes": 7362 + }, + { + "_path": "site-packages/pip/_internal/cli/status_codes.py", + "path_type": "hardlink", + "sha256": "b0414751a5096eabfc880acbdc702d733b5666618e157d358537ac4b2b43121d", + "size_in_bytes": 116 + }, + { + "_path": "site-packages/pip/_internal/commands/__init__.py", + "path_type": "hardlink", + "sha256": "68d7826d0bab1968a17e142aec1a9a2d71ea5834348b7234e0e4bb9312baa654", + "size_in_bytes": 4026 + }, + { + "_path": "site-packages/pip/_internal/commands/cache.py", + "path_type": "hardlink", + "sha256": "5e34fb92363c192212324b051ec2ef8d2f4e81f8b97b1b4d95452ff9d5285823", + "size_in_bytes": 9142 + }, + { + "_path": "site-packages/pip/_internal/commands/check.py", + "path_type": "hardlink", + "sha256": "85514141ecd0df38f813276859b1508ff69f3d4a6932deebf493c0958db653a6", + "size_in_bytes": 2244 + }, + { + "_path": "site-packages/pip/_internal/commands/completion.py", + "path_type": "hardlink", + "sha256": "2e3bd1219e905220d724bdc838c15e0fefc9f7b1df8cc1a0124d23dad586bb55", + "size_in_bytes": 4565 + }, + { + "_path": "site-packages/pip/_internal/commands/configuration.py", + "path_type": "hardlink", + "sha256": "ea034e1ab5569ce2d4d79cd49c088db8e3217fbe9144866f09d543d1d7a03d19", + "size_in_bytes": 10105 + }, + { + "_path": "site-packages/pip/_internal/commands/debug.py", + "path_type": "hardlink", + "sha256": "12f04bb118dc4d132b3aec8790b9494ba5ce0cb05b6ac365bd5cdc7bb71b46fa", + "size_in_bytes": 6543 + }, + { + "_path": "site-packages/pip/_internal/commands/download.py", + "path_type": "hardlink", + "sha256": "2d4355a1bbaf09d6a08cb06e3c16b11de0621c48887b4ddf4ceda6e9a842f2ac", + "size_in_bytes": 5178 + }, + { + "_path": "site-packages/pip/_internal/commands/freeze.py", + "path_type": "hardlink", + "sha256": "7f1a16f0001cf9b02a07f7d774dab656767725f5a414c83e6d1e8b71d0d53bb0", + "size_in_bytes": 3099 + }, + { + "_path": "site-packages/pip/_internal/commands/hash.py", + "path_type": "hardlink", + "sha256": "18ef6944ddf05c2da441aa2f2b9ed368b60131cdc896d387f763ba404c3a604d", + "size_in_bytes": 1679 + }, + { + "_path": "site-packages/pip/_internal/commands/help.py", + "path_type": "hardlink", + "sha256": "073dcb7233505e4cf80aefffa4be0267cea8e3e1cd2d98f535959d949863baed", + "size_in_bytes": 1108 + }, + { + "_path": "site-packages/pip/_internal/commands/index.py", + "path_type": "hardlink", + "sha256": "661be0680bba9a4cadb36e4bdf799d070f1d7e2e74ad33493982cef0636033b6", + "size_in_bytes": 5514 + }, + { + "_path": "site-packages/pip/_internal/commands/inspect.py", + "path_type": "hardlink", + "sha256": "2e6cbbf961d9ee3b87a7eb718caed4ef85f78ebe5c7ef80e303202c8a8adae23", + "size_in_bytes": 3184 + }, + { + "_path": "site-packages/pip/_internal/commands/install.py", + "path_type": "hardlink", + "sha256": "c30b47610dd4a03c5770ccac8d34676d63bc65e83f0befcd93d4a031f0c7020a", + "size_in_bytes": 33733 + }, + { + "_path": "site-packages/pip/_internal/commands/list.py", + "path_type": "hardlink", + "sha256": "eff630b4f1cdf916d63c7842a7585a8d737fccdc51f5476c1c652e549cc054d4", + "size_in_bytes": 13638 + }, + { + "_path": "site-packages/pip/_internal/commands/lock.py", + "path_type": "hardlink", + "sha256": "d78e6286350affeee03fc3bae573c38bfc4c8658798677b5a6d90775f9db0274", + "size_in_bytes": 6027 + }, + { + "_path": "site-packages/pip/_internal/commands/search.py", + "path_type": "hardlink", + "sha256": "cdb32c5ff6004a3ea45c0e972018130efd1b18ae75c46f825772329d925c13e7", + "size_in_bytes": 5782 + }, + { + "_path": "site-packages/pip/_internal/commands/show.py", + "path_type": "hardlink", + "sha256": "a0b54921f2969832a6d12b101848b7a68ccd8aaad78d3adab3f7db05260aa410", + "size_in_bytes": 8066 + }, + { + "_path": "site-packages/pip/_internal/commands/uninstall.py", + "path_type": "hardlink", + "sha256": "0ac3a286abdbe9903a3baecbef4a177a82c778e7cdccc33cf07f60fbd6a8720c", + "size_in_bytes": 3868 + }, + { + "_path": "site-packages/pip/_internal/commands/wheel.py", + "path_type": "hardlink", + "sha256": "2fdbc4cc9fc4e36b1c17f1e08795f81e4dfd9ea2432b11a0e2eee094361b3567", + "size_in_bytes": 5880 + }, + { + "_path": "site-packages/pip/_internal/configuration.py", + "path_type": "hardlink", + "sha256": "5b1c304b063f066e90cc381fdf606cba31323bc76045e75e802a606d47c3bccf", + "size_in_bytes": 14568 + }, + { + "_path": "site-packages/pip/_internal/distributions/__init__.py", + "path_type": "hardlink", + "sha256": "1eaea4b7a8170608cd8ade614d358b03378234e2a807e374a46612a9e86b962f", + "size_in_bytes": 858 + }, + { + "_path": "site-packages/pip/_internal/distributions/base.py", + "path_type": "hardlink", + "sha256": "97e39308022cdb996c6a97a303a218a4f67148ce7e0444f8b1d64392a97c8e26", + "size_in_bytes": 1830 + }, + { + "_path": "site-packages/pip/_internal/distributions/installed.py", + "path_type": "hardlink", + "sha256": "92020413fd4dce36712c1482fafe6ceb8b8e15995512ddda3eb8d3b4beb1d976", + "size_in_bytes": 929 + }, + { + "_path": "site-packages/pip/_internal/distributions/sdist.py", + "path_type": "hardlink", + "sha256": "458c1021bbb1a4acba3a394164201e7f1a4c0daa28714438745b61786b224ce4", + "size_in_bytes": 6627 + }, + { + "_path": "site-packages/pip/_internal/distributions/wheel.py", + "path_type": "hardlink", + "sha256": "fc76c6d0e7a117c7708f8517fb157ffed5cbc203eeb3d3a33047f635346a05b1", + "size_in_bytes": 1364 + }, + { + "_path": "site-packages/pip/_internal/exceptions.py", + "path_type": "hardlink", + "sha256": "3d7cc67c1994177aca4108c200c709d5fb33070ea768bd674caf025e1222ef3a", + "size_in_bytes": 32166 + }, + { + "_path": "site-packages/pip/_internal/index/__init__.py", + "path_type": "hardlink", + "sha256": "b73c0c1ff7e141eb9bc0ca877528af6ac83571181349b360d8288c567ccc9b25", + "size_in_bytes": 29 + }, + { + "_path": "site-packages/pip/_internal/index/collector.py", + "path_type": "hardlink", + "sha256": "47b19cc7fe0612848423e89acdf0195443c6dcba7a99b653e256c00fa36301cd", + "size_in_bytes": 16144 + }, + { + "_path": "site-packages/pip/_internal/index/package_finder.py", + "path_type": "hardlink", + "sha256": "7d7f654657e2524a02f7aac889883833f6c3595354a5a5f64f35f1fc53fe6a82", + "size_in_bytes": 41347 + }, + { + "_path": "site-packages/pip/_internal/index/sources.py", + "path_type": "hardlink", + "sha256": "9d72643a384bcbe3b616caca53d448a823aa818d8fb28296c9bb598e3460a94d", + "size_in_bytes": 8639 + }, + { + "_path": "site-packages/pip/_internal/locations/__init__.py", + "path_type": "hardlink", + "sha256": "88ff725599ffe223ee35c694361d80fef24b72f519fbccb8cef28b0d512a68cd", + "size_in_bytes": 14022 + }, + { + "_path": "site-packages/pip/_internal/locations/_distutils.py", + "path_type": "hardlink", + "sha256": "8e9163e15d34ac3f48477bc0f53aab1a4c1c74d545739f0bb028596af81ef496", + "size_in_bytes": 5975 + }, + { + "_path": "site-packages/pip/_internal/locations/_sysconfig.py", + "path_type": "hardlink", + "sha256": "f02a538edc5a0b31d20ab2a96b15a71c4eda29c26b4494669ed47564b572b0b9", + "size_in_bytes": 7779 + }, + { + "_path": "site-packages/pip/_internal/locations/base.py", + "path_type": "hardlink", + "sha256": "0089a36095b13ad0e473428a73a6381b3ebbedc83dd5c68c0382fde01f456448", + "size_in_bytes": 2550 + }, + { + "_path": "site-packages/pip/_internal/main.py", + "path_type": "hardlink", + "sha256": "d5c1ea8ec7c50ab3057f7079b70ce87314c951d1cc2e85d4a72e6526816a522f", + "size_in_bytes": 338 + }, + { + "_path": "site-packages/pip/_internal/metadata/__init__.py", + "path_type": "hardlink", + "sha256": "be9f8903189683ffa5e45f004f425c7b2ef6b949e1f020f0c2897df8a92d1d9f", + "size_in_bytes": 5824 + }, + { + "_path": "site-packages/pip/_internal/metadata/_json.py", + "path_type": "hardlink", + "sha256": "84dbe73073972c0c8d9738ab5a13cbf4dc760af0aa6b589199ae8eb2ad587d5f", + "size_in_bytes": 2711 + }, + { + "_path": "site-packages/pip/_internal/metadata/base.py", + "path_type": "hardlink", + "sha256": "046b8c7a795c413f22ee3f62725adf742def4b082f86bf208e7f79e5c0b2d7ab", + "size_in_bytes": 25420 + }, + { + "_path": "site-packages/pip/_internal/metadata/importlib/__init__.py", + "path_type": "hardlink", + "sha256": "8d4522768c671dc7c84c71da0161b51b68b97dd058925bffb89723a36c7b5581", + "size_in_bytes": 135 + }, + { + "_path": "site-packages/pip/_internal/metadata/importlib/_compat.py", + "path_type": "hardlink", + "sha256": "b27795878ffa5b14192b8963765df2955b8ffaad2db52a9b825f665add079ce8", + "size_in_bytes": 2804 + }, + { + "_path": "site-packages/pip/_internal/metadata/importlib/_dists.py", + "path_type": "hardlink", + "sha256": "73bdfcb1500a17fce187214e20a98b94c69d46f18e7c476a7282a3ce7c296142", + "size_in_bytes": 8711 + }, + { + "_path": "site-packages/pip/_internal/metadata/importlib/_envs.py", + "path_type": "hardlink", + "sha256": "1f7a952d7561e0b5afacfbeefde9177f775f6edc2796134940fda9c57a5c71f5", + "size_in_bytes": 5333 + }, + { + "_path": "site-packages/pip/_internal/metadata/pkg_resources.py", + "path_type": "hardlink", + "sha256": "34eefa66b7d1dbe2ca253c9a5eb990a0686624c02b00bbda72b9591d58920d3f", + "size_in_bytes": 10544 + }, + { + "_path": "site-packages/pip/_internal/models/__init__.py", + "path_type": "hardlink", + "sha256": "023982101c57fcc1fd7ff8d58c818d08524a60261e4847b5f32caf371e2e44a4", + "size_in_bytes": 62 + }, + { + "_path": "site-packages/pip/_internal/models/candidate.py", + "path_type": "hardlink", + "sha256": "e53ab0254d183a8828dc4b083e885aa90dd9e217d4e0134dc81601109b3a5b1c", + "size_in_bytes": 720 + }, + { + "_path": "site-packages/pip/_internal/models/direct_url.py", + "path_type": "hardlink", + "sha256": "f514b74d0017927c0b77c24e3995a56c157a59916cf6a9fe600624d1543c47f4", + "size_in_bytes": 944 + }, + { + "_path": "site-packages/pip/_internal/models/format_control.py", + "path_type": "hardlink", + "sha256": "3f07a6606d4bdbb04cd1fd4a3fad6b9b6e304a110d172c6a943d535aedf86a57", + "size_in_bytes": 2471 + }, + { + "_path": "site-packages/pip/_internal/models/index.py", + "path_type": "hardlink", + "sha256": "b589cbf28c468b8692356babd261bc0c03fbac2eb2ba16bf33024ef31c3472b2", + "size_in_bytes": 1030 + }, + { + "_path": "site-packages/pip/_internal/models/installation_report.py", + "path_type": "hardlink", + "sha256": "5383255d6141fbc7afff285eb8c3bd4f69bfcb96f80be84ecd56a81d5a1b977f", + "size_in_bytes": 2846 + }, + { + "_path": "site-packages/pip/_internal/models/link.py", + "path_type": "hardlink", + "sha256": "ced8b9502c75853d377ad62a9ba302a8577bd78725993817f2b4d94fd08a6434", + "size_in_bytes": 21992 + }, + { + "_path": "site-packages/pip/_internal/models/release_control.py", + "path_type": "hardlink", + "sha256": "df5261f991ec4c80592defbbb8f36860b8914965c08c42358c6371c2a2ca7780", + "size_in_bytes": 3365 + }, + { + "_path": "site-packages/pip/_internal/models/scheme.py", + "path_type": "hardlink", + "sha256": "1be3bd28495a6dc5ea6cfc1f13feba9735f97c66a18771aee83024cfff59849c", + "size_in_bytes": 558 + }, + { + "_path": "site-packages/pip/_internal/models/search_scope.py", + "path_type": "hardlink", + "sha256": "fe2f868ffc3f170640bd3b3b5a18ec9410c3ef427ef219887635c1c88f2e1194", + "size_in_bytes": 4461 + }, + { + "_path": "site-packages/pip/_internal/models/selection_prefs.py", + "path_type": "hardlink", + "sha256": "d2d79e930495c56e4c3a4d163c6e4da2fc39abf5c98f18a371def99193ba13d8", + "size_in_bytes": 1503 + }, + { + "_path": "site-packages/pip/_internal/models/target_python.py", + "path_type": "hardlink", + "sha256": "2347854be7a26b793086b3af82ca61159b4d001d88c1767d4abf5fa7a22304fe", + "size_in_bytes": 4243 + }, + { + "_path": "site-packages/pip/_internal/models/wheel.py", + "path_type": "hardlink", + "sha256": "d5275f0ef37b00b4ec6f267d10eb0dcb518f8ab3f59fa1231f2ccfad9c8b4a1f", + "size_in_bytes": 2920 + }, + { + "_path": "site-packages/pip/_internal/network/__init__.py", + "path_type": "hardlink", + "sha256": "14ccb4e8ffffcba8cc8d473ccf765c41d285fa9999db3335e3fbc17873c68542", + "size_in_bytes": 49 + }, + { + "_path": "site-packages/pip/_internal/network/auth.py", + "path_type": "hardlink", + "sha256": "21372e2eeb3bebaeb084d54948836e34c459ccda061f09aa8519cfea112ed289", + "size_in_bytes": 20846 + }, + { + "_path": "site-packages/pip/_internal/network/cache.py", + "path_type": "hardlink", + "sha256": "926457290ac6f44dbac50463db5d4b1de106a4383f4a5614f439f57c9f8031e2", + "size_in_bytes": 4862 + }, + { + "_path": "site-packages/pip/_internal/network/download.py", + "path_type": "hardlink", + "sha256": "f22959c535819bd2754c4a6ea45139e954398ecdcbf35aefdd7d2b6707c13d38", + "size_in_bytes": 12625 + }, + { + "_path": "site-packages/pip/_internal/network/lazy_wheel.py", + "path_type": "hardlink", + "sha256": "cbd81592c7490928e72df633b3f9b70d8500b65de173f93ec453c305df4380eb", + "size_in_bytes": 7646 + }, + { + "_path": "site-packages/pip/_internal/network/session.py", + "path_type": "hardlink", + "sha256": "ef32bb11e402491162a6ee19cdc5a5d55dc030a9225ddb46a85afb1af5362eb6", + "size_in_bytes": 19555 + }, + { + "_path": "site-packages/pip/_internal/network/utils.py", + "path_type": "hardlink", + "sha256": "002b177759aca8d0a2747557b2eecb1d44abf0d81aca970e290e0a1be67fc093", + "size_in_bytes": 4091 + }, + { + "_path": "site-packages/pip/_internal/network/xmlrpc.py", + "path_type": "hardlink", + "sha256": "ffe467937bce7dff2e17d8401a64fa48b00b7e563580c05c6c6c12d767dbfd8e", + "size_in_bytes": 1830 + }, + { + "_path": "site-packages/pip/_internal/operations/__init__.py", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_internal/operations/build/__init__.py", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_internal/operations/build/build_tracker.py", + "path_type": "hardlink", + "sha256": "5b76f972690c58f684e902307f3b136b2268efe3a5c451d60f17cfb9ac7529c1", + "size_in_bytes": 4771 + }, + { + "_path": "site-packages/pip/_internal/operations/build/metadata.py", + "path_type": "hardlink", + "sha256": "20d1da7a245f3a22d80970297c3351a3d0b0db12385704dcd0a22dbdf75f3a39", + "size_in_bytes": 1421 + }, + { + "_path": "site-packages/pip/_internal/operations/build/metadata_editable.py", + "path_type": "hardlink", + "sha256": "a16b9d32c9e3cb89683bf272ee0e0df67c6c9da117fe20e5551802cbba6ed6bb", + "size_in_bytes": 1509 + }, + { + "_path": "site-packages/pip/_internal/operations/build/wheel.py", + "path_type": "hardlink", + "sha256": "ddb3fe9cd889e12f09bcc6819f27acb17414061c53aadd46071e8343588f2436", + "size_in_bytes": 1136 + }, + { + "_path": "site-packages/pip/_internal/operations/build/wheel_editable.py", + "path_type": "hardlink", + "sha256": "ab791f12572533a16eb556c5c04f3b24e4e9556b798b10dfdff5241c02157f3e", + "size_in_bytes": 1478 + }, + { + "_path": "site-packages/pip/_internal/operations/check.py", + "path_type": "hardlink", + "sha256": "c82d975ad87a89e846184fdf8fb5d124b8d5281b13206dd9a16464162deb3b07", + "size_in_bytes": 5894 + }, + { + "_path": "site-packages/pip/_internal/operations/freeze.py", + "path_type": "hardlink", + "sha256": "3c3758fb2fd9b596492c029c6963c8191280196ec35d1e3c7f468c454d23ec10", + "size_in_bytes": 9854 + }, + { + "_path": "site-packages/pip/_internal/operations/install/__init__.py", + "path_type": "hardlink", + "sha256": "6a4f941137103ca94565a5a860a5aee505576e9141be0d2c5dcde2d0ee2f4986", + "size_in_bytes": 50 + }, + { + "_path": "site-packages/pip/_internal/operations/install/wheel.py", + "path_type": "hardlink", + "sha256": "150225d809cd69d1d5e58186395126387b5450d3bc969ce3dc8728a384b6c62b", + "size_in_bytes": 27923 + }, + { + "_path": "site-packages/pip/_internal/operations/prepare.py", + "path_type": "hardlink", + "sha256": "1b1eabe7b2c6fe0baf0181aa29476effaf2b1cf3e43bb090fea736c0a9d8cacb", + "size_in_bytes": 29046 + }, + { + "_path": "site-packages/pip/_internal/pyproject.py", + "path_type": "hardlink", + "sha256": "27eb135aa0be5dfb0a420cfd9b56f2a4c5993c722db121f320dfcd59e2119a13", + "size_in_bytes": 4555 + }, + { + "_path": "site-packages/pip/_internal/req/__init__.py", + "path_type": "hardlink", + "sha256": "59c63dcfb0f7ae520a5f5418f3fb519c0b12fe9a1e6e218676d43b109e49410a", + "size_in_bytes": 3041 + }, + { + "_path": "site-packages/pip/_internal/req/constructors.py", + "path_type": "hardlink", + "sha256": "11781b314700b4168d8fa7189acd19c1e23134e4a838f7101bc12a5e5f476213", + "size_in_bytes": 22918 + }, + { + "_path": "site-packages/pip/_internal/req/pep723.py", + "path_type": "hardlink", + "sha256": "26c1b5a7709a55c5bc7237250f69038fb77daad56b35069ebd8fd49ca874d2d9", + "size_in_bytes": 1242 + }, + { + "_path": "site-packages/pip/_internal/req/req_dependency_group.py", + "path_type": "hardlink", + "sha256": "3eb58ab65c08f316d69d610a8d7b3d464ae9431dbf874d8005e7d84f465d7908", + "size_in_bytes": 3145 + }, + { + "_path": "site-packages/pip/_internal/req/req_file.py", + "path_type": "hardlink", + "sha256": "89d563e2e55df32408050a23a2e94bd5c7971abd5093ca27817cf0238bd34ecb", + "size_in_bytes": 20521 + }, + { + "_path": "site-packages/pip/_internal/req/req_install.py", + "path_type": "hardlink", + "sha256": "555ccef14229e93394fd0084a12c587641b7f73e78a4a3d08e0f19eb3e166cd3", + "size_in_bytes": 31845 + }, + { + "_path": "site-packages/pip/_internal/req/req_set.py", + "path_type": "hardlink", + "sha256": "6b092a2179d80383eb9ac8f441bdf386a75b61499777ed68d0ff8a6779af450b", + "size_in_bytes": 2828 + }, + { + "_path": "site-packages/pip/_internal/req/req_uninstall.py", + "path_type": "hardlink", + "sha256": "74298e1edfbd45a241abddb52f8b4c1f73e62010deb46a659db8d1297986b74d", + "size_in_bytes": 24099 + }, + { + "_path": "site-packages/pip/_internal/resolution/__init__.py", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_internal/resolution/base.py", + "path_type": "hardlink", + "sha256": "448b2a48fefda253dd3a0b4f296fa8390dfae08095a297a103a45f1a445f7b6b", + "size_in_bytes": 577 + }, + { + "_path": "site-packages/pip/_internal/resolution/legacy/__init__.py", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_internal/resolution/legacy/resolver.py", + "path_type": "hardlink", + "sha256": "a4cc14d7514ed63796076bd7fb0bc0e5f7720c13d61fa0dc723f6a11d8756773", + "size_in_bytes": 24061 + }, + { + "_path": "site-packages/pip/_internal/resolution/resolvelib/__init__.py", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_internal/resolution/resolvelib/base.py", + "path_type": "hardlink", + "sha256": "837aad724021dc4df8cbee47ad82e5627399f5288f183212cecaa16910d402a4", + "size_in_bytes": 5903 + }, + { + "_path": "site-packages/pip/_internal/resolution/resolvelib/candidates.py", + "path_type": "hardlink", + "sha256": "e2fdc0d90ee04b56b5b5b31ba61a3d1e58855b87d198716ece3f1f6bb4e167a7", + "size_in_bytes": 20912 + }, + { + "_path": "site-packages/pip/_internal/resolution/resolvelib/factory.py", + "path_type": "hardlink", + "sha256": "81646b720afae1baf479c17f3cfc4a7e7797133af493e4a896fd97f73dc6a23d", + "size_in_bytes": 36771 + }, + { + "_path": "site-packages/pip/_internal/resolution/resolvelib/found_candidates.py", + "path_type": "hardlink", + "sha256": "f1b6580c264b5d274b1f2fecd68e5fe2bd791e62afa85521cc1510385db52ebe", + "size_in_bytes": 6018 + }, + { + "_path": "site-packages/pip/_internal/resolution/resolvelib/provider.py", + "path_type": "hardlink", + "sha256": "5f79eb09c5537abde6652132fb5dca88f1412589a17d625d03572bf869f5abb3", + "size_in_bytes": 12150 + }, + { + "_path": "site-packages/pip/_internal/resolution/resolvelib/reporter.py", + "path_type": "hardlink", + "sha256": "b440bb305f08a865385b0f6deb56157cd14ab68690a5bebe0302d9a6d273d551", + "size_in_bytes": 3918 + }, + { + "_path": "site-packages/pip/_internal/resolution/resolvelib/requirements.py", + "path_type": "hardlink", + "sha256": "23397d9fc9dcd7cf250350523d2f10c5fb9d7c340f1e09e0c3e8a3ea15edd274", + "size_in_bytes": 8239 + }, + { + "_path": "site-packages/pip/_internal/resolution/resolvelib/resolver.py", + "path_type": "hardlink", + "sha256": "c10f781e47a9fbb91610701cf8d6cc2619b3784ce0100b71781c72295cd9a1ea", + "size_in_bytes": 13437 + }, + { + "_path": "site-packages/pip/_internal/self_outdated_check.py", + "path_type": "hardlink", + "sha256": "f57c4e5cfaac66529c7933f6b594bb23bad78e8767a9ddc6ac843c534fcbf013", + "size_in_bytes": 8097 + }, + { + "_path": "site-packages/pip/_internal/utils/__init__.py", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_internal/utils/_jaraco_text.py", + "path_type": "hardlink", + "sha256": "335e6e50f221e4da4fd6d754181c516aeeaad59004b48f3e5f22c4113b1c15f1", + "size_in_bytes": 3350 + }, + { + "_path": "site-packages/pip/_internal/utils/_log.py", + "path_type": "hardlink", + "sha256": "fa31cb384fd31da673e4115c0a7a122fd11802d2749d77a6e3db3da1fe23bcac", + "size_in_bytes": 1015 + }, + { + "_path": "site-packages/pip/_internal/utils/appdirs.py", + "path_type": "hardlink", + "sha256": "2ebcc33d930a561d2bb9bb42c7dbeedd79596cb092ba0e954a3e10b2fb7ae810", + "size_in_bytes": 1681 + }, + { + "_path": "site-packages/pip/_internal/utils/compat.py", + "path_type": "hardlink", + "sha256": "0bd2c75c900a930007f079f79cf933f4460adeba8f05e3bf21790e1b6cf3b1d4", + "size_in_bytes": 2514 + }, + { + "_path": "site-packages/pip/_internal/utils/compatibility_tags.py", + "path_type": "hardlink", + "sha256": "0e23522eaa6eaee5d46a6190c0e2765990720c62d319a5e2f4ef977fc7ce8b7e", + "size_in_bytes": 6630 + }, + { + "_path": "site-packages/pip/_internal/utils/datetime.py", + "path_type": "hardlink", + "sha256": "92e24e7f5996f06e6d44537a8d66ab75d752fbda92691e7794ad639b1dcd4d96", + "size_in_bytes": 868 + }, + { + "_path": "site-packages/pip/_internal/utils/deprecation.py", + "path_type": "hardlink", + "sha256": "a04425b660aae382d0e843fb345e5b67248c7fec0289fa32cbd8e5dfad419d53", + "size_in_bytes": 4319 + }, + { + "_path": "site-packages/pip/_internal/utils/direct_url_helpers.py", + "path_type": "hardlink", + "sha256": "58208f2679a83c7cfb92261e3eb11c5407a7da50e9093f56415226a071d608ef", + "size_in_bytes": 3363 + }, + { + "_path": "site-packages/pip/_internal/utils/egg_link.py", + "path_type": "hardlink", + "sha256": "6167ecadb99f72b7d682a418cba3ae223b326fd21f2f5abfdafe33b26b355a32", + "size_in_bytes": 2459 + }, + { + "_path": "site-packages/pip/_internal/utils/entrypoints.py", + "path_type": "hardlink", + "sha256": "b8f8c0c9284a39b768b63423254ce9ad0eabdf142f0c86705187c71ea67b0e89", + "size_in_bytes": 3324 + }, + { + "_path": "site-packages/pip/_internal/utils/filesystem.py", + "path_type": "hardlink", + "sha256": "181078da96f199481d4406d280b4d1ad64046a9c8b0834a3c53db50cde108d4f", + "size_in_bytes": 6812 + }, + { + "_path": "site-packages/pip/_internal/utils/filetypes.py", + "path_type": "hardlink", + "sha256": "b0431adfca9aaa3bf1d5989ddce0805236b7d4138153e512b9230f06f537ca3a", + "size_in_bytes": 689 + }, + { + "_path": "site-packages/pip/_internal/utils/glibc.py", + "path_type": "hardlink", + "sha256": "b0487c44924b612751bd3a803b84c754f3c0f9848354b0f8488f52a3e6f15f55", + "size_in_bytes": 3726 + }, + { + "_path": "site-packages/pip/_internal/utils/hashes.py", + "path_type": "hardlink", + "sha256": "dfcf9b08e2521e2a6943bafd46db6b307c5bda6bf710046dd46c3c905996ef78", + "size_in_bytes": 5040 + }, + { + "_path": "site-packages/pip/_internal/utils/logging.py", + "path_type": "hardlink", + "sha256": "ea5256302e9ceff683fe2e2c76069a79bf939b7916a5883485b6bf575f8e2e71", + "size_in_bytes": 13414 + }, + { + "_path": "site-packages/pip/_internal/utils/misc.py", + "path_type": "hardlink", + "sha256": "f9f17face871071a79ee4c0694d9775f388172cd2009fe83d39c3167e9a4a137", + "size_in_bytes": 23704 + }, + { + "_path": "site-packages/pip/_internal/utils/packaging.py", + "path_type": "hardlink", + "sha256": "b39b6952616e9b05741fd2524f3af2ac863827040cf29686b7b4a6ede370b766", + "size_in_bytes": 1601 + }, + { + "_path": "site-packages/pip/_internal/utils/pylock.py", + "path_type": "hardlink", + "sha256": "4f8ab277e4d66f9e3020ee7f0ddc004804ed53b822d3c20611affea5d151ec71", + "size_in_bytes": 9358 + }, + { + "_path": "site-packages/pip/_internal/utils/retry.py", + "path_type": "hardlink", + "sha256": "f37c11784076adc9ed319e552ddedab1c6984a39ff90b765402ab120bc5690f3", + "size_in_bytes": 1461 + }, + { + "_path": "site-packages/pip/_internal/utils/subprocess.py", + "path_type": "hardlink", + "sha256": "af8f816bf61cdee6574298b42b8a5916c093fd0a9d4afb45dd727edb4e1059a0", + "size_in_bytes": 8983 + }, + { + "_path": "site-packages/pip/_internal/utils/temp_dir.py", + "path_type": "hardlink", + "sha256": "0fd73c0fb58e3eba0e3bc1860eaa417954a3d74346166ba71b4a364e87638c85", + "size_in_bytes": 9307 + }, + { + "_path": "site-packages/pip/_internal/utils/unpacking.py", + "path_type": "hardlink", + "sha256": "eb6aa914e971465e708db788612ac5f8613e340d4aa3b980623cb0799c7d316b", + "size_in_bytes": 13537 + }, + { + "_path": "site-packages/pip/_internal/utils/urls.py", + "path_type": "hardlink", + "sha256": "685fde83dba5e5df1b302c5f4924b141c7ecf8ea4975b4ad62a647a32d8ad511", + "size_in_bytes": 1601 + }, + { + "_path": "site-packages/pip/_internal/utils/virtualenv.py", + "path_type": "hardlink", + "sha256": "997f943f2c3530fc61c14c4a85ba96597ef427a3c75c0263555ad19c6d21f667", + "size_in_bytes": 3455 + }, + { + "_path": "site-packages/pip/_internal/utils/wheel.py", + "path_type": "hardlink", + "sha256": "61d46e8fa322706f90f4c834dc56d4bf55932da9ba2dcec08228d8e2fa15ca2b", + "size_in_bytes": 4468 + }, + { + "_path": "site-packages/pip/_internal/vcs/__init__.py", + "path_type": "hardlink", + "sha256": "500aafce96e2d156d9a3751beac904799030fa8a08651fb35ff5a909bc720a85", + "size_in_bytes": 596 + }, + { + "_path": "site-packages/pip/_internal/vcs/bazaar.py", + "path_type": "hardlink", + "sha256": "dd6d5e1e3918c76bdce9ba1e6f634187823fae51805ccfafaf37cd84b9b54718", + "size_in_bytes": 3734 + }, + { + "_path": "site-packages/pip/_internal/vcs/git.py", + "path_type": "hardlink", + "sha256": "4d37aa0eecd2fbf04548db944ad556984da7183a4abaf521041264fc20905d5d", + "size_in_bytes": 19144 + }, + { + "_path": "site-packages/pip/_internal/vcs/mercurial.py", + "path_type": "hardlink", + "sha256": "c3564958b2aa34fd689c48e47e39700559cca8f64d488111f1aca341c9d3ab8c", + "size_in_bytes": 5575 + }, + { + "_path": "site-packages/pip/_internal/vcs/subversion.py", + "path_type": "hardlink", + "sha256": "b9481d3efc66bc407c430b63af41dcd178058db88d8b971bbc8e2f0112ce257a", + "size_in_bytes": 11787 + }, + { + "_path": "site-packages/pip/_internal/vcs/versioncontrol.py", + "path_type": "hardlink", + "sha256": "31afc7319055bde4a4798bf169cbea7ae8e791221a1755e3c53b12dc1c1c27c1", + "size_in_bytes": 22599 + }, + { + "_path": "site-packages/pip/_internal/wheel_builder.py", + "path_type": "hardlink", + "sha256": "caf1142d2b59b6dcbd2a9969f3db438acde119dc8a43ed8151b14b989ff98a79", + "size_in_bytes": 9010 + }, + { + "_path": "site-packages/pip/_vendor/README.rst", + "path_type": "hardlink", + "sha256": "b7b2229e36a2bb0521f35d9799502940725bf294f0df753c03d511ab2e86945e", + "size_in_bytes": 9222 + }, + { + "_path": "site-packages/pip/_vendor/__init__.py", + "path_type": "hardlink", + "sha256": "5b3bac3d319620c790416495274876ada7c69154daf56289d874fedbe12866b5", + "size_in_bytes": 4907 + }, + { + "_path": "site-packages/pip/_vendor/cachecontrol/LICENSE.txt", + "path_type": "hardlink", + "sha256": "86eeee87be2a43f3ff1f56496f451f69243926f025fedbb033666c304c4c161b", + "size_in_bytes": 558 + }, + { + "_path": "site-packages/pip/_vendor/cachecontrol/__init__.py", + "path_type": "hardlink", + "sha256": "1b1c11926fd3401b4f6697e954af6be92f5d032d835675600d51c929388f6759", + "size_in_bytes": 820 + }, + { + "_path": "site-packages/pip/_vendor/cachecontrol/_cmd.py", + "path_type": "hardlink", + "sha256": "8a2b2dd84a7326f0d5221300c57abc8859d306c89901dea2a65c5f98d6e83729", + "size_in_bytes": 1737 + }, + { + "_path": "site-packages/pip/_vendor/cachecontrol/adapter.py", + "path_type": "hardlink", + "sha256": "5be1d6fa5d358320ac9f190ec826eac7bb31ad662805b2ab0ec2a455540de8d1", + "size_in_bytes": 6586 + }, + { + "_path": "site-packages/pip/_vendor/cachecontrol/cache.py", + "path_type": "hardlink", + "sha256": "397c2fec59f60309ca3626a12479e3b6f68a2e776f54bbfffb33be96d955f6a2", + "size_in_bytes": 1953 + }, + { + "_path": "site-packages/pip/_vendor/cachecontrol/caches/__init__.py", + "path_type": "hardlink", + "sha256": "76daebae82b90670034751968c2675f5a674b45b0c7ef141b4b410535b29fda8", + "size_in_bytes": 303 + }, + { + "_path": "site-packages/pip/_vendor/cachecontrol/caches/file_cache.py", + "path_type": "hardlink", + "sha256": "77cba9166cbfcf06829a56d61150652d715d76df19c3c739485a7178e66c75fc", + "size_in_bytes": 4117 + }, + { + "_path": "site-packages/pip/_vendor/cachecontrol/caches/redis_cache.py", + "path_type": "hardlink", + "sha256": "f6b9aac2d62efe58d5916ebfa0ba9b0bb11a5ff6bc613ff22ee9daf9e4b4760a", + "size_in_bytes": 1386 + }, + { + "_path": "site-packages/pip/_vendor/cachecontrol/controller.py", + "path_type": "hardlink", + "sha256": "c416ae0bebd44aee46b09b310f8f96f8968aaaa6c1cf430de99bfc3c0d8df212", + "size_in_bytes": 19102 + }, + { + "_path": "site-packages/pip/_vendor/cachecontrol/filewrapper.py", + "path_type": "hardlink", + "sha256": "0e1c42feb4a4f9b78a75bb1885fbc1503a2f4075fdaf78071ff8cff7eabf98a9", + "size_in_bytes": 4354 + }, + { + "_path": "site-packages/pip/_vendor/cachecontrol/heuristics.py", + "path_type": "hardlink", + "sha256": "82a31753cc34810b8442249dbb7620fb4bddf645bb9eb58a6cb71aef9ae17861", + "size_in_bytes": 4881 + }, + { + "_path": "site-packages/pip/_vendor/cachecontrol/py.typed", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_vendor/cachecontrol/serialize.py", + "path_type": "hardlink", + "sha256": "1d0776225950d391f33e454b3174c5dae5f99a31108c3064c42a94254383a599", + "size_in_bytes": 5163 + }, + { + "_path": "site-packages/pip/_vendor/cachecontrol/wrapper.py", + "path_type": "hardlink", + "sha256": "86c19cee0f101904d3fb87fcb60cf700ce6ac12720e853b405274b491744be95", + "size_in_bytes": 1417 + }, + { + "_path": "site-packages/pip/_vendor/certifi/LICENSE", + "path_type": "hardlink", + "sha256": "e93716da6b9c0d5a4a1df60fe695b370f0695603d21f6f83f053e42cfc10caf7", + "size_in_bytes": 989 + }, + { + "_path": "site-packages/pip/_vendor/certifi/__init__.py", + "path_type": "hardlink", + "sha256": "73d79a62e7efd6948b97443c40d70c88c2cb1f85aab8373174fc8a8e6238a296", + "size_in_bytes": 94 + }, + { + "_path": "site-packages/pip/_vendor/certifi/__main__.py", + "path_type": "hardlink", + "sha256": "d64dc2afde6f0b1c464460e58eb5b7c0c76965d2f73617f4bb59fe936a9db026", + "size_in_bytes": 255 + }, + { + "_path": "site-packages/pip/_vendor/certifi/cacert.pem", + "path_type": "hardlink", + "sha256": "fc9165a12403263e7ebfbdad7be7a3eac0fa5d325d3c70465f28d3690072ca28", + "size_in_bytes": 272441 + }, + { + "_path": "site-packages/pip/_vendor/certifi/core.py", + "path_type": "hardlink", + "sha256": "82efc40952359b746ad32b69b0d13ad6181019c29a380b7d46cf46f0ab1308e2", + "size_in_bytes": 3442 + }, + { + "_path": "site-packages/pip/_vendor/certifi/py.typed", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_vendor/distlib/LICENSE.txt", + "path_type": "hardlink", + "sha256": "808e10c8a6ab8deb149ff9b3fb19f447a808094606d712a9ca57fead3552599d", + "size_in_bytes": 14531 + }, + { + "_path": "site-packages/pip/_vendor/distlib/__init__.py", + "path_type": "hardlink", + "sha256": "0dea37ba8f7c694c887dd28936aa1f7921055b00f3ad5d907862d72ec82ad008", + "size_in_bytes": 625 + }, + { + "_path": "site-packages/pip/_vendor/distlib/compat.py", + "path_type": "hardlink", + "sha256": "da34528d1238a3ebe55de4cad8108621486473a7bd646852b1a711339a2c793c", + "size_in_bytes": 41467 + }, + { + "_path": "site-packages/pip/_vendor/distlib/resources.py", + "path_type": "hardlink", + "sha256": "2f06cf92c73403524c6e2e979ee3dd301527f375fb04fb85356a8f184288ebdf", + "size_in_bytes": 10820 + }, + { + "_path": "site-packages/pip/_vendor/distlib/scripts.py", + "path_type": "hardlink", + "sha256": "42fa7be84f49737220c98b9b9e9a88f5f4bb7ac78639ee058e97952aa2adf48c", + "size_in_bytes": 18612 + }, + { + "_path": "site-packages/pip/_vendor/distlib/t32.exe", + "path_type": "hardlink", + "sha256": "6b4195e640a85ac32eb6f9628822a622057df1e459df7c17a12f97aeabc9415b", + "size_in_bytes": 97792 + }, + { + "_path": "site-packages/pip/_vendor/distlib/t64-arm.exe", + "path_type": "hardlink", + "sha256": "ebc4c06b7d95e74e315419ee7e88e1d0f71e9e9477538c00a93a9ff8c66a6cfc", + "size_in_bytes": 182784 + }, + { + "_path": "site-packages/pip/_vendor/distlib/t64.exe", + "path_type": "hardlink", + "sha256": "81a618f21cb87db9076134e70388b6e9cb7c2106739011b6a51772d22cae06b7", + "size_in_bytes": 108032 + }, + { + "_path": "site-packages/pip/_vendor/distlib/util.py", + "path_type": "hardlink", + "sha256": "bcc3c6bec4b88fd845e98f64dd3ca89b569a1cb6f4ac5999004cb378075e97dc", + "size_in_bytes": 66682 + }, + { + "_path": "site-packages/pip/_vendor/distlib/w32.exe", + "path_type": "hardlink", + "sha256": "47872cc77f8e18cf642f868f23340a468e537e64521d9a3a416c8b84384d064b", + "size_in_bytes": 91648 + }, + { + "_path": "site-packages/pip/_vendor/distlib/w64-arm.exe", + "path_type": "hardlink", + "sha256": "c5dc9884a8f458371550e09bd396e5418bf375820a31b9899f6499bf391c7b2e", + "size_in_bytes": 168448 + }, + { + "_path": "site-packages/pip/_vendor/distlib/w64.exe", + "path_type": "hardlink", + "sha256": "7a319ffaba23a017d7b1e18ba726ba6c54c53d6446db55f92af53c279894f8ad", + "size_in_bytes": 101888 + }, + { + "_path": "site-packages/pip/_vendor/distro/LICENSE", + "path_type": "hardlink", + "sha256": "cb5e8e7e5f4a3988e1063c142c60dc2df75605f4c46515e776e3aca6df976e14", + "size_in_bytes": 11325 + }, + { + "_path": "site-packages/pip/_vendor/distro/__init__.py", + "path_type": "hardlink", + "sha256": "d9f1e317e49f80fbe3c8d67588787fc23a96751fd8a393831f0642d232c13e17", + "size_in_bytes": 981 + }, + { + "_path": "site-packages/pip/_vendor/distro/__main__.py", + "path_type": "hardlink", + "sha256": "6eef5ddd389fa0a72264572a441bb2815dc64ae4e19d50ff9b620ae1ccfde95b", + "size_in_bytes": 64 + }, + { + "_path": "site-packages/pip/_vendor/distro/distro.py", + "path_type": "hardlink", + "sha256": "5ea6de7da7008434f8cebfedae76c0d79798f2f74ae064e08609af506ac433fe", + "size_in_bytes": 49430 + }, + { + "_path": "site-packages/pip/_vendor/distro/py.typed", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_vendor/idna/LICENSE.md", + "path_type": "hardlink", + "sha256": "b7a336abf3b04e180ec065cdd16e705d079e1cc7a14f910aa6e9187f36b9cd87", + "size_in_bytes": 1541 + }, + { + "_path": "site-packages/pip/_vendor/idna/__init__.py", + "path_type": "hardlink", + "sha256": "30fa8d0cb65b5ea19a35d5f1005862a853ca1105e3bb68cd42109ecbafb97893", + "size_in_bytes": 868 + }, + { + "_path": "site-packages/pip/_vendor/idna/codec.py", + "path_type": "hardlink", + "sha256": "33648658dedcb3fe81df6426293c9337ac50199798420436c225f7fc347a9681", + "size_in_bytes": 3438 + }, + { + "_path": "site-packages/pip/_vendor/idna/compat.py", + "path_type": "hardlink", + "sha256": "4732f2e90402765f7bf3868585bd845fd10a1822638343f73e294675e5d7731f", + "size_in_bytes": 316 + }, + { + "_path": "site-packages/pip/_vendor/idna/core.py", + "path_type": "hardlink", + "sha256": "3f6ebf5d5c9cb8c4d9d51da634ad594445733399af4f375a6c15dfc99554d4b7", + "size_in_bytes": 13246 + }, + { + "_path": "site-packages/pip/_vendor/idna/idnadata.py", + "path_type": "hardlink", + "sha256": "486f2385a184e778a20fa078f69b76a704effd4bc295c89613e379e28476a785", + "size_in_bytes": 79623 + }, + { + "_path": "site-packages/pip/_vendor/idna/intranges.py", + "path_type": "hardlink", + "sha256": "6a652d91d8587101bc66bf82a0c33f91545a731922bc2d568313756fadca29d5", + "size_in_bytes": 1898 + }, + { + "_path": "site-packages/pip/_vendor/idna/package_data.py", + "path_type": "hardlink", + "sha256": "fc251abcec686e76f2346d852f21e837c4073f740cf56d6d2aec3b7aaf50c019", + "size_in_bytes": 21 + }, + { + "_path": "site-packages/pip/_vendor/idna/py.typed", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_vendor/idna/uts46data.py", + "path_type": "hardlink", + "sha256": "1fd277e55903d05f4bf6628eaa378d19dd80f956ba1653e8cfa273e0aee1fa9b", + "size_in_bytes": 243725 + }, + { + "_path": "site-packages/pip/_vendor/msgpack/COPYING", + "path_type": "hardlink", + "sha256": "492dedba85da5872f78e6091bcd1fea474d660d35acb4dee964b8aab3f007427", + "size_in_bytes": 614 + }, + { + "_path": "site-packages/pip/_vendor/msgpack/__init__.py", + "path_type": "hardlink", + "sha256": "440f2072a2b5ed8a64c419cdc172556b5a1ad8bca058381f1759c0d4d3f0de6a", + "size_in_bytes": 1109 + }, + { + "_path": "site-packages/pip/_vendor/msgpack/exceptions.py", + "path_type": "hardlink", + "sha256": "7424d67a2f1da64accb100dc8d093be004e5f47b08047d326edf3338f36a3187", + "size_in_bytes": 1081 + }, + { + "_path": "site-packages/pip/_vendor/msgpack/ext.py", + "path_type": "hardlink", + "sha256": "92d789bf4de7f6d633779a28df1628a554e8e2f45a031a27050409857a21659a", + "size_in_bytes": 5726 + }, + { + "_path": "site-packages/pip/_vendor/msgpack/fallback.py", + "path_type": "hardlink", + "sha256": "d20d4fce9d2fb66044989e70f45decffe24c55444ff114b81b571ce5345a02c2", + "size_in_bytes": 32390 + }, + { + "_path": "site-packages/pip/_vendor/packaging/LICENSE", + "path_type": "hardlink", + "sha256": "cad1ef5bd340d73e074ba614d26f7deaca5c7940c3d8c34852e65c4909686c48", + "size_in_bytes": 197 + }, + { + "_path": "site-packages/pip/_vendor/packaging/LICENSE.APACHE", + "path_type": "hardlink", + "sha256": "0d542e0c8804e39aa7f37eb00da5a762149dc682d7829451287e11b938e94594", + "size_in_bytes": 10174 + }, + { + "_path": "site-packages/pip/_vendor/packaging/LICENSE.BSD", + "path_type": "hardlink", + "sha256": "b70e7e9b742f1cc6f948b34c16aa39ffece94196364bc88ff0d2180f0028fac5", + "size_in_bytes": 1344 + }, + { + "_path": "site-packages/pip/_vendor/packaging/__init__.py", + "path_type": "hardlink", + "sha256": "42130474fbb65e882b2735774b42964bab7b97423d93c11e0d1265e1f9f0f3bb", + "size_in_bytes": 494 + }, + { + "_path": "site-packages/pip/_vendor/packaging/_elffile.py", + "path_type": "hardlink", + "sha256": "fac2a4a6d62acd8c36fb1dd007225ae66078adf3d6bb5a719191d1c755801426", + "size_in_bytes": 3211 + }, + { + "_path": "site-packages/pip/_vendor/packaging/_manylinux.py", + "path_type": "hardlink", + "sha256": "1dfea707470eadac84b3debea77a085c08069c5aaebf6d033b997ea36fd79efd", + "size_in_bytes": 9559 + }, + { + "_path": "site-packages/pip/_vendor/packaging/_musllinux.py", + "path_type": "hardlink", + "sha256": "67ab308c7dcc03b5d2dea5e798c37b40f86a3f77e7a18234790d7c7bdf878001", + "size_in_bytes": 2707 + }, + { + "_path": "site-packages/pip/_vendor/packaging/_parser.py", + "path_type": "hardlink", + "sha256": "29fda7b03c38739e17f36a58f1b6b8174d81bdee8eca018c0232fe05e82a71ec", + "size_in_bytes": 11698 + }, + { + "_path": "site-packages/pip/_vendor/packaging/_structures.py", + "path_type": "hardlink", + "sha256": "eb48d16c5efca7ccf930a9cd77a700a6b80e69d0891d5d03966526441a8565cb", + "size_in_bytes": 1109 + }, + { + "_path": "site-packages/pip/_vendor/packaging/_tokenizer.py", + "path_type": "hardlink", + "sha256": "b455365abf996497406e45cb109a3ba9440325a2247dfb7d0ea6a27e210d0fb0", + "size_in_bytes": 5391 + }, + { + "_path": "site-packages/pip/_vendor/packaging/dependency_groups.py", + "path_type": "hardlink", + "sha256": "5d92005452bdb871b84421a9ae6267dd522751631eb3185afe4cad26e30ef5e6", + "size_in_bytes": 10218 + }, + { + "_path": "site-packages/pip/_vendor/packaging/direct_url.py", + "path_type": "hardlink", + "sha256": "78a99b0e23cfd6c2d5e0c8ff902499aaa927ac8c953bd4abec9a45f0a0a3a785", + "size_in_bytes": 10917 + }, + { + "_path": "site-packages/pip/_vendor/packaging/errors.py", + "path_type": "hardlink", + "sha256": "ea17c461701ff2ffc817ae7e94569d24e30889e04fdb120ab721178c6d67188b", + "size_in_bytes": 2680 + }, + { + "_path": "site-packages/pip/_vendor/packaging/licenses/__init__.py", + "path_type": "hardlink", + "sha256": "fc9c745d1883ff9f296a5b169f22eb2ee879f59a4608f20f5cb29d668f4e26f4", + "size_in_bytes": 7293 + }, + { + "_path": "site-packages/pip/_vendor/packaging/licenses/_spdx.py", + "path_type": "hardlink", + "sha256": "596ec35e2ca0ebcba9fd8343ff0a51625af548786257815f24b41f7e08613314", + "size_in_bytes": 51122 + }, + { + "_path": "site-packages/pip/_vendor/packaging/markers.py", + "path_type": "hardlink", + "sha256": "422c4155c6fd0f61e3c04622ba1a4d91baa4f739cf45b53cccd5f4911d5122b5", + "size_in_bytes": 17067 + }, + { + "_path": "site-packages/pip/_vendor/packaging/metadata.py", + "path_type": "hardlink", + "sha256": "72b021d04dc654656a3e5bba11d445b1a1be63a518ce74d4aa3b8629118fbfa7", + "size_in_bytes": 38770 + }, + { + "_path": "site-packages/pip/_vendor/packaging/py.typed", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_vendor/packaging/pylock.py", + "path_type": "hardlink", + "sha256": "1bfd609dc4e60db44b6358e8e150c8f54c3e6f9204ae1fd0f55fc16d5253983f", + "size_in_bytes": 33890 + }, + { + "_path": "site-packages/pip/_vendor/packaging/requirements.py", + "path_type": "hardlink", + "sha256": "43e05d107556e4aefce46057b7b45c3f8504b1d20a5a8585aa5ac78d1e16579d", + "size_in_bytes": 4395 + }, + { + "_path": "site-packages/pip/_vendor/packaging/specifiers.py", + "path_type": "hardlink", + "sha256": "dd705c4ac966f984041043bfcebbf817a751e70471b3812b26f274be33417c63", + "size_in_bytes": 71550 + }, + { + "_path": "site-packages/pip/_vendor/packaging/tags.py", + "path_type": "hardlink", + "sha256": "00d607671610569f4194e41838753902b0cd548a53165e0a95ba1c6150569c5b", + "size_in_bytes": 34236 + }, + { + "_path": "site-packages/pip/_vendor/packaging/utils.py", + "path_type": "hardlink", + "sha256": "33bf8930a89cdac3f562d57ff1a5bb795181fb1dc00ee282892aec55e09dd94a", + "size_in_bytes": 9848 + }, + { + "_path": "site-packages/pip/_vendor/packaging/version.py", + "path_type": "hardlink", + "sha256": "31cbbb4dfe98d62d20438157bf8b7483c71b2f98e8004b218e0229cffdaf2122", + "size_in_bytes": 38393 + }, + { + "_path": "site-packages/pip/_vendor/pkg_resources/LICENSE", + "path_type": "hardlink", + "sha256": "86da0f01aeae46348a3c3d465195dc1ceccde79f79e87769a64b8da04b2a4741", + "size_in_bytes": 1023 + }, + { + "_path": "site-packages/pip/_vendor/pkg_resources/__init__.py", + "path_type": "hardlink", + "sha256": "bdb4c9d3faee5201b1423944aacaee16688d3d5ca1dadf6afb3c930d3d39df12", + "size_in_bytes": 124451 + }, + { + "_path": "site-packages/pip/_vendor/platformdirs/LICENSE", + "path_type": "hardlink", + "sha256": "29e0fd62e929850e86eb28c3fdccf0cefdf4fa94879011cffb3d0d4bed6d4db6", + "size_in_bytes": 1089 + }, + { + "_path": "site-packages/pip/_vendor/platformdirs/__init__.py", + "path_type": "hardlink", + "sha256": "51f7921d697c01e4ed6ce04ea070312b874e0ce5a466d7f2fa6fe2edc59d27c7", + "size_in_bytes": 22344 + }, + { + "_path": "site-packages/pip/_vendor/platformdirs/__main__.py", + "path_type": "hardlink", + "sha256": "8c127ccdbecca71e5e6dca85f37c6ba4ef7831a782a4d18755ff5cbc337624b8", + "size_in_bytes": 1505 + }, + { + "_path": "site-packages/pip/_vendor/platformdirs/android.py", + "path_type": "hardlink", + "sha256": "af40ec85505ff913b58d72465fc0b84e297b1755d6b7e6e47563209af1226988", + "size_in_bytes": 9013 + }, + { + "_path": "site-packages/pip/_vendor/platformdirs/api.py", + "path_type": "hardlink", + "sha256": "c0f1ce9703ac7f3da8a9067a03615c0aee641008fe2689ddce834e1d8150d21f", + "size_in_bytes": 9281 + }, + { + "_path": "site-packages/pip/_vendor/platformdirs/macos.py", + "path_type": "hardlink", + "sha256": "d17a0e8229f534aed0922ee2b240fea12f312b1c3a6d782828481daa90910054", + "size_in_bytes": 6322 + }, + { + "_path": "site-packages/pip/_vendor/platformdirs/py.typed", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_vendor/platformdirs/unix.py", + "path_type": "hardlink", + "sha256": "5999a4500fbe2f724d4469b3df6b37e587e80f789c6bac4a20f74257f1e12dcb", + "size_in_bytes": 10458 + }, + { + "_path": "site-packages/pip/_vendor/platformdirs/version.py", + "path_type": "hardlink", + "sha256": "048fdd28b48cc25925e7bbe5c599d3f285633e2502d96fec771ffcfe1f7d1de4", + "size_in_bytes": 704 + }, + { + "_path": "site-packages/pip/_vendor/platformdirs/windows.py", + "path_type": "hardlink", + "sha256": "5ef09f925194315c496d78ade758e960c37e94d79270f07cdaa4b50807a994bd", + "size_in_bytes": 10362 + }, + { + "_path": "site-packages/pip/_vendor/pygments/LICENSE", + "path_type": "hardlink", + "sha256": "a9d66f1d526df02e29dce73436d34e56e8632f46c275bbdffc70569e882f9f17", + "size_in_bytes": 1331 + }, + { + "_path": "site-packages/pip/_vendor/pygments/__init__.py", + "path_type": "hardlink", + "sha256": "f2e36a2420b05ea6c4c79692b01af417291440e0432818a13b998faa2c356aaa", + "size_in_bytes": 2983 + }, + { + "_path": "site-packages/pip/_vendor/pygments/__main__.py", + "path_type": "hardlink", + "sha256": "5ab9dda527ba8b57245ff490d4a6b10fd093286cc3d04b82385c5c6f0169a0b5", + "size_in_bytes": 353 + }, + { + "_path": "site-packages/pip/_vendor/pygments/console.py", + "path_type": "hardlink", + "sha256": "01a8035aac1e6b6c8159fd74282f69b4180ca4c8f12a9f3200102687e3503959", + "size_in_bytes": 1718 + }, + { + "_path": "site-packages/pip/_vendor/pygments/filter.py", + "path_type": "hardlink", + "sha256": "60bb694e7662bb4ee7637a0af677d1e84f58d4504784fe4f5fc82f90959c7da8", + "size_in_bytes": 1910 + }, + { + "_path": "site-packages/pip/_vendor/pygments/filters/__init__.py", + "path_type": "hardlink", + "sha256": "e14e23b40d17de23fcdee42707df9323e1c34b0f04f32f333181dad148db6da2", + "size_in_bytes": 40392 + }, + { + "_path": "site-packages/pip/_vendor/pygments/formatter.py", + "path_type": "hardlink", + "sha256": "29940c9b2a3fc643889101bc83ae8b6049018756f1edad07c8608172f848f44c", + "size_in_bytes": 4390 + }, + { + "_path": "site-packages/pip/_vendor/pygments/formatters/__init__.py", + "path_type": "hardlink", + "sha256": "293c019a75e56a8a498500ce7a6547607b24883821baafb4f18b4feb13cd24f8", + "size_in_bytes": 5385 + }, + { + "_path": "site-packages/pip/_vendor/pygments/formatters/_mapping.py", + "path_type": "hardlink", + "sha256": "d42c37ec5b9094d69c9f144a9ad94f5f89f22e85fdfedb64a39670b1c354659e", + "size_in_bytes": 4176 + }, + { + "_path": "site-packages/pip/_vendor/pygments/lexer.py", + "path_type": "hardlink", + "sha256": "fe406b389fcd4f94e5d0854cd2b03d73c7b2b0febfcab946cc4408d1e55807e0", + "size_in_bytes": 35349 + }, + { + "_path": "site-packages/pip/_vendor/pygments/lexers/__init__.py", + "path_type": "hardlink", + "sha256": "c1b20c137e461fb6c8d41f6b34f245a964fe8a3fd102964360f52567271a2f30", + "size_in_bytes": 12115 + }, + { + "_path": "site-packages/pip/_vendor/pygments/lexers/_mapping.py", + "path_type": "hardlink", + "sha256": "978b425ccf1ef5a3c2d810fab2322bd1d793f89fb3e6d1e00b02fea757d2d0f1", + "size_in_bytes": 77602 + }, + { + "_path": "site-packages/pip/_vendor/pygments/lexers/python.py", + "path_type": "hardlink", + "sha256": "bf18e7d5c38772520a24ac68ca206c41363ae461db919b5946e290d8054229ac", + "size_in_bytes": 53853 + }, + { + "_path": "site-packages/pip/_vendor/pygments/modeline.py", + "path_type": "hardlink", + "sha256": "2b9792911f064b5af93a45d74c739c57468cffac6993d7963442005be38e2768", + "size_in_bytes": 1005 + }, + { + "_path": "site-packages/pip/_vendor/pygments/plugin.py", + "path_type": "hardlink", + "sha256": "b4fc74ac9093219f62a1180b3581b8a627c26c0c1345465d76f2f0f8d7c0936c", + "size_in_bytes": 1891 + }, + { + "_path": "site-packages/pip/_vendor/pygments/regexopt.py", + "path_type": "hardlink", + "sha256": "c1768ff468e9fe1280767202aa80e447100e40949ce2fdd7ea6731c77cfe4cdb", + "size_in_bytes": 3072 + }, + { + "_path": "site-packages/pip/_vendor/pygments/scanner.py", + "path_type": "hardlink", + "sha256": "9cd7044d1475b51ba24da1e61d24d310255814f70b7fa98366ed5ee2ef7503d1", + "size_in_bytes": 3092 + }, + { + "_path": "site-packages/pip/_vendor/pygments/sphinxext.py", + "path_type": "hardlink", + "sha256": "e71ed987d62553a212277d5d33076e89a6a76f97566672a0dccc8442cb1e3674", + "size_in_bytes": 7981 + }, + { + "_path": "site-packages/pip/_vendor/pygments/style.py", + "path_type": "hardlink", + "sha256": "3e5399aa5b274d5779f111b2e74be403671743f94fe5b1791063040539e8e830", + "size_in_bytes": 6420 + }, + { + "_path": "site-packages/pip/_vendor/pygments/styles/__init__.py", + "path_type": "hardlink", + "sha256": "c7d79b72d7f2bc2005a4c4e5309e58c7070d601ce382aeb325a2a4366efcaf83", + "size_in_bytes": 2042 + }, + { + "_path": "site-packages/pip/_vendor/pygments/styles/_mapping.py", + "path_type": "hardlink", + "sha256": "ea5a2f154136f6dcfa12c5775d8638860a3327bab524bedc7cedd43a58274bcc", + "size_in_bytes": 3312 + }, + { + "_path": "site-packages/pip/_vendor/pygments/token.py", + "path_type": "hardlink", + "sha256": "59b7561a1626fd5a2c6f40c3c56f651cd3e02135df593b10987b7a732f516dc3", + "size_in_bytes": 6226 + }, + { + "_path": "site-packages/pip/_vendor/pygments/unistring.py", + "path_type": "hardlink", + "sha256": "6a5fbfac17a646e1af8a7b2b33a6ad36c1d3989e8351bc36e2ad8ed91bb57017", + "size_in_bytes": 63208 + }, + { + "_path": "site-packages/pip/_vendor/pygments/util.py", + "path_type": "hardlink", + "sha256": "a11b52a62028e6333dba59ed92f55b81751d8805b9ee39ee60607bb7d7d8ba17", + "size_in_bytes": 10031 + }, + { + "_path": "site-packages/pip/_vendor/pyproject_hooks/LICENSE", + "path_type": "hardlink", + "sha256": "1b22b049b5267d6dfc23a67bf4a84d8ec04b9fdfb1a51d360e42b4342c8b4154", + "size_in_bytes": 1081 + }, + { + "_path": "site-packages/pip/_vendor/pyproject_hooks/__init__.py", + "path_type": "hardlink", + "sha256": "70f07f6bd2d7cf9c6fb116d7d68daac807632dab5925d43f2dce4c70d5fe5fb6", + "size_in_bytes": 691 + }, + { + "_path": "site-packages/pip/_vendor/pyproject_hooks/_impl.py", + "path_type": "hardlink", + "sha256": "8d8fab6b19e6c91c81e7baee022b6b25153311ec6e021193a6033282ac7aed9e", + "size_in_bytes": 14936 + }, + { + "_path": "site-packages/pip/_vendor/pyproject_hooks/_in_process/__init__.py", + "path_type": "hardlink", + "sha256": "30934fa5f23170ef85821c6905bc641b5ac58907fa1ce51b5785399aad07167b", + "size_in_bytes": 557 + }, + { + "_path": "site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", + "path_type": "hardlink", + "sha256": "a9c5cc866c7ffcc209ab5d201875b7980e1397c772f18cc731c7309cda0a970d", + "size_in_bytes": 12216 + }, + { + "_path": "site-packages/pip/_vendor/pyproject_hooks/py.typed", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_vendor/requests/LICENSE", + "path_type": "hardlink", + "sha256": "09e8a9bcec8067104652c168685ab0931e7868f9c8284b66f5ae6edae5f1130b", + "size_in_bytes": 10142 + }, + { + "_path": "site-packages/pip/_vendor/requests/__init__.py", + "path_type": "hardlink", + "sha256": "6faae55cfcae88b01dfacfa910f5fb21e8c99e6207d5ea42385a3f98b26b01c9", + "size_in_bytes": 5029 + }, + { + "_path": "site-packages/pip/_vendor/requests/__version__.py", + "path_type": "hardlink", + "sha256": "9d9df14f61e842310e2f8396ec2336b415adae97dc95ac6e4b3ddb4197ff99b2", + "size_in_bytes": 435 + }, + { + "_path": "site-packages/pip/_vendor/requests/_internal_utils.py", + "path_type": "hardlink", + "sha256": "f7fedf71d61f3050dfc8ae210f63ac4608868aaf240f0759706b91aa43f94758", + "size_in_bytes": 1502 + }, + { + "_path": "site-packages/pip/_vendor/requests/adapters.py", + "path_type": "hardlink", + "sha256": "55a866a438d909df0445ee057d3722f4d1d7bed20e17b76cd3a817d245997e9a", + "size_in_bytes": 26292 + }, + { + "_path": "site-packages/pip/_vendor/requests/api.py", + "path_type": "hardlink", + "sha256": "fd96fd39aeedcd5222cd32b016b3e30c463d7a3b66fce9d2444467003c46b10b", + "size_in_bytes": 6449 + }, + { + "_path": "site-packages/pip/_vendor/requests/auth.py", + "path_type": "hardlink", + "sha256": "2875df9db347d857b8add1892b7ada2f83b79f1917c9494b8b324904482e8527", + "size_in_bytes": 10170 + }, + { + "_path": "site-packages/pip/_vendor/requests/certs.py", + "path_type": "hardlink", + "sha256": "783d46d11a0c677900d25c9d930ee8a3496670aaaf0f5861cfac8e96048a9bcc", + "size_in_bytes": 442 + }, + { + "_path": "site-packages/pip/_vendor/requests/compat.py", + "path_type": "hardlink", + "sha256": "41f6e67531626738d21cc5e232b7788e809153a45a6ed43dcc870fa1568722eb", + "size_in_bytes": 1822 + }, + { + "_path": "site-packages/pip/_vendor/requests/cookies.py", + "path_type": "hardlink", + "sha256": "6cd8be8aa123e0d3d9d34fa86feac7bf392f39bccdde5129830de0ea9692dd7c", + "size_in_bytes": 18590 + }, + { + "_path": "site-packages/pip/_vendor/requests/exceptions.py", + "path_type": "hardlink", + "sha256": "7f3e67da77df6bb437d07a3d0270ae35e90ea344b7043212ed59381d095a916b", + "size_in_bytes": 4273 + }, + { + "_path": "site-packages/pip/_vendor/requests/help.py", + "path_type": "hardlink", + "sha256": "95110ef76cd4b977b4827929b6795646d355a9d27749e37049b1e0033a8c6b44", + "size_in_bytes": 3740 + }, + { + "_path": "site-packages/pip/_vendor/requests/hooks.py", + "path_type": "hardlink", + "sha256": "f5fad88402ec2c19071fbe86f8762abc0becb1296ed42d5becbebc700b3e1398", + "size_in_bytes": 734 + }, + { + "_path": "site-packages/pip/_vendor/requests/models.py", + "path_type": "hardlink", + "sha256": "b6fab91eb8b866e5b6a324181dfa19e6873af3c93c0f3b241366aee6c6560941", + "size_in_bytes": 35530 + }, + { + "_path": "site-packages/pip/_vendor/requests/packages.py", + "path_type": "hardlink", + "sha256": "fd94030894c9f123f79155ae9d2a81b1164d3f38f673558556a6ddaf4f29cf75", + "size_in_bytes": 1057 + }, + { + "_path": "site-packages/pip/_vendor/requests/sessions.py", + "path_type": "hardlink", + "sha256": "81b9a5b0d4a2f7ab088a0d26aed1f3640653fdf388593a1ef989d6eefe69b4a2", + "size_in_bytes": 30645 + }, + { + "_path": "site-packages/pip/_vendor/requests/status_codes.py", + "path_type": "hardlink", + "sha256": "889500780db96da4ddc3ee8f7c3d1e178aa1a48343251248fb268cab1b382c42", + "size_in_bytes": 4322 + }, + { + "_path": "site-packages/pip/_vendor/requests/structures.py", + "path_type": "hardlink", + "sha256": "f886e6855cf4e92fb968f499b94b6167afba0fd5ce8d1b935c739a6d8d38d573", + "size_in_bytes": 2912 + }, + { + "_path": "site-packages/pip/_vendor/requests/utils.py", + "path_type": "hardlink", + "sha256": "c69369a71392a249cb09dfe760a44cfbcd10ae1c64665b907e21f9cce50c8e2f", + "size_in_bytes": 32978 + }, + { + "_path": "site-packages/pip/_vendor/resolvelib/LICENSE", + "path_type": "hardlink", + "sha256": "f388fd38cad13112c1dc0f669bbe80e7f84541edbafb72f3030d2ca7642c3c9d", + "size_in_bytes": 751 + }, + { + "_path": "site-packages/pip/_vendor/resolvelib/__init__.py", + "path_type": "hardlink", + "sha256": "ca85fe778493bf01860a24111397090bd0ad7abebd4a0560a82971382bd23fb3", + "size_in_bytes": 541 + }, + { + "_path": "site-packages/pip/_vendor/resolvelib/providers.py", + "path_type": "hardlink", + "sha256": "a485896c874927d185b4d6edc131f421ae37563ea16021098f60ce2ee7b5e453", + "size_in_bytes": 8914 + }, + { + "_path": "site-packages/pip/_vendor/resolvelib/py.typed", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_vendor/resolvelib/reporters.py", + "path_type": "hardlink", + "sha256": "a4d25fe271712e901e2b1941522d86123d1ad888f59e2918d1469b4ca5deb13e", + "size_in_bytes": 2037 + }, + { + "_path": "site-packages/pip/_vendor/resolvelib/resolvers/__init__.py", + "path_type": "hardlink", + "sha256": "ef6f0cdc4be69cf6d55d2ec4c5796fda432ee9bef012ca0fbad11f97eb9593f2", + "size_in_bytes": 640 + }, + { + "_path": "site-packages/pip/_vendor/resolvelib/resolvers/abstract.py", + "path_type": "hardlink", + "sha256": "08d7903e7a40b9d63bee79b33a438d4a6020465cc87f4e97f97f66bd160e0e6b", + "size_in_bytes": 1543 + }, + { + "_path": "site-packages/pip/_vendor/resolvelib/resolvers/criterion.py", + "path_type": "hardlink", + "sha256": "95c9991afe6c2873a7143fd1cd9c2f9464a3d7d31e03ee6b08ca5d7f64a0c3b6", + "size_in_bytes": 1768 + }, + { + "_path": "site-packages/pip/_vendor/resolvelib/resolvers/exceptions.py", + "path_type": "hardlink", + "sha256": "967fe3690b602e545448563adbbca21c6da00fb020697cd129a12515587b7c34", + "size_in_bytes": 1768 + }, + { + "_path": "site-packages/pip/_vendor/resolvelib/resolvers/resolution.py", + "path_type": "hardlink", + "sha256": "dc9ff3916fac0f7118f8194d5e3ca59fffe78e9c87e67d146494fab95ec285e0", + "size_in_bytes": 24212 + }, + { + "_path": "site-packages/pip/_vendor/resolvelib/structs.py", + "path_type": "hardlink", + "sha256": "a6ef84262476201213af649078d3d16b4ad7863952b5f98efc6120021af7d34e", + "size_in_bytes": 6420 + }, + { + "_path": "site-packages/pip/_vendor/rich/LICENSE", + "path_type": "hardlink", + "sha256": "deed7c17a4318158190a3ea239cc879a5a50271cebb98ae7025f48fbe58dca15", + "size_in_bytes": 1056 + }, + { + "_path": "site-packages/pip/_vendor/rich/__init__.py", + "path_type": "hardlink", + "sha256": "751c6320bf926c5558d2adc88d232b7e00531eb9b52d90e02ceca0541c226197", + "size_in_bytes": 6090 + }, + { + "_path": "site-packages/pip/_vendor/rich/__main__.py", + "path_type": "hardlink", + "sha256": "7bf6950beb43cdaad6416f52b9932e0a006be8e0d5fe20cd5765a1db19313a5c", + "size_in_bytes": 7896 + }, + { + "_path": "site-packages/pip/_vendor/rich/_cell_widths.py", + "path_type": "hardlink", + "sha256": "7db99ec9eb447478f313f571da5d6e2bbb673ce84cb365f59497cedefb0a0e90", + "size_in_bytes": 10209 + }, + { + "_path": "site-packages/pip/_vendor/rich/_emoji_codes.py", + "path_type": "hardlink", + "sha256": "86ed552fd9db55da6926b5688a356c85195c4517bfbf7763bb7326776b0a65d6", + "size_in_bytes": 140235 + }, + { + "_path": "site-packages/pip/_vendor/rich/_emoji_replace.py", + "path_type": "hardlink", + "sha256": "9fe91c7adb04531d99526850adf78c35cfad79e1a1a6e490e45f153c1b32bc3a", + "size_in_bytes": 1064 + }, + { + "_path": "site-packages/pip/_vendor/rich/_export_format.py", + "path_type": "hardlink", + "sha256": "448d3ca52ae6e6d052ccf32f9db4ea6c3f5621a95a3a837977833545398bab56", + "size_in_bytes": 2128 + }, + { + "_path": "site-packages/pip/_vendor/rich/_extension.py", + "path_type": "hardlink", + "sha256": "5ede3b41a7022b062bbb38c38be80e06aef6e0945e0e3f429bdc548b97ebfb7e", + "size_in_bytes": 265 + }, + { + "_path": "site-packages/pip/_vendor/rich/_fileno.py", + "path_type": "hardlink", + "sha256": "1d66713f90b66a331b1ebcaf01066c79f9557d0a06cec28e1f3286b0b0fcca74", + "size_in_bytes": 799 + }, + { + "_path": "site-packages/pip/_vendor/rich/_inspect.py", + "path_type": "hardlink", + "sha256": "44e4f43cb0b618c5a26a559992a2488e662aec83518a34109284a89164da0222", + "size_in_bytes": 9656 + }, + { + "_path": "site-packages/pip/_vendor/rich/_log_render.py", + "path_type": "hardlink", + "sha256": "d41c88d0f035669c5963708624e2b9e218e5ab85fe073fdba088c8a8277c2a7b", + "size_in_bytes": 3225 + }, + { + "_path": "site-packages/pip/_vendor/rich/_loop.py", + "path_type": "hardlink", + "sha256": "855ffa08b7683e6d2f6b6d96a70e332aa334458b33dd36715e3d0fa12fbd7834", + "size_in_bytes": 1236 + }, + { + "_path": "site-packages/pip/_vendor/rich/_null_file.py", + "path_type": "hardlink", + "sha256": "00318aa75cadfa4ef414c295ead9ea0aa79c07ead2273a7e590b03ecb3cbfa48", + "size_in_bytes": 1394 + }, + { + "_path": "site-packages/pip/_vendor/rich/_palettes.py", + "path_type": "hardlink", + "sha256": "71d7afd4940a67426f960b95f62a478339d3767be52335050c16f422dd8fce32", + "size_in_bytes": 7063 + }, + { + "_path": "site-packages/pip/_vendor/rich/_pick.py", + "path_type": "hardlink", + "sha256": "7af0edf10378945e428b0ad421794e2429ed8ad0423ac23764b3c42005512c95", + "size_in_bytes": 423 + }, + { + "_path": "site-packages/pip/_vendor/rich/_ratio.py", + "path_type": "hardlink", + "sha256": "20eb65efcb1009866c987cb185ee3992b91bebcbbdc55cfbcc5b175490fe6f66", + "size_in_bytes": 5325 + }, + { + "_path": "site-packages/pip/_vendor/rich/_spinners.py", + "path_type": "hardlink", + "sha256": "536af5fe0ff5cd28ec8e251d00449cda200c7378b8ae2fd2f0f60fea4439cf52", + "size_in_bytes": 19919 + }, + { + "_path": "site-packages/pip/_vendor/rich/_stack.py", + "path_type": "hardlink", + "sha256": "f82f0e2bbaf19f7b0851d570c59041a5e1e12335f4788f9533731e9987da5e6d", + "size_in_bytes": 351 + }, + { + "_path": "site-packages/pip/_vendor/rich/_timer.py", + "path_type": "hardlink", + "sha256": "cde9716d3ea83c566736bc163e973592d51e013f957387ee15c4592d018bb4c2", + "size_in_bytes": 417 + }, + { + "_path": "site-packages/pip/_vendor/rich/_win32_console.py", + "path_type": "hardlink", + "sha256": "05268344833004b2139ff9b499344b3ea304e6afaab8675232e60ca587982707", + "size_in_bytes": 22755 + }, + { + "_path": "site-packages/pip/_vendor/rich/_windows.py", + "path_type": "hardlink", + "sha256": "681c1a0ff4b9e926e0a2922f6b2566a64d18dbcbb06360b905a6f5c25dc1a7e2", + "size_in_bytes": 1925 + }, + { + "_path": "site-packages/pip/_vendor/rich/_windows_renderer.py", + "path_type": "hardlink", + "sha256": "b7be192f7c6e0c23f79e64e9f691f52f92e223671a909b9045095e1c225eae59", + "size_in_bytes": 2783 + }, + { + "_path": "site-packages/pip/_vendor/rich/_wrap.py", + "path_type": "hardlink", + "sha256": "1654aca26e445f42d5900dca5b2df8c879c27cbb6a5fe6487a95ca87eef4ae97", + "size_in_bytes": 3404 + }, + { + "_path": "site-packages/pip/_vendor/rich/abc.py", + "path_type": "hardlink", + "sha256": "38df84f99a924a1799f3c56b297d8cdcf5e915b18451464f31afc07f497ee1fd", + "size_in_bytes": 890 + }, + { + "_path": "site-packages/pip/_vendor/rich/align.py", + "path_type": "hardlink", + "sha256": "760fbbb98d2e90c2cb95412c04344bbdadb6fec4202090f804ad1d9991c51ee8", + "size_in_bytes": 10324 + }, + { + "_path": "site-packages/pip/_vendor/rich/ansi.py", + "path_type": "hardlink", + "sha256": "02fb352c76d275cc8ebc339da442d952850b7018987b063be9e341a7ab85061b", + "size_in_bytes": 6921 + }, + { + "_path": "site-packages/pip/_vendor/rich/bar.py", + "path_type": "hardlink", + "sha256": "95d6d51cecca24e9df95536ebf5c52ee0e9d2d7d84df03275e474f6e9cc94dcb", + "size_in_bytes": 3263 + }, + { + "_path": "site-packages/pip/_vendor/rich/box.py", + "path_type": "hardlink", + "sha256": "9266af05cfdd9fbdcbfe0ffcbf1592c18243daecc15ce5054ed24e7e96dccdc3", + "size_in_bytes": 10686 + }, + { + "_path": "site-packages/pip/_vendor/rich/cells.py", + "path_type": "hardlink", + "sha256": "2ab4248f9f8b821082a492d23502320198e775ce1b9c4a8e1268b962e67d5026", + "size_in_bytes": 5130 + }, + { + "_path": "site-packages/pip/_vendor/rich/color.py", + "path_type": "hardlink", + "sha256": "dc74942d50e3eea4245d47455afefc24e8926737f2e72d6791c6219dadbde95d", + "size_in_bytes": 18211 + }, + { + "_path": "site-packages/pip/_vendor/rich/color_triplet.py", + "path_type": "hardlink", + "sha256": "de585091d25bbd63e82c33be0276089805a626f579765818342559f7b39168de", + "size_in_bytes": 1054 + }, + { + "_path": "site-packages/pip/_vendor/rich/columns.py", + "path_type": "hardlink", + "sha256": "1d45f429c326f5db0a362d757d36e233f876883b65f3248269573195a944ceaf", + "size_in_bytes": 7131 + }, + { + "_path": "site-packages/pip/_vendor/rich/console.py", + "path_type": "hardlink", + "sha256": "b7d6b366999131553972985505949284db26071776f880167134e5868afe135b", + "size_in_bytes": 100849 + }, + { + "_path": "site-packages/pip/_vendor/rich/constrain.py", + "path_type": "hardlink", + "sha256": "d5520fb82f0082d296adc9dc42b8c1758a80dc9556cacbba8d9a35aeb87b73b4", + "size_in_bytes": 1288 + }, + { + "_path": "site-packages/pip/_vendor/rich/containers.py", + "path_type": "hardlink", + "sha256": "73fe7a4f171e74662a0dea4704c4ee65d5088a38ad010827a31f9075ed19d6aa", + "size_in_bytes": 5502 + }, + { + "_path": "site-packages/pip/_vendor/rich/control.py", + "path_type": "hardlink", + "sha256": "1144d25052d06f163a666a3fb1d33ee4bb37db7bc81d305f37c4cfba5a9e1d46", + "size_in_bytes": 6487 + }, + { + "_path": "site-packages/pip/_vendor/rich/default_styles.py", + "path_type": "hardlink", + "sha256": "921405aaa6a80ecddba6b32a5a91f0f273b95291b60cde90b6e4dde8bcd9c187", + "size_in_bytes": 8257 + }, + { + "_path": "site-packages/pip/_vendor/rich/diagnose.py", + "path_type": "hardlink", + "sha256": "7c99754c8b519f5f601b0a2ea9383ef333d45b762a401a8696dadf3d0b351fdc", + "size_in_bytes": 1025 + }, + { + "_path": "site-packages/pip/_vendor/rich/emoji.py", + "path_type": "hardlink", + "sha256": "59de1b42e6d9752cbaf8fcab45036e307b67d959258caf6e3d93d596ed9c9b1d", + "size_in_bytes": 2367 + }, + { + "_path": "site-packages/pip/_vendor/rich/errors.py", + "path_type": "hardlink", + "sha256": "e693f729ce5de1027f734285b31adfca18e23d57bb275ccea9215b140cdc57e6", + "size_in_bytes": 642 + }, + { + "_path": "site-packages/pip/_vendor/rich/file_proxy.py", + "path_type": "hardlink", + "sha256": "4e5f531cc0d9f8f9395a6f2c23580683f5390e1bac9b10fe159d1f51b714d16d", + "size_in_bytes": 1683 + }, + { + "_path": "site-packages/pip/_vendor/rich/filesize.py", + "path_type": "hardlink", + "sha256": "fe2cfd948a5182f5bb30d49e0999cb83e1f0cdb3f81844e0e78dd6a83f1216cd", + "size_in_bytes": 2484 + }, + { + "_path": "site-packages/pip/_vendor/rich/highlighter.py", + "path_type": "hardlink", + "sha256": "1bfb27fbc0ca8ccd6c1232c6fe8738a2f9169a25295af8fc6d78b4c9e7762e76", + "size_in_bytes": 9586 + }, + { + "_path": "site-packages/pip/_vendor/rich/json.py", + "path_type": "hardlink", + "sha256": "bd512829d6b0a094630056b23f05e43013cbcbb4524ecf9fe38c124034769c9d", + "size_in_bytes": 5031 + }, + { + "_path": "site-packages/pip/_vendor/rich/jupyter.py", + "path_type": "hardlink", + "sha256": "432a0aa04ffc21d09baed8921e9f53b1348dc931d8d053b9c2113b8ce4ddf541", + "size_in_bytes": 3252 + }, + { + "_path": "site-packages/pip/_vendor/rich/layout.py", + "path_type": "hardlink", + "sha256": "6a3912140b4456ff44153705b3ec38b997dfb7b9c45e13732fb655760ad3e6b2", + "size_in_bytes": 14004 + }, + { + "_path": "site-packages/pip/_vendor/rich/live.py", + "path_type": "hardlink", + "sha256": "b45dee90000967f37665b19c96a67e8b02e822867c7f41c7533efd8c0c89aa3f", + "size_in_bytes": 15180 + }, + { + "_path": "site-packages/pip/_vendor/rich/live_render.py", + "path_type": "hardlink", + "sha256": "22dff7f58773ac19bca372cbd24686a2b3c583e05f65601cac18cb8c5a246f1e", + "size_in_bytes": 3521 + }, + { + "_path": "site-packages/pip/_vendor/rich/logging.py", + "path_type": "hardlink", + "sha256": "e4a68f3d230ff45c5c5cf05c28ce1c19dff35bbf0f3207fe61b3159ef7d2c34a", + "size_in_bytes": 12468 + }, + { + "_path": "site-packages/pip/_vendor/rich/markup.py", + "path_type": "hardlink", + "sha256": "ddeb8628fe6ce353424306928d39c9c6eb398993078f1a483345ba7c2c6b6b7f", + "size_in_bytes": 8451 + }, + { + "_path": "site-packages/pip/_vendor/rich/measure.py", + "path_type": "hardlink", + "sha256": "1e6ac8257f2c5914c76e087c33111acbff37564a8d5bfef4b3c68a3f965c608f", + "size_in_bytes": 5305 + }, + { + "_path": "site-packages/pip/_vendor/rich/padding.py", + "path_type": "hardlink", + "sha256": "295108ded3b0a3db202b560d4ae1fffccd7f8d45a62d9c11555fca98eb55cf23", + "size_in_bytes": 4908 + }, + { + "_path": "site-packages/pip/_vendor/rich/pager.py", + "path_type": "hardlink", + "sha256": "48efc44c114a6e0de7fc080ecd79b8d52bf7e98c57032237fd1f8a398dbfb927", + "size_in_bytes": 828 + }, + { + "_path": "site-packages/pip/_vendor/rich/palette.py", + "path_type": "hardlink", + "sha256": "9489ef4753830d3d9fdd464c7cbd60aeaedd63fa4374a1f0e1b75480e19a3386", + "size_in_bytes": 3396 + }, + { + "_path": "site-packages/pip/_vendor/rich/panel.py", + "path_type": "hardlink", + "sha256": "f6c425d3484f22a1f91b68002d0a3835ea45c293f493dc13facfe03a6b39a487", + "size_in_bytes": 11157 + }, + { + "_path": "site-packages/pip/_vendor/rich/pretty.py", + "path_type": "hardlink", + "sha256": "832dd2ef6bb8151836cada28ecdd590d60c8bc1e2e9dbcdde625067609bef1f7", + "size_in_bytes": 36391 + }, + { + "_path": "site-packages/pip/_vendor/rich/progress.py", + "path_type": "hardlink", + "sha256": "09473696453e5f9f6655d19f8cc0819197a218f2f7bb174e36384d245d93ef06", + "size_in_bytes": 60408 + }, + { + "_path": "site-packages/pip/_vendor/rich/progress_bar.py", + "path_type": "hardlink", + "sha256": "9994cfa4953071f71d8100934f3de4c98f9f73bf5d74bc2dc7a1a18717e8d3ae", + "size_in_bytes": 8162 + }, + { + "_path": "site-packages/pip/_vendor/rich/prompt.py", + "path_type": "hardlink", + "sha256": "974461414fb45154d5f5ed3cc56d416c88f426ad885f20a15f8942d2514dcede", + "size_in_bytes": 12447 + }, + { + "_path": "site-packages/pip/_vendor/rich/protocol.py", + "path_type": "hardlink", + "sha256": "e611c70c3347724764f22587e7311b8becee215485e616d4da3228e3b47b9531", + "size_in_bytes": 1391 + }, + { + "_path": "site-packages/pip/_vendor/rich/py.typed", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_vendor/rich/region.py", + "path_type": "hardlink", + "sha256": "acd4fdc59ad56536085d90b43589f8d42250c1835b47e29e70f3b14e042f07c6", + "size_in_bytes": 166 + }, + { + "_path": "site-packages/pip/_vendor/rich/repr.py", + "path_type": "hardlink", + "sha256": "e4c64966638d802ea4b9df905befe6d68917c0bd9a47abbacbea54714089cf6f", + "size_in_bytes": 4431 + }, + { + "_path": "site-packages/pip/_vendor/rich/rule.py", + "path_type": "hardlink", + "sha256": "d1f35a4bf68445add43117374f958ca4dfecba6b43c5f6a8af6cb7a1fd5fb419", + "size_in_bytes": 4602 + }, + { + "_path": "site-packages/pip/_vendor/rich/scope.py", + "path_type": "hardlink", + "sha256": "4cc514f2aa35eed872a9008faa30cb62983f514d64e6a55df96c2226f9c955ab", + "size_in_bytes": 2843 + }, + { + "_path": "site-packages/pip/_vendor/rich/screen.py", + "path_type": "hardlink", + "sha256": "628791784494871ef882ba9bd264926fd960861cac5a6147621b1b3154235cef", + "size_in_bytes": 1591 + }, + { + "_path": "site-packages/pip/_vendor/rich/segment.py", + "path_type": "hardlink", + "sha256": "a2d9ca78a18457e591950568b1f2557850dc0f100a1e9bc9fe12f34aee65ba63", + "size_in_bytes": 24743 + }, + { + "_path": "site-packages/pip/_vendor/rich/spinner.py", + "path_type": "hardlink", + "sha256": "a27221a4a9658d11e9a5365ab313bc91782d632087524a5280a825449de8e758", + "size_in_bytes": 4214 + }, + { + "_path": "site-packages/pip/_vendor/rich/status.py", + "path_type": "hardlink", + "sha256": "9243e987761e019068f97fb8c0fa7c813a99c94e3ae8d2f06410383d94d37b0a", + "size_in_bytes": 4424 + }, + { + "_path": "site-packages/pip/_vendor/rich/style.py", + "path_type": "hardlink", + "sha256": "5bd09ccbc3f2f253480ad95f729fabcb3313b90686c405376afefe8397c7bb4b", + "size_in_bytes": 26990 + }, + { + "_path": "site-packages/pip/_vendor/rich/styled.py", + "path_type": "hardlink", + "sha256": "799367cc6ac8e248bfe78a606373a3d13fb1de5c5d5d3621e3faf20c1db8c015", + "size_in_bytes": 1258 + }, + { + "_path": "site-packages/pip/_vendor/rich/syntax.py", + "path_type": "hardlink", + "sha256": "78328847097ef9e6742f0a3675ad9146d7eeb5719abeb24eeb50a5e4e912e7d5", + "size_in_bytes": 36371 + }, + { + "_path": "site-packages/pip/_vendor/rich/table.py", + "path_type": "hardlink", + "sha256": "6664fb57b30c08e60ac3b4c663d4992f26037fa25d33e5957f4ec5755b958532", + "size_in_bytes": 40049 + }, + { + "_path": "site-packages/pip/_vendor/rich/terminal_theme.py", + "path_type": "hardlink", + "sha256": "d63e7eb9f25f9ef940a3942c8bf0026625c39b0317cea826141c8e6d3f7ec896", + "size_in_bytes": 3370 + }, + { + "_path": "site-packages/pip/_vendor/rich/text.py", + "path_type": "hardlink", + "sha256": "00eec93c2cfafa068dd6d8552d73019ed1260cf55816014d1b5a0ceb5fec6a75", + "size_in_bytes": 47552 + }, + { + "_path": "site-packages/pip/_vendor/rich/theme.py", + "path_type": "hardlink", + "sha256": "a0dca15e119a82d0e56c3c9eded56eddeb16396934bcd92ec45c3efee9e568ad", + "size_in_bytes": 3771 + }, + { + "_path": "site-packages/pip/_vendor/rich/themes.py", + "path_type": "hardlink", + "sha256": "d318132e8cdf69b79b62d709b43742e50917e4855411abe2a83509261e185459", + "size_in_bytes": 102 + }, + { + "_path": "site-packages/pip/_vendor/rich/traceback.py", + "path_type": "hardlink", + "sha256": "7345a607f2f4e3f51f65b2daa07f7cdbf53fb3b7a8b3128c5220159833dd4585", + "size_in_bytes": 35861 + }, + { + "_path": "site-packages/pip/_vendor/rich/tree.py", + "path_type": "hardlink", + "sha256": "c969d0eab02f446277a991aa06bc52d925b64ca05336b3f449d63c4313853eec", + "size_in_bytes": 9451 + }, + { + "_path": "site-packages/pip/_vendor/tomli/LICENSE", + "path_type": "hardlink", + "sha256": "b80816b0d530b8accb4c2211783790984a6e3b61922c2b5ee92f3372ab2742fe", + "size_in_bytes": 1072 + }, + { + "_path": "site-packages/pip/_vendor/tomli/__init__.py", + "path_type": "hardlink", + "sha256": "aacd12e34a097e45c84249dc7586733fcc587f4a5425bd7cd31192de340f5ed7", + "size_in_bytes": 314 + }, + { + "_path": "site-packages/pip/_vendor/tomli/_parser.py", + "path_type": "hardlink", + "sha256": "dc5162e65002cfd79fe268d8296e12c38f1ed7986f76000e204bc500d51c7edf", + "size_in_bytes": 26232 + }, + { + "_path": "site-packages/pip/_vendor/tomli/_re.py", + "path_type": "hardlink", + "sha256": "9fcf88a3c64ad54f85ea3ce583b3da6dce3484b149b1ac04dae34b287f70ee25", + "size_in_bytes": 3235 + }, + { + "_path": "site-packages/pip/_vendor/tomli/_types.py", + "path_type": "hardlink", + "sha256": "f864c6d9552a929c7032ace654ee05ef26ca75d21b027b801d77e65907138b74", + "size_in_bytes": 254 + }, + { + "_path": "site-packages/pip/_vendor/tomli/py.typed", + "path_type": "hardlink", + "sha256": "f0f8f2675695a10a5156fb7bd66bafbaae6a13e8d315990af862c792175e6e67", + "size_in_bytes": 26 + }, + { + "_path": "site-packages/pip/_vendor/tomli_w/LICENSE", + "path_type": "hardlink", + "sha256": "b80816b0d530b8accb4c2211783790984a6e3b61922c2b5ee92f3372ab2742fe", + "size_in_bytes": 1072 + }, + { + "_path": "site-packages/pip/_vendor/tomli_w/__init__.py", + "path_type": "hardlink", + "sha256": "d05f320ed5f1dd4ba7866f3be0aac070fefab2bb0cf7ccbb5b21d0c02ba565ba", + "size_in_bytes": 169 + }, + { + "_path": "site-packages/pip/_vendor/tomli_w/_writer.py", + "path_type": "hardlink", + "sha256": "76c89f152db161fd62efa9a64727f3f72d76e710bb67f1d0f38e592a126c617b", + "size_in_bytes": 6961 + }, + { + "_path": "site-packages/pip/_vendor/tomli_w/py.typed", + "path_type": "hardlink", + "sha256": "f0f8f2675695a10a5156fb7bd66bafbaae6a13e8d315990af862c792175e6e67", + "size_in_bytes": 26 + }, + { + "_path": "site-packages/pip/_vendor/truststore/LICENSE", + "path_type": "hardlink", + "sha256": "33be7b7e8fa4fd19b1760e1a8ed8a668bdab852c91b692dd41424bcb725a9fca", + "size_in_bytes": 1086 + }, + { + "_path": "site-packages/pip/_vendor/truststore/__init__.py", + "path_type": "hardlink", + "sha256": "06eee4aa49a9ba784bb23e710aef204ffdb992da0f5dc4a7c1ef151e4d46989a", + "size_in_bytes": 1320 + }, + { + "_path": "site-packages/pip/_vendor/truststore/_api.py", + "path_type": "hardlink", + "sha256": "0982425790537edb5961fa98de6a2f74c044fbc6b3eee8444ff2d86ca4f6367e", + "size_in_bytes": 11413 + }, + { + "_path": "site-packages/pip/_vendor/truststore/_macos.py", + "path_type": "hardlink", + "sha256": "9d994b90e9accd413483aaf2470055198e423b33f2b9d72c889b4359aacce4b4", + "size_in_bytes": 20503 + }, + { + "_path": "site-packages/pip/_vendor/truststore/_openssl.py", + "path_type": "hardlink", + "sha256": "cc1f9242f272764b3bb50d32230acfe860f77d035249a3e2abbcf0e321794f8d", + "size_in_bytes": 2412 + }, + { + "_path": "site-packages/pip/_vendor/truststore/_ssl_constants.py", + "path_type": "hardlink", + "sha256": "3540f87d529d483d36ae2efe75bd2d9ced15a8b3fd687bb3992b5c5bbb40974f", + "size_in_bytes": 1130 + }, + { + "_path": "site-packages/pip/_vendor/truststore/_windows.py", + "path_type": "hardlink", + "sha256": "ac01f22980fc33bb7e6d77c6f1580e55add3a5f85585bb78ad94253b8e58b8ff", + "size_in_bytes": 17993 + }, + { + "_path": "site-packages/pip/_vendor/truststore/py.typed", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/LICENSE.txt", + "path_type": "hardlink", + "sha256": "130e3a64d5fdd5d096a752694634a7d9df284469de86e5732100268041e3d686", + "size_in_bytes": 1093 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/__init__.py", + "path_type": "hardlink", + "sha256": "24ca35b60d67215d40789daf10d0bf4f17e5d1ee61e86ce5f43195935ad645ba", + "size_in_bytes": 6979 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/_base_connection.py", + "path_type": "hardlink", + "sha256": "4f57301f7461cecac187a073dc03865436e846c13bbde8a3a993d75d04d1d918", + "size_in_bytes": 5568 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/_collections.py", + "path_type": "hardlink", + "sha256": "52f57b52ab464d229dbf0f0dfcbc56b848a464b9b9801d7315f4d9607f4a8409", + "size_in_bytes": 17595 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/_request_methods.py", + "path_type": "hardlink", + "sha256": "802785f3948efd45385a83f0607228cffb70f9e33f1153a42c5a7c385b02ec30", + "size_in_bytes": 9931 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/_version.py", + "path_type": "hardlink", + "sha256": "bca13ca2bd269aa82c16955bec5626b3e9cd39508f3c01227e0c55ad368f072c", + "size_in_bytes": 704 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/connection.py", + "path_type": "hardlink", + "sha256": "d5947682a7c5748cd36085301742b99dfb60dba84ba94e67af5c874dd29bed60", + "size_in_bytes": 42800 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/connectionpool.py", + "path_type": "hardlink", + "sha256": "64486e76c6bc048b9b0f63345e8c4106c8f16ec5f0320512707ee843d8be8f56", + "size_in_bytes": 43371 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/contrib/__init__.py", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/contrib/emscripten/__init__.py", + "path_type": "hardlink", + "sha256": "66bb97696295cc010976a347dcd121d26ac7af0fbed956586f4cd7d11a273590", + "size_in_bytes": 870 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/contrib/emscripten/connection.py", + "path_type": "hardlink", + "sha256": "822125b01a14b0a55445b6736fc182ac99aa5b6dd79ef8f668dc90545e36b258", + "size_in_bytes": 8960 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/contrib/emscripten/emscripten_fetch_worker.js", + "path_type": "hardlink", + "sha256": "cf5937cd9e3f84329ddfeb4def0cf3f0b1e31c2da9c4dfeebbc07793d0fd0377", + "size_in_bytes": 3677 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/contrib/emscripten/fetch.py", + "path_type": "hardlink", + "sha256": "e7171dfbebe217165dda7072d1a2bbdddb49f53b21d7261953f4945f09f089b9", + "size_in_bytes": 23520 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/contrib/emscripten/request.py", + "path_type": "hardlink", + "sha256": "98bdbcb33cb52af137349856a2be633666aba7c830a650d4fbb8301996398344", + "size_in_bytes": 566 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/contrib/emscripten/response.py", + "path_type": "hardlink", + "sha256": "ee854f10d6191eecc4191b46e341e89e91f9b402181ec19c1cf6c9b7667453e6", + "size_in_bytes": 9507 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/contrib/pyopenssl.py", + "path_type": "hardlink", + "sha256": "9d764a3281ec8b898f3f92b7ae1d0e7486f13487fc019d2615411ee3a1b691e7", + "size_in_bytes": 19750 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/contrib/socks.py", + "path_type": "hardlink", + "sha256": "781d9e59fbbc5b3d5f9feaafaffa84fdd64071e724d8d72fed7435e4396f55b5", + "size_in_bytes": 7547 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/exceptions.py", + "path_type": "hardlink", + "sha256": "79e43bee726317dedb3fa4af08ae209b1e81a5064a53cca3bccf80203c19757f", + "size_in_bytes": 9952 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/fields.py", + "path_type": "hardlink", + "sha256": "1427fb5142d291fd7472e4d15164d0112cf1825d564fc7b6682cb791fc998a7b", + "size_in_bytes": 10829 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/filepost.py", + "path_type": "hardlink", + "sha256": "53c78d67e9a928a1e1ae56c7104893c7180ad7a21e8e111aeeecf8db2a80fdd2", + "size_in_bytes": 2388 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/http2/__init__.py", + "path_type": "hardlink", + "sha256": "c73ac0487ed1e4035190f24ea2de651a70133aadca2aec97cc8e36adc9f09aab", + "size_in_bytes": 1741 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/http2/connection.py", + "path_type": "hardlink", + "sha256": "6c7307e9f36f6adc173eb2aaadc9fbe32037a5459ca8f0e9a672b52dc2826cff", + "size_in_bytes": 12578 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/http2/probe.py", + "path_type": "hardlink", + "sha256": "9e7024a9b8406a43a217be6bcfb5b4b9d677f047a1fee0fc7e357be0def71442", + "size_in_bytes": 3014 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/poolmanager.py", + "path_type": "hardlink", + "sha256": "da9903ba3b7ee824d27ab4b05df9314ef70cf7713696c3471dbe09fc07ba34d3", + "size_in_bytes": 23845 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/py.typed", + "path_type": "hardlink", + "sha256": "51a0ae3c56b71fc5006a46edfb91bc48f69c95d4ce1af26fd7ca4f8d42798036", + "size_in_bytes": 93 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/response.py", + "path_type": "hardlink", + "sha256": "7848fab57f7c669db5960442f310073dd888e5b45d1e592e2947008eb53253bf", + "size_in_bytes": 52743 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/util/__init__.py", + "path_type": "hardlink", + "sha256": "faa792d1071e8af6b3bc110a0cd142008fba00271d0ce1384ccbe8ed22cd9404", + "size_in_bytes": 1001 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/util/connection.py", + "path_type": "hardlink", + "sha256": "2633bbdb69731e5ccb5cf4e4afd65605d86c7979cc5633126f50c92d5ad74a74", + "size_in_bytes": 4444 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/util/proxy.py", + "path_type": "hardlink", + "sha256": "b1e3fcf90e41e9b07474cb703e3f98719650df4bc7b8ba91bbeb48d096767f3b", + "size_in_bytes": 1148 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/util/request.py", + "path_type": "hardlink", + "sha256": "a7d2a2f5ea35b4504efa3a95ffb2a6989eb444aaa8636af86a8d1299a1cbc8eb", + "size_in_bytes": 8086 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/util/response.py", + "path_type": "hardlink", + "sha256": "bd013adfdba81218f5be98c4771bb994d22124249466477ba6a965508d0164e0", + "size_in_bytes": 3374 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/util/retry.py", + "path_type": "hardlink", + "sha256": "58e7081d56b129ff9d55bf3d9546e9bdca5e33bacd605fefb0ab0238ac35d19f", + "size_in_bytes": 19235 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/util/ssl_.py", + "path_type": "hardlink", + "sha256": "63d44d9160887a10f1211bf21671d48e23253e8966dfaf0660cc9ad9874339a8", + "size_in_bytes": 19929 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/util/ssl_match_hostname.py", + "path_type": "hardlink", + "sha256": "0e2ec353bce892896d6a94ff1744a3db57df631c1a4bf704e5aa4eb70b9e7b20", + "size_in_bytes": 5845 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/util/ssltransport.py", + "path_type": "hardlink", + "sha256": "133e0ef2947fbd3f1d6a7fc5bea0584ba7600df05710c7d57ebcdc754a167e2e", + "size_in_bytes": 8847 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/util/timeout.py", + "path_type": "hardlink", + "sha256": "bec5094693b49df2a4fb2d4e2a5805198d4e34918f824699ec1ee4aee129558c", + "size_in_bytes": 10363 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/util/url.py", + "path_type": "hardlink", + "sha256": "3c40d0332a6276e75ed2701972d2cb8852bd7a937e2cf9d21fb2a938b2f0a87d", + "size_in_bytes": 15256 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/util/util.py", + "path_type": "hardlink", + "sha256": "8f795b64ad633f28b00f7e13f08809cdd5846554fee04fb4bd82098bd52378d0", + "size_in_bytes": 1146 + }, + { + "_path": "site-packages/pip/_vendor/urllib3/util/wait.py", + "path_type": "hardlink", + "sha256": "fe987c22b511deca8faa2d0ea29420254947e30ce419e3390a2c80ed7186b662", + "size_in_bytes": 4423 + }, + { + "_path": "site-packages/pip/_vendor/vendor.txt", + "path_type": "hardlink", + "sha256": "e7673bce58219ac86720dbadbf4927921d6c213f2363b7a930c1e01594eea302", + "size_in_bytes": 316 + }, + { + "_path": "site-packages/pip/py.typed", + "path_type": "hardlink", + "sha256": "10156fbcf4539ff788a73e5ee50ced48276b317ed0c1ded53fddd14a82256762", + "size_in_bytes": 286 + } + ], + "paths_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/repodata_record.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/repodata_record.json new file mode 100644 index 0000000000000000000000000000000000000000..56773921583403e89049ab5b69508347b8f03eb4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/info/repodata_record.json @@ -0,0 +1,26 @@ +{ + "arch": null, + "build": "pyh8b19718_0", + "build_number": 0, + "build_string": "pyh8b19718_0", + "channel": "conda-forge", + "constrains": [], + "depends": [ + "python >=3.10,<3.13.0a0", + "setuptools", + "wheel" + ], + "fn": "pip-26.1.1-pyh8b19718_0.conda", + "license": "MIT", + "license_family": "MIT", + "md5": "35870d32aed92041d31cbb15e822dca3", + "name": "pip", + "noarch": "python", + "platform": null, + "sha256": "1bd94ef1ae08fd811ef3b26857e46ba460c7430bf1f3ccd94a4d6614fd619bd5", + "size": 1201616, + "subdir": "noarch", + "timestamp": 1777924080, + "url": "https://conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0.conda", + "version": "26.1.1" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/INSTALLER b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/INSTALLER new file mode 100644 index 0000000000000000000000000000000000000000..f79e4cb9aaf0b2d9e8ba78861e2071317b2384b3 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/INSTALLER @@ -0,0 +1 @@ +conda \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/METADATA b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/METADATA new file mode 100644 index 0000000000000000000000000000000000000000..f591474d6c25ff68d14b9b990f46912cc4ae056e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/METADATA @@ -0,0 +1,109 @@ +Metadata-Version: 2.4 +Name: pip +Version: 26.1.1 +Summary: The PyPA recommended tool for installing Python packages. +Author-email: The pip developers +Requires-Python: >=3.10 +Description-Content-Type: text/x-rst +License-Expression: MIT +Classifier: Development Status :: 5 - Production/Stable +Classifier: Intended Audience :: Developers +Classifier: Topic :: Software Development :: Build Tools +Classifier: Programming Language :: Python +Classifier: Programming Language :: Python :: 3 +Classifier: Programming Language :: Python :: 3 :: Only +Classifier: Programming Language :: Python :: 3.10 +Classifier: Programming Language :: Python :: 3.11 +Classifier: Programming Language :: Python :: 3.12 +Classifier: Programming Language :: Python :: 3.13 +Classifier: Programming Language :: Python :: 3.14 +Classifier: Programming Language :: Python :: Implementation :: CPython +Classifier: Programming Language :: Python :: Implementation :: PyPy +License-File: AUTHORS.txt +License-File: LICENSE.txt +License-File: src/pip/_vendor/cachecontrol/LICENSE.txt +License-File: src/pip/_vendor/certifi/LICENSE +License-File: src/pip/_vendor/distlib/LICENSE.txt +License-File: src/pip/_vendor/distro/LICENSE +License-File: src/pip/_vendor/idna/LICENSE.md +License-File: src/pip/_vendor/msgpack/COPYING +License-File: src/pip/_vendor/packaging/LICENSE +License-File: src/pip/_vendor/packaging/LICENSE.APACHE +License-File: src/pip/_vendor/packaging/LICENSE.BSD +License-File: src/pip/_vendor/pkg_resources/LICENSE +License-File: src/pip/_vendor/platformdirs/LICENSE +License-File: src/pip/_vendor/pygments/LICENSE +License-File: src/pip/_vendor/pyproject_hooks/LICENSE +License-File: src/pip/_vendor/requests/LICENSE +License-File: src/pip/_vendor/resolvelib/LICENSE +License-File: src/pip/_vendor/rich/LICENSE +License-File: src/pip/_vendor/tomli/LICENSE +License-File: src/pip/_vendor/tomli_w/LICENSE +License-File: src/pip/_vendor/truststore/LICENSE +License-File: src/pip/_vendor/urllib3/LICENSE.txt +Project-URL: Changelog, https://pip.pypa.io/en/stable/news/ +Project-URL: Documentation, https://pip.pypa.io +Project-URL: Homepage, https://pip.pypa.io/ +Project-URL: Source, https://github.com/pypa/pip + +pip - The Python Package Installer +================================== + +.. |pypi-version| image:: https://img.shields.io/pypi/v/pip.svg + :target: https://pypi.org/project/pip/ + :alt: PyPI + +.. |python-versions| image:: https://img.shields.io/pypi/pyversions/pip + :target: https://pypi.org/project/pip + :alt: PyPI - Python Version + +.. |docs-badge| image:: https://readthedocs.org/projects/pip/badge/?version=latest + :target: https://pip.pypa.io/en/latest + :alt: Documentation + +|pypi-version| |python-versions| |docs-badge| + +pip is the `package installer`_ for Python. You can use pip to install packages from the `Python Package Index`_ and other indexes. + +Please take a look at our documentation for how to install and use pip: + +* `Installation`_ +* `Usage`_ + +We release updates regularly, with a new version every 3 months. Find more details in our documentation: + +* `Release notes`_ +* `Release process`_ + +If you find bugs, need help, or want to talk to the developers, please use our mailing lists or chat rooms: + +* `Issue tracking`_ +* `Discourse channel`_ +* `User IRC`_ + +If you want to get involved, head over to GitHub to get the source code, look at our development documentation and feel free to jump on the developer mailing lists and chat rooms: + +* `GitHub page`_ +* `Development documentation`_ +* `Development IRC`_ + +Code of Conduct +--------------- + +Everyone interacting in the pip project's codebases, issue trackers, chat +rooms, and mailing lists is expected to follow the `PSF Code of Conduct`_. + +.. _package installer: https://packaging.python.org/guides/tool-recommendations/ +.. _Python Package Index: https://pypi.org +.. _Installation: https://pip.pypa.io/en/stable/installation/ +.. _Usage: https://pip.pypa.io/en/stable/ +.. _Release notes: https://pip.pypa.io/en/stable/news.html +.. _Release process: https://pip.pypa.io/en/latest/development/release-process/ +.. _GitHub page: https://github.com/pypa/pip +.. _Development documentation: https://pip.pypa.io/en/latest/development +.. _Issue tracking: https://github.com/pypa/pip/issues +.. _Discourse channel: https://discuss.python.org/c/packaging +.. _User IRC: https://kiwiirc.com/nextclient/#ircs://irc.libera.chat:+6697/pypa +.. _Development IRC: https://kiwiirc.com/nextclient/#ircs://irc.libera.chat:+6697/pypa-dev +.. _PSF Code of Conduct: https://github.com/pypa/.github/blob/main/CODE_OF_CONDUCT.md + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/RECORD b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/RECORD new file mode 100644 index 0000000000000000000000000000000000000000..d3c44c219464e32c8b9ad2b9ac85189e88e7e3c6 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/RECORD @@ -0,0 +1,866 @@ +../../../bin/pip,sha256=jcrTAfiJHhhSWpU5AOpV6lUqNtGjmITeEbp0ENYkUM4,452 +../../../bin/pip3,sha256=jcrTAfiJHhhSWpU5AOpV6lUqNtGjmITeEbp0ENYkUM4,452 +../../../bin/pip3.12,sha256=jcrTAfiJHhhSWpU5AOpV6lUqNtGjmITeEbp0ENYkUM4,452 +pip-26.1.1.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +pip-26.1.1.dist-info/METADATA,sha256=2g9CrQU5mpjv7Pv68xdtKRIPZxJCVQH36zTG9s3xqtk,4566 +pip-26.1.1.dist-info/RECORD,, +pip-26.1.1.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip-26.1.1.dist-info/WHEEL,sha256=G2gURzTEtmeR8nrdXUJfNiB3VYVxigPQ-bEQujpNiNs,82 +pip-26.1.1.dist-info/direct_url.json,sha256=Za0119dt-5F9RyQKE37mfohhyBQgZm7QsgWCXCWbIbw,99 +pip-26.1.1.dist-info/entry_points.txt,sha256=Vhf8s0IYgX37mtd4vGL73BPcxdKnqeCFPzB5-d30x8o,84 +pip-26.1.1.dist-info/licenses/AUTHORS.txt,sha256=sE0bcE_9PMRlDzzb-q8bjfhKXYTEQm3IxLLMDr2nfJM,11852 +pip-26.1.1.dist-info/licenses/LICENSE.txt,sha256=Y0MApmnUmurmWxLGxIySTFGkzfPR_whtw0VtyLyqIQQ,1093 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/cachecontrol/LICENSE.txt,sha256=hu7uh74qQ_P_H1ZJb0UfaSQ5JvAl_tuwM2ZsMExMFhs,558 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/certifi/LICENSE,sha256=6TcW2mucDVpKHfYP5pWzcPBpVgPSH2-D8FPkLPwQyvc,989 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/distlib/LICENSE.txt,sha256=gI4QyKarjesUn_mz-xn0R6gICUYG1xKpylf-rTVSWZ0,14531 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/distro/LICENSE,sha256=y16Ofl9KOYjhBjwULGDcLfdWBfTEZRXnduOspt-XbhQ,11325 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/idna/LICENSE.md,sha256=t6M2q_OwThgOwGXN0W5wXQeeHMehT5EKpukYfza5zYc,1541 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/msgpack/COPYING,sha256=SS3tuoXaWHL3jmCRvNH-pHTWYNNay03ulkuKqz8AdCc,614 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE,sha256=ytHvW9NA1z4HS6YU0m996spceUDD2MNIUuZcSQlobEg,197 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE.APACHE,sha256=DVQuDIgE45qn836wDaWnYhSdxoLXgpRRKH4RuTjpRZQ,10174 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE.BSD,sha256=tw5-m3QvHMb5SLNMFqo5_-zpQZY2S8iP8NIYDwAo-sU,1344 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/pkg_resources/LICENSE,sha256=htoPAa6uRjSKPD1GUZXcHOzN55956HdppkuNoEsqR0E,1023 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/platformdirs/LICENSE,sha256=KeD9YukphQ6G6yjD_czwzv30-pSHkBHP-z0NS-1tTbY,1089 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/pygments/LICENSE,sha256=qdZvHVJt8C4p3Oc0NtNOVuhjL0bCdbvf_HBWnogvnxc,1331 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/pyproject_hooks/LICENSE,sha256=GyKwSbUmfW38I6Z79KhNjsBLn9-xpR02DkK0NCyLQVQ,1081 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/requests/LICENSE,sha256=CeipvOyAZxBGUsFoaFqwkx54aPnIKEtm9a5u2uXxEws,10142 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/resolvelib/LICENSE,sha256=84j9OMrRMRLB3A9mm76A5_hFQe26-3LzAw0sp2QsPJ0,751 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/rich/LICENSE,sha256=3u18F6QxgVgZCj6iOcyHmlpQJxzruYrnAl9I--WNyhU,1056 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/tomli/LICENSE,sha256=uAgWsNUwuKzLTCIReDeQmEpuO2GSLCte6S8zcqsnQv4,1072 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/tomli_w/LICENSE,sha256=uAgWsNUwuKzLTCIReDeQmEpuO2GSLCte6S8zcqsnQv4,1072 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/truststore/LICENSE,sha256=M757fo-k_Rmxdg4ajtimaL2rhSyRtpLdQUJLy3Jan8o,1086 +pip-26.1.1.dist-info/licenses/src/pip/_vendor/urllib3/LICENSE.txt,sha256=Ew46ZNX91dCWp1JpRjSn2d8oRGnehuVzIQAmgEHj1oY,1093 +pip/__init__.py,sha256=D-SKDnJXnZSVdwb4PTrC_Udxb3L0zdsgGQnAvhc1JqI,355 +pip/__main__.py,sha256=rOZRtrXjDBzY24niaxTnd9ZHHWL7B0EawVdLoJ3nI6c,874 +pip/__pip-runner__.py,sha256=720Mt6h07Uce52v80EOF__JYauoLw9b7Pfs_5B91isg,1451 +pip/__pycache__/__init__.cpython-312.pyc,, +pip/__pycache__/__main__.cpython-312.pyc,, +pip/__pycache__/__pip-runner__.cpython-312.pyc,, +pip/_internal/__init__.py,sha256=S7i9Dn9aSZS0MG-2Wrve3dV9TImPzvQn5jjhp9t_uf0,511 +pip/_internal/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/__pycache__/build_env.cpython-312.pyc,, +pip/_internal/__pycache__/cache.cpython-312.pyc,, +pip/_internal/__pycache__/configuration.cpython-312.pyc,, +pip/_internal/__pycache__/exceptions.cpython-312.pyc,, +pip/_internal/__pycache__/main.cpython-312.pyc,, +pip/_internal/__pycache__/pyproject.cpython-312.pyc,, +pip/_internal/__pycache__/self_outdated_check.cpython-312.pyc,, +pip/_internal/__pycache__/wheel_builder.cpython-312.pyc,, +pip/_internal/build_env.py,sha256=XpgOIlTQLgz3PvDT2n7j2NzX_rVFZLCIG7t7b2ddhcM,21911 +pip/_internal/cache.py,sha256=nMh48Yv3yu1HS1yCdscouu6B6B5zYBWdV6bhqs7gL-E,10345 +pip/_internal/cli/__init__.py,sha256=Iqg_tKA771XuMO1P4t_sDHnSKPzkUb9D0DqunAmw_ko,131 +pip/_internal/cli/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/cli/__pycache__/autocompletion.cpython-312.pyc,, +pip/_internal/cli/__pycache__/base_command.cpython-312.pyc,, +pip/_internal/cli/__pycache__/cmdoptions.cpython-312.pyc,, +pip/_internal/cli/__pycache__/command_context.cpython-312.pyc,, +pip/_internal/cli/__pycache__/index_command.cpython-312.pyc,, +pip/_internal/cli/__pycache__/main.cpython-312.pyc,, +pip/_internal/cli/__pycache__/main_parser.cpython-312.pyc,, +pip/_internal/cli/__pycache__/parser.cpython-312.pyc,, +pip/_internal/cli/__pycache__/progress_bars.cpython-312.pyc,, +pip/_internal/cli/__pycache__/req_command.cpython-312.pyc,, +pip/_internal/cli/__pycache__/spinners.cpython-312.pyc,, +pip/_internal/cli/__pycache__/status_codes.cpython-312.pyc,, +pip/_internal/cli/autocompletion.py,sha256=ZG2cM03nlcNrs-WG_SFTW46isx9s2Go5lUD_8-iv70o,7193 +pip/_internal/cli/base_command.py,sha256=-oJs5lKaPD2RXBuByBfKvumAa1XNYVthv0Pm0RXwGgA,9579 +pip/_internal/cli/cmdoptions.py,sha256=xbTSw40piYzeuhqdG4cWtxmPthh1ye0aGz0fyqiNMG8,37592 +pip/_internal/cli/command_context.py,sha256=kmu3EWZbfBega1oDamnGJTA_UaejhIQNuMj2CVmMXu0,817 +pip/_internal/cli/index_command.py,sha256=PTcKSd-J3bUalzDO9kNvZ3mEGiJXix32Q4fPwkxSXIc,7094 +pip/_internal/cli/main.py,sha256=ljDQBkvBtC8xTjOdb6rDJzJUNi1s-PnVR_W5C-Mq0Dk,3137 +pip/_internal/cli/main_parser.py,sha256=YjzJAjqf78ARNsLlnJT9l6fNbpyDPJA-arOIXYsK5Ik,4403 +pip/_internal/cli/parser.py,sha256=EIFExrWX_1nrl1Ib--GOor70WYqLtduHByenb1u9xH4,13827 +pip/_internal/cli/progress_bars.py,sha256=IW1PH5n2FPqUBTP7ULQ5Yu-wyNNO9XGY3g1PT4RMu44,4706 +pip/_internal/cli/req_command.py,sha256=KmCppnkf7M6SvJIVrds0ng83HFMZ2z4Y6pg1yCnyjDM,17484 +pip/_internal/cli/spinners.py,sha256=EJzZIZNyUtJljp3-WjcsyIrqxW-HUsfWzhuW84n_Tqw,7362 +pip/_internal/cli/status_codes.py,sha256=sEFHUaUJbqv8iArL3HAtcztWZmGOFX01hTesSytDEh0,116 +pip/_internal/commands/__init__.py,sha256=aNeCbQurGWihfhQq7BqaLXHqWDQ0i3I04OS7kxK6plQ,4026 +pip/_internal/commands/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/commands/__pycache__/cache.cpython-312.pyc,, +pip/_internal/commands/__pycache__/check.cpython-312.pyc,, +pip/_internal/commands/__pycache__/completion.cpython-312.pyc,, +pip/_internal/commands/__pycache__/configuration.cpython-312.pyc,, +pip/_internal/commands/__pycache__/debug.cpython-312.pyc,, +pip/_internal/commands/__pycache__/download.cpython-312.pyc,, +pip/_internal/commands/__pycache__/freeze.cpython-312.pyc,, +pip/_internal/commands/__pycache__/hash.cpython-312.pyc,, +pip/_internal/commands/__pycache__/help.cpython-312.pyc,, +pip/_internal/commands/__pycache__/index.cpython-312.pyc,, +pip/_internal/commands/__pycache__/inspect.cpython-312.pyc,, +pip/_internal/commands/__pycache__/install.cpython-312.pyc,, +pip/_internal/commands/__pycache__/list.cpython-312.pyc,, +pip/_internal/commands/__pycache__/lock.cpython-312.pyc,, +pip/_internal/commands/__pycache__/search.cpython-312.pyc,, +pip/_internal/commands/__pycache__/show.cpython-312.pyc,, +pip/_internal/commands/__pycache__/uninstall.cpython-312.pyc,, +pip/_internal/commands/__pycache__/wheel.cpython-312.pyc,, +pip/_internal/commands/cache.py,sha256=XjT7kjY8GSISMksFHsLvjS9Ogfi5extNlUUv-dUoWCM,9142 +pip/_internal/commands/check.py,sha256=hVFBQezQ3zj4EydoWbFQj_afPUppMt7r9JPAlY22U6Y,2244 +pip/_internal/commands/completion.py,sha256=LjvRIZ6QUiDXJL3IOMFeD-_J97HfjMGgEk0j2tWGu1U,4565 +pip/_internal/commands/configuration.py,sha256=6gNOGrVWnOLU15zUnAiNuOMhf76RRIZvCdVD0degPRk,10105 +pip/_internal/commands/debug.py,sha256=EvBLsRjcTRMrOuyHkLlJS6XODLBbasNlvVzce7cbRvo,6543 +pip/_internal/commands/download.py,sha256=LUNVobuvCdagjLBuPBaxHeBiHEiIe03fTO2m6ahC8qw,5178 +pip/_internal/commands/freeze.py,sha256=fxoW8AAc-bAqB_fXdNq2VnZ3JfWkFMg-bR6LcdDVO7A,3099 +pip/_internal/commands/hash.py,sha256=GO9pRN3wXC2kQaovK57TaLYBMc3IltOH92O6QEw6YE0,1679 +pip/_internal/commands/help.py,sha256=Bz3LcjNQXkz4Cu__pL4CZ86o4-HNLZj1NZWdlJhjuu0,1108 +pip/_internal/commands/index.py,sha256=ZhvgaAu6mkyts25L33mdBw8dfi50rTNJOYLO8GNgM7Y,5514 +pip/_internal/commands/inspect.py,sha256=Lmy7-WHZ7juHp-txjK7U74X3jr5cfvgOMDICyKitriM,3184 +pip/_internal/commands/install.py,sha256=wwtHYQ3UoDxXcMysjTRnbWO8Zeg_C-_Nk9SgMfDHAgo,33733 +pip/_internal/commands/list.py,sha256=7_YwtPHN-RbWPHhCp1hajXN_zNxR9UdsHGUuVJzAVNQ,13638 +pip/_internal/commands/lock.py,sha256=145ihjUK_-7gP8O65XPDi_xMhlh5hne1ptkHdfnbAnQ,6027 +pip/_internal/commands/search.py,sha256=zbMsX_YASj6kXA6XIBgTDv0bGK51xG-CV3IynZJcE-c,5782 +pip/_internal/commands/show.py,sha256=oLVJIfKWmDKm0SsQGEi3pozNiqrXjTras_fbBSYKpBA,8066 +pip/_internal/commands/uninstall.py,sha256=CsOihqvb6ZA6O67L70oXeoLHeOfNzMM88H9g-9aocgw,3868 +pip/_internal/commands/wheel.py,sha256=L9vEzJ_E42scF_Hgh5X4Hk39nqJDKxGg4u7glDYbNWc,5880 +pip/_internal/configuration.py,sha256=WxwwSwY_Bm6QzDgf32BsujEyO8dgRedegCpgbUfDvM8,14568 +pip/_internal/distributions/__init__.py,sha256=Hq6kt6gXBgjNit5hTTWLAzeCNOKoB-N0pGYSqehrli8,858 +pip/_internal/distributions/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/distributions/__pycache__/base.cpython-312.pyc,, +pip/_internal/distributions/__pycache__/installed.cpython-312.pyc,, +pip/_internal/distributions/__pycache__/sdist.cpython-312.pyc,, +pip/_internal/distributions/__pycache__/wheel.cpython-312.pyc,, +pip/_internal/distributions/base.py,sha256=l-OTCAIs25lsapejA6IYpPZxSM5-BET4sdZDkql8jiY,1830 +pip/_internal/distributions/installed.py,sha256=kgIEE_1NzjZxLBSC-v5s64uOFZlVEt3aPrjTtL6x2XY,929 +pip/_internal/distributions/sdist.py,sha256=RYwQIbuxpKy6OjlBZCAefxpMDaoocUQ4dFtheGsiTOQ,6627 +pip/_internal/distributions/wheel.py,sha256=_HbG0OehF8dwj4UX-xV__tXLwgPus9OjMEf2NTRqBbE,1364 +pip/_internal/exceptions.py,sha256=PXzGfBmUF3rKQQjCAMcJ1fszBw6naL1nTK8CXhIi7zo,32166 +pip/_internal/index/__init__.py,sha256=tzwMH_fhQeubwMqHdSivasg1cRgTSbNg2CiMVnzMmyU,29 +pip/_internal/index/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/index/__pycache__/collector.cpython-312.pyc,, +pip/_internal/index/__pycache__/package_finder.cpython-312.pyc,, +pip/_internal/index/__pycache__/sources.cpython-312.pyc,, +pip/_internal/index/collector.py,sha256=R7Gcx_4GEoSEI-iazfAZVEPG3Lp6mbZT4lbAD6NjAc0,16144 +pip/_internal/index/package_finder.py,sha256=fX9lRlfiUkoC96rIiYg4M_bDWVNUpaX2TzXx_FP-aoI,41347 +pip/_internal/index/sources.py,sha256=nXJkOjhLy-O2FsrKU9RIqCOqgY2PsoKWybtZjjRgqU0,8639 +pip/_internal/locations/__init__.py,sha256=iP9yVZn_4iPuNcaUNh2A_vJLcvUZ-8y4zvKLDVEqaM0,14022 +pip/_internal/locations/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/locations/__pycache__/_distutils.cpython-312.pyc,, +pip/_internal/locations/__pycache__/_sysconfig.cpython-312.pyc,, +pip/_internal/locations/__pycache__/base.cpython-312.pyc,, +pip/_internal/locations/_distutils.py,sha256=jpFj4V00rD9IR3vA9TqrGkwcdNVFc58LsChZavge9JY,5975 +pip/_internal/locations/_sysconfig.py,sha256=8CpTjtxaCzHSCrKpaxWnHE7aKcJrRJRmntR1ZLVysLk,7779 +pip/_internal/locations/base.py,sha256=AImjYJWxOtDkc0KKc6Y4Gz677cg91caMA4L94B9FZEg,2550 +pip/_internal/main.py,sha256=1cHqjsfFCrMFf3B5twzocxTJUdHMLoXUpy5lJoFqUi8,338 +pip/_internal/metadata/__init__.py,sha256=vp-JAxiWg_-l5F8AT0Jcey72uUnh8CDwwol9-KktHZ8,5824 +pip/_internal/metadata/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/metadata/__pycache__/_json.cpython-312.pyc,, +pip/_internal/metadata/__pycache__/base.cpython-312.pyc,, +pip/_internal/metadata/__pycache__/pkg_resources.cpython-312.pyc,, +pip/_internal/metadata/_json.py,sha256=hNvnMHOXLAyNlzirWhPL9Nx2CvCqa1iRma6Osq1YfV8,2711 +pip/_internal/metadata/base.py,sha256=BGuMenlcQT8i7j9iclrfdC3vSwgvhr8gjn955cCy16s,25420 +pip/_internal/metadata/importlib/__init__.py,sha256=jUUidoxnHcfITHHaAWG1G2i5fdBYklv_uJcjo2x7VYE,135 +pip/_internal/metadata/importlib/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/metadata/importlib/__pycache__/_compat.cpython-312.pyc,, +pip/_internal/metadata/importlib/__pycache__/_dists.cpython-312.pyc,, +pip/_internal/metadata/importlib/__pycache__/_envs.cpython-312.pyc,, +pip/_internal/metadata/importlib/_compat.py,sha256=sneVh4_6WxQZK4ljdl3ylVuP-q0ttSqbgl9mWt0HnOg,2804 +pip/_internal/metadata/importlib/_dists.py,sha256=c738sVAKF_zhhyFOIKmLlMadRvGOfEdqcoKjznwpYUI,8711 +pip/_internal/metadata/importlib/_envs.py,sha256=H3qVLXVh4LWvrPvu_ekXf3dfbtwnlhNJQP2pxXpccfU,5333 +pip/_internal/metadata/pkg_resources.py,sha256=NO76ZrfR2-LKJTyaXrmQoGhmJMArALvacrlZHViSDT8,10544 +pip/_internal/models/__init__.py,sha256=AjmCEBxX_MH9f_jVjIGNCFJKYCYeSEe18yyvNx4uRKQ,62 +pip/_internal/models/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/models/__pycache__/candidate.cpython-312.pyc,, +pip/_internal/models/__pycache__/direct_url.cpython-312.pyc,, +pip/_internal/models/__pycache__/format_control.cpython-312.pyc,, +pip/_internal/models/__pycache__/index.cpython-312.pyc,, +pip/_internal/models/__pycache__/installation_report.cpython-312.pyc,, +pip/_internal/models/__pycache__/link.cpython-312.pyc,, +pip/_internal/models/__pycache__/release_control.cpython-312.pyc,, +pip/_internal/models/__pycache__/scheme.cpython-312.pyc,, +pip/_internal/models/__pycache__/search_scope.cpython-312.pyc,, +pip/_internal/models/__pycache__/selection_prefs.cpython-312.pyc,, +pip/_internal/models/__pycache__/target_python.cpython-312.pyc,, +pip/_internal/models/__pycache__/wheel.cpython-312.pyc,, +pip/_internal/models/candidate.py,sha256=5TqwJU0YOogo3EsIPohaqQ3Z4hfU4BNNyBYBEJs6Wxw,720 +pip/_internal/models/direct_url.py,sha256=9RS3TQAXknwLd8JOOZWlbBV6WZFs9qn-YAYk0VQ8R_Q,944 +pip/_internal/models/format_control.py,sha256=PwemYG1L27BM0f1KP61rm24wShENFyxqlD1TWu34alc,2471 +pip/_internal/models/index.py,sha256=tYnL8oxGi4aSNWur0mG8DAP7rC6yuha_MwJO8xw0crI,1030 +pip/_internal/models/installation_report.py,sha256=U4MlXWFB-8ev_yheuMO9T2m_y5b4C-hOzVaoHVobl38,2846 +pip/_internal/models/link.py,sha256=zti5UCx1hT03etYqm6MCqFd714clmTgX8rTZT9CKZDQ,21992 +pip/_internal/models/release_control.py,sha256=31Jh-ZHsTIBZLe-7uPNoYLiRSWXAjEI1jGNxwqLKd4A,3365 +pip/_internal/models/scheme.py,sha256=G-O9KElabcXqbPwfE_66lzX5fGahh3Gu6DAkz_9ZhJw,558 +pip/_internal/models/search_scope.py,sha256=_i-Gj_w_FwZAvTs7WhjslBDD70J-8hmIdjXByI8uEZQ,4461 +pip/_internal/models/selection_prefs.py,sha256=0teekwSVxW5MOk0WPG5Novw5q_XJjxijcd75kZO6E9g,1503 +pip/_internal/models/target_python.py,sha256=I0eFS-eia3kwhrOvgsphFZtNAB2IwXZ9Sr9fp6IjBP4,4243 +pip/_internal/models/wheel.py,sha256=1SdfDvN7ALTsbyZ9EOsNy1GPirP1n6EjHyzPrZyLSh8,2920 +pip/_internal/network/__init__.py,sha256=FMy06P__y6jMjUc8z3ZcQdKF-pmZ2zM14_vBeHPGhUI,49 +pip/_internal/network/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/network/__pycache__/auth.cpython-312.pyc,, +pip/_internal/network/__pycache__/cache.cpython-312.pyc,, +pip/_internal/network/__pycache__/download.cpython-312.pyc,, +pip/_internal/network/__pycache__/lazy_wheel.cpython-312.pyc,, +pip/_internal/network/__pycache__/session.cpython-312.pyc,, +pip/_internal/network/__pycache__/utils.cpython-312.pyc,, +pip/_internal/network/__pycache__/xmlrpc.cpython-312.pyc,, +pip/_internal/network/auth.py,sha256=ITcuLus7666whNVJSINuNMRZzNoGHwmqhRnP6hEu0ok,20846 +pip/_internal/network/cache.py,sha256=kmRXKQrG9E26xQRj211LHeEGpDg_SlYU9Dn1fJ-AMeI,4862 +pip/_internal/network/download.py,sha256=8ilZxTWBm9J1TEpupFE56VQ5js3L81rv3X0rZwfBPTg,12625 +pip/_internal/network/lazy_wheel.py,sha256=y9gVksdJCSjnLfYzs_m3DYUAtl3hc_k-xFPDBd9DgOs,7646 +pip/_internal/network/session.py,sha256=7zK7EeQCSRFipu4ZzcWl1V3AMKkiXdtGqFr7GvU2LrY,19555 +pip/_internal/network/utils.py,sha256=ACsXd1msqNCidHVXsu7LHUSr8NgaypcOKQ4KG-Z_wJM,4091 +pip/_internal/network/xmlrpc.py,sha256=_-Rnk3vOff8uF9hAGmT6SLALflY1gMBcbGwS12fb_Y4,1830 +pip/_internal/operations/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_internal/operations/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/operations/__pycache__/check.cpython-312.pyc,, +pip/_internal/operations/__pycache__/freeze.cpython-312.pyc,, +pip/_internal/operations/__pycache__/prepare.cpython-312.pyc,, +pip/_internal/operations/build/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_internal/operations/build/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/operations/build/__pycache__/build_tracker.cpython-312.pyc,, +pip/_internal/operations/build/__pycache__/metadata.cpython-312.pyc,, +pip/_internal/operations/build/__pycache__/metadata_editable.cpython-312.pyc,, +pip/_internal/operations/build/__pycache__/wheel.cpython-312.pyc,, +pip/_internal/operations/build/__pycache__/wheel_editable.cpython-312.pyc,, +pip/_internal/operations/build/build_tracker.py,sha256=W3b5cmkMWPaE6QIwfzsTayJo7-OlxFHWDxfPuax1KcE,4771 +pip/_internal/operations/build/metadata.py,sha256=INHaeiRfOiLYCXApfDNRo9Cw2xI4VwTc0KItvfdfOjk,1421 +pip/_internal/operations/build/metadata_editable.py,sha256=oWudMsnjy4loO_Jy7g4N9nxsnaEX_iDlVRgCy7pu1rs,1509 +pip/_internal/operations/build/wheel.py,sha256=3bP-nNiJ4S8JvMaBnyessXQUBhxTqt1GBx6DQ1iPJDY,1136 +pip/_internal/operations/build/wheel_editable.py,sha256=q3kfElclM6FutVbFwE87JOTpVWt5ixDf3_UkHAIVfz4,1478 +pip/_internal/operations/check.py,sha256=yC2XWth6iehGGE_fj7XRJLjVKBsTIG3ZoWRkFi3rOwc,5894 +pip/_internal/operations/freeze.py,sha256=PDdY-y_ZtZZJLAKcaWPIGRKAGW7DXR48f0aMRU0j7BA,9854 +pip/_internal/operations/install/__init__.py,sha256=ak-UETcQPKlFZaWoYKWu5QVXbpFBvg0sXc3i0O4vSYY,50 +pip/_internal/operations/install/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/operations/install/__pycache__/wheel.cpython-312.pyc,, +pip/_internal/operations/install/wheel.py,sha256=FQIl2AnNadHV5YGGOVEmOHtUUNO8lpzj3Icoo4S2xis,27923 +pip/_internal/operations/prepare.py,sha256=Gx6r57LG_guvAYGqKUdu_68rHPPkO7CQ_qc2wKnYyss,29046 +pip/_internal/pyproject.py,sha256=J-sTWqC-XfsKQgz9m1bypMWZPHItsSHzIN_NWeIRmhM,4555 +pip/_internal/req/__init__.py,sha256=WcY9z7D3rlIKX1QY8_tRnAsS_poebiGGdtQ7EJ5JQQo,3041 +pip/_internal/req/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/req/__pycache__/constructors.cpython-312.pyc,, +pip/_internal/req/__pycache__/pep723.cpython-312.pyc,, +pip/_internal/req/__pycache__/req_dependency_group.cpython-312.pyc,, +pip/_internal/req/__pycache__/req_file.cpython-312.pyc,, +pip/_internal/req/__pycache__/req_install.cpython-312.pyc,, +pip/_internal/req/__pycache__/req_set.cpython-312.pyc,, +pip/_internal/req/__pycache__/req_uninstall.cpython-312.pyc,, +pip/_internal/req/constructors.py,sha256=EXgbMUcAtBaNj6cYms0ZweIxNOSoOPcQG8EqXl9HYhM,22918 +pip/_internal/req/pep723.py,sha256=JsG1p3CaVcW8cjclD2kDj7d9qtVrNQaevY_UnKh00tk,1242 +pip/_internal/req/req_dependency_group.py,sha256=PrWKtlwI8xbWnWEKjXs9RkrpQx2_h02ABefYT0ZdeQg,3145 +pip/_internal/req/req_file.py,sha256=idVj4uVd8yQIBQojoulL1ceXGr1Qk8ongXzwI4vTTss,20521 +pip/_internal/req/req_install.py,sha256=VVzO8UIp6TOU_QCEoSxYdkG39z54pKPQjg8Z6z4WbNM,31845 +pip/_internal/req/req_set.py,sha256=awkqIXnYA4Prmsj0Qb3zhqdbYUmXd-1o0P-KZ3mvRQs,2828 +pip/_internal/req/req_uninstall.py,sha256=dCmOHt-9RaJBq921L4tMH3PmIBDetGplnbjRKXmGt00,24099 +pip/_internal/resolution/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_internal/resolution/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/resolution/__pycache__/base.cpython-312.pyc,, +pip/_internal/resolution/base.py,sha256=RIsqSP79olPdOgtPKW-oOQ364ICVopehA6RfGkRfe2s,577 +pip/_internal/resolution/legacy/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_internal/resolution/legacy/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/resolution/legacy/__pycache__/resolver.cpython-312.pyc,, +pip/_internal/resolution/legacy/resolver.py,sha256=pMwU11FO1jeWB2vX-wvA5fdyDBPWH6Dccj9qEdh1Z3M,24061 +pip/_internal/resolution/resolvelib/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_internal/resolution/resolvelib/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/resolution/resolvelib/__pycache__/base.cpython-312.pyc,, +pip/_internal/resolution/resolvelib/__pycache__/candidates.cpython-312.pyc,, +pip/_internal/resolution/resolvelib/__pycache__/factory.cpython-312.pyc,, +pip/_internal/resolution/resolvelib/__pycache__/found_candidates.cpython-312.pyc,, +pip/_internal/resolution/resolvelib/__pycache__/provider.cpython-312.pyc,, +pip/_internal/resolution/resolvelib/__pycache__/reporter.cpython-312.pyc,, +pip/_internal/resolution/resolvelib/__pycache__/requirements.cpython-312.pyc,, +pip/_internal/resolution/resolvelib/__pycache__/resolver.cpython-312.pyc,, +pip/_internal/resolution/resolvelib/base.py,sha256=g3qtckAh3E34y-5HrYLlYnOZ9SiPGDISzsqhaRDUAqQ,5903 +pip/_internal/resolution/resolvelib/candidates.py,sha256=4v3A2Q7gS1a1tbMbpho9HliFW4fRmHFuzj8fa7ThZ6c,20912 +pip/_internal/resolution/resolvelib/factory.py,sha256=gWRrcgr64br0ecF_PPxKfneXEzr0k-Solv2X9z3Goj0,36771 +pip/_internal/resolution/resolvelib/found_candidates.py,sha256=8bZYDCZLXSdLHy_s1o5f4r15HmKvqFUhzBUQOF21Lr4,6018 +pip/_internal/resolution/resolvelib/provider.py,sha256=X3nrCcVTer3mZSEy-13KiPFBJYmhfWJdA1cr-Gn1q7M,12150 +pip/_internal/resolution/resolvelib/reporter.py,sha256=tEC7MF8IqGU4Ww9t61YVfNFKtoaQpb6-AwLZptJz1VE,3918 +pip/_internal/resolution/resolvelib/requirements.py,sha256=Izl9n8nc188lA1BSPS8QxfudfDQPHgngw-ij6hXt0nQ,8239 +pip/_internal/resolution/resolvelib/resolver.py,sha256=wQ94Hkep-7kWEHAc-NbMJhmzeEzgEAtxeBxyKVzZoeo,13437 +pip/_internal/self_outdated_check.py,sha256=9XxOXPqsZlKceTP2tZS7I7rXjodnqd3GrIQ8U0_L8BM,8097 +pip/_internal/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_internal/utils/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/utils/__pycache__/_jaraco_text.cpython-312.pyc,, +pip/_internal/utils/__pycache__/_log.cpython-312.pyc,, +pip/_internal/utils/__pycache__/appdirs.cpython-312.pyc,, +pip/_internal/utils/__pycache__/compat.cpython-312.pyc,, +pip/_internal/utils/__pycache__/compatibility_tags.cpython-312.pyc,, +pip/_internal/utils/__pycache__/datetime.cpython-312.pyc,, +pip/_internal/utils/__pycache__/deprecation.cpython-312.pyc,, +pip/_internal/utils/__pycache__/direct_url_helpers.cpython-312.pyc,, +pip/_internal/utils/__pycache__/egg_link.cpython-312.pyc,, +pip/_internal/utils/__pycache__/entrypoints.cpython-312.pyc,, +pip/_internal/utils/__pycache__/filesystem.cpython-312.pyc,, +pip/_internal/utils/__pycache__/filetypes.cpython-312.pyc,, +pip/_internal/utils/__pycache__/glibc.cpython-312.pyc,, +pip/_internal/utils/__pycache__/hashes.cpython-312.pyc,, +pip/_internal/utils/__pycache__/logging.cpython-312.pyc,, +pip/_internal/utils/__pycache__/misc.cpython-312.pyc,, +pip/_internal/utils/__pycache__/packaging.cpython-312.pyc,, +pip/_internal/utils/__pycache__/pylock.cpython-312.pyc,, +pip/_internal/utils/__pycache__/retry.cpython-312.pyc,, +pip/_internal/utils/__pycache__/subprocess.cpython-312.pyc,, +pip/_internal/utils/__pycache__/temp_dir.cpython-312.pyc,, +pip/_internal/utils/__pycache__/unpacking.cpython-312.pyc,, +pip/_internal/utils/__pycache__/urls.cpython-312.pyc,, +pip/_internal/utils/__pycache__/virtualenv.cpython-312.pyc,, +pip/_internal/utils/__pycache__/wheel.cpython-312.pyc,, +pip/_internal/utils/_jaraco_text.py,sha256=M15uUPIh5NpP1tdUGBxRau6q1ZAEtI8-XyLEETscFfE,3350 +pip/_internal/utils/_log.py,sha256=-jHLOE_THaZz5BFcCnoSL9EYAtJ0nXem49s9of4jvKw,1015 +pip/_internal/utils/appdirs.py,sha256=LrzDPZMKVh0rubtCx9vu3XlZbLCSug6VSj4Qsvt66BA,1681 +pip/_internal/utils/compat.py,sha256=C9LHXJAKkwAH8Hn3nPkz9EYK3rqPBeO_IXkOG2zzsdQ,2514 +pip/_internal/utils/compatibility_tags.py,sha256=DiNSLqpuruXUamGQwOJ2WZByDGLTGaXi9O-Xf8fOi34,6630 +pip/_internal/utils/datetime.py,sha256=kuJOf1mW8G5tRFN6jWardddS-9qSaR53lK1jmx3NTZY,868 +pip/_internal/utils/deprecation.py,sha256=oEQltmCq44LQ6EP7NF5bZySMf-wCifoyy9jl361BnVM,4319 +pip/_internal/utils/direct_url_helpers.py,sha256=WCCPJnmoPHz7kiYePrEcVAen2lDpCT9WQVImoHHWCO8,3363 +pip/_internal/utils/egg_link.py,sha256=YWfsrbmfcrfWgqQYy6OuIjsyb9IfL1q_2v4zsms1WjI,2459 +pip/_internal/utils/entrypoints.py,sha256=uPjAyShKObdotjQjJUzprQ6r3xQvDIZwUYfHHqZ7Dok,3324 +pip/_internal/utils/filesystem.py,sha256=GBB42pbxmUgdRAbSgLTRrWQEapyLCDSjxT21DN4QjU8,6812 +pip/_internal/utils/filetypes.py,sha256=sEMa38qaqjvx1Zid3OCAUja31BOBU-USuSMPBvU3yjo,689 +pip/_internal/utils/glibc.py,sha256=sEh8RJJLYSdRvTqAO4THVPPA-YSDVLD4SI9So-bxX1U,3726 +pip/_internal/utils/hashes.py,sha256=38-bCOJSHippQ7r9RttrMHxb2mv3EARt1Gw8kFmW73g,5040 +pip/_internal/utils/logging.py,sha256=6lJWMC6c7_aD_i4sdgaaeb-Tm3kWpYg0hba_V1-OLnE,13414 +pip/_internal/utils/misc.py,sha256=-fF_rOhxBxp57kwGlNl3XziBcs0gCf6D05wxZ-mkoTc,23704 +pip/_internal/utils/packaging.py,sha256=s5tpUmFumwV0H9JSTzryrIY4JwQM8paGt7Sm7eNwt2Y,1601 +pip/_internal/utils/pylock.py,sha256=T4qyd-TWb54wIO5_DdwASATtU7gi08IGEa_-pdFR7HE,9358 +pip/_internal/utils/retry.py,sha256=83wReEB2rcntMZ5VLd7ascaYSjn_kLdlQCqxILxWkPM,1461 +pip/_internal/utils/subprocess.py,sha256=r4-Ba_Yc3uZXQpi0K4pZFsCT_QqdSvtF3XJ-204QWaA,8983 +pip/_internal/utils/temp_dir.py,sha256=D9c8D7WOProOO8GGDqpBeVSj10NGFmunG0o2TodjjIU,9307 +pip/_internal/utils/unpacking.py,sha256=62qpFOlxRl5wjbeIYSrF-GE-NA1Ko7mAYjyweZx9MWs,13537 +pip/_internal/utils/urls.py,sha256=aF_eg9ul5d8bMCxfSSSxQcfs-OpJdbStYqZHoy2K1RE,1601 +pip/_internal/utils/virtualenv.py,sha256=mX-UPyw1MPxhwUxKhbqWWX70J6PHXAJjVVrRnG0h9mc,3455 +pip/_internal/utils/wheel.py,sha256=YdRuj6MicG-Q9Mg03FbUv1WTLam6Lc7AgijY4voVyis,4468 +pip/_internal/vcs/__init__.py,sha256=UAqvzpbi0VbZo3Ub6skEeZAw-ooIZR-zX_WpCbxyCoU,596 +pip/_internal/vcs/__pycache__/__init__.cpython-312.pyc,, +pip/_internal/vcs/__pycache__/bazaar.cpython-312.pyc,, +pip/_internal/vcs/__pycache__/git.cpython-312.pyc,, +pip/_internal/vcs/__pycache__/mercurial.cpython-312.pyc,, +pip/_internal/vcs/__pycache__/subversion.cpython-312.pyc,, +pip/_internal/vcs/__pycache__/versioncontrol.cpython-312.pyc,, +pip/_internal/vcs/bazaar.py,sha256=3W1eHjkYx2vc6boeb2NBh4I_rlGAXM-vrzfNhLm1Rxg,3734 +pip/_internal/vcs/git.py,sha256=TTeqDuzS-_BFSNuUStVWmE2nGDpKuvUhBBJk_CCQXV0,19144 +pip/_internal/vcs/mercurial.py,sha256=w1ZJWLKqNP1onEjkfjlwBVnMqPZNSIER8ayjQcnTq4w,5575 +pip/_internal/vcs/subversion.py,sha256=uUgdPvxmvEB8Qwtjr0Hc0XgFjbiNi5cbvI4vARLOJXo,11787 +pip/_internal/vcs/versioncontrol.py,sha256=Ma_HMZBVveSkeYvxacvqeujnkSIaF1XjxTsS3BwcJ8E,22599 +pip/_internal/wheel_builder.py,sha256=yvEULStZtty9Kplp89tDis3hGdyKQ-2BUbFLmJ_5ink,9010 +pip/_vendor/README.rst,sha256=t7IinjaiuwUh812XmVApQHJb8pTw33U8A9URqy6GlF4,9222 +pip/_vendor/__init__.py,sha256=WzusPTGWIMeQQWSVJ0h2rafGkVTa9WKJ2HT-2-EoZrU,4907 +pip/_vendor/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/cachecontrol/LICENSE.txt,sha256=hu7uh74qQ_P_H1ZJb0UfaSQ5JvAl_tuwM2ZsMExMFhs,558 +pip/_vendor/cachecontrol/__init__.py,sha256=GxwRkm_TQBtPZpfpVK9r6S9dAy2DVnVgDVHJKTiPZ1k,820 +pip/_vendor/cachecontrol/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/cachecontrol/__pycache__/_cmd.cpython-312.pyc,, +pip/_vendor/cachecontrol/__pycache__/adapter.cpython-312.pyc,, +pip/_vendor/cachecontrol/__pycache__/cache.cpython-312.pyc,, +pip/_vendor/cachecontrol/__pycache__/controller.cpython-312.pyc,, +pip/_vendor/cachecontrol/__pycache__/filewrapper.cpython-312.pyc,, +pip/_vendor/cachecontrol/__pycache__/heuristics.cpython-312.pyc,, +pip/_vendor/cachecontrol/__pycache__/serialize.cpython-312.pyc,, +pip/_vendor/cachecontrol/__pycache__/wrapper.cpython-312.pyc,, +pip/_vendor/cachecontrol/_cmd.py,sha256=iist2EpzJvDVIhMAxXq8iFnTBsiZAd6iplxfmNboNyk,1737 +pip/_vendor/cachecontrol/adapter.py,sha256=W-HW-l01gyCsnxkOyCbqx7sxrWYoBbKrDsKkVVQN6NE,6586 +pip/_vendor/cachecontrol/cache.py,sha256=OXwv7Fn2AwnKNiahJHnjtvaKLndvVLv_-zO-ltlV9qI,1953 +pip/_vendor/cachecontrol/caches/__init__.py,sha256=dtrrroK5BnADR1GWjCZ19aZ0tFsMfvFBtLQQU1sp_ag,303 +pip/_vendor/cachecontrol/caches/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/cachecontrol/caches/__pycache__/file_cache.cpython-312.pyc,, +pip/_vendor/cachecontrol/caches/__pycache__/redis_cache.cpython-312.pyc,, +pip/_vendor/cachecontrol/caches/file_cache.py,sha256=d8upFmy_zwaCmlbWEVBlLXFddt8Zw8c5SFpxeOZsdfw,4117 +pip/_vendor/cachecontrol/caches/redis_cache.py,sha256=9rmqwtYu_ljVkW6_oLqbC7EaX_a8YT_yLuna-eS0dgo,1386 +pip/_vendor/cachecontrol/controller.py,sha256=xBauC-vUSu5GsJsxD4-W-JaKqqbBz0MN6Zv8PA2N8hI,19102 +pip/_vendor/cachecontrol/filewrapper.py,sha256=DhxC_rSk-beKdbsYhfvBUDovQHX9r3gHH_jP9-q_mKk,4354 +pip/_vendor/cachecontrol/heuristics.py,sha256=gqMXU8w0gQuEQiSdu3Yg-0vd9kW7nrWKbLca75rheGE,4881 +pip/_vendor/cachecontrol/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_vendor/cachecontrol/serialize.py,sha256=HQd2IllQ05HzPkVLMXTF2uX5mjEQjDBkxCqUJUODpZk,5163 +pip/_vendor/cachecontrol/wrapper.py,sha256=hsGc7g8QGQTT-4f8tgz3AM5qwScg6FO0BSdLSRdEvpU,1417 +pip/_vendor/certifi/LICENSE,sha256=6TcW2mucDVpKHfYP5pWzcPBpVgPSH2-D8FPkLPwQyvc,989 +pip/_vendor/certifi/__init__.py,sha256=c9eaYufv1pSLl0Q8QNcMiMLLH4WquDcxdPyKjmI4opY,94 +pip/_vendor/certifi/__main__.py,sha256=1k3Cr95vCxxGRGDljrW3wMdpZdL3Nhf0u1n-k2qdsCY,255 +pip/_vendor/certifi/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/certifi/__pycache__/__main__.cpython-312.pyc,, +pip/_vendor/certifi/__pycache__/core.cpython-312.pyc,, +pip/_vendor/certifi/cacert.pem,sha256=_JFloSQDJj5-v72te-ej6sD6XTJdPHBGXyjTaQByyig,272441 +pip/_vendor/certifi/core.py,sha256=gu_ECVI1m3Rq0ytpsNE61hgQGcKaOAt9Rs9G8KsTCOI,3442 +pip/_vendor/certifi/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_vendor/distlib/LICENSE.txt,sha256=gI4QyKarjesUn_mz-xn0R6gICUYG1xKpylf-rTVSWZ0,14531 +pip/_vendor/distlib/__init__.py,sha256=Deo3uo98aUyIfdKJNqofeSEFWwDzrV2QeGLXLsgq0Ag,625 +pip/_vendor/distlib/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/distlib/__pycache__/compat.cpython-312.pyc,, +pip/_vendor/distlib/__pycache__/resources.cpython-312.pyc,, +pip/_vendor/distlib/__pycache__/scripts.cpython-312.pyc,, +pip/_vendor/distlib/__pycache__/util.cpython-312.pyc,, +pip/_vendor/distlib/compat.py,sha256=2jRSjRI4o-vlXeTK2BCGIUhkc6e9ZGhSsacRM5oseTw,41467 +pip/_vendor/distlib/resources.py,sha256=LwbPksc0A1JMbi6XnuPdMBUn83X7BPuFNWqPGEKI698,10820 +pip/_vendor/distlib/scripts.py,sha256=Qvp76E9Jc3IgyYubnpqI9fS7eseGOe4FjpeVKqKt9Iw,18612 +pip/_vendor/distlib/t32.exe,sha256=a0GV5kCoWsMutvliiCKmIgV98eRZ33wXoS-XrqvJQVs,97792 +pip/_vendor/distlib/t64-arm.exe,sha256=68TAa32V504xVBnufojh0PcenpR3U4wAqTqf-MZqbPw,182784 +pip/_vendor/distlib/t64.exe,sha256=gaYY8hy4fbkHYTTnA4i26ct8IQZzkBG2pRdy0iyuBrc,108032 +pip/_vendor/distlib/util.py,sha256=vMPGvsS4j9hF6Y9k3Tyom1aaHLb0rFmZAEyzeAdel9w,66682 +pip/_vendor/distlib/w32.exe,sha256=R4csx3-OGM9kL4aPIzQKRo5TfmRSHZo6QWyLhDhNBks,91648 +pip/_vendor/distlib/w64-arm.exe,sha256=xdyYhKj0WDcVUOCb05blQYvzdYIKMbmJn2SZvzkcey4,168448 +pip/_vendor/distlib/w64.exe,sha256=ejGf-rojoBfXseGLpya6bFTFPWRG21X5KvU8J5iU-K0,101888 +pip/_vendor/distro/LICENSE,sha256=y16Ofl9KOYjhBjwULGDcLfdWBfTEZRXnduOspt-XbhQ,11325 +pip/_vendor/distro/__init__.py,sha256=2fHjF-SfgPvjyNZ1iHh_wjqWdR_Yo5ODHwZC0jLBPhc,981 +pip/_vendor/distro/__main__.py,sha256=bu9d3TifoKciZFcqRBuygV3GSuThnVD_m2IK4cz96Vs,64 +pip/_vendor/distro/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/distro/__pycache__/__main__.cpython-312.pyc,, +pip/_vendor/distro/__pycache__/distro.cpython-312.pyc,, +pip/_vendor/distro/distro.py,sha256=XqbefacAhDT4zr_trnbA15eY8vdK4GTghgmvUGrEM_4,49430 +pip/_vendor/distro/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_vendor/idna/LICENSE.md,sha256=t6M2q_OwThgOwGXN0W5wXQeeHMehT5EKpukYfza5zYc,1541 +pip/_vendor/idna/__init__.py,sha256=MPqNDLZbXqGaNdXxAFhiqFPKEQXju2jNQhCey6-5eJM,868 +pip/_vendor/idna/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/idna/__pycache__/codec.cpython-312.pyc,, +pip/_vendor/idna/__pycache__/compat.cpython-312.pyc,, +pip/_vendor/idna/__pycache__/core.cpython-312.pyc,, +pip/_vendor/idna/__pycache__/idnadata.cpython-312.pyc,, +pip/_vendor/idna/__pycache__/intranges.cpython-312.pyc,, +pip/_vendor/idna/__pycache__/package_data.cpython-312.pyc,, +pip/_vendor/idna/__pycache__/uts46data.cpython-312.pyc,, +pip/_vendor/idna/codec.py,sha256=M2SGWN7cs_6B32QmKTyTN6xQGZeYQgQ2wiX3_DR6loE,3438 +pip/_vendor/idna/compat.py,sha256=RzLy6QQCdl9784aFhb2EX9EKGCJjg0P3PilGdeXXcx8,316 +pip/_vendor/idna/core.py,sha256=P26_XVycuMTZ1R2mNK1ZREVzM5mvTzdabBXfyZVU1Lc,13246 +pip/_vendor/idna/idnadata.py,sha256=SG8jhaGE53iiD6B49pt2pwTv_UvClciWE-N54oR2p4U,79623 +pip/_vendor/idna/intranges.py,sha256=amUtkdhYcQG8Zr-CoMM_kVRacxkivC1WgxN1b63KKdU,1898 +pip/_vendor/idna/package_data.py,sha256=_CUavOxobnbyNG2FLyHoN8QHP3QM9W1tKuw7eq9QwBk,21 +pip/_vendor/idna/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_vendor/idna/uts46data.py,sha256=H9J35VkD0F9L9mKOqjeNGd2A-Va6FlPoz6Jz4K7h-ps,243725 +pip/_vendor/msgpack/COPYING,sha256=SS3tuoXaWHL3jmCRvNH-pHTWYNNay03ulkuKqz8AdCc,614 +pip/_vendor/msgpack/__init__.py,sha256=RA8gcqK17YpkxBnNwXJVa1oa2LygWDgfF1nA1NPw3mo,1109 +pip/_vendor/msgpack/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/msgpack/__pycache__/exceptions.cpython-312.pyc,, +pip/_vendor/msgpack/__pycache__/ext.cpython-312.pyc,, +pip/_vendor/msgpack/__pycache__/fallback.cpython-312.pyc,, +pip/_vendor/msgpack/exceptions.py,sha256=dCTWei8dpkrMsQDcjQk74ATl9HsIBH0ybt8zOPNqMYc,1081 +pip/_vendor/msgpack/ext.py,sha256=kteJv03n9tYzd5oo3xYopVTo4vRaAxonBQQJhXohZZo,5726 +pip/_vendor/msgpack/fallback.py,sha256=0g1Pzp0vtmBEmJ5w9F3s_-JMVURP8RS4G1cc5TRaAsI,32390 +pip/_vendor/packaging/LICENSE,sha256=ytHvW9NA1z4HS6YU0m996spceUDD2MNIUuZcSQlobEg,197 +pip/_vendor/packaging/LICENSE.APACHE,sha256=DVQuDIgE45qn836wDaWnYhSdxoLXgpRRKH4RuTjpRZQ,10174 +pip/_vendor/packaging/LICENSE.BSD,sha256=tw5-m3QvHMb5SLNMFqo5_-zpQZY2S8iP8NIYDwAo-sU,1344 +pip/_vendor/packaging/__init__.py,sha256=QhMEdPu2XogrJzV3S0KWS6t7l0I9k8EeDRJl4fnw87s,494 +pip/_vendor/packaging/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/_elffile.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/_manylinux.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/_musllinux.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/_parser.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/_structures.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/_tokenizer.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/dependency_groups.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/direct_url.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/errors.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/markers.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/metadata.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/pylock.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/requirements.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/specifiers.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/tags.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/utils.cpython-312.pyc,, +pip/_vendor/packaging/__pycache__/version.cpython-312.pyc,, +pip/_vendor/packaging/_elffile.py,sha256=-sKkptYqzYw2-x3QByJa5mB4rfPWu1pxkZHRx1WAFCY,3211 +pip/_vendor/packaging/_manylinux.py,sha256=Hf6nB0cOrayEs96-p3oIXAgGnFquv20DO5l-o2_Xnv0,9559 +pip/_vendor/packaging/_musllinux.py,sha256=Z6swjH3MA7XS3qXnmMN7QPhqP3fnoYI0eQ18e9-HgAE,2707 +pip/_vendor/packaging/_parser.py,sha256=Kf2nsDw4c54X82pY8ba4F02Bve6OygGMAjL-Begqcew,11698 +pip/_vendor/packaging/_structures.py,sha256=60jRbF78p8z5MKnNd6cAprgOadCJHV0DlmUmRBqFZcs,1109 +pip/_vendor/packaging/_tokenizer.py,sha256=tFU2Wr-ZZJdAbkXLEJo7qUQDJaIkfft9DqaifiEND7A,5391 +pip/_vendor/packaging/dependency_groups.py,sha256=XZIAVFK9uHG4RCGprmJn3VInUWMesxha_kytJuMO9eY,10218 +pip/_vendor/packaging/direct_url.py,sha256=eKmbDiPP1sLV4Mj_kCSZqqknrIyVO9Sr7JpF8KCjp4U,10917 +pip/_vendor/packaging/errors.py,sha256=6hfEYXAf8v_IF65-lFadJOMIieBP2xIKtyEXjG1nGIs,2680 +pip/_vendor/packaging/licenses/__init__.py,sha256=_Jx0XRiD_58palsWnyLrLuh59ZpGCPIPXLKdZo9OJvQ,7293 +pip/_vendor/packaging/licenses/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/packaging/licenses/__pycache__/_spdx.cpython-312.pyc,, +pip/_vendor/packaging/licenses/_spdx.py,sha256=WW7DXiyg68up_YND_wpRYlr1SHhiV4FfJLQffghhMxQ,51122 +pip/_vendor/packaging/markers.py,sha256=QixBVcb9D2HjwEYiuhpNkbqk9znPRbU8zNX0kR1RIrU,17067 +pip/_vendor/packaging/metadata.py,sha256=crAh0E3GVGVqPlu6EdRFsaG-Y6UYznTUqjuGKRGPv6c,38770 +pip/_vendor/packaging/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_vendor/packaging/pylock.py,sha256=G_1gncTmDbRLY1jo4VDI9Uw-b5IErh_Q9V_BbVJTmD8,33890 +pip/_vendor/packaging/requirements.py,sha256=Q-BdEHVW5K785GBXt7RcP4UEsdIKWoWFqlrHjR4WV50,4395 +pip/_vendor/packaging/specifiers.py,sha256=3XBcSslm-YQEEEO_zrv4F6dR5wRxs4ErJvJ0vjNBfGM,71550 +pip/_vendor/packaging/tags.py,sha256=ANYHZxYQVp9BlOQYOHU5ArDNVIpTFl4KlbocYVBWnFs,34236 +pip/_vendor/packaging/utils.py,sha256=M7-JMKic2sP1YtV_8aW7eVGB-x3ADuKCiSrsVeCd2Uo,9848 +pip/_vendor/packaging/version.py,sha256=Mcu7Tf6Y1i0gQ4FXv4t0g8cbL5joAEshjgIpz_2vISI,38393 +pip/_vendor/pkg_resources/LICENSE,sha256=htoPAa6uRjSKPD1GUZXcHOzN55956HdppkuNoEsqR0E,1023 +pip/_vendor/pkg_resources/__init__.py,sha256=vbTJ0_ruUgGxQjlEqsruFmiNPVyh2t9q-zyTDT053xI,124451 +pip/_vendor/pkg_resources/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/platformdirs/LICENSE,sha256=KeD9YukphQ6G6yjD_czwzv30-pSHkBHP-z0NS-1tTbY,1089 +pip/_vendor/platformdirs/__init__.py,sha256=UfeSHWl8AeTtbOBOoHAxK4dODOWkZtfy-m_i7cWdJ8c,22344 +pip/_vendor/platformdirs/__main__.py,sha256=jBJ8zb7Mpx5ebcqF83xrpO94MaeCpNGHVf9cvDN2JLg,1505 +pip/_vendor/platformdirs/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/platformdirs/__pycache__/__main__.cpython-312.pyc,, +pip/_vendor/platformdirs/__pycache__/android.cpython-312.pyc,, +pip/_vendor/platformdirs/__pycache__/api.cpython-312.pyc,, +pip/_vendor/platformdirs/__pycache__/macos.cpython-312.pyc,, +pip/_vendor/platformdirs/__pycache__/unix.cpython-312.pyc,, +pip/_vendor/platformdirs/__pycache__/version.cpython-312.pyc,, +pip/_vendor/platformdirs/__pycache__/windows.cpython-312.pyc,, +pip/_vendor/platformdirs/android.py,sha256=r0DshVBf-RO1jXJGX8C4Til7F1XWt-bkdWMgmvEiaYg,9013 +pip/_vendor/platformdirs/api.py,sha256=wPHOlwOsfz2oqQZ6A2FcCu5kEAj-JondzoNOHYFQ0h8,9281 +pip/_vendor/platformdirs/macos.py,sha256=0XoOgin1NK7Qki7iskD-oS8xKxw6bXgoKEgdqpCRAFQ,6322 +pip/_vendor/platformdirs/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_vendor/platformdirs/unix.py,sha256=WZmkUA--L3JNRGmz32s35YfoD3ica6xKIPdCV_HhLcs,10458 +pip/_vendor/platformdirs/version.py,sha256=BI_dKLSMwlkl57vlxZnT8oVjPiUC2W_sdx_8_h99HeQ,704 +pip/_vendor/platformdirs/windows.py,sha256=XvCfklGUMVxJbXit51jpYMN-lNeScPB82qS1CAeplL0,10362 +pip/_vendor/pygments/LICENSE,sha256=qdZvHVJt8C4p3Oc0NtNOVuhjL0bCdbvf_HBWnogvnxc,1331 +pip/_vendor/pygments/__init__.py,sha256=8uNqJCCwXqbEx5aSsBr0FykUQOBDKBihO5mPqiw1aqo,2983 +pip/_vendor/pygments/__main__.py,sha256=WrndpSe6i1ckX_SQ1KaxD9CTKGzD0EuCOFxcbwFpoLU,353 +pip/_vendor/pygments/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/pygments/__pycache__/__main__.cpython-312.pyc,, +pip/_vendor/pygments/__pycache__/console.cpython-312.pyc,, +pip/_vendor/pygments/__pycache__/filter.cpython-312.pyc,, +pip/_vendor/pygments/__pycache__/formatter.cpython-312.pyc,, +pip/_vendor/pygments/__pycache__/lexer.cpython-312.pyc,, +pip/_vendor/pygments/__pycache__/modeline.cpython-312.pyc,, +pip/_vendor/pygments/__pycache__/plugin.cpython-312.pyc,, +pip/_vendor/pygments/__pycache__/regexopt.cpython-312.pyc,, +pip/_vendor/pygments/__pycache__/scanner.cpython-312.pyc,, +pip/_vendor/pygments/__pycache__/sphinxext.cpython-312.pyc,, +pip/_vendor/pygments/__pycache__/style.cpython-312.pyc,, +pip/_vendor/pygments/__pycache__/token.cpython-312.pyc,, +pip/_vendor/pygments/__pycache__/unistring.cpython-312.pyc,, +pip/_vendor/pygments/__pycache__/util.cpython-312.pyc,, +pip/_vendor/pygments/console.py,sha256=AagDWqwea2yBWf10KC9ptBgMpMjxKp8yABAmh-NQOVk,1718 +pip/_vendor/pygments/filter.py,sha256=YLtpTnZiu07nY3oK9nfR6E9Y1FBHhP5PX8gvkJWcfag,1910 +pip/_vendor/pygments/filters/__init__.py,sha256=4U4jtA0X3iP83uQnB9-TI-HDSw8E8y8zMYHa0UjbbaI,40392 +pip/_vendor/pygments/filters/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/pygments/formatter.py,sha256=KZQMmyo_xkOIkQG8g66LYEkBh1bx7a0HyGCBcvhI9Ew,4390 +pip/_vendor/pygments/formatters/__init__.py,sha256=KTwBmnXlaopJhQDOemVHYHskiDghuq-08YtP6xPNJPg,5385 +pip/_vendor/pygments/formatters/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/pygments/formatters/__pycache__/_mapping.cpython-312.pyc,, +pip/_vendor/pygments/formatters/_mapping.py,sha256=1Cw37FuQlNacnxRKmtlPX4nyLoX9_ttko5ZwscNUZZ4,4176 +pip/_vendor/pygments/lexer.py,sha256=_kBrOJ_NT5Tl0IVM0rA9c8eysP6_yrlGzEQI0eVYB-A,35349 +pip/_vendor/pygments/lexers/__init__.py,sha256=wbIME35GH7bI1B9rNPJFqWT-ij_RApZDYPUlZycaLzA,12115 +pip/_vendor/pygments/lexers/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/pygments/lexers/__pycache__/_mapping.cpython-312.pyc,, +pip/_vendor/pygments/lexers/__pycache__/python.cpython-312.pyc,, +pip/_vendor/pygments/lexers/_mapping.py,sha256=l4tCXM8e9aPC2BD6sjIr0deT-J-z5tHgCwL-p1fS0PE,77602 +pip/_vendor/pygments/lexers/python.py,sha256=vxjn1cOHclIKJKxoyiBsQTY65GHbkZtZRuKQ2AVCKaw,53853 +pip/_vendor/pygments/modeline.py,sha256=K5eSkR8GS1r5OkXXTHOcV0aM_6xpk9eWNEIAW-OOJ2g,1005 +pip/_vendor/pygments/plugin.py,sha256=tPx0rJCTIZ9ioRgLNYG4pifCbAwTRUZddvLw-NfAk2w,1891 +pip/_vendor/pygments/regexopt.py,sha256=wXaP9Gjp_hKAdnICqoDkRxAOQJSc4v3X6mcxx3z-TNs,3072 +pip/_vendor/pygments/scanner.py,sha256=nNcETRR1tRuiTaHmHSTTECVYFPcLf6mDZu1e4u91A9E,3092 +pip/_vendor/pygments/sphinxext.py,sha256=5x7Zh9YlU6ISJ31dMwduiaanb5dWZnKg3MyEQsseNnQ,7981 +pip/_vendor/pygments/style.py,sha256=PlOZqlsnTVd58RGy50vkA2cXQ_lP5bF5EGMEBTno6DA,6420 +pip/_vendor/pygments/styles/__init__.py,sha256=x9ebctfyvCAFpMTlMJ5YxwcNYBzjgq6zJaKkNm78r4M,2042 +pip/_vendor/pygments/styles/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/pygments/styles/__pycache__/_mapping.cpython-312.pyc,, +pip/_vendor/pygments/styles/_mapping.py,sha256=6lovFUE29tz6EsV3XYY4hgozJ7q1JL7cfO3UOlgnS8w,3312 +pip/_vendor/pygments/token.py,sha256=WbdWGhYm_Vosb0DDxW9lHNPgITXfWTsQmHt6cy9RbcM,6226 +pip/_vendor/pygments/unistring.py,sha256=al-_rBemRuGvinsrM6atNsHTmJ6DUbw24q2O2Ru1cBc,63208 +pip/_vendor/pygments/util.py,sha256=oRtSpiAo5jM9ulntkvVbgXUdiAW57jnuYGB7t9fYuhc,10031 +pip/_vendor/pyproject_hooks/LICENSE,sha256=GyKwSbUmfW38I6Z79KhNjsBLn9-xpR02DkK0NCyLQVQ,1081 +pip/_vendor/pyproject_hooks/__init__.py,sha256=cPB_a9LXz5xvsRbX1o2qyAdjLatZJdQ_Lc5McNX-X7Y,691 +pip/_vendor/pyproject_hooks/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/pyproject_hooks/__pycache__/_impl.cpython-312.pyc,, +pip/_vendor/pyproject_hooks/_impl.py,sha256=jY-raxnmyRyB57ruAitrJRUzEexuAhGTpgMygqx67Z4,14936 +pip/_vendor/pyproject_hooks/_in_process/__init__.py,sha256=MJNPpfIxcO-FghxpBbxkG1rFiQf6HOUbV4U5mq0HFns,557 +pip/_vendor/pyproject_hooks/_in_process/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/pyproject_hooks/_in_process/__pycache__/_in_process.cpython-312.pyc,, +pip/_vendor/pyproject_hooks/_in_process/_in_process.py,sha256=qcXMhmx__MIJq10gGHW3mA4Tl8dy8YzHMccwnNoKlw0,12216 +pip/_vendor/pyproject_hooks/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_vendor/requests/LICENSE,sha256=CeipvOyAZxBGUsFoaFqwkx54aPnIKEtm9a5u2uXxEws,10142 +pip/_vendor/requests/__init__.py,sha256=b6rlXPyuiLAd-s-pEPX7IejJnmIH1epCOFo_mLJrAck,5029 +pip/_vendor/requests/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/__version__.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/_internal_utils.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/adapters.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/api.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/auth.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/certs.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/compat.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/cookies.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/exceptions.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/help.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/hooks.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/models.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/packages.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/sessions.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/status_codes.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/structures.cpython-312.pyc,, +pip/_vendor/requests/__pycache__/utils.cpython-312.pyc,, +pip/_vendor/requests/__version__.py,sha256=nZ3xT2HoQjEOL4OW7CM2tBWtrpfclaxuSz3bQZf_mbI,435 +pip/_vendor/requests/_internal_utils.py,sha256=9_7fcdYfMFDfyK4hD2OsRgiGiq8kDwdZcGuRqkP5R1g,1502 +pip/_vendor/requests/adapters.py,sha256=VahmpDjZCd8ERe4FfTci9NHXvtIOF7ds06gX0kWZfpo,26292 +pip/_vendor/requests/api.py,sha256=_Zb9Oa7tzVIizTKwFrPjDEY9ejtm_OnSRERnADxGsQs,6449 +pip/_vendor/requests/auth.py,sha256=KHXfnbNH2Fe4rdGJK3raL4O3nxkXyUlLizJJBEguhSc,10170 +pip/_vendor/requests/certs.py,sha256=eD1G0RoMZ3kA0lydkw7oo0lmcKqvD1hhz6yOlgSKm8w,442 +pip/_vendor/requests/compat.py,sha256=QfbmdTFiZzjSHMXiMrd4joCRU6RabtQ9zIcPoVaHIus,1822 +pip/_vendor/requests/cookies.py,sha256=bNi-iqEj4NPZ00-ob-rHvzkvObzN3lEpgw3g6paS3Xw,18590 +pip/_vendor/requests/exceptions.py,sha256=fz5n2nffa7Q30Ho9AnCuNekOo0S3BDIS7Vk4HQlakWs,4273 +pip/_vendor/requests/help.py,sha256=lREO92zUuXe0gnkptnlWRtNVqdJ3SeNwSbHgAzqMa0Q,3740 +pip/_vendor/requests/hooks.py,sha256=9frYhALsLBkHH76G-HYqvAvssSlu1C1b7L68cAs-E5g,734 +pip/_vendor/requests/models.py,sha256=tvq5Hri4ZuW2oyQYHfoZ5oc688k8DzskE2au5sZWCUE,35530 +pip/_vendor/requests/packages.py,sha256=_ZQDCJTJ8SP3kVWunSqBsRZNPzj2c1WFVqbdr08pz3U,1057 +pip/_vendor/requests/sessions.py,sha256=gbmlsNSi96sIig0mrtHzZAZT_fOIWToe-YnW7v5ptKI,30645 +pip/_vendor/requests/status_codes.py,sha256=iJUAeA25baTdw-6PfD0eF4qhpINDJRJI-yaMqxs4LEI,4322 +pip/_vendor/requests/structures.py,sha256=-IbmhVz06S-5aPSZuUthZ6-6D9XOjRuTXHOabY041XM,2912 +pip/_vendor/requests/utils.py,sha256=xpNppxOSoknLCd_nYKRM-80QrhxkZluQfiH5zOUMji8,32978 +pip/_vendor/resolvelib/LICENSE,sha256=84j9OMrRMRLB3A9mm76A5_hFQe26-3LzAw0sp2QsPJ0,751 +pip/_vendor/resolvelib/__init__.py,sha256=yoX-d4STvwGGCiQRE5cJC9Cter69SgVgqClxOCvSP7M,541 +pip/_vendor/resolvelib/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/resolvelib/__pycache__/providers.cpython-312.pyc,, +pip/_vendor/resolvelib/__pycache__/reporters.cpython-312.pyc,, +pip/_vendor/resolvelib/__pycache__/structs.cpython-312.pyc,, +pip/_vendor/resolvelib/providers.py,sha256=pIWJbIdJJ9GFtNbtwTH0Ia43Vj6hYCEJj2DOLue15FM,8914 +pip/_vendor/resolvelib/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_vendor/resolvelib/reporters.py,sha256=pNJf4nFxLpAeKxlBUi2GEj0a2Ij1nikY0UabTKXesT4,2037 +pip/_vendor/resolvelib/resolvers/__init__.py,sha256=728M3EvmnPbVXS7ExXlv2kMu6b7wEsoPutEfl-uVk_I,640 +pip/_vendor/resolvelib/resolvers/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/resolvelib/resolvers/__pycache__/abstract.cpython-312.pyc,, +pip/_vendor/resolvelib/resolvers/__pycache__/criterion.cpython-312.pyc,, +pip/_vendor/resolvelib/resolvers/__pycache__/exceptions.cpython-312.pyc,, +pip/_vendor/resolvelib/resolvers/__pycache__/resolution.cpython-312.pyc,, +pip/_vendor/resolvelib/resolvers/abstract.py,sha256=CNeQPnpAudY77nmzOkONSmAgRlzIf06X-X9mvRYODms,1543 +pip/_vendor/resolvelib/resolvers/criterion.py,sha256=lcmZGv5sKHOnFD_RzZwvlGSj19MeA-5rCMpdf2Sgw7Y,1768 +pip/_vendor/resolvelib/resolvers/exceptions.py,sha256=ln_jaQtgLlRUSFY627yiHG2gD7AgaXzRKaElFVh7fDQ,1768 +pip/_vendor/resolvelib/resolvers/resolution.py,sha256=3J_zkW-sD3EY-BlNXjyln__njpyH5n0UZJT6uV7CheA,24212 +pip/_vendor/resolvelib/structs.py,sha256=pu-EJiR2IBITr2SQeNPRa0rXhjlStfmO_GEgAhr3004,6420 +pip/_vendor/rich/LICENSE,sha256=3u18F6QxgVgZCj6iOcyHmlpQJxzruYrnAl9I--WNyhU,1056 +pip/_vendor/rich/__init__.py,sha256=dRxjIL-SbFVY0q3IjSMrfgBTHrm1LZDgLOygVBwiYZc,6090 +pip/_vendor/rich/__main__.py,sha256=e_aVC-tDzarWQW9SuZMuCgBr6ODV_iDNV2Wh2xkxOlw,7896 +pip/_vendor/rich/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/__main__.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_cell_widths.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_emoji_codes.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_emoji_replace.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_export_format.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_extension.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_fileno.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_inspect.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_log_render.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_loop.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_null_file.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_palettes.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_pick.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_ratio.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_spinners.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_stack.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_timer.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_win32_console.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_windows.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_windows_renderer.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/_wrap.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/abc.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/align.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/ansi.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/bar.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/box.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/cells.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/color.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/color_triplet.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/columns.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/console.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/constrain.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/containers.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/control.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/default_styles.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/diagnose.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/emoji.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/errors.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/file_proxy.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/filesize.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/highlighter.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/json.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/jupyter.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/layout.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/live.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/live_render.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/logging.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/markup.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/measure.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/padding.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/pager.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/palette.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/panel.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/pretty.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/progress.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/progress_bar.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/prompt.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/protocol.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/region.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/repr.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/rule.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/scope.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/screen.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/segment.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/spinner.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/status.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/style.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/styled.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/syntax.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/table.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/terminal_theme.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/text.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/theme.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/themes.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/traceback.cpython-312.pyc,, +pip/_vendor/rich/__pycache__/tree.cpython-312.pyc,, +pip/_vendor/rich/_cell_widths.py,sha256=fbmeyetEdHjzE_Vx2l1uK7tnPOhMs2X1lJfO3vsKDpA,10209 +pip/_vendor/rich/_emoji_codes.py,sha256=hu1VL9nbVdppJrVoijVshRlcRRe_v3dju3Mmd2sKZdY,140235 +pip/_vendor/rich/_emoji_replace.py,sha256=n-kcetsEUx2ZUmhQrfeMNc-teeGhpuSQ5F8VPBsyvDo,1064 +pip/_vendor/rich/_export_format.py,sha256=RI08pSrm5tBSzPMvnbTqbD9WIalaOoN5d4M1RTmLq1Y,2128 +pip/_vendor/rich/_extension.py,sha256=Xt47QacCKwYruzjDi-gOBq724JReDj9Cm9xUi5fr-34,265 +pip/_vendor/rich/_fileno.py,sha256=HWZxP5C2ajMbHryvAQZseflVfQoGzsKOHzKGsLD8ynQ,799 +pip/_vendor/rich/_inspect.py,sha256=ROT0PLC2GMWialWZkqJIjmYq7INRijQQkoSokWTaAiI,9656 +pip/_vendor/rich/_log_render.py,sha256=1ByI0PA1ZpxZY3CGJOK54hjlq4X-Bz_boIjIqCd8Kns,3225 +pip/_vendor/rich/_loop.py,sha256=hV_6CLdoPm0va22Wpw4zKqM0RYsz3TZxXj0PoS-9eDQ,1236 +pip/_vendor/rich/_null_file.py,sha256=ADGKp1yt-k70FMKV6tnqCqecB-rSJzp-WQsD7LPL-kg,1394 +pip/_vendor/rich/_palettes.py,sha256=cdev1JQKZ0JvlguV9ipHgznTdnvlIzUFDBb0It2PzjI,7063 +pip/_vendor/rich/_pick.py,sha256=evDt8QN4lF5CiwrUIXlOJCntitBCOsI3ZLPEIAVRLJU,423 +pip/_vendor/rich/_ratio.py,sha256=IOtl78sQCYZsmHyxhe45krkb68u9xVz7zFsXVJD-b2Y,5325 +pip/_vendor/rich/_spinners.py,sha256=U2r1_g_1zSjsjiUdAESc2iAMc3i4ri_S8PYP6kQ5z1I,19919 +pip/_vendor/rich/_stack.py,sha256=-C8OK7rxn3sIUdVwxZBBpeHhIzX0eI-VM3MemYfaXm0,351 +pip/_vendor/rich/_timer.py,sha256=zelxbT6oPFZnNrwWPpc1ktUeAT-Vc4fuFcRZLQGLtMI,417 +pip/_vendor/rich/_win32_console.py,sha256=BSaDRIMwBLITn_m0mTRLPqME5q-quGdSMuYMpYeYJwc,22755 +pip/_vendor/rich/_windows.py,sha256=aBwaD_S56SbgopIvayVmpk0Y28uwY2C5Bab1wl3Bp-I,1925 +pip/_vendor/rich/_windows_renderer.py,sha256=t74ZL3xuDCP3nmTp9pH1L5LiI2cakJuQRQleHCJerlk,2783 +pip/_vendor/rich/_wrap.py,sha256=FlSsom5EX0LVkA3KWy34yHnCfLtqX-ZIepXKh-70rpc,3404 +pip/_vendor/rich/abc.py,sha256=ON-E-ZqSSheZ88VrKX2M3PXpFbGEUUZPMa_Af0l-4f0,890 +pip/_vendor/rich/align.py,sha256=dg-7uY0ukMLLlUEsBDRLva22_sQgIJD4BK0dmZHFHug,10324 +pip/_vendor/rich/ansi.py,sha256=Avs1LHbSdcyOvDOdpELZUoULcBiYewY76eNBp6uFBhs,6921 +pip/_vendor/rich/bar.py,sha256=ldbVHOzKJOnflVNuv1xS7g6dLX2E3wMnXkdPbpzJTcs,3263 +pip/_vendor/rich/box.py,sha256=kmavBc_dn73L_g_8vxWSwYJD2uzBXOUFTtJOfpbczcM,10686 +pip/_vendor/rich/cells.py,sha256=KrQkj5-LghCCpJLSNQIyAZjndc4bnEqOEmi5YuZ9UCY,5130 +pip/_vendor/rich/color.py,sha256=3HSULVDj7qQkXUdFWv78JOiSZzfy5y1nkcYhna296V0,18211 +pip/_vendor/rich/color_triplet.py,sha256=3lhQkdJbvWPoLDO-AnYImAWmJvV5dlgYNCVZ97ORaN4,1054 +pip/_vendor/rich/columns.py,sha256=HUX0KcMm9dsKNi11fTbiM_h2iDtl8ySCaVcxlalEzq8,7131 +pip/_vendor/rich/console.py,sha256=t9azZpmRMVU5cphVBZSShNsmBxd2-IAWcTTlhor-E1s,100849 +pip/_vendor/rich/constrain.py,sha256=1VIPuC8AgtKWrcncQrjBdYqA3JVWysu6jZo1rrh7c7Q,1288 +pip/_vendor/rich/containers.py,sha256=c_56TxcedGYqDepHBMTuZdUIijitAQgnox-Qde0Z1qo,5502 +pip/_vendor/rich/control.py,sha256=EUTSUFLQbxY6Zmo_sdM-5Ls323vIHTBfN8TPulqeHUY,6487 +pip/_vendor/rich/default_styles.py,sha256=khQFqqaoDs3bprMqWpHw8nO5UpG2DN6QtuTd6LzZwYc,8257 +pip/_vendor/rich/diagnose.py,sha256=fJl1TItRn19gGwouqTg-8zPUW3YqQBqGltrfPQs1H9w,1025 +pip/_vendor/rich/emoji.py,sha256=Wd4bQubZdSy6-PyrRQNuMHtn2VkljK9uPZPVlu2cmx0,2367 +pip/_vendor/rich/errors.py,sha256=5pP3Kc5d4QJ_c0KFsxrfyhjiPVe7J1zOqSFbFAzcV-Y,642 +pip/_vendor/rich/file_proxy.py,sha256=Tl9THMDZ-Pk5Wm8sI1gGg_U5DhusmxD-FZ0fUbcU0W0,1683 +pip/_vendor/rich/filesize.py,sha256=_iz9lIpRgvW7MNSeCZnLg-HwzbP4GETg543WqD8SFs0,2484 +pip/_vendor/rich/highlighter.py,sha256=G_sn-8DKjM1sEjLG_oc4ovkWmiUpWvj8bXi0yed2LnY,9586 +pip/_vendor/rich/json.py,sha256=vVEoKdawoJRjAFayPwXkMBPLy7RSTs-f44wSQDR2nJ0,5031 +pip/_vendor/rich/jupyter.py,sha256=QyoKoE_8IdCbrtiSHp9TsTSNyTHY0FO5whE7jOTd9UE,3252 +pip/_vendor/rich/layout.py,sha256=ajkSFAtEVv9EFTcFs-w4uZfft7nEXhNzL7ZVdgrT5rI,14004 +pip/_vendor/rich/live.py,sha256=tF3ukAAJZ_N2ZbGclqZ-iwLoIoZ8f0HHUz79jAyJqj8,15180 +pip/_vendor/rich/live_render.py,sha256=It_39YdzrBm8o3LL0kaGorPFg-BfZWAcrBjLjFokbx4,3521 +pip/_vendor/rich/logging.py,sha256=5KaPPSMP9FxcXPBcKM4cGd_zW78PMgf-YbMVnvfSw0o,12468 +pip/_vendor/rich/markup.py,sha256=3euGKP5s41NCQwaSjTnJxus5iZMHjxpIM0W6fCxra38,8451 +pip/_vendor/rich/measure.py,sha256=HmrIJX8sWRTHbgh8MxEay_83VkqNW_70s8aKP5ZcYI8,5305 +pip/_vendor/rich/padding.py,sha256=KVEI3tOwo9sgK1YNSuH__M1_jUWmLZwRVV_KmOtVzyM,4908 +pip/_vendor/rich/pager.py,sha256=SO_ETBFKbg3n_AgOzXm41Sv36YxXAyI3_R-KOY2_uSc,828 +pip/_vendor/rich/palette.py,sha256=lInvR1ODDT2f3UZMfL1grq7dY_pDdKHw4bdUgOGaM4Y,3396 +pip/_vendor/rich/panel.py,sha256=9sQl00hPIqH5G2gALQo4NepFwpP0k9wT-s_gOms5pIc,11157 +pip/_vendor/rich/pretty.py,sha256=gy3S72u4FRg2ytoo7N1ZDWDIvB4unbzd5iUGdgm-8fc,36391 +pip/_vendor/rich/progress.py,sha256=CUc2lkU-X59mVdGfjMCBkZeiGPL3uxdONjhNJF2T7wY,60408 +pip/_vendor/rich/progress_bar.py,sha256=mZTPpJUwcfcdgQCTTz3kyY-fc79ddLwtx6Ghhxfo064,8162 +pip/_vendor/rich/prompt.py,sha256=l0RhQU-0UVTV9e08xW1BbIj0Jq2IXyChX4lC0lFNzt4,12447 +pip/_vendor/rich/protocol.py,sha256=5hHHDDNHckdk8iWH5zEbi-zuIVSF5hbU2jIo47R7lTE,1391 +pip/_vendor/rich/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_vendor/rich/region.py,sha256=rNT9xZrVZTYIXZC0NYn41CJQwYNbR-KecPOxTgQvB8Y,166 +pip/_vendor/rich/repr.py,sha256=5MZJZmONgC6kud-QW-_m1okXwL2aR6u6y-pUcUCJz28,4431 +pip/_vendor/rich/rule.py,sha256=0fNaS_aERa3UMRc3T5WMpN_sumtDxfaor2y3of1ftBk,4602 +pip/_vendor/rich/scope.py,sha256=TMUU8qo17thyqQCPqjDLYpg_UU1k5qVd-WwiJvnJVas,2843 +pip/_vendor/rich/screen.py,sha256=YoeReESUhx74grqb0mSSb9lghhysWmFHYhsbMVQjXO8,1591 +pip/_vendor/rich/segment.py,sha256=otnKeKGEV-WRlQVosfJVeFDcDxAKHpvJ_hLzSu5lumM,24743 +pip/_vendor/rich/spinner.py,sha256=onIhpKlljRHppTZasxO8kXgtYyCHUkpSgKglRJ3o51g,4214 +pip/_vendor/rich/status.py,sha256=kkPph3YeAZBo-X-4wPp8gTqZyU466NLwZBA4PZTTewo,4424 +pip/_vendor/rich/style.py,sha256=W9Ccy8Py8lNICtlfcp-ryzMTuQaGxAU3av7-g5fHu0s,26990 +pip/_vendor/rich/styled.py,sha256=eZNnzGrI4ki_54pgY3Oj0T-x3lxdXTYh4_ryDB24wBU,1258 +pip/_vendor/rich/syntax.py,sha256=eDKIRwl--eZ0Lwo2da2RRtfutXGavrJO61Cl5OkS59U,36371 +pip/_vendor/rich/table.py,sha256=ZmT7V7MMCOYKw7TGY9SZLyYDf6JdM-WVf07FdVuVhTI,40049 +pip/_vendor/rich/terminal_theme.py,sha256=1j5-ufJfnvlAo5Qsi_ACZiXDmwMXzqgmFByObT9-yJY,3370 +pip/_vendor/rich/text.py,sha256=AO7JPCz6-gaN1thVLXMBntEmDPVYFgFNG1oM61_sanU,47552 +pip/_vendor/rich/theme.py,sha256=oNyhXhGagtDlbDye3tVu3esWOWk0vNkuxFw-_unlaK0,3771 +pip/_vendor/rich/themes.py,sha256=0xgTLozfabebYtcJtDdC5QkX5IVUEaviqDUJJh4YVFk,102 +pip/_vendor/rich/traceback.py,sha256=c0WmB_L04_UfZbLaoH982_U_s7eosxKMUiAVmDPdRYU,35861 +pip/_vendor/rich/tree.py,sha256=yWnQ6rAvRGJ3qZGqBrxS2SW2TKBTNrP0SdY8QxOFPuw,9451 +pip/_vendor/tomli/LICENSE,sha256=uAgWsNUwuKzLTCIReDeQmEpuO2GSLCte6S8zcqsnQv4,1072 +pip/_vendor/tomli/__init__.py,sha256=qs0S40oJfkXIQkncdYZzP8xYf0pUJb180xGS3jQPXtc,314 +pip/_vendor/tomli/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/tomli/__pycache__/_parser.cpython-312.pyc,, +pip/_vendor/tomli/__pycache__/_re.cpython-312.pyc,, +pip/_vendor/tomli/__pycache__/_types.cpython-312.pyc,, +pip/_vendor/tomli/_parser.py,sha256=3FFi5lACz9ef4mjYKW4Sw48e15hvdgAOIEvFANUcft8,26232 +pip/_vendor/tomli/_re.py,sha256=n8-Io8ZK1U-F6jzlg7Pabc40hLFJsawE2uNLKH9w7iU,3235 +pip/_vendor/tomli/_types.py,sha256=-GTG2VUqkpxwMqzmVO4F7ybKddIbAnuAHXfmWQcTi3Q,254 +pip/_vendor/tomli/py.typed,sha256=8PjyZ1aVoQpRVvt71muvuq5qE-jTFZkK-GLHkhdebmc,26 +pip/_vendor/tomli_w/LICENSE,sha256=uAgWsNUwuKzLTCIReDeQmEpuO2GSLCte6S8zcqsnQv4,1072 +pip/_vendor/tomli_w/__init__.py,sha256=0F8yDtXx3Uunhm874KrAcP76srsM98y7WyHQwCulZbo,169 +pip/_vendor/tomli_w/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/tomli_w/__pycache__/_writer.cpython-312.pyc,, +pip/_vendor/tomli_w/_writer.py,sha256=dsifFS2xYf1i76mmRyfz9y125xC7Z_HQ845ZKhJsYXs,6961 +pip/_vendor/tomli_w/py.typed,sha256=8PjyZ1aVoQpRVvt71muvuq5qE-jTFZkK-GLHkhdebmc,26 +pip/_vendor/truststore/LICENSE,sha256=M757fo-k_Rmxdg4ajtimaL2rhSyRtpLdQUJLy3Jan8o,1086 +pip/_vendor/truststore/__init__.py,sha256=Bu7kqkmpunhLsj5xCu8gT_25ktoPXcSnwe8VHk1GmJo,1320 +pip/_vendor/truststore/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/truststore/__pycache__/_api.cpython-312.pyc,, +pip/_vendor/truststore/__pycache__/_macos.cpython-312.pyc,, +pip/_vendor/truststore/__pycache__/_openssl.cpython-312.pyc,, +pip/_vendor/truststore/__pycache__/_ssl_constants.cpython-312.pyc,, +pip/_vendor/truststore/__pycache__/_windows.cpython-312.pyc,, +pip/_vendor/truststore/_api.py,sha256=CYJCV5BTfttZYfqY3movdMBE-8az7uhET_LYbKT2Nn4,11413 +pip/_vendor/truststore/_macos.py,sha256=nZlLkOmszUE0g6ryRwBVGY5COzPyudcsiJtDWarM5LQ,20503 +pip/_vendor/truststore/_openssl.py,sha256=zB-SQvJydks7tQ0yIwrP6GD3fQNSSaPiq7zw4yF5T40,2412 +pip/_vendor/truststore/_ssl_constants.py,sha256=NUD4fVKdSD02ri7-db0tnO0VqLP9aHuzmStcW7tAl08,1130 +pip/_vendor/truststore/_windows.py,sha256=rAHyKYD8M7t-bXfG8VgOVa3TpfhVhbt4rZQlO45YuP8,17993 +pip/_vendor/truststore/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_vendor/urllib3/LICENSE.txt,sha256=Ew46ZNX91dCWp1JpRjSn2d8oRGnehuVzIQAmgEHj1oY,1093 +pip/_vendor/urllib3/__init__.py,sha256=JMo1tg1nIV1AeJ2vENC_Txfl0e5h6Gzl9DGVk1rWRbo,6979 +pip/_vendor/urllib3/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/urllib3/__pycache__/_base_connection.cpython-312.pyc,, +pip/_vendor/urllib3/__pycache__/_collections.cpython-312.pyc,, +pip/_vendor/urllib3/__pycache__/_request_methods.cpython-312.pyc,, +pip/_vendor/urllib3/__pycache__/_version.cpython-312.pyc,, +pip/_vendor/urllib3/__pycache__/connection.cpython-312.pyc,, +pip/_vendor/urllib3/__pycache__/connectionpool.cpython-312.pyc,, +pip/_vendor/urllib3/__pycache__/exceptions.cpython-312.pyc,, +pip/_vendor/urllib3/__pycache__/fields.cpython-312.pyc,, +pip/_vendor/urllib3/__pycache__/filepost.cpython-312.pyc,, +pip/_vendor/urllib3/__pycache__/poolmanager.cpython-312.pyc,, +pip/_vendor/urllib3/__pycache__/response.cpython-312.pyc,, +pip/_vendor/urllib3/_base_connection.py,sha256=T1cwH3RhzsrBh6Bz3AOGVDboRsE7veijqZPXXQTR2Rg,5568 +pip/_vendor/urllib3/_collections.py,sha256=UvV7UqtGTSKdvw8N_LxWuEikZLm5gB1zFfTZYH9KhAk,17595 +pip/_vendor/urllib3/_request_methods.py,sha256=gCeF85SO_UU4WoPwYHIoz_tw-eM_EVOkLFp8OFsC7DA,9931 +pip/_vendor/urllib3/_version.py,sha256=vKE8or0mmqgsFpVb7FYms-nNOVCPPAEifgxVrTaPByw,704 +pip/_vendor/urllib3/connection.py,sha256=1ZR2gqfFdIzTYIUwF0K5nftg26hLqU5nr1yHTdKb7WA,42800 +pip/_vendor/urllib3/connectionpool.py,sha256=ZEhudsa8BIubD2M0XoxBBsjxbsXwMgUScH7oQ9i-j1Y,43371 +pip/_vendor/urllib3/contrib/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pip/_vendor/urllib3/contrib/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/urllib3/contrib/__pycache__/pyopenssl.cpython-312.pyc,, +pip/_vendor/urllib3/contrib/__pycache__/socks.cpython-312.pyc,, +pip/_vendor/urllib3/contrib/emscripten/__init__.py,sha256=ZruXaWKVzAEJdqNH3NEh0mrHrw--2VZYb0zX0RonNZA,870 +pip/_vendor/urllib3/contrib/emscripten/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/urllib3/contrib/emscripten/__pycache__/connection.cpython-312.pyc,, +pip/_vendor/urllib3/contrib/emscripten/__pycache__/fetch.cpython-312.pyc,, +pip/_vendor/urllib3/contrib/emscripten/__pycache__/request.cpython-312.pyc,, +pip/_vendor/urllib3/contrib/emscripten/__pycache__/response.cpython-312.pyc,, +pip/_vendor/urllib3/contrib/emscripten/connection.py,sha256=giElsBoUsKVURbZzb8GCrJmqW23Xnvj2aNyQVF42slg,8960 +pip/_vendor/urllib3/contrib/emscripten/emscripten_fetch_worker.js,sha256=z1k3zZ4_hDKd3-tN7wzz8LHjHC2pxN_uu8B3k9D9A3c,3677 +pip/_vendor/urllib3/contrib/emscripten/fetch.py,sha256=5xcd--viFxZd2nBy0aK73dtJ9Tsh1yYZU_SUXwnwibk,23520 +pip/_vendor/urllib3/contrib/emscripten/request.py,sha256=mL28szy1KvE3NJhWor5jNmarp8gwplDU-7gwGZY5g0Q,566 +pip/_vendor/urllib3/contrib/emscripten/response.py,sha256=7oVPENYZHuzEGRtG40HonpH5tAIYHsGcHPbJt2Z0U-Y,9507 +pip/_vendor/urllib3/contrib/pyopenssl.py,sha256=nXZKMoHsi4mPP5K3rh0OdIbxNIf8AZ0mFUEe46G2kec,19750 +pip/_vendor/urllib3/contrib/socks.py,sha256=eB2eWfu8Wz1fn-qvr_qE_dZAceck2Ncv7XQ15DlvVbU,7547 +pip/_vendor/urllib3/exceptions.py,sha256=eeQ77nJjF97bP6SvCK4gmx6BpQZKU8yjvM-AIDwZdX8,9952 +pip/_vendor/urllib3/fields.py,sha256=FCf7UULSkf10cuTRUWTQESzxgl1WT8e2aCy3kfyZins,10829 +pip/_vendor/urllib3/filepost.py,sha256=U8eNZ-mpKKHhrlbHEEiTxxgK16IejhEa7uz42yqA_dI,2388 +pip/_vendor/urllib3/http2/__init__.py,sha256=xzrASH7R5ANRkPJOot5lGnATOq3KKuyXzI42rcnwmqs,1741 +pip/_vendor/urllib3/http2/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/urllib3/http2/__pycache__/connection.cpython-312.pyc,, +pip/_vendor/urllib3/http2/__pycache__/probe.cpython-312.pyc,, +pip/_vendor/urllib3/http2/connection.py,sha256=bHMH6fNvatwXPrKqrcn74yA3pUWcqPDppnK1LcKCbP8,12578 +pip/_vendor/urllib3/http2/probe.py,sha256=nnAkqbhAakOiF75rz7W0udZ38Eeh_uD8fjV74N73FEI,3014 +pip/_vendor/urllib3/poolmanager.py,sha256=2pkDujt-6CTSerSwXfkxTvcM93E2lsNHHb4J_Ae6NNM,23845 +pip/_vendor/urllib3/py.typed,sha256=UaCuPFa3H8UAakbt-5G8SPacldTOGvJv18pPjUJ5gDY,93 +pip/_vendor/urllib3/response.py,sha256=eEj6tX98Zp21lgRC8xAHPdiI5bRdHlkuKUcAjrUyU78,52743 +pip/_vendor/urllib3/util/__init__.py,sha256=-qeS0QceivazvBEKDNFCAI-6ACcdDOE4TMvo7SLNlAQ,1001 +pip/_vendor/urllib3/util/__pycache__/__init__.cpython-312.pyc,, +pip/_vendor/urllib3/util/__pycache__/connection.cpython-312.pyc,, +pip/_vendor/urllib3/util/__pycache__/proxy.cpython-312.pyc,, +pip/_vendor/urllib3/util/__pycache__/request.cpython-312.pyc,, +pip/_vendor/urllib3/util/__pycache__/response.cpython-312.pyc,, +pip/_vendor/urllib3/util/__pycache__/retry.cpython-312.pyc,, +pip/_vendor/urllib3/util/__pycache__/ssl_.cpython-312.pyc,, +pip/_vendor/urllib3/util/__pycache__/ssl_match_hostname.cpython-312.pyc,, +pip/_vendor/urllib3/util/__pycache__/ssltransport.cpython-312.pyc,, +pip/_vendor/urllib3/util/__pycache__/timeout.cpython-312.pyc,, +pip/_vendor/urllib3/util/__pycache__/url.cpython-312.pyc,, +pip/_vendor/urllib3/util/__pycache__/util.cpython-312.pyc,, +pip/_vendor/urllib3/util/__pycache__/wait.cpython-312.pyc,, +pip/_vendor/urllib3/util/connection.py,sha256=JjO722lzHlzLXPTkr9ZWBdhseXnMVjMSb1DJLVrXSnQ,4444 +pip/_vendor/urllib3/util/proxy.py,sha256=seP8-Q5B6bB0dMtwPj-YcZZQ30vHuLqRu-tI0JZ2fzs,1148 +pip/_vendor/urllib3/util/request.py,sha256=p9Ki9eo1tFBO-jqV_7KmmJ60RKqoY2r4ao0SmaHLyOs,8086 +pip/_vendor/urllib3/util/response.py,sha256=vQE639uoEhj1vpjEdxu5lNIhJCSUZkd7pqllUI0BZOA,3374 +pip/_vendor/urllib3/util/retry.py,sha256=WOcIHVaxKf-dVb89lUbpvcpeM7rNYF_vsKsCOKw10Z8,19235 +pip/_vendor/urllib3/util/ssl_.py,sha256=Y9RNkWCIehDxIRvyFnHUjiMlPolm368GYMya2YdDOag,19929 +pip/_vendor/urllib3/util/ssl_match_hostname.py,sha256=Di7DU7zokoltapT_F0Sj21ffYxwaS_cE5apOtwueeyA,5845 +pip/_vendor/urllib3/util/ssltransport.py,sha256=Ez4O8pR_vT8dan_FvqBYS6dgDfBXEMfVfrzcdUoWfi4,8847 +pip/_vendor/urllib3/util/timeout.py,sha256=vsUJRpO0nfKk-y1OKlgFGY1ONJGPgkaZ7B7kruEpVYw,10363 +pip/_vendor/urllib3/util/url.py,sha256=PEDQMypidude0nAZctLLiFK9epN-LPnSH7KpOLLwqH0,15256 +pip/_vendor/urllib3/util/util.py,sha256=j3lbZK1jPyiwD34T8IgJzdWEZVT-4E-0vYIJi9UjeNA,1146 +pip/_vendor/urllib3/util/wait.py,sha256=_ph8IrUR3sqPqi0OopQgJUlH4wzkGeM5CiyA7XGGtmI,4423 +pip/_vendor/vendor.txt,sha256=52c7zlghmshnINutv0knkh1sIT8jY7epMMHgFZTuowI,316 +pip/py.typed,sha256=EBVvvPRTn_eIpz5e5QztSCdrMX7Qwd7VP93RSoIlZ2I,286 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/REQUESTED b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/REQUESTED new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/WHEEL b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/WHEEL new file mode 100644 index 0000000000000000000000000000000000000000..d8b9936dad9ab2513fa6979f411560d3b6b57e37 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/WHEEL @@ -0,0 +1,4 @@ +Wheel-Version: 1.0 +Generator: flit 3.12.0 +Root-Is-Purelib: true +Tag: py3-none-any diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/direct_url.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/direct_url.json new file mode 100644 index 0000000000000000000000000000000000000000..b3f2724feaaa216d10d9de2dbd508cdd1997c4ff --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/direct_url.json @@ -0,0 +1 @@ +{"dir_info": {}, "url": "file:///home/conda/feedstock_root/build_artifacts/pip_1777924007781/work"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/entry_points.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/entry_points.txt new file mode 100644 index 0000000000000000000000000000000000000000..c6436d21fcc6479564ce8581c93e30e2cc60a096 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/entry_points.txt @@ -0,0 +1,4 @@ +[console_scripts] +pip=pip._internal.cli.main:main +pip3=pip._internal.cli.main:main + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/AUTHORS.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/AUTHORS.txt new file mode 100644 index 0000000000000000000000000000000000000000..f6291c9bfc891a10edff3379f4f731c424ad2f2d --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/AUTHORS.txt @@ -0,0 +1,867 @@ +@Switch01 +A_Rog +Aakanksha Agrawal +Aarni Koskela +Abhinav Sagar +ABHYUDAY PRATAP SINGH +abs51295 +AceGentile +Adam Chainz +Adam Tse +Adam Turner +Adam Wentz +admin +Adolfo Ochagavía +Adrien Morison +Agus +ahayrapetyan +Ahilya +AinsworthK +Akash Srivastava +Alan Yee +Albert Tugushev +Albert-Guan +albertg +Alberto Sottile +Aleks Bunin +Ales Erjavec +Alessandro Molina +Alethea Flowers +Alex Gaynor +Alex Grönholm +Alex Hedges +Alex Loosley +Alex Morega +Alex Stachowiak +Alexander Regueiro +Alexander Shtyrov +Alexandre Conrad +Alexey Popravka +Aleš Erjavec +Alli +Aman +Ami Fischman +Ananya Maiti +Anatoly Techtonik +Anders Kaseorg +Andre Aguiar +Andreas Lutro +Andrei Geacar +Andrew Gaul +Andrew Shymanel +Andrey Bienkowski +Andrey Bulgakov +Andrés Delfino +Andy Freeland +Andy Kluger +Ani Hayrapetyan +Aniruddha Basak +Anish Tambe +Anrs Hu +Anthony Sottile +Antoine Lambert +Antoine Musso +Anton Ovchinnikov +Anton Patrushev +Anton Zelenov +Antonio Alvarado Hernandez +Antony Lee +Antti Kaihola +Anubhav Patel +Anudit Nagar +Anuj Godase +AQNOUCH Mohammed +AraHaan +arena +arenasys +Arindam Choudhury +Armin Ronacher +Arnon Yaari +Artem +Arun Babu Neelicattu +Ashley Manton +Ashwin Ramaswami +atse +Atsushi Odagiri +Avinash Karhana +Avner Cohen +Awit (Ah-Wit) Ghirmai +Baptiste Mispelon +Barney Gale +barneygale +Bartek Ogryczak +Bastian Venthur +Ben Bodenmiller +Ben Darnell +Ben Hoyt +Ben Mares +Ben Rosser +Bence Nagy +Benjamin Peterson +Benjamin VanEvery +Benoit Pierre +Berker Peksag +Bernard +Bernard Tyers +Bernardo B. Marques +Bernhard M. Wiedemann +Bertil Hatt +Bhavam Vidyarthi +Blazej Michalik +Bogdan Opanchuk +BorisZZZ +Brad Erickson +Bradley Ayers +Bradley Reynolds +Branch Vincent +Brandon L. Reiss +Brandt Bucher +Brannon Dorsey +Brett Randall +Brett Rosen +Brian Cristante +Brian Rosner +briantracy +BrownTruck +Bruno Oliveira +Bruno Renié +Bruno S +Bstrdsmkr +Buck Golemon +burrows +Bussonnier Matthias +bwoodsend +c22 +Caleb Brown +Caleb Martinez +Calvin Smith +Carl Meyer +Carlos Liam +Carol Willing +Carter Thayer +Cass +Chandrasekhar Atina +Charlie Marsh +charwick +Chih-Hsuan Yen +Chris Brinker +Chris Hunt +Chris Jerdonek +Chris Kuehl +Chris Markiewicz +Chris McDonough +Chris Pawley +Chris Pryer +Chris Wolfe +Christian Clauss +Christian Heimes +Christian Oudard +Christoph Reiter +Christopher Hunt +Christopher Snyder +chrysle +cjc7373 +Clark Boylan +Claudio Jolowicz +Clay McClure +Cody +Cody Soyland +Colin Watson +Collin Anderson +Connor Osborn +Cooper Lees +Cooper Ry Lees +Cory Benfield +Cory Wright +Craig Kerstiens +Cristian Sorinel +Cristina +Cristina Muñoz +ctg123 +Curtis Doty +cytolentino +Daan De Meyer +Dale +Damian +Damian Quiroga +Damian Shaw +Dan Black +Dan Savilonis +Dan Sully +Dane Hillard +daniel +Daniel Collins +Daniel Hahler +Daniel Hollas +Daniel Holth +Daniel Jost +Daniel Katz +Daniel Shaulov +Daniele Esposti +Daniele Nicolodi +Daniele Procida +Daniil Konovalenko +Danny Hermes +Danny McClanahan +Darren Kavanagh +Dav Clark +Dave Abrahams +Dave Jones +David Aguilar +David Black +David Bordeynik +David Caro +David D Lowe +David Evans +David Hewitt +David Linke +David Poggi +David Poznik +David Pursehouse +David Runge +David Tucker +David Wales +Davidovich +ddelange +Deepak Sharma +Deepyaman Datta +Denis Roussel (ACSONE) +Denise Yu +dependabot[bot] +derwolfe +Desetude +developer +Devesh Kumar +Devesh Kumar Singh +devsagul +Diego Caraballo +Diego Ramirez +DiegoCaraballo +Dimitri Merejkowsky +Dimitri Papadopoulos +Dimitri Papadopoulos Orfanos +Dirk Stolle +dkjsone +Dmitrii Sutiagin +Dmitry Gladkov +Dmitry Volodin +Domen Kožar +Dominic Davis-Foster +Donald Stufft +Dongweiming +doron zarhi +Dos Moonen +Douglas Thor +DrFeathers +Dustin Ingram +Dustin Rodrigues +Dwayne Bailey +Ed Morley +Edgar Ramírez +Edgar Ramírez Mondragón +Ee Durbin +Efflam Lemaillet +efflamlemaillet +Eitan Adler +ekristina +elainechan +Eli Schwartz +Elisha Hollander +Ellen Marie Dash +Emil Burzo +Emil Styrke +Emmanuel Arias +Endoh Takanao +enoch +Erdinc Mutlu +Eric Cousineau +Eric Gillingham +Eric Hanchrow +Eric Hopper +Erik M. Bray +Erik Rose +Erwin Janssen +Eugene Vereshchagin +everdimension +Federico +Felipe Peter +Felix Yan +fiber-space +Filip Kokosiński +Filipe Laíns +Finn Womack +finnagin +Flavio Amurrio +Florian Briand +Florian Rathgeber +Francesco +Francesco Montesano +Fredrik Orderud +Fredrik Roubert +Frost Ming +Gabriel Curio +Gabriel de Perthuis +Garry Polley +gavin +gdanielson +Gene Wood +Geoffrey Sneddon +George Margaritis +George Song +Georgi Valkov +Georgy Pchelkin +Gertjan van Zwieten +ghost +Giancarlo Cicellyn Comneno +Giftlin Rajaiah +gizmoguy1 +gkdoc +Godefroid Chapelle +Gopinath M +GOTO Hayato +gousaiyang +gpiks +Greg Roodt +Greg Ward +Guido Diepen +Guilherme Espada +Guillaume Seguin +gutsytechster +Guy Rozendorn +Guy Tuval +gzpan123 +Hanjun Kim +Hari Charan +Harsh Vardhan +Harsha Sai +harupy +Harutaka Kawamura +Hasan-8326 +hauntsaninja +Henrich Hartzer +Henry Schreiner +Herbert Pfennig +Holly Stotelmyer +Honnix +Hsiaoming Yang +Hugo Lopes Tavares +Hugo van Kemenade +Hugues Bruant +Hynek Schlawack +iamsrp-deshaw +Ian Bicking +Ian Cordasco +Ian Lee +Ian Stapleton Cordasco +Ian Wienand +Igor Kuzmitshov +Igor Sobreira +Ikko Ashimine +Ilan Schnell +Illia Volochii +Ilya Abdolmanafi +Ilya Baryshev +Inada Naoki +Ionel Cristian Mărieș +Ionel Maries Cristian +Itamar Turner-Trauring +iTrooz +Ivan Pozdeev +J. Nick Koston +Jacob Kim +Jacob Walls +Jaime Sanz +Jake Lishman +jakirkham +Jakub Kuczys +Jakub Stasiak +Jakub Vysoky +Jakub Wilk +James +James Cleveland +James Curtin +James Firth +James Gerity +James Polley +Jan Pokorný +Jannis Leidel +Jarek Potiuk +jarondl +Jason Curtis +Jason R. Coombs +JasonMo +JasonMo1 +Jay Graves +Jean Abou Samra +Jean-Christophe Fillion-Robin +Jeff Barber +Jeff Dairiki +Jeff Widman +Jelmer Vernooij +jenix21 +Jeremy Fleischman +Jeremy Stanley +Jeremy Zafran +Jesse Rittner +Jiashuo Li +Jim Fisher +Jim Garrison +Jinzhe Zeng +Jiun Bae +Jivan Amara +Joa +Joe Bylund +Joe Michelini +Johannes Altmanninger +John Paton +John Sirois +John T. Wodder II +John-Scott Atlakson +johnthagen +Jon Banafato +Jon Dufresne +Jon Parise +Jonas Nockert +Jonathan Herbert +Joonatan Partanen +Joost Molenaar +Jorge Niedbalski +Joseph Bylund +Joseph Long +Josh Bronson +Josh Cannon +Josh Hansen +Josh Schneier +Joshua +JoshuaPerdue +Jost Migenda +Juan Luis Cano Rodríguez +Juanjo Bazán +Judah Rand +Julian Berman +Julian Gethmann +Julien Demoor +Julien Stephan +July Tikhonov +Jussi Kukkonen +Justin van Heek +jwg4 +Jyrki Pulliainen +Kai Chen +Kai Mueller +Kamal Bin Mustafa +Karolina Surma +kasium +kaustav haldar +Kaz Nishimura +keanemind +Keith Maxwell +Kelsey Hightower +Kenneth Belitzky +Kenneth Reitz +Kevin Burke +Kevin Carter +Kevin Frommelt +Kevin R Patterson +Kevin Turcios +Kexuan Sun +Kit Randel +Klaas van Schelven +KOLANICH +konstin +kpinc +Krishan Bhasin +Krishna Oza +Kumar McMillan +Kuntal Majumder +Kurt McKee +Kyle Persohn +lakshmanaram +Laszlo Kiss-Kollar +Laurent Bristiel +Laurent LAPORTE +Laurie O +Laurie Opperman +layday +Leon Sasson +Lev Givon +Lincoln de Sousa +Lipis +lorddavidiii +Loren Carvalho +Lucas Cimon +Ludovic Gasc +Luis Medel +Lukas Geiger +Lukas Juhrich +Luke Macken +Luo Jiebin +luojiebin +luz.paz +László Kiss Kollár +M00nL1ght +MajorTanya +Malcolm Smith +Marc Abramowitz +Marc Tamlyn +Marcus Smith +Mariatta +Mark Kohler +Mark McLoughlin +Mark Williams +Markus Hametner +Martey Dodoo +Martin Fischer +Martin Häcker +Martin Pavlasek +Masaki +Masklinn +Matej Stuchlik +Mateusz Sokół +Mathew Jennings +Mathieu Bridon +Mathieu Kniewallner +Matt Bacchi +Matt Good +Matt Maker +Matt Robenolt +Matt Wozniski +matthew +Matthew Einhorn +Matthew Feickert +Matthew Gilliard +Matthew Hughes +Matthew Iversen +Matthew Treinish +Matthew Trumbell +Matthew Willson +Matthias Bussonnier +mattip +Maurits van Rees +Max W Chase +Maxim Kurnikov +Maxime Rouyrre +mayeut +mbaluna +Md Sujauddin Sekh +mdebi +Meet Vasita +memoselyk +meowmeowcat +Michael +Michael Aquilina +Michael E. Karpeles +Michael Klich +Michael Mintz +Michael Williamson +michaelpacer +Michał Górny +Mickaël Schoentgen +Miguel Araujo Perez +Mihir Singh +Mike +Mike Hendricks +Min RK +MinRK +Miro Hrončok +Monica Baluna +montefra +Monty Taylor +morotti +mrKazzila +Muha Ajjan +MUTHUSRIHEMADHARSHINI S A +Nadav Wexler +Nahuel Ambrosini +Nate Coraor +Nate Prewitt +Nathan Houghton +Nathaniel J. Smith +Nehal J Wani +Neil Botelho +Nguyễn Gia Phong +Nicholas Serra +Nick Coghlan +Nick Stenning +Nick Timkovich +Nicolas Bock +Nicole Harris +Nikhil Benesch +Nikhil Ladha +Nikita Chepanov +Nikolay Korolev +Nipunn Koorapati +Nitesh Sharma +Niyas Sait +Noah +Noah Gorny +Norbert Manthey +Nothing-991 +Nowell Strite +NtaleGrey +nucccc +nvdv +OBITORASU +Ofek Lev +ofrinevo +Oleg Burnaev +Oliver Freund +Oliver Jeeves +Oliver Mannion +Oliver Tonnhofer +Olivier Girardot +Olivier Grisel +Ollie Rutherfurd +OMOTO Kenji +Omry Yadan +onlinejudge95 +Oren Held +Oscar Benjamin +oxygen dioxide +Oz N Tiram +Pachwenko +Paresh Joshi +Patrick Dubroy +Patrick Jenkins +Patrick Lawson +patricktokeeffe +Patrik Kopkan +Paul Ganssle +Paul Kehrer +Paul Moore +Paul Nasrat +Paul Oswald +Paul van der Linden +Paulus Schoutsen +Pavel Safronov +Pavithra Eswaramoorthy +Pawel Jasinski +Paweł Szramowski +Pekka Klärck +Peter Gessler +Peter Lisák +Peter Shen +Peter Waller +Petr Viktorin +petr-tik +Phaneendra Chiruvella +Phil Elson +Phil Freo +Phil Pennock +Phil Whelan +Philip Jägenstedt +Philip Molloy +Philippe Ombredanne +Pi Delport +Pierre-Yves Rofes +Pieter Degroote +pip +Prabakaran Kumaresshan +Prabhjyotsing Surjit Singh Sodhi +Prabhu Marappan +Pradyun Gedam +Prashant Sharma +Pratik Mallya +pre-commit-ci[bot] +Preet Thakkar +Preston Holmes +Przemek Wrzos +Pulkit Goyal +q0w +Qiangning Hong +Qiming Xu +qraqras +Quentin Lee +Quentin Pradet +R. David Murray +Rafael Caricio +Ralf Schmitt +Ran Benita +Randy Döring +Razzi Abuissa +rdb +Reece Dunham +Remi Rampin +Rene Dudfield +Riccardo Magliocchetti +Riccardo Schirone +Richard Jones +Richard Si +Ricky Ng-Adam +Rishi +rmorotti +RobberPhex +Robert Collins +Robert McGibbon +Robert Pollak +Robert T. McGibbon +robin elisha robinson +Rodney, Tiara +Roey Berman +Rohan Jain +Roman Bogorodskiy +Roman Donchenko +Romuald Brunet +ronaudinho +Ronny Pfannschmidt +Rory McCann +Ross Brattain +Roy Wellington Ⅳ +Ruairidh MacLeod +Russell Keith-Magee +Ryan Shepherd +Ryan Wooden +ryneeverett +Ryuma Asai +S. Guliaev +Sachi King +Salvatore Rinchiera +sandeepkiran-js +Sander Van Balen +Savio Jomton +schlamar +Scott Kitterman +Sean +seanj +Sebastian Jordan +Sebastian Schaetz +Segev Finer +SeongSoo Cho +Sepehr Rasouli +sepehrrasooli +Sergey Vasilyev +Seth Michael Larson +Seth Woodworth +Shahar Epstein +Shantanu +shenxianpeng +shireenrao +Shivansh-007 +Shixian Sheng +Shlomi Fish +Shovan Maity +Shubham Nagure +Simeon Visser +Simon Cross +Simon Pichugin +sinoroc +sinscary +snook92 +socketubs +Sorin Sbarnea +Srinivas Nyayapati +Srishti Hegde +Stavros Korokithakis +Stefan Scherfke +Stefano Rivera +Stephan Erb +Stephane Chazelas +Stephen Payne +Stephen Rosen +stepshal +Steve (Gadget) Barnes +Steve Barnes +Steve Dower +Steve Kowalik +Steven Myint +Steven Silvester +stonebig +studioj +Stéphane Bidoul +Stéphane Bidoul (ACSONE) +Stéphane Klein +Sumana Harihareswara +Surbhi Sharma +Sviatoslav Sydorenko +Sviatoslav Sydorenko (Святослав Сидоренко) +Swat009 +Sylvain +Takayuki SHIMIZUKAWA +Taneli Hukkinen +tbeswick +Terrance +Thiago +Thijs Triemstra +Thomas Fenzl +Thomas Grainger +Thomas Guettler +Thomas Johansson +Thomas Kluyver +Thomas Smith +Thomas VINCENT +Tim D. Smith +Tim Gates +Tim Harder +Tim Heap +tim smith +tinruufu +Tobias Hermann +Tom Forbes +Tom Freudenheim +Tom V +Tomas Hrnciar +Tomas Orsava +Tomer Chachamu +Tommi Enenkel | AnB +Tomáš Hrnčiar +Tony Beswick +Tony Narlock +Tony Zhaocheng Tan +TonyBeswick +toonarmycaptain +Toshio Kuratomi +toxinu +Travis Swicegood +Tushar Sadhwani +Tzu-ping Chung +Valentin Haenel +Victor Stinner +victorvpaulo +Vikram - Google +Viktor Szépe +Ville Skyttä +Vinay Sajip +Vincent Fazio +Vincent Philippon +Vinicyus Macedo +Vipul Kumar +Vitaly Babiy +Vladimir Fokow +Vladimir Rutsky +W. Trevor King +Weida Hong +Wil Tan +Wilfred Hughes +William Edwards +William ML Leslie +William T Olson +William Woodruff +Wilson Mo +wim glenn +Winson Luk +Wolfgang Maier +Wu Zhenyu +XAMES3 +Xavier Fernandez +Xianpeng Shen +xoviat +xtreak +YAMAMOTO Takashi +Yash +Yashraj +Yen Chi Hsuan +Yeray Diaz Diaz +Yoval P +Yu Jian +Yuan Jing Vincent Yan +Yuki Kobayashi +Yusuke Hayashi +Zachary Ware +zackzack38 +Zearin +Zhiping Deng +ziebam +Zvezdan Petkovic +Łukasz Langa +Роман Донченко +Семён Марьясин diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/LICENSE.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/LICENSE.txt new file mode 100644 index 0000000000000000000000000000000000000000..8e7b65eaf628360e6f32f4140fcdd7ec7c2b7077 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/LICENSE.txt @@ -0,0 +1,20 @@ +Copyright (c) 2008-present The pip developers (see AUTHORS.txt file) + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/cachecontrol/LICENSE.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/cachecontrol/LICENSE.txt new file mode 100644 index 0000000000000000000000000000000000000000..d8b3b56d361cfaa04de6304c96c328f27266f74e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/cachecontrol/LICENSE.txt @@ -0,0 +1,13 @@ +Copyright 2012-2021 Eric Larson + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/certifi/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/certifi/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..62b076cdee58ec8f34034141ba0befd9015b0c7e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/certifi/LICENSE @@ -0,0 +1,20 @@ +This package contains a modified version of ca-bundle.crt: + +ca-bundle.crt -- Bundle of CA Root Certificates + +This is a bundle of X.509 certificates of public Certificate Authorities +(CA). These were automatically extracted from Mozilla's root certificates +file (certdata.txt). This file can be found in the mozilla source tree: +https://hg.mozilla.org/mozilla-central/file/tip/security/nss/lib/ckfw/builtins/certdata.txt +It contains the certificates in PEM format and therefore +can be directly used with curl / libcurl / php_curl, or with +an Apache+mod_ssl webserver for SSL client authentication. +Just configure this file as the SSLCACertificateFile.# + +***** BEGIN LICENSE BLOCK ***** +This Source Code Form is subject to the terms of the Mozilla Public License, +v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain +one at http://mozilla.org/MPL/2.0/. + +***** END LICENSE BLOCK ***** +@(#) $RCSfile: certdata.txt,v $ $Revision: 1.80 $ $Date: 2011/11/03 15:11:58 $ diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/distlib/LICENSE.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/distlib/LICENSE.txt new file mode 100644 index 0000000000000000000000000000000000000000..c31ac56d772f7061c8b42f0ee96063b7a94a4859 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/distlib/LICENSE.txt @@ -0,0 +1,284 @@ +A. HISTORY OF THE SOFTWARE +========================== + +Python was created in the early 1990s by Guido van Rossum at Stichting +Mathematisch Centrum (CWI, see http://www.cwi.nl) in the Netherlands +as a successor of a language called ABC. Guido remains Python's +principal author, although it includes many contributions from others. + +In 1995, Guido continued his work on Python at the Corporation for +National Research Initiatives (CNRI, see http://www.cnri.reston.va.us) +in Reston, Virginia where he released several versions of the +software. + +In May 2000, Guido and the Python core development team moved to +BeOpen.com to form the BeOpen PythonLabs team. In October of the same +year, the PythonLabs team moved to Digital Creations (now Zope +Corporation, see http://www.zope.com). In 2001, the Python Software +Foundation (PSF, see http://www.python.org/psf/) was formed, a +non-profit organization created specifically to own Python-related +Intellectual Property. Zope Corporation is a sponsoring member of +the PSF. + +All Python releases are Open Source (see http://www.opensource.org for +the Open Source Definition). Historically, most, but not all, Python +releases have also been GPL-compatible; the table below summarizes +the various releases. + + Release Derived Year Owner GPL- + from compatible? (1) + + 0.9.0 thru 1.2 1991-1995 CWI yes + 1.3 thru 1.5.2 1.2 1995-1999 CNRI yes + 1.6 1.5.2 2000 CNRI no + 2.0 1.6 2000 BeOpen.com no + 1.6.1 1.6 2001 CNRI yes (2) + 2.1 2.0+1.6.1 2001 PSF no + 2.0.1 2.0+1.6.1 2001 PSF yes + 2.1.1 2.1+2.0.1 2001 PSF yes + 2.2 2.1.1 2001 PSF yes + 2.1.2 2.1.1 2002 PSF yes + 2.1.3 2.1.2 2002 PSF yes + 2.2.1 2.2 2002 PSF yes + 2.2.2 2.2.1 2002 PSF yes + 2.2.3 2.2.2 2003 PSF yes + 2.3 2.2.2 2002-2003 PSF yes + 2.3.1 2.3 2002-2003 PSF yes + 2.3.2 2.3.1 2002-2003 PSF yes + 2.3.3 2.3.2 2002-2003 PSF yes + 2.3.4 2.3.3 2004 PSF yes + 2.3.5 2.3.4 2005 PSF yes + 2.4 2.3 2004 PSF yes + 2.4.1 2.4 2005 PSF yes + 2.4.2 2.4.1 2005 PSF yes + 2.4.3 2.4.2 2006 PSF yes + 2.4.4 2.4.3 2006 PSF yes + 2.5 2.4 2006 PSF yes + 2.5.1 2.5 2007 PSF yes + 2.5.2 2.5.1 2008 PSF yes + 2.5.3 2.5.2 2008 PSF yes + 2.6 2.5 2008 PSF yes + 2.6.1 2.6 2008 PSF yes + 2.6.2 2.6.1 2009 PSF yes + 2.6.3 2.6.2 2009 PSF yes + 2.6.4 2.6.3 2009 PSF yes + 2.6.5 2.6.4 2010 PSF yes + 3.0 2.6 2008 PSF yes + 3.0.1 3.0 2009 PSF yes + 3.1 3.0.1 2009 PSF yes + 3.1.1 3.1 2009 PSF yes + 3.1.2 3.1 2010 PSF yes + 3.2 3.1 2010 PSF yes + +Footnotes: + +(1) GPL-compatible doesn't mean that we're distributing Python under + the GPL. All Python licenses, unlike the GPL, let you distribute + a modified version without making your changes open source. The + GPL-compatible licenses make it possible to combine Python with + other software that is released under the GPL; the others don't. + +(2) According to Richard Stallman, 1.6.1 is not GPL-compatible, + because its license has a choice of law clause. According to + CNRI, however, Stallman's lawyer has told CNRI's lawyer that 1.6.1 + is "not incompatible" with the GPL. + +Thanks to the many outside volunteers who have worked under Guido's +direction to make these releases possible. + + +B. TERMS AND CONDITIONS FOR ACCESSING OR OTHERWISE USING PYTHON +=============================================================== + +PYTHON SOFTWARE FOUNDATION LICENSE VERSION 2 +-------------------------------------------- + +1. This LICENSE AGREEMENT is between the Python Software Foundation +("PSF"), and the Individual or Organization ("Licensee") accessing and +otherwise using this software ("Python") in source or binary form and +its associated documentation. + +2. Subject to the terms and conditions of this License Agreement, PSF hereby +grants Licensee a nonexclusive, royalty-free, world-wide license to reproduce, +analyze, test, perform and/or display publicly, prepare derivative works, +distribute, and otherwise use Python alone or in any derivative version, +provided, however, that PSF's License Agreement and PSF's notice of copyright, +i.e., "Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 +Python Software Foundation; All Rights Reserved" are retained in Python alone or +in any derivative version prepared by Licensee. + +3. In the event Licensee prepares a derivative work that is based on +or incorporates Python or any part thereof, and wants to make +the derivative work available to others as provided herein, then +Licensee hereby agrees to include in any such work a brief summary of +the changes made to Python. + +4. PSF is making Python available to Licensee on an "AS IS" +basis. PSF MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR +IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, PSF MAKES NO AND +DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS +FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF PYTHON WILL NOT +INFRINGE ANY THIRD PARTY RIGHTS. + +5. PSF SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON +FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS AS +A RESULT OF MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON, +OR ANY DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF. + +6. This License Agreement will automatically terminate upon a material +breach of its terms and conditions. + +7. Nothing in this License Agreement shall be deemed to create any +relationship of agency, partnership, or joint venture between PSF and +Licensee. This License Agreement does not grant permission to use PSF +trademarks or trade name in a trademark sense to endorse or promote +products or services of Licensee, or any third party. + +8. By copying, installing or otherwise using Python, Licensee +agrees to be bound by the terms and conditions of this License +Agreement. + + +BEOPEN.COM LICENSE AGREEMENT FOR PYTHON 2.0 +------------------------------------------- + +BEOPEN PYTHON OPEN SOURCE LICENSE AGREEMENT VERSION 1 + +1. This LICENSE AGREEMENT is between BeOpen.com ("BeOpen"), having an +office at 160 Saratoga Avenue, Santa Clara, CA 95051, and the +Individual or Organization ("Licensee") accessing and otherwise using +this software in source or binary form and its associated +documentation ("the Software"). + +2. Subject to the terms and conditions of this BeOpen Python License +Agreement, BeOpen hereby grants Licensee a non-exclusive, +royalty-free, world-wide license to reproduce, analyze, test, perform +and/or display publicly, prepare derivative works, distribute, and +otherwise use the Software alone or in any derivative version, +provided, however, that the BeOpen Python License is retained in the +Software, alone or in any derivative version prepared by Licensee. + +3. BeOpen is making the Software available to Licensee on an "AS IS" +basis. BEOPEN MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR +IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, BEOPEN MAKES NO AND +DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS +FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF THE SOFTWARE WILL NOT +INFRINGE ANY THIRD PARTY RIGHTS. + +4. BEOPEN SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF THE +SOFTWARE FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS +AS A RESULT OF USING, MODIFYING OR DISTRIBUTING THE SOFTWARE, OR ANY +DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF. + +5. This License Agreement will automatically terminate upon a material +breach of its terms and conditions. + +6. This License Agreement shall be governed by and interpreted in all +respects by the law of the State of California, excluding conflict of +law provisions. Nothing in this License Agreement shall be deemed to +create any relationship of agency, partnership, or joint venture +between BeOpen and Licensee. This License Agreement does not grant +permission to use BeOpen trademarks or trade names in a trademark +sense to endorse or promote products or services of Licensee, or any +third party. As an exception, the "BeOpen Python" logos available at +http://www.pythonlabs.com/logos.html may be used according to the +permissions granted on that web page. + +7. By copying, installing or otherwise using the software, Licensee +agrees to be bound by the terms and conditions of this License +Agreement. + + +CNRI LICENSE AGREEMENT FOR PYTHON 1.6.1 +--------------------------------------- + +1. This LICENSE AGREEMENT is between the Corporation for National +Research Initiatives, having an office at 1895 Preston White Drive, +Reston, VA 20191 ("CNRI"), and the Individual or Organization +("Licensee") accessing and otherwise using Python 1.6.1 software in +source or binary form and its associated documentation. + +2. Subject to the terms and conditions of this License Agreement, CNRI +hereby grants Licensee a nonexclusive, royalty-free, world-wide +license to reproduce, analyze, test, perform and/or display publicly, +prepare derivative works, distribute, and otherwise use Python 1.6.1 +alone or in any derivative version, provided, however, that CNRI's +License Agreement and CNRI's notice of copyright, i.e., "Copyright (c) +1995-2001 Corporation for National Research Initiatives; All Rights +Reserved" are retained in Python 1.6.1 alone or in any derivative +version prepared by Licensee. Alternately, in lieu of CNRI's License +Agreement, Licensee may substitute the following text (omitting the +quotes): "Python 1.6.1 is made available subject to the terms and +conditions in CNRI's License Agreement. This Agreement together with +Python 1.6.1 may be located on the Internet using the following +unique, persistent identifier (known as a handle): 1895.22/1013. This +Agreement may also be obtained from a proxy server on the Internet +using the following URL: http://hdl.handle.net/1895.22/1013". + +3. In the event Licensee prepares a derivative work that is based on +or incorporates Python 1.6.1 or any part thereof, and wants to make +the derivative work available to others as provided herein, then +Licensee hereby agrees to include in any such work a brief summary of +the changes made to Python 1.6.1. + +4. CNRI is making Python 1.6.1 available to Licensee on an "AS IS" +basis. CNRI MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR +IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, CNRI MAKES NO AND +DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS +FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF PYTHON 1.6.1 WILL NOT +INFRINGE ANY THIRD PARTY RIGHTS. + +5. CNRI SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON +1.6.1 FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS AS +A RESULT OF MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON 1.6.1, +OR ANY DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF. + +6. This License Agreement will automatically terminate upon a material +breach of its terms and conditions. + +7. This License Agreement shall be governed by the federal +intellectual property law of the United States, including without +limitation the federal copyright law, and, to the extent such +U.S. federal law does not apply, by the law of the Commonwealth of +Virginia, excluding Virginia's conflict of law provisions. +Notwithstanding the foregoing, with regard to derivative works based +on Python 1.6.1 that incorporate non-separable material that was +previously distributed under the GNU General Public License (GPL), the +law of the Commonwealth of Virginia shall govern this License +Agreement only as to issues arising under or with respect to +Paragraphs 4, 5, and 7 of this License Agreement. Nothing in this +License Agreement shall be deemed to create any relationship of +agency, partnership, or joint venture between CNRI and Licensee. This +License Agreement does not grant permission to use CNRI trademarks or +trade name in a trademark sense to endorse or promote products or +services of Licensee, or any third party. + +8. By clicking on the "ACCEPT" button where indicated, or by copying, +installing or otherwise using Python 1.6.1, Licensee agrees to be +bound by the terms and conditions of this License Agreement. + + ACCEPT + + +CWI LICENSE AGREEMENT FOR PYTHON 0.9.0 THROUGH 1.2 +-------------------------------------------------- + +Copyright (c) 1991 - 1995, Stichting Mathematisch Centrum Amsterdam, +The Netherlands. 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 Stichting Mathematisch +Centrum or CWI not be used in advertising or publicity pertaining to +distribution of the software without specific, written prior +permission. + +STICHTING MATHEMATISCH CENTRUM DISCLAIMS ALL WARRANTIES WITH REGARD TO +THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND +FITNESS, IN NO EVENT SHALL STICHTING MATHEMATISCH CENTRUM 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. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/distro/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/distro/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..e06d2081865a766a8668acc12878f98b27fc9ea0 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/distro/LICENSE @@ -0,0 +1,202 @@ +Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "{}" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright {yyyy} {name of copyright owner} + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/idna/LICENSE.md b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/idna/LICENSE.md new file mode 100644 index 0000000000000000000000000000000000000000..256ba90cd91190a6c980bd44663dc51c201c14d3 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/idna/LICENSE.md @@ -0,0 +1,31 @@ +BSD 3-Clause License + +Copyright (c) 2013-2025, Kim Davies and contributors. +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + +1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + +3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED +TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/msgpack/COPYING b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/msgpack/COPYING new file mode 100644 index 0000000000000000000000000000000000000000..f067af3aae15a5b494f0eeb15a7064c176e30fd5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/msgpack/COPYING @@ -0,0 +1,14 @@ +Copyright (C) 2008-2011 INADA Naoki + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..6f62d44e4ef733c0e713afcd2371fed7f2b3de67 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE @@ -0,0 +1,3 @@ +This software is made available under the terms of *either* of the licenses +found in LICENSE.APACHE or LICENSE.BSD. Contributions to this software is made +under the terms of *both* these licenses. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE.APACHE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE.APACHE new file mode 100644 index 0000000000000000000000000000000000000000..f433b1a53f5b830a205fd2df78e2b34974656c7b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE.APACHE @@ -0,0 +1,177 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE.BSD b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE.BSD new file mode 100644 index 0000000000000000000000000000000000000000..42ce7b75c92fb01a3f6ed17eea363f756b7da582 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/packaging/LICENSE.BSD @@ -0,0 +1,23 @@ +Copyright (c) Donald Stufft and individual contributors. +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/pkg_resources/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/pkg_resources/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..1bb5a44356f00884a71ceeefd24ded6caaba2418 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/pkg_resources/LICENSE @@ -0,0 +1,17 @@ +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to +deal in the Software without restriction, including without limitation the +rights to use, copy, modify, merge, publish, distribute, sublicense, and/or +sell copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS +IN THE SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/platformdirs/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/platformdirs/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..f35fed9191b1142ddaada8a96de4a9461c5d796c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/platformdirs/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2010-202x The platformdirs developers + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/pygments/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/pygments/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..446a1a805c8a949579fb8a9799f2bec7777349dc --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/pygments/LICENSE @@ -0,0 +1,25 @@ +Copyright (c) 2006-2022 by the respective authors (see AUTHORS file). +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + +* Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + +* Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/pyproject_hooks/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/pyproject_hooks/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..b0ae9dbc262b5f7ed4cb6f964cfb5eb5c0d0b0be --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/pyproject_hooks/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2017 Thomas Kluyver + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/requests/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/requests/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..67db8588217f266eb561f75fae738656325deac9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/requests/LICENSE @@ -0,0 +1,175 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/resolvelib/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/resolvelib/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..b9077766e9b9bdcae49ea5c8fced750ed13ec8f7 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/resolvelib/LICENSE @@ -0,0 +1,13 @@ +Copyright (c) 2018, Tzu-ping Chung + +Permission to use, copy, modify, and distribute this software for any +purpose with or without fee is hereby granted, provided that the above +copyright notice and this permission notice appear in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +ANY SPECIAL, DIRECT, 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. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/rich/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/rich/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..4415505566f261c802b671426be529a31f914137 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/rich/LICENSE @@ -0,0 +1,19 @@ +Copyright (c) 2020 Will McGugan + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/tomli/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/tomli/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..e859590f886cd78344206af1a8ccb3080d4385e0 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/tomli/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2021 Taneli Hukkinen + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/tomli_w/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/tomli_w/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..e859590f886cd78344206af1a8ccb3080d4385e0 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/tomli_w/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2021 Taneli Hukkinen + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/truststore/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/truststore/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..7ec568c1136eb8ec86aa05cf7abacfb54c3e5ead --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/truststore/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2022 Seth Michael Larson + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/urllib3/LICENSE.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/urllib3/LICENSE.txt new file mode 100644 index 0000000000000000000000000000000000000000..e6183d0276b26c5b87aecccf8d0d5bcd7b1148d4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip-26.1.1.dist-info/licenses/src/pip/_vendor/urllib3/LICENSE.txt @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2008-2020 Andrey Petrov and contributors. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..b49ac8288ae9b3f78b4bdb608957e11b483541d4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/__init__.py @@ -0,0 +1,13 @@ +from __future__ import annotations + +__version__ = "26.1.1" + + +def main(args: list[str] | None = None) -> int: + """This is an internal API only meant for use by pip's own console scripts. + + For additional details, see https://github.com/pypa/pip/issues/7498. + """ + from pip._internal.utils.entrypoints import _wrapper + + return _wrapper(args) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/__main__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/__main__.py new file mode 100644 index 0000000000000000000000000000000000000000..094361cd1aa963d4b7e13ed0d22484390970d5f3 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/__main__.py @@ -0,0 +1,24 @@ +import os +import sys + +# Remove '' and current working directory from the first entry +# of sys.path, if present to avoid using current directory +# in pip commands check, freeze, install, list and show, +# when invoked as python -m pip +if sys.path[0] in ("", os.getcwd()): + sys.path.pop(0) + +# If we are running from a wheel, add the wheel to sys.path +# This allows the usage python pip-*.whl/pip install pip-*.whl +if not __spec__ or __spec__.parent == "": + # __file__ is pip-*.whl/pip/__main__.py + # first dirname call strips of '/__main__.py', second strips off '/pip' + # Resulting path is the name of the wheel itself + # Add that to sys.path so we can import pip + path = os.path.dirname(os.path.dirname(__file__)) + sys.path.insert(0, path) + +if __name__ == "__main__": + from pip._internal.cli.main import main as _main + + sys.exit(_main()) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/__pip-runner__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/__pip-runner__.py new file mode 100644 index 0000000000000000000000000000000000000000..a1aee8195308a2095a6eff9019f6aeee4d89b2a6 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/__pip-runner__.py @@ -0,0 +1,50 @@ +"""Execute exactly this copy of pip, within a different environment. + +This file is named as it is, to ensure that this module can't be imported via +an import statement. +""" + +# /!\ This version compatibility check section must be Python 2 compatible. /!\ + +import sys + +# Copied from pyproject.toml +PYTHON_REQUIRES = (3, 10) + + +def version_str(version): # type: ignore + return ".".join(str(v) for v in version) + + +if sys.version_info[:2] < PYTHON_REQUIRES: + raise SystemExit( + "This version of pip does not support python {} (requires >={}).".format( + version_str(sys.version_info[:2]), version_str(PYTHON_REQUIRES) + ) + ) + +# From here on, we can use Python 3 features, but the syntax must remain +# Python 2 compatible. + +import runpy # noqa: E402 +from importlib.machinery import PathFinder # noqa: E402 +from os.path import dirname # noqa: E402 + +PIP_SOURCES_ROOT = dirname(dirname(__file__)) + + +class PipImportRedirectingFinder: + @classmethod + def find_spec(self, fullname, path=None, target=None): # type: ignore + if fullname != "pip": + return None + + spec = PathFinder.find_spec(fullname, [PIP_SOURCES_ROOT], target) + assert spec, (PIP_SOURCES_ROOT, fullname) + return spec + + +sys.meta_path.insert(0, PipImportRedirectingFinder()) + +assert __name__ == "__main__", "Cannot run __pip-runner__.py as a non-main module" +runpy.run_module("pip", run_name="__main__", alter_sys=True) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..24d0baf0c31c2902e45623a29aea8d7ede8c0dee --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/__init__.py @@ -0,0 +1,18 @@ +from __future__ import annotations + +from pip._internal.utils import _log + +# init_logging() must be called before any call to logging.getLogger() +# which happens at import of most modules. +_log.init_logging() + + +def main(args: list[str] | None = None) -> int: + """This is preserved for old console scripts that may still be referencing + it. + + For additional details, see https://github.com/pypa/pip/issues/7498. + """ + from pip._internal.utils.entrypoints import _wrapper + + return _wrapper(args) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/build_env.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/build_env.py new file mode 100644 index 0000000000000000000000000000000000000000..1a42a9d4115c3d7c6ed2901f9845290e6c57a268 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/build_env.py @@ -0,0 +1,606 @@ +"""Build Environment used for isolation during sdist building""" + +from __future__ import annotations + +import logging +import os +import pathlib +import site +import sys +import textwrap +from collections import OrderedDict +from collections.abc import Iterable, Sequence +from contextlib import AbstractContextManager as ContextManager +from contextlib import nullcontext +from io import StringIO +from types import TracebackType +from typing import TYPE_CHECKING, Protocol, TypedDict + +from pip._vendor.packaging.version import Version + +from pip import __file__ as pip_location +from pip._internal.cli.spinners import open_rich_spinner, open_spinner +from pip._internal.exceptions import ( + BuildDependencyInstallError, + DiagnosticPipError, + InstallWheelBuildError, + PipError, +) +from pip._internal.locations import get_platlib, get_purelib, get_scheme +from pip._internal.metadata import get_default_environment, get_environment +from pip._internal.utils.deprecation import deprecated +from pip._internal.utils.logging import VERBOSE, capture_logging +from pip._internal.utils.packaging import get_requirement +from pip._internal.utils.subprocess import call_subprocess +from pip._internal.utils.temp_dir import TempDirectory, tempdir_kinds + +if TYPE_CHECKING: + from pip._internal.cache import WheelCache + from pip._internal.index.package_finder import PackageFinder + from pip._internal.operations.build.build_tracker import BuildTracker + from pip._internal.req.req_install import InstallRequirement + from pip._internal.resolution.base import BaseResolver + + class ExtraEnviron(TypedDict, total=False): + extra_environ: dict[str, str] + + +logger = logging.getLogger(__name__) + + +def _dedup(a: str, b: str) -> tuple[str] | tuple[str, str]: + return (a, b) if a != b else (a,) + + +class _Prefix: + def __init__(self, path: str) -> None: + self.path = path + self.setup = False + scheme = get_scheme("", prefix=path) + self.bin_dir = scheme.scripts + self.lib_dirs = _dedup(scheme.purelib, scheme.platlib) + + +def get_runnable_pip() -> str: + """Get a file to pass to a Python executable, to run the currently-running pip. + + This is used to run a pip subprocess, for installing requirements into the build + environment. + """ + source = pathlib.Path(pip_location).resolve().parent + + if not source.is_dir(): + # This would happen if someone is using pip from inside a zip file. In that + # case, we can use that directly. + return str(source) + + return os.fsdecode(source / "__pip-runner__.py") + + +def _get_system_sitepackages() -> set[str]: + """Get system site packages + + Usually from site.getsitepackages, + but fallback on `get_purelib()/get_platlib()` if unavailable + (e.g. in a virtualenv created by virtualenv<20) + + Returns normalized set of strings. + """ + if hasattr(site, "getsitepackages"): + system_sites = site.getsitepackages() + else: + # virtualenv < 20 overwrites site.py without getsitepackages + # fallback on get_purelib/get_platlib. + # this is known to miss things, but shouldn't in the cases + # where getsitepackages() has been removed (inside a virtualenv) + system_sites = [get_purelib(), get_platlib()] + return {os.path.normcase(path) for path in system_sites} + + +class BuildEnvironmentInstaller(Protocol): + """ + Interface for installing build dependencies into an isolated build + environment. + """ + + def install( + self, + requirements: Iterable[str], + prefix: _Prefix, + *, + kind: str, + for_req: InstallRequirement | None, + ) -> None: ... + + +class SubprocessBuildEnvironmentInstaller: + """ + Install build dependencies by calling pip in a subprocess. + """ + + def __init__( + self, + finder: PackageFinder, + build_constraints: list[str] | None = None, + build_constraint_feature_enabled: bool = False, + ) -> None: + self.finder = finder + self._build_constraints = build_constraints or [] + self._build_constraint_feature_enabled = build_constraint_feature_enabled + + def _deprecation_constraint_check(self) -> None: + """ + Check for deprecation warning: PIP_CONSTRAINT affecting build environments. + + This warns when build-constraint feature is NOT enabled and PIP_CONSTRAINT + is not empty. + """ + if self._build_constraint_feature_enabled or self._build_constraints: + return + + pip_constraint = os.environ.get("PIP_CONSTRAINT") + if not pip_constraint or not pip_constraint.strip(): + return + + deprecated( + reason=( + "Setting PIP_CONSTRAINT will not affect " + "build constraints in the future," + ), + replacement=( + "to specify build constraints using --build-constraint or " + "PIP_BUILD_CONSTRAINT. To disable this warning without " + "any build constraints set --use-feature=build-constraint or " + 'PIP_USE_FEATURE="build-constraint"' + ), + gone_in="26.2", + issue=None, + ) + + def install( + self, + requirements: Iterable[str], + prefix: _Prefix, + *, + kind: str, + for_req: InstallRequirement | None, + ) -> None: + self._deprecation_constraint_check() + + finder = self.finder + args: list[str] = [ + sys.executable, + get_runnable_pip(), + "install", + "--ignore-installed", + "--no-user", + "--prefix", + prefix.path, + "--no-warn-script-location", + "--disable-pip-version-check", + # As the build environment is ephemeral, it's wasteful to + # pre-compile everything, especially as not every Python + # module will be used/compiled in most cases. + "--no-compile", + # The prefix specified two lines above, thus + # target from config file or env var should be ignored + "--target", + "", + ] + if logger.getEffectiveLevel() <= logging.DEBUG: + args.append("-vv") + elif logger.getEffectiveLevel() <= VERBOSE: + args.append("-v") + for format_control in ("no_binary", "only_binary"): + formats = getattr(finder.format_control, format_control) + args.extend( + ( + "--" + format_control.replace("_", "-"), + ",".join(sorted(formats or {":none:"})), + ) + ) + + if finder.release_control is not None: + # Use ordered args to preserve the user's original command-line order + # This is important because later flags can override earlier ones + for attr_name, value in finder.release_control.get_ordered_args(): + args.extend(("--" + attr_name.replace("_", "-"), value)) + + index_urls = finder.index_urls + if index_urls: + args.extend(["-i", index_urls[0]]) + for extra_index in index_urls[1:]: + args.extend(["--extra-index-url", extra_index]) + else: + args.append("--no-index") + for link in finder.find_links: + args.extend(["--find-links", link]) + + if finder.proxy: + args.extend(["--proxy", finder.proxy]) + for host in finder.trusted_hosts: + args.extend(["--trusted-host", host]) + if finder.custom_cert: + args.extend(["--cert", finder.custom_cert]) + if finder.client_cert: + args.extend(["--client-cert", finder.client_cert]) + if finder.prefer_binary: + args.append("--prefer-binary") + + # Handle build constraints + if self._build_constraint_feature_enabled: + args.extend(["--use-feature", "build-constraint"]) + + if self._build_constraints: + # Build constraints must be passed as both constraints + # and build constraints, so that nested builds receive + # build constraints + for constraint_file in self._build_constraints: + args.extend(["--constraint", constraint_file]) + args.extend(["--build-constraint", constraint_file]) + + extra_environ: ExtraEnviron = {} + if self._build_constraint_feature_enabled and not self._build_constraints: + # If there are no build constraints but the build constraints + # feature is enabled then we must ignore regular constraints + # in the isolated build environment + extra_environ = {"extra_environ": {"_PIP_IN_BUILD_IGNORE_CONSTRAINTS": "1"}} + + if finder.uploaded_prior_to: + args.extend(["--uploaded-prior-to", finder.uploaded_prior_to.isoformat()]) + args.append("--") + args.extend(requirements) + + identify_requirement = ( + f" for {for_req.name}" if for_req and for_req.name else "" + ) + with open_spinner(f"Installing {kind}") as spinner: + call_subprocess( + args, + command_desc=f"installing {kind}{identify_requirement}", + spinner=spinner, + **extra_environ, + ) + + +class InprocessBuildEnvironmentInstaller: + """ + Build dependency installer that runs in the same pip process. + + This contains a stripped down version of the install command with + only the logic necessary for installing build dependencies. The + finder, session, build tracker, and wheel cache are reused, but new + instances of everything else are created as needed. + + Options are inherited from the parent install command unless + they don't make sense for build dependencies (in which case, they + are hard-coded, see comments below). + """ + + def __init__( + self, + *, + finder: PackageFinder, + build_tracker: BuildTracker, + wheel_cache: WheelCache, + build_constraints: Sequence[InstallRequirement] = (), + verbosity: int = 0, + ) -> None: + from pip._internal.operations.prepare import RequirementPreparer + + self._finder = finder + self._build_constraints = build_constraints + self._wheel_cache = wheel_cache + self._level = 0 + + build_dir = TempDirectory(kind="build-env-install", globally_managed=True) + self._preparer = RequirementPreparer( + build_isolation_installer=self, + # Inherited options or state. + finder=finder, + session=finder._link_collector.session, + build_dir=build_dir.path, + build_tracker=build_tracker, + verbosity=verbosity, + # This is irrelevant as it only applies to editable requirements. + src_dir="", + # Hard-coded options (that should NOT be inherited). + download_dir=None, + build_isolation=True, + check_build_deps=False, + progress_bar="off", + # TODO: hash-checking should be extended to build deps, but that is + # deferred for later as it'd be a breaking change. + require_hashes=False, + use_user_site=False, + lazy_wheel=False, + legacy_resolver=False, + ) + + def install( + self, + requirements: Iterable[str], + prefix: _Prefix, + *, + kind: str, + for_req: InstallRequirement | None, + ) -> None: + """Install entrypoint. Manages output capturing and error handling.""" + capture_logs = not logger.isEnabledFor(VERBOSE) and self._level == 0 + if capture_logs: + # Hide the logs from the installation of build dependencies. + # They will be shown only if an error occurs. + capture_ctx: ContextManager[StringIO] = capture_logging() + spinner: ContextManager[None] = open_rich_spinner(f"Installing {kind}") + else: + # Otherwise, pass-through all logs (with a header). + capture_ctx, spinner = nullcontext(StringIO()), nullcontext() + logger.info("Installing %s ...", kind) + + try: + self._level += 1 + with spinner, capture_ctx as stream: + self._install_impl(requirements, prefix) + + except DiagnosticPipError as exc: + # Format similar to a nested subprocess error, where the + # causing error is shown first, followed by the build error. + logger.info(textwrap.dedent(stream.getvalue())) + logger.error("%s", exc, extra={"rich": True}) + logger.info("") + raise BuildDependencyInstallError( + for_req, requirements, cause=exc, log_lines=None + ) + + except Exception as exc: + logs: list[str] | None = textwrap.dedent(stream.getvalue()).splitlines() + if not capture_logs: + # If logs aren't being captured, then display the error inline + # with the rest of the logs. + logs = None + if isinstance(exc, PipError): + logger.error("%s", exc) + else: + logger.exception("pip crashed unexpectedly") + raise BuildDependencyInstallError( + for_req, requirements, cause=exc, log_lines=logs + ) + + finally: + self._level -= 1 + + def _install_impl(self, requirements: Iterable[str], prefix: _Prefix) -> None: + """Core build dependency install logic.""" + from pip._internal.commands.install import installed_packages_summary + from pip._internal.req import install_given_reqs + from pip._internal.req.constructors import install_req_from_line + from pip._internal.wheel_builder import build + + ireqs = [install_req_from_line(req, user_supplied=True) for req in requirements] + ireqs.extend(self._build_constraints) + + resolver = self._make_resolver() + resolved_set = resolver.resolve(ireqs, check_supported_wheels=True) + self._preparer.prepare_linked_requirements_more( + resolved_set.requirements.values() + ) + + reqs_to_build = [ + r for r in resolved_set.requirements_to_install if not r.is_wheel + ] + _, build_failures = build(reqs_to_build, self._wheel_cache, verify=True) + if build_failures: + raise InstallWheelBuildError(build_failures) + + installed = install_given_reqs( + resolver.get_installation_order(resolved_set), + prefix=prefix.path, + # Hard-coded options (that should NOT be inherited). + root=None, + home=None, + warn_script_location=False, + use_user_site=False, + # As the build environment is ephemeral, it's wasteful to + # pre-compile everything since not all modules will be used. + pycompile=False, + progress_bar="off", + ) + + env = get_environment(list(prefix.lib_dirs)) + if summary := installed_packages_summary(installed, env): + logger.info(summary) + + def _make_resolver(self) -> BaseResolver: + """Create a new resolver for one time use.""" + # Legacy installer never used the legacy resolver so create a + # resolvelib resolver directly. Yuck. + from pip._internal.req.constructors import install_req_from_req_string + from pip._internal.resolution.resolvelib.resolver import Resolver + + return Resolver( + make_install_req=install_req_from_req_string, + # Inherited state. + preparer=self._preparer, + finder=self._finder, + wheel_cache=self._wheel_cache, + # Hard-coded options (that should NOT be inherited). + ignore_requires_python=False, + use_user_site=False, + ignore_dependencies=False, + ignore_installed=True, + force_reinstall=False, + upgrade_strategy="to-satisfy-only", + py_version_info=None, + ) + + +class BuildEnvironment: + """Creates and manages an isolated environment to install build deps""" + + def __init__(self, installer: BuildEnvironmentInstaller) -> None: + self.installer = installer + temp_dir = TempDirectory(kind=tempdir_kinds.BUILD_ENV, globally_managed=True) + + self._prefixes = OrderedDict( + (name, _Prefix(os.path.join(temp_dir.path, name))) + for name in ("normal", "overlay") + ) + + self._bin_dirs: list[str] = [] + self._lib_dirs: list[str] = [] + for prefix in reversed(list(self._prefixes.values())): + self._bin_dirs.append(prefix.bin_dir) + self._lib_dirs.extend(prefix.lib_dirs) + + # Customize site to: + # - ensure .pth files are honored + # - prevent access to system site packages + system_sites = _get_system_sitepackages() + + self._site_dir = os.path.join(temp_dir.path, "site") + if not os.path.exists(self._site_dir): + os.mkdir(self._site_dir) + with open( + os.path.join(self._site_dir, "sitecustomize.py"), "w", encoding="utf-8" + ) as fp: + fp.write( + textwrap.dedent( + """ + import os, site, sys + + # First, drop system-sites related paths. + original_sys_path = sys.path[:] + known_paths = set() + for path in {system_sites!r}: + site.addsitedir(path, known_paths=known_paths) + system_paths = set( + os.path.normcase(path) + for path in sys.path[len(original_sys_path):] + ) + original_sys_path = [ + path for path in original_sys_path + if os.path.normcase(path) not in system_paths + ] + sys.path = original_sys_path + + # Second, add lib directories. + # ensuring .pth file are processed. + for path in {lib_dirs!r}: + assert not path in sys.path + site.addsitedir(path) + """ + ).format(system_sites=system_sites, lib_dirs=self._lib_dirs) + ) + + def __enter__(self) -> None: + self._save_env = { + name: os.environ.get(name, None) + for name in ("PATH", "PYTHONNOUSERSITE", "PYTHONPATH") + } + + path = self._bin_dirs[:] + old_path = self._save_env["PATH"] + if old_path: + path.extend(old_path.split(os.pathsep)) + + pythonpath = [self._site_dir] + + os.environ.update( + { + "PATH": os.pathsep.join(path), + "PYTHONNOUSERSITE": "1", + "PYTHONPATH": os.pathsep.join(pythonpath), + } + ) + + def __exit__( + self, + exc_type: type[BaseException] | None, + exc_val: BaseException | None, + exc_tb: TracebackType | None, + ) -> None: + for varname, old_value in self._save_env.items(): + if old_value is None: + os.environ.pop(varname, None) + else: + os.environ[varname] = old_value + + def check_requirements( + self, reqs: Iterable[str] + ) -> tuple[set[tuple[str, str]], set[str]]: + """Return 2 sets: + - conflicting requirements: set of (installed, wanted) reqs tuples + - missing requirements: set of reqs + """ + missing = set() + conflicting = set() + if reqs: + env = ( + get_environment(self._lib_dirs) + if hasattr(self, "_lib_dirs") + else get_default_environment() + ) + for req_str in reqs: + req = get_requirement(req_str) + # We're explicitly evaluating with an empty extra value, since build + # environments are not provided any mechanism to select specific extras. + if req.marker is not None and not req.marker.evaluate({"extra": ""}): + continue + dist = env.get_distribution(req.name) + if not dist: + missing.add(req_str) + continue + if isinstance(dist.version, Version): + installed_req_str = f"{req.name}=={dist.version}" + else: + installed_req_str = f"{req.name}==={dist.version}" + if not req.specifier.contains(dist.version, prereleases=True): + conflicting.add((installed_req_str, req_str)) + # FIXME: Consider direct URL? + return conflicting, missing + + def install_requirements( + self, + requirements: Iterable[str], + prefix_as_string: str, + *, + kind: str, + for_req: InstallRequirement | None = None, + ) -> None: + prefix = self._prefixes[prefix_as_string] + assert not prefix.setup + prefix.setup = True + if not requirements: + return + self.installer.install(requirements, prefix, kind=kind, for_req=for_req) + + +class NoOpBuildEnvironment(BuildEnvironment): + """A no-op drop-in replacement for BuildEnvironment""" + + def __init__(self) -> None: + pass + + def __enter__(self) -> None: + pass + + def __exit__( + self, + exc_type: type[BaseException] | None, + exc_val: BaseException | None, + exc_tb: TracebackType | None, + ) -> None: + pass + + def cleanup(self) -> None: + pass + + def install_requirements( + self, + requirements: Iterable[str], + prefix_as_string: str, + *, + kind: str, + for_req: InstallRequirement | None = None, + ) -> None: + raise NotImplementedError() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/cache.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/cache.py new file mode 100644 index 0000000000000000000000000000000000000000..0bcb6975425142b06a289cf15646f29de59824f3 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/cache.py @@ -0,0 +1,291 @@ +"""Cache Management""" + +from __future__ import annotations + +import hashlib +import json +import logging +import os +from pathlib import Path +from typing import Any + +from pip._vendor.packaging.tags import Tag, interpreter_name, interpreter_version +from pip._vendor.packaging.utils import canonicalize_name + +from pip._internal.exceptions import InvalidWheelFilename +from pip._internal.models.direct_url import DirectUrl +from pip._internal.models.link import Link +from pip._internal.models.wheel import Wheel +from pip._internal.utils.temp_dir import TempDirectory, tempdir_kinds +from pip._internal.utils.urls import path_to_url + +logger = logging.getLogger(__name__) + +ORIGIN_JSON_NAME = "origin.json" + + +def _hash_dict(d: dict[str, str]) -> str: + """Return a stable sha224 of a dictionary.""" + s = json.dumps(d, sort_keys=True, separators=(",", ":"), ensure_ascii=True) + return hashlib.sha224(s.encode("ascii")).hexdigest() + + +class Cache: + """An abstract class - provides cache directories for data from links + + :param cache_dir: The root of the cache. + """ + + def __init__(self, cache_dir: str) -> None: + super().__init__() + assert not cache_dir or os.path.isabs(cache_dir) + self.cache_dir = cache_dir or None + + def _get_cache_path_parts(self, link: Link) -> list[str]: + """Get parts of part that must be os.path.joined with cache_dir""" + + # We want to generate an url to use as our cache key, we don't want to + # just reuse the URL because it might have other items in the fragment + # and we don't care about those. + key_parts = {"url": link.url_without_fragment} + if link.hash_name is not None and link.hash is not None: + key_parts[link.hash_name] = link.hash + if link.subdirectory_fragment: + key_parts["subdirectory"] = link.subdirectory_fragment + + # Include interpreter name, major and minor version in cache key + # to cope with ill-behaved sdists that build a different wheel + # depending on the python version their setup.py is being run on, + # and don't encode the difference in compatibility tags. + # https://github.com/pypa/pip/issues/7296 + key_parts["interpreter_name"] = interpreter_name() + key_parts["interpreter_version"] = interpreter_version() + + # Encode our key url with sha224, we'll use this because it has similar + # security properties to sha256, but with a shorter total output (and + # thus less secure). However the differences don't make a lot of + # difference for our use case here. + hashed = _hash_dict(key_parts) + + # We want to nest the directories some to prevent having a ton of top + # level directories where we might run out of sub directories on some + # FS. + parts = [hashed[:2], hashed[2:4], hashed[4:6], hashed[6:]] + + return parts + + def _get_candidates(self, link: Link, canonical_package_name: str) -> list[Any]: + can_not_cache = not self.cache_dir or not canonical_package_name or not link + if can_not_cache: + return [] + + path = self.get_path_for_link(link) + if os.path.isdir(path): + return [(candidate, path) for candidate in os.listdir(path)] + return [] + + def get_path_for_link(self, link: Link) -> str: + """Return a directory to store cached items in for link.""" + raise NotImplementedError() + + def get( + self, + link: Link, + package_name: str | None, + supported_tags: list[Tag], + ) -> Link: + """Returns a link to a cached item if it exists, otherwise returns the + passed link. + """ + raise NotImplementedError() + + +class SimpleWheelCache(Cache): + """A cache of wheels for future installs.""" + + def __init__(self, cache_dir: str) -> None: + super().__init__(cache_dir) + + def get_path_for_link(self, link: Link) -> str: + """Return a directory to store cached wheels for link + + Because there are M wheels for any one sdist, we provide a directory + to cache them in, and then consult that directory when looking up + cache hits. + + We only insert things into the cache if they have plausible version + numbers, so that we don't contaminate the cache with things that were + not unique. E.g. ./package might have dozens of installs done for it + and build a version of 0.0...and if we built and cached a wheel, we'd + end up using the same wheel even if the source has been edited. + + :param link: The link of the sdist for which this will cache wheels. + """ + parts = self._get_cache_path_parts(link) + assert self.cache_dir + # Store wheels within the root cache_dir + return os.path.join(self.cache_dir, "wheels", *parts) + + def get( + self, + link: Link, + package_name: str | None, + supported_tags: list[Tag], + ) -> Link: + candidates = [] + + if not package_name: + return link + + canonical_package_name = canonicalize_name(package_name) + for wheel_name, wheel_dir in self._get_candidates(link, canonical_package_name): + try: + wheel = Wheel(wheel_name) + except InvalidWheelFilename: + continue + if wheel.name != canonical_package_name: + logger.debug( + "Ignoring cached wheel %s for %s as it " + "does not match the expected distribution name %s.", + wheel_name, + link, + package_name, + ) + continue + if not wheel.supported(supported_tags): + # Built for a different python/arch/etc + continue + candidates.append( + ( + wheel.support_index_min(supported_tags), + wheel_name, + wheel_dir, + ) + ) + + if not candidates: + return link + + _, wheel_name, wheel_dir = min(candidates) + return Link(path_to_url(os.path.join(wheel_dir, wheel_name))) + + +class EphemWheelCache(SimpleWheelCache): + """A SimpleWheelCache that creates it's own temporary cache directory""" + + def __init__(self) -> None: + self._temp_dir = TempDirectory( + kind=tempdir_kinds.EPHEM_WHEEL_CACHE, + globally_managed=True, + ) + + super().__init__(self._temp_dir.path) + + +class CacheEntry: + def __init__( + self, + link: Link, + persistent: bool, + ): + self.link = link + self.persistent = persistent + self.origin: DirectUrl | None = None + origin_direct_url_path = Path(self.link.file_path).parent / ORIGIN_JSON_NAME + if origin_direct_url_path.exists(): + try: + self.origin = DirectUrl.from_json( + origin_direct_url_path.read_text(encoding="utf-8") + ) + except Exception as e: + logger.warning( + "Ignoring invalid cache entry origin file %s for %s (%s)", + origin_direct_url_path, + link.filename, + e, + ) + + +class WheelCache(Cache): + """Wraps EphemWheelCache and SimpleWheelCache into a single Cache + + This Cache allows for gracefully degradation, using the ephem wheel cache + when a certain link is not found in the simple wheel cache first. + """ + + def __init__(self, cache_dir: str) -> None: + super().__init__(cache_dir) + self._wheel_cache = SimpleWheelCache(cache_dir) + self._ephem_cache = EphemWheelCache() + + def get_path_for_link(self, link: Link) -> str: + return self._wheel_cache.get_path_for_link(link) + + def get_ephem_path_for_link(self, link: Link) -> str: + return self._ephem_cache.get_path_for_link(link) + + def get( + self, + link: Link, + package_name: str | None, + supported_tags: list[Tag], + ) -> Link: + cache_entry = self.get_cache_entry(link, package_name, supported_tags) + if cache_entry is None: + return link + return cache_entry.link + + def get_cache_entry( + self, + link: Link, + package_name: str | None, + supported_tags: list[Tag], + ) -> CacheEntry | None: + """Returns a CacheEntry with a link to a cached item if it exists or + None. The cache entry indicates if the item was found in the persistent + or ephemeral cache. + """ + retval = self._wheel_cache.get( + link=link, + package_name=package_name, + supported_tags=supported_tags, + ) + if retval is not link: + return CacheEntry(retval, persistent=True) + + retval = self._ephem_cache.get( + link=link, + package_name=package_name, + supported_tags=supported_tags, + ) + if retval is not link: + return CacheEntry(retval, persistent=False) + + return None + + @staticmethod + def record_download_origin(cache_dir: str, download_info: DirectUrl) -> None: + origin_path = Path(cache_dir) / ORIGIN_JSON_NAME + if origin_path.exists(): + try: + origin = DirectUrl.from_json(origin_path.read_text(encoding="utf-8")) + except Exception as e: + logger.warning( + "Could not read origin file %s in cache entry (%s). " + "Will attempt to overwrite it.", + origin_path, + e, + ) + else: + # TODO: use DirectUrl.equivalent when + # https://github.com/pypa/pip/pull/10564 is merged. + if origin.url != download_info.url: + logger.warning( + "Origin URL %s in cache entry %s does not match download URL " + "%s. This is likely a pip bug or a cache corruption issue. " + "Will overwrite it with the new value.", + origin.url, + cache_dir, + download_info.url, + ) + origin_path.write_text(download_info.to_json(), encoding="utf-8") diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/configuration.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/configuration.py new file mode 100644 index 0000000000000000000000000000000000000000..e164653bbc212e67318e8d4ea3fac4c122288fd9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/configuration.py @@ -0,0 +1,396 @@ +"""Configuration management setup + +Some terminology: +- name + As written in config files. +- value + Value associated with a name +- key + Name combined with it's section (section.name) +- variant + A single word describing where the configuration key-value pair came from +""" + +from __future__ import annotations + +import configparser +import locale +import os +import sys +from collections.abc import Iterable +from typing import Any, NewType + +from pip._internal.exceptions import ( + ConfigurationError, + ConfigurationFileCouldNotBeLoaded, +) +from pip._internal.utils import appdirs +from pip._internal.utils.compat import WINDOWS +from pip._internal.utils.logging import getLogger +from pip._internal.utils.misc import ensure_dir, enum + +RawConfigParser = configparser.RawConfigParser # Shorthand +Kind = NewType("Kind", str) + +CONFIG_BASENAME = "pip.ini" if WINDOWS else "pip.conf" +ENV_NAMES_IGNORED = "version", "help" + +# The kinds of configurations there are. +kinds = enum( + USER="user", # User Specific + GLOBAL="global", # System Wide + SITE="site", # [Virtual] Environment Specific + ENV="env", # from PIP_CONFIG_FILE + ENV_VAR="env-var", # from Environment Variables +) +OVERRIDE_ORDER = kinds.GLOBAL, kinds.USER, kinds.SITE, kinds.ENV, kinds.ENV_VAR +VALID_LOAD_ONLY = kinds.USER, kinds.GLOBAL, kinds.SITE + +logger = getLogger(__name__) + + +# NOTE: Maybe use the optionx attribute to normalize keynames. +def _normalize_name(name: str) -> str: + """Make a name consistent regardless of source (environment or file)""" + name = name.lower().replace("_", "-") + name = name.removeprefix("--") # only prefer long opts + return name + + +def _disassemble_key(name: str) -> list[str]: + if "." not in name: + error_message = ( + "Key does not contain dot separated section and key. " + f"Perhaps you wanted to use 'global.{name}' instead?" + ) + raise ConfigurationError(error_message) + return name.split(".", 1) + + +def get_configuration_files() -> dict[Kind, list[str]]: + global_config_files = [ + os.path.join(path, CONFIG_BASENAME) for path in appdirs.site_config_dirs("pip") + ] + + site_config_file = os.path.join(sys.prefix, CONFIG_BASENAME) + legacy_config_file = os.path.join( + os.path.expanduser("~"), + "pip" if WINDOWS else ".pip", + CONFIG_BASENAME, + ) + new_config_file = os.path.join(appdirs.user_config_dir("pip"), CONFIG_BASENAME) + return { + kinds.GLOBAL: global_config_files, + kinds.SITE: [site_config_file], + kinds.USER: [legacy_config_file, new_config_file], + } + + +class Configuration: + """Handles management of configuration. + + Provides an interface to accessing and managing configuration files. + + This class converts provides an API that takes "section.key-name" style + keys and stores the value associated with it as "key-name" under the + section "section". + + This allows for a clean interface wherein the both the section and the + key-name are preserved in an easy to manage form in the configuration files + and the data stored is also nice. + """ + + def __init__(self, isolated: bool, load_only: Kind | None = None) -> None: + super().__init__() + + if load_only is not None and load_only not in VALID_LOAD_ONLY: + raise ConfigurationError( + "Got invalid value for load_only - should be one of {}".format( + ", ".join(map(repr, VALID_LOAD_ONLY)) + ) + ) + self.isolated = isolated + self.load_only = load_only + + # Because we keep track of where we got the data from + self._parsers: dict[Kind, list[tuple[str, RawConfigParser]]] = { + variant: [] for variant in OVERRIDE_ORDER + } + self._config: dict[Kind, dict[str, dict[str, Any]]] = { + variant: {} for variant in OVERRIDE_ORDER + } + self._modified_parsers: list[tuple[str, RawConfigParser]] = [] + + def load(self) -> None: + """Loads configuration from configuration files and environment""" + self._load_config_files() + if not self.isolated: + self._load_environment_vars() + + def get_file_to_edit(self) -> str | None: + """Returns the file with highest priority in configuration""" + assert self.load_only is not None, "Need to be specified a file to be editing" + + try: + return self._get_parser_to_modify()[0] + except IndexError: + return None + + def items(self) -> Iterable[tuple[str, Any]]: + """Returns key-value pairs like dict.items() representing the loaded + configuration + """ + return self._dictionary.items() + + def get_value(self, key: str) -> Any: + """Get a value from the configuration.""" + orig_key = key + key = _normalize_name(key) + try: + clean_config: dict[str, Any] = {} + for file_values in self._dictionary.values(): + clean_config.update(file_values) + return clean_config[key] + except KeyError: + # disassembling triggers a more useful error message than simply + # "No such key" in the case that the key isn't in the form command.option + _disassemble_key(key) + raise ConfigurationError(f"No such key - {orig_key}") + + def set_value(self, key: str, value: Any) -> None: + """Modify a value in the configuration.""" + key = _normalize_name(key) + self._ensure_have_load_only() + + assert self.load_only + fname, parser = self._get_parser_to_modify() + + if parser is not None: + section, name = _disassemble_key(key) + + # Modify the parser and the configuration + if not parser.has_section(section): + parser.add_section(section) + parser.set(section, name, value) + + self._config[self.load_only].setdefault(fname, {}) + self._config[self.load_only][fname][key] = value + self._mark_as_modified(fname, parser) + + def unset_value(self, key: str) -> None: + """Unset a value in the configuration.""" + orig_key = key + key = _normalize_name(key) + self._ensure_have_load_only() + + assert self.load_only + fname, parser = self._get_parser_to_modify() + + if ( + key not in self._config[self.load_only][fname] + and key not in self._config[self.load_only] + ): + raise ConfigurationError(f"No such key - {orig_key}") + + if parser is not None: + section, name = _disassemble_key(key) + if not ( + parser.has_section(section) and parser.remove_option(section, name) + ): + # The option was not removed. + raise ConfigurationError( + "Fatal Internal error [id=1]. Please report as a bug." + ) + + # The section may be empty after the option was removed. + if not parser.items(section): + parser.remove_section(section) + self._mark_as_modified(fname, parser) + try: + del self._config[self.load_only][fname][key] + except KeyError: + del self._config[self.load_only][key] + + def save(self) -> None: + """Save the current in-memory state.""" + self._ensure_have_load_only() + + for fname, parser in self._modified_parsers: + logger.info("Writing to %s", fname) + + # Ensure directory exists. + ensure_dir(os.path.dirname(fname)) + + # Ensure directory's permission(need to be writeable) + try: + with open(fname, "w") as f: + parser.write(f) + except OSError as error: + raise ConfigurationError( + f"An error occurred while writing to the configuration file " + f"{fname}: {error}" + ) + + # + # Private routines + # + + def _ensure_have_load_only(self) -> None: + if self.load_only is None: + raise ConfigurationError("Needed a specific file to be modifying.") + logger.debug("Will be working with %s variant only", self.load_only) + + @property + def _dictionary(self) -> dict[str, dict[str, Any]]: + """A dictionary representing the loaded configuration.""" + # NOTE: Dictionaries are not populated if not loaded. So, conditionals + # are not needed here. + retval = {} + + for variant in OVERRIDE_ORDER: + retval.update(self._config[variant]) + + return retval + + def _load_config_files(self) -> None: + """Loads configuration from configuration files""" + config_files = dict(self.iter_config_files()) + if config_files[kinds.ENV][0:1] == [os.devnull]: + logger.debug( + "Skipping loading configuration files due to " + "environment's PIP_CONFIG_FILE being os.devnull" + ) + return + + for variant, files in config_files.items(): + for fname in files: + # If there's specific variant set in `load_only`, load only + # that variant, not the others. + if self.load_only is not None and variant != self.load_only: + logger.debug("Skipping file '%s' (variant: %s)", fname, variant) + continue + + parser = self._load_file(variant, fname) + + # Keeping track of the parsers used + self._parsers[variant].append((fname, parser)) + + def _load_file(self, variant: Kind, fname: str) -> RawConfigParser: + logger.verbose("For variant '%s', will try loading '%s'", variant, fname) + parser = self._construct_parser(fname) + + for section in parser.sections(): + items = parser.items(section) + self._config[variant].setdefault(fname, {}) + self._config[variant][fname].update(self._normalized_keys(section, items)) + + return parser + + def _construct_parser(self, fname: str) -> RawConfigParser: + parser = configparser.RawConfigParser() + # If there is no such file, don't bother reading it but create the + # parser anyway, to hold the data. + # Doing this is useful when modifying and saving files, where we don't + # need to construct a parser. + if os.path.exists(fname): + locale_encoding = locale.getpreferredencoding(False) + try: + parser.read(fname, encoding=locale_encoding) + except UnicodeDecodeError: + # See https://github.com/pypa/pip/issues/4963 + raise ConfigurationFileCouldNotBeLoaded( + reason=f"contains invalid {locale_encoding} characters", + fname=fname, + ) + except configparser.Error as error: + # See https://github.com/pypa/pip/issues/4893 + raise ConfigurationFileCouldNotBeLoaded(error=error) + return parser + + def _load_environment_vars(self) -> None: + """Loads configuration from environment variables""" + self._config[kinds.ENV_VAR].setdefault(":env:", {}) + self._config[kinds.ENV_VAR][":env:"].update( + self._normalized_keys(":env:", self.get_environ_vars()) + ) + + def _normalized_keys( + self, section: str, items: Iterable[tuple[str, Any]] + ) -> dict[str, Any]: + """Normalizes items to construct a dictionary with normalized keys. + + This routine is where the names become keys and are made the same + regardless of source - configuration files or environment. + """ + normalized = {} + for name, val in items: + key = section + "." + _normalize_name(name) + normalized[key] = val + return normalized + + def get_environ_vars(self) -> Iterable[tuple[str, str]]: + """Returns a generator with all environmental vars with prefix PIP_""" + for key, val in os.environ.items(): + if key.startswith("PIP_"): + name = key[4:].lower() + if name not in ENV_NAMES_IGNORED: + yield name, val + + # XXX: This is patched in the tests. + def iter_config_files(self) -> Iterable[tuple[Kind, list[str]]]: + """Yields variant and configuration files associated with it. + + This should be treated like items of a dictionary. The order + here doesn't affect what gets overridden. That is controlled + by OVERRIDE_ORDER. However this does control the order they are + displayed to the user. It's probably most ergonomic to display + things in the same order as OVERRIDE_ORDER + """ + # SMELL: Move the conditions out of this function + + env_config_file = os.environ.get("PIP_CONFIG_FILE", None) + config_files = get_configuration_files() + + yield kinds.GLOBAL, config_files[kinds.GLOBAL] + + # per-user config is not loaded when env_config_file exists + should_load_user_config = not self.isolated and not ( + env_config_file and os.path.exists(env_config_file) + ) + if should_load_user_config: + # The legacy config file is overridden by the new config file + yield kinds.USER, config_files[kinds.USER] + + # virtualenv config + yield kinds.SITE, config_files[kinds.SITE] + + if env_config_file is not None: + yield kinds.ENV, [env_config_file] + else: + yield kinds.ENV, [] + + def get_values_in_config(self, variant: Kind) -> dict[str, Any]: + """Get values present in a config file""" + return self._config[variant] + + def _get_parser_to_modify(self) -> tuple[str, RawConfigParser]: + # Determine which parser to modify + assert self.load_only + parsers = self._parsers[self.load_only] + if not parsers: + # This should not happen if everything works correctly. + raise ConfigurationError( + "Fatal Internal error [id=2]. Please report as a bug." + ) + + # Use the highest priority parser. + return parsers[-1] + + # XXX: This is patched in the tests. + def _mark_as_modified(self, fname: str, parser: RawConfigParser) -> None: + file_parser_tuple = (fname, parser) + if file_parser_tuple not in self._modified_parsers: + self._modified_parsers.append(file_parser_tuple) + + def __repr__(self) -> str: + return f"{self.__class__.__name__}({self._dictionary!r})" diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/exceptions.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/exceptions.py new file mode 100644 index 0000000000000000000000000000000000000000..23e1e34cd35efb9adf1076ee6f9a238de2225209 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/exceptions.py @@ -0,0 +1,971 @@ +"""Exceptions used throughout package. + +This module MUST NOT try to import from anything within `pip._internal` to +operate. This is expected to be importable from any/all files within the +subpackage and, thus, should not depend on them. +""" + +from __future__ import annotations + +import configparser +import contextlib +import locale +import logging +import pathlib +import re +import sys +import traceback +from collections.abc import Iterable, Iterator +from itertools import chain, groupby, repeat +from typing import TYPE_CHECKING, Literal + +from pip._vendor.packaging.requirements import InvalidRequirement +from pip._vendor.packaging.version import InvalidVersion +from pip._vendor.rich.console import Console, ConsoleOptions, RenderResult +from pip._vendor.rich.markup import escape +from pip._vendor.rich.text import Text + +if TYPE_CHECKING: + from hashlib import _Hash + + from pip._vendor.requests.models import PreparedRequest, Request, Response + + from pip._internal.metadata import BaseDistribution + from pip._internal.models.link import Link + from pip._internal.network.download import _FileDownload + from pip._internal.req.req_install import InstallRequirement + +logger = logging.getLogger(__name__) + + +# +# Scaffolding +# +def _is_kebab_case(s: str) -> bool: + return re.match(r"^[a-z]+(-[a-z]+)*$", s) is not None + + +def _prefix_with_indent( + s: Text | str, + console: Console, + *, + prefix: str, + indent: str, +) -> Text: + if isinstance(s, Text): + text = s + else: + text = console.render_str(s) + + return console.render_str(prefix, overflow="ignore") + console.render_str( + f"\n{indent}", overflow="ignore" + ).join(text.split(allow_blank=True)) + + +class PipError(Exception): + """The base pip error.""" + + +class DiagnosticPipError(PipError): + """An error, that presents diagnostic information to the user. + + This contains a bunch of logic, to enable pretty presentation of our error + messages. Each error gets a unique reference. Each error can also include + additional context, a hint and/or a note -- which are presented with the + main error message in a consistent style. + + This is adapted from the error output styling in `sphinx-theme-builder`. + """ + + reference: str + + def __init__( + self, + *, + kind: Literal["error", "warning"] = "error", + reference: str | None = None, + message: str | Text, + context: str | Text | None, + hint_stmt: str | Text | None, + note_stmt: str | Text | None = None, + link: str | None = None, + ) -> None: + # Ensure a proper reference is provided. + if reference is None: + assert hasattr(self, "reference"), "error reference not provided!" + reference = self.reference + assert _is_kebab_case(reference), "error reference must be kebab-case!" + + self.kind = kind + self.reference = reference + + self.message = message + self.context = context + + self.note_stmt = note_stmt + self.hint_stmt = hint_stmt + + self.link = link + + super().__init__(f"<{self.__class__.__name__}: {self.reference}>") + + def __repr__(self) -> str: + return ( + f"<{self.__class__.__name__}(" + f"reference={self.reference!r}, " + f"message={self.message!r}, " + f"context={self.context!r}, " + f"note_stmt={self.note_stmt!r}, " + f"hint_stmt={self.hint_stmt!r}" + ")>" + ) + + def __rich_console__( + self, + console: Console, + options: ConsoleOptions, + ) -> RenderResult: + colour = "red" if self.kind == "error" else "yellow" + + yield f"[{colour} bold]{self.kind}[/]: [bold]{self.reference}[/]" + yield "" + + if not options.ascii_only: + # Present the main message, with relevant context indented. + if self.context is not None: + yield _prefix_with_indent( + self.message, + console, + prefix=f"[{colour}]×[/] ", + indent=f"[{colour}]│[/] ", + ) + yield _prefix_with_indent( + self.context, + console, + prefix=f"[{colour}]╰─>[/] ", + indent=f"[{colour}] [/] ", + ) + else: + yield _prefix_with_indent( + self.message, + console, + prefix="[red]×[/] ", + indent=" ", + ) + else: + yield self.message + if self.context is not None: + yield "" + yield self.context + + if self.note_stmt is not None or self.hint_stmt is not None: + yield "" + + if self.note_stmt is not None: + yield _prefix_with_indent( + self.note_stmt, + console, + prefix="[magenta bold]note[/]: ", + indent=" ", + ) + if self.hint_stmt is not None: + yield _prefix_with_indent( + self.hint_stmt, + console, + prefix="[cyan bold]hint[/]: ", + indent=" ", + ) + + if self.link is not None: + yield "" + yield f"Link: {self.link}" + + +# +# Actual Errors +# +class ConfigurationError(PipError): + """General exception in configuration""" + + +class InstallationError(PipError): + """General exception during installation""" + + +class FailedToPrepareCandidate(InstallationError): + """Raised when we fail to prepare a candidate (i.e. fetch and generate metadata). + + This is intentionally not a diagnostic error, since the output will be presented + above this error, when this occurs. This should instead present information to the + user. + """ + + def __init__( + self, *, package_name: str, requirement_chain: str, failed_step: str + ) -> None: + super().__init__(f"Failed to build '{package_name}' when {failed_step.lower()}") + self.package_name = package_name + self.requirement_chain = requirement_chain + self.failed_step = failed_step + + +class MissingPyProjectBuildRequires(DiagnosticPipError): + """Raised when pyproject.toml has `build-system`, but no `build-system.requires`.""" + + reference = "missing-pyproject-build-system-requires" + + def __init__(self, *, package: str) -> None: + super().__init__( + message=f"Can not process {escape(package)}", + context=Text( + "This package has an invalid pyproject.toml file.\n" + "The [build-system] table is missing the mandatory `requires` key." + ), + note_stmt="This is an issue with the package mentioned above, not pip.", + hint_stmt=Text("See PEP 518 for the detailed specification."), + ) + + +class InvalidPyProjectBuildRequires(DiagnosticPipError): + """Raised when pyproject.toml an invalid `build-system.requires`.""" + + reference = "invalid-pyproject-build-system-requires" + + def __init__(self, *, package: str, reason: str) -> None: + super().__init__( + message=f"Can not process {escape(package)}", + context=Text( + "This package has an invalid `build-system.requires` key in " + f"pyproject.toml.\n{reason}" + ), + note_stmt="This is an issue with the package mentioned above, not pip.", + hint_stmt=Text("See PEP 518 for the detailed specification."), + ) + + +class NoneMetadataError(PipError): + """Raised when accessing a Distribution's "METADATA" or "PKG-INFO". + + This signifies an inconsistency, when the Distribution claims to have + the metadata file (if not, raise ``FileNotFoundError`` instead), but is + not actually able to produce its content. This may be due to permission + errors. + """ + + def __init__( + self, + dist: BaseDistribution, + metadata_name: str, + ) -> None: + """ + :param dist: A Distribution object. + :param metadata_name: The name of the metadata being accessed + (can be "METADATA" or "PKG-INFO"). + """ + self.dist = dist + self.metadata_name = metadata_name + + def __str__(self) -> str: + # Use `dist` in the error message because its stringification + # includes more information, like the version and location. + return f"None {self.metadata_name} metadata found for distribution: {self.dist}" + + +class UserInstallationInvalid(InstallationError): + """A --user install is requested on an environment without user site.""" + + def __str__(self) -> str: + return "User base directory is not specified" + + +class InvalidSchemeCombination(InstallationError): + def __str__(self) -> str: + before = ", ".join(str(a) for a in self.args[:-1]) + return f"Cannot set {before} and {self.args[-1]} together" + + +class DistributionNotFound(InstallationError): + """Raised when a distribution cannot be found to satisfy a requirement""" + + +class RequirementsFileParseError(InstallationError): + """Raised when a general error occurs parsing a requirements file line.""" + + +class BestVersionAlreadyInstalled(PipError): + """Raised when the most up-to-date version of a package is already + installed.""" + + +class BadCommand(PipError): + """Raised when virtualenv or a command is not found""" + + +class CommandError(PipError): + """Raised when there is an error in command-line arguments""" + + +class PreviousBuildDirError(PipError): + """Raised when there's a previous conflicting build directory""" + + +class NetworkConnectionError(PipError): + """HTTP connection error""" + + def __init__( + self, + error_msg: str, + response: Response | None = None, + request: Request | PreparedRequest | None = None, + ) -> None: + """ + Initialize NetworkConnectionError with `request` and `response` + objects. + """ + self.response = response + self.request = request + self.error_msg = error_msg + if ( + self.response is not None + and not self.request + and hasattr(response, "request") + ): + self.request = self.response.request + super().__init__(error_msg, response, request) + + def __str__(self) -> str: + return str(self.error_msg) + + +class InvalidWheelFilename(InstallationError): + """Invalid wheel filename.""" + + +class UnsupportedWheel(InstallationError): + """Unsupported wheel.""" + + +class InvalidWheel(InstallationError): + """Invalid (e.g. corrupt) wheel.""" + + def __init__(self, location: str, name: str): + self.location = location + self.name = name + + def __str__(self) -> str: + return f"Wheel '{self.name}' located at {self.location} is invalid." + + +class MetadataInconsistent(InstallationError): + """Built metadata contains inconsistent information. + + This is raised when the metadata contains values (e.g. name and version) + that do not match the information previously obtained from sdist filename, + user-supplied ``#egg=`` value, or an install requirement name. + """ + + def __init__( + self, ireq: InstallRequirement, field: str, f_val: str, m_val: str + ) -> None: + self.ireq = ireq + self.field = field + self.f_val = f_val + self.m_val = m_val + + def __str__(self) -> str: + return ( + f"Requested {self.ireq} has inconsistent {self.field}: " + f"expected {self.f_val!r}, but metadata has {self.m_val!r}" + ) + + +class MetadataInvalid(InstallationError): + """Metadata is invalid.""" + + def __init__(self, ireq: InstallRequirement, error: str) -> None: + self.ireq = ireq + self.error = error + + def __str__(self) -> str: + return f"Requested {self.ireq} has invalid metadata: {self.error}" + + +class InstallationSubprocessError(DiagnosticPipError, InstallationError): + """A subprocess call failed.""" + + reference = "subprocess-exited-with-error" + + def __init__( + self, + *, + command_description: str, + exit_code: int, + output_lines: list[str] | None, + ) -> None: + if output_lines is None: + output_prompt = Text("No available output.") + else: + output_prompt = ( + Text.from_markup(f"[red][{len(output_lines)} lines of output][/]\n") + + Text("".join(output_lines)) + + Text.from_markup(R"[red]\[end of output][/]") + ) + + super().__init__( + message=( + f"[green]{escape(command_description)}[/] did not run successfully.\n" + f"exit code: {exit_code}" + ), + context=output_prompt, + hint_stmt=None, + note_stmt=( + "This error originates from a subprocess, and is likely not a " + "problem with pip." + ), + ) + + self.command_description = command_description + self.exit_code = exit_code + + def __str__(self) -> str: + return f"{self.command_description} exited with {self.exit_code}" + + +class MetadataGenerationFailed(DiagnosticPipError, InstallationError): + reference = "metadata-generation-failed" + + def __init__( + self, + *, + package_details: str, + ) -> None: + super().__init__( + message="Encountered error while generating package metadata.", + context=escape(package_details), + hint_stmt="See above for details.", + note_stmt="This is an issue with the package mentioned above, not pip.", + ) + + def __str__(self) -> str: + return "metadata generation failed" + + +class HashErrors(InstallationError): + """Multiple HashError instances rolled into one for reporting""" + + def __init__(self) -> None: + self.errors: list[HashError] = [] + + def append(self, error: HashError) -> None: + self.errors.append(error) + + def __str__(self) -> str: + lines = [] + self.errors.sort(key=lambda e: e.order) + for cls, errors_of_cls in groupby(self.errors, lambda e: e.__class__): + lines.append(cls.head) + lines.extend(e.body() for e in errors_of_cls) + if lines: + return "\n".join(lines) + return "" + + def __bool__(self) -> bool: + return bool(self.errors) + + +class HashError(InstallationError): + """ + A failure to verify a package against known-good hashes + + :cvar order: An int sorting hash exception classes by difficulty of + recovery (lower being harder), so the user doesn't bother fretting + about unpinned packages when he has deeper issues, like VCS + dependencies, to deal with. Also keeps error reports in a + deterministic order. + :cvar head: A section heading for display above potentially many + exceptions of this kind + :ivar req: The InstallRequirement that triggered this error. This is + pasted on after the exception is instantiated, because it's not + typically available earlier. + + """ + + req: InstallRequirement | None = None + head = "" + order: int = -1 + + def body(self) -> str: + """Return a summary of me for display under the heading. + + This default implementation simply prints a description of the + triggering requirement. + + :param req: The InstallRequirement that provoked this error, with + its link already populated by the resolver's _populate_link(). + + """ + return f" {self._requirement_name()}" + + def __str__(self) -> str: + return f"{self.head}\n{self.body()}" + + def _requirement_name(self) -> str: + """Return a description of the requirement that triggered me. + + This default implementation returns long description of the req, with + line numbers + + """ + return str(self.req) if self.req else "unknown package" + + +class VcsHashUnsupported(HashError): + """A hash was provided for a version-control-system-based requirement, but + we don't have a method for hashing those.""" + + order = 0 + head = ( + "Can't verify hashes for these requirements because we don't " + "have a way to hash version control repositories:" + ) + + +class DirectoryUrlHashUnsupported(HashError): + """A hash was provided for a version-control-system-based requirement, but + we don't have a method for hashing those.""" + + order = 1 + head = ( + "Can't verify hashes for these file:// requirements because they " + "point to directories:" + ) + + +class HashMissing(HashError): + """A hash was needed for a requirement but is absent.""" + + order = 2 + head = ( + "Hashes are required in --require-hashes mode, but they are " + "missing from some requirements. Here is a list of those " + "requirements along with the hashes their downloaded archives " + "actually had. Add lines like these to your requirements files to " + "prevent tampering. (If you did not enable --require-hashes " + "manually, note that it turns on automatically when any package " + "has a hash.)" + ) + + def __init__(self, gotten_hash: str) -> None: + """ + :param gotten_hash: The hash of the (possibly malicious) archive we + just downloaded + """ + self.gotten_hash = gotten_hash + + def body(self) -> str: + # Dodge circular import. + from pip._internal.utils.hashes import FAVORITE_HASH + + package = None + if self.req: + # In the case of URL-based requirements, display the original URL + # seen in the requirements file rather than the package name, + # so the output can be directly copied into the requirements file. + package = ( + self.req.original_link + if self.req.is_direct + # In case someone feeds something downright stupid + # to InstallRequirement's constructor. + else getattr(self.req, "req", None) + ) + return " {} --hash={}:{}".format( + package or "unknown package", FAVORITE_HASH, self.gotten_hash + ) + + +class HashUnpinned(HashError): + """A requirement had a hash specified but was not pinned to a specific + version.""" + + order = 3 + head = ( + "In --require-hashes mode, all requirements must have their " + "versions pinned with ==. These do not:" + ) + + +class HashMismatch(HashError): + """ + Distribution file hash values don't match. + + :ivar package_name: The name of the package that triggered the hash + mismatch. Feel free to write to this after the exception is raise to + improve its error message. + + """ + + order = 4 + head = ( + "THESE PACKAGES DO NOT MATCH THE HASHES FROM THE REQUIREMENTS " + "FILE. If you have updated the package versions, please update " + "the hashes. Otherwise, examine the package contents carefully; " + "someone may have tampered with them." + ) + + def __init__(self, allowed: dict[str, list[str]], gots: dict[str, _Hash]) -> None: + """ + :param allowed: A dict of algorithm names pointing to lists of allowed + hex digests + :param gots: A dict of algorithm names pointing to hashes we + actually got from the files under suspicion + """ + self.allowed = allowed + self.gots = gots + + def body(self) -> str: + return f" {self._requirement_name()}:\n{self._hash_comparison()}" + + def _hash_comparison(self) -> str: + """ + Return a comparison of actual and expected hash values. + + Example:: + + Expected sha256 abcdeabcdeabcdeabcdeabcdeabcdeabcdeabcdeabcde + or 123451234512345123451234512345123451234512345 + Got bcdefbcdefbcdefbcdefbcdefbcdefbcdefbcdefbcdef + + """ + + def hash_then_or(hash_name: str) -> chain[str]: + # For now, all the decent hashes have 6-char names, so we can get + # away with hard-coding space literals. + return chain([hash_name], repeat(" or")) + + lines: list[str] = [] + for hash_name, expecteds in self.allowed.items(): + prefix = hash_then_or(hash_name) + lines.extend((f" Expected {next(prefix)} {e}") for e in expecteds) + lines.append( + f" Got {self.gots[hash_name].hexdigest()}\n" + ) + return "\n".join(lines) + + +class UnsupportedPythonVersion(InstallationError): + """Unsupported python version according to Requires-Python package + metadata.""" + + +class ConfigurationFileCouldNotBeLoaded(ConfigurationError): + """When there are errors while loading a configuration file""" + + def __init__( + self, + reason: str = "could not be loaded", + fname: str | None = None, + error: configparser.Error | None = None, + ) -> None: + super().__init__(error) + self.reason = reason + self.fname = fname + self.error = error + + def __str__(self) -> str: + if self.fname is not None: + message_part = f" in {self.fname}." + else: + assert self.error is not None + message_part = f".\n{self.error}\n" + return f"Configuration file {self.reason}{message_part}" + + +_DEFAULT_EXTERNALLY_MANAGED_ERROR = f"""\ +The Python environment under {sys.prefix} is managed externally, and may not be +manipulated by the user. Please use specific tooling from the distributor of +the Python installation to interact with this environment instead. +""" + + +class ExternallyManagedEnvironment(DiagnosticPipError): + """The current environment is externally managed. + + This is raised when the current environment is externally managed, as + defined by `PEP 668`_. The ``EXTERNALLY-MANAGED`` configuration is checked + and displayed when the error is bubbled up to the user. + + :param error: The error message read from ``EXTERNALLY-MANAGED``. + """ + + reference = "externally-managed-environment" + + def __init__(self, error: str | None) -> None: + if error is None: + context = Text(_DEFAULT_EXTERNALLY_MANAGED_ERROR) + else: + context = Text(error) + super().__init__( + message="This environment is externally managed", + context=context, + note_stmt=( + "If you believe this is a mistake, please contact your " + "Python installation or OS distribution provider. " + "You can override this, at the risk of breaking your Python " + "installation or OS, by passing --break-system-packages." + ), + hint_stmt=Text("See PEP 668 for the detailed specification."), + ) + + @staticmethod + def _iter_externally_managed_error_keys() -> Iterator[str]: + # LC_MESSAGES is in POSIX, but not the C standard. The most common + # platform that does not implement this category is Windows, where + # using other categories for console message localization is equally + # unreliable, so we fall back to the locale-less vendor message. This + # can always be re-evaluated when a vendor proposes a new alternative. + try: + category = locale.LC_MESSAGES + except AttributeError: + lang: str | None = None + else: + lang, _ = locale.getlocale(category) + if lang is not None: + yield f"Error-{lang}" + for sep in ("-", "_"): + before, found, _ = lang.partition(sep) + if not found: + continue + yield f"Error-{before}" + yield "Error" + + @classmethod + def from_config( + cls, + config: pathlib.Path | str, + ) -> ExternallyManagedEnvironment: + parser = configparser.ConfigParser(interpolation=None) + try: + parser.read(config, encoding="utf-8") + section = parser["externally-managed"] + for key in cls._iter_externally_managed_error_keys(): + with contextlib.suppress(KeyError): + return cls(section[key]) + except KeyError: + pass + except (OSError, UnicodeDecodeError, configparser.ParsingError): + from pip._internal.utils._log import VERBOSE + + exc_info = logger.isEnabledFor(VERBOSE) + logger.warning("Failed to read %s", config, exc_info=exc_info) + return cls(None) + + +class UninstallMissingRecord(DiagnosticPipError): + reference = "uninstall-no-record-file" + + def __init__(self, *, distribution: BaseDistribution) -> None: + installer = distribution.installer + if not installer or installer == "pip": + dep = f"{distribution.raw_name}=={distribution.version}" + hint = Text.assemble( + "You might be able to recover from this via: ", + (f"pip install --ignore-installed --no-deps {dep}", "green"), + ) + else: + hint = Text( + f"The package was installed by {installer}. " + "You should check if it can uninstall the package." + ) + + super().__init__( + message=Text(f"Cannot uninstall {distribution}"), + context=( + "The package's contents are unknown: " + f"no RECORD file was found for {distribution.raw_name}." + ), + hint_stmt=hint, + ) + + +class LegacyDistutilsInstall(DiagnosticPipError): + reference = "uninstall-distutils-installed-package" + + def __init__(self, *, distribution: BaseDistribution) -> None: + super().__init__( + message=Text(f"Cannot uninstall {distribution}"), + context=( + "It is a distutils installed project and thus we cannot accurately " + "determine which files belong to it which would lead to only a partial " + "uninstall." + ), + hint_stmt=None, + ) + + +class InvalidInstalledPackage(DiagnosticPipError): + reference = "invalid-installed-package" + + def __init__( + self, + *, + dist: BaseDistribution, + invalid_exc: InvalidRequirement | InvalidVersion, + ) -> None: + installed_location = dist.installed_location + + if isinstance(invalid_exc, InvalidRequirement): + invalid_type = "requirement" + else: + invalid_type = "version" + + super().__init__( + message=Text( + f"Cannot process installed package {dist} " + + (f"in {installed_location!r} " if installed_location else "") + + f"because it has an invalid {invalid_type}:\n{invalid_exc.args[0]}" + ), + context=( + "Starting with pip 24.1, packages with invalid " + f"{invalid_type}s can not be processed." + ), + hint_stmt="To proceed this package must be uninstalled.", + ) + + +class IncompleteDownloadError(DiagnosticPipError): + """Raised when the downloader receives fewer bytes than advertised + in the Content-Length header.""" + + reference = "incomplete-download" + + def __init__(self, download: _FileDownload) -> None: + # Dodge circular import. + from pip._internal.utils.misc import format_size + + assert download.size is not None + download_status = ( + f"{format_size(download.bytes_received)}/{format_size(download.size)}" + ) + if download.reattempts: + retry_status = f"after {download.reattempts + 1} attempts " + hint = "Use --resume-retries to configure resume attempt limit." + else: + # Download retrying is not enabled. + retry_status = "" + hint = "Consider using --resume-retries to enable download resumption." + message = Text( + f"Download failed {retry_status}because not enough bytes " + f"were received ({download_status})" + ) + + super().__init__( + message=message, + context=f"URL: {download.link.redacted_url}", + hint_stmt=hint, + note_stmt="This is an issue with network connectivity, not pip.", + ) + + +class ResolutionTooDeepError(DiagnosticPipError): + """Raised when the dependency resolver exceeds the maximum recursion depth.""" + + reference = "resolution-too-deep" + + def __init__(self) -> None: + super().__init__( + message="Dependency resolution exceeded maximum depth", + context=( + "Pip cannot resolve the current dependencies as the dependency graph " + "is too complex for pip to solve efficiently." + ), + hint_stmt=( + "Try adding lower bounds to constrain your dependencies, " + "for example: 'package>=2.0.0' instead of just 'package'. " + ), + link="https://pip.pypa.io/en/stable/topics/dependency-resolution/#handling-resolution-too-deep-errors", + ) + + +class InstallWheelBuildError(DiagnosticPipError): + reference = "failed-wheel-build-for-install" + + def __init__(self, failed: list[InstallRequirement]) -> None: + super().__init__( + message=( + "Failed to build installable wheels for some " + "pyproject.toml based projects" + ), + context=", ".join(r.name for r in failed), # type: ignore + hint_stmt=None, + ) + + +class InvalidEggFragment(DiagnosticPipError): + reference = "invalid-egg-fragment" + + def __init__(self, link: Link, fragment: str) -> None: + hint = "" + if ">" in fragment or "=" in fragment or "<" in fragment: + hint = ( + "Version specifiers are silently ignored for URL references. " + "Remove them. " + ) + if "[" in fragment and "]" in fragment: + hint += "Try using the Direct URL requirement syntax: 'name[extra] @ URL'" + + if not hint: + hint = "Egg fragments can only be a valid project name." + + super().__init__( + message=f"The '{escape(fragment)}' egg fragment is invalid", + context=f"from '{escape(str(link))}'", + hint_stmt=escape(hint), + ) + + +class BuildDependencyInstallError(DiagnosticPipError): + """Raised when build dependencies cannot be installed.""" + + reference = "failed-build-dependency-install" + + def __init__( + self, + req: InstallRequirement | None, + build_reqs: Iterable[str], + *, + cause: Exception, + log_lines: list[str] | None, + ) -> None: + if isinstance(cause, PipError): + note = "This is likely not a problem with pip." + else: + note = ( + "pip crashed unexpectedly. Please file an issue on pip's issue " + "tracker: https://github.com/pypa/pip/issues/new" + ) + + if log_lines is None: + # No logs are available, they must have been printed earlier. + context = Text("See above for more details.") + else: + if isinstance(cause, PipError): + log_lines.append(f"ERROR: {cause}") + else: + # Split rendered error into real lines without trailing newlines. + log_lines.extend( + "".join(traceback.format_exception(cause)).splitlines() + ) + + context = Text.assemble( + f"Installing {' '.join(build_reqs)}\n", + (f"[{len(log_lines)} lines of output]\n", "red"), + "\n".join(log_lines), + ("\n[end of output]", "red"), + ) + + message = Text("Cannot install build dependencies", "green") + if req: + message += Text(f" for {req}") + super().__init__( + message=message, context=context, hint_stmt=None, note_stmt=note + ) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/main.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/main.py new file mode 100644 index 0000000000000000000000000000000000000000..ec52c4e0c398cb0f2cc4d941484258bd016015a8 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/main.py @@ -0,0 +1,12 @@ +from __future__ import annotations + + +def main(args: list[str] | None = None) -> int: + """This is preserved for old console scripts that may still be referencing + it. + + For additional details, see https://github.com/pypa/pip/issues/7498. + """ + from pip._internal.utils.entrypoints import _wrapper + + return _wrapper(args) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/pyproject.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/pyproject.py new file mode 100644 index 0000000000000000000000000000000000000000..8c2f7221c93a4fa292795bffa427436c000495ec --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/pyproject.py @@ -0,0 +1,123 @@ +from __future__ import annotations + +import os +from collections import namedtuple +from typing import Any + +from pip._vendor.packaging.requirements import InvalidRequirement + +from pip._internal.exceptions import ( + InstallationError, + InvalidPyProjectBuildRequires, + MissingPyProjectBuildRequires, +) +from pip._internal.utils.compat import tomllib +from pip._internal.utils.packaging import get_requirement + + +def _is_list_of_str(obj: Any) -> bool: + return isinstance(obj, list) and all(isinstance(item, str) for item in obj) + + +def make_pyproject_path(unpacked_source_directory: str) -> str: + return os.path.join(unpacked_source_directory, "pyproject.toml") + + +BuildSystemDetails = namedtuple( + "BuildSystemDetails", ["requires", "backend", "check", "backend_path"] +) + + +def load_pyproject_toml( + pyproject_toml: str, setup_py: str, req_name: str +) -> BuildSystemDetails: + """Load the pyproject.toml file. + + Parameters: + pyproject_toml - Location of the project's pyproject.toml file + setup_py - Location of the project's setup.py file + req_name - The name of the requirement we're processing (for + error reporting) + + Returns: + None if we should use the legacy code path, otherwise a tuple + ( + requirements from pyproject.toml, + name of PEP 517 backend, + requirements we should check are installed after setting + up the build environment + directory paths to import the backend from (backend-path), + relative to the project root. + ) + """ + has_pyproject = os.path.isfile(pyproject_toml) + has_setup = os.path.isfile(setup_py) + + if not has_pyproject and not has_setup: + raise InstallationError( + f"{req_name} does not appear to be a Python project: " + f"neither 'setup.py' nor 'pyproject.toml' found." + ) + + if has_pyproject: + with open(pyproject_toml, encoding="utf-8") as f: + pp_toml = tomllib.loads(f.read()) + build_system = pp_toml.get("build-system") + else: + build_system = None + + if build_system is None: + # In the absence of any explicit backend specification, we + # assume the setuptools backend that most closely emulates the + # traditional direct setup.py execution, and require wheel and + # a version of setuptools that supports that backend. + + build_system = { + "requires": ["setuptools>=40.8.0"], + "build-backend": "setuptools.build_meta:__legacy__", + } + + # Ensure that the build-system section in pyproject.toml conforms + # to PEP 518. + + # Specifying the build-system table but not the requires key is invalid + if "requires" not in build_system: + raise MissingPyProjectBuildRequires(package=req_name) + + # Error out if requires is not a list of strings + requires = build_system["requires"] + if not _is_list_of_str(requires): + raise InvalidPyProjectBuildRequires( + package=req_name, + reason="It is not a list of strings.", + ) + + # Each requirement must be valid as per PEP 508 + for requirement in requires: + try: + get_requirement(requirement) + except InvalidRequirement as error: + raise InvalidPyProjectBuildRequires( + package=req_name, + reason=f"It contains an invalid requirement: {requirement!r}", + ) from error + + backend = build_system.get("build-backend") + backend_path = build_system.get("backend-path", []) + check: list[str] = [] + if backend is None: + # If the user didn't specify a backend, we assume they want to use + # the setuptools backend. But we can't be sure they have included + # a version of setuptools which supplies the backend. So we + # make a note to check that this requirement is present once + # we have set up the environment. + # This is quite a lot of work to check for a very specific case. But + # the problem is, that case is potentially quite common - projects that + # adopted PEP 518 early for the ability to specify requirements to + # execute setup.py, but never considered needing to mention the build + # tools themselves. The original PEP 518 code had a similar check (but + # implemented in a different way). + backend = "setuptools.build_meta:__legacy__" + check = ["setuptools>=40.8.0"] + + return BuildSystemDetails(requires, backend, check, backend_path) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/self_outdated_check.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/self_outdated_check.py new file mode 100644 index 0000000000000000000000000000000000000000..4b5248ed3ded7e4c6cca61df39a48264f7b42814 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/self_outdated_check.py @@ -0,0 +1,246 @@ +from __future__ import annotations + +import datetime +import hashlib +import json +import logging +import optparse +import os.path +import sys +from dataclasses import dataclass + +from pip._vendor.packaging.version import Version +from pip._vendor.packaging.version import parse as parse_version +from pip._vendor.rich.console import Group +from pip._vendor.rich.markup import escape +from pip._vendor.rich.text import Text + +from pip._internal.index.collector import LinkCollector +from pip._internal.index.package_finder import PackageFinder +from pip._internal.metadata import get_default_environment +from pip._internal.models.release_control import ReleaseControl +from pip._internal.models.selection_prefs import SelectionPreferences +from pip._internal.network.session import PipSession +from pip._internal.utils.compat import WINDOWS +from pip._internal.utils.datetime import parse_iso_datetime +from pip._internal.utils.entrypoints import ( + get_best_invocation_for_this_pip, + get_best_invocation_for_this_python, +) +from pip._internal.utils.filesystem import ( + adjacent_tmp_file, + check_path_owner, + copy_directory_permissions, + replace, +) +from pip._internal.utils.misc import ( + ExternallyManagedEnvironment, + check_externally_managed, + ensure_dir, +) + +_WEEK = datetime.timedelta(days=7) + +logger = logging.getLogger(__name__) + + +def _get_statefile_name(key: str) -> str: + key_bytes = key.encode() + name = hashlib.sha224(key_bytes).hexdigest() + return name + + +class SelfCheckState: + def __init__(self, cache_dir: str) -> None: + self._state: dict[str, str] = {} + self._statefile_path = None + + # Try to load the existing state + if cache_dir: + self._statefile_path = os.path.join( + cache_dir, "selfcheck", _get_statefile_name(self.key) + ) + try: + with open(self._statefile_path, encoding="utf-8") as statefile: + self._state = json.load(statefile) + except (OSError, ValueError, KeyError): + # Explicitly suppressing exceptions, since we don't want to + # error out if the cache file is invalid. + pass + + @property + def key(self) -> str: + return sys.prefix + + def get(self, current_time: datetime.datetime) -> str | None: + """Check if we have a not-outdated version loaded already.""" + if not self._state: + return None + + if "last_check" not in self._state: + return None + + if "pypi_version" not in self._state: + return None + + # Determine if we need to refresh the state + last_check = parse_iso_datetime(self._state["last_check"]) + time_since_last_check = current_time - last_check + if time_since_last_check > _WEEK: + return None + + return self._state["pypi_version"] + + def set(self, pypi_version: str, current_time: datetime.datetime) -> None: + # If we do not have a path to cache in, don't bother saving. + if not self._statefile_path: + return + + statefile_directory = os.path.dirname(self._statefile_path) + + # Check to make sure that we own the directory + if not check_path_owner(statefile_directory): + return + + # Now that we've ensured the directory is owned by this user, we'll go + # ahead and make sure that all our directories are created. + ensure_dir(statefile_directory) + + state = { + # Include the key so it's easy to tell which pip wrote the + # file. + "key": self.key, + "last_check": current_time.isoformat(), + "pypi_version": pypi_version, + } + + text = json.dumps(state, sort_keys=True, separators=(",", ":")) + + with adjacent_tmp_file(self._statefile_path) as f: + f.write(text.encode()) + copy_directory_permissions(statefile_directory, f) + + try: + # Since we have a prefix-specific state file, we can just + # overwrite whatever is there, no need to check. + replace(f.name, self._statefile_path) + except OSError: + # Best effort. + pass + + +@dataclass +class UpgradePrompt: + old: str + new: str + + def __rich__(self) -> Group: + if WINDOWS: + pip_cmd = f"{get_best_invocation_for_this_python()} -m pip" + else: + pip_cmd = get_best_invocation_for_this_pip() + + notice = "[bold][[reset][blue]notice[reset][bold]][reset]" + return Group( + Text(), + Text.from_markup( + f"{notice} A new release of pip is available: " + f"[red]{self.old}[reset] -> [green]{self.new}[reset]" + ), + Text.from_markup( + f"{notice} To update, run: " + f"[green]{escape(pip_cmd)} install --upgrade pip" + ), + ) + + +def _get_current_remote_pip_version( + session: PipSession, options: optparse.Values +) -> str | None: + # Lets use PackageFinder to see what the latest pip version is + link_collector = LinkCollector.create( + session, + options=options, + suppress_no_index=True, + ) + + # Pass allow_yanked=False so we don't suggest upgrading to a + # yanked version. + selection_prefs = SelectionPreferences( + allow_yanked=False, + release_control=ReleaseControl(only_final={"pip"}), + ) + + finder = PackageFinder.create( + link_collector=link_collector, + selection_prefs=selection_prefs, + ) + best_candidate = finder.find_best_candidate("pip").best_candidate + if best_candidate is None: + return None + + return str(best_candidate.version) + + +def _compute_upgrade_prompt( + local_version: Version, remote_version_str: str, installed_by_pip: bool +) -> UpgradePrompt | None: + remote_version = parse_version(remote_version_str) + logger.debug("Remote version of pip: %s", remote_version) + logger.debug("Local version of pip: %s", local_version) + logger.debug("Was pip installed by pip? %s", installed_by_pip) + + if not installed_by_pip: + return None # Only suggest upgrade if pip is installed by pip. + + local_version_is_older = ( + local_version < remote_version + and local_version.base_version != remote_version.base_version + ) + if local_version_is_older: + return UpgradePrompt(old=str(local_version), new=remote_version_str) + + return None + + +def pip_self_version_check_fetch( + session: PipSession, options: optparse.Values +) -> UpgradePrompt | None: + """Compute the pip upgrade prompt, if any, before the command runs. + + Limit the frequency of checks to once per week. State is stored either in + the active virtualenv or in the user's USER_CACHE_DIR keyed off the prefix + of the pip script path. + + Pair with :func:`pip_self_version_check_emit`, which displays the prompt + after the command body runs. + """ + installed_dist = get_default_environment().get_distribution("pip") + if not installed_dist: + return None + try: + check_externally_managed() + except ExternallyManagedEnvironment: + return None + + state = SelfCheckState(cache_dir=options.cache_dir) + current_time = datetime.datetime.now(datetime.timezone.utc) + remote_version_str = state.get(current_time) + if remote_version_str is None: + remote_version_str = _get_current_remote_pip_version(session, options) + if remote_version_str is None: + logger.debug("No remote pip version found") + return None + state.set(remote_version_str, current_time) + + return _compute_upgrade_prompt( + local_version=installed_dist.version, + remote_version_str=remote_version_str, + installed_by_pip=installed_dist.installer == "pip", + ) + + +def pip_self_version_check_emit(upgrade_prompt: UpgradePrompt | None) -> None: + """Emit the upgrade prompt captured by :func:`pip_self_version_check_fetch`.""" + if upgrade_prompt is not None: + logger.warning("%s", upgrade_prompt, extra={"rich": True}) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/wheel_builder.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/wheel_builder.py new file mode 100644 index 0000000000000000000000000000000000000000..4dbf7677866fed30a574ddbd1cdf316503a634b7 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_internal/wheel_builder.py @@ -0,0 +1,261 @@ +"""Orchestrator for building wheels from InstallRequirements.""" + +from __future__ import annotations + +import logging +import os.path +import re +from collections.abc import Iterable +from tempfile import TemporaryDirectory + +from pip._vendor.packaging.utils import canonicalize_name, canonicalize_version +from pip._vendor.packaging.version import InvalidVersion, Version + +from pip._internal.cache import WheelCache +from pip._internal.exceptions import InvalidWheelFilename, UnsupportedWheel +from pip._internal.metadata import FilesystemWheel, get_wheel_distribution +from pip._internal.models.link import Link +from pip._internal.models.wheel import Wheel +from pip._internal.operations.build.wheel import build_wheel_pep517 +from pip._internal.operations.build.wheel_editable import build_wheel_editable +from pip._internal.req.req_install import InstallRequirement +from pip._internal.utils.logging import indent_log +from pip._internal.utils.misc import ensure_dir, hash_file +from pip._internal.utils.urls import path_to_url +from pip._internal.vcs import vcs + +logger = logging.getLogger(__name__) + +_egg_info_re = re.compile(r"([a-z0-9_.]+)-([a-z0-9_.!+-]+)", re.IGNORECASE) + +BuildResult = tuple[list[InstallRequirement], list[InstallRequirement]] + + +def _contains_egg_info(s: str) -> bool: + """Determine whether the string looks like an egg_info. + + :param s: The string to parse. E.g. foo-2.1 + """ + return bool(_egg_info_re.search(s)) + + +def _should_cache( + req: InstallRequirement, +) -> bool | None: + """ + Return whether a built InstallRequirement can be stored in the persistent + wheel cache, assuming the wheel cache is available. + """ + if req.editable or not req.source_dir: + # never cache editable requirements + return False + + if req.link and req.link.is_vcs: + # VCS checkout. Do not cache + # unless it points to an immutable commit hash. + assert not req.editable + assert req.source_dir + vcs_backend = vcs.get_backend_for_scheme(req.link.scheme) + assert vcs_backend + if vcs_backend.is_immutable_rev_checkout(req.link.url, req.source_dir): + return True + return False + + assert req.link + base, ext = req.link.splitext() + if _contains_egg_info(base): + return True + + # Otherwise, do not cache. + return False + + +def _get_cache_dir( + req: InstallRequirement, + wheel_cache: WheelCache, +) -> str: + """Return the persistent or temporary cache directory where the built + wheel need to be stored. + """ + cache_available = bool(wheel_cache.cache_dir) + assert req.link + if cache_available and _should_cache(req): + cache_dir = wheel_cache.get_path_for_link(req.link) + else: + cache_dir = wheel_cache.get_ephem_path_for_link(req.link) + return cache_dir + + +def _verify_one(req: InstallRequirement, wheel_path: str) -> None: + canonical_name = canonicalize_name(req.name or "") + w = Wheel(os.path.basename(wheel_path)) + if w.name != canonical_name: + raise InvalidWheelFilename( + f"Wheel has unexpected file name: expected {canonical_name!r}, " + f"got {w.name!r}", + ) + dist = get_wheel_distribution(FilesystemWheel(wheel_path), canonical_name) + dist_verstr = str(dist.version) + if canonicalize_version(dist_verstr) != canonicalize_version(w.version): + raise InvalidWheelFilename( + f"Wheel has unexpected file name: expected {dist_verstr!r}, " + f"got {w.version!r}", + ) + metadata_version_value = dist.metadata_version + if metadata_version_value is None: + raise UnsupportedWheel("Missing Metadata-Version") + try: + metadata_version = Version(metadata_version_value) + except InvalidVersion: + msg = f"Invalid Metadata-Version: {metadata_version_value}" + raise UnsupportedWheel(msg) + if metadata_version >= Version("1.2") and not isinstance(dist.version, Version): + raise UnsupportedWheel( + f"Metadata 1.2 mandates PEP 440 version, but {dist_verstr!r} is not" + ) + + +def _build_one( + req: InstallRequirement, + output_dir: str, + verify: bool, + editable: bool, +) -> str | None: + """Build one wheel. + + :return: The filename of the built wheel, or None if the build failed. + """ + artifact = "editable" if editable else "wheel" + try: + ensure_dir(output_dir) + except OSError as e: + logger.warning( + "Building %s for %s failed: %s", + artifact, + req.name, + e, + ) + return None + + # Install build deps into temporary directory (PEP 518) + with req.build_env: + wheel_path = _build_one_inside_env(req, output_dir, editable) + if wheel_path and verify: + try: + _verify_one(req, wheel_path) + except (InvalidWheelFilename, UnsupportedWheel) as e: + logger.warning("Built %s for %s is invalid: %s", artifact, req.name, e) + return None + return wheel_path + + +def _build_one_inside_env( + req: InstallRequirement, + output_dir: str, + editable: bool, +) -> str | None: + with TemporaryDirectory(dir=output_dir) as wheel_directory: + assert req.name + assert req.metadata_directory + assert req.pep517_backend + if editable: + wheel_path = build_wheel_editable( + name=req.name, + backend=req.pep517_backend, + metadata_directory=req.metadata_directory, + wheel_directory=wheel_directory, + ) + else: + wheel_path = build_wheel_pep517( + name=req.name, + backend=req.pep517_backend, + metadata_directory=req.metadata_directory, + wheel_directory=wheel_directory, + ) + + if wheel_path is not None: + wheel_name = os.path.basename(wheel_path) + dest_path = os.path.join(output_dir, wheel_name) + try: + wheel_hash, length = hash_file(wheel_path) + # We can do a replace here because wheel_path is guaranteed to + # be in the same filesystem as output_dir. This will perform an + # atomic rename, which is necessary to avoid concurrency issues + # when populating the cache. + os.replace(wheel_path, dest_path) + logger.info( + "Created wheel for %s: filename=%s size=%d sha256=%s", + req.name, + wheel_name, + length, + wheel_hash.hexdigest(), + ) + logger.info("Stored in directory: %s", output_dir) + return dest_path + except Exception as e: + logger.warning( + "Building wheel for %s failed: %s", + req.name, + e, + ) + return None + + +def build( + requirements: Iterable[InstallRequirement], + wheel_cache: WheelCache, + verify: bool, +) -> BuildResult: + """Build wheels. + + :return: The list of InstallRequirement that succeeded to build and + the list of InstallRequirement that failed to build. + """ + if not requirements: + return [], [] + + # Build the wheels. + logger.info( + "Building wheels for collected packages: %s", + ", ".join(req.name for req in requirements), # type: ignore + ) + + with indent_log(): + build_successes, build_failures = [], [] + for req in requirements: + assert req.name + cache_dir = _get_cache_dir(req, wheel_cache) + wheel_file = _build_one( + req, + cache_dir, + verify, + req.editable and req.permit_editable_wheels, + ) + if wheel_file: + # Record the download origin in the cache + if req.download_info is not None: + # download_info is guaranteed to be set because when we build an + # InstallRequirement it has been through the preparer before, but + # let's be cautious. + wheel_cache.record_download_origin(cache_dir, req.download_info) + # Update the link for this. + req.link = Link(path_to_url(wheel_file)) + req.local_file_path = req.link.file_path + assert req.link.is_wheel + build_successes.append(req) + else: + build_failures.append(req) + + # notify success/failure + if build_successes: + logger.info( + "Successfully built %s", + " ".join([req.name for req in build_successes]), # type: ignore + ) + if build_failures: + logger.info( + "Failed to build %s", + " ".join([req.name for req in build_failures]), # type: ignore + ) + # Return a list of requirements that failed to build + return build_successes, build_failures diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/README.rst b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/README.rst new file mode 100644 index 0000000000000000000000000000000000000000..7429a52f46fb3a76f214744d79f0509be026b87a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/README.rst @@ -0,0 +1,178 @@ +================ +Vendoring Policy +================ + +* Vendored libraries **MUST** not be modified except as required to + successfully vendor them. +* Vendored libraries **MUST** be released copies of libraries available on + PyPI. +* Vendored libraries **MUST** be available under a license that allows + them to be integrated into ``pip``, which is released under the MIT license. +* Vendored libraries **MUST** be accompanied with LICENSE files. +* The versions of libraries vendored in pip **MUST** be reflected in + ``pip/_vendor/vendor.txt``. +* Vendored libraries **MUST** function without any build steps such as ``2to3`` + or compilation of C code, practically this limits to single source 2.x/3.x and + pure Python. +* Any modifications made to libraries **MUST** be noted in + ``pip/_vendor/README.rst`` and their corresponding patches **MUST** be + included ``tools/vendoring/patches``. +* Vendored libraries should have corresponding ``vendored()`` entries in + ``pip/_vendor/__init__.py``. + +Rationale +========= + +Historically pip has not had any dependencies except for ``setuptools`` itself, +choosing instead to implement any functionality it needed to prevent needing +a dependency. However, starting with pip 1.5, we began to replace code that was +implemented inside of pip with reusable libraries from PyPI. This brought the +typical benefits of reusing libraries instead of reinventing the wheel like +higher quality and more battle tested code, centralization of bug fixes +(particularly security sensitive ones), and better/more features for less work. + +However, there are several issues with having dependencies in the traditional +way (via ``install_requires``) for pip. These issues are: + +**Fragility** + When pip depends on another library to function then if for whatever reason + that library either isn't installed or an incompatible version is installed + then pip ceases to function. This is of course true for all Python + applications, however for every application *except* for pip the way you fix + it is by re-running pip. Obviously, when pip can't run, you can't use pip to + fix pip, so you're left having to manually resolve dependencies and + installing them by hand. + +**Making other libraries uninstallable** + One of pip's current dependencies is the ``requests`` library, for which pip + requires a fairly recent version to run. If pip depended on ``requests`` in + the traditional manner, then we'd either have to maintain compatibility with + every ``requests`` version that has ever existed (and ever will), OR allow + pip to render certain versions of ``requests`` uninstallable. (The second + issue, although technically true for any Python application, is magnified by + pip's ubiquity; pip is installed by default in Python, in ``pyvenv``, and in + ``virtualenv``.) + +**Security** + This might seem puzzling at first glance, since vendoring has a tendency to + complicate updating dependencies for security updates, and that holds true + for pip. However, given the *other* reasons for avoiding dependencies, the + alternative is for pip to reinvent the wheel itself. This is what pip did + historically. It forced pip to re-implement its own HTTPS verification + routines as a workaround for the Python standard library's lack of SSL + validation, which resulted in similar bugs in the validation routine in + ``requests`` and ``urllib3``, except that they had to be discovered and + fixed independently. Even though we're vendoring, reusing libraries keeps + pip more secure by relying on the great work of our dependencies, *and* + allowing for faster, easier security fixes by simply pulling in newer + versions of dependencies. + +**Bootstrapping** + Currently most popular methods of installing pip rely on pip's + self-contained nature to install pip itself. These tools work by bundling a + copy of pip, adding it to ``sys.path``, and then executing that copy of pip. + This is done instead of implementing a "mini installer" (to reduce + duplication); pip already knows how to install a Python package, and is far + more battle-tested than any "mini installer" could ever possibly be. + +Many downstream redistributors have policies against this kind of bundling, and +instead opt to patch the software they distribute to debundle it and make it +rely on the global versions of the software that they already have packaged +(which may have its own patches applied to it). We (the pip team) would prefer +it if pip was *not* debundled in this manner due to the above reasons and +instead we would prefer it if pip would be left intact as it is now. + +In the longer term, if someone has a *portable* solution to the above problems, +other than the bundling method we currently use, that doesn't add additional +problems that are unreasonable then we would be happy to consider, and possibly +switch to said method. This solution must function correctly across all of the +situation that we expect pip to be used and not mandate some external mechanism +such as OS packages. + + +Modifications +============= + +* ``setuptools`` is completely stripped to only keep ``pkg_resources``. +* ``pkg_resources`` has been modified to import its dependencies from + ``pip._vendor``, and to use the vendored copy of ``platformdirs`` + rather than ``appdirs``. +* ``packaging`` has been modified to import its dependencies from + ``pip._vendor``. +* ``CacheControl`` has been modified to import its dependencies from + ``pip._vendor``. +* ``requests`` has been modified to import its other dependencies from + ``pip._vendor`` and to *not* load ``simplejson`` (all platforms) and + ``pyopenssl`` (Windows). +* ``platformdirs`` has been modified to import its submodules from ``pip._vendor.platformdirs``. + +Automatic Vendoring +=================== + +Vendoring is automated via the `vendoring `_ tool from the content of +``pip/_vendor/vendor.txt`` and the different patches in +``tools/vendoring/patches``. +Launch it via ``vendoring sync . -v`` (requires ``vendoring>=0.2.2``). +Tool configuration is done via ``pyproject.toml``. + +To update the vendored library versions, we have a session defined in ``nox``. +The command to upgrade everything is:: + + nox -s vendoring -- --upgrade-all --skip setuptools + +We do not upgrade ``setuptools``, because we only rely on ``pkg_resources``, +and tracking every ``setuptools`` change is unnecessary for our needs. + + +Managing Local Patches +====================== + +The ``vendoring`` tool automatically applies our local patches, but updating, +the patches sometimes no longer apply cleanly. In that case, the update will +fail. To resolve this, take the following steps: + +1. Revert any incomplete changes in the revendoring branch, to ensure you have + a clean starting point. +2. Run the revendoring of the library with a problem again: ``nox -s vendoring + -- --upgrade ``. +3. This will fail again, but you will have the original source in your working + directory. Review the existing patch against the source, and modify the patch + to reflect the new version of the source. If you ``git add`` the changes the + vendoring made, you can modify the source to reflect the patch file and then + generate a new patch with ``git diff``. +4. Now, revert everything *except* the patch file changes. Leave the modified + patch file unstaged but saved in the working tree. +5. Re-run the vendoring. This time, it should pick up the changed patch file + and apply it cleanly. The patch file changes will be committed along with the + revendoring, so the new commit should be ready to test and publish as a PR. + + +Debundling +========== + +As mentioned in the rationale, we, the pip team, would prefer it if pip was not +debundled (other than optionally ``pip/_vendor/requests/cacert.pem``) and that +pip was left intact. However, if you insist on doing so, we have a +semi-supported method (that we don't test in our CI) and requires a bit of +extra work on your end in order to solve the problems described above. + +1. Delete everything in ``pip/_vendor/`` **except** for + ``pip/_vendor/__init__.py`` and ``pip/_vendor/vendor.txt``. +2. Generate wheels for each of pip's dependencies (and any of their + dependencies) using your patched copies of these libraries. These must be + placed somewhere on the filesystem that pip can access (``pip/_vendor`` is + the default assumption). +3. Modify ``pip/_vendor/__init__.py`` so that the ``DEBUNDLED`` variable is + ``True``. +4. Upon installation, the ``INSTALLER`` file in pip's own ``dist-info`` + directory should be set to something other than ``pip``, so that pip + can detect that it wasn't installed using itself. +5. *(optional)* If you've placed the wheels in a location other than + ``pip/_vendor/``, then modify ``pip/_vendor/__init__.py`` so that the + ``WHEEL_DIR`` variable points to the location you've placed them. +6. *(optional)* Update the ``pip_self_version_check`` logic to use the + appropriate logic for determining the latest available version of pip and + prompt the user with the correct upgrade message. + +Note that partial debundling is **NOT** supported. You need to prepare wheels +for all dependencies for successful debundling. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..34ccb99079139bf230b91f4f7b9303a34de6b717 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/__init__.py @@ -0,0 +1,117 @@ +""" +pip._vendor is for vendoring dependencies of pip to prevent needing pip to +depend on something external. + +Files inside of pip._vendor should be considered immutable and should only be +updated to versions from upstream. +""" +from __future__ import absolute_import + +import glob +import os.path +import sys + +# Downstream redistributors which have debundled our dependencies should also +# patch this value to be true. This will trigger the additional patching +# to cause things like "six" to be available as pip. +DEBUNDLED = False + +# By default, look in this directory for a bunch of .whl files which we will +# add to the beginning of sys.path before attempting to import anything. This +# is done to support downstream re-distributors like Debian and Fedora who +# wish to create their own Wheels for our dependencies to aid in debundling. +WHEEL_DIR = os.path.abspath(os.path.dirname(__file__)) + + +# Define a small helper function to alias our vendored modules to the real ones +# if the vendored ones do not exist. This idea of this was taken from +# https://github.com/kennethreitz/requests/pull/2567. +def vendored(modulename): + vendored_name = "{0}.{1}".format(__name__, modulename) + + try: + __import__(modulename, globals(), locals(), level=0) + except ImportError: + # We can just silently allow import failures to pass here. If we + # got to this point it means that ``import pip._vendor.whatever`` + # failed and so did ``import whatever``. Since we're importing this + # upfront in an attempt to alias imports, not erroring here will + # just mean we get a regular import error whenever pip *actually* + # tries to import one of these modules to use it, which actually + # gives us a better error message than we would have otherwise + # gotten. + pass + else: + sys.modules[vendored_name] = sys.modules[modulename] + base, head = vendored_name.rsplit(".", 1) + setattr(sys.modules[base], head, sys.modules[modulename]) + + +# If we're operating in a debundled setup, then we want to go ahead and trigger +# the aliasing of our vendored libraries as well as looking for wheels to add +# to our sys.path. This will cause all of this code to be a no-op typically +# however downstream redistributors can enable it in a consistent way across +# all platforms. +if DEBUNDLED: + # Actually look inside of WHEEL_DIR to find .whl files and add them to the + # front of our sys.path. + sys.path[:] = glob.glob(os.path.join(WHEEL_DIR, "*.whl")) + sys.path + + # Actually alias all of our vendored dependencies. + vendored("cachecontrol") + vendored("certifi") + vendored("dependency-groups") + vendored("distlib") + vendored("distro") + vendored("packaging") + vendored("packaging.version") + vendored("packaging.specifiers") + vendored("pkg_resources") + vendored("platformdirs") + vendored("progress") + vendored("pyproject_hooks") + vendored("requests") + vendored("requests.exceptions") + vendored("requests.packages") + vendored("requests.packages.urllib3") + vendored("requests.packages.urllib3._collections") + vendored("requests.packages.urllib3.connection") + vendored("requests.packages.urllib3.connectionpool") + vendored("requests.packages.urllib3.contrib") + vendored("requests.packages.urllib3.contrib.ntlmpool") + vendored("requests.packages.urllib3.contrib.pyopenssl") + vendored("requests.packages.urllib3.exceptions") + vendored("requests.packages.urllib3.fields") + vendored("requests.packages.urllib3.filepost") + vendored("requests.packages.urllib3.packages") + vendored("requests.packages.urllib3.packages.ordered_dict") + vendored("requests.packages.urllib3.packages.six") + vendored("requests.packages.urllib3.packages.ssl_match_hostname") + vendored("requests.packages.urllib3.packages.ssl_match_hostname." + "_implementation") + vendored("requests.packages.urllib3.poolmanager") + vendored("requests.packages.urllib3.request") + vendored("requests.packages.urllib3.response") + vendored("requests.packages.urllib3.util") + vendored("requests.packages.urllib3.util.connection") + vendored("requests.packages.urllib3.util.request") + vendored("requests.packages.urllib3.util.response") + vendored("requests.packages.urllib3.util.retry") + vendored("requests.packages.urllib3.util.ssl_") + vendored("requests.packages.urllib3.util.timeout") + vendored("requests.packages.urllib3.util.url") + vendored("resolvelib") + vendored("rich") + vendored("rich.console") + vendored("rich.highlighter") + vendored("rich.logging") + vendored("rich.markup") + vendored("rich.progress") + vendored("rich.segment") + vendored("rich.style") + vendored("rich.text") + vendored("rich.traceback") + if sys.version_info < (3, 11): + vendored("tomli") + vendored("truststore") + vendored("urllib3") diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/LICENSE.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/LICENSE.txt new file mode 100644 index 0000000000000000000000000000000000000000..d8b3b56d361cfaa04de6304c96c328f27266f74e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/LICENSE.txt @@ -0,0 +1,13 @@ +Copyright 2012-2021 Eric Larson + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/adapter.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/adapter.py new file mode 100644 index 0000000000000000000000000000000000000000..01f1253629e538b8abe56033a77c34ffbba2931e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/adapter.py @@ -0,0 +1,167 @@ +# SPDX-FileCopyrightText: 2015 Eric Larson +# +# SPDX-License-Identifier: Apache-2.0 +from __future__ import annotations + +import functools +import weakref +import zlib +from typing import TYPE_CHECKING, Any, Collection, Mapping + +from pip._vendor.requests.adapters import HTTPAdapter + +from pip._vendor.cachecontrol.cache import DictCache +from pip._vendor.cachecontrol.controller import PERMANENT_REDIRECT_STATUSES, CacheController +from pip._vendor.cachecontrol.filewrapper import CallbackFileWrapper + +if TYPE_CHECKING: + from pip._vendor.requests import PreparedRequest, Response + from pip._vendor.urllib3 import HTTPResponse + + from pip._vendor.cachecontrol.cache import BaseCache + from pip._vendor.cachecontrol.heuristics import BaseHeuristic + from pip._vendor.cachecontrol.serialize import Serializer + + +class CacheControlAdapter(HTTPAdapter): + invalidating_methods = {"PUT", "PATCH", "DELETE"} + + def __init__( + self, + cache: BaseCache | None = None, + cache_etags: bool = True, + controller_class: type[CacheController] | None = None, + serializer: Serializer | None = None, + heuristic: BaseHeuristic | None = None, + cacheable_methods: Collection[str] | None = None, + *args: Any, + **kw: Any, + ) -> None: + super().__init__(*args, **kw) + self.cache = DictCache() if cache is None else cache + self.heuristic = heuristic + self.cacheable_methods = cacheable_methods or ("GET",) + + controller_factory = controller_class or CacheController + self.controller = controller_factory( + self.cache, cache_etags=cache_etags, serializer=serializer + ) + + def send( + self, + request: PreparedRequest, + stream: bool = False, + timeout: None | float | tuple[float, float] | tuple[float, None] = None, + verify: bool | str = True, + cert: (None | bytes | str | tuple[bytes | str, bytes | str]) = None, + proxies: Mapping[str, str] | None = None, + cacheable_methods: Collection[str] | None = None, + ) -> Response: + """ + Send a request. Use the request information to see if it + exists in the cache and cache the response if we need to and can. + """ + cacheable = cacheable_methods or self.cacheable_methods + if request.method in cacheable: + try: + cached_response = self.controller.cached_request(request) + except zlib.error: + cached_response = None + if cached_response: + return self.build_response(request, cached_response, from_cache=True) + + # check for etags and add headers if appropriate + request.headers.update(self.controller.conditional_headers(request)) + + resp = super().send(request, stream, timeout, verify, cert, proxies) + + return resp + + def build_response( # type: ignore[override] + self, + request: PreparedRequest, + response: HTTPResponse, + from_cache: bool = False, + cacheable_methods: Collection[str] | None = None, + ) -> Response: + """ + Build a response by making a request or using the cache. + + This will end up calling send and returning a potentially + cached response + """ + cacheable = cacheable_methods or self.cacheable_methods + if not from_cache and request.method in cacheable: + # Check for any heuristics that might update headers + # before trying to cache. + if self.heuristic: + response = self.heuristic.apply(response) + + # apply any expiration heuristics + if response.status == 304: + # We must have sent an ETag request. This could mean + # that we've been expired already or that we simply + # have an etag. In either case, we want to try and + # update the cache if that is the case. + cached_response = self.controller.update_cached_response( + request, response + ) + + if cached_response is not response: + from_cache = True + + # We are done with the server response, read a + # possible response body (compliant servers will + # not return one, but we cannot be 100% sure) and + # release the connection back to the pool. + response.read(decode_content=False) + response.release_conn() + + response = cached_response + + # We always cache the 301 responses + elif int(response.status) in PERMANENT_REDIRECT_STATUSES: + self.controller.cache_response(request, response) + else: + # Wrap the response file with a wrapper that will cache the + # response when the stream has been consumed. + response._fp = CallbackFileWrapper( # type: ignore[assignment] + response._fp, # type: ignore[arg-type] + functools.partial( + self.controller.cache_response, request, weakref.ref(response) + ), + ) + if response.chunked: + super_update_chunk_length = response.__class__._update_chunk_length + + def _update_chunk_length( + weak_self: weakref.ReferenceType[HTTPResponse], + ) -> None: + self = weak_self() + if self is None: + return + + super_update_chunk_length(self) + if self.chunk_left == 0: + self._fp._close() # type: ignore[union-attr] + + response._update_chunk_length = functools.partial( # type: ignore[method-assign] + _update_chunk_length, weakref.ref(response) + ) + + resp: Response = super().build_response(request, response) + + # See if we should invalidate the cache. + if request.method in self.invalidating_methods and resp.ok: + assert request.url is not None + cache_url = self.controller.cache_url(request.url) + self.cache.delete(cache_url) + + # Give the request a from_cache attr to let people use it + resp.from_cache = from_cache # type: ignore[attr-defined] + + return resp + + def close(self) -> None: + self.cache.close() + super().close() # type: ignore[no-untyped-call] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/cache.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/cache.py new file mode 100644 index 0000000000000000000000000000000000000000..91598e92034fa4f70353fbf7c9c19dc9558e320b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/cache.py @@ -0,0 +1,75 @@ +# SPDX-FileCopyrightText: 2015 Eric Larson +# +# SPDX-License-Identifier: Apache-2.0 + +""" +The cache object API for implementing caches. The default is a thread +safe in-memory dictionary. +""" + +from __future__ import annotations + +from threading import Lock +from typing import IO, TYPE_CHECKING, MutableMapping + +if TYPE_CHECKING: + from datetime import datetime + + +class BaseCache: + def get(self, key: str) -> bytes | None: + raise NotImplementedError() + + def set( + self, key: str, value: bytes, expires: int | datetime | None = None + ) -> None: + raise NotImplementedError() + + def delete(self, key: str) -> None: + raise NotImplementedError() + + def close(self) -> None: + pass + + +class DictCache(BaseCache): + def __init__(self, init_dict: MutableMapping[str, bytes] | None = None) -> None: + self.lock = Lock() + self.data = init_dict or {} + + def get(self, key: str) -> bytes | None: + return self.data.get(key, None) + + def set( + self, key: str, value: bytes, expires: int | datetime | None = None + ) -> None: + with self.lock: + self.data.update({key: value}) + + def delete(self, key: str) -> None: + with self.lock: + if key in self.data: + self.data.pop(key) + + +class SeparateBodyBaseCache(BaseCache): + """ + In this variant, the body is not stored mixed in with the metadata, but is + passed in (as a bytes-like object) in a separate call to ``set_body()``. + + That is, the expected interaction pattern is:: + + cache.set(key, serialized_metadata) + cache.set_body(key) + + Similarly, the body should be loaded separately via ``get_body()``. + """ + + def set_body(self, key: str, body: bytes) -> None: + raise NotImplementedError() + + def get_body(self, key: str) -> IO[bytes] | None: + """ + Return the body as file-like object. + """ + raise NotImplementedError() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/controller.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/controller.py new file mode 100644 index 0000000000000000000000000000000000000000..0bf380136aea0e32c90fe5a07c8f4991d3ba990f --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/controller.py @@ -0,0 +1,511 @@ +# SPDX-FileCopyrightText: 2015 Eric Larson +# +# SPDX-License-Identifier: Apache-2.0 + +""" +The httplib2 algorithms ported for use with requests. +""" + +from __future__ import annotations + +import calendar +import logging +import re +import time +import weakref +from email.utils import parsedate_tz +from typing import TYPE_CHECKING, Collection, Mapping + +from pip._vendor.requests.structures import CaseInsensitiveDict + +from pip._vendor.cachecontrol.cache import DictCache, SeparateBodyBaseCache +from pip._vendor.cachecontrol.serialize import Serializer + +if TYPE_CHECKING: + from typing import Literal + + from pip._vendor.requests import PreparedRequest + from pip._vendor.urllib3 import HTTPResponse + + from pip._vendor.cachecontrol.cache import BaseCache + +logger = logging.getLogger(__name__) + +URI = re.compile(r"^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?") + +PERMANENT_REDIRECT_STATUSES = (301, 308) + + +def parse_uri(uri: str) -> tuple[str, str, str, str, str]: + """Parses a URI using the regex given in Appendix B of RFC 3986. + + (scheme, authority, path, query, fragment) = parse_uri(uri) + """ + match = URI.match(uri) + assert match is not None + groups = match.groups() + return (groups[1], groups[3], groups[4], groups[6], groups[8]) + + +class CacheController: + """An interface to see if request should cached or not.""" + + def __init__( + self, + cache: BaseCache | None = None, + cache_etags: bool = True, + serializer: Serializer | None = None, + status_codes: Collection[int] | None = None, + ): + self.cache = DictCache() if cache is None else cache + self.cache_etags = cache_etags + self.serializer = serializer or Serializer() + self.cacheable_status_codes = status_codes or (200, 203, 300, 301, 308) + + @classmethod + def _urlnorm(cls, uri: str) -> str: + """Normalize the URL to create a safe key for the cache""" + (scheme, authority, path, query, fragment) = parse_uri(uri) + if not scheme or not authority: + raise Exception("Only absolute URIs are allowed. uri = %s" % uri) + + scheme = scheme.lower() + authority = authority.lower() + + if not path: + path = "/" + + # Could do syntax based normalization of the URI before + # computing the digest. See Section 6.2.2 of Std 66. + request_uri = query and "?".join([path, query]) or path + defrag_uri = scheme + "://" + authority + request_uri + + return defrag_uri + + @classmethod + def cache_url(cls, uri: str) -> str: + return cls._urlnorm(uri) + + def parse_cache_control(self, headers: Mapping[str, str]) -> dict[str, int | None]: + known_directives = { + # https://tools.ietf.org/html/rfc7234#section-5.2 + "max-age": (int, True), + "max-stale": (int, False), + "min-fresh": (int, True), + "no-cache": (None, False), + "no-store": (None, False), + "no-transform": (None, False), + "only-if-cached": (None, False), + "must-revalidate": (None, False), + "public": (None, False), + "private": (None, False), + "proxy-revalidate": (None, False), + "s-maxage": (int, True), + } + + cc_headers = headers.get("cache-control", headers.get("Cache-Control", "")) + + retval: dict[str, int | None] = {} + + for cc_directive in cc_headers.split(","): + if not cc_directive.strip(): + continue + + parts = cc_directive.split("=", 1) + directive = parts[0].strip() + + try: + typ, required = known_directives[directive] + except KeyError: + logger.debug("Ignoring unknown cache-control directive: %s", directive) + continue + + if not typ or not required: + retval[directive] = None + if typ: + try: + retval[directive] = typ(parts[1].strip()) + except IndexError: + if required: + logger.debug( + "Missing value for cache-control " "directive: %s", + directive, + ) + except ValueError: + logger.debug( + "Invalid value for cache-control directive " "%s, must be %s", + directive, + typ.__name__, + ) + + return retval + + def _load_from_cache(self, request: PreparedRequest) -> HTTPResponse | None: + """ + Load a cached response, or return None if it's not available. + """ + # We do not support caching of partial content: so if the request contains a + # Range header then we don't want to load anything from the cache. + if "Range" in request.headers: + return None + + cache_url = request.url + assert cache_url is not None + cache_data = self.cache.get(cache_url) + if cache_data is None: + logger.debug("No cache entry available") + return None + + if isinstance(self.cache, SeparateBodyBaseCache): + body_file = self.cache.get_body(cache_url) + else: + body_file = None + + result = self.serializer.loads(request, cache_data, body_file) + if result is None: + logger.warning("Cache entry deserialization failed, entry ignored") + return result + + def cached_request(self, request: PreparedRequest) -> HTTPResponse | Literal[False]: + """ + Return a cached response if it exists in the cache, otherwise + return False. + """ + assert request.url is not None + cache_url = self.cache_url(request.url) + logger.debug('Looking up "%s" in the cache', cache_url) + cc = self.parse_cache_control(request.headers) + + # Bail out if the request insists on fresh data + if "no-cache" in cc: + logger.debug('Request header has "no-cache", cache bypassed') + return False + + if "max-age" in cc and cc["max-age"] == 0: + logger.debug('Request header has "max_age" as 0, cache bypassed') + return False + + # Check whether we can load the response from the cache: + resp = self._load_from_cache(request) + if not resp: + return False + + # If we have a cached permanent redirect, return it immediately. We + # don't need to test our response for other headers b/c it is + # intrinsically "cacheable" as it is Permanent. + # + # See: + # https://tools.ietf.org/html/rfc7231#section-6.4.2 + # + # Client can try to refresh the value by repeating the request + # with cache busting headers as usual (ie no-cache). + if int(resp.status) in PERMANENT_REDIRECT_STATUSES: + msg = ( + "Returning cached permanent redirect response " + "(ignoring date and etag information)" + ) + logger.debug(msg) + return resp + + headers: CaseInsensitiveDict[str] = CaseInsensitiveDict(resp.headers) + if not headers or "date" not in headers: + if "etag" not in headers: + # Without date or etag, the cached response can never be used + # and should be deleted. + logger.debug("Purging cached response: no date or etag") + self.cache.delete(cache_url) + logger.debug("Ignoring cached response: no date") + return False + + now = time.time() + time_tuple = parsedate_tz(headers["date"]) + assert time_tuple is not None + date = calendar.timegm(time_tuple[:6]) + current_age = max(0, now - date) + logger.debug("Current age based on date: %i", current_age) + + # TODO: There is an assumption that the result will be a + # urllib3 response object. This may not be best since we + # could probably avoid instantiating or constructing the + # response until we know we need it. + resp_cc = self.parse_cache_control(headers) + + # determine freshness + freshness_lifetime = 0 + + # Check the max-age pragma in the cache control header + max_age = resp_cc.get("max-age") + if max_age is not None: + freshness_lifetime = max_age + logger.debug("Freshness lifetime from max-age: %i", freshness_lifetime) + + # If there isn't a max-age, check for an expires header + elif "expires" in headers: + expires = parsedate_tz(headers["expires"]) + if expires is not None: + expire_time = calendar.timegm(expires[:6]) - date + freshness_lifetime = max(0, expire_time) + logger.debug("Freshness lifetime from expires: %i", freshness_lifetime) + + # Determine if we are setting freshness limit in the + # request. Note, this overrides what was in the response. + max_age = cc.get("max-age") + if max_age is not None: + freshness_lifetime = max_age + logger.debug( + "Freshness lifetime from request max-age: %i", freshness_lifetime + ) + + min_fresh = cc.get("min-fresh") + if min_fresh is not None: + # adjust our current age by our min fresh + current_age += min_fresh + logger.debug("Adjusted current age from min-fresh: %i", current_age) + + # Return entry if it is fresh enough + if freshness_lifetime > current_age: + logger.debug('The response is "fresh", returning cached response') + logger.debug("%i > %i", freshness_lifetime, current_age) + return resp + + # we're not fresh. If we don't have an Etag, clear it out + if "etag" not in headers: + logger.debug('The cached response is "stale" with no etag, purging') + self.cache.delete(cache_url) + + # return the original handler + return False + + def conditional_headers(self, request: PreparedRequest) -> dict[str, str]: + resp = self._load_from_cache(request) + new_headers = {} + + if resp: + headers: CaseInsensitiveDict[str] = CaseInsensitiveDict(resp.headers) + + if "etag" in headers: + new_headers["If-None-Match"] = headers["ETag"] + + if "last-modified" in headers: + new_headers["If-Modified-Since"] = headers["Last-Modified"] + + return new_headers + + def _cache_set( + self, + cache_url: str, + request: PreparedRequest, + response: HTTPResponse, + body: bytes | None = None, + expires_time: int | None = None, + ) -> None: + """ + Store the data in the cache. + """ + if isinstance(self.cache, SeparateBodyBaseCache): + # We pass in the body separately; just put a placeholder empty + # string in the metadata. + self.cache.set( + cache_url, + self.serializer.dumps(request, response, b""), + expires=expires_time, + ) + # body is None can happen when, for example, we're only updating + # headers, as is the case in update_cached_response(). + if body is not None: + self.cache.set_body(cache_url, body) + else: + self.cache.set( + cache_url, + self.serializer.dumps(request, response, body), + expires=expires_time, + ) + + def cache_response( + self, + request: PreparedRequest, + response_or_ref: HTTPResponse | weakref.ReferenceType[HTTPResponse], + body: bytes | None = None, + status_codes: Collection[int] | None = None, + ) -> None: + """ + Algorithm for caching requests. + + This assumes a requests Response object. + """ + if isinstance(response_or_ref, weakref.ReferenceType): + response = response_or_ref() + if response is None: + # The weakref can be None only in case the user used streamed request + # and did not consume or close it, and holds no reference to requests.Response. + # In such case, we don't want to cache the response. + return + else: + response = response_or_ref + + # From httplib2: Don't cache 206's since we aren't going to + # handle byte range requests + cacheable_status_codes = status_codes or self.cacheable_status_codes + if response.status not in cacheable_status_codes: + logger.debug( + "Status code %s not in %s", response.status, cacheable_status_codes + ) + return + + response_headers: CaseInsensitiveDict[str] = CaseInsensitiveDict( + response.headers + ) + + if "date" in response_headers: + time_tuple = parsedate_tz(response_headers["date"]) + assert time_tuple is not None + date = calendar.timegm(time_tuple[:6]) + else: + date = 0 + + # If we've been given a body, our response has a Content-Length, that + # Content-Length is valid then we can check to see if the body we've + # been given matches the expected size, and if it doesn't we'll just + # skip trying to cache it. + if ( + body is not None + and "content-length" in response_headers + and response_headers["content-length"].isdigit() + and int(response_headers["content-length"]) != len(body) + ): + return + + cc_req = self.parse_cache_control(request.headers) + cc = self.parse_cache_control(response_headers) + + assert request.url is not None + cache_url = self.cache_url(request.url) + logger.debug('Updating cache with response from "%s"', cache_url) + + # Delete it from the cache if we happen to have it stored there + no_store = False + if "no-store" in cc: + no_store = True + logger.debug('Response header has "no-store"') + if "no-store" in cc_req: + no_store = True + logger.debug('Request header has "no-store"') + if no_store and self.cache.get(cache_url): + logger.debug('Purging existing cache entry to honor "no-store"') + self.cache.delete(cache_url) + if no_store: + return + + # https://tools.ietf.org/html/rfc7234#section-4.1: + # A Vary header field-value of "*" always fails to match. + # Storing such a response leads to a deserialization warning + # during cache lookup and is not allowed to ever be served, + # so storing it can be avoided. + if "*" in response_headers.get("vary", ""): + logger.debug('Response header has "Vary: *"') + return + + # If we've been given an etag, then keep the response + if self.cache_etags and "etag" in response_headers: + expires_time = 0 + if response_headers.get("expires"): + expires = parsedate_tz(response_headers["expires"]) + if expires is not None: + expires_time = calendar.timegm(expires[:6]) - date + + expires_time = max(expires_time, 14 * 86400) + + logger.debug(f"etag object cached for {expires_time} seconds") + logger.debug("Caching due to etag") + self._cache_set(cache_url, request, response, body, expires_time) + + # Add to the cache any permanent redirects. We do this before looking + # that the Date headers. + elif int(response.status) in PERMANENT_REDIRECT_STATUSES: + logger.debug("Caching permanent redirect") + self._cache_set(cache_url, request, response, b"") + + # Add to the cache if the response headers demand it. If there + # is no date header then we can't do anything about expiring + # the cache. + elif "date" in response_headers: + time_tuple = parsedate_tz(response_headers["date"]) + assert time_tuple is not None + date = calendar.timegm(time_tuple[:6]) + # cache when there is a max-age > 0 + max_age = cc.get("max-age") + if max_age is not None and max_age > 0: + logger.debug("Caching b/c date exists and max-age > 0") + expires_time = max_age + self._cache_set( + cache_url, + request, + response, + body, + expires_time, + ) + + # If the request can expire, it means we should cache it + # in the meantime. + elif "expires" in response_headers: + if response_headers["expires"]: + expires = parsedate_tz(response_headers["expires"]) + if expires is not None: + expires_time = calendar.timegm(expires[:6]) - date + else: + expires_time = None + + logger.debug( + "Caching b/c of expires header. expires in {} seconds".format( + expires_time + ) + ) + self._cache_set( + cache_url, + request, + response, + body, + expires_time, + ) + + def update_cached_response( + self, request: PreparedRequest, response: HTTPResponse + ) -> HTTPResponse: + """On a 304 we will get a new set of headers that we want to + update our cached value with, assuming we have one. + + This should only ever be called when we've sent an ETag and + gotten a 304 as the response. + """ + assert request.url is not None + cache_url = self.cache_url(request.url) + cached_response = self._load_from_cache(request) + + if not cached_response: + # we didn't have a cached response + return response + + # Lets update our headers with the headers from the new request: + # http://tools.ietf.org/html/draft-ietf-httpbis-p4-conditional-26#section-4.1 + # + # The server isn't supposed to send headers that would make + # the cached body invalid. But... just in case, we'll be sure + # to strip out ones we know that might be problematic due to + # typical assumptions. + excluded_headers = ["content-length"] + + cached_response.headers.update( + { + k: v + for k, v in response.headers.items() + if k.lower() not in excluded_headers + } + ) + + # we want a 200 b/c we have content via the cache + cached_response.status = 200 + + # update our cache + self._cache_set(cache_url, request, cached_response) + + return cached_response diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/filewrapper.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/filewrapper.py new file mode 100644 index 0000000000000000000000000000000000000000..6569fb5cd88d922c67acc18bd8b32275f8ad2645 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/filewrapper.py @@ -0,0 +1,121 @@ +# SPDX-FileCopyrightText: 2015 Eric Larson +# +# SPDX-License-Identifier: Apache-2.0 +from __future__ import annotations + +import mmap +from tempfile import NamedTemporaryFile +from typing import TYPE_CHECKING, Any, Callable + +if TYPE_CHECKING: + from collections.abc import Buffer + from http.client import HTTPResponse + + +class CallbackFileWrapper: + """ + Small wrapper around a fp object which will tee everything read into a + buffer, and when that file is closed it will execute a callback with the + contents of that buffer. + + All attributes are proxied to the underlying file object. + + This class uses members with a double underscore (__) leading prefix so as + not to accidentally shadow an attribute. + + The data is stored in a temporary file until it is all available. As long + as the temporary files directory is disk-based (sometimes it's a + memory-backed-``tmpfs`` on Linux), data will be unloaded to disk if memory + pressure is high. For small files the disk usually won't be used at all, + it'll all be in the filesystem memory cache, so there should be no + performance impact. + """ + + def __init__( + self, fp: HTTPResponse, callback: Callable[[Buffer], None] | None + ) -> None: + self.__buf = NamedTemporaryFile("rb+", delete=True) + self.__fp = fp + self.__callback = callback + + def __getattr__(self, name: str) -> Any: + # The vagaries of garbage collection means that self.__fp is + # not always set. By using __getattribute__ and the private + # name[0] allows looking up the attribute value and raising an + # AttributeError when it doesn't exist. This stop things from + # infinitely recursing calls to getattr in the case where + # self.__fp hasn't been set. + # + # [0] https://docs.python.org/2/reference/expressions.html#atom-identifiers + fp = self.__getattribute__("_CallbackFileWrapper__fp") + return getattr(fp, name) + + def __is_fp_closed(self) -> bool: + try: + return self.__fp.fp is None + + except AttributeError: + pass + + try: + closed: bool = self.__fp.closed + return closed + + except AttributeError: + pass + + # We just don't cache it then. + # TODO: Add some logging here... + return False + + def _close(self) -> None: + result: Buffer + if self.__callback: + if self.__buf.tell() == 0: + # Empty file: + result = b"" + else: + # Return the data without actually loading it into memory, + # relying on Python's buffer API and mmap(). mmap() just gives + # a view directly into the filesystem's memory cache, so it + # doesn't result in duplicate memory use. + self.__buf.seek(0, 0) + result = memoryview( + mmap.mmap(self.__buf.fileno(), 0, access=mmap.ACCESS_READ) + ) + self.__callback(result) + + # We assign this to None here, because otherwise we can get into + # really tricky problems where the CPython interpreter dead locks + # because the callback is holding a reference to something which + # has a __del__ method. Setting this to None breaks the cycle + # and allows the garbage collector to do it's thing normally. + self.__callback = None + + # Closing the temporary file releases memory and frees disk space. + # Important when caching big files. + self.__buf.close() + + def read(self, amt: int | None = None) -> bytes: + data: bytes = self.__fp.read(amt) + if data: + # We may be dealing with b'', a sign that things are over: + # it's passed e.g. after we've already closed self.__buf. + self.__buf.write(data) + if self.__is_fp_closed(): + self._close() + + return data + + def _safe_read(self, amt: int) -> bytes: + data: bytes = self.__fp._safe_read(amt) # type: ignore[attr-defined] + if amt == 2 and data == b"\r\n": + # urllib executes this read to toss the CRLF at the end + # of the chunk. + return data + + self.__buf.write(data) + if self.__is_fp_closed(): + self._close() + + return data diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/heuristics.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/heuristics.py new file mode 100644 index 0000000000000000000000000000000000000000..b778c4f3f7ad5e22fca433be02a824446fb47ff5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/cachecontrol/heuristics.py @@ -0,0 +1,157 @@ +# SPDX-FileCopyrightText: 2015 Eric Larson +# +# SPDX-License-Identifier: Apache-2.0 +from __future__ import annotations + +import calendar +import time +from datetime import datetime, timedelta, timezone +from email.utils import formatdate, parsedate, parsedate_tz +from typing import TYPE_CHECKING, Any, Mapping + +if TYPE_CHECKING: + from pip._vendor.urllib3 import HTTPResponse + +TIME_FMT = "%a, %d %b %Y %H:%M:%S GMT" + + +def expire_after(delta: timedelta, date: datetime | None = None) -> datetime: + date = date or datetime.now(timezone.utc) + return date + delta + + +def datetime_to_header(dt: datetime) -> str: + return formatdate(calendar.timegm(dt.timetuple())) + + +class BaseHeuristic: + def warning(self, response: HTTPResponse) -> str | None: + """ + Return a valid 1xx warning header value describing the cache + adjustments. + + The response is provided too allow warnings like 113 + http://tools.ietf.org/html/rfc7234#section-5.5.4 where we need + to explicitly say response is over 24 hours old. + """ + return '110 - "Response is Stale"' + + def update_headers(self, response: HTTPResponse) -> dict[str, str]: + """Update the response headers with any new headers. + + NOTE: This SHOULD always include some Warning header to + signify that the response was cached by the client, not + by way of the provided headers. + """ + return {} + + def apply(self, response: HTTPResponse) -> HTTPResponse: + updated_headers = self.update_headers(response) + + if updated_headers: + response.headers.update(updated_headers) + warning_header_value = self.warning(response) + if warning_header_value is not None: + response.headers.update({"Warning": warning_header_value}) + + return response + + +class OneDayCache(BaseHeuristic): + """ + Cache the response by providing an expires 1 day in the + future. + """ + + def update_headers(self, response: HTTPResponse) -> dict[str, str]: + headers = {} + + if "expires" not in response.headers: + date = parsedate(response.headers["date"]) + expires = expire_after( + timedelta(days=1), + date=datetime(*date[:6], tzinfo=timezone.utc), # type: ignore[index,misc] + ) + headers["expires"] = datetime_to_header(expires) + headers["cache-control"] = "public" + return headers + + +class ExpiresAfter(BaseHeuristic): + """ + Cache **all** requests for a defined time period. + """ + + def __init__(self, **kw: Any) -> None: + self.delta = timedelta(**kw) + + def update_headers(self, response: HTTPResponse) -> dict[str, str]: + expires = expire_after(self.delta) + return {"expires": datetime_to_header(expires), "cache-control": "public"} + + def warning(self, response: HTTPResponse) -> str | None: + tmpl = "110 - Automatically cached for %s. Response might be stale" + return tmpl % self.delta + + +class LastModified(BaseHeuristic): + """ + If there is no Expires header already, fall back on Last-Modified + using the heuristic from + http://tools.ietf.org/html/rfc7234#section-4.2.2 + to calculate a reasonable value. + + Firefox also does something like this per + https://developer.mozilla.org/en-US/docs/Web/HTTP/Caching_FAQ + http://lxr.mozilla.org/mozilla-release/source/netwerk/protocol/http/nsHttpResponseHead.cpp#397 + Unlike mozilla we limit this to 24-hr. + """ + + cacheable_by_default_statuses = { + 200, + 203, + 204, + 206, + 300, + 301, + 404, + 405, + 410, + 414, + 501, + } + + def update_headers(self, resp: HTTPResponse) -> dict[str, str]: + headers: Mapping[str, str] = resp.headers + + if "expires" in headers: + return {} + + if "cache-control" in headers and headers["cache-control"] != "public": + return {} + + if resp.status not in self.cacheable_by_default_statuses: + return {} + + if "date" not in headers or "last-modified" not in headers: + return {} + + time_tuple = parsedate_tz(headers["date"]) + assert time_tuple is not None + date = calendar.timegm(time_tuple[:6]) + last_modified = parsedate(headers["last-modified"]) + if last_modified is None: + return {} + + now = time.time() + current_age = max(0, now - date) + delta = date - calendar.timegm(last_modified) + freshness_lifetime = max(0, min(delta / 10, 24 * 3600)) + if freshness_lifetime <= current_age: + return {} + + expires = date + freshness_lifetime + return {"expires": time.strftime(TIME_FMT, time.gmtime(expires))} + + def warning(self, resp: HTTPResponse) -> str | None: + return None diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/vendor.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/vendor.txt new file mode 100644 index 0000000000000000000000000000000000000000..4e85aef47935e7d4b15eb3de633d68cb43bc7069 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/_vendor/vendor.txt @@ -0,0 +1,18 @@ +CacheControl==0.14.4 +distlib==0.4.0 +distro==1.9.0 +msgpack==1.1.2 +packaging==26.2 +platformdirs==4.5.1 +pyproject-hooks==1.2.0 +requests==2.33.1 + certifi==2026.2.25 + idna==3.11 + urllib3==2.6.3 +rich==14.2.0 + pygments==2.19.2 +resolvelib==1.2.1 +setuptools==70.3.0 +tomli==2.3.1 +tomli-w==1.2.0 +truststore==0.10.4 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/py.typed b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/py.typed new file mode 100644 index 0000000000000000000000000000000000000000..493b53e4e7a3984ddd49780313bf3bd9901dc1e0 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0/site-packages/pip/py.typed @@ -0,0 +1,4 @@ +pip is a command line program. While it is implemented in Python, and so is +available for import, you must not use pip's internal APIs in this way. Typing +information is provided as a convenience only and is not a guarantee. Expect +unannounced changes to the API and types in releases. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/about.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/about.json new file mode 100644 index 0000000000000000000000000000000000000000..556deb268549f34b9364972b9ab8b8c1759c2ece --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/about.json @@ -0,0 +1,19 @@ +{ + "channels": [ + "https://conda.anaconda.org/conda-forge/" + ], + "dev_url": "https://github.com/tox-dev/platformdirs", + "extra": { + "flow_run_id": "github_24192627818", + "recipe-maintainers": [ + "adament", + "gaborbernat", + "bollwyvl" + ], + "remote_url": "https://github.com/conda-forge/platformdirs-feedstock", + "sha": "9b615fad9b0c0b266170328bbf374a0600845ddd" + }, + "home": "https://pypi.org/project/platformdirs", + "license": "MIT", + "summary": "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/hash_input.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/hash_input.json new file mode 100644 index 0000000000000000000000000000000000000000..8cab3e9c53cdf587ba644746533a696e1ec88e46 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/hash_input.json @@ -0,0 +1 @@ +{"channel_sources": "conda-forge", "channel_targets": "conda-forge main", "python_min": "3.10", "target_platform": "noarch"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/index.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/index.json new file mode 100644 index 0000000000000000000000000000000000000000..25f341bc2d0f3f41c2b782f52cb136c43697ee41 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/index.json @@ -0,0 +1,14 @@ +{ + "build": "pyhcf101f3_0", + "build_number": 0, + "depends": [ + "python >=3.10", + "python" + ], + "license": "MIT", + "name": "platformdirs", + "noarch": "python", + "subdir": "noarch", + "timestamp": 1775741140609, + "version": "4.9.6" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..f35fed9191b1142ddaada8a96de4a9461c5d796c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/licenses/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2010-202x The platformdirs developers + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/link.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/link.json new file mode 100644 index 0000000000000000000000000000000000000000..ec6589c68a1bf1aedb3f856ab584e80f5302f2cb --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/link.json @@ -0,0 +1,6 @@ +{ + "noarch": { + "type": "python" + }, + "package_metadata_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/paths.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/paths.json new file mode 100644 index 0000000000000000000000000000000000000000..75386bfdd8c02567f9617927a80cb5136719d303 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/paths.json @@ -0,0 +1,107 @@ +{ + "paths": [ + { + "_path": "site-packages/platformdirs/__init__.py", + "path_type": "hardlink", + "sha256": "84bfd9ca1b10e447d87f85bf4ebe0ee85d2500e28bbd08b44d9e1efd618221ce", + "size_in_bytes": 30718 + }, + { + "_path": "site-packages/platformdirs/__main__.py", + "path_type": "hardlink", + "sha256": "32f33a7ca2690407a24d97243491928a15c52a44b8ead4bdfcfe60c92660dd12", + "size_in_bytes": 1633 + }, + { + "_path": "site-packages/platformdirs/_xdg.py", + "path_type": "hardlink", + "sha256": "bcd05be15b29defc791e879cb18194c15b01d5b7d8b6165c8d1939d452d851ea", + "size_in_bytes": 6391 + }, + { + "_path": "site-packages/platformdirs/android.py", + "path_type": "hardlink", + "sha256": "9db10963877236317e38ce516a50345892101c2532f0e2a2a060d2f46ffe6468", + "size_in_bytes": 10591 + }, + { + "_path": "site-packages/platformdirs/api.py", + "path_type": "hardlink", + "sha256": "d0b90b3a526d6ea120949169cb29d63facd2303117db76a47491117130f15967", + "size_in_bytes": 13415 + }, + { + "_path": "site-packages/platformdirs/macos.py", + "path_type": "hardlink", + "sha256": "237e96b3034f28c00016f1b9eec453babd0d6e75e957f86186ea52c7d3f880ec", + "size_in_bytes": 8090 + }, + { + "_path": "site-packages/platformdirs/py.typed", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/platformdirs/unix.py", + "path_type": "hardlink", + "sha256": "4204f13fc13038079a2a99c281774d67d7e79a72a97a87b5202bff7b57c5a2fe", + "size_in_bytes": 12259 + }, + { + "_path": "site-packages/platformdirs/version.py", + "path_type": "hardlink", + "sha256": "5c04c5705d8cf88917e5a33459c1d8440d5f91c1755d65e8342d581b56cf6e4d", + "size_in_bytes": 704 + }, + { + "_path": "site-packages/platformdirs/windows.py", + "path_type": "hardlink", + "sha256": "7901646ce711708e58a6598fc79f4539def25c9961ab6ecfa4bec755a0bbb1ee", + "size_in_bytes": 14564 + }, + { + "_path": "site-packages/platformdirs-4.9.6.dist-info/INSTALLER", + "path_type": "hardlink", + "sha256": "bc33022edcb7639ff53355b4e91dade50a0bbf0299efeb6171d1ec0ba5029cfc", + "size_in_bytes": 6 + }, + { + "_path": "site-packages/platformdirs-4.9.6.dist-info/METADATA", + "path_type": "hardlink", + "sha256": "7dc437d6904fab5d1b6527ac1bdfe03044e9ad53649dadc143471a6f2472927c", + "size_in_bytes": 4683 + }, + { + "_path": "site-packages/platformdirs-4.9.6.dist-info/RECORD", + "path_type": "hardlink", + "sha256": "1aa6b005909aed8fefa56a3de40e7618933727583e65e011238b819911b1e38e", + "size_in_bytes": 1871 + }, + { + "_path": "site-packages/platformdirs-4.9.6.dist-info/REQUESTED", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/platformdirs-4.9.6.dist-info/WHEEL", + "path_type": "hardlink", + "sha256": "41c708c5adba6e097513ab8ccb9f1d7865a2fb469e22491a9e01dcc64da459fc", + "size_in_bytes": 87 + }, + { + "_path": "site-packages/platformdirs-4.9.6.dist-info/direct_url.json", + "path_type": "hardlink", + "sha256": "ec02d65768695d261323ee1224c785b652320819f9a9df35a6f9c5c3ccae6a60", + "size_in_bytes": 123 + }, + { + "_path": "site-packages/platformdirs-4.9.6.dist-info/licenses/LICENSE", + "path_type": "hardlink", + "sha256": "29e0fd62e929850e86eb28c3fdccf0cefdf4fa94879011cffb3d0d4bed6d4db6", + "size_in_bytes": 1089 + } + ], + "paths_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/recipe/recipe-scripts-license.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/recipe/recipe-scripts-license.txt new file mode 100644 index 0000000000000000000000000000000000000000..c5aa738f1bd246658c9da9e1bbe2502df6d0e173 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/recipe/recipe-scripts-license.txt @@ -0,0 +1,26 @@ +BSD-3-Clause license +Copyright (c) 2015-2026, conda-forge contributors + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + 3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/recipe/recipe.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/recipe/recipe.yaml new file mode 100644 index 0000000000000000000000000000000000000000..4e3dc8a4244a749dc0138ee3d40c96640846289f --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/recipe/recipe.yaml @@ -0,0 +1,56 @@ +# yaml-language-server: $schema=https://raw.githubusercontent.com/prefix-dev/recipe-format/main/schema.json +schema_version: 1 + +context: + version: "4.9.6" + python_check_max: "3.14" + +package: + name: platformdirs + version: ${{ version }} + +source: + url: https://pypi.org/packages/source/p/platformdirs/platformdirs-${{ version }}.tar.gz + sha256: 3bfa75b0ad0db84096ae777218481852c0ebc6c727b3168c1b9e0118e458cf0a + +build: + number: 0 + noarch: python + script: + - ${{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation --disable-pip-version-check + +requirements: + host: + - hatch-vcs >=0.5 + - hatchling >=1.29 + - pip + - python ${{ python_min }}.* + run: + - python >=${{ python_min }} + +tests: + - python: + pip_check: true + python_version: + - ${{ python_min }}.* + - ${{ python_check_max }}.* + imports: platformdirs + - requirements: + run: + - mypy + - python ${{ python_min }}.* + script: + - mypy -p platformdirs --ignore-missing-imports --disable-error-code=safe-super ${{ "--exclude=windows" if unix }} + +about: + homepage: https://pypi.org/project/platformdirs + license_file: LICENSE + license: MIT + summary: A small Python module for determining appropriate platform-specific dirs, e.g. a "user data dir". + repository: https://github.com/tox-dev/platformdirs + +extra: + recipe-maintainers: + - adament + - gaborbernat + - bollwyvl diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/recipe/rendered_recipe.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/recipe/rendered_recipe.yaml new file mode 100644 index 0000000000000000000000000000000000000000..6d2c20b23d2cce9523135f23cbd2592081575007 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/recipe/rendered_recipe.yaml @@ -0,0 +1,925 @@ +recipe: + schema_version: 1 + context: + version: 4.9.6 + python_check_max: '3.14' + package: + name: platformdirs + version: 4.9.6 + source: + - url: https://pypi.org/packages/source/p/platformdirs/platformdirs-4.9.6.tar.gz + sha256: 3bfa75b0ad0db84096ae777218481852c0ebc6c727b3168c1b9e0118e458cf0a + build: + number: 0 + string: pyhcf101f3_0 + script: ${{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation --disable-pip-version-check + noarch: python + requirements: + host: + - hatch-vcs >=0.5 + - hatchling >=1.29 + - pip + - python 3.10.* + run: + - python >=3.10 + tests: + - python: + imports: + - platformdirs + python_version: + - 3.10.* + - 3.14.* + - script: mypy -p platformdirs --ignore-missing-imports --disable-error-code=safe-super ${{ "--exclude=windows" if unix }} + requirements: + run: + - mypy + - python 3.10.* + about: + homepage: https://pypi.org/project/platformdirs + repository: https://github.com/tox-dev/platformdirs + license: MIT + license_file: + - LICENSE + summary: A small Python module for determining appropriate platform-specific dirs, e.g. a "user data dir". + extra: + recipe-maintainers: + - adament + - gaborbernat + - bollwyvl +build_configuration: + target_platform: noarch + host_platform: + platform: linux-64 + virtual_packages: + - __unix=0=0 + - __linux=6.17.0=0 + - __glibc=2.34=0 + - __archspec=1=zen2 + build_platform: + platform: linux-64 + virtual_packages: + - __unix=0=0 + - __linux=6.17.0=0 + - __glibc=2.34=0 + - __archspec=1=zen2 + variant: + channel_sources: conda-forge + channel_targets: conda-forge main + python_min: '3.10' + target_platform: noarch + hash: + hash: cf101f3 + prefix: py + directories: + host_prefix: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_platformdirs_1775741140/host_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_p + build_prefix: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_platformdirs_1775741140/build_env + work_dir: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_platformdirs_1775741140/work + build_dir: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_platformdirs_1775741140 + channels: + - https://conda.anaconda.org/conda-forge + channel_priority: strict + solve_strategy: highest + timestamp: 2026-04-09T13:25:40.609187264Z + subpackages: + platformdirs: + name: platformdirs + version: 4.9.6 + build_string: pyhcf101f3_0 + packaging_settings: + archive_type: conda + compression_level: 15 +finalized_dependencies: + build: null + host: + specs: + - source: hatch-vcs >=0.5 + - source: hatchling >=1.29 + - source: pip + - source: python 3.10.* + resolved: + - build: pyhcf101f3_0 + build_number: 0 + depends: + - packaging >=24.2 + - pathspec >=0.10.1 + - pluggy >=1.0.0 + - python >=3.10 + - tomli >=1.2.2 + - trove-classifiers + - editables >=0.3 + - python + license: MIT + license_family: MIT + md5: 9d67ecd4cd5e6a9be36522be95951785 + name: hatchling + noarch: python + run_exports: {} + sha256: bb86ff4ca54a2a0f63714766c7653a772c13d34c9e7cfb7be653db2fb806f961 + size: 61052 + subdir: noarch + timestamp: 1773194193187 + version: 1.29.0 + fn: hatchling-1.29.0-pyhcf101f3_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/hatchling-1.29.0-pyhcf101f3_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_0 + build_number: 0 + depends: + - hatchling >=1.1.0 + - python >=3.9 + - setuptools-scm >=8.2.0 + license: MIT + license_family: MIT + md5: 065706a37a02addf0c14101e5c2b9ac5 + name: hatch-vcs + noarch: python + run_exports: {} + sha256: 6dd40a4866ef764ed2b1a801d39df2b4aada17ec43f080a957521a8f4f214702 + size: 13842 + subdir: noarch + timestamp: 1748343600326 + version: 0.5.0 + fn: hatch-vcs-0.5.0-pyhd8ed1ab_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/hatch-vcs-0.5.0-pyhd8ed1ab_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyh8b19718_0 + build_number: 0 + depends: + - python >=3.10,<3.13.0a0 + - setuptools + - wheel + license: MIT + license_family: MIT + md5: 67bdec43082fd8a9cffb9484420b39a2 + name: pip + noarch: python + run_exports: {} + sha256: 8e1497814a9997654ed7990a79c054ea5a42545679407acbc6f7e809c73c9120 + size: 1181790 + subdir: noarch + timestamp: 1770270305795 + version: 26.0.1 + fn: pip-26.0.1-pyh8b19718_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/pip-26.0.1-pyh8b19718_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h3c07f61_0_cpython + build_number: 0 + constrains: + - python_abi 3.10.* *_cp310 + depends: + - __glibc >=2.17,<3.0.a0 + - bzip2 >=1.0.8,<2.0a0 + - ld_impl_linux-64 >=2.36.1 + - libexpat >=2.7.4,<3.0a0 + - libffi >=3.4,<4.0a0 + - libgcc >=14 + - liblzma >=5.8.2,<6.0a0 + - libnsl >=2.0.1,<2.1.0a0 + - libsqlite >=3.51.2,<4.0a0 + - libuuid >=2.41.3,<3.0a0 + - libxcrypt >=4.4.36 + - libzlib >=1.3.1,<2.0a0 + - ncurses >=6.5,<7.0a0 + - openssl >=3.5.5,<4.0a0 + - readline >=8.3,<9.0a0 + - tk >=8.6.13,<8.7.0a0 + - tzdata + license: Python-2.0 + md5: 5d4e2b00d99feacd026859b7fa239dc0 + name: python + run_exports: + weak: + - python_abi 3.10.* *_cp310 + noarch: + - python + sha256: 8ff2ce308faf2588b69c65b120293f59a8f2577b772b34df4e817d220b09e081 + size: 25455342 + subdir: linux-64 + timestamp: 1772729810280 + version: 3.10.20 + fn: python-3.10.20-h3c07f61_0_cpython.conda + url: https://conda.anaconda.org/conda-forge/linux-64/python-3.10.20-h3c07f61_0_cpython.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h853b02a_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + - ncurses >=6.5,<7.0a0 + license: GPL-3.0-only + license_family: GPL + md5: d7d95fc8287ea7bf33e0e7116d2b95ec + name: readline + run_exports: + weak: + - readline >=8.3,<9.0a0 + sha256: 12ffde5a6f958e285aa22c191ca01bbd3d6e710aa852e00618fa6ddc59149002 + size: 345073 + subdir: linux-64 + timestamp: 1765813471974 + version: '8.3' + fn: readline-8.3-h853b02a_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/readline-8.3-h853b02a_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb03c661_0 + build_number: 0 + constrains: + - xz 5.8.2.* + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: 0BSD + md5: c7c83eecbb72d88b940c249af56c8b17 + name: liblzma + run_exports: + weak: + - liblzma >=5.8.2,<6.0a0 + sha256: 755c55ebab181d678c12e49cced893598f2bab22d582fbbf4d8b83c18be207eb + size: 113207 + subdir: linux-64 + timestamp: 1768752626120 + version: 5.8.2 + fn: liblzma-5.8.2-hb03c661_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/liblzma-5.8.2-hb03c661_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_0 + build_number: 0 + depends: + - importlib-metadata + - packaging >=20.0 + - python >=3.10 + - setuptools >=45 + - tomli >=1.0.0 + - typing-extensions + license: MIT + license_family: MIT + md5: e2e4d7094d0580ccd62e2a41947444f3 + name: setuptools-scm + noarch: python + run_exports: {} + sha256: 2161ac35fc22770b248bab0be2cc3b5bd765f528a9e60e7f3be784fd8d0d605a + size: 52539 + subdir: noarch + timestamp: 1760965125925 + version: 9.2.2 + fn: setuptools-scm-9.2.2-pyhd8ed1ab_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/setuptools-scm-9.2.2-pyhd8ed1ab_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhcf101f3_0 + build_number: 0 + depends: + - python >=3.8 + - python + license: Apache-2.0 + license_family: APACHE + md5: b76541e68fea4d511b1ac46a28dcd2c6 + name: packaging + noarch: python + run_exports: {} + sha256: c1fc0f953048f743385d31c468b4a678b3ad20caffdeaa94bed85ba63049fd58 + size: 72010 + subdir: noarch + timestamp: 1769093650580 + version: '26.0' + fn: packaging-26.0-pyhcf101f3_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/packaging-26.0-pyhcf101f3_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_0 + build_number: 0 + depends: + - python >=3.10 + license: MPL-2.0 + license_family: MOZILLA + md5: 2908273ac396d2cd210a8127f5f1c0d6 + name: pathspec + noarch: python + run_exports: {} + sha256: 29ea20d0faf20374fcd61c25f6d32fb8e9a2c786a7f1473a0c3ead359470fbe1 + size: 53739 + subdir: noarch + timestamp: 1769677743677 + version: 1.0.4 + fn: pathspec-1.0.4-pyhd8ed1ab_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/pathspec-1.0.4-pyhd8ed1ab_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhf9edf01_1 + build_number: 1 + depends: + - python >=3.9 + - python + license: MIT + license_family: MIT + md5: d7585b6550ad04c8c5e21097ada2888e + name: pluggy + noarch: python + run_exports: {} + sha256: e14aafa63efa0528ca99ba568eaf506eb55a0371d12e6250aaaa61718d2eb62e + size: 25877 + subdir: noarch + timestamp: 1764896838868 + version: 1.6.0 + fn: pluggy-1.6.0-pyhf9edf01_1.conda + url: https://conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhcf101f3_0 + build_number: 0 + depends: + - python >=3.10 + - python + license: MIT + license_family: MIT + md5: b5325cf06a000c5b14970462ff5e4d58 + name: tomli + noarch: python + run_exports: {} + sha256: 91cafdb64268e43e0e10d30bd1bef5af392e69f00edd34dfaf909f69ab2da6bd + size: 21561 + subdir: noarch + timestamp: 1774492402955 + version: 2.4.1 + fn: tomli-2.4.1-pyhcf101f3_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/tomli-2.4.1-pyhcf101f3_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_0 + build_number: 0 + depends: + - python >=3.10 + license: Apache-2.0 + license_family: Apache + md5: f5793a97363a42fd6a98f31f29537bbc + name: trove-classifiers + noarch: python + run_exports: {} + sha256: 302d576f7e44fa13d2849b901772a04f1c2aabc5d6b6c7dcdc5a271bcffd50fe + size: 19707 + subdir: noarch + timestamp: 1768550221435 + version: 2026.1.14.14 + fn: trove-classifiers-2026.1.14.14-pyhd8ed1ab_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/trove-classifiers-2026.1.14.14-pyhd8ed1ab_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_1 + build_number: 1 + depends: + - python >=3.9 + license: MIT + license_family: MIT + md5: 2cf824fe702d88e641eec9f9f653e170 + name: editables + noarch: python + run_exports: {} + sha256: 8d4f908e670be360617d418c328213bc46e7100154c3742db085148141712f60 + size: 10828 + subdir: noarch + timestamp: 1733208220327 + version: '0.5' + fn: editables-0.5-pyhd8ed1ab_1.conda + url: https://conda.anaconda.org/conda-forge/noarch/editables-0.5-pyhd8ed1ab_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyh332efcf_0 + build_number: 0 + depends: + - python >=3.10 + license: MIT + license_family: MIT + md5: 8e194e7b992f99a5015edbd4ebd38efd + name: setuptools + noarch: python + run_exports: {} + sha256: 82088a6e4daa33329a30bc26dc19a98c7c1d3f05c0f73ce9845d4eab4924e9e1 + size: 639697 + subdir: noarch + timestamp: 1773074868565 + version: 82.0.1 + fn: setuptools-82.0.1-pyh332efcf_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_0 + build_number: 0 + depends: + - packaging >=24.0 + - python >=3.10 + license: MIT + license_family: MIT + md5: bdbd7385b4a67025ac2dba4ef8cb6a8f + name: wheel + noarch: python + run_exports: {} + sha256: d6cf2f0ebd5e09120c28ecba450556ce553752652d91795442f0e70f837126ae + size: 31858 + subdir: noarch + timestamp: 1769139207397 + version: 0.46.3 + fn: wheel-0.46.3-pyhd8ed1ab_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/wheel-0.46.3-pyhd8ed1ab_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hda65f42_9 + build_number: 9 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: bzip2-1.0.6 + license_family: BSD + md5: d2ffd7602c02f2b316fd921d39876885 + name: bzip2 + run_exports: + weak: + - bzip2 >=1.0.8,<2.0a0 + sha256: 0b75d45f0bba3e95dc693336fa51f40ea28c980131fec438afb7ce6118ed05f6 + size: 260182 + subdir: linux-64 + timestamp: 1771350215188 + version: 1.0.8 + fn: bzip2-1.0.8-hda65f42_9.conda + url: https://conda.anaconda.org/conda-forge/linux-64/bzip2-1.0.8-hda65f42_9.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: default_hbd61a6d_102 + build_number: 102 + constrains: + - binutils_impl_linux-64 2.45.1 + depends: + - __glibc >=2.17,<3.0.a0 + - zstd >=1.5.7,<1.6.0a0 + license: GPL-3.0-only + license_family: GPL + md5: 18335a698559cdbcd86150a48bf54ba6 + name: ld_impl_linux-64 + run_exports: {} + sha256: 3d584956604909ff5df353767f3a2a2f60e07d070b328d109f30ac40cd62df6c + size: 728002 + subdir: linux-64 + timestamp: 1774197446916 + version: 2.45.1 + fn: ld_impl_linux-64-2.45.1-default_hbd61a6d_102.conda + url: https://conda.anaconda.org/conda-forge/linux-64/ld_impl_linux-64-2.45.1-default_hbd61a6d_102.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hecca717_0 + build_number: 0 + constrains: + - expat 2.7.5.* + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: MIT + license_family: MIT + md5: 49f570f3bc4c874a06ea69b7225753af + name: libexpat + run_exports: {} + sha256: e8c2b57f6aacabdf2f1b0924bd4831ce5071ba080baa4a9e8c0d720588b6794c + size: 76624 + subdir: linux-64 + timestamp: 1774719175983 + version: 2.7.5 + fn: libexpat-2.7.5-hecca717_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libexpat-2.7.5-hecca717_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h3435931_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: MIT + license_family: MIT + md5: a360c33a5abe61c07959e449fa1453eb + name: libffi + run_exports: + weak: + - libffi >=3.5.2,<3.6.0a0 + sha256: 31f19b6a88ce40ebc0d5a992c131f57d919f73c0b92cd1617a5bec83f6e961e6 + size: 58592 + subdir: linux-64 + timestamp: 1769456073053 + version: 3.5.2 + fn: libffi-3.5.2-h3435931_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libffi-3.5.2-h3435931_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: he0feb66_18 + build_number: 18 + constrains: + - libgcc-ng ==15.2.0=*_18 + - libgomp 15.2.0 he0feb66_18 + depends: + - __glibc >=2.17,<3.0.a0 + - _openmp_mutex >=4.5 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + md5: 0aa00f03f9e39fb9876085dee11a85d4 + name: libgcc + run_exports: {} + sha256: faf7d2017b4d718951e3a59d081eb09759152f93038479b768e3d612688f83f5 + size: 1041788 + subdir: linux-64 + timestamp: 1771378212382 + version: 15.2.0 + fn: libgcc-15.2.0-he0feb66_18.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgcc-15.2.0-he0feb66_18.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb9d3cd8_1 + build_number: 1 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: LGPL-2.1-only + license_family: GPL + md5: d864d34357c3b65a4b731f78c0801dc4 + name: libnsl + run_exports: + weak: + - libnsl >=2.0.1,<2.1.0a0 + sha256: 927fe72b054277cde6cb82597d0fcf6baf127dcbce2e0a9d8925a68f1265eef5 + size: 33731 + subdir: linux-64 + timestamp: 1750274110928 + version: 2.0.1 + fn: libnsl-2.0.1-hb9d3cd8_1.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libnsl-2.0.1-hb9d3cd8_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hf4e2dac_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - icu >=78.2,<79.0a0 + - libgcc >=14 + - libzlib >=1.3.1,<2.0a0 + license: blessing + md5: fd893f6a3002a635b5e50ceb9dd2c0f4 + name: libsqlite + run_exports: + weak: + - libsqlite >=3.52.0,<4.0a0 + sha256: d716847b7deca293d2e49ed1c8ab9e4b9e04b9d780aea49a97c26925b28a7993 + size: 951405 + subdir: linux-64 + timestamp: 1772818874251 + version: 3.52.0 + fn: libsqlite-3.52.0-hf4e2dac_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libsqlite-3.52.0-hf4e2dac_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h5347b49_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: BSD-3-Clause + license_family: BSD + md5: 38ffe67b78c9d4de527be8315e5ada2c + name: libuuid + run_exports: + weak: + - libuuid >=2.42,<3.0a0 + sha256: bc1b08c92626c91500fd9f26f2c797f3eb153b627d53e9c13cd167f1e12b2829 + size: 40297 + subdir: linux-64 + timestamp: 1775052476770 + version: '2.42' + fn: libuuid-2.42-h5347b49_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libuuid-2.42-h5347b49_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hd590300_1 + build_number: 1 + depends: + - libgcc-ng >=12 + license: LGPL-2.1-or-later + md5: 5aa797f8787fe7a17d1b0821485b5adc + name: libxcrypt + run_exports: + weak: + - libxcrypt >=4.4.36 + sha256: 6ae68e0b86423ef188196fff6207ed0c8195dd84273cb5623b85aa08033a410c + size: 100393 + subdir: linux-64 + timestamp: 1702724383534 + version: 4.4.36 + fn: libxcrypt-4.4.36-hd590300_1.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libxcrypt-4.4.36-hd590300_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h69a702a_18 + build_number: 18 + depends: + - libgcc 15.2.0 he0feb66_18 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + md5: d5e96b1ed75ca01906b3d2469b4ce493 + name: libgcc-ng + run_exports: + strong: + - libgcc + sha256: e318a711400f536c81123e753d4c797a821021fb38970cebfb3f454126016893 + size: 27526 + subdir: linux-64 + timestamp: 1771378224552 + version: 15.2.0 + fn: libgcc-ng-15.2.0-h69a702a_18.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgcc-ng-15.2.0-h69a702a_18.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h25fd6f3_2 + build_number: 2 + constrains: + - zlib 1.3.2 *_2 + depends: + - __glibc >=2.17,<3.0.a0 + license: Zlib + license_family: Other + md5: d87ff7921124eccd67248aa483c23fec + name: libzlib + run_exports: + weak: + - libzlib >=1.3.2,<2.0a0 + sha256: 55044c403570f0dc26e6364de4dc5368e5f3fc7ff103e867c487e2b5ab2bcda9 + size: 63629 + subdir: linux-64 + timestamp: 1774072609062 + version: 1.3.2 + fn: libzlib-1.3.2-h25fd6f3_2.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libzlib-1.3.2-h25fd6f3_2.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h2d0b736_3 + build_number: 3 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: X11 AND BSD-3-Clause + md5: 47e340acb35de30501a76c7c799c41d7 + name: ncurses + run_exports: + weak: + - ncurses >=6.5,<7.0a0 + sha256: 3fde293232fa3fca98635e1167de6b7c7fda83caf24b9d6c91ec9eefb4f4d586 + size: 891641 + subdir: linux-64 + timestamp: 1738195959188 + version: '6.5' + fn: ncurses-6.5-h2d0b736_3.conda + url: https://conda.anaconda.org/conda-forge/linux-64/ncurses-6.5-h2d0b736_3.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h35e630c_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - ca-certificates + - libgcc >=14 + license: Apache-2.0 + license_family: Apache + md5: da1b85b6a87e141f5140bb9924cecab0 + name: openssl + run_exports: + weak: + - openssl >=3.6.2,<4.0a0 + sha256: c0ef482280e38c71a08ad6d71448194b719630345b0c9c60744a2010e8a8e0cb + size: 3167099 + subdir: linux-64 + timestamp: 1775587756857 + version: 3.6.2 + fn: openssl-3.6.2-h35e630c_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/openssl-3.6.2-h35e630c_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: noxft_h366c992_103 + build_number: 103 + constrains: + - xorg-libx11 >=1.8.12,<2.0a0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + - libzlib >=1.3.1,<2.0a0 + license: TCL + license_family: BSD + md5: cffd3bdd58090148f4cfcd831f4b26ab + name: tk + run_exports: + weak: + - tk >=8.6.13,<8.7.0a0 + sha256: cafeec44494f842ffeca27e9c8b0c27ed714f93ac77ddadc6aaf726b5554ebac + size: 3301196 + subdir: linux-64 + timestamp: 1769460227866 + version: 8.6.13 + fn: tk-8.6.13-noxft_h366c992_103.conda + url: https://conda.anaconda.org/conda-forge/linux-64/tk-8.6.13-noxft_h366c992_103.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hc9c84f9_1 + build_number: 1 + depends: [] + license: LicenseRef-Public-Domain + md5: ad659d0a2b3e47e38d829aa8cad2d610 + name: tzdata + noarch: generic + run_exports: {} + sha256: 1d30098909076af33a35017eed6f2953af1c769e273a0626a04722ac4acaba3c + size: 119135 + subdir: noarch + timestamp: 1767016325805 + version: 2025c + fn: tzdata-2025c-hc9c84f9_1.conda + url: https://conda.anaconda.org/conda-forge/noarch/tzdata-2025c-hc9c84f9_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhcf101f3_0 + build_number: 0 + depends: + - python >=3.10 + - zipp >=3.20 + - python + license: Apache-2.0 + license_family: APACHE + md5: 080594bf4493e6bae2607e65390c520a + name: importlib-metadata + noarch: python + run_exports: {} + sha256: 82ab2a0d91ca1e7e63ab6a4939356667ef683905dea631bc2121aa534d347b16 + size: 34387 + subdir: noarch + timestamp: 1773931568510 + version: 8.8.0 + fn: importlib-metadata-8.8.0-pyhcf101f3_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/importlib-metadata-8.8.0-pyhcf101f3_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h396c80c_0 + build_number: 0 + depends: + - typing_extensions ==4.15.0 pyhcf101f3_0 + license: PSF-2.0 + license_family: PSF + md5: edd329d7d3a4ab45dcf905899a7a6115 + name: typing-extensions + noarch: generic + run_exports: {} + sha256: 7c2df5721c742c2a47b2c8f960e718c930031663ac1174da67c1ed5999f7938c + size: 91383 + subdir: noarch + timestamp: 1756220668932 + version: 4.15.0 + fn: typing-extensions-4.15.0-h396c80c_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/typing-extensions-4.15.0-h396c80c_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhcf101f3_0 + build_number: 0 + depends: + - python >=3.10 + - python + license: PSF-2.0 + license_family: PSF + md5: 0caa1af407ecff61170c9437a808404d + name: typing_extensions + noarch: python + run_exports: {} + sha256: 032271135bca55aeb156cee361c81350c6f3fb203f57d024d7e5a1fc9ef18731 + size: 51692 + subdir: noarch + timestamp: 1756220668932 + version: 4.15.0 + fn: typing_extensions-4.15.0-pyhcf101f3_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/typing_extensions-4.15.0-pyhcf101f3_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb78ec9c_6 + build_number: 6 + depends: + - __glibc >=2.17,<3.0.a0 + - libzlib >=1.3.1,<2.0a0 + license: BSD-3-Clause + license_family: BSD + md5: 4a13eeac0b5c8e5b8ab496e6c4ddd829 + name: zstd + run_exports: + weak: + - zstd >=1.5.7,<1.6.0a0 + sha256: 68f0206ca6e98fea941e5717cec780ed2873ffabc0e1ed34428c061e2c6268c7 + size: 601375 + subdir: linux-64 + timestamp: 1764777111296 + version: 1.5.7 + fn: zstd-1.5.7-hb78ec9c_6.conda + url: https://conda.anaconda.org/conda-forge/linux-64/zstd-1.5.7-hb78ec9c_6.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: 20_gnu + build_number: 20 + constrains: + - openmp_impl <0.0a0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgomp >=7.5.0 + license: BSD-3-Clause + license_family: BSD + md5: a9f577daf3de00bca7c3c76c0ecbd1de + name: _openmp_mutex + run_exports: + strong: + - _openmp_mutex >=4.5 + sha256: 1dd3fffd892081df9726d7eb7e0dea6198962ba775bd88842135a4ddb4deb3c9 + size: 28948 + subdir: linux-64 + timestamp: 1770939786096 + version: '4.5' + fn: _openmp_mutex-4.5-20_gnu.conda + url: https://conda.anaconda.org/conda-forge/linux-64/_openmp_mutex-4.5-20_gnu.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: he0feb66_18 + build_number: 18 + depends: + - __glibc >=2.17,<3.0.a0 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + md5: 239c5e9546c38a1e884d69effcf4c882 + name: libgomp + run_exports: + strong: + - _openmp_mutex >=4.5 + sha256: 21337ab58e5e0649d869ab168d4e609b033509de22521de1bfed0c031bfc5110 + size: 603262 + subdir: linux-64 + timestamp: 1771378117851 + version: 15.2.0 + fn: libgomp-15.2.0-he0feb66_18.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgomp-15.2.0-he0feb66_18.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h33c6efd_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + - libstdcxx >=14 + license: MIT + license_family: MIT + md5: c80d8a3b84358cb967fa81e7075fbc8a + name: icu + run_exports: + weak: + - icu >=78.3,<79.0a0 + sha256: fbf86c4a59c2ed05bbffb2ba25c7ed94f6185ec30ecb691615d42342baa1a16a + size: 12723451 + subdir: linux-64 + timestamp: 1773822285671 + version: '78.3' + fn: icu-78.3-h33c6efd_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/icu-78.3-h33c6efd_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h934c35e_18 + build_number: 18 + constrains: + - libstdcxx-ng ==15.2.0=*_18 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc 15.2.0 he0feb66_18 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + md5: 1b08cd684f34175e4514474793d44bcb + name: libstdcxx + run_exports: {} + sha256: 78668020064fdaa27e9ab65cd2997e2c837b564ab26ce3bf0e58a2ce1a525c6e + size: 5852330 + subdir: linux-64 + timestamp: 1771378262446 + version: 15.2.0 + fn: libstdcxx-15.2.0-h934c35e_18.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libstdcxx-15.2.0-h934c35e_18.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hbd8a1cb_0 + build_number: 0 + depends: + - __unix + license: ISC + md5: 4492fd26db29495f0ba23f146cd5638d + name: ca-certificates + noarch: generic + run_exports: {} + sha256: 67cc7101b36421c5913a1687ef1b99f85b5d6868da3abbf6ec1a4181e79782fc + size: 147413 + subdir: noarch + timestamp: 1772006283803 + version: 2026.2.25 + fn: ca-certificates-2026.2.25-hbd8a1cb_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/ca-certificates-2026.2.25-hbd8a1cb_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhcf101f3_1 + build_number: 1 + depends: + - python >=3.10 + - python + license: MIT + license_family: MIT + md5: 30cd29cb87d819caead4d55184c1d115 + name: zipp + noarch: python + run_exports: {} + sha256: b4533f7d9efc976511a73ef7d4a2473406d7f4c750884be8e8620b0ce70f4dae + size: 24194 + subdir: noarch + timestamp: 1764460141901 + version: 3.23.0 + fn: zipp-3.23.0-pyhcf101f3_1.conda + url: https://conda.anaconda.org/conda-forge/noarch/zipp-3.23.0-pyhcf101f3_1.conda + channel: https://conda.anaconda.org/conda-forge/ + run: + depends: + - source: python >=3.10 + - spec: python + from: host + run_export: python + constraints: [] +finalized_sources: +- url: https://pypi.org/packages/source/p/platformdirs/platformdirs-4.9.6.tar.gz + sha256: 3bfa75b0ad0db84096ae777218481852c0ebc6c727b3168c1b9e0118e458cf0a +system_tools: + rattler-build: 0.61.4 +extra_meta: + flow_run_id: github_24192627818 + remote_url: https://github.com/conda-forge/platformdirs-feedstock + sha: 9b615fad9b0c0b266170328bbf374a0600845ddd diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/recipe/variant_config.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/recipe/variant_config.yaml new file mode 100644 index 0000000000000000000000000000000000000000..9c9555bc0715cf4927cf43dc30e6dd1e88c57b9a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/recipe/variant_config.yaml @@ -0,0 +1,4 @@ +channel_sources: conda-forge +channel_targets: conda-forge main +python_min: '3.10' +target_platform: noarch diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/repodata_record.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/repodata_record.json new file mode 100644 index 0000000000000000000000000000000000000000..6e77f22e46761caf9f86338a1c6b2bf32c0095db --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/repodata_record.json @@ -0,0 +1,22 @@ +{ + "build": "pyhcf101f3_0", + "build_number": 0, + "build_string": "pyhcf101f3_0", + "channel": "conda-forge", + "constrains": [], + "depends": [ + "python >=3.10", + "python" + ], + "fn": "platformdirs-4.9.6-pyhcf101f3_0.conda", + "license": "MIT", + "md5": "89c0b6d1793601a2a3a3f7d2d3d8b937", + "name": "platformdirs", + "noarch": "python", + "sha256": "8f29915c172f1f7f4f7c9391cd5dac3ebf5d13745c8b7c8006032615246345a5", + "size": 25862, + "subdir": "noarch", + "timestamp": 1775741140, + "url": "https://conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0.conda", + "version": "4.9.6" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/tests/tests.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/tests/tests.yaml new file mode 100644 index 0000000000000000000000000000000000000000..c0e419f269b2669da5022c8a2d428297b8cb7f47 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/info/tests/tests.yaml @@ -0,0 +1,12 @@ +- python: + imports: + - platformdirs + python_version: + - 3.10.* + - 3.14.* +- script: + content: mypy -p platformdirs --ignore-missing-imports --disable-error-code=safe-super --exclude=windows + requirements: + run: + - mypy + - python 3.10.* diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/INSTALLER b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/INSTALLER new file mode 100644 index 0000000000000000000000000000000000000000..a34a7e56db35cc4c85bfa166244b3d63a6a240d4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/INSTALLER @@ -0,0 +1 @@ +conda diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/METADATA b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/METADATA new file mode 100644 index 0000000000000000000000000000000000000000..f9ac753abd2e2389768e6e5a530a20d4fc92925a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/METADATA @@ -0,0 +1,100 @@ +Metadata-Version: 2.4 +Name: platformdirs +Version: 4.9.6 +Summary: A small Python package for determining appropriate platform-specific dirs, e.g. a `user data dir`. +Project-URL: Changelog, https://platformdirs.readthedocs.io/en/latest/changelog.html +Project-URL: Documentation, https://platformdirs.readthedocs.io +Project-URL: Homepage, https://github.com/tox-dev/platformdirs +Project-URL: Source, https://github.com/tox-dev/platformdirs +Project-URL: Tracker, https://github.com/tox-dev/platformdirs/issues +Maintainer-email: Bernát Gábor , Julian Berman , Ofek Lev , Ronny Pfannschmidt +License-Expression: MIT +License-File: LICENSE +Keywords: appdirs,application,cache,directory,log,user +Classifier: Development Status :: 5 - Production/Stable +Classifier: Intended Audience :: Developers +Classifier: License :: OSI Approved :: MIT License +Classifier: Operating System :: OS Independent +Classifier: Programming Language :: Python +Classifier: Programming Language :: Python :: 3 :: Only +Classifier: Programming Language :: Python :: 3.10 +Classifier: Programming Language :: Python :: 3.11 +Classifier: Programming Language :: Python :: 3.12 +Classifier: Programming Language :: Python :: 3.13 +Classifier: Programming Language :: Python :: 3.14 +Classifier: Programming Language :: Python :: Implementation :: CPython +Classifier: Programming Language :: Python :: Implementation :: PyPy +Classifier: Topic :: Software Development :: Libraries :: Python Modules +Requires-Python: >=3.10 +Description-Content-Type: text/markdown + +# platformdirs + +[![PyPI version](https://badge.fury.io/py/platformdirs.svg)](https://badge.fury.io/py/platformdirs) +[![Python versions](https://img.shields.io/pypi/pyversions/platformdirs.svg)](https://pypi.python.org/pypi/platformdirs/) +[![CI](https://github.com/tox-dev/platformdirs/actions/workflows/check.yaml/badge.svg)](https://github.com/platformdirs/platformdirs/actions) +[![Downloads](https://static.pepy.tech/badge/platformdirs/month)](https://pepy.tech/project/platformdirs) + +A Python package for determining platform-specific directories (e.g. user data, config, cache, logs). Handles the +differences between macOS, Windows, Linux/Unix, and Android so you don't have to. + +## Quick start + +```python +from platformdirs import PlatformDirs + +dirs = PlatformDirs("MyApp", "MyCompany") +dirs.user_data_dir # ~/.local/share/MyApp (Linux) +dirs.user_config_dir # ~/.config/MyApp (Linux) +dirs.user_cache_dir # ~/.cache/MyApp (Linux) +dirs.user_state_dir # ~/.local/state/MyApp (Linux) +dirs.user_log_dir # ~/.local/state/MyApp/log (Linux) +dirs.user_documents_dir # ~/Documents +dirs.user_downloads_dir # ~/Downloads +dirs.user_runtime_dir # /run/user//MyApp (Linux) +``` + +For Path objects instead of strings: + +```python +from platformdirs import PlatformDirs + +dirs = PlatformDirs("MyApp", "MyCompany") +dirs.user_data_path # pathlib.Path('~/.local/share/MyApp') +dirs.user_config_path # pathlib.Path('~/.config/MyApp') +``` + +Convenience functions for quick access: + +```python +from platformdirs import user_data_dir, user_config_path + +user_data_dir("MyApp", "MyCompany") # returns str +user_config_path("MyApp", "MyCompany") # returns pathlib.Path +``` + +## Directory types + +- **Data**: Persistent application data (`user_data_dir`, `site_data_dir`) +- **Config**: Configuration files and settings (`user_config_dir`, `site_config_dir`) +- **Cache**: Cached data that can be regenerated (`user_cache_dir`, `site_cache_dir`) +- **State**: Non-essential runtime state like window positions (`user_state_dir`, `site_state_dir`) +- **Logs**: Log files (`user_log_dir`, `site_log_dir`) +- **Runtime**: Runtime files like sockets and PIDs (`user_runtime_dir`, `site_runtime_dir`) + +Each type has both `user_*` (per-user, writable) and `site_*` (system-wide, read-only for users) variants. + +## Documentation + +Full documentation is available at [platformdirs.readthedocs.io](https://platformdirs.readthedocs.io): + +- **[Getting started tutorial](https://platformdirs.readthedocs.io/en/latest/tutorial.html)** -- learn core concepts + through real-world examples +- **[How-to guides](https://platformdirs.readthedocs.io/en/latest/howto.html)** -- recipes for common tasks and + platform-specific tips +- **[API reference](https://platformdirs.readthedocs.io/en/latest/api.html)** -- complete list of functions and classes +- **[Platform details](https://platformdirs.readthedocs.io/en/latest/platforms.html)** -- default paths for each + operating system + +Contributions are welcome! See [CONTRIBUTING.md](https://github.com/tox-dev/platformdirs/blob/main/CONTRIBUTING.md) for +details. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/RECORD b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/RECORD new file mode 100644 index 0000000000000000000000000000000000000000..121da99a2ee4e2e87cfdf2485e0bea2556ef3ef9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/RECORD @@ -0,0 +1,26 @@ +platformdirs-4.9.6.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +platformdirs-4.9.6.dist-info/METADATA,sha256=fcQ31pBPq10bZSesG9_gMETprVNkna3BQ0cabyRyknw,4683 +platformdirs-4.9.6.dist-info/RECORD,, +platformdirs-4.9.6.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +platformdirs-4.9.6.dist-info/WHEEL,sha256=QccIxa26bgl1E6uMy58deGWi-0aeIkkangHcxk2kWfw,87 +platformdirs-4.9.6.dist-info/direct_url.json,sha256=7ALWV2hpXSYTI-4SJMeFtlIyCBn5qd81pvnFw8yuamA,123 +platformdirs-4.9.6.dist-info/licenses/LICENSE,sha256=KeD9YukphQ6G6yjD_czwzv30-pSHkBHP-z0NS-1tTbY,1089 +platformdirs/__init__.py,sha256=hL_ZyhsQ5EfYf4W_Tr4O6F0lAOKLvQi0TZ4e_WGCIc4,30718 +platformdirs/__main__.py,sha256=MvM6fKJpBAeiTZckNJGSihXFKkS46tS9_P5gySZg3RI,1633 +platformdirs/__pycache__/__init__.cpython-310.pyc,, +platformdirs/__pycache__/__main__.cpython-310.pyc,, +platformdirs/__pycache__/_xdg.cpython-310.pyc,, +platformdirs/__pycache__/android.cpython-310.pyc,, +platformdirs/__pycache__/api.cpython-310.pyc,, +platformdirs/__pycache__/macos.cpython-310.pyc,, +platformdirs/__pycache__/unix.cpython-310.pyc,, +platformdirs/__pycache__/version.cpython-310.pyc,, +platformdirs/__pycache__/windows.cpython-310.pyc,, +platformdirs/_xdg.py,sha256=vNBb4Vsp3vx5HoecsYGUwVsB1bfYthZcjRk51FLYUeo,6391 +platformdirs/android.py,sha256=nbEJY4dyNjF-OM5RalA0WJIQHCUy8OKioGDS9G_-ZGg,10591 +platformdirs/api.py,sha256=0LkLOlJtbqEglJFpyynWP6zSMDEX23akdJERcTDxWWc,13415 +platformdirs/macos.py,sha256=I36WswNPKMAAFvG57sRTur0NbnXpV_hhhupSx9P4gOw,8090 +platformdirs/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +platformdirs/unix.py,sha256=QgTxP8EwOAeaKpnCgXdNZ9fnmnKpeoe1ICv_e1fFov4,12259 +platformdirs/version.py,sha256=XATFcF2M-IkX5aM0WcHYRA1fkcF1XWXoNC1YG1bPbk0,704 +platformdirs/windows.py,sha256=eQFkbOcRcI5YplmPx59FOd7yXJlhq27PpL7HVaC7se4,14564 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/REQUESTED b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/REQUESTED new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/WHEEL b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/WHEEL new file mode 100644 index 0000000000000000000000000000000000000000..b1b94fd58e7e9ed0ef3449473bc48de68afcc3fe --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/WHEEL @@ -0,0 +1,4 @@ +Wheel-Version: 1.0 +Generator: hatchling 1.29.0 +Root-Is-Purelib: true +Tag: py3-none-any diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/direct_url.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/direct_url.json new file mode 100644 index 0000000000000000000000000000000000000000..46979cc362341edbda83998058e8e6d452bac76a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/direct_url.json @@ -0,0 +1 @@ +{"dir_info": {}, "url": "file:///home/conda/feedstock_root/build_artifacts/bld/rattler-build_platformdirs_1775741140/work"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..f35fed9191b1142ddaada8a96de4a9461c5d796c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs-4.9.6.dist-info/licenses/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2010-202x The platformdirs developers + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..4ab450ea953e237bb7ffcdf83f0c76200507cdc1 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/__init__.py @@ -0,0 +1,857 @@ +"""Utilities for determining application-specific dirs. + +Provides convenience functions (e.g. :func:`user_data_dir`, :func:`user_config_path`), a :data:`PlatformDirs` class that +auto-detects the current platform, and the :class:`~platformdirs.api.PlatformDirsABC` base class. + +See for details and usage. + +""" + +from __future__ import annotations + +import os +import sys +from typing import TYPE_CHECKING + +from .api import PlatformDirsABC +from .version import __version__ +from .version import __version_tuple__ as __version_info__ + +if TYPE_CHECKING: + from pathlib import Path + from typing import Literal + +if sys.platform == "win32": + from platformdirs.windows import Windows as _Result +elif sys.platform == "darwin": + from platformdirs.macos import MacOS as _Result +else: + from platformdirs.unix import Unix as _Result + + +def _set_platform_dir_class() -> type[PlatformDirsABC]: + if os.getenv("ANDROID_DATA") == "/data" and os.getenv("ANDROID_ROOT") == "/system": + if os.getenv("SHELL") or os.getenv("PREFIX"): + return _Result + + from platformdirs.android import _android_folder # noqa: PLC0415 + + if _android_folder() is not None: + from platformdirs.android import Android # noqa: PLC0415 + + return Android # return to avoid redefinition of a result + + return _Result + + +if TYPE_CHECKING: + # Work around mypy issue: https://github.com/python/mypy/issues/10962 + PlatformDirs = _Result +else: + PlatformDirs = _set_platform_dir_class() #: Currently active platform +AppDirs = PlatformDirs #: Backwards compatibility with appdirs + + +def user_data_dir( # noqa: PLR0913, PLR0917 + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + roaming: bool = False, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 + use_site_for_root: bool = False, # noqa: FBT001, FBT002 +) -> str: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param roaming: See `roaming `. + :param ensure_exists: See `ensure_exists `. + :param use_site_for_root: See `use_site_for_root `. + + :returns: data directory tied to the user + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + roaming=roaming, + ensure_exists=ensure_exists, + use_site_for_root=use_site_for_root, + ).user_data_dir + + +def site_data_dir( + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + multipath: bool = False, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 +) -> str: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param multipath: See `multipath `. + :param ensure_exists: See `ensure_exists `. + + :returns: data directory shared by users + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + multipath=multipath, + ensure_exists=ensure_exists, + ).site_data_dir + + +def user_config_dir( # noqa: PLR0913, PLR0917 + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + roaming: bool = False, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 + use_site_for_root: bool = False, # noqa: FBT001, FBT002 +) -> str: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param roaming: See `roaming `. + :param ensure_exists: See `ensure_exists `. + :param use_site_for_root: See `use_site_for_root `. + + :returns: config directory tied to the user + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + roaming=roaming, + ensure_exists=ensure_exists, + use_site_for_root=use_site_for_root, + ).user_config_dir + + +def site_config_dir( + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + multipath: bool = False, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 +) -> str: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param multipath: See `multipath `. + :param ensure_exists: See `ensure_exists `. + + :returns: config directory shared by users + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + multipath=multipath, + ensure_exists=ensure_exists, + ).site_config_dir + + +def user_cache_dir( # noqa: PLR0913, PLR0917 + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + opinion: bool = True, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 + use_site_for_root: bool = False, # noqa: FBT001, FBT002 +) -> str: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param opinion: See `opinion `. + :param ensure_exists: See `ensure_exists `. + :param use_site_for_root: See `use_site_for_root `. + + :returns: cache directory tied to the user + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + opinion=opinion, + ensure_exists=ensure_exists, + use_site_for_root=use_site_for_root, + ).user_cache_dir + + +def site_cache_dir( + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + opinion: bool = True, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 +) -> str: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param opinion: See `opinion `. + :param ensure_exists: See `ensure_exists `. + + :returns: cache directory shared by users + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + opinion=opinion, + ensure_exists=ensure_exists, + ).site_cache_dir + + +def user_state_dir( # noqa: PLR0913, PLR0917 + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + roaming: bool = False, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 + use_site_for_root: bool = False, # noqa: FBT001, FBT002 +) -> str: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param roaming: See `roaming `. + :param ensure_exists: See `ensure_exists `. + :param use_site_for_root: See `use_site_for_root `. + + :returns: state directory tied to the user + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + roaming=roaming, + ensure_exists=ensure_exists, + use_site_for_root=use_site_for_root, + ).user_state_dir + + +def site_state_dir( + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + ensure_exists: bool = False, # noqa: FBT001, FBT002 +) -> str: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param ensure_exists: See `ensure_exists `. + + :returns: state directory shared by users + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + ensure_exists=ensure_exists, + ).site_state_dir + + +def user_log_dir( # noqa: PLR0913, PLR0917 + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + opinion: bool = True, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 + use_site_for_root: bool = False, # noqa: FBT001, FBT002 +) -> str: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param opinion: See `opinion `. + :param ensure_exists: See `ensure_exists `. + :param use_site_for_root: See `use_site_for_root `. + + :returns: log directory tied to the user + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + opinion=opinion, + ensure_exists=ensure_exists, + use_site_for_root=use_site_for_root, + ).user_log_dir + + +def site_log_dir( + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + opinion: bool = True, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 +) -> str: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param opinion: See `opinion `. + :param ensure_exists: See `ensure_exists `. + + :returns: log directory shared by users + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + opinion=opinion, + ensure_exists=ensure_exists, + ).site_log_dir + + +def user_documents_dir() -> str: + """:returns: documents directory tied to the user""" + return PlatformDirs().user_documents_dir + + +def user_downloads_dir() -> str: + """:returns: downloads directory tied to the user""" + return PlatformDirs().user_downloads_dir + + +def user_pictures_dir() -> str: + """:returns: pictures directory tied to the user""" + return PlatformDirs().user_pictures_dir + + +def user_videos_dir() -> str: + """:returns: videos directory tied to the user""" + return PlatformDirs().user_videos_dir + + +def user_music_dir() -> str: + """:returns: music directory tied to the user""" + return PlatformDirs().user_music_dir + + +def user_desktop_dir() -> str: + """:returns: desktop directory tied to the user""" + return PlatformDirs().user_desktop_dir + + +def user_bin_dir() -> str: + """:returns: bin directory tied to the user""" + return PlatformDirs().user_bin_dir + + +def site_bin_dir() -> str: + """:returns: bin directory shared by users""" + return PlatformDirs().site_bin_dir + + +def user_applications_dir() -> str: + """:returns: applications directory tied to the user""" + return PlatformDirs().user_applications_dir + + +def site_applications_dir( + multipath: bool = False, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 +) -> str: + """:param multipath: See `multipath `. + :param ensure_exists: See `ensure_exists `. + + :returns: applications directory shared by users + + """ + return PlatformDirs( + multipath=multipath, + ensure_exists=ensure_exists, + ).site_applications_dir + + +def user_runtime_dir( # noqa: PLR0913, PLR0917 + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + opinion: bool = True, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 + use_site_for_root: bool = False, # noqa: FBT001, FBT002 +) -> str: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param opinion: See `opinion `. + :param ensure_exists: See `ensure_exists `. + :param use_site_for_root: See `use_site_for_root `. + + :returns: runtime directory tied to the user + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + opinion=opinion, + ensure_exists=ensure_exists, + use_site_for_root=use_site_for_root, + ).user_runtime_dir + + +def site_runtime_dir( + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + opinion: bool = True, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 +) -> str: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param opinion: See `opinion `. + :param ensure_exists: See `ensure_exists `. + + :returns: runtime directory shared by users + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + opinion=opinion, + ensure_exists=ensure_exists, + ).site_runtime_dir + + +def user_data_path( # noqa: PLR0913, PLR0917 + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + roaming: bool = False, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 + use_site_for_root: bool = False, # noqa: FBT001, FBT002 +) -> Path: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param roaming: See `roaming `. + :param ensure_exists: See `ensure_exists `. + :param use_site_for_root: See `use_site_for_root `. + + :returns: data path tied to the user + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + roaming=roaming, + ensure_exists=ensure_exists, + use_site_for_root=use_site_for_root, + ).user_data_path + + +def site_data_path( + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + multipath: bool = False, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 +) -> Path: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param multipath: See `multipath `. + :param ensure_exists: See `ensure_exists `. + + :returns: data path shared by users + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + multipath=multipath, + ensure_exists=ensure_exists, + ).site_data_path + + +def user_config_path( # noqa: PLR0913, PLR0917 + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + roaming: bool = False, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 + use_site_for_root: bool = False, # noqa: FBT001, FBT002 +) -> Path: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param roaming: See `roaming `. + :param ensure_exists: See `ensure_exists `. + :param use_site_for_root: See `use_site_for_root `. + + :returns: config path tied to the user + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + roaming=roaming, + ensure_exists=ensure_exists, + use_site_for_root=use_site_for_root, + ).user_config_path + + +def site_config_path( + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + multipath: bool = False, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 +) -> Path: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param multipath: See `multipath `. + :param ensure_exists: See `ensure_exists `. + + :returns: config path shared by users + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + multipath=multipath, + ensure_exists=ensure_exists, + ).site_config_path + + +def site_cache_path( + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + opinion: bool = True, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 +) -> Path: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param opinion: See `opinion `. + :param ensure_exists: See `ensure_exists `. + + :returns: cache path shared by users + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + opinion=opinion, + ensure_exists=ensure_exists, + ).site_cache_path + + +def user_cache_path( # noqa: PLR0913, PLR0917 + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + opinion: bool = True, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 + use_site_for_root: bool = False, # noqa: FBT001, FBT002 +) -> Path: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param opinion: See `opinion `. + :param ensure_exists: See `ensure_exists `. + :param use_site_for_root: See `use_site_for_root `. + + :returns: cache path tied to the user + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + opinion=opinion, + ensure_exists=ensure_exists, + use_site_for_root=use_site_for_root, + ).user_cache_path + + +def user_state_path( # noqa: PLR0913, PLR0917 + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + roaming: bool = False, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 + use_site_for_root: bool = False, # noqa: FBT001, FBT002 +) -> Path: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param roaming: See `roaming `. + :param ensure_exists: See `ensure_exists `. + :param use_site_for_root: See `use_site_for_root `. + + :returns: state path tied to the user + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + roaming=roaming, + ensure_exists=ensure_exists, + use_site_for_root=use_site_for_root, + ).user_state_path + + +def site_state_path( + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + ensure_exists: bool = False, # noqa: FBT001, FBT002 +) -> Path: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param ensure_exists: See `ensure_exists `. + + :returns: state path shared by users + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + ensure_exists=ensure_exists, + ).site_state_path + + +def user_log_path( # noqa: PLR0913, PLR0917 + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + opinion: bool = True, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 + use_site_for_root: bool = False, # noqa: FBT001, FBT002 +) -> Path: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param opinion: See `opinion `. + :param ensure_exists: See `ensure_exists `. + :param use_site_for_root: See `use_site_for_root `. + + :returns: log path tied to the user + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + opinion=opinion, + ensure_exists=ensure_exists, + use_site_for_root=use_site_for_root, + ).user_log_path + + +def site_log_path( + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + opinion: bool = True, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 +) -> Path: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param opinion: See `opinion `. + :param ensure_exists: See `ensure_exists `. + + :returns: log path shared by users + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + opinion=opinion, + ensure_exists=ensure_exists, + ).site_log_path + + +def user_documents_path() -> Path: + """:returns: documents path tied to the user""" + return PlatformDirs().user_documents_path + + +def user_downloads_path() -> Path: + """:returns: downloads path tied to the user""" + return PlatformDirs().user_downloads_path + + +def user_pictures_path() -> Path: + """:returns: pictures path tied to the user""" + return PlatformDirs().user_pictures_path + + +def user_videos_path() -> Path: + """:returns: videos path tied to the user""" + return PlatformDirs().user_videos_path + + +def user_music_path() -> Path: + """:returns: music path tied to the user""" + return PlatformDirs().user_music_path + + +def user_desktop_path() -> Path: + """:returns: desktop path tied to the user""" + return PlatformDirs().user_desktop_path + + +def user_bin_path() -> Path: + """:returns: bin path tied to the user""" + return PlatformDirs().user_bin_path + + +def site_bin_path() -> Path: + """:returns: bin path shared by users""" + return PlatformDirs().site_bin_path + + +def user_applications_path() -> Path: + """:returns: applications path tied to the user""" + return PlatformDirs().user_applications_path + + +def site_applications_path( + multipath: bool = False, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 +) -> Path: + """:param multipath: See `multipath `. + :param ensure_exists: See `ensure_exists `. + + :returns: applications path shared by users + + """ + return PlatformDirs( + multipath=multipath, + ensure_exists=ensure_exists, + ).site_applications_path + + +def user_runtime_path( # noqa: PLR0913, PLR0917 + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + opinion: bool = True, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 + use_site_for_root: bool = False, # noqa: FBT001, FBT002 +) -> Path: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param opinion: See `opinion `. + :param ensure_exists: See `ensure_exists `. + :param use_site_for_root: See `use_site_for_root `. + + :returns: runtime path tied to the user + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + opinion=opinion, + ensure_exists=ensure_exists, + use_site_for_root=use_site_for_root, + ).user_runtime_path + + +def site_runtime_path( + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + opinion: bool = True, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 +) -> Path: + """:param appname: See `appname `. + :param appauthor: See `appauthor `. + :param version: See `version `. + :param opinion: See `opinion `. + :param ensure_exists: See `ensure_exists `. + + :returns: runtime path shared by users + + """ + return PlatformDirs( + appname=appname, + appauthor=appauthor, + version=version, + opinion=opinion, + ensure_exists=ensure_exists, + ).site_runtime_path + + +__all__ = [ + "AppDirs", + "PlatformDirs", + "PlatformDirsABC", + "__version__", + "__version_info__", + "site_applications_dir", + "site_applications_path", + "site_bin_dir", + "site_bin_path", + "site_cache_dir", + "site_cache_path", + "site_config_dir", + "site_config_path", + "site_data_dir", + "site_data_path", + "site_log_dir", + "site_log_path", + "site_runtime_dir", + "site_runtime_path", + "site_state_dir", + "site_state_path", + "user_applications_dir", + "user_applications_path", + "user_bin_dir", + "user_bin_path", + "user_cache_dir", + "user_cache_path", + "user_config_dir", + "user_config_path", + "user_data_dir", + "user_data_path", + "user_desktop_dir", + "user_desktop_path", + "user_documents_dir", + "user_documents_path", + "user_downloads_dir", + "user_downloads_path", + "user_log_dir", + "user_log_path", + "user_music_dir", + "user_music_path", + "user_pictures_dir", + "user_pictures_path", + "user_runtime_dir", + "user_runtime_path", + "user_state_dir", + "user_state_path", + "user_videos_dir", + "user_videos_path", +] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/__main__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/__main__.py new file mode 100644 index 0000000000000000000000000000000000000000..2490ffbbe1bbc1626bc961ca3e1e6a8a1effc083 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/__main__.py @@ -0,0 +1,61 @@ +"""Main entry point.""" + +from __future__ import annotations + +from platformdirs import PlatformDirs, __version__ + +PROPS = ( + "user_data_dir", + "user_config_dir", + "user_cache_dir", + "user_state_dir", + "user_log_dir", + "user_documents_dir", + "user_downloads_dir", + "user_pictures_dir", + "user_videos_dir", + "user_music_dir", + "user_bin_dir", + "site_bin_dir", + "user_applications_dir", + "user_runtime_dir", + "site_data_dir", + "site_config_dir", + "site_cache_dir", + "site_state_dir", + "site_log_dir", + "site_applications_dir", + "site_runtime_dir", +) + + +def main() -> None: + """Run the main entry point.""" + app_name = "MyApp" + app_author = "MyCompany" + + print(f"-- platformdirs {__version__} --") # noqa: T201 + + print("-- app dirs (with optional 'version')") # noqa: T201 + dirs = PlatformDirs(app_name, app_author, version="1.0") + for prop in PROPS: + print(f"{prop}: {getattr(dirs, prop)}") # noqa: T201 + + print("\n-- app dirs (without optional 'version')") # noqa: T201 + dirs = PlatformDirs(app_name, app_author) + for prop in PROPS: + print(f"{prop}: {getattr(dirs, prop)}") # noqa: T201 + + print("\n-- app dirs (without optional 'appauthor')") # noqa: T201 + dirs = PlatformDirs(app_name) + for prop in PROPS: + print(f"{prop}: {getattr(dirs, prop)}") # noqa: T201 + + print("\n-- app dirs (with disabled 'appauthor')") # noqa: T201 + dirs = PlatformDirs(app_name, appauthor=False) + for prop in PROPS: + print(f"{prop}: {getattr(dirs, prop)}") # noqa: T201 + + +if __name__ == "__main__": + main() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/_xdg.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/_xdg.py new file mode 100644 index 0000000000000000000000000000000000000000..5ffbf93eb57c0a82184e8c069810f9ecc638927f --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/_xdg.py @@ -0,0 +1,143 @@ +"""XDG environment variable mixin for Unix and macOS.""" + +from __future__ import annotations + +import os + +from .api import PlatformDirsABC + + +class XDGMixin(PlatformDirsABC): + """Mixin that checks XDG environment variables, falling back to platform-specific defaults via ``super()``.""" + + @property + def user_data_dir(self) -> str: + """:returns: data directory tied to the user, from ``$XDG_DATA_HOME`` if set, else platform default""" + if path := os.environ.get("XDG_DATA_HOME", "").strip(): + return self._append_app_name_and_version(path) + return super().user_data_dir + + @property + def _site_data_dirs(self) -> list[str]: + if xdg_dirs := os.environ.get("XDG_DATA_DIRS", "").strip(): + return [self._append_app_name_and_version(p) for p in xdg_dirs.split(os.pathsep) if p.strip()] + return super()._site_data_dirs + + @property + def site_data_dir(self) -> str: + """:returns: data directories shared by users, from ``$XDG_DATA_DIRS`` if set, else platform default""" + dirs = self._site_data_dirs + return os.pathsep.join(dirs) if self.multipath else dirs[0] + + @property + def user_config_dir(self) -> str: + """:returns: config directory tied to the user, from ``$XDG_CONFIG_HOME`` if set, else platform default""" + if path := os.environ.get("XDG_CONFIG_HOME", "").strip(): + return self._append_app_name_and_version(path) + return super().user_config_dir + + @property + def _site_config_dirs(self) -> list[str]: + if xdg_dirs := os.environ.get("XDG_CONFIG_DIRS", "").strip(): + return [self._append_app_name_and_version(p) for p in xdg_dirs.split(os.pathsep) if p.strip()] + return super()._site_config_dirs + + @property + def site_config_dir(self) -> str: + """:returns: config directories shared by users, from ``$XDG_CONFIG_DIRS`` if set, else platform default""" + dirs = self._site_config_dirs + return os.pathsep.join(dirs) if self.multipath else dirs[0] + + @property + def user_cache_dir(self) -> str: + """:returns: cache directory tied to the user, from ``$XDG_CACHE_HOME`` if set, else platform default""" + if path := os.environ.get("XDG_CACHE_HOME", "").strip(): + return self._append_app_name_and_version(path) + return super().user_cache_dir + + @property + def user_state_dir(self) -> str: + """:returns: state directory tied to the user, from ``$XDG_STATE_HOME`` if set, else platform default""" + if path := os.environ.get("XDG_STATE_HOME", "").strip(): + return self._append_app_name_and_version(path) + return super().user_state_dir + + @property + def user_runtime_dir(self) -> str: + """:returns: runtime directory tied to the user, from ``$XDG_RUNTIME_DIR`` if set, else platform default""" + if path := os.environ.get("XDG_RUNTIME_DIR", "").strip(): + return self._append_app_name_and_version(path) + return super().user_runtime_dir + + @property + def site_runtime_dir(self) -> str: + """:returns: runtime directory shared by users, from ``$XDG_RUNTIME_DIR`` if set, else platform default""" + if path := os.environ.get("XDG_RUNTIME_DIR", "").strip(): + return self._append_app_name_and_version(path) + return super().site_runtime_dir + + @property + def user_documents_dir(self) -> str: + """:returns: documents directory tied to the user, from ``$XDG_DOCUMENTS_DIR`` if set, else platform default""" + if path := os.environ.get("XDG_DOCUMENTS_DIR", "").strip(): + return os.path.expanduser(path) # noqa: PTH111 + return super().user_documents_dir + + @property + def user_downloads_dir(self) -> str: + """:returns: downloads directory tied to the user, from ``$XDG_DOWNLOAD_DIR`` if set, else platform default""" + if path := os.environ.get("XDG_DOWNLOAD_DIR", "").strip(): + return os.path.expanduser(path) # noqa: PTH111 + return super().user_downloads_dir + + @property + def user_pictures_dir(self) -> str: + """:returns: pictures directory tied to the user, from ``$XDG_PICTURES_DIR`` if set, else platform default""" + if path := os.environ.get("XDG_PICTURES_DIR", "").strip(): + return os.path.expanduser(path) # noqa: PTH111 + return super().user_pictures_dir + + @property + def user_videos_dir(self) -> str: + """:returns: videos directory tied to the user, from ``$XDG_VIDEOS_DIR`` if set, else platform default""" + if path := os.environ.get("XDG_VIDEOS_DIR", "").strip(): + return os.path.expanduser(path) # noqa: PTH111 + return super().user_videos_dir + + @property + def user_music_dir(self) -> str: + """:returns: music directory tied to the user, from ``$XDG_MUSIC_DIR`` if set, else platform default""" + if path := os.environ.get("XDG_MUSIC_DIR", "").strip(): + return os.path.expanduser(path) # noqa: PTH111 + return super().user_music_dir + + @property + def user_desktop_dir(self) -> str: + """:returns: desktop directory tied to the user, from ``$XDG_DESKTOP_DIR`` if set, else platform default""" + if path := os.environ.get("XDG_DESKTOP_DIR", "").strip(): + return os.path.expanduser(path) # noqa: PTH111 + return super().user_desktop_dir + + @property + def user_applications_dir(self) -> str: + """:returns: applications directory tied to the user, from ``$XDG_DATA_HOME`` if set, else platform default""" + if path := os.environ.get("XDG_DATA_HOME", "").strip(): + return os.path.join(os.path.expanduser(path), "applications") # noqa: PTH111, PTH118 + return super().user_applications_dir + + @property + def _site_applications_dirs(self) -> list[str]: + if xdg_dirs := os.environ.get("XDG_DATA_DIRS", "").strip(): + return [os.path.join(p, "applications") for p in xdg_dirs.split(os.pathsep) if p.strip()] # noqa: PTH118 + return super()._site_applications_dirs + + @property + def site_applications_dir(self) -> str: + """:returns: applications directories shared by users, from ``$XDG_DATA_DIRS`` if set, else platform default""" + dirs = self._site_applications_dirs + return os.pathsep.join(dirs) if self.multipath else dirs[0] + + +__all__ = [ + "XDGMixin", +] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/android.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/android.py new file mode 100644 index 0000000000000000000000000000000000000000..8c798b95e3136dc1a750fd5fd6f7c37799caa46c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/android.py @@ -0,0 +1,275 @@ +"""Android.""" + +from __future__ import annotations + +import os +import re +import sys +from functools import lru_cache +from typing import TYPE_CHECKING, cast + +from .api import PlatformDirsABC + + +class Android(PlatformDirsABC): # noqa: PLR0904 + """Platform directories for Android. + + Follows the guidance `from here `_. Directories are typically located + under the app's private storage (``/data/user///``). + + Makes use of the `appname `, `version + `, `opinion `, `ensure_exists + `. + + """ + + @property + def user_data_dir(self) -> str: + """:returns: data directory tied to the user, e.g. ``/data/user///files/``""" + return self._append_app_name_and_version(cast("str", _android_folder()), "files") + + @property + def site_data_dir(self) -> str: + """:returns: data directory shared by users, same as `user_data_dir`""" + return self.user_data_dir + + @property + def user_config_dir(self) -> str: + """:returns: config directory tied to the user, e.g. ``/data/user///shared_prefs/``""" + return self._append_app_name_and_version(cast("str", _android_folder()), "shared_prefs") + + @property + def site_config_dir(self) -> str: + """:returns: config directory shared by users, same as `user_config_dir`""" + return self.user_config_dir + + @property + def user_cache_dir(self) -> str: + """:returns: cache directory tied to the user, e.g.,``/data/user///cache/``""" + return self._append_app_name_and_version(cast("str", _android_folder()), "cache") + + @property + def site_cache_dir(self) -> str: + """:returns: cache directory shared by users, same as `user_cache_dir`""" + return self.user_cache_dir + + @property + def user_state_dir(self) -> str: + """:returns: state directory tied to the user, same as `user_data_dir`""" + return self.user_data_dir + + @property + def site_state_dir(self) -> str: + """:returns: state directory shared by users, same as `user_state_dir`""" + return self.user_state_dir + + @property + def user_log_dir(self) -> str: + """:returns: log directory tied to the user, same as `user_cache_dir` if not opinionated else ``log`` in it, e.g. ``/data/user///cache//log``""" + path = self.user_cache_dir + if self.opinion: + path = os.path.join(path, "log") # noqa: PTH118 + self._optionally_create_directory(path) + return path + + @property + def site_log_dir(self) -> str: + """:returns: log directory shared by users, same as `user_log_dir`""" + return self.user_log_dir + + @property + def user_documents_dir(self) -> str: + """:returns: documents directory tied to the user e.g. ``/storage/emulated/0/Documents``""" + return _android_documents_folder() + + @property + def user_downloads_dir(self) -> str: + """:returns: downloads directory tied to the user e.g. ``/storage/emulated/0/Downloads``""" + return _android_downloads_folder() + + @property + def user_pictures_dir(self) -> str: + """:returns: pictures directory tied to the user e.g. ``/storage/emulated/0/Pictures``""" + return _android_pictures_folder() + + @property + def user_videos_dir(self) -> str: + """:returns: videos directory tied to the user e.g. ``/storage/emulated/0/DCIM/Camera``""" + return _android_videos_folder() + + @property + def user_music_dir(self) -> str: + """:returns: music directory tied to the user e.g. ``/storage/emulated/0/Music``""" + return _android_music_folder() + + @property + def user_desktop_dir(self) -> str: + """:returns: desktop directory tied to the user e.g. ``/storage/emulated/0/Desktop``""" + return "/storage/emulated/0/Desktop" + + @property + def user_bin_dir(self) -> str: + """:returns: bin directory tied to the user, e.g. ``/data/user///files/bin``""" + return os.path.join(cast("str", _android_folder()), "files", "bin") # noqa: PTH118 + + @property + def site_bin_dir(self) -> str: + """:returns: bin directory shared by users, same as `user_bin_dir`""" + return self.user_bin_dir + + @property + def user_applications_dir(self) -> str: + """:returns: applications directory tied to the user, same as `user_data_dir`""" + return self.user_data_dir + + @property + def site_applications_dir(self) -> str: + """:returns: applications directory shared by users, same as `user_applications_dir`""" + return self.user_applications_dir + + @property + def user_runtime_dir(self) -> str: + """:returns: runtime directory tied to the user, same as `user_cache_dir` if not opinionated else ``tmp`` in it, e.g. ``/data/user///cache//tmp``""" + path = self.user_cache_dir + if self.opinion: + path = os.path.join(path, "tmp") # noqa: PTH118 + self._optionally_create_directory(path) + return path + + @property + def site_runtime_dir(self) -> str: + """:returns: runtime directory shared by users, same as `user_runtime_dir`""" + return self.user_runtime_dir + + +@lru_cache(maxsize=1) +def _android_folder() -> str | None: # noqa: C901 + """:returns: base folder for the Android OS or None if it cannot be found""" + result: str | None = None + # type checker isn't happy with our "import android", just don't do this when type checking see + # https://stackoverflow.com/a/61394121 + if not TYPE_CHECKING: + try: + # First try to get a path to android app using python4android (if available)... + from android import mActivity # noqa: PLC0415 + + context = cast("android.content.Context", mActivity.getApplicationContext()) # noqa: F821 + result = context.getFilesDir().getParentFile().getAbsolutePath() + except Exception: # noqa: BLE001 + result = None + if result is None: + try: + # ...and fall back to using plain pyjnius, if python4android isn't available or doesn't deliver any useful + # result... + from jnius import autoclass # noqa: PLC0415 # ty: ignore[unresolved-import] + + context = autoclass("android.content.Context") + result = context.getFilesDir().getParentFile().getAbsolutePath() + except Exception: # noqa: BLE001 + result = None + if result is None: + # and if that fails, too, find an android folder looking at path on the sys.path + # warning: only works for apps installed under /data, not adopted storage etc. + pattern = re.compile(r"/data/(data|user/\d+)/(.+)/files") + for path in sys.path: + if pattern.match(path): + result = path.split("/files")[0] + break + else: + result = None + if result is None: + # one last try: find an android folder looking at path on the sys.path taking adopted storage paths into + # account + pattern = re.compile(r"/mnt/expand/[a-fA-F0-9-]{36}/(data|user/\d+)/(.+)/files") + for path in sys.path: + if pattern.match(path): + result = path.split("/files")[0] + break + else: + result = None + return result + + +@lru_cache(maxsize=1) +def _android_documents_folder() -> str: + """:returns: documents folder for the Android OS""" + # Get directories with pyjnius + try: + from jnius import autoclass # noqa: PLC0415 # ty: ignore[unresolved-import] + + context = autoclass("android.content.Context") + environment = autoclass("android.os.Environment") + documents_dir: str = context.getExternalFilesDir(environment.DIRECTORY_DOCUMENTS).getAbsolutePath() + except Exception: # noqa: BLE001 + documents_dir = "/storage/emulated/0/Documents" + + return documents_dir + + +@lru_cache(maxsize=1) +def _android_downloads_folder() -> str: + """:returns: downloads folder for the Android OS""" + # Get directories with pyjnius + try: + from jnius import autoclass # noqa: PLC0415 # ty: ignore[unresolved-import] + + context = autoclass("android.content.Context") + environment = autoclass("android.os.Environment") + downloads_dir: str = context.getExternalFilesDir(environment.DIRECTORY_DOWNLOADS).getAbsolutePath() + except Exception: # noqa: BLE001 + downloads_dir = "/storage/emulated/0/Downloads" + + return downloads_dir + + +@lru_cache(maxsize=1) +def _android_pictures_folder() -> str: + """:returns: pictures folder for the Android OS""" + # Get directories with pyjnius + try: + from jnius import autoclass # noqa: PLC0415 # ty: ignore[unresolved-import] + + context = autoclass("android.content.Context") + environment = autoclass("android.os.Environment") + pictures_dir: str = context.getExternalFilesDir(environment.DIRECTORY_PICTURES).getAbsolutePath() + except Exception: # noqa: BLE001 + pictures_dir = "/storage/emulated/0/Pictures" + + return pictures_dir + + +@lru_cache(maxsize=1) +def _android_videos_folder() -> str: + """:returns: videos folder for the Android OS""" + # Get directories with pyjnius + try: + from jnius import autoclass # noqa: PLC0415 # ty: ignore[unresolved-import] + + context = autoclass("android.content.Context") + environment = autoclass("android.os.Environment") + videos_dir: str = context.getExternalFilesDir(environment.DIRECTORY_DCIM).getAbsolutePath() + except Exception: # noqa: BLE001 + videos_dir = "/storage/emulated/0/DCIM/Camera" + + return videos_dir + + +@lru_cache(maxsize=1) +def _android_music_folder() -> str: + """:returns: music folder for the Android OS""" + # Get directories with pyjnius + try: + from jnius import autoclass # noqa: PLC0415 # ty: ignore[unresolved-import] + + context = autoclass("android.content.Context") + environment = autoclass("android.os.Environment") + music_dir: str = context.getExternalFilesDir(environment.DIRECTORY_MUSIC).getAbsolutePath() + except Exception: # noqa: BLE001 + music_dir = "/storage/emulated/0/Music" + + return music_dir + + +__all__ = [ + "Android", +] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/api.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/api.py new file mode 100644 index 0000000000000000000000000000000000000000..1e3b9a97c6538c8456ffcd196407eb040238013d --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/api.py @@ -0,0 +1,413 @@ +"""Base API.""" + +from __future__ import annotations + +import os +from abc import ABC, abstractmethod +from pathlib import Path +from typing import TYPE_CHECKING + +if TYPE_CHECKING: + from collections.abc import Iterator + from typing import Literal + + +class PlatformDirsABC(ABC): # noqa: PLR0904 + """Abstract base class defining all platform directory properties, their :class:`~pathlib.Path` variants, and iterators. + + Platform-specific subclasses (e.g. :class:`~platformdirs.windows.Windows`, :class:`~platformdirs.macos.MacOS`, + :class:`~platformdirs.unix.Unix`) implement the abstract properties to return the appropriate paths for each + operating system. + + """ + + def __init__( # noqa: PLR0913, PLR0917 + self, + appname: str | None = None, + appauthor: str | Literal[False] | None = None, + version: str | None = None, + roaming: bool = False, # noqa: FBT001, FBT002 + multipath: bool = False, # noqa: FBT001, FBT002 + opinion: bool = True, # noqa: FBT001, FBT002 + ensure_exists: bool = False, # noqa: FBT001, FBT002 + use_site_for_root: bool = False, # noqa: FBT001, FBT002 + ) -> None: + """Create a new platform directory. + + :param appname: See `appname`. + :param appauthor: See `appauthor`. + :param version: See `version`. + :param roaming: See `roaming`. + :param multipath: See `multipath`. + :param opinion: See `opinion`. + :param ensure_exists: See `ensure_exists`. + :param use_site_for_root: See `use_site_for_root`. + + """ + self.appname = appname #: The name of the application. + self.appauthor = appauthor + """The name of the app author or distributing body for this application. + + Typically, it is the owning company name. Defaults to `appname`. You may pass ``False`` to disable it. + + .. note:: + + On Windows, the directory structure is ``//``. When ``appauthor`` is ``None`` (the + default), it falls back to ``appname``, resulting in ``//`` (e.g. + ``AppData/Local/myapp/myapp``). Pass ``appauthor=False`` to omit the author directory entirely and get + ``/``. + + """ + self.version = version + """An optional version path element to append to the path. + + You might want to use this if you want multiple versions of your app to be able to run independently. If used, + this would typically be ``.``. + + """ + self.roaming = roaming + """Whether to use the roaming appdata directory on Windows. + + That means that for users on a Windows network setup for roaming profiles, this user data will be synced on + login (see `here `_). + + """ + self.multipath = multipath + """An optional parameter which indicates that the entire list of data dirs should be returned. + + By default, the first item would only be returned. Only affects ``site_data_dir`` and ``site_config_dir`` on + Unix and macOS. + + """ + self.opinion = opinion + """Whether to use opinionated values. + + When enabled, appends an additional subdirectory for certain directories: e.g. ``Cache`` for cache and ``Logs`` + for logs on Windows, ``log`` for logs on Unix. + + """ + self.ensure_exists = ensure_exists + """Optionally create the directory (and any missing parents) upon access if it does not exist. + + By default, no directories are created. + + """ + self.use_site_for_root = use_site_for_root + """Whether to redirect ``user_*_dir`` calls to their ``site_*_dir`` equivalents when running as root (uid 0). + + Only has an effect on Unix. Disabled by default for backwards compatibility. When enabled, XDG user environment + variables (e.g. ``XDG_DATA_HOME``) are bypassed for the redirected directories. + + """ + + def _append_app_name_and_version(self, *base: str) -> str: + params = list(base[1:]) + if self.appname: + params.append(self.appname) + if self.version: + params.append(self.version) + path = os.path.join(base[0], *params) # noqa: PTH118 + self._optionally_create_directory(path) + return path + + def _optionally_create_directory(self, path: str) -> None: + if self.ensure_exists: + Path(path).mkdir(parents=True, exist_ok=True) + + def _first_item_as_path_if_multipath(self, directory: str) -> Path: + if self.multipath: + # If multipath is True, the first path is returned. + directory = directory.partition(os.pathsep)[0] + return Path(directory) + + @property + @abstractmethod + def user_data_dir(self) -> str: + """:returns: data directory tied to the user""" + + @property + @abstractmethod + def site_data_dir(self) -> str: + """:returns: data directory shared by users""" + + @property + def _site_data_dirs(self) -> list[str]: + raise NotImplementedError + + @property + @abstractmethod + def user_config_dir(self) -> str: + """:returns: config directory tied to the user""" + + @property + @abstractmethod + def site_config_dir(self) -> str: + """:returns: config directory shared by users""" + + @property + def _site_config_dirs(self) -> list[str]: + raise NotImplementedError + + @property + @abstractmethod + def user_cache_dir(self) -> str: + """:returns: cache directory tied to the user""" + + @property + @abstractmethod + def site_cache_dir(self) -> str: + """:returns: cache directory shared by users""" + + @property + @abstractmethod + def user_state_dir(self) -> str: + """:returns: state directory tied to the user""" + + @property + @abstractmethod + def site_state_dir(self) -> str: + """:returns: state directory shared by users""" + + @property + @abstractmethod + def user_log_dir(self) -> str: + """:returns: log directory tied to the user""" + + @property + @abstractmethod + def site_log_dir(self) -> str: + """:returns: log directory shared by users""" + + @property + @abstractmethod + def user_documents_dir(self) -> str: + """:returns: documents directory tied to the user""" + + @property + @abstractmethod + def user_downloads_dir(self) -> str: + """:returns: downloads directory tied to the user""" + + @property + @abstractmethod + def user_pictures_dir(self) -> str: + """:returns: pictures directory tied to the user""" + + @property + @abstractmethod + def user_videos_dir(self) -> str: + """:returns: videos directory tied to the user""" + + @property + @abstractmethod + def user_music_dir(self) -> str: + """:returns: music directory tied to the user""" + + @property + @abstractmethod + def user_desktop_dir(self) -> str: + """:returns: desktop directory tied to the user""" + + @property + @abstractmethod + def user_bin_dir(self) -> str: + """:returns: bin directory tied to the user""" + + @property + @abstractmethod + def site_bin_dir(self) -> str: + """:returns: bin directory shared by users""" + + @property + @abstractmethod + def user_applications_dir(self) -> str: + """:returns: applications directory tied to the user""" + + @property + @abstractmethod + def site_applications_dir(self) -> str: + """:returns: applications directory shared by users""" + + @property + def _site_applications_dirs(self) -> list[str]: + raise NotImplementedError + + @property + @abstractmethod + def user_runtime_dir(self) -> str: + """:returns: runtime directory tied to the user""" + + @property + @abstractmethod + def site_runtime_dir(self) -> str: + """:returns: runtime directory shared by users""" + + @property + def user_data_path(self) -> Path: + """:returns: data path tied to the user""" + return Path(self.user_data_dir) + + @property + def site_data_path(self) -> Path: + """:returns: data path shared by users""" + return Path(self.site_data_dir) + + @property + def user_config_path(self) -> Path: + """:returns: config path tied to the user""" + return Path(self.user_config_dir) + + @property + def site_config_path(self) -> Path: + """:returns: config path shared by users""" + return Path(self.site_config_dir) + + @property + def user_cache_path(self) -> Path: + """:returns: cache path tied to the user""" + return Path(self.user_cache_dir) + + @property + def site_cache_path(self) -> Path: + """:returns: cache path shared by users""" + return Path(self.site_cache_dir) + + @property + def user_state_path(self) -> Path: + """:returns: state path tied to the user""" + return Path(self.user_state_dir) + + @property + def site_state_path(self) -> Path: + """:returns: state path shared by users""" + return Path(self.site_state_dir) + + @property + def user_log_path(self) -> Path: + """:returns: log path tied to the user""" + return Path(self.user_log_dir) + + @property + def site_log_path(self) -> Path: + """:returns: log path shared by users""" + return Path(self.site_log_dir) + + @property + def user_documents_path(self) -> Path: + """:returns: documents path tied to the user""" + return Path(self.user_documents_dir) + + @property + def user_downloads_path(self) -> Path: + """:returns: downloads path tied to the user""" + return Path(self.user_downloads_dir) + + @property + def user_pictures_path(self) -> Path: + """:returns: pictures path tied to the user""" + return Path(self.user_pictures_dir) + + @property + def user_videos_path(self) -> Path: + """:returns: videos path tied to the user""" + return Path(self.user_videos_dir) + + @property + def user_music_path(self) -> Path: + """:returns: music path tied to the user""" + return Path(self.user_music_dir) + + @property + def user_desktop_path(self) -> Path: + """:returns: desktop path tied to the user""" + return Path(self.user_desktop_dir) + + @property + def user_bin_path(self) -> Path: + """:returns: bin path tied to the user""" + return Path(self.user_bin_dir) + + @property + def site_bin_path(self) -> Path: + """:returns: bin path shared by users""" + return Path(self.site_bin_dir) + + @property + def user_applications_path(self) -> Path: + """:returns: applications path tied to the user""" + return Path(self.user_applications_dir) + + @property + def site_applications_path(self) -> Path: + """:returns: applications path shared by users""" + return Path(self.site_applications_dir) + + @property + def user_runtime_path(self) -> Path: + """:returns: runtime path tied to the user""" + return Path(self.user_runtime_dir) + + @property + def site_runtime_path(self) -> Path: + """:returns: runtime path shared by users""" + return Path(self.site_runtime_dir) + + def iter_config_dirs(self) -> Iterator[str]: + """:yield: all user and site configuration directories.""" + yield self.user_config_dir + yield self.site_config_dir + + def iter_data_dirs(self) -> Iterator[str]: + """:yield: all user and site data directories.""" + yield self.user_data_dir + yield self.site_data_dir + + def iter_cache_dirs(self) -> Iterator[str]: + """:yield: all user and site cache directories.""" + yield self.user_cache_dir + yield self.site_cache_dir + + def iter_state_dirs(self) -> Iterator[str]: + """:yield: all user and site state directories.""" + yield self.user_state_dir + yield self.site_state_dir + + def iter_log_dirs(self) -> Iterator[str]: + """:yield: all user and site log directories.""" + yield self.user_log_dir + yield self.site_log_dir + + def iter_runtime_dirs(self) -> Iterator[str]: + """:yield: all user and site runtime directories.""" + yield self.user_runtime_dir + yield self.site_runtime_dir + + def iter_config_paths(self) -> Iterator[Path]: + """:yield: all user and site configuration paths.""" + for path in self.iter_config_dirs(): + yield Path(path) + + def iter_data_paths(self) -> Iterator[Path]: + """:yield: all user and site data paths.""" + for path in self.iter_data_dirs(): + yield Path(path) + + def iter_cache_paths(self) -> Iterator[Path]: + """:yield: all user and site cache paths.""" + for path in self.iter_cache_dirs(): + yield Path(path) + + def iter_state_paths(self) -> Iterator[Path]: + """:yield: all user and site state paths.""" + for path in self.iter_state_dirs(): + yield Path(path) + + def iter_log_paths(self) -> Iterator[Path]: + """:yield: all user and site log paths.""" + for path in self.iter_log_dirs(): + yield Path(path) + + def iter_runtime_paths(self) -> Iterator[Path]: + """:yield: all user and site runtime paths.""" + for path in self.iter_runtime_dirs(): + yield Path(path) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/macos.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/macos.py new file mode 100644 index 0000000000000000000000000000000000000000..26447e396e38d61be2f9cc4bbb5ce4f0dcf3bb93 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/macos.py @@ -0,0 +1,193 @@ +"""macOS.""" + +from __future__ import annotations + +import os.path +import sys +from typing import TYPE_CHECKING + +if TYPE_CHECKING: + from collections.abc import Iterator + +from ._xdg import XDGMixin +from .api import PlatformDirsABC + +if TYPE_CHECKING: + from pathlib import Path + + +class _MacOSDefaults(PlatformDirsABC): # noqa: PLR0904 + """Default platform directories for macOS without XDG environment variable overrides. + + Follows the guidance from `Apple's File System Programming Guide + `_. + The XDG env var handling is in :class:`~platformdirs._xdg.XDGMixin`. + + """ + + def _base_user_app_support_dir(self) -> str: + return self._append_app_name_and_version(os.path.expanduser("~/Library/Application Support")) # noqa: PTH111 + + def _base_site_dirs(self) -> list[str]: + is_homebrew = "/opt/python" in sys.prefix + homebrew_prefix = sys.prefix.split("/opt/python")[0] if is_homebrew else "" + path_list = [self._append_app_name_and_version(f"{homebrew_prefix}/share")] if is_homebrew else [] + path_list.append(self._append_app_name_and_version("/Library/Application Support")) + return path_list + + @property + def user_data_dir(self) -> str: + """:returns: data directory tied to the user, e.g. ``~/Library/Application Support/$appname/$version``""" + return self._base_user_app_support_dir() + + @property + def _site_data_dirs(self) -> list[str]: + return self._base_site_dirs() + + @property + def site_data_path(self) -> Path: + """:returns: data path shared by users. Only return the first item, even if ``multipath`` is set to ``True``""" + return self._first_item_as_path_if_multipath(self.site_data_dir) + + @property + def user_config_dir(self) -> str: + """:returns: config directory tied to the user, same as `user_data_dir`""" + return self._base_user_app_support_dir() + + @property + def _site_config_dirs(self) -> list[str]: + return self._base_site_dirs() + + @property + def user_cache_dir(self) -> str: + """:returns: cache directory tied to the user, e.g. ``~/Library/Caches/$appname/$version``""" + return self._append_app_name_and_version(os.path.expanduser("~/Library/Caches")) # noqa: PTH111 + + @property + def site_cache_dir(self) -> str: + """:returns: cache directory shared by users, e.g. ``/Library/Caches/$appname/$version``. If we're using a Python binary managed by `Homebrew `_, the directory will be under the Homebrew prefix, e.g. ``$homebrew_prefix/var/cache/$appname/$version``. If `multipath ` is enabled, and we're in Homebrew, the response is a multi-path string separated by ":", e.g. ``$homebrew_prefix/var/cache/$appname/$version:/Library/Caches/$appname/$version``""" + is_homebrew = "/opt/python" in sys.prefix + homebrew_prefix = sys.prefix.split("/opt/python")[0] if is_homebrew else "" + path_list = [self._append_app_name_and_version(f"{homebrew_prefix}/var/cache")] if is_homebrew else [] + path_list.append(self._append_app_name_and_version("/Library/Caches")) + if self.multipath: + return os.pathsep.join(path_list) + return path_list[0] + + @property + def site_cache_path(self) -> Path: + """:returns: cache path shared by users. Only return the first item, even if ``multipath`` is set to ``True``""" + return self._first_item_as_path_if_multipath(self.site_cache_dir) + + @property + def user_state_dir(self) -> str: + """:returns: state directory tied to the user, same as `user_data_dir`""" + return self._base_user_app_support_dir() + + @property + def site_state_dir(self) -> str: + """:returns: state directory shared by users, same as `site_data_dir`""" + return self._base_site_dirs()[0] + + @property + def user_log_dir(self) -> str: + """:returns: log directory tied to the user, e.g. ``~/Library/Logs/$appname/$version``""" + return self._append_app_name_and_version(os.path.expanduser("~/Library/Logs")) # noqa: PTH111 + + @property + def site_log_dir(self) -> str: + """:returns: log directory shared by users, e.g. ``/Library/Logs/$appname/$version``""" + return self._append_app_name_and_version("/Library/Logs") + + @property + def user_documents_dir(self) -> str: + """:returns: documents directory tied to the user, e.g. ``~/Documents``""" + return os.path.expanduser("~/Documents") # noqa: PTH111 + + @property + def user_downloads_dir(self) -> str: + """:returns: downloads directory tied to the user, e.g. ``~/Downloads``""" + return os.path.expanduser("~/Downloads") # noqa: PTH111 + + @property + def user_pictures_dir(self) -> str: + """:returns: pictures directory tied to the user, e.g. ``~/Pictures``""" + return os.path.expanduser("~/Pictures") # noqa: PTH111 + + @property + def user_videos_dir(self) -> str: + """:returns: videos directory tied to the user, e.g. ``~/Movies``""" + return os.path.expanduser("~/Movies") # noqa: PTH111 + + @property + def user_music_dir(self) -> str: + """:returns: music directory tied to the user, e.g. ``~/Music``""" + return os.path.expanduser("~/Music") # noqa: PTH111 + + @property + def user_desktop_dir(self) -> str: + """:returns: desktop directory tied to the user, e.g. ``~/Desktop``""" + return os.path.expanduser("~/Desktop") # noqa: PTH111 + + @property + def user_bin_dir(self) -> str: + """:returns: bin directory tied to the user, e.g. ``~/.local/bin``""" + return os.path.expanduser("~/.local/bin") # noqa: PTH111 + + @property + def site_bin_dir(self) -> str: + """:returns: bin directory shared by users, e.g. ``/usr/local/bin``""" + return "/usr/local/bin" + + @property + def user_applications_dir(self) -> str: + """:returns: applications directory tied to the user, e.g. ``~/Applications``""" + return os.path.expanduser("~/Applications") # noqa: PTH111 + + @property + def _site_applications_dirs(self) -> list[str]: + return ["/Applications"] + + @property + def site_applications_dir(self) -> str: + """:returns: applications directory shared by users, e.g. ``/Applications``""" + dirs = self._site_applications_dirs + return os.pathsep.join(dirs) if self.multipath else dirs[0] + + @property + def user_runtime_dir(self) -> str: + """:returns: runtime directory tied to the user, e.g. ``~/Library/Caches/TemporaryItems/$appname/$version``""" + return self._append_app_name_and_version(os.path.expanduser("~/Library/Caches/TemporaryItems")) # noqa: PTH111 + + @property + def site_runtime_dir(self) -> str: + """:returns: runtime directory shared by users, same as `user_runtime_dir`""" + return self.user_runtime_dir + + def iter_config_dirs(self) -> Iterator[str]: + """:yield: all user and site configuration directories.""" + yield self.user_config_dir + yield from self._site_config_dirs + + def iter_data_dirs(self) -> Iterator[str]: + """:yield: all user and site data directories.""" + yield self.user_data_dir + yield from self._site_data_dirs + + +class MacOS(XDGMixin, _MacOSDefaults): + """Platform directories for the macOS operating system. + + Follows the guidance from `Apple documentation + `_. + Makes use of the `appname `, `version + `, `ensure_exists `. + + XDG environment variables (e.g. ``$XDG_DATA_HOME``) are supported and take precedence over macOS defaults. + + """ + + +__all__ = [ + "MacOS", +] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/py.typed b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/py.typed new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/unix.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/unix.py new file mode 100644 index 0000000000000000000000000000000000000000..8ec5a6bc71839e1ade4fee8f84035ac3dc11454b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/unix.py @@ -0,0 +1,296 @@ +"""Unix.""" + +from __future__ import annotations + +import os +import sys +from configparser import ConfigParser +from functools import cached_property +from pathlib import Path +from tempfile import gettempdir +from typing import TYPE_CHECKING, NoReturn + +from ._xdg import XDGMixin +from .api import PlatformDirsABC + +if TYPE_CHECKING: + from collections.abc import Iterator + +if sys.platform == "win32": + + def getuid() -> NoReturn: + msg = "should only be used on Unix" + raise RuntimeError(msg) + +else: + from os import getuid + + +class _UnixDefaults(PlatformDirsABC): # noqa: PLR0904 + """Default directories for Unix/Linux without XDG environment variable overrides. + + The XDG env var handling is in :class:`~platformdirs._xdg.XDGMixin`. + + """ + + @cached_property + def _use_site(self) -> bool: + return self.use_site_for_root and getuid() == 0 + + @property + def user_data_dir(self) -> str: + """:returns: data directory tied to the user, e.g. ``~/.local/share/$appname/$version`` or ``$XDG_DATA_HOME/$appname/$version``""" + return self._append_app_name_and_version(os.path.expanduser("~/.local/share")) # noqa: PTH111 + + @property + def _site_data_dirs(self) -> list[str]: + return [self._append_app_name_and_version("/usr/local/share"), self._append_app_name_and_version("/usr/share")] + + @property + def user_config_dir(self) -> str: + """:returns: config directory tied to the user, e.g. ``~/.config/$appname/$version`` or ``$XDG_CONFIG_HOME/$appname/$version``""" + return self._append_app_name_and_version(os.path.expanduser("~/.config")) # noqa: PTH111 + + @property + def _site_config_dirs(self) -> list[str]: + return [self._append_app_name_and_version("/etc/xdg")] + + @property + def user_cache_dir(self) -> str: + """:returns: cache directory tied to the user, e.g. ``~/.cache/$appname/$version`` or ``$XDG_CACHE_HOME/$appname/$version``""" + return self._append_app_name_and_version(os.path.expanduser("~/.cache")) # noqa: PTH111 + + @property + def site_cache_dir(self) -> str: + """:returns: cache directory shared by users, e.g. ``/var/cache/$appname/$version``""" + return self._append_app_name_and_version("/var/cache") + + @property + def user_state_dir(self) -> str: + """:returns: state directory tied to the user, e.g. ``~/.local/state/$appname/$version`` or ``$XDG_STATE_HOME/$appname/$version``""" + return self._append_app_name_and_version(os.path.expanduser("~/.local/state")) # noqa: PTH111 + + @property + def site_state_dir(self) -> str: + """:returns: state directory shared by users, e.g. ``/var/lib/$appname/$version``""" + return self._append_app_name_and_version("/var/lib") + + @property + def user_log_dir(self) -> str: + """:returns: log directory tied to the user, same as `user_state_dir` if not opinionated else ``log`` in it""" + path = self.user_state_dir + if self.opinion: + path = os.path.join(path, "log") # noqa: PTH118 + self._optionally_create_directory(path) + return path + + @property + def site_log_dir(self) -> str: + """:returns: log directory shared by users, e.g. ``/var/log/$appname/$version`` + + Unlike `user_log_dir`, ``opinion`` has no effect since ``/var/log`` is inherently a log directory. + + """ + return self._append_app_name_and_version("/var/log") + + @property + def user_documents_dir(self) -> str: + """:returns: documents directory tied to the user, e.g. ``~/Documents``""" + return _get_user_media_dir("XDG_DOCUMENTS_DIR", "~/Documents") + + @property + def user_downloads_dir(self) -> str: + """:returns: downloads directory tied to the user, e.g. ``~/Downloads``""" + return _get_user_media_dir("XDG_DOWNLOAD_DIR", "~/Downloads") + + @property + def user_pictures_dir(self) -> str: + """:returns: pictures directory tied to the user, e.g. ``~/Pictures``""" + return _get_user_media_dir("XDG_PICTURES_DIR", "~/Pictures") + + @property + def user_videos_dir(self) -> str: + """:returns: videos directory tied to the user, e.g. ``~/Videos``""" + return _get_user_media_dir("XDG_VIDEOS_DIR", "~/Videos") + + @property + def user_music_dir(self) -> str: + """:returns: music directory tied to the user, e.g. ``~/Music``""" + return _get_user_media_dir("XDG_MUSIC_DIR", "~/Music") + + @property + def user_desktop_dir(self) -> str: + """:returns: desktop directory tied to the user, e.g. ``~/Desktop``""" + return _get_user_media_dir("XDG_DESKTOP_DIR", "~/Desktop") + + @property + def user_bin_dir(self) -> str: + """:returns: bin directory tied to the user, e.g. ``~/.local/bin``""" + return os.path.expanduser("~/.local/bin") # noqa: PTH111 + + @property + def site_bin_dir(self) -> str: + """:returns: bin directory shared by users, e.g. ``/usr/local/bin``""" + return "/usr/local/bin" + + @property + def user_applications_dir(self) -> str: + """:returns: applications directory tied to the user, e.g. ``~/.local/share/applications``""" + return os.path.join(os.path.expanduser("~/.local/share"), "applications") # noqa: PTH111, PTH118 + + @property + def _site_applications_dirs(self) -> list[str]: + return [os.path.join(p, "applications") for p in ["/usr/local/share", "/usr/share"]] # noqa: PTH118 + + @property + def site_applications_dir(self) -> str: + """:returns: applications directory shared by users, e.g. ``/usr/share/applications``""" + dirs = self._site_applications_dirs + return os.pathsep.join(dirs) if self.multipath else dirs[0] + + @property + def user_runtime_dir(self) -> str: + """:returns: runtime directory tied to the user, e.g. ``$XDG_RUNTIME_DIR/$appname/$version``. + + If ``$XDG_RUNTIME_DIR`` is unset, tries the platform default (``/tmp/run/user/$(id -u)`` on OpenBSD, ``/var/run/user/$(id -u)`` on FreeBSD/NetBSD, ``/run/user/$(id -u)`` otherwise). If the default is not writable, falls back to a temporary directory. + + """ + if sys.platform.startswith("openbsd"): + path = f"/tmp/run/user/{getuid()}" # noqa: S108 + elif sys.platform.startswith(("freebsd", "netbsd")): + path = f"/var/run/user/{getuid()}" + else: + path = f"/run/user/{getuid()}" + if not os.access(path, os.W_OK): + path = f"{gettempdir()}/runtime-{getuid()}" + return self._append_app_name_and_version(path) + + @property + def site_runtime_dir(self) -> str: + """:returns: runtime directory shared by users, e.g. ``/run/$appname/$version`` or ``$XDG_RUNTIME_DIR/$appname/$version``. + + Note that this behaves almost exactly like `user_runtime_dir` if ``$XDG_RUNTIME_DIR`` is set, but will fall back to paths associated to the root user instead of a regular logged-in user if it's not set. + + If you wish to ensure that a logged-in root user path is returned e.g. ``/run/user/0``, use `user_runtime_dir` instead. + + For FreeBSD/OpenBSD/NetBSD, it would return ``/var/run/$appname/$version`` if ``$XDG_RUNTIME_DIR`` is not set. + + """ + if sys.platform.startswith(("freebsd", "openbsd", "netbsd")): + path = "/var/run" + else: + path = "/run" + return self._append_app_name_and_version(path) + + @property + def site_data_path(self) -> Path: + """:returns: data path shared by users. Only return the first item, even if ``multipath`` is set to ``True``""" + return self._first_item_as_path_if_multipath(self.site_data_dir) + + @property + def site_config_path(self) -> Path: + """:returns: config path shared by users, returns the first item, even if ``multipath`` is set to ``True``""" + return self._first_item_as_path_if_multipath(self.site_config_dir) + + @property + def site_cache_path(self) -> Path: + """:returns: cache path shared by users. Only return the first item, even if ``multipath`` is set to ``True``""" + return self._first_item_as_path_if_multipath(self.site_cache_dir) + + def iter_config_dirs(self) -> Iterator[str]: + """:yield: all user and site configuration directories.""" + if not self._use_site: + yield self.user_config_dir + yield from self._site_config_dirs + + def iter_data_dirs(self) -> Iterator[str]: + """:yield: all user and site data directories.""" + if not self._use_site: + yield self.user_data_dir + yield from self._site_data_dirs + + +class Unix(XDGMixin, _UnixDefaults): + """On Unix/Linux, we follow the `XDG Basedir Spec `_. + + The spec allows overriding directories with environment variables. The examples shown are the default values, + alongside the name of the environment variable that overrides them. Makes use of the `appname + `, `version `, `multipath + `, `opinion `, `ensure_exists + `. + + """ + + @property + def user_data_dir(self) -> str: + """:returns: data directory tied to the user, or site equivalent when root with ``use_site_for_root``""" + return self.site_data_dir if self._use_site else super().user_data_dir + + @property + def user_config_dir(self) -> str: + """:returns: config directory tied to the user, or site equivalent when root with ``use_site_for_root``""" + return self.site_config_dir if self._use_site else super().user_config_dir + + @property + def user_cache_dir(self) -> str: + """:returns: cache directory tied to the user, or site equivalent when root with ``use_site_for_root``""" + return self.site_cache_dir if self._use_site else super().user_cache_dir + + @property + def user_state_dir(self) -> str: + """:returns: state directory tied to the user, or site equivalent when root with ``use_site_for_root``""" + return self.site_state_dir if self._use_site else super().user_state_dir + + @property + def user_log_dir(self) -> str: + """:returns: log directory tied to the user, or site equivalent when root with ``use_site_for_root``""" + return self.site_log_dir if self._use_site else super().user_log_dir + + @property + def user_applications_dir(self) -> str: + """:returns: applications directory tied to the user, or site equivalent when root with ``use_site_for_root``""" + return self.site_applications_dir if self._use_site else super().user_applications_dir + + @property + def user_runtime_dir(self) -> str: + """:returns: runtime directory tied to the user, or site equivalent when root with ``use_site_for_root``""" + return self.site_runtime_dir if self._use_site else super().user_runtime_dir + + @property + def user_bin_dir(self) -> str: + """:returns: bin directory tied to the user, or site equivalent when root with ``use_site_for_root``""" + return self.site_bin_dir if self._use_site else super().user_bin_dir + + +def _get_user_media_dir(env_var: str, fallback_tilde_path: str) -> str: + if media_dir := _get_user_dirs_folder(env_var): + return media_dir + return os.path.expanduser(fallback_tilde_path) # noqa: PTH111 + + +def _get_user_dirs_folder(key: str) -> str | None: + """Return directory from user-dirs.dirs config file. + + See https://freedesktop.org/wiki/Software/xdg-user-dirs/. + + """ + config_home = os.environ.get("XDG_CONFIG_HOME", "").strip() or os.path.expanduser("~/.config") # noqa: PTH111 + user_dirs_config_path = Path(config_home) / "user-dirs.dirs" + if user_dirs_config_path.exists(): + parser = ConfigParser() + + with user_dirs_config_path.open() as stream: + parser.read_string(f"[top]\n{stream.read()}") + + if key not in parser["top"]: + return None + + path = parser["top"][key].strip('"') + return path.replace("$HOME", os.path.expanduser("~")) # noqa: PTH111 + + return None + + +__all__ = [ + "Unix", +] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/version.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/version.py new file mode 100644 index 0000000000000000000000000000000000000000..220c58a5247f52206d70af62cee1539e9a17354d --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/version.py @@ -0,0 +1,34 @@ +# file generated by setuptools-scm +# don't change, don't track in version control + +__all__ = [ + "__version__", + "__version_tuple__", + "version", + "version_tuple", + "__commit_id__", + "commit_id", +] + +TYPE_CHECKING = False +if TYPE_CHECKING: + from typing import Tuple + from typing import Union + + VERSION_TUPLE = Tuple[Union[int, str], ...] + COMMIT_ID = Union[str, None] +else: + VERSION_TUPLE = object + COMMIT_ID = object + +version: str +__version__: str +__version_tuple__: VERSION_TUPLE +version_tuple: VERSION_TUPLE +commit_id: COMMIT_ID +__commit_id__: COMMIT_ID + +__version__ = version = '4.9.6' +__version_tuple__ = version_tuple = (4, 9, 6) + +__commit_id__ = commit_id = None diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/windows.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/windows.py new file mode 100644 index 0000000000000000000000000000000000000000..47403dea5efe90751e3af5a0380430687073279b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/platformdirs-4.9.6-pyhcf101f3_0/site-packages/platformdirs/windows.py @@ -0,0 +1,369 @@ +"""Windows.""" + +from __future__ import annotations + +import os +import sys +from typing import TYPE_CHECKING, Final + +from .api import PlatformDirsABC + +if TYPE_CHECKING: + from collections.abc import Callable + +# Not exposed by CPython; defined in the Windows SDK (shlobj_core.h) +_KF_FLAG_DONT_VERIFY: Final[int] = 0x00004000 + + +class Windows(PlatformDirsABC): # noqa: PLR0904 + """`MSDN on where to store app data files `_. + + Makes use of the `appname `, `appauthor + `, `version `, `roaming + `, `opinion `, `ensure_exists + `. + + """ + + @property + def user_data_dir(self) -> str: + r""":returns: data directory tied to the user, e.g. ``%USERPROFILE%\AppData\Local\$appauthor\$appname`` (not roaming) or ``%USERPROFILE%\AppData\Roaming\$appauthor\$appname`` (roaming)""" + const = "CSIDL_APPDATA" if self.roaming else "CSIDL_LOCAL_APPDATA" + path = os.path.normpath(get_win_folder(const)) + return self._append_parts(path) + + def _append_parts(self, path: str, *, opinion_value: str | None = None) -> str: + params = [] + if self.appname: + if self.appauthor is not False: + author = self.appauthor or self.appname + params.append(author) + params.append(self.appname) + if opinion_value is not None and self.opinion: + params.append(opinion_value) + if self.version: + params.append(self.version) + path = os.path.join(path, *params) # noqa: PTH118 + self._optionally_create_directory(path) + return path + + @property + def site_data_dir(self) -> str: + r""":returns: data directory shared by users, e.g. ``C:\ProgramData\$appauthor\$appname``""" + path = os.path.normpath(get_win_folder("CSIDL_COMMON_APPDATA")) + return self._append_parts(path) + + @property + def user_config_dir(self) -> str: + """:returns: config directory tied to the user, same as `user_data_dir`""" + return self.user_data_dir + + @property + def site_config_dir(self) -> str: + """:returns: config directory shared by users, same as `site_data_dir`""" + return self.site_data_dir + + @property + def user_cache_dir(self) -> str: + r""":returns: cache directory tied to the user (if opinionated with ``Cache`` folder within ``$appname``) e.g. ``%USERPROFILE%\AppData\Local\$appauthor\$appname\Cache\$version``""" + path = os.path.normpath(get_win_folder("CSIDL_LOCAL_APPDATA")) + return self._append_parts(path, opinion_value="Cache") + + @property + def site_cache_dir(self) -> str: + r""":returns: cache directory shared by users, e.g. ``C:\ProgramData\$appauthor\$appname\Cache\$version``""" + path = os.path.normpath(get_win_folder("CSIDL_COMMON_APPDATA")) + return self._append_parts(path, opinion_value="Cache") + + @property + def user_state_dir(self) -> str: + """:returns: state directory tied to the user, same as `user_data_dir`""" + return self.user_data_dir + + @property + def site_state_dir(self) -> str: + """:returns: state directory shared by users, same as `site_data_dir`""" + return self.site_data_dir + + @property + def user_log_dir(self) -> str: + """:returns: log directory tied to the user, same as `user_data_dir` if not opinionated else ``Logs`` in it""" + path = self.user_data_dir + if self.opinion: + path = os.path.join(path, "Logs") # noqa: PTH118 + self._optionally_create_directory(path) + return path + + @property + def site_log_dir(self) -> str: + """:returns: log directory shared by users, same as `site_data_dir` if not opinionated else ``Logs`` in it""" + path = self.site_data_dir + if self.opinion: + path = os.path.join(path, "Logs") # noqa: PTH118 + self._optionally_create_directory(path) + return path + + @property + def user_documents_dir(self) -> str: + r""":returns: documents directory tied to the user e.g. ``%USERPROFILE%\Documents``""" + return os.path.normpath(get_win_folder("CSIDL_PERSONAL")) + + @property + def user_downloads_dir(self) -> str: + r""":returns: downloads directory tied to the user e.g. ``%USERPROFILE%\Downloads``""" + return os.path.normpath(get_win_folder("CSIDL_DOWNLOADS")) + + @property + def user_pictures_dir(self) -> str: + r""":returns: pictures directory tied to the user e.g. ``%USERPROFILE%\Pictures``""" + return os.path.normpath(get_win_folder("CSIDL_MYPICTURES")) + + @property + def user_videos_dir(self) -> str: + r""":returns: videos directory tied to the user e.g. ``%USERPROFILE%\Videos``""" + return os.path.normpath(get_win_folder("CSIDL_MYVIDEO")) + + @property + def user_music_dir(self) -> str: + r""":returns: music directory tied to the user e.g. ``%USERPROFILE%\Music``""" + return os.path.normpath(get_win_folder("CSIDL_MYMUSIC")) + + @property + def user_desktop_dir(self) -> str: + r""":returns: desktop directory tied to the user, e.g. ``%USERPROFILE%\Desktop``""" + return os.path.normpath(get_win_folder("CSIDL_DESKTOPDIRECTORY")) + + @property + def user_bin_dir(self) -> str: + r""":returns: bin directory tied to the user, e.g. ``%LOCALAPPDATA%\Programs``""" + return os.path.normpath(os.path.join(get_win_folder("CSIDL_LOCAL_APPDATA"), "Programs")) # noqa: PTH118 + + @property + def site_bin_dir(self) -> str: + """:returns: bin directory shared by users, e.g. ``C:\\ProgramData\bin``""" + return os.path.normpath(os.path.join(get_win_folder("CSIDL_COMMON_APPDATA"), "bin")) # noqa: PTH118 + + @property + def user_applications_dir(self) -> str: + r""":returns: applications directory tied to the user, e.g. ``Start Menu\Programs``""" + return os.path.normpath(get_win_folder("CSIDL_PROGRAMS")) + + @property + def site_applications_dir(self) -> str: + r""":returns: applications directory shared by users, e.g. ``C:\ProgramData\Microsoft\Windows\Start Menu\Programs``""" + return os.path.normpath(get_win_folder("CSIDL_COMMON_PROGRAMS")) + + @property + def user_runtime_dir(self) -> str: + r""":returns: runtime directory tied to the user, e.g. ``%USERPROFILE%\AppData\Local\Temp\$appauthor\$appname``""" + path = os.path.normpath(os.path.join(get_win_folder("CSIDL_LOCAL_APPDATA"), "Temp")) # noqa: PTH118 + return self._append_parts(path) + + @property + def site_runtime_dir(self) -> str: + """:returns: runtime directory shared by users, same as `user_runtime_dir`""" + return self.user_runtime_dir + + +def get_win_folder_from_env_vars(csidl_name: str) -> str: + """Get folder from environment variables.""" + result = get_win_folder_if_csidl_name_not_env_var(csidl_name) + if result is not None: + return result + + env_var_name = { + "CSIDL_APPDATA": "APPDATA", + "CSIDL_COMMON_APPDATA": "ALLUSERSPROFILE", + "CSIDL_LOCAL_APPDATA": "LOCALAPPDATA", + }.get(csidl_name) + if env_var_name is None: + msg = f"Unknown CSIDL name: {csidl_name}" + raise ValueError(msg) + result = os.environ.get(env_var_name) + if result is None: + msg = f"Unset environment variable: {env_var_name}" + raise ValueError(msg) + return result + + +def get_win_folder_if_csidl_name_not_env_var(csidl_name: str) -> str | None: # noqa: PLR0911 + """Get a folder for a CSIDL name that does not exist as an environment variable.""" + if csidl_name == "CSIDL_PERSONAL": + return os.path.join(os.path.normpath(os.environ["USERPROFILE"]), "Documents") # noqa: PTH118 + + if csidl_name == "CSIDL_DOWNLOADS": + return os.path.join(os.path.normpath(os.environ["USERPROFILE"]), "Downloads") # noqa: PTH118 + + if csidl_name == "CSIDL_MYPICTURES": + return os.path.join(os.path.normpath(os.environ["USERPROFILE"]), "Pictures") # noqa: PTH118 + + if csidl_name == "CSIDL_MYVIDEO": + return os.path.join(os.path.normpath(os.environ["USERPROFILE"]), "Videos") # noqa: PTH118 + + if csidl_name == "CSIDL_MYMUSIC": + return os.path.join(os.path.normpath(os.environ["USERPROFILE"]), "Music") # noqa: PTH118 + + if csidl_name == "CSIDL_PROGRAMS": + return os.path.join( # noqa: PTH118 + os.path.normpath(os.environ["APPDATA"]), + "Microsoft", + "Windows", + "Start Menu", + "Programs", + ) + + if csidl_name == "CSIDL_COMMON_PROGRAMS": + return os.path.join( # noqa: PTH118 + os.path.normpath(os.environ.get("PROGRAMDATA", os.environ.get("ALLUSERSPROFILE", "C:\\ProgramData"))), + "Microsoft", + "Windows", + "Start Menu", + "Programs", + ) + return None + + +def get_win_folder_from_registry(csidl_name: str) -> str: + """Get folder from the registry. + + This is a fallback technique at best. I'm not sure if using the registry for these guarantees us the correct answer + for all CSIDL_* names. + + """ + machine_names = { + "CSIDL_COMMON_APPDATA", + "CSIDL_COMMON_PROGRAMS", + } + shell_folder_name = { + "CSIDL_APPDATA": "AppData", + "CSIDL_COMMON_APPDATA": "Common AppData", + "CSIDL_LOCAL_APPDATA": "Local AppData", + "CSIDL_PERSONAL": "Personal", + "CSIDL_DOWNLOADS": "{374DE290-123F-4565-9164-39C4925E467B}", + "CSIDL_MYPICTURES": "My Pictures", + "CSIDL_MYVIDEO": "My Video", + "CSIDL_MYMUSIC": "My Music", + "CSIDL_PROGRAMS": "Programs", + "CSIDL_COMMON_PROGRAMS": "Common Programs", + }.get(csidl_name) + if shell_folder_name is None: + msg = f"Unknown CSIDL name: {csidl_name}" + raise ValueError(msg) + if sys.platform != "win32": # only needed for mypy type checker to know that this code runs only on Windows + raise NotImplementedError + import winreg # noqa: PLC0415 + + # Use HKEY_LOCAL_MACHINE for system-wide folders, HKEY_CURRENT_USER for user-specific folders + hkey = winreg.HKEY_LOCAL_MACHINE if csidl_name in machine_names else winreg.HKEY_CURRENT_USER + + key = winreg.OpenKey(hkey, r"Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders") + directory, _ = winreg.QueryValueEx(key, shell_folder_name) + return str(directory) + + +_KNOWN_FOLDER_GUIDS: dict[str, str] = { + "CSIDL_APPDATA": "{3EB685DB-65F9-4CF6-A03A-E3EF65729F3D}", + "CSIDL_COMMON_APPDATA": "{62AB5D82-FDC1-4DC3-A9DD-070D1D495D97}", + "CSIDL_LOCAL_APPDATA": "{F1B32785-6FBA-4FCF-9D55-7B8E7F157091}", + "CSIDL_PERSONAL": "{FDD39AD0-238F-46AF-ADB4-6C85480369C7}", + "CSIDL_MYPICTURES": "{33E28130-4E1E-4676-835A-98395C3BC3BB}", + "CSIDL_MYVIDEO": "{18989B1D-99B5-455B-841C-AB7C74E4DDFC}", + "CSIDL_MYMUSIC": "{4BD8D571-6D19-48D3-BE97-422220080E43}", + "CSIDL_DOWNLOADS": "{374DE290-123F-4565-9164-39C4925E467B}", + "CSIDL_DESKTOPDIRECTORY": "{B4BFCC3A-DB2C-424C-B029-7FE99A87C641}", + "CSIDL_PROGRAMS": "{A77F5D77-2E2B-44C3-A6A2-ABA601054A51}", + "CSIDL_COMMON_PROGRAMS": "{0139D44E-6AFE-49F2-8690-3DAFCAE6FFB8}", +} + + +def get_win_folder_via_ctypes(csidl_name: str) -> str: + """Get folder via :func:`SHGetKnownFolderPath`. + + See https://learn.microsoft.com/en-us/windows/win32/api/shlobj_core/nf-shlobj_core-shgetknownfolderpath. + + """ + if sys.platform != "win32": # only needed for type checker to know that this code runs only on Windows + raise NotImplementedError + from ctypes import HRESULT, POINTER, Structure, WinDLL, byref, create_unicode_buffer, wintypes # noqa: PLC0415 + + class _GUID(Structure): + _fields_ = [ + ("Data1", wintypes.DWORD), + ("Data2", wintypes.WORD), + ("Data3", wintypes.WORD), + ("Data4", wintypes.BYTE * 8), + ] + + ole32 = WinDLL("ole32") + ole32.CLSIDFromString.restype = HRESULT + ole32.CLSIDFromString.argtypes = [wintypes.LPCOLESTR, POINTER(_GUID)] + ole32.CoTaskMemFree.restype = None + ole32.CoTaskMemFree.argtypes = [wintypes.LPVOID] + + shell32 = WinDLL("shell32") + shell32.SHGetKnownFolderPath.restype = HRESULT + shell32.SHGetKnownFolderPath.argtypes = [POINTER(_GUID), wintypes.DWORD, wintypes.HANDLE, POINTER(wintypes.LPWSTR)] + + kernel32 = WinDLL("kernel32") + kernel32.GetShortPathNameW.restype = wintypes.DWORD + kernel32.GetShortPathNameW.argtypes = [wintypes.LPWSTR, wintypes.LPWSTR, wintypes.DWORD] + + folder_guid = _KNOWN_FOLDER_GUIDS.get(csidl_name) + if folder_guid is None: + msg = f"Unknown CSIDL name: {csidl_name}" + raise ValueError(msg) + + guid = _GUID() + ole32.CLSIDFromString(folder_guid, byref(guid)) + + path_ptr = wintypes.LPWSTR() + shell32.SHGetKnownFolderPath(byref(guid), _KF_FLAG_DONT_VERIFY, None, byref(path_ptr)) + result = path_ptr.value + ole32.CoTaskMemFree(path_ptr) + + if result is None: + msg = f"SHGetKnownFolderPath returned NULL for {csidl_name}" + raise ValueError(msg) + + if any(ord(c) > 255 for c in result): # noqa: PLR2004 + buf = create_unicode_buffer(1024) + if kernel32.GetShortPathNameW(result, buf, 1024): + result = buf.value + + return result + + +def _pick_get_win_folder() -> Callable[[str], str]: + """Select the best method to resolve Windows folder paths: ctypes, then registry, then environment variables.""" + try: + import ctypes # noqa: PLC0415, F401 + except ImportError: + pass + else: + return get_win_folder_via_ctypes + try: + import winreg # noqa: PLC0415, F401 + except ImportError: + return get_win_folder_from_env_vars + else: + return get_win_folder_from_registry + + +_resolve_win_folder = _pick_get_win_folder() + + +def get_win_folder(csidl_name: str) -> str: + """Get a Windows folder path, checking for ``WIN_PD_OVERRIDE_*`` environment variable overrides first. + + For example, ``CSIDL_LOCAL_APPDATA`` can be overridden by setting ``WIN_PD_OVERRIDE_LOCAL_APPDATA``. + + """ + env_var = f"WIN_PD_OVERRIDE_{csidl_name.removeprefix('CSIDL_')}" + if override := os.environ.get(env_var, "").strip(): + return override + return _resolve_win_folder(csidl_name) + + +__all__ = [ + "Windows", +] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/about.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/about.json new file mode 100644 index 0000000000000000000000000000000000000000..d8c0142d6e929dac8ad61ff4fbfe9f03e39dbb17 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/about.json @@ -0,0 +1,10 @@ +{ + "channels": [ + "https://conda.anaconda.org/conda-forge/" + ], + "dev_url": "https://github.com/pytest-dev/pluggy/", + "doc_url": "https://pluggy.readthedocs.io/en/latest/", + "home": "https://github.com/pytest-dev/pluggy", + "license": "MIT", + "summary": "Plugin registration and hook calling for Python" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/hash_input.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/hash_input.json new file mode 100644 index 0000000000000000000000000000000000000000..3788e359eb80478ba1f37549cc7226b452042021 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/hash_input.json @@ -0,0 +1 @@ +{"python_min": "3.9", "target_platform": "noarch"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/index.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/index.json new file mode 100644 index 0000000000000000000000000000000000000000..7a5193689e66c08802c24c53a5dd76f472cac920 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/index.json @@ -0,0 +1,14 @@ +{ + "build": "pyhf9edf01_1", + "build_number": 1, + "depends": [ + "python >=3.9", + "python" + ], + "license": "MIT", + "name": "pluggy", + "noarch": "python", + "subdir": "noarch", + "timestamp": 1764896838868, + "version": "1.6.0" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..85f4dd63d2da8e31d7e84d5180f016fdfe315c2c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/licenses/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015 holger krekel (rather uses bitbucket/hpk42) + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/link.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/link.json new file mode 100644 index 0000000000000000000000000000000000000000..ec6589c68a1bf1aedb3f856ab584e80f5302f2cb --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/link.json @@ -0,0 +1,6 @@ +{ + "noarch": { + "type": "python" + }, + "package_metadata_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/paths.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/paths.json new file mode 100644 index 0000000000000000000000000000000000000000..ca43e98038a645e5a0a6faeb127e24b9929ecda0 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/paths.json @@ -0,0 +1,107 @@ +{ + "paths": [ + { + "_path": "site-packages/pluggy/__init__.py", + "path_type": "hardlink", + "sha256": "0fa769d609840e3b43a7c840c1073eaab81aba59cbe2296daea90b0ddfa0f6d8", + "size_in_bytes": 811 + }, + { + "_path": "site-packages/pluggy/_callers.py", + "path_type": "hardlink", + "sha256": "804665946692615b2c676526a4d7e6602d1b755821da361b0057982afb913236", + "size_in_bytes": 5991 + }, + { + "_path": "site-packages/pluggy/_hooks.py", + "path_type": "hardlink", + "sha256": "13a7f79d8708e9d6c4b8ed069b2eb5a3380653fe7dfdeebd902d3c6b4e8406ea", + "size_in_bytes": 25218 + }, + { + "_path": "site-packages/pluggy/_manager.py", + "path_type": "hardlink", + "sha256": "2b8229fe99048ef4f6a0e21f40fa7c0b0016a1756710d81045ccbdb651a28b4a", + "size_in_bytes": 20219 + }, + { + "_path": "site-packages/pluggy/_result.py", + "path_type": "hardlink", + "sha256": "dd77f2ec3ae35db61bee9b91aaec98d956e274858daba3e9ed09ee12531d8fc4", + "size_in_bytes": 3098 + }, + { + "_path": "site-packages/pluggy/_tracing.py", + "path_type": "hardlink", + "sha256": "9d777604298381ff2327157e1cedcfab147e595e777969c5f01e001759c91a0a", + "size_in_bytes": 2073 + }, + { + "_path": "site-packages/pluggy/_version.py", + "path_type": "hardlink", + "sha256": "42e89f4fd17020a57706df00b76f82bc7dec979c5a7150c142c5a5140a958db8", + "size_in_bytes": 704 + }, + { + "_path": "site-packages/pluggy/_warnings.py", + "path_type": "hardlink", + "sha256": "b5dd00bd90697da9ab8820b73aab0bc31321f92cc03237e399ce7c4f9bcfde5c", + "size_in_bytes": 828 + }, + { + "_path": "site-packages/pluggy/py.typed", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pluggy-1.6.0.dist-info/INSTALLER", + "path_type": "hardlink", + "sha256": "bc33022edcb7639ff53355b4e91dade50a0bbf0299efeb6171d1ec0ba5029cfc", + "size_in_bytes": 6 + }, + { + "_path": "site-packages/pluggy-1.6.0.dist-info/METADATA", + "path_type": "hardlink", + "sha256": "7438c35ee25a095eb7416f84b461c2d74425c5e734ad54c3912453c65244e01c", + "size_in_bytes": 4811 + }, + { + "_path": "site-packages/pluggy-1.6.0.dist-info/RECORD", + "path_type": "hardlink", + "sha256": "af5790503854a1f4df4e5d544661dc3d5cb3c5da0ca05e9c60327d6a6727b489", + "size_in_bytes": 1704 + }, + { + "_path": "site-packages/pluggy-1.6.0.dist-info/REQUESTED", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pluggy-1.6.0.dist-info/WHEEL", + "path_type": "hardlink", + "sha256": "ff309ddcdd65ebd02bc724dbf2bcc4a0ff53a5b61792a44548d383e4ebb19d3b", + "size_in_bytes": 91 + }, + { + "_path": "site-packages/pluggy-1.6.0.dist-info/direct_url.json", + "path_type": "hardlink", + "sha256": "b61601a8d764ae7c2ad1647a5b82344ef9509ee0545fb2cec91c62a6480fb5c7", + "size_in_bytes": 117 + }, + { + "_path": "site-packages/pluggy-1.6.0.dist-info/licenses/LICENSE", + "path_type": "hardlink", + "sha256": "d6b65e6c213a5d0b577911d34d6e5949b9f59d76c238c5071a2f3fc16cfb2606", + "size_in_bytes": 1110 + }, + { + "_path": "site-packages/pluggy-1.6.0.dist-info/top_level.txt", + "path_type": "hardlink", + "sha256": "c4a4824616a2faff4c724bccb96a8dcf5e9cd6d6ec98e820a0c4b04e07296071", + "size_in_bytes": 7 + } + ], + "paths_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/recipe/recipe-scripts-license.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/recipe/recipe-scripts-license.txt new file mode 100644 index 0000000000000000000000000000000000000000..2ec51d75f362bc4327a3cfe1c515c16bb3c57367 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/recipe/recipe-scripts-license.txt @@ -0,0 +1,27 @@ +BSD-3-Clause license +Copyright (c) 2015-2022, conda-forge contributors +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + 3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/recipe/recipe.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/recipe/recipe.yaml new file mode 100644 index 0000000000000000000000000000000000000000..05b3c7cfe1de44fc73c76651ef0bd04d452a226c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/recipe/recipe.yaml @@ -0,0 +1,48 @@ +schema_version: 1 + +context: + name: pluggy + version: "1.6.0" + +package: + name: ${{ name|lower }} + version: ${{ version }} + +source: + url: https://pypi.org/packages/source/${{ name[0] }}/${{ name }}/pluggy-${{ version }}.tar.gz + sha256: 7dcc130b76258d33b90f61b658791dede3486c3e6bfb003ee5c9bfb396dd22f3 + +build: + noarch: python + number: 1 + script: ${{ PYTHON }} -m pip install . -vv + +requirements: + host: + - python ${{ python_min }}.* + - setuptools + - setuptools-scm + - pip + run: + - python >=${{ python_min }} + +tests: + - python: + python_version: ${{ python_min }}.* + imports: + - pluggy + pip_check: true + +about: + homepage: https://github.com/pytest-dev/pluggy + license: MIT + license_file: LICENSE + summary: Plugin registration and hook calling for Python + documentation: https://pluggy.readthedocs.io/en/latest/ + repository: https://github.com/pytest-dev/pluggy/ + +extra: + recipe-maintainers: + - johnnygenomics + - nicoddemus + - adriendelsalle diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/recipe/rendered_recipe.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/recipe/rendered_recipe.yaml new file mode 100644 index 0000000000000000000000000000000000000000..3e5de01612ae73486e6576238fa734bf4e4cd607 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/recipe/rendered_recipe.yaml @@ -0,0 +1,762 @@ +recipe: + schema_version: 1 + context: + name: pluggy + version: 1.6.0 + package: + name: pluggy + version: 1.6.0 + source: + - url: https://pypi.org/packages/source/p/pluggy/pluggy-1.6.0.tar.gz + sha256: 7dcc130b76258d33b90f61b658791dede3486c3e6bfb003ee5c9bfb396dd22f3 + build: + number: 1 + string: pyhf9edf01_1 + script: ${{ PYTHON }} -m pip install . -vv + noarch: python + requirements: + host: + - python 3.9.* + - setuptools + - setuptools-scm + - pip + run: + - python >=3.9 + tests: + - python: + imports: + - pluggy + python_version: 3.9.* + about: + homepage: https://github.com/pytest-dev/pluggy + repository: https://github.com/pytest-dev/pluggy/ + documentation: https://pluggy.readthedocs.io/en/latest/ + license: MIT + license_file: + - LICENSE + summary: Plugin registration and hook calling for Python + extra: + recipe-maintainers: + - johnnygenomics + - nicoddemus + - adriendelsalle +build_configuration: + target_platform: noarch + host_platform: + platform: linux-64 + virtual_packages: + - __unix=0=0 + - __linux=6.11.0=0 + - __glibc=2.34=0 + - __archspec=1=x86_64_v4 + build_platform: + platform: linux-64 + virtual_packages: + - __unix=0=0 + - __linux=6.11.0=0 + - __glibc=2.34=0 + - __archspec=1=x86_64_v4 + variant: + python_min: '3.9' + target_platform: noarch + hash: + hash: f9edf01 + prefix: py + directories: + host_prefix: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_pluggy_1764896838/host_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placeho + build_prefix: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_pluggy_1764896838/build_env + work_dir: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_pluggy_1764896838/work + build_dir: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_pluggy_1764896838 + channels: + - https://conda.anaconda.org/conda-forge + channel_priority: strict + solve_strategy: highest + timestamp: 2025-12-05T01:07:18.868262320Z + subpackages: + pluggy: + name: pluggy + version: 1.6.0 + build_string: pyhf9edf01_1 + packaging_settings: + archive_type: conda + compression_level: 15 +finalized_dependencies: + build: null + host: + specs: + - source: python 3.9.* + - source: setuptools + - source: setuptools-scm + - source: pip + resolved: + - build: hc30ae73_0_cpython + build_number: 0 + constrains: + - python_abi 3.9.* *_cp39 + depends: + - __glibc >=2.17,<3.0.a0 + - bzip2 >=1.0.8,<2.0a0 + - ld_impl_linux-64 >=2.36.1 + - libexpat >=2.7.0,<3.0a0 + - libffi >=3.4,<4.0a0 + - libgcc >=13 + - liblzma >=5.8.1,<6.0a0 + - libnsl >=2.0.1,<2.1.0a0 + - libsqlite >=3.50.0,<4.0a0 + - libuuid >=2.38.1,<3.0a0 + - libxcrypt >=4.4.36 + - libzlib >=1.3.1,<2.0a0 + - ncurses >=6.5,<7.0a0 + - openssl >=3.5.0,<4.0a0 + - readline >=8.2,<9.0a0 + - tk >=8.6.13,<8.7.0a0 + - tzdata + license: Python-2.0 + md5: 624ab0484356d86a54297919352d52b6 + name: python + run_exports: + weak: + - python_abi 3.9.* *_cp39 + noarch: + - python + sha256: dcfc417424b21ffca70dddf7a86ef69270b3e8d2040c748b7356a615470d5298 + size: 23677900 + subdir: linux-64 + timestamp: 1749060753022 + version: 3.9.23 + fn: python-3.9.23-hc30ae73_0_cpython.conda + url: https://conda.anaconda.org/conda-forge/linux-64/python-3.9.23-hc30ae73_0_cpython.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhff2d567_0 + build_number: 0 + depends: + - python >=3.9 + license: MIT + license_family: MIT + md5: 4de79c071274a53dcaf2a8c749d1499e + name: setuptools + noarch: python + run_exports: {} + sha256: 972560fcf9657058e3e1f97186cc94389144b46dbdf58c807ce62e83f977e863 + size: 748788 + subdir: noarch + timestamp: 1748804951958 + version: 80.9.0 + fn: setuptools-80.9.0-pyhff2d567_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/setuptools-80.9.0-pyhff2d567_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_0 + build_number: 0 + depends: + - importlib-metadata + - packaging >=20.0 + - python >=3.9 + - setuptools >=45 + - tomli >=1.0.0 + - typing-extensions + license: MIT + license_family: MIT + md5: ad8f901272d56cfb6bf22bb89e9be59b + name: setuptools-scm + noarch: python + run_exports: {} + sha256: 3cfaa3ab1a96fb9bd8debb007604d93576cfa5ec57c01d44567fc5a8b6cf414c + size: 51770 + subdir: noarch + timestamp: 1755378776442 + version: 9.2.0 + fn: setuptools-scm-9.2.0-pyhd8ed1ab_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/setuptools-scm-9.2.0-pyhd8ed1ab_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyh8b19718_0 + build_number: 0 + depends: + - python >=3.9,<3.13.0a0 + - setuptools + - wheel + license: MIT + license_family: MIT + md5: dfce4b2af4bfe90cdcaf56ca0b28ddf5 + name: pip + noarch: python + run_exports: {} + sha256: ec9ed3cef137679f3e3a68e286c6efd52144684e1be0b05004d9699882dadcdd + size: 1177168 + subdir: noarch + timestamp: 1753924973872 + version: '25.2' + fn: pip-25.2-pyh8b19718_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/pip-25.2-pyh8b19718_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hda65f42_8 + build_number: 8 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: bzip2-1.0.6 + license_family: BSD + md5: 51a19bba1b8ebfb60df25cde030b7ebc + name: bzip2 + run_exports: + weak: + - bzip2 >=1.0.8,<2.0a0 + sha256: c30daba32ddebbb7ded490f0e371eae90f51e72db620554089103b4a6934b0d5 + size: 260341 + subdir: linux-64 + timestamp: 1757437258798 + version: 1.0.8 + fn: bzip2-1.0.8-hda65f42_8.conda + url: https://conda.anaconda.org/conda-forge/linux-64/bzip2-1.0.8-hda65f42_8.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: default_hbd61a6d_104 + build_number: 104 + constrains: + - binutils_impl_linux-64 2.45 + depends: + - __glibc >=2.17,<3.0.a0 + - zstd >=1.5.7,<1.6.0a0 + license: GPL-3.0-only + license_family: GPL + md5: a6abd2796fc332536735f68ba23f7901 + name: ld_impl_linux-64 + run_exports: {} + sha256: 9e191baf2426a19507f1d0a17be0fdb7aa155cdf0f61d5a09c808e0a69464312 + size: 725545 + subdir: linux-64 + timestamp: 1764007826689 + version: '2.45' + fn: ld_impl_linux-64-2.45-default_hbd61a6d_104.conda + url: https://conda.anaconda.org/conda-forge/linux-64/ld_impl_linux-64-2.45-default_hbd61a6d_104.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hecca717_0 + build_number: 0 + constrains: + - expat 2.7.3.* + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: MIT + license_family: MIT + md5: 8b09ae86839581147ef2e5c5e229d164 + name: libexpat + run_exports: {} + sha256: 1e1b08f6211629cbc2efe7a5bca5953f8f6b3cae0eeb04ca4dacee1bd4e2db2f + size: 76643 + subdir: linux-64 + timestamp: 1763549731408 + version: 2.7.3 + fn: libexpat-2.7.3-hecca717_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libexpat-2.7.3-hecca717_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h9ec8514_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: MIT + license_family: MIT + md5: 35f29eec58405aaf55e01cb470d8c26a + name: libffi + run_exports: + weak: + - libffi >=3.5.2,<3.6.0a0 + sha256: 25cbdfa65580cfab1b8d15ee90b4c9f1e0d72128f1661449c9a999d341377d54 + size: 57821 + subdir: linux-64 + timestamp: 1760295480630 + version: 3.5.2 + fn: libffi-3.5.2-h9ec8514_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libffi-3.5.2-h9ec8514_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: he0feb66_15 + build_number: 15 + constrains: + - libgomp 15.2.0 he0feb66_15 + - libgcc-ng ==15.2.0=*_15 + depends: + - __glibc >=2.17,<3.0.a0 + - _openmp_mutex >=4.5 + license: GPL-3.0-only WITH GCC-exception-3.1 + md5: a5d86b0496174a412d531eac03af9174 + name: libgcc + run_exports: {} + sha256: 37f2edde2f8281672987c63f13c85a57d04d889dc929ce38204426d5eb2059cc + size: 1041379 + subdir: linux-64 + timestamp: 1764836112865 + version: 15.2.0 + fn: libgcc-15.2.0-he0feb66_15.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgcc-15.2.0-he0feb66_15.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb9d3cd8_2 + build_number: 2 + constrains: + - xz 5.8.1.* + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: 0BSD + md5: 1a580f7796c7bf6393fddb8bbbde58dc + name: liblzma + run_exports: + weak: + - liblzma >=5.8.1,<6.0a0 + sha256: f2591c0069447bbe28d4d696b7fcb0c5bd0b4ac582769b89addbcf26fb3430d8 + size: 112894 + subdir: linux-64 + timestamp: 1749230047870 + version: 5.8.1 + fn: liblzma-5.8.1-hb9d3cd8_2.conda + url: https://conda.anaconda.org/conda-forge/linux-64/liblzma-5.8.1-hb9d3cd8_2.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb9d3cd8_1 + build_number: 1 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: LGPL-2.1-only + license_family: GPL + md5: d864d34357c3b65a4b731f78c0801dc4 + name: libnsl + run_exports: + weak: + - libnsl >=2.0.1,<2.1.0a0 + sha256: 927fe72b054277cde6cb82597d0fcf6baf127dcbce2e0a9d8925a68f1265eef5 + size: 33731 + subdir: linux-64 + timestamp: 1750274110928 + version: 2.0.1 + fn: libnsl-2.0.1-hb9d3cd8_1.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libnsl-2.0.1-hb9d3cd8_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h0c1763c_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + - libzlib >=1.3.1,<2.0a0 + license: blessing + md5: 2e1b84d273b01835256e53fd938de355 + name: libsqlite + run_exports: + weak: + - libsqlite >=3.51.1,<4.0a0 + sha256: 6f0e8a812e8e33a4d8b7a0e595efe28373080d27b78ee4828aa4f6649a088454 + size: 938979 + subdir: linux-64 + timestamp: 1764359444435 + version: 3.51.1 + fn: libsqlite-3.51.1-h0c1763c_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libsqlite-3.51.1-h0c1763c_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h5347b49_1 + build_number: 1 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: BSD-3-Clause + md5: 41f5c09a211985c3ce642d60721e7c3e + name: libuuid + run_exports: + weak: + - libuuid >=2.41.2,<3.0a0 + sha256: 030447cf827c471abd37092ab9714fde82b8222106f22fde94bc7a64e2704c40 + size: 40235 + subdir: linux-64 + timestamp: 1764790744114 + version: 2.41.2 + fn: libuuid-2.41.2-h5347b49_1.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libuuid-2.41.2-h5347b49_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hd590300_1 + build_number: 1 + depends: + - libgcc-ng >=12 + license: LGPL-2.1-or-later + md5: 5aa797f8787fe7a17d1b0821485b5adc + name: libxcrypt + run_exports: + weak: + - libxcrypt >=4.4.36 + sha256: 6ae68e0b86423ef188196fff6207ed0c8195dd84273cb5623b85aa08033a410c + size: 100393 + subdir: linux-64 + timestamp: 1702724383534 + version: 4.4.36 + fn: libxcrypt-4.4.36-hd590300_1.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libxcrypt-4.4.36-hd590300_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h69a702a_15 + build_number: 15 + depends: + - libgcc 15.2.0 he0feb66_15 + license: GPL-3.0-only WITH GCC-exception-3.1 + md5: 7b742943660c5173bb6a5c823021c9a0 + name: libgcc-ng + run_exports: + strong: + - libgcc + sha256: 497d8cdba0da8fa154613d1c15f585674cadc194964ed1b4fe7c2809938dc41f + size: 26834 + subdir: linux-64 + timestamp: 1764836127111 + version: 15.2.0 + fn: libgcc-ng-15.2.0-h69a702a_15.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgcc-ng-15.2.0-h69a702a_15.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb9d3cd8_2 + build_number: 2 + constrains: + - zlib 1.3.1 *_2 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: Zlib + license_family: Other + md5: edb0dca6bc32e4f4789199455a1dbeb8 + name: libzlib + run_exports: + weak: + - libzlib >=1.3.1,<2.0a0 + sha256: d4bfe88d7cb447768e31650f06257995601f89076080e76df55e3112d4e47dc4 + size: 60963 + subdir: linux-64 + timestamp: 1727963148474 + version: 1.3.1 + fn: libzlib-1.3.1-hb9d3cd8_2.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libzlib-1.3.1-hb9d3cd8_2.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h2d0b736_3 + build_number: 3 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: X11 AND BSD-3-Clause + md5: 47e340acb35de30501a76c7c799c41d7 + name: ncurses + run_exports: + weak: + - ncurses >=6.5,<7.0a0 + sha256: 3fde293232fa3fca98635e1167de6b7c7fda83caf24b9d6c91ec9eefb4f4d586 + size: 891641 + subdir: linux-64 + timestamp: 1738195959188 + version: '6.5' + fn: ncurses-6.5-h2d0b736_3.conda + url: https://conda.anaconda.org/conda-forge/linux-64/ncurses-6.5-h2d0b736_3.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h26f9b46_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - ca-certificates + - libgcc >=14 + license: Apache-2.0 + license_family: Apache + md5: 9ee58d5c534af06558933af3c845a780 + name: openssl + run_exports: + weak: + - openssl >=3.6.0,<4.0a0 + sha256: a47271202f4518a484956968335b2521409c8173e123ab381e775c358c67fe6d + size: 3165399 + subdir: linux-64 + timestamp: 1762839186699 + version: 3.6.0 + fn: openssl-3.6.0-h26f9b46_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/openssl-3.6.0-h26f9b46_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h8c095d6_2 + build_number: 2 + depends: + - libgcc >=13 + - ncurses >=6.5,<7.0a0 + license: GPL-3.0-only + license_family: GPL + md5: 283b96675859b20a825f8fa30f311446 + name: readline + run_exports: + weak: + - readline >=8.2,<9.0a0 + sha256: 2d6d0c026902561ed77cd646b5021aef2d4db22e57a5b0178dfc669231e06d2c + size: 282480 + subdir: linux-64 + timestamp: 1740379431762 + version: '8.2' + fn: readline-8.2-h8c095d6_2.conda + url: https://conda.anaconda.org/conda-forge/linux-64/readline-8.2-h8c095d6_2.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: noxft_ha0e22de_103 + build_number: 103 + constrains: + - xorg-libx11 >=1.8.12,<2.0a0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + - libzlib >=1.3.1,<2.0a0 + license: TCL + license_family: BSD + md5: 86bc20552bf46075e3d92b67f089172d + name: tk + run_exports: + weak: + - tk >=8.6.13,<8.7.0a0 + sha256: 1544760538a40bcd8ace2b1d8ebe3eb5807ac268641f8acdc18c69c5ebfeaf64 + size: 3284905 + subdir: linux-64 + timestamp: 1763054914403 + version: 8.6.13 + fn: tk-8.6.13-noxft_ha0e22de_103.conda + url: https://conda.anaconda.org/conda-forge/linux-64/tk-8.6.13-noxft_ha0e22de_103.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h78e105d_0 + build_number: 0 + depends: [] + license: LicenseRef-Public-Domain + md5: 4222072737ccff51314b5ece9c7d6f5a + name: tzdata + noarch: generic + run_exports: {} + sha256: 5aaa366385d716557e365f0a4e9c3fca43ba196872abbbe3d56bb610d131e192 + size: 122968 + subdir: noarch + timestamp: 1742727099393 + version: 2025b + fn: tzdata-2025b-h78e105d_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/tzdata-2025b-h78e105d_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhe01879c_1 + build_number: 1 + depends: + - python >=3.9 + - zipp >=3.20 + - python + license: Apache-2.0 + license_family: APACHE + md5: 63ccfdc3a3ce25b027b8767eb722fca8 + name: importlib-metadata + noarch: python + run_exports: {} + sha256: c18ab120a0613ada4391b15981d86ff777b5690ca461ea7e9e49531e8f374745 + size: 34641 + subdir: noarch + timestamp: 1747934053147 + version: 8.7.0 + fn: importlib-metadata-8.7.0-pyhe01879c_1.conda + url: https://conda.anaconda.org/conda-forge/noarch/importlib-metadata-8.7.0-pyhe01879c_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyh29332c3_1 + build_number: 1 + depends: + - python >=3.8 + - python + license: Apache-2.0 + license_family: APACHE + md5: 58335b26c38bf4a20f399384c33cbcf9 + name: packaging + noarch: python + run_exports: {} + sha256: 289861ed0c13a15d7bbb408796af4de72c2fe67e2bcb0de98f4c3fce259d7991 + size: 62477 + subdir: noarch + timestamp: 1745345660407 + version: '25.0' + fn: packaging-25.0-pyh29332c3_1.conda + url: https://conda.anaconda.org/conda-forge/noarch/packaging-25.0-pyh29332c3_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhe01879c_2 + build_number: 2 + depends: + - python >=3.9 + - python + license: MIT + license_family: MIT + md5: 30a0a26c8abccf4b7991d590fe17c699 + name: tomli + noarch: python + run_exports: {} + sha256: 040a5a05c487647c089ad5e05ad5aff5942830db2a4e656f1e300d73436436f1 + size: 21238 + subdir: noarch + timestamp: 1753796677376 + version: 2.2.1 + fn: tomli-2.2.1-pyhe01879c_2.conda + url: https://conda.anaconda.org/conda-forge/noarch/tomli-2.2.1-pyhe01879c_2.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h4440ef1_0 + build_number: 0 + depends: + - typing_extensions ==4.14.1 pyhe01879c_0 + license: PSF-2.0 + license_family: PSF + md5: 75be1a943e0a7f99fcf118309092c635 + name: typing-extensions + noarch: generic + run_exports: {} + sha256: 349951278fa8d0860ec6b61fcdc1e6f604e6fce74fabf73af2e39a37979d0223 + size: 90486 + subdir: noarch + timestamp: 1751643513473 + version: 4.14.1 + fn: typing-extensions-4.14.1-h4440ef1_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/typing-extensions-4.14.1-h4440ef1_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhe01879c_0 + build_number: 0 + depends: + - python >=3.9 + - python + license: PSF-2.0 + license_family: PSF + md5: e523f4f1e980ed7a4240d7e27e9ec81f + name: typing_extensions + noarch: python + run_exports: {} + sha256: 4f52390e331ea8b9019b87effaebc4f80c6466d09f68453f52d5cdc2a3e1194f + size: 51065 + subdir: noarch + timestamp: 1751643513473 + version: 4.14.1 + fn: typing_extensions-4.14.1-pyhe01879c_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/typing_extensions-4.14.1-pyhe01879c_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_1 + build_number: 1 + depends: + - python >=3.9 + license: MIT + license_family: MIT + md5: 75cb7132eb58d97896e173ef12ac9986 + name: wheel + noarch: python + run_exports: {} + sha256: 1b34021e815ff89a4d902d879c3bd2040bc1bd6169b32e9427497fa05c55f1ce + size: 62931 + subdir: noarch + timestamp: 1733130309598 + version: 0.45.1 + fn: wheel-0.45.1-pyhd8ed1ab_1.conda + url: https://conda.anaconda.org/conda-forge/noarch/wheel-0.45.1-pyhd8ed1ab_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb78ec9c_6 + build_number: 6 + depends: + - __glibc >=2.17,<3.0.a0 + - libzlib >=1.3.1,<2.0a0 + license: BSD-3-Clause + md5: 4a13eeac0b5c8e5b8ab496e6c4ddd829 + name: zstd + run_exports: + weak: + - zstd >=1.5.7,<1.6.0a0 + sha256: 68f0206ca6e98fea941e5717cec780ed2873ffabc0e1ed34428c061e2c6268c7 + size: 601375 + subdir: linux-64 + timestamp: 1764777111296 + version: 1.5.7 + fn: zstd-1.5.7-hb78ec9c_6.conda + url: https://conda.anaconda.org/conda-forge/linux-64/zstd-1.5.7-hb78ec9c_6.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: 2_gnu + build_number: 16 + constrains: + - openmp_impl 9999 + depends: + - _libgcc_mutex 0.1 conda_forge + - libgomp >=7.5.0 + license: BSD-3-Clause + license_family: BSD + md5: 73aaf86a425cc6e73fcf236a5a46396d + name: _openmp_mutex + run_exports: + strong: + - _openmp_mutex >=4.5 + sha256: fbe2c5e56a653bebb982eda4876a9178aedfc2b545f25d0ce9c4c0b508253d22 + size: 23621 + subdir: linux-64 + timestamp: 1650670423406 + version: '4.5' + fn: _openmp_mutex-4.5-2_gnu.tar.bz2 + url: https://conda.anaconda.org/conda-forge/linux-64/_openmp_mutex-4.5-2_gnu.tar.bz2 + channel: https://conda.anaconda.org/conda-forge/ + - build: he0feb66_15 + build_number: 15 + depends: + - __glibc >=2.17,<3.0.a0 + license: GPL-3.0-only WITH GCC-exception-3.1 + md5: a90d6983da0757f4c09bb8fcfaf34e71 + name: libgomp + run_exports: + strong: + - _openmp_mutex >=4.5 + sha256: b3c4e39be7aba6f5a8695d428362c5c918b96a281ce0a7037f1e889dfc340615 + size: 602978 + subdir: linux-64 + timestamp: 1764836011147 + version: 15.2.0 + fn: libgomp-15.2.0-he0feb66_15.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgomp-15.2.0-he0feb66_15.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: conda_forge + build_number: 0 + depends: [] + license: None + md5: d7c89558ba9fa0495403155b64376d81 + name: _libgcc_mutex + run_exports: {} + sha256: fe51de6107f9edc7aa4f786a70f4a883943bc9d39b3bb7307c04c41410990726 + size: 2562 + subdir: linux-64 + timestamp: 1578324546067 + version: '0.1' + fn: _libgcc_mutex-0.1-conda_forge.tar.bz2 + url: https://conda.anaconda.org/conda-forge/linux-64/_libgcc_mutex-0.1-conda_forge.tar.bz2 + channel: https://conda.anaconda.org/conda-forge/ + - build: hbd8a1cb_0 + build_number: 0 + depends: + - __unix + license: ISC + md5: f0991f0f84902f6b6009b4d2350a83aa + name: ca-certificates + noarch: generic + run_exports: {} + sha256: b986ba796d42c9d3265602bc038f6f5264095702dd546c14bc684e60c385e773 + size: 152432 + subdir: noarch + timestamp: 1762967197890 + version: 2025.11.12 + fn: ca-certificates-2025.11.12-hbd8a1cb_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/ca-certificates-2025.11.12-hbd8a1cb_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_0 + build_number: 0 + depends: + - python >=3.9 + license: MIT + license_family: MIT + md5: df5e78d904988eb55042c0c97446079f + name: zipp + noarch: python + run_exports: {} + sha256: 7560d21e1b021fd40b65bfb72f67945a3fcb83d78ad7ccf37b8b3165ec3b68ad + size: 22963 + subdir: noarch + timestamp: 1749421737203 + version: 3.23.0 + fn: zipp-3.23.0-pyhd8ed1ab_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/zipp-3.23.0-pyhd8ed1ab_0.conda + channel: https://conda.anaconda.org/conda-forge/ + run: + depends: + - source: python >=3.9 + - spec: python + from: host + run_export: python + constraints: [] +finalized_sources: +- url: https://pypi.org/packages/source/p/pluggy/pluggy-1.6.0.tar.gz + sha256: 7dcc130b76258d33b90f61b658791dede3486c3e6bfb003ee5c9bfb396dd22f3 +system_tools: + rattler-build: 0.53.0 +extra_meta: {} diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/recipe/variant_config.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/recipe/variant_config.yaml new file mode 100644 index 0000000000000000000000000000000000000000..6651913f6bb0b9c2f22965014faeb6020ee5e550 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/recipe/variant_config.yaml @@ -0,0 +1,2 @@ +python_min: '3.9' +target_platform: noarch diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/repodata_record.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/repodata_record.json new file mode 100644 index 0000000000000000000000000000000000000000..2d20f71c0352bf2157f40137182513203482df6b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/repodata_record.json @@ -0,0 +1,22 @@ +{ + "build": "pyhf9edf01_1", + "build_number": 1, + "build_string": "pyhf9edf01_1", + "channel": "conda-forge", + "constrains": [], + "depends": [ + "python >=3.9", + "python" + ], + "fn": "pluggy-1.6.0-pyhf9edf01_1.conda", + "license": "MIT", + "md5": "d7585b6550ad04c8c5e21097ada2888e", + "name": "pluggy", + "noarch": "python", + "sha256": "e14aafa63efa0528ca99ba568eaf506eb55a0371d12e6250aaaa61718d2eb62e", + "size": 25877, + "subdir": "noarch", + "timestamp": 1764896838, + "url": "https://conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1.conda", + "version": "1.6.0" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/tests/tests.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/tests/tests.yaml new file mode 100644 index 0000000000000000000000000000000000000000..6146ec5e2079ff08de6f5e9ecb2e49304fb049c4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/info/tests/tests.yaml @@ -0,0 +1,4 @@ +- python: + imports: + - pluggy + python_version: 3.9.* diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/INSTALLER b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/INSTALLER new file mode 100644 index 0000000000000000000000000000000000000000..a34a7e56db35cc4c85bfa166244b3d63a6a240d4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/INSTALLER @@ -0,0 +1 @@ +conda diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/METADATA b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/METADATA new file mode 100644 index 0000000000000000000000000000000000000000..12345f88ebe873247f9298feca3e469e7e8af87f --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/METADATA @@ -0,0 +1,152 @@ +Metadata-Version: 2.4 +Name: pluggy +Version: 1.6.0 +Summary: plugin and hook calling mechanisms for python +Author-email: Holger Krekel +License: MIT +Classifier: Development Status :: 6 - Mature +Classifier: Intended Audience :: Developers +Classifier: License :: OSI Approved :: MIT License +Classifier: Operating System :: POSIX +Classifier: Operating System :: Microsoft :: Windows +Classifier: Operating System :: MacOS :: MacOS X +Classifier: Topic :: Software Development :: Testing +Classifier: Topic :: Software Development :: Libraries +Classifier: Topic :: Utilities +Classifier: Programming Language :: Python :: Implementation :: CPython +Classifier: Programming Language :: Python :: Implementation :: PyPy +Classifier: Programming Language :: Python :: 3 +Classifier: Programming Language :: Python :: 3 :: Only +Classifier: Programming Language :: Python :: 3.9 +Classifier: Programming Language :: Python :: 3.10 +Classifier: Programming Language :: Python :: 3.11 +Classifier: Programming Language :: Python :: 3.12 +Classifier: Programming Language :: Python :: 3.13 +Requires-Python: >=3.9 +Description-Content-Type: text/x-rst +License-File: LICENSE +Provides-Extra: dev +Requires-Dist: pre-commit; extra == "dev" +Requires-Dist: tox; extra == "dev" +Provides-Extra: testing +Requires-Dist: pytest; extra == "testing" +Requires-Dist: pytest-benchmark; extra == "testing" +Requires-Dist: coverage; extra == "testing" +Dynamic: license-file + +==================================================== +pluggy - A minimalist production ready plugin system +==================================================== + +|pypi| |conda-forge| |versions| |github-actions| |gitter| |black| |codecov| + +This is the core framework used by the `pytest`_, `tox`_, and `devpi`_ projects. + +Please `read the docs`_ to learn more! + +A definitive example +==================== +.. code-block:: python + + import pluggy + + hookspec = pluggy.HookspecMarker("myproject") + hookimpl = pluggy.HookimplMarker("myproject") + + + class MySpec: + """A hook specification namespace.""" + + @hookspec + def myhook(self, arg1, arg2): + """My special little hook that you can customize.""" + + + class Plugin_1: + """A hook implementation namespace.""" + + @hookimpl + def myhook(self, arg1, arg2): + print("inside Plugin_1.myhook()") + return arg1 + arg2 + + + class Plugin_2: + """A 2nd hook implementation namespace.""" + + @hookimpl + def myhook(self, arg1, arg2): + print("inside Plugin_2.myhook()") + return arg1 - arg2 + + + # create a manager and add the spec + pm = pluggy.PluginManager("myproject") + pm.add_hookspecs(MySpec) + + # register plugins + pm.register(Plugin_1()) + pm.register(Plugin_2()) + + # call our ``myhook`` hook + results = pm.hook.myhook(arg1=1, arg2=2) + print(results) + + +Running this directly gets us:: + + $ python docs/examples/toy-example.py + inside Plugin_2.myhook() + inside Plugin_1.myhook() + [-1, 3] + + +.. badges + +.. |pypi| image:: https://img.shields.io/pypi/v/pluggy.svg + :target: https://pypi.org/pypi/pluggy + +.. |versions| image:: https://img.shields.io/pypi/pyversions/pluggy.svg + :target: https://pypi.org/pypi/pluggy + +.. |github-actions| image:: https://github.com/pytest-dev/pluggy/workflows/main/badge.svg + :target: https://github.com/pytest-dev/pluggy/actions + +.. |conda-forge| image:: https://img.shields.io/conda/vn/conda-forge/pluggy.svg + :target: https://anaconda.org/conda-forge/pytest + +.. |gitter| image:: https://badges.gitter.im/pytest-dev/pluggy.svg + :alt: Join the chat at https://gitter.im/pytest-dev/pluggy + :target: https://gitter.im/pytest-dev/pluggy?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge + +.. |black| image:: https://img.shields.io/badge/code%20style-black-000000.svg + :target: https://github.com/ambv/black + +.. |codecov| image:: https://codecov.io/gh/pytest-dev/pluggy/branch/master/graph/badge.svg + :target: https://codecov.io/gh/pytest-dev/pluggy + :alt: Code coverage Status + +.. links +.. _pytest: + http://pytest.org +.. _tox: + https://tox.readthedocs.org +.. _devpi: + http://doc.devpi.net +.. _read the docs: + https://pluggy.readthedocs.io/en/latest/ + + +Support pluggy +-------------- + +`Open Collective`_ is an online funding platform for open and transparent communities. +It provides tools to raise money and share your finances in full transparency. + +It is the platform of choice for individuals and companies that want to make one-time or +monthly donations directly to the project. + +``pluggy`` is part of the ``pytest-dev`` project, see more details in the `pytest collective`_. + +.. _Open Collective: https://opencollective.com +.. _pytest collective: https://opencollective.com/pytest diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/RECORD b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/RECORD new file mode 100644 index 0000000000000000000000000000000000000000..41de6722551ac6c5e422c8d17f10dfb1b5fa0710 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/RECORD @@ -0,0 +1,25 @@ +pluggy-1.6.0.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +pluggy-1.6.0.dist-info/METADATA,sha256=dDjDXuJaCV63QW-EtGHC10Qlxec0rVTDkSRTxlJE4Bw,4811 +pluggy-1.6.0.dist-info/RECORD,, +pluggy-1.6.0.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pluggy-1.6.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91 +pluggy-1.6.0.dist-info/direct_url.json,sha256=thYBqNdkrnwq0WR6W4I0TvlQnuBUX7LOyRxipkgPtcc,117 +pluggy-1.6.0.dist-info/licenses/LICENSE,sha256=1rZebCE6XQtXeRHTTW5ZSbn1nXbCOMUHGi8_wWz7JgY,1110 +pluggy-1.6.0.dist-info/top_level.txt,sha256=xKSCRhai-v9MckvMuWqNz16c1tbsmOggoMSwTgcpYHE,7 +pluggy/__init__.py,sha256=D6dp1gmEDjtDp8hAwQc-qrgaulnL4iltrqkLDd-g9tg,811 +pluggy/__pycache__/__init__.cpython-39.pyc,, +pluggy/__pycache__/_callers.cpython-39.pyc,, +pluggy/__pycache__/_hooks.cpython-39.pyc,, +pluggy/__pycache__/_manager.cpython-39.pyc,, +pluggy/__pycache__/_result.cpython-39.pyc,, +pluggy/__pycache__/_tracing.cpython-39.pyc,, +pluggy/__pycache__/_version.cpython-39.pyc,, +pluggy/__pycache__/_warnings.cpython-39.pyc,, +pluggy/_callers.py,sha256=gEZllGaSYVssZ2UmpNfmYC0bdVgh2jYbAFeYKvuRMjY,5991 +pluggy/_hooks.py,sha256=E6f3nYcI6dbEuO0Gmy61ozgGU_59_e69kC08a06EBuo,25218 +pluggy/_manager.py,sha256=K4Ip_pkEjvT2oOIfQPp8CwAWoXVnENgQRcy9tlGii0o,20219 +pluggy/_result.py,sha256=3Xfy7DrjXbYb7puRquyY2VbidIWNq6Pp7QnuElMdj8Q,3098 +pluggy/_tracing.py,sha256=nXd2BCmDgf8jJxV-HO3PqxR-WV53eWnF8B4AF1nJGgo,2073 +pluggy/_version.py,sha256=QuifT9FwIKV3Bt8At2-CvH3sl5xacVDBQsWlFAqVjbg,704 +pluggy/_warnings.py,sha256=td0AvZBpfamriCC3OqsLwxMh-SzAMjfjmc58T5vP3lw,828 +pluggy/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/REQUESTED b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/REQUESTED new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/WHEEL b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/WHEEL new file mode 100644 index 0000000000000000000000000000000000000000..e7fa31b6f3f78deb1022c1f7927f07d4d16da822 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/WHEEL @@ -0,0 +1,5 @@ +Wheel-Version: 1.0 +Generator: setuptools (80.9.0) +Root-Is-Purelib: true +Tag: py3-none-any + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/direct_url.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/direct_url.json new file mode 100644 index 0000000000000000000000000000000000000000..03175f6a323ce22e81fd5b6a382210b546307299 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/direct_url.json @@ -0,0 +1 @@ +{"dir_info": {}, "url": "file:///home/conda/feedstock_root/build_artifacts/bld/rattler-build_pluggy_1764896838/work"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..85f4dd63d2da8e31d7e84d5180f016fdfe315c2c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/licenses/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015 holger krekel (rather uses bitbucket/hpk42) + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/top_level.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/top_level.txt new file mode 100644 index 0000000000000000000000000000000000000000..11bdb5c1f5fcdd91af5d587c352039cb8476af49 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy-1.6.0.dist-info/top_level.txt @@ -0,0 +1 @@ +pluggy diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..8a651f499d9da137fd61a1aefcd8a031a86372c2 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/__init__.py @@ -0,0 +1,30 @@ +__all__ = [ + "__version__", + "PluginManager", + "PluginValidationError", + "HookCaller", + "HookCallError", + "HookspecOpts", + "HookimplOpts", + "HookImpl", + "HookRelay", + "HookspecMarker", + "HookimplMarker", + "Result", + "PluggyWarning", + "PluggyTeardownRaisedWarning", +] +from ._hooks import HookCaller +from ._hooks import HookImpl +from ._hooks import HookimplMarker +from ._hooks import HookimplOpts +from ._hooks import HookRelay +from ._hooks import HookspecMarker +from ._hooks import HookspecOpts +from ._manager import PluginManager +from ._manager import PluginValidationError +from ._result import HookCallError +from ._result import Result +from ._version import version as __version__ +from ._warnings import PluggyTeardownRaisedWarning +from ._warnings import PluggyWarning diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_callers.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_callers.py new file mode 100644 index 0000000000000000000000000000000000000000..472d5dd05be442ad0dbe8ea5b8ca98b86e569fdc --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_callers.py @@ -0,0 +1,169 @@ +""" +Call loop machinery +""" + +from __future__ import annotations + +from collections.abc import Generator +from collections.abc import Mapping +from collections.abc import Sequence +from typing import cast +from typing import NoReturn +import warnings + +from ._hooks import HookImpl +from ._result import HookCallError +from ._result import Result +from ._warnings import PluggyTeardownRaisedWarning + + +# Need to distinguish between old- and new-style hook wrappers. +# Wrapping with a tuple is the fastest type-safe way I found to do it. +Teardown = Generator[None, object, object] + + +def run_old_style_hookwrapper( + hook_impl: HookImpl, hook_name: str, args: Sequence[object] +) -> Teardown: + """ + backward compatibility wrapper to run a old style hookwrapper as a wrapper + """ + + teardown: Teardown = cast(Teardown, hook_impl.function(*args)) + try: + next(teardown) + except StopIteration: + _raise_wrapfail(teardown, "did not yield") + try: + res = yield + result = Result(res, None) + except BaseException as exc: + result = Result(None, exc) + try: + teardown.send(result) + except StopIteration: + pass + except BaseException as e: + _warn_teardown_exception(hook_name, hook_impl, e) + raise + else: + _raise_wrapfail(teardown, "has second yield") + finally: + teardown.close() + return result.get_result() + + +def _raise_wrapfail( + wrap_controller: Generator[None, object, object], + msg: str, +) -> NoReturn: + co = wrap_controller.gi_code # type: ignore[attr-defined] + raise RuntimeError( + f"wrap_controller at {co.co_name!r} {co.co_filename}:{co.co_firstlineno} {msg}" + ) + + +def _warn_teardown_exception( + hook_name: str, hook_impl: HookImpl, e: BaseException +) -> None: + msg = "A plugin raised an exception during an old-style hookwrapper teardown.\n" + msg += f"Plugin: {hook_impl.plugin_name}, Hook: {hook_name}\n" + msg += f"{type(e).__name__}: {e}\n" + msg += "For more information see https://pluggy.readthedocs.io/en/stable/api_reference.html#pluggy.PluggyTeardownRaisedWarning" # noqa: E501 + warnings.warn(PluggyTeardownRaisedWarning(msg), stacklevel=6) + + +def _multicall( + hook_name: str, + hook_impls: Sequence[HookImpl], + caller_kwargs: Mapping[str, object], + firstresult: bool, +) -> object | list[object]: + """Execute a call into multiple python functions/methods and return the + result(s). + + ``caller_kwargs`` comes from HookCaller.__call__(). + """ + __tracebackhide__ = True + results: list[object] = [] + exception = None + try: # run impl and wrapper setup functions in a loop + teardowns: list[Teardown] = [] + try: + for hook_impl in reversed(hook_impls): + try: + args = [caller_kwargs[argname] for argname in hook_impl.argnames] + except KeyError as e: + # coverage bug - this is tested + for argname in hook_impl.argnames: # pragma: no cover + if argname not in caller_kwargs: + raise HookCallError( + f"hook call must provide argument {argname!r}" + ) from e + + if hook_impl.hookwrapper: + function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) + + next(function_gen) # first yield + teardowns.append(function_gen) + + elif hook_impl.wrapper: + try: + # If this cast is not valid, a type error is raised below, + # which is the desired response. + res = hook_impl.function(*args) + function_gen = cast(Generator[None, object, object], res) + next(function_gen) # first yield + teardowns.append(function_gen) + except StopIteration: + _raise_wrapfail(function_gen, "did not yield") + else: + res = hook_impl.function(*args) + if res is not None: + results.append(res) + if firstresult: # halt further impl calls + break + except BaseException as exc: + exception = exc + finally: + if firstresult: # first result hooks return a single value + result = results[0] if results else None + else: + result = results + + # run all wrapper post-yield blocks + for teardown in reversed(teardowns): + try: + if exception is not None: + try: + teardown.throw(exception) + except RuntimeError as re: + # StopIteration from generator causes RuntimeError + # even for coroutine usage - see #544 + if ( + isinstance(exception, StopIteration) + and re.__cause__ is exception + ): + teardown.close() + continue + else: + raise + else: + teardown.send(result) + # Following is unreachable for a well behaved hook wrapper. + # Try to force finalizers otherwise postponed till GC action. + # Note: close() may raise if generator handles GeneratorExit. + teardown.close() + except StopIteration as si: + result = si.value + exception = None + continue + except BaseException as e: + exception = e + continue + _raise_wrapfail(teardown, "has second yield") + + if exception is not None: + raise exception + else: + return result diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_hooks.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_hooks.py new file mode 100644 index 0000000000000000000000000000000000000000..97fef0d75fc2c8c3fee866ce8d2cc19f9ab54c7c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_hooks.py @@ -0,0 +1,714 @@ +""" +Internal hook annotation, representation and calling machinery. +""" + +from __future__ import annotations + +from collections.abc import Generator +from collections.abc import Mapping +from collections.abc import Sequence +from collections.abc import Set +import inspect +import sys +from types import ModuleType +from typing import Any +from typing import Callable +from typing import Final +from typing import final +from typing import Optional +from typing import overload +from typing import TYPE_CHECKING +from typing import TypedDict +from typing import TypeVar +from typing import Union +import warnings + +from ._result import Result + + +_T = TypeVar("_T") +_F = TypeVar("_F", bound=Callable[..., object]) +_Namespace = Union[ModuleType, type] +_Plugin = object +_HookExec = Callable[ + [str, Sequence["HookImpl"], Mapping[str, object], bool], + Union[object, list[object]], +] +_HookImplFunction = Callable[..., Union[_T, Generator[None, Result[_T], None]]] + + +class HookspecOpts(TypedDict): + """Options for a hook specification.""" + + #: Whether the hook is :ref:`first result only `. + firstresult: bool + #: Whether the hook is :ref:`historic `. + historic: bool + #: Whether the hook :ref:`warns when implemented `. + warn_on_impl: Warning | None + #: Whether the hook warns when :ref:`certain arguments are requested + #: `. + #: + #: .. versionadded:: 1.5 + warn_on_impl_args: Mapping[str, Warning] | None + + +class HookimplOpts(TypedDict): + """Options for a hook implementation.""" + + #: Whether the hook implementation is a :ref:`wrapper `. + wrapper: bool + #: Whether the hook implementation is an :ref:`old-style wrapper + #: `. + hookwrapper: bool + #: Whether validation against a hook specification is :ref:`optional + #: `. + optionalhook: bool + #: Whether to try to order this hook implementation :ref:`first + #: `. + tryfirst: bool + #: Whether to try to order this hook implementation :ref:`last + #: `. + trylast: bool + #: The name of the hook specification to match, see :ref:`specname`. + specname: str | None + + +@final +class HookspecMarker: + """Decorator for marking functions as hook specifications. + + Instantiate it with a project_name to get a decorator. + Calling :meth:`PluginManager.add_hookspecs` later will discover all marked + functions if the :class:`PluginManager` uses the same project name. + """ + + __slots__ = ("project_name",) + + def __init__(self, project_name: str) -> None: + self.project_name: Final = project_name + + @overload + def __call__( + self, + function: _F, + firstresult: bool = False, + historic: bool = False, + warn_on_impl: Warning | None = None, + warn_on_impl_args: Mapping[str, Warning] | None = None, + ) -> _F: ... + + @overload # noqa: F811 + def __call__( # noqa: F811 + self, + function: None = ..., + firstresult: bool = ..., + historic: bool = ..., + warn_on_impl: Warning | None = ..., + warn_on_impl_args: Mapping[str, Warning] | None = ..., + ) -> Callable[[_F], _F]: ... + + def __call__( # noqa: F811 + self, + function: _F | None = None, + firstresult: bool = False, + historic: bool = False, + warn_on_impl: Warning | None = None, + warn_on_impl_args: Mapping[str, Warning] | None = None, + ) -> _F | Callable[[_F], _F]: + """If passed a function, directly sets attributes on the function + which will make it discoverable to :meth:`PluginManager.add_hookspecs`. + + If passed no function, returns a decorator which can be applied to a + function later using the attributes supplied. + + :param firstresult: + If ``True``, the 1:N hook call (N being the number of registered + hook implementation functions) will stop at I<=N when the I'th + function returns a non-``None`` result. See :ref:`firstresult`. + + :param historic: + If ``True``, every call to the hook will be memorized and replayed + on plugins registered after the call was made. See :ref:`historic`. + + :param warn_on_impl: + If given, every implementation of this hook will trigger the given + warning. See :ref:`warn_on_impl`. + + :param warn_on_impl_args: + If given, every implementation of this hook which requests one of + the arguments in the dict will trigger the corresponding warning. + See :ref:`warn_on_impl`. + + .. versionadded:: 1.5 + """ + + def setattr_hookspec_opts(func: _F) -> _F: + if historic and firstresult: + raise ValueError("cannot have a historic firstresult hook") + opts: HookspecOpts = { + "firstresult": firstresult, + "historic": historic, + "warn_on_impl": warn_on_impl, + "warn_on_impl_args": warn_on_impl_args, + } + setattr(func, self.project_name + "_spec", opts) + return func + + if function is not None: + return setattr_hookspec_opts(function) + else: + return setattr_hookspec_opts + + +@final +class HookimplMarker: + """Decorator for marking functions as hook implementations. + + Instantiate it with a ``project_name`` to get a decorator. + Calling :meth:`PluginManager.register` later will discover all marked + functions if the :class:`PluginManager` uses the same project name. + """ + + __slots__ = ("project_name",) + + def __init__(self, project_name: str) -> None: + self.project_name: Final = project_name + + @overload + def __call__( + self, + function: _F, + hookwrapper: bool = ..., + optionalhook: bool = ..., + tryfirst: bool = ..., + trylast: bool = ..., + specname: str | None = ..., + wrapper: bool = ..., + ) -> _F: ... + + @overload # noqa: F811 + def __call__( # noqa: F811 + self, + function: None = ..., + hookwrapper: bool = ..., + optionalhook: bool = ..., + tryfirst: bool = ..., + trylast: bool = ..., + specname: str | None = ..., + wrapper: bool = ..., + ) -> Callable[[_F], _F]: ... + + def __call__( # noqa: F811 + self, + function: _F | None = None, + hookwrapper: bool = False, + optionalhook: bool = False, + tryfirst: bool = False, + trylast: bool = False, + specname: str | None = None, + wrapper: bool = False, + ) -> _F | Callable[[_F], _F]: + """If passed a function, directly sets attributes on the function + which will make it discoverable to :meth:`PluginManager.register`. + + If passed no function, returns a decorator which can be applied to a + function later using the attributes supplied. + + :param optionalhook: + If ``True``, a missing matching hook specification will not result + in an error (by default it is an error if no matching spec is + found). See :ref:`optionalhook`. + + :param tryfirst: + If ``True``, this hook implementation will run as early as possible + in the chain of N hook implementations for a specification. See + :ref:`callorder`. + + :param trylast: + If ``True``, this hook implementation will run as late as possible + in the chain of N hook implementations for a specification. See + :ref:`callorder`. + + :param wrapper: + If ``True`` ("new-style hook wrapper"), the hook implementation + needs to execute exactly one ``yield``. The code before the + ``yield`` is run early before any non-hook-wrapper function is run. + The code after the ``yield`` is run after all non-hook-wrapper + functions have run. The ``yield`` receives the result value of the + inner calls, or raises the exception of inner calls (including + earlier hook wrapper calls). The return value of the function + becomes the return value of the hook, and a raised exception becomes + the exception of the hook. See :ref:`hookwrapper`. + + :param hookwrapper: + If ``True`` ("old-style hook wrapper"), the hook implementation + needs to execute exactly one ``yield``. The code before the + ``yield`` is run early before any non-hook-wrapper function is run. + The code after the ``yield`` is run after all non-hook-wrapper + function have run The ``yield`` receives a :class:`Result` object + representing the exception or result outcome of the inner calls + (including earlier hook wrapper calls). This option is mutually + exclusive with ``wrapper``. See :ref:`old_style_hookwrapper`. + + :param specname: + If provided, the given name will be used instead of the function + name when matching this hook implementation to a hook specification + during registration. See :ref:`specname`. + + .. versionadded:: 1.2.0 + The ``wrapper`` parameter. + """ + + def setattr_hookimpl_opts(func: _F) -> _F: + opts: HookimplOpts = { + "wrapper": wrapper, + "hookwrapper": hookwrapper, + "optionalhook": optionalhook, + "tryfirst": tryfirst, + "trylast": trylast, + "specname": specname, + } + setattr(func, self.project_name + "_impl", opts) + return func + + if function is None: + return setattr_hookimpl_opts + else: + return setattr_hookimpl_opts(function) + + +def normalize_hookimpl_opts(opts: HookimplOpts) -> None: + opts.setdefault("tryfirst", False) + opts.setdefault("trylast", False) + opts.setdefault("wrapper", False) + opts.setdefault("hookwrapper", False) + opts.setdefault("optionalhook", False) + opts.setdefault("specname", None) + + +_PYPY = hasattr(sys, "pypy_version_info") + + +def varnames(func: object) -> tuple[tuple[str, ...], tuple[str, ...]]: + """Return tuple of positional and keywrord argument names for a function, + method, class or callable. + + In case of a class, its ``__init__`` method is considered. + For methods the ``self`` parameter is not included. + """ + if inspect.isclass(func): + try: + func = func.__init__ + except AttributeError: # pragma: no cover - pypy special case + return (), () + elif not inspect.isroutine(func): # callable object? + try: + func = getattr(func, "__call__", func) + except Exception: # pragma: no cover - pypy special case + return (), () + + try: + # func MUST be a function or method here or we won't parse any args. + sig = inspect.signature( + func.__func__ if inspect.ismethod(func) else func # type:ignore[arg-type] + ) + except TypeError: # pragma: no cover + return (), () + + _valid_param_kinds = ( + inspect.Parameter.POSITIONAL_ONLY, + inspect.Parameter.POSITIONAL_OR_KEYWORD, + ) + _valid_params = { + name: param + for name, param in sig.parameters.items() + if param.kind in _valid_param_kinds + } + args = tuple(_valid_params) + defaults = ( + tuple( + param.default + for param in _valid_params.values() + if param.default is not param.empty + ) + or None + ) + + if defaults: + index = -len(defaults) + args, kwargs = args[:index], tuple(args[index:]) + else: + kwargs = () + + # strip any implicit instance arg + # pypy3 uses "obj" instead of "self" for default dunder methods + if not _PYPY: + implicit_names: tuple[str, ...] = ("self",) + else: # pragma: no cover + implicit_names = ("self", "obj") + if args: + qualname: str = getattr(func, "__qualname__", "") + if inspect.ismethod(func) or ("." in qualname and args[0] in implicit_names): + args = args[1:] + + return args, kwargs + + +@final +class HookRelay: + """Hook holder object for performing 1:N hook calls where N is the number + of registered plugins.""" + + __slots__ = ("__dict__",) + + def __init__(self) -> None: + """:meta private:""" + + if TYPE_CHECKING: + + def __getattr__(self, name: str) -> HookCaller: ... + + +# Historical name (pluggy<=1.2), kept for backward compatibility. +_HookRelay = HookRelay + + +_CallHistory = list[tuple[Mapping[str, object], Optional[Callable[[Any], None]]]] + + +class HookCaller: + """A caller of all registered implementations of a hook specification.""" + + __slots__ = ( + "name", + "spec", + "_hookexec", + "_hookimpls", + "_call_history", + ) + + def __init__( + self, + name: str, + hook_execute: _HookExec, + specmodule_or_class: _Namespace | None = None, + spec_opts: HookspecOpts | None = None, + ) -> None: + """:meta private:""" + #: Name of the hook getting called. + self.name: Final = name + self._hookexec: Final = hook_execute + # The hookimpls list. The caller iterates it *in reverse*. Format: + # 1. trylast nonwrappers + # 2. nonwrappers + # 3. tryfirst nonwrappers + # 4. trylast wrappers + # 5. wrappers + # 6. tryfirst wrappers + self._hookimpls: Final[list[HookImpl]] = [] + self._call_history: _CallHistory | None = None + # TODO: Document, or make private. + self.spec: HookSpec | None = None + if specmodule_or_class is not None: + assert spec_opts is not None + self.set_specification(specmodule_or_class, spec_opts) + + # TODO: Document, or make private. + def has_spec(self) -> bool: + return self.spec is not None + + # TODO: Document, or make private. + def set_specification( + self, + specmodule_or_class: _Namespace, + spec_opts: HookspecOpts, + ) -> None: + if self.spec is not None: + raise ValueError( + f"Hook {self.spec.name!r} is already registered " + f"within namespace {self.spec.namespace}" + ) + self.spec = HookSpec(specmodule_or_class, self.name, spec_opts) + if spec_opts.get("historic"): + self._call_history = [] + + def is_historic(self) -> bool: + """Whether this caller is :ref:`historic `.""" + return self._call_history is not None + + def _remove_plugin(self, plugin: _Plugin) -> None: + for i, method in enumerate(self._hookimpls): + if method.plugin == plugin: + del self._hookimpls[i] + return + raise ValueError(f"plugin {plugin!r} not found") + + def get_hookimpls(self) -> list[HookImpl]: + """Get all registered hook implementations for this hook.""" + return self._hookimpls.copy() + + def _add_hookimpl(self, hookimpl: HookImpl) -> None: + """Add an implementation to the callback chain.""" + for i, method in enumerate(self._hookimpls): + if method.hookwrapper or method.wrapper: + splitpoint = i + break + else: + splitpoint = len(self._hookimpls) + if hookimpl.hookwrapper or hookimpl.wrapper: + start, end = splitpoint, len(self._hookimpls) + else: + start, end = 0, splitpoint + + if hookimpl.trylast: + self._hookimpls.insert(start, hookimpl) + elif hookimpl.tryfirst: + self._hookimpls.insert(end, hookimpl) + else: + # find last non-tryfirst method + i = end - 1 + while i >= start and self._hookimpls[i].tryfirst: + i -= 1 + self._hookimpls.insert(i + 1, hookimpl) + + def __repr__(self) -> str: + return f"" + + def _verify_all_args_are_provided(self, kwargs: Mapping[str, object]) -> None: + # This is written to avoid expensive operations when not needed. + if self.spec: + for argname in self.spec.argnames: + if argname not in kwargs: + notincall = ", ".join( + repr(argname) + for argname in self.spec.argnames + # Avoid self.spec.argnames - kwargs.keys() + # it doesn't preserve order. + if argname not in kwargs.keys() + ) + warnings.warn( + f"Argument(s) {notincall} which are declared in the hookspec " + "cannot be found in this hook call", + stacklevel=2, + ) + break + + def __call__(self, **kwargs: object) -> Any: + """Call the hook. + + Only accepts keyword arguments, which should match the hook + specification. + + Returns the result(s) of calling all registered plugins, see + :ref:`calling`. + """ + assert not self.is_historic(), ( + "Cannot directly call a historic hook - use call_historic instead." + ) + self._verify_all_args_are_provided(kwargs) + firstresult = self.spec.opts.get("firstresult", False) if self.spec else False + # Copy because plugins may register other plugins during iteration (#438). + return self._hookexec(self.name, self._hookimpls.copy(), kwargs, firstresult) + + def call_historic( + self, + result_callback: Callable[[Any], None] | None = None, + kwargs: Mapping[str, object] | None = None, + ) -> None: + """Call the hook with given ``kwargs`` for all registered plugins and + for all plugins which will be registered afterwards, see + :ref:`historic`. + + :param result_callback: + If provided, will be called for each non-``None`` result obtained + from a hook implementation. + """ + assert self._call_history is not None + kwargs = kwargs or {} + self._verify_all_args_are_provided(kwargs) + self._call_history.append((kwargs, result_callback)) + # Historizing hooks don't return results. + # Remember firstresult isn't compatible with historic. + # Copy because plugins may register other plugins during iteration (#438). + res = self._hookexec(self.name, self._hookimpls.copy(), kwargs, False) + if result_callback is None: + return + if isinstance(res, list): + for x in res: + result_callback(x) + + def call_extra( + self, methods: Sequence[Callable[..., object]], kwargs: Mapping[str, object] + ) -> Any: + """Call the hook with some additional temporarily participating + methods using the specified ``kwargs`` as call parameters, see + :ref:`call_extra`.""" + assert not self.is_historic(), ( + "Cannot directly call a historic hook - use call_historic instead." + ) + self._verify_all_args_are_provided(kwargs) + opts: HookimplOpts = { + "wrapper": False, + "hookwrapper": False, + "optionalhook": False, + "trylast": False, + "tryfirst": False, + "specname": None, + } + hookimpls = self._hookimpls.copy() + for method in methods: + hookimpl = HookImpl(None, "", method, opts) + # Find last non-tryfirst nonwrapper method. + i = len(hookimpls) - 1 + while i >= 0 and ( + # Skip wrappers. + (hookimpls[i].hookwrapper or hookimpls[i].wrapper) + # Skip tryfirst nonwrappers. + or hookimpls[i].tryfirst + ): + i -= 1 + hookimpls.insert(i + 1, hookimpl) + firstresult = self.spec.opts.get("firstresult", False) if self.spec else False + return self._hookexec(self.name, hookimpls, kwargs, firstresult) + + def _maybe_apply_history(self, method: HookImpl) -> None: + """Apply call history to a new hookimpl if it is marked as historic.""" + if self.is_historic(): + assert self._call_history is not None + for kwargs, result_callback in self._call_history: + res = self._hookexec(self.name, [method], kwargs, False) + if res and result_callback is not None: + # XXX: remember firstresult isn't compat with historic + assert isinstance(res, list) + result_callback(res[0]) + + +# Historical name (pluggy<=1.2), kept for backward compatibility. +_HookCaller = HookCaller + + +class _SubsetHookCaller(HookCaller): + """A proxy to another HookCaller which manages calls to all registered + plugins except the ones from remove_plugins.""" + + # This class is unusual: in inhertits from `HookCaller` so all of + # the *code* runs in the class, but it delegates all underlying *data* + # to the original HookCaller. + # `subset_hook_caller` used to be implemented by creating a full-fledged + # HookCaller, copying all hookimpls from the original. This had problems + # with memory leaks (#346) and historic calls (#347), which make a proxy + # approach better. + # An alternative implementation is to use a `_getattr__`/`__getattribute__` + # proxy, however that adds more overhead and is more tricky to implement. + + __slots__ = ( + "_orig", + "_remove_plugins", + ) + + def __init__(self, orig: HookCaller, remove_plugins: Set[_Plugin]) -> None: + self._orig = orig + self._remove_plugins = remove_plugins + self.name = orig.name # type: ignore[misc] + self._hookexec = orig._hookexec # type: ignore[misc] + + @property # type: ignore[misc] + def _hookimpls(self) -> list[HookImpl]: + return [ + impl + for impl in self._orig._hookimpls + if impl.plugin not in self._remove_plugins + ] + + @property + def spec(self) -> HookSpec | None: # type: ignore[override] + return self._orig.spec + + @property + def _call_history(self) -> _CallHistory | None: # type: ignore[override] + return self._orig._call_history + + def __repr__(self) -> str: + return f"<_SubsetHookCaller {self.name!r}>" + + +@final +class HookImpl: + """A hook implementation in a :class:`HookCaller`.""" + + __slots__ = ( + "function", + "argnames", + "kwargnames", + "plugin", + "opts", + "plugin_name", + "wrapper", + "hookwrapper", + "optionalhook", + "tryfirst", + "trylast", + ) + + def __init__( + self, + plugin: _Plugin, + plugin_name: str, + function: _HookImplFunction[object], + hook_impl_opts: HookimplOpts, + ) -> None: + """:meta private:""" + #: The hook implementation function. + self.function: Final = function + argnames, kwargnames = varnames(self.function) + #: The positional parameter names of ``function```. + self.argnames: Final = argnames + #: The keyword parameter names of ``function```. + self.kwargnames: Final = kwargnames + #: The plugin which defined this hook implementation. + self.plugin: Final = plugin + #: The :class:`HookimplOpts` used to configure this hook implementation. + self.opts: Final = hook_impl_opts + #: The name of the plugin which defined this hook implementation. + self.plugin_name: Final = plugin_name + #: Whether the hook implementation is a :ref:`wrapper `. + self.wrapper: Final = hook_impl_opts["wrapper"] + #: Whether the hook implementation is an :ref:`old-style wrapper + #: `. + self.hookwrapper: Final = hook_impl_opts["hookwrapper"] + #: Whether validation against a hook specification is :ref:`optional + #: `. + self.optionalhook: Final = hook_impl_opts["optionalhook"] + #: Whether to try to order this hook implementation :ref:`first + #: `. + self.tryfirst: Final = hook_impl_opts["tryfirst"] + #: Whether to try to order this hook implementation :ref:`last + #: `. + self.trylast: Final = hook_impl_opts["trylast"] + + def __repr__(self) -> str: + return f"" + + +@final +class HookSpec: + __slots__ = ( + "namespace", + "function", + "name", + "argnames", + "kwargnames", + "opts", + "warn_on_impl", + "warn_on_impl_args", + ) + + def __init__(self, namespace: _Namespace, name: str, opts: HookspecOpts) -> None: + self.namespace = namespace + self.function: Callable[..., object] = getattr(namespace, name) + self.name = name + self.argnames, self.kwargnames = varnames(self.function) + self.opts = opts + self.warn_on_impl = opts.get("warn_on_impl") + self.warn_on_impl_args = opts.get("warn_on_impl_args") diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_manager.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_manager.py new file mode 100644 index 0000000000000000000000000000000000000000..ff1e3ce6e300eaed456bf67cf61aa4d15fceeb1f --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_manager.py @@ -0,0 +1,523 @@ +from __future__ import annotations + +from collections.abc import Iterable +from collections.abc import Mapping +from collections.abc import Sequence +import inspect +import types +from typing import Any +from typing import Callable +from typing import cast +from typing import Final +from typing import TYPE_CHECKING +import warnings + +from . import _tracing +from ._callers import _multicall +from ._hooks import _HookImplFunction +from ._hooks import _Namespace +from ._hooks import _Plugin +from ._hooks import _SubsetHookCaller +from ._hooks import HookCaller +from ._hooks import HookImpl +from ._hooks import HookimplOpts +from ._hooks import HookRelay +from ._hooks import HookspecOpts +from ._hooks import normalize_hookimpl_opts +from ._result import Result + + +if TYPE_CHECKING: + # importtlib.metadata import is slow, defer it. + import importlib.metadata + + +_BeforeTrace = Callable[[str, Sequence[HookImpl], Mapping[str, Any]], None] +_AfterTrace = Callable[[Result[Any], str, Sequence[HookImpl], Mapping[str, Any]], None] + + +def _warn_for_function(warning: Warning, function: Callable[..., object]) -> None: + func = cast(types.FunctionType, function) + warnings.warn_explicit( + warning, + type(warning), + lineno=func.__code__.co_firstlineno, + filename=func.__code__.co_filename, + ) + + +class PluginValidationError(Exception): + """Plugin failed validation. + + :param plugin: The plugin which failed validation. + :param message: Error message. + """ + + def __init__(self, plugin: _Plugin, message: str) -> None: + super().__init__(message) + #: The plugin which failed validation. + self.plugin = plugin + + +class DistFacade: + """Emulate a pkg_resources Distribution""" + + def __init__(self, dist: importlib.metadata.Distribution) -> None: + self._dist = dist + + @property + def project_name(self) -> str: + name: str = self.metadata["name"] + return name + + def __getattr__(self, attr: str, default: Any | None = None) -> Any: + return getattr(self._dist, attr, default) + + def __dir__(self) -> list[str]: + return sorted(dir(self._dist) + ["_dist", "project_name"]) + + +class PluginManager: + """Core class which manages registration of plugin objects and 1:N hook + calling. + + You can register new hooks by calling :meth:`add_hookspecs(module_or_class) + `. + + You can register plugin objects (which contain hook implementations) by + calling :meth:`register(plugin) `. + + For debugging purposes you can call :meth:`PluginManager.enable_tracing` + which will subsequently send debug information to the trace helper. + + :param project_name: + The short project name. Prefer snake case. Make sure it's unique! + """ + + def __init__(self, project_name: str) -> None: + #: The project name. + self.project_name: Final = project_name + self._name2plugin: Final[dict[str, _Plugin]] = {} + self._plugin_distinfo: Final[list[tuple[_Plugin, DistFacade]]] = [] + #: The "hook relay", used to call a hook on all registered plugins. + #: See :ref:`calling`. + self.hook: Final = HookRelay() + #: The tracing entry point. See :ref:`tracing`. + self.trace: Final[_tracing.TagTracerSub] = _tracing.TagTracer().get( + "pluginmanage" + ) + self._inner_hookexec = _multicall + + def _hookexec( + self, + hook_name: str, + methods: Sequence[HookImpl], + kwargs: Mapping[str, object], + firstresult: bool, + ) -> object | list[object]: + # called from all hookcaller instances. + # enable_tracing will set its own wrapping function at self._inner_hookexec + return self._inner_hookexec(hook_name, methods, kwargs, firstresult) + + def register(self, plugin: _Plugin, name: str | None = None) -> str | None: + """Register a plugin and return its name. + + :param name: + The name under which to register the plugin. If not specified, a + name is generated using :func:`get_canonical_name`. + + :returns: + The plugin name. If the name is blocked from registering, returns + ``None``. + + If the plugin is already registered, raises a :exc:`ValueError`. + """ + plugin_name = name or self.get_canonical_name(plugin) + + if plugin_name in self._name2plugin: + if self._name2plugin.get(plugin_name, -1) is None: + return None # blocked plugin, return None to indicate no registration + raise ValueError( + "Plugin name already registered: " + f"{plugin_name}={plugin}\n{self._name2plugin}" + ) + + if plugin in self._name2plugin.values(): + raise ValueError( + "Plugin already registered under a different name: " + f"{plugin_name}={plugin}\n{self._name2plugin}" + ) + + # XXX if an error happens we should make sure no state has been + # changed at point of return + self._name2plugin[plugin_name] = plugin + + # register matching hook implementations of the plugin + for name in dir(plugin): + hookimpl_opts = self.parse_hookimpl_opts(plugin, name) + if hookimpl_opts is not None: + normalize_hookimpl_opts(hookimpl_opts) + method: _HookImplFunction[object] = getattr(plugin, name) + hookimpl = HookImpl(plugin, plugin_name, method, hookimpl_opts) + name = hookimpl_opts.get("specname") or name + hook: HookCaller | None = getattr(self.hook, name, None) + if hook is None: + hook = HookCaller(name, self._hookexec) + setattr(self.hook, name, hook) + elif hook.has_spec(): + self._verify_hook(hook, hookimpl) + hook._maybe_apply_history(hookimpl) + hook._add_hookimpl(hookimpl) + return plugin_name + + def parse_hookimpl_opts(self, plugin: _Plugin, name: str) -> HookimplOpts | None: + """Try to obtain a hook implementation from an item with the given name + in the given plugin which is being searched for hook impls. + + :returns: + The parsed hookimpl options, or None to skip the given item. + + This method can be overridden by ``PluginManager`` subclasses to + customize how hook implementation are picked up. By default, returns the + options for items decorated with :class:`HookimplMarker`. + """ + method: object = getattr(plugin, name) + if not inspect.isroutine(method): + return None + try: + res: HookimplOpts | None = getattr( + method, self.project_name + "_impl", None + ) + except Exception: # pragma: no cover + res = {} # type: ignore[assignment] #pragma: no cover + if res is not None and not isinstance(res, dict): + # false positive + res = None # type:ignore[unreachable] #pragma: no cover + return res + + def unregister( + self, plugin: _Plugin | None = None, name: str | None = None + ) -> Any | None: + """Unregister a plugin and all of its hook implementations. + + The plugin can be specified either by the plugin object or the plugin + name. If both are specified, they must agree. + + Returns the unregistered plugin, or ``None`` if not found. + """ + if name is None: + assert plugin is not None, "one of name or plugin needs to be specified" + name = self.get_name(plugin) + assert name is not None, "plugin is not registered" + + if plugin is None: + plugin = self.get_plugin(name) + if plugin is None: + return None + + hookcallers = self.get_hookcallers(plugin) + if hookcallers: + for hookcaller in hookcallers: + hookcaller._remove_plugin(plugin) + + # if self._name2plugin[name] == None registration was blocked: ignore + if self._name2plugin.get(name): + assert name is not None + del self._name2plugin[name] + + return plugin + + def set_blocked(self, name: str) -> None: + """Block registrations of the given name, unregister if already registered.""" + self.unregister(name=name) + self._name2plugin[name] = None + + def is_blocked(self, name: str) -> bool: + """Return whether the given plugin name is blocked.""" + return name in self._name2plugin and self._name2plugin[name] is None + + def unblock(self, name: str) -> bool: + """Unblocks a name. + + Returns whether the name was actually blocked. + """ + if self._name2plugin.get(name, -1) is None: + del self._name2plugin[name] + return True + return False + + def add_hookspecs(self, module_or_class: _Namespace) -> None: + """Add new hook specifications defined in the given ``module_or_class``. + + Functions are recognized as hook specifications if they have been + decorated with a matching :class:`HookspecMarker`. + """ + names = [] + for name in dir(module_or_class): + spec_opts = self.parse_hookspec_opts(module_or_class, name) + if spec_opts is not None: + hc: HookCaller | None = getattr(self.hook, name, None) + if hc is None: + hc = HookCaller(name, self._hookexec, module_or_class, spec_opts) + setattr(self.hook, name, hc) + else: + # Plugins registered this hook without knowing the spec. + hc.set_specification(module_or_class, spec_opts) + for hookfunction in hc.get_hookimpls(): + self._verify_hook(hc, hookfunction) + names.append(name) + + if not names: + raise ValueError( + f"did not find any {self.project_name!r} hooks in {module_or_class!r}" + ) + + def parse_hookspec_opts( + self, module_or_class: _Namespace, name: str + ) -> HookspecOpts | None: + """Try to obtain a hook specification from an item with the given name + in the given module or class which is being searched for hook specs. + + :returns: + The parsed hookspec options for defining a hook, or None to skip the + given item. + + This method can be overridden by ``PluginManager`` subclasses to + customize how hook specifications are picked up. By default, returns the + options for items decorated with :class:`HookspecMarker`. + """ + method = getattr(module_or_class, name) + opts: HookspecOpts | None = getattr(method, self.project_name + "_spec", None) + return opts + + def get_plugins(self) -> set[Any]: + """Return a set of all registered plugin objects.""" + return {x for x in self._name2plugin.values() if x is not None} + + def is_registered(self, plugin: _Plugin) -> bool: + """Return whether the plugin is already registered.""" + return any(plugin == val for val in self._name2plugin.values()) + + def get_canonical_name(self, plugin: _Plugin) -> str: + """Return a canonical name for a plugin object. + + Note that a plugin may be registered under a different name + specified by the caller of :meth:`register(plugin, name) `. + To obtain the name of a registered plugin use :meth:`get_name(plugin) + ` instead. + """ + name: str | None = getattr(plugin, "__name__", None) + return name or str(id(plugin)) + + def get_plugin(self, name: str) -> Any | None: + """Return the plugin registered under the given name, if any.""" + return self._name2plugin.get(name) + + def has_plugin(self, name: str) -> bool: + """Return whether a plugin with the given name is registered.""" + return self.get_plugin(name) is not None + + def get_name(self, plugin: _Plugin) -> str | None: + """Return the name the plugin is registered under, or ``None`` if + is isn't.""" + for name, val in self._name2plugin.items(): + if plugin == val: + return name + return None + + def _verify_hook(self, hook: HookCaller, hookimpl: HookImpl) -> None: + if hook.is_historic() and (hookimpl.hookwrapper or hookimpl.wrapper): + raise PluginValidationError( + hookimpl.plugin, + f"Plugin {hookimpl.plugin_name!r}\nhook {hook.name!r}\n" + "historic incompatible with yield/wrapper/hookwrapper", + ) + + assert hook.spec is not None + if hook.spec.warn_on_impl: + _warn_for_function(hook.spec.warn_on_impl, hookimpl.function) + + # positional arg checking + notinspec = set(hookimpl.argnames) - set(hook.spec.argnames) + if notinspec: + raise PluginValidationError( + hookimpl.plugin, + f"Plugin {hookimpl.plugin_name!r} for hook {hook.name!r}\n" + f"hookimpl definition: {_formatdef(hookimpl.function)}\n" + f"Argument(s) {notinspec} are declared in the hookimpl but " + "can not be found in the hookspec", + ) + + if hook.spec.warn_on_impl_args: + for hookimpl_argname in hookimpl.argnames: + argname_warning = hook.spec.warn_on_impl_args.get(hookimpl_argname) + if argname_warning is not None: + _warn_for_function(argname_warning, hookimpl.function) + + if ( + hookimpl.wrapper or hookimpl.hookwrapper + ) and not inspect.isgeneratorfunction(hookimpl.function): + raise PluginValidationError( + hookimpl.plugin, + f"Plugin {hookimpl.plugin_name!r} for hook {hook.name!r}\n" + f"hookimpl definition: {_formatdef(hookimpl.function)}\n" + "Declared as wrapper=True or hookwrapper=True " + "but function is not a generator function", + ) + + if hookimpl.wrapper and hookimpl.hookwrapper: + raise PluginValidationError( + hookimpl.plugin, + f"Plugin {hookimpl.plugin_name!r} for hook {hook.name!r}\n" + f"hookimpl definition: {_formatdef(hookimpl.function)}\n" + "The wrapper=True and hookwrapper=True options are mutually exclusive", + ) + + def check_pending(self) -> None: + """Verify that all hooks which have not been verified against a + hook specification are optional, otherwise raise + :exc:`PluginValidationError`.""" + for name in self.hook.__dict__: + if name[0] == "_": + continue + hook: HookCaller = getattr(self.hook, name) + if not hook.has_spec(): + for hookimpl in hook.get_hookimpls(): + if not hookimpl.optionalhook: + raise PluginValidationError( + hookimpl.plugin, + f"unknown hook {name!r} in plugin {hookimpl.plugin!r}", + ) + + def load_setuptools_entrypoints(self, group: str, name: str | None = None) -> int: + """Load modules from querying the specified setuptools ``group``. + + :param group: + Entry point group to load plugins. + :param name: + If given, loads only plugins with the given ``name``. + + :return: + The number of plugins loaded by this call. + """ + import importlib.metadata + + count = 0 + for dist in list(importlib.metadata.distributions()): + for ep in dist.entry_points: + if ( + ep.group != group + or (name is not None and ep.name != name) + # already registered + or self.get_plugin(ep.name) + or self.is_blocked(ep.name) + ): + continue + plugin = ep.load() + self.register(plugin, name=ep.name) + self._plugin_distinfo.append((plugin, DistFacade(dist))) + count += 1 + return count + + def list_plugin_distinfo(self) -> list[tuple[_Plugin, DistFacade]]: + """Return a list of (plugin, distinfo) pairs for all + setuptools-registered plugins.""" + return list(self._plugin_distinfo) + + def list_name_plugin(self) -> list[tuple[str, _Plugin]]: + """Return a list of (name, plugin) pairs for all registered plugins.""" + return list(self._name2plugin.items()) + + def get_hookcallers(self, plugin: _Plugin) -> list[HookCaller] | None: + """Get all hook callers for the specified plugin. + + :returns: + The hook callers, or ``None`` if ``plugin`` is not registered in + this plugin manager. + """ + if self.get_name(plugin) is None: + return None + hookcallers = [] + for hookcaller in self.hook.__dict__.values(): + for hookimpl in hookcaller.get_hookimpls(): + if hookimpl.plugin is plugin: + hookcallers.append(hookcaller) + return hookcallers + + def add_hookcall_monitoring( + self, before: _BeforeTrace, after: _AfterTrace + ) -> Callable[[], None]: + """Add before/after tracing functions for all hooks. + + Returns an undo function which, when called, removes the added tracers. + + ``before(hook_name, hook_impls, kwargs)`` will be called ahead + of all hook calls and receive a hookcaller instance, a list + of HookImpl instances and the keyword arguments for the hook call. + + ``after(outcome, hook_name, hook_impls, kwargs)`` receives the + same arguments as ``before`` but also a :class:`~pluggy.Result` object + which represents the result of the overall hook call. + """ + oldcall = self._inner_hookexec + + def traced_hookexec( + hook_name: str, + hook_impls: Sequence[HookImpl], + caller_kwargs: Mapping[str, object], + firstresult: bool, + ) -> object | list[object]: + before(hook_name, hook_impls, caller_kwargs) + outcome = Result.from_call( + lambda: oldcall(hook_name, hook_impls, caller_kwargs, firstresult) + ) + after(outcome, hook_name, hook_impls, caller_kwargs) + return outcome.get_result() + + self._inner_hookexec = traced_hookexec + + def undo() -> None: + self._inner_hookexec = oldcall + + return undo + + def enable_tracing(self) -> Callable[[], None]: + """Enable tracing of hook calls. + + Returns an undo function which, when called, removes the added tracing. + """ + hooktrace = self.trace.root.get("hook") + + def before( + hook_name: str, methods: Sequence[HookImpl], kwargs: Mapping[str, object] + ) -> None: + hooktrace.root.indent += 1 + hooktrace(hook_name, kwargs) + + def after( + outcome: Result[object], + hook_name: str, + methods: Sequence[HookImpl], + kwargs: Mapping[str, object], + ) -> None: + if outcome.exception is None: + hooktrace("finish", hook_name, "-->", outcome.get_result()) + hooktrace.root.indent -= 1 + + return self.add_hookcall_monitoring(before, after) + + def subset_hook_caller( + self, name: str, remove_plugins: Iterable[_Plugin] + ) -> HookCaller: + """Return a proxy :class:`~pluggy.HookCaller` instance for the named + method which manages calls to all registered plugins except the ones + from remove_plugins.""" + orig: HookCaller = getattr(self.hook, name) + plugins_to_remove = {plug for plug in remove_plugins if hasattr(plug, name)} + if plugins_to_remove: + return _SubsetHookCaller(orig, plugins_to_remove) + return orig + + +def _formatdef(func: Callable[..., object]) -> str: + return f"{func.__name__}{inspect.signature(func)}" diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_result.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_result.py new file mode 100644 index 0000000000000000000000000000000000000000..656a58416cae5d9c9967f0e0b28052252a513704 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_result.py @@ -0,0 +1,107 @@ +""" +Hook wrapper "result" utilities. +""" + +from __future__ import annotations + +from types import TracebackType +from typing import Callable +from typing import cast +from typing import final +from typing import Generic +from typing import Optional +from typing import TypeVar + + +_ExcInfo = tuple[type[BaseException], BaseException, Optional[TracebackType]] +ResultType = TypeVar("ResultType") + + +class HookCallError(Exception): + """Hook was called incorrectly.""" + + +@final +class Result(Generic[ResultType]): + """An object used to inspect and set the result in a :ref:`hook wrapper + `.""" + + __slots__ = ("_result", "_exception", "_traceback") + + def __init__( + self, + result: ResultType | None, + exception: BaseException | None, + ) -> None: + """:meta private:""" + self._result = result + self._exception = exception + # Exception __traceback__ is mutable, this keeps the original. + self._traceback = exception.__traceback__ if exception is not None else None + + @property + def excinfo(self) -> _ExcInfo | None: + """:meta private:""" + exc = self._exception + if exc is None: + return None + else: + return (type(exc), exc, self._traceback) + + @property + def exception(self) -> BaseException | None: + """:meta private:""" + return self._exception + + @classmethod + def from_call(cls, func: Callable[[], ResultType]) -> Result[ResultType]: + """:meta private:""" + __tracebackhide__ = True + result = exception = None + try: + result = func() + except BaseException as exc: + exception = exc + return cls(result, exception) + + def force_result(self, result: ResultType) -> None: + """Force the result(s) to ``result``. + + If the hook was marked as a ``firstresult`` a single value should + be set, otherwise set a (modified) list of results. Any exceptions + found during invocation will be deleted. + + This overrides any previous result or exception. + """ + self._result = result + self._exception = None + self._traceback = None + + def force_exception(self, exception: BaseException) -> None: + """Force the result to fail with ``exception``. + + This overrides any previous result or exception. + + .. versionadded:: 1.1.0 + """ + self._result = None + self._exception = exception + self._traceback = exception.__traceback__ if exception is not None else None + + def get_result(self) -> ResultType: + """Get the result(s) for this hook call. + + If the hook was marked as a ``firstresult`` only a single value + will be returned, otherwise a list of results. + """ + __tracebackhide__ = True + exc = self._exception + tb = self._traceback + if exc is None: + return cast(ResultType, self._result) + else: + raise exc.with_traceback(tb) + + +# Historical name (pluggy<=1.2), kept for backward compatibility. +_Result = Result diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_tracing.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_tracing.py new file mode 100644 index 0000000000000000000000000000000000000000..f0b36db1524ffe1dac4c93561d952ef0a7dbfd8a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_tracing.py @@ -0,0 +1,72 @@ +""" +Tracing utils +""" + +from __future__ import annotations + +from collections.abc import Sequence +from typing import Any +from typing import Callable + + +_Writer = Callable[[str], object] +_Processor = Callable[[tuple[str, ...], tuple[Any, ...]], object] + + +class TagTracer: + def __init__(self) -> None: + self._tags2proc: dict[tuple[str, ...], _Processor] = {} + self._writer: _Writer | None = None + self.indent = 0 + + def get(self, name: str) -> TagTracerSub: + return TagTracerSub(self, (name,)) + + def _format_message(self, tags: Sequence[str], args: Sequence[object]) -> str: + if isinstance(args[-1], dict): + extra = args[-1] + args = args[:-1] + else: + extra = {} + + content = " ".join(map(str, args)) + indent = " " * self.indent + + lines = ["{}{} [{}]\n".format(indent, content, ":".join(tags))] + + for name, value in extra.items(): + lines.append(f"{indent} {name}: {value}\n") + + return "".join(lines) + + def _processmessage(self, tags: tuple[str, ...], args: tuple[object, ...]) -> None: + if self._writer is not None and args: + self._writer(self._format_message(tags, args)) + try: + processor = self._tags2proc[tags] + except KeyError: + pass + else: + processor(tags, args) + + def setwriter(self, writer: _Writer | None) -> None: + self._writer = writer + + def setprocessor(self, tags: str | tuple[str, ...], processor: _Processor) -> None: + if isinstance(tags, str): + tags = tuple(tags.split(":")) + else: + assert isinstance(tags, tuple) + self._tags2proc[tags] = processor + + +class TagTracerSub: + def __init__(self, root: TagTracer, tags: tuple[str, ...]) -> None: + self.root = root + self.tags = tags + + def __call__(self, *args: object) -> None: + self.root._processmessage(self.tags, args) + + def get(self, name: str) -> TagTracerSub: + return self.__class__(self.root, self.tags + (name,)) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_version.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_version.py new file mode 100644 index 0000000000000000000000000000000000000000..9d2b67bc3aab4764437411241b3ec1eeedd970f6 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_version.py @@ -0,0 +1,34 @@ +# file generated by setuptools-scm +# don't change, don't track in version control + +__all__ = [ + "__version__", + "__version_tuple__", + "version", + "version_tuple", + "__commit_id__", + "commit_id", +] + +TYPE_CHECKING = False +if TYPE_CHECKING: + from typing import Tuple + from typing import Union + + VERSION_TUPLE = Tuple[Union[int, str], ...] + COMMIT_ID = Union[str, None] +else: + VERSION_TUPLE = object + COMMIT_ID = object + +version: str +__version__: str +__version_tuple__: VERSION_TUPLE +version_tuple: VERSION_TUPLE +commit_id: COMMIT_ID +__commit_id__: COMMIT_ID + +__version__ = version = '1.6.0' +__version_tuple__ = version_tuple = (1, 6, 0) + +__commit_id__ = commit_id = None diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_warnings.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_warnings.py new file mode 100644 index 0000000000000000000000000000000000000000..6356c770c7d1f26ef4f90a4781b1386209f8169c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/_warnings.py @@ -0,0 +1,27 @@ +from typing import final + + +class PluggyWarning(UserWarning): + """Base class for all warnings emitted by pluggy.""" + + __module__ = "pluggy" + + +@final +class PluggyTeardownRaisedWarning(PluggyWarning): + """A plugin raised an exception during an :ref:`old-style hookwrapper + ` teardown. + + Such exceptions are not handled by pluggy, and may cause subsequent + teardowns to be executed at unexpected times, or be skipped entirely. + + This is an issue in the plugin implementation. + + If the exception is unintended, fix the underlying cause. + + If the exception is intended, switch to :ref:`new-style hook wrappers + `, or use :func:`result.force_exception() + ` to set the exception instead of raising. + """ + + __module__ = "pluggy" diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/py.typed b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pluggy-1.6.0-pyhf9edf01_1/site-packages/pluggy/py.typed new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/about.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/about.json new file mode 100644 index 0000000000000000000000000000000000000000..74b19c33f28fd2c74b44e2403f1f045f7599c0cd --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/about.json @@ -0,0 +1,244 @@ +{ + "channels": [ + "https://conda.anaconda.org/conda-forge" + ], + "conda_build_version": "26.1.0", + "conda_version": "26.1.1", + "env_vars": { + "CIO_TEST": "" + }, + "extra": { + "copy_test_source_files": true, + "final": true, + "flow_run_id": "github_23711927601", + "recipe-maintainers": [ + "jakirkham", + "pelson", + "ocefpaf", + "scopatz" + ], + "remote_url": "https://github.com/conda-forge/pygments-feedstock", + "sha": "f4e28944213d3c3d486c24c08936670ab4bc2747" + }, + "home": "http://pygments.org/", + "identifiers": [], + "keywords": [], + "license": "BSD-2-Clause", + "license_file": "LICENSE", + "root_pkgs": [ + "git 2.53.0 pl5321h6d3cee1_0", + "chardet 5.2.0 pyhd8ed1ab_3", + "distro 1.9.0 pyhd8ed1ab_1", + "tzdata 2025c hc9c84f9_1", + "py-lief 0.17.6 py312h1289d80_0", + "jaraco.context 6.1.1 pyhcf101f3_0", + "libsqlite 3.52.0 hf4e2dac_0", + "jsonschema 4.26.0 pyhcf101f3_0", + "libstdcxx-ng 15.2.0 hdf11a46_18", + "brotli-python 1.2.0 py312hdb49522_1", + "archspec 0.2.5 pyhd8ed1ab_0", + "simdjson 4.2.4 hb700be7_0", + "xz 5.8.2 ha02ee65_0", + "libssh2 1.11.1 hcf80075_0", + "libev 4.33 hd590300_2", + "certifi 2026.2.25 pyhd8ed1ab_0", + "python_abi 3.12 8_cp312", + "charset-normalizer 3.4.6 pyhd8ed1ab_0", + "mdurl 0.1.2 pyhd8ed1ab_1", + "patchelf 0.17.2 h58526e2_0", + "libstdcxx 15.2.0 h934c35e_18", + "nbformat 5.10.4 pyhd8ed1ab_1", + "anaconda-cli-base 0.8.1 pyhc364b38_1", + "readchar 4.2.1 pyhe01879c_0", + "lzo 2.10 h280c20c_1002", + "tk 8.6.13 noxft_h366c992_103", + "packaging 26.0 pyhcf101f3_0", + "httpx 0.28.1 pyhd8ed1ab_0", + "ruamel.yaml.clib 0.2.15 py312h5253ce2_1", + "libnghttp2 1.68.1 h877daf1_0", + "libuuid 2.41.3 h5347b49_0", + "click 8.3.1 pyh8f84b5b_1", + "libxml2 2.15.2 he237659_0", + "_openmp_mutex 4.5 20_gnu", + "pydantic-core 2.41.5 py312h868fb18_1", + "libmambapy 2.5.0 py312h1ca65c7_0", + "jaraco.classes 3.4.0 pyhcf101f3_3", + "idna 3.11 pyhd8ed1ab_0", + "jupyter_core 5.9.1 pyhc90fa1f_0", + "platformdirs 4.9.4 pyhcf101f3_0", + "jsonschema-specifications 2025.9.1 pyhcf101f3_0", + "conda-package-handling 2.4.0 pyh7900ff3_2", + "libtiff 4.7.1 h9d88235_1", + "rich 14.3.3 pyhcf101f3_0", + "libglib 2.86.4 h6548e54_1", + "pytz 2026.1.post1 pyhcf101f3_0", + "c-ares 1.34.6 hb03c661_0", + "semver 3.0.4 pyhcf101f3_1", + "zlib-ng 2.3.3 hceb46e0_1", + "dbus 1.16.2 h24cb091_1", + "perl 5.32.1 7_hd590300_perl5", + "libfreetype 2.14.3 ha770c72_0", + "markdown-it-py 4.0.0 pyhd8ed1ab_0", + "_libgcc_mutex 0.1 conda_forge", + "libmamba 2.5.0 hd28c85e_0", + "python-fastjsonschema 2.21.2 pyhe01879c_0", + "readline 8.3 h853b02a_0", + "pluggy 1.6.0 pyhf9edf01_1", + "psutil 7.2.2 py312h5253ce2_0", + "reproc 14.2.5.post0 hb9d3cd8_0", + "openjpeg 2.5.4 h55fea9a_0", + "backports.tarfile 1.2.0 pyhcf101f3_2", + "pixi 0.66.0 ha759004_0", + "typing-extensions 4.15.0 h396c80c_0", + "lz4-c 1.10.0 h5888daf_1", + "su-exec 0.2 h166bdaf_1003", + "pyjwt 2.12.1 pyhcf101f3_0", + "anaconda-client 1.14.1 pyhcf101f3_0", + "zstd 1.5.7 hb78ec9c_6", + "jsonpointer 3.1.1 pyhcf101f3_0", + "libcurl 8.19.0 hcf29cc6_0", + "httpcore 1.0.9 pyh29332c3_0", + "evalidate 2.0.5 pyhe01879c_0", + "boltons 25.0.0 pyhd8ed1ab_0", + "wheel 0.46.3 pyhd8ed1ab_0", + "nlohmann_json-abi 3.12.0 h0f90c79_1", + "libarchive 3.8.6 gpl_hc2c16d8_100", + "importlib_resources 6.5.2 pyhd8ed1ab_0", + "libgcc 15.2.0 he0feb66_18", + "liblzma-devel 5.8.2 hb03c661_0", + "libxcb 1.17.0 h8a09558_0", + "pysocks 1.7.1 pyha55dd90_7", + "ld_impl_linux-64 2.45.1 default_hbd61a6d_102", + "colorama 0.4.6 pyhd8ed1ab_1", + "xorg-libxdmcp 1.1.5 hb03c661_1", + "menuinst 2.4.2 py312h7900ff3_0", + "referencing 0.37.0 pyhcf101f3_0", + "pip 26.0.1 pyh8b19718_0", + "zipp 3.23.0 pyhcf101f3_1", + "truststore 0.10.4 pyhcf101f3_0", + "attrs 26.1.0 pyhcf101f3_0", + "annotated-types 0.7.0 pyhd8ed1ab_1", + "conda-libmamba-solver 25.11.0 pyhd8ed1ab_1", + "hyperframe 6.1.0 pyhd8ed1ab_0", + "rpds-py 0.30.0 py312h868fb18_0", + "defusedxml 0.7.1 pyhd8ed1ab_0", + "pyyaml 6.0.3 py312h8a5da7c_1", + "typing_extensions 4.15.0 pyhcf101f3_0", + "python-dotenv 1.2.2 pyhcf101f3_0", + "bzip2 1.0.8 hda65f42_9", + "zstandard 0.25.0 py312h5253ce2_1", + "tqdm 4.67.3 pyh8f84b5b_0", + "requests-toolbelt 1.0.0 pyhd8ed1ab_1", + "h11 0.16.0 pyhcf101f3_1", + "libwebp-base 1.6.0 hd42ef1d_0", + "ncurses 6.5 h2d0b736_3", + "soupsieve 2.8.3 pyhd8ed1ab_0", + "cffi 2.0.0 py312h460c074_1", + "shellingham 1.5.4 pyhd8ed1ab_2", + "jeepney 0.9.0 pyhd8ed1ab_0", + "h2 4.3.0 pyhcf101f3_0", + "traitlets 5.14.3 pyhd8ed1ab_1", + "pcre2 10.47 haa7fec5_0", + "libjpeg-turbo 3.1.2 hb03c661_0", + "liblzma 5.8.2 hb03c661_0", + "msgpack-python 1.1.2 py312hd9148b4_1", + "exceptiongroup 1.3.1 pyhd8ed1ab_0", + "secretstorage 3.4.1 py312h7900ff3_0", + "keyring 25.7.0 pyha804496_0", + "cryptography 46.0.5 py312ha4b625e_0", + "setuptools 82.0.1 pyh332efcf_0", + "annotated-doc 0.0.4 pyhcf101f3_0", + "ca-certificates 2026.2.25 hbd8a1cb_0", + "tomlkit 0.14.0 pyha770c72_0", + "spdlog 1.17.0 hab81395_1", + "lcms2 2.18 h0c24ade_0", + "openssl 3.6.1 h35e630c_1", + "pydantic 2.12.5 pyhcf101f3_1", + "libxcrypt 4.4.36 hd590300_1", + "libpng 1.6.56 h421ea60_0", + "anaconda-auth 0.14.0 pyhd8ed1ab_0", + "hpack 4.1.0 pyhd8ed1ab_0", + "libsolv 0.7.36 h9463b59_0", + "xz-tools 5.8.2 hb03c661_0", + "markupsafe 3.0.3 py312h8a5da7c_1", + "icu 78.3 h33c6efd_0", + "jaraco.functools 4.4.0 pyhcf101f3_1", + "libzlib 1.3.2 h25fd6f3_2", + "python-dateutil 2.9.0.post0 pyhe01879c_2", + "conda 26.1.1 py312h7900ff3_0", + "importlib-metadata 8.8.0 pyhcf101f3_0", + "reproc-cpp 14.2.5.post0 h5888daf_0", + "jinja2 3.1.6 pyhcf101f3_1", + "pydantic-settings 2.13.1 pyhd8ed1ab_0", + "libedit 3.1.20250104 pl5321h7949ede_0", + "pkce 1.0.3 pyhd8ed1ab_1", + "libexpat 2.7.5 hecca717_0", + "backports.zstd 1.3.0 py312h90b7ffd_0", + "pycparser 2.22 pyh29332c3_1", + "mbedtls 3.6.3.1 h5888daf_0", + "lerc 4.1.0 hdb68285_0", + "xz-gpl-tools 5.8.2 ha02ee65_0", + "jsonpatch 1.33 pyhd8ed1ab_1", + "yaml-cpp 0.8.0 h59595ed_0", + "libdeflate 1.25 h17f619e_0", + "typing-inspection 0.4.2 pyhd8ed1ab_1", + "pkginfo 1.12.1.2 pyhd8ed1ab_0", + "frozendict 2.4.7 py312h4c3975b_0", + "keyutils 1.6.3 hb9d3cd8_0", + "backports 1.0 pyhd8ed1ab_5", + "krb5 1.22.2 ha1258a1_0", + "yaml 0.2.5 h280c20c_3", + "tini 0.19.0 h166bdaf_1", + "libxml2-16 2.15.2 hca6bf5a_0", + "pthread-stubs 0.4 hb9d3cd8_1002", + "conda-index 0.7.0 pyhd8ed1ab_0", + "libfreetype6 2.14.3 h73754d4_0", + "patch 2.8 hb03c661_1002", + "libiconv 1.18 h3b78370_2", + "beautifulsoup4 4.14.3 pyha770c72_0", + "ruamel.yaml 0.18.17 py312h5253ce2_2", + "filelock 3.25.2 pyhd8ed1ab_0", + "pybind11-abi 11 hc364b38_1", + "tomli 2.4.1 pyhcf101f3_0", + "ripgrep 15.1.0 hdab8a38_0", + "python-libarchive-c 5.3 pyhe01879c_1", + "pygments 2.19.2 pyhd8ed1ab_0", + "urllib3 2.6.3 pyhd8ed1ab_0", + "conda-package-streaming 0.12.0 pyhd8ed1ab_0", + "anyio 4.13.0 pyhcf101f3_0", + "mamba 2.5.0 h9835478_0", + "python 3.12.13 hd63d673_0_cpython", + "libnsl 2.0.1 hb9d3cd8_1", + "libffi 3.5.2 h3435931_0", + "more-itertools 10.8.0 pyhcf101f3_1", + "pycosat 0.6.6 py312h4c3975b_3", + "sniffio 1.3.1 pyhd8ed1ab_2", + "six 1.17.0 pyhe01879c_1", + "pillow 12.1.1 py312h50c33e8_0", + "libgomp 15.2.0 he0feb66_18", + "cpp-expected 1.3.1 h171cf75_0", + "conda-build 26.1.0 pyh31ec981_2", + "liblief 0.17.6 hecca717_0", + "typer 0.24.0 pyhcf101f3_0", + "fmt 12.1.0 hff5e90c_0", + "libmamba-spdlog 2.5.0 h12fcf84_0", + "requests 2.33.0 pyhcf101f3_0", + "xorg-libxau 1.0.12 hb03c661_1", + "libgcc-ng 15.2.0 h69a702a_18", + "oras-py 0.1.14 pyhd8ed1ab_0", + "wrapt 2.1.2 py312h4c3975b_0", + "joblib 1.5.3 pyhd8ed1ab_0", + "conda-oci-mirror 0.2.3 pyhd8ed1ab_0", + "rattler-build 0.61.2 ha759004_0", + "conda-forge-metadata 0.13.0 pyhcf101f3_0", + "deprecated 1.3.1 pyhd8ed1ab_1", + "oniguruma 6.9.10 hb9d3cd8_0", + "conda-env 2.6.0 1", + "conda-forge-ci-setup 4.24.2 py312hef7310e_101", + "shyaml 0.6.2 pyhd3deb0d_0", + "jq 1.8.1 h73b1eb8_0", + "rattler-build-conda-compat 1.4.11 pyhd8ed1ab_0" + ], + "summary": "Pygments is a generic syntax highlighter suitable for use in code hosting, forums, wikis or other applications that need to prettify source code.", + "tags": [] +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/files b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/files new file mode 100644 index 0000000000000000000000000000000000000000..ee390cd18ce53d8981ea68458f345c8452840673 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/files @@ -0,0 +1,348 @@ +site-packages/pygments-2.20.0.dist-info/INSTALLER +site-packages/pygments-2.20.0.dist-info/METADATA +site-packages/pygments-2.20.0.dist-info/RECORD +site-packages/pygments-2.20.0.dist-info/REQUESTED +site-packages/pygments-2.20.0.dist-info/WHEEL +site-packages/pygments-2.20.0.dist-info/direct_url.json +site-packages/pygments-2.20.0.dist-info/entry_points.txt +site-packages/pygments-2.20.0.dist-info/licenses/AUTHORS +site-packages/pygments-2.20.0.dist-info/licenses/LICENSE +site-packages/pygments/__init__.py +site-packages/pygments/__main__.py +site-packages/pygments/cmdline.py +site-packages/pygments/console.py +site-packages/pygments/filter.py +site-packages/pygments/filters/__init__.py +site-packages/pygments/formatter.py +site-packages/pygments/formatters/__init__.py +site-packages/pygments/formatters/_mapping.py +site-packages/pygments/formatters/bbcode.py +site-packages/pygments/formatters/groff.py +site-packages/pygments/formatters/html.py +site-packages/pygments/formatters/img.py +site-packages/pygments/formatters/irc.py +site-packages/pygments/formatters/latex.py +site-packages/pygments/formatters/other.py +site-packages/pygments/formatters/pangomarkup.py +site-packages/pygments/formatters/rtf.py +site-packages/pygments/formatters/svg.py +site-packages/pygments/formatters/terminal.py +site-packages/pygments/formatters/terminal256.py +site-packages/pygments/lexer.py +site-packages/pygments/lexers/__init__.py +site-packages/pygments/lexers/_ada_builtins.py +site-packages/pygments/lexers/_asy_builtins.py +site-packages/pygments/lexers/_cl_builtins.py +site-packages/pygments/lexers/_cocoa_builtins.py +site-packages/pygments/lexers/_csound_builtins.py +site-packages/pygments/lexers/_css_builtins.py +site-packages/pygments/lexers/_googlesql_builtins.py +site-packages/pygments/lexers/_julia_builtins.py +site-packages/pygments/lexers/_lasso_builtins.py +site-packages/pygments/lexers/_lilypond_builtins.py +site-packages/pygments/lexers/_lua_builtins.py +site-packages/pygments/lexers/_luau_builtins.py +site-packages/pygments/lexers/_mapping.py +site-packages/pygments/lexers/_mql_builtins.py +site-packages/pygments/lexers/_mysql_builtins.py +site-packages/pygments/lexers/_openedge_builtins.py +site-packages/pygments/lexers/_php_builtins.py +site-packages/pygments/lexers/_postgres_builtins.py +site-packages/pygments/lexers/_qlik_builtins.py +site-packages/pygments/lexers/_scheme_builtins.py +site-packages/pygments/lexers/_scilab_builtins.py +site-packages/pygments/lexers/_sourcemod_builtins.py +site-packages/pygments/lexers/_sql_builtins.py +site-packages/pygments/lexers/_stan_builtins.py +site-packages/pygments/lexers/_stata_builtins.py +site-packages/pygments/lexers/_tsql_builtins.py +site-packages/pygments/lexers/_usd_builtins.py +site-packages/pygments/lexers/_vbscript_builtins.py +site-packages/pygments/lexers/_vim_builtins.py +site-packages/pygments/lexers/actionscript.py +site-packages/pygments/lexers/ada.py +site-packages/pygments/lexers/agile.py +site-packages/pygments/lexers/algebra.py +site-packages/pygments/lexers/ambient.py +site-packages/pygments/lexers/amdgpu.py +site-packages/pygments/lexers/ampl.py +site-packages/pygments/lexers/apdlexer.py +site-packages/pygments/lexers/apl.py +site-packages/pygments/lexers/archetype.py +site-packages/pygments/lexers/arrow.py +site-packages/pygments/lexers/arturo.py +site-packages/pygments/lexers/asc.py +site-packages/pygments/lexers/asm.py +site-packages/pygments/lexers/asn1.py +site-packages/pygments/lexers/automation.py +site-packages/pygments/lexers/bare.py +site-packages/pygments/lexers/basic.py +site-packages/pygments/lexers/bdd.py +site-packages/pygments/lexers/berry.py +site-packages/pygments/lexers/bibtex.py +site-packages/pygments/lexers/blueprint.py +site-packages/pygments/lexers/boa.py +site-packages/pygments/lexers/bqn.py +site-packages/pygments/lexers/business.py +site-packages/pygments/lexers/c_cpp.py +site-packages/pygments/lexers/c_like.py +site-packages/pygments/lexers/capnproto.py +site-packages/pygments/lexers/carbon.py +site-packages/pygments/lexers/cddl.py +site-packages/pygments/lexers/chapel.py +site-packages/pygments/lexers/clean.py +site-packages/pygments/lexers/codeql.py +site-packages/pygments/lexers/comal.py +site-packages/pygments/lexers/compiled.py +site-packages/pygments/lexers/configs.py +site-packages/pygments/lexers/console.py +site-packages/pygments/lexers/cplint.py +site-packages/pygments/lexers/crystal.py +site-packages/pygments/lexers/csound.py +site-packages/pygments/lexers/css.py +site-packages/pygments/lexers/d.py +site-packages/pygments/lexers/dalvik.py +site-packages/pygments/lexers/data.py +site-packages/pygments/lexers/dax.py +site-packages/pygments/lexers/devicetree.py +site-packages/pygments/lexers/diff.py +site-packages/pygments/lexers/dns.py +site-packages/pygments/lexers/dotnet.py +site-packages/pygments/lexers/dsls.py +site-packages/pygments/lexers/dylan.py +site-packages/pygments/lexers/ecl.py +site-packages/pygments/lexers/eiffel.py +site-packages/pygments/lexers/elm.py +site-packages/pygments/lexers/elpi.py +site-packages/pygments/lexers/email.py +site-packages/pygments/lexers/erlang.py +site-packages/pygments/lexers/esoteric.py +site-packages/pygments/lexers/ezhil.py +site-packages/pygments/lexers/factor.py +site-packages/pygments/lexers/fantom.py +site-packages/pygments/lexers/felix.py +site-packages/pygments/lexers/fift.py +site-packages/pygments/lexers/floscript.py +site-packages/pygments/lexers/forth.py +site-packages/pygments/lexers/fortran.py +site-packages/pygments/lexers/foxpro.py +site-packages/pygments/lexers/freefem.py +site-packages/pygments/lexers/func.py +site-packages/pygments/lexers/functional.py +site-packages/pygments/lexers/futhark.py +site-packages/pygments/lexers/gcodelexer.py +site-packages/pygments/lexers/gdscript.py +site-packages/pygments/lexers/gleam.py +site-packages/pygments/lexers/go.py +site-packages/pygments/lexers/grammar_notation.py +site-packages/pygments/lexers/graph.py +site-packages/pygments/lexers/graphics.py +site-packages/pygments/lexers/graphql.py +site-packages/pygments/lexers/graphviz.py +site-packages/pygments/lexers/gsql.py +site-packages/pygments/lexers/hare.py +site-packages/pygments/lexers/haskell.py +site-packages/pygments/lexers/haxe.py +site-packages/pygments/lexers/hdl.py +site-packages/pygments/lexers/hexdump.py +site-packages/pygments/lexers/html.py +site-packages/pygments/lexers/idl.py +site-packages/pygments/lexers/igor.py +site-packages/pygments/lexers/inferno.py +site-packages/pygments/lexers/installers.py +site-packages/pygments/lexers/int_fiction.py +site-packages/pygments/lexers/iolang.py +site-packages/pygments/lexers/j.py +site-packages/pygments/lexers/javascript.py +site-packages/pygments/lexers/jmespath.py +site-packages/pygments/lexers/jslt.py +site-packages/pygments/lexers/json5.py +site-packages/pygments/lexers/jsonnet.py +site-packages/pygments/lexers/jsx.py +site-packages/pygments/lexers/julia.py +site-packages/pygments/lexers/jvm.py +site-packages/pygments/lexers/kuin.py +site-packages/pygments/lexers/kusto.py +site-packages/pygments/lexers/ldap.py +site-packages/pygments/lexers/lean.py +site-packages/pygments/lexers/lilypond.py +site-packages/pygments/lexers/lisp.py +site-packages/pygments/lexers/macaulay2.py +site-packages/pygments/lexers/make.py +site-packages/pygments/lexers/maple.py +site-packages/pygments/lexers/markup.py +site-packages/pygments/lexers/math.py +site-packages/pygments/lexers/matlab.py +site-packages/pygments/lexers/maxima.py +site-packages/pygments/lexers/meson.py +site-packages/pygments/lexers/mime.py +site-packages/pygments/lexers/minecraft.py +site-packages/pygments/lexers/mips.py +site-packages/pygments/lexers/ml.py +site-packages/pygments/lexers/modeling.py +site-packages/pygments/lexers/modula2.py +site-packages/pygments/lexers/mojo.py +site-packages/pygments/lexers/monte.py +site-packages/pygments/lexers/mosel.py +site-packages/pygments/lexers/ncl.py +site-packages/pygments/lexers/nimrod.py +site-packages/pygments/lexers/nit.py +site-packages/pygments/lexers/nix.py +site-packages/pygments/lexers/numbair.py +site-packages/pygments/lexers/oberon.py +site-packages/pygments/lexers/objective.py +site-packages/pygments/lexers/ooc.py +site-packages/pygments/lexers/openscad.py +site-packages/pygments/lexers/other.py +site-packages/pygments/lexers/parasail.py +site-packages/pygments/lexers/parsers.py +site-packages/pygments/lexers/pascal.py +site-packages/pygments/lexers/pawn.py +site-packages/pygments/lexers/pddl.py +site-packages/pygments/lexers/perl.py +site-packages/pygments/lexers/phix.py +site-packages/pygments/lexers/php.py +site-packages/pygments/lexers/pointless.py +site-packages/pygments/lexers/pony.py +site-packages/pygments/lexers/praat.py +site-packages/pygments/lexers/procfile.py +site-packages/pygments/lexers/prolog.py +site-packages/pygments/lexers/promql.py +site-packages/pygments/lexers/prql.py +site-packages/pygments/lexers/ptx.py +site-packages/pygments/lexers/python.py +site-packages/pygments/lexers/q.py +site-packages/pygments/lexers/qlik.py +site-packages/pygments/lexers/qvt.py +site-packages/pygments/lexers/r.py +site-packages/pygments/lexers/rdf.py +site-packages/pygments/lexers/rebol.py +site-packages/pygments/lexers/rego.py +site-packages/pygments/lexers/rell.py +site-packages/pygments/lexers/resource.py +site-packages/pygments/lexers/ride.py +site-packages/pygments/lexers/rita.py +site-packages/pygments/lexers/rnc.py +site-packages/pygments/lexers/roboconf.py +site-packages/pygments/lexers/robotframework.py +site-packages/pygments/lexers/ruby.py +site-packages/pygments/lexers/rust.py +site-packages/pygments/lexers/sas.py +site-packages/pygments/lexers/savi.py +site-packages/pygments/lexers/scdoc.py +site-packages/pygments/lexers/scripting.py +site-packages/pygments/lexers/sgf.py +site-packages/pygments/lexers/shell.py +site-packages/pygments/lexers/sieve.py +site-packages/pygments/lexers/slash.py +site-packages/pygments/lexers/smalltalk.py +site-packages/pygments/lexers/smithy.py +site-packages/pygments/lexers/smv.py +site-packages/pygments/lexers/snobol.py +site-packages/pygments/lexers/solidity.py +site-packages/pygments/lexers/soong.py +site-packages/pygments/lexers/sophia.py +site-packages/pygments/lexers/special.py +site-packages/pygments/lexers/spice.py +site-packages/pygments/lexers/sql.py +site-packages/pygments/lexers/srcinfo.py +site-packages/pygments/lexers/stata.py +site-packages/pygments/lexers/supercollider.py +site-packages/pygments/lexers/tablegen.py +site-packages/pygments/lexers/tact.py +site-packages/pygments/lexers/tal.py +site-packages/pygments/lexers/tcl.py +site-packages/pygments/lexers/teal.py +site-packages/pygments/lexers/templates.py +site-packages/pygments/lexers/teraterm.py +site-packages/pygments/lexers/testing.py +site-packages/pygments/lexers/text.py +site-packages/pygments/lexers/textedit.py +site-packages/pygments/lexers/textfmts.py +site-packages/pygments/lexers/theorem.py +site-packages/pygments/lexers/thingsdb.py +site-packages/pygments/lexers/tlb.py +site-packages/pygments/lexers/tls.py +site-packages/pygments/lexers/tnt.py +site-packages/pygments/lexers/trafficscript.py +site-packages/pygments/lexers/typoscript.py +site-packages/pygments/lexers/typst.py +site-packages/pygments/lexers/ul4.py +site-packages/pygments/lexers/unicon.py +site-packages/pygments/lexers/urbi.py +site-packages/pygments/lexers/usd.py +site-packages/pygments/lexers/varnish.py +site-packages/pygments/lexers/verification.py +site-packages/pygments/lexers/verifpal.py +site-packages/pygments/lexers/vip.py +site-packages/pygments/lexers/vyper.py +site-packages/pygments/lexers/web.py +site-packages/pygments/lexers/webassembly.py +site-packages/pygments/lexers/webidl.py +site-packages/pygments/lexers/webmisc.py +site-packages/pygments/lexers/wgsl.py +site-packages/pygments/lexers/whiley.py +site-packages/pygments/lexers/wowtoc.py +site-packages/pygments/lexers/wren.py +site-packages/pygments/lexers/x10.py +site-packages/pygments/lexers/xorg.py +site-packages/pygments/lexers/yang.py +site-packages/pygments/lexers/yara.py +site-packages/pygments/lexers/zig.py +site-packages/pygments/modeline.py +site-packages/pygments/plugin.py +site-packages/pygments/regexopt.py +site-packages/pygments/scanner.py +site-packages/pygments/sphinxext.py +site-packages/pygments/style.py +site-packages/pygments/styles/__init__.py +site-packages/pygments/styles/_mapping.py +site-packages/pygments/styles/abap.py +site-packages/pygments/styles/algol.py +site-packages/pygments/styles/algol_nu.py +site-packages/pygments/styles/arduino.py +site-packages/pygments/styles/autumn.py +site-packages/pygments/styles/borland.py +site-packages/pygments/styles/bw.py +site-packages/pygments/styles/coffee.py +site-packages/pygments/styles/colorful.py +site-packages/pygments/styles/default.py +site-packages/pygments/styles/dracula.py +site-packages/pygments/styles/emacs.py +site-packages/pygments/styles/friendly.py +site-packages/pygments/styles/friendly_grayscale.py +site-packages/pygments/styles/fruity.py +site-packages/pygments/styles/gh_dark.py +site-packages/pygments/styles/gruvbox.py +site-packages/pygments/styles/igor.py +site-packages/pygments/styles/inkpot.py +site-packages/pygments/styles/lightbulb.py +site-packages/pygments/styles/lilypond.py +site-packages/pygments/styles/lovelace.py +site-packages/pygments/styles/manni.py +site-packages/pygments/styles/material.py +site-packages/pygments/styles/monokai.py +site-packages/pygments/styles/murphy.py +site-packages/pygments/styles/native.py +site-packages/pygments/styles/nord.py +site-packages/pygments/styles/onedark.py +site-packages/pygments/styles/paraiso_dark.py +site-packages/pygments/styles/paraiso_light.py +site-packages/pygments/styles/pastie.py +site-packages/pygments/styles/perldoc.py +site-packages/pygments/styles/rainbow_dash.py +site-packages/pygments/styles/rrt.py +site-packages/pygments/styles/sas.py +site-packages/pygments/styles/solarized.py +site-packages/pygments/styles/staroffice.py +site-packages/pygments/styles/stata_dark.py +site-packages/pygments/styles/stata_light.py +site-packages/pygments/styles/tango.py +site-packages/pygments/styles/trac.py +site-packages/pygments/styles/vim.py +site-packages/pygments/styles/vs.py +site-packages/pygments/styles/xcode.py +site-packages/pygments/styles/zenburn.py +site-packages/pygments/token.py +site-packages/pygments/unistring.py +site-packages/pygments/util.py diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/git b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/git new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/hash_input.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/hash_input.json new file mode 100644 index 0000000000000000000000000000000000000000..13d50ee321d847b554d3c6459e367e47afdcf976 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/hash_input.json @@ -0,0 +1,3 @@ +{ + "channel_targets": "conda-forge main" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/index.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/index.json new file mode 100644 index 0000000000000000000000000000000000000000..d9ef83f6190eb4bcabc75c8cc85f28660b164343 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/index.json @@ -0,0 +1,15 @@ +{ + "arch": null, + "build": "pyhd8ed1ab_0", + "build_number": 0, + "depends": [ + "python >=3.10" + ], + "license": "BSD-2-Clause", + "name": "pygments", + "noarch": "python", + "platform": null, + "subdir": "noarch", + "timestamp": 1774796815820, + "version": "2.20.0" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..446a1a805c8a949579fb8a9799f2bec7777349dc --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/licenses/LICENSE @@ -0,0 +1,25 @@ +Copyright (c) 2006-2022 by the respective authors (see AUTHORS file). +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + +* Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + +* Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/link.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/link.json new file mode 100644 index 0000000000000000000000000000000000000000..18604d5852448adb7ad8dc365e8ee7155529492d --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/link.json @@ -0,0 +1,9 @@ +{ + "noarch": { + "entry_points": [ + "pygmentize = pygments.cmdline:main" + ], + "type": "python" + }, + "package_metadata_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/paths.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/paths.json new file mode 100644 index 0000000000000000000000000000000000000000..0fd6976a3ccef56ec5f1afca75430d2cd0aa6ff2 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/paths.json @@ -0,0 +1,2093 @@ +{ + "paths": [ + { + "_path": "site-packages/pygments-2.20.0.dist-info/INSTALLER", + "path_type": "hardlink", + "sha256": "d0edee15f91b406f3f99726e44eb990be6e34fd0345b52b910c568e0eef6a2a8", + "size_in_bytes": 5 + }, + { + "_path": "site-packages/pygments-2.20.0.dist-info/METADATA", + "path_type": "hardlink", + "sha256": "e0528f51b30427fae94723662ba622f8d8db2a4d8d3f1365698d67a52450a845", + "size_in_bytes": 2476 + }, + { + "_path": "site-packages/pygments-2.20.0.dist-info/RECORD", + "path_type": "hardlink", + "sha256": "3f287859c16ff56cffb4c32cd62718f9da9553a7bf6ad807ded9f60edc8ddc35", + "size_in_bytes": 47751 + }, + { + "_path": "site-packages/pygments-2.20.0.dist-info/REQUESTED", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pygments-2.20.0.dist-info/WHEEL", + "path_type": "hardlink", + "sha256": "41c708c5adba6e097513ab8ccb9f1d7865a2fb469e22491a9e01dcc64da459fc", + "size_in_bytes": 87 + }, + { + "_path": "site-packages/pygments-2.20.0.dist-info/direct_url.json", + "path_type": "hardlink", + "sha256": "d9ef2f948e9ae873b65385fe0316667f5c8dee4fd554e1bf4d4a23f636f50478", + "size_in_bytes": 104 + }, + { + "_path": "site-packages/pygments-2.20.0.dist-info/entry_points.txt", + "path_type": "hardlink", + "sha256": "b945f0f9784c281117e2959c0ada6e4d39cf84bde1ece104da35a2e75550b1af", + "size_in_bytes": 53 + }, + { + "_path": "site-packages/pygments-2.20.0.dist-info/licenses/AUTHORS", + "path_type": "hardlink", + "sha256": "0db603a5f4499f690c4425477ff664c166da325d3acc3b5a8d4de3db072443d0", + "size_in_bytes": 10873 + }, + { + "_path": "site-packages/pygments-2.20.0.dist-info/licenses/LICENSE", + "path_type": "hardlink", + "sha256": "a9d66f1d526df02e29dce73436d34e56e8632f46c275bbdffc70569e882f9f17", + "size_in_bytes": 1331 + }, + { + "_path": "site-packages/pygments/__init__.py", + "path_type": "hardlink", + "sha256": "673a675e9be7bf473baff3884bc87b51e6844aa60d28ccbffe957b2828965f1c", + "size_in_bytes": 2962 + }, + { + "_path": "site-packages/pygments/__main__.py", + "path_type": "hardlink", + "sha256": "4195a3d13e934d1b2aafec3ed18bd520ba350f202fcf3c9d18244e370744ceaa", + "size_in_bytes": 351 + }, + { + "_path": "site-packages/pygments/cmdline.py", + "path_type": "hardlink", + "sha256": "fdd3a7aed6bfd8621ef0983ed58d296f9bd68bc2fa413889cf2a13b87ad8adb3", + "size_in_bytes": 23542 + }, + { + "_path": "site-packages/pygments/console.py", + "path_type": "hardlink", + "sha256": "0b5f3d240c210b5421d002a0b21cdbd70543cc5a819efd55678e644c40c83b7d", + "size_in_bytes": 1721 + }, + { + "_path": "site-packages/pygments/filter.py", + "path_type": "hardlink", + "sha256": "d5d9db92ad80742dc0907b770da5f09ce91304b0a1975911ea76922f09ebfed7", + "size_in_bytes": 1913 + }, + { + "_path": "site-packages/pygments/filters/__init__.py", + "path_type": "hardlink", + "sha256": "d37658748626c6758287b80d5c3ee5110f3af437f89331e7386338e222716a7f", + "size_in_bytes": 40349 + }, + { + "_path": "site-packages/pygments/formatter.py", + "path_type": "hardlink", + "sha256": "3d30674d6d041e47b6bf39402aebc72648f7fbf08c8fc76e231fb7c955227bea", + "size_in_bytes": 4369 + }, + { + "_path": "site-packages/pygments/formatters/__init__.py", + "path_type": "hardlink", + "sha256": "a8f1b8ab972e69944606096610954b3f8483bf8dd0237b4052c923df433e98e6", + "size_in_bytes": 5352 + }, + { + "_path": "site-packages/pygments/formatters/_mapping.py", + "path_type": "hardlink", + "sha256": "d42c37ec5b9094d69c9f144a9ad94f5f89f22e85fdfedb64a39670b1c354659e", + "size_in_bytes": 4176 + }, + { + "_path": "site-packages/pygments/formatters/bbcode.py", + "path_type": "hardlink", + "sha256": "96f1b5444649bf4a4ce9531ef90c0b4aea34625d516bf5f9d7087dddf5bc0369", + "size_in_bytes": 3299 + }, + { + "_path": "site-packages/pygments/formatters/groff.py", + "path_type": "hardlink", + "sha256": "6a71777cd6c3630c0e969a4e528293660e05cf33db66b1388dc24231de3dff58", + "size_in_bytes": 5085 + }, + { + "_path": "site-packages/pygments/formatters/html.py", + "path_type": "hardlink", + "sha256": "a9ee0feaa215e3ad87919a2f4bcb39c4a2b26173d042f523cfa5a3ec75f50b16", + "size_in_bytes": 36053 + }, + { + "_path": "site-packages/pygments/formatters/img.py", + "path_type": "hardlink", + "sha256": "e35b92634a4a83d56628962b1ee6af095820d33fa683cd69dbc404324b707f5a", + "size_in_bytes": 23304 + }, + { + "_path": "site-packages/pygments/formatters/irc.py", + "path_type": "hardlink", + "sha256": "85d3aa02f174d9b23c098f3fb6eb67529b4166958404bcd502a4b8fd8034b5ec", + "size_in_bytes": 4907 + }, + { + "_path": "site-packages/pygments/formatters/latex.py", + "path_type": "hardlink", + "sha256": "710984d4d8f813dab93745d0241aa973a74bb6ee5434eb58ab7a653f2097d479", + "size_in_bytes": 19261 + }, + { + "_path": "site-packages/pygments/formatters/other.py", + "path_type": "hardlink", + "sha256": "1eaeaa6383ce059fe5940591af583348ef54a1e60f38d94b3012bad11916e1b8", + "size_in_bytes": 4989 + }, + { + "_path": "site-packages/pygments/formatters/pangomarkup.py", + "path_type": "hardlink", + "sha256": "2f88d4ea83b5f14a8432a5de3791643ed922b17ad7b97abdc1c79c832ffa773a", + "size_in_bytes": 2209 + }, + { + "_path": "site-packages/pygments/formatters/rtf.py", + "path_type": "hardlink", + "sha256": "610616f0d4eb0785df3a32db433badc83e23df94e2985359d13dfd7444fd0cea", + "size_in_bytes": 11924 + }, + { + "_path": "site-packages/pygments/formatters/svg.py", + "path_type": "hardlink", + "sha256": "a24b174fe6674c70ec9f55ad5a006cf55eea98a16cc002b1ee3577eed6f6b586", + "size_in_bytes": 7141 + }, + { + "_path": "site-packages/pygments/formatters/terminal.py", + "path_type": "hardlink", + "sha256": "abb8cb2da9e57b7dde099903af80a81c037e7470457f50c1862e0570143cff51", + "size_in_bytes": 4629 + }, + { + "_path": "site-packages/pygments/formatters/terminal256.py", + "path_type": "hardlink", + "sha256": "3e903fa004c70a28775138eb6df2aa21151cbecca9fd3781686c379292317810", + "size_in_bytes": 11717 + }, + { + "_path": "site-packages/pygments/lexer.py", + "path_type": "hardlink", + "sha256": "80d318ce675291337259faa22c9dfba147752ab37f74c5edb0fc9a5f6fa7f440", + "size_in_bytes": 35154 + }, + { + "_path": "site-packages/pygments/lexers/__init__.py", + "path_type": "hardlink", + "sha256": "1b876da84e5030402aa1a683d6bc126597aea8a84cc92e2eb65333d6cce4ad38", + "size_in_bytes": 12070 + }, + { + "_path": "site-packages/pygments/lexers/_ada_builtins.py", + "path_type": "hardlink", + "sha256": "7596fe96876c48ce8be5e98b9602e0fab0a59b61ee9af9c72bbd827ad9d245d0", + "size_in_bytes": 1546 + }, + { + "_path": "site-packages/pygments/lexers/_asy_builtins.py", + "path_type": "hardlink", + "sha256": "ce0e787c6860cd65d0524ebea99e8e5b91932fd7783ab9c1f12250923ac3d31b", + "size_in_bytes": 27290 + }, + { + "_path": "site-packages/pygments/lexers/_cl_builtins.py", + "path_type": "hardlink", + "sha256": "a01174d19909c83d782e462e47ad371031483328ad9337b5d9a4fb5330d82d8b", + "size_in_bytes": 13997 + }, + { + "_path": "site-packages/pygments/lexers/_cocoa_builtins.py", + "path_type": "hardlink", + "sha256": "69beacabe8b2e4b6a913570d63297c3c95cb83a108357c7e94c45bc0445d298b", + "size_in_bytes": 105176 + }, + { + "_path": "site-packages/pygments/lexers/_csound_builtins.py", + "path_type": "hardlink", + "sha256": "c2e5a2423984321695bec57c6ff79fb1e6e053460a228302d040a939abd30883", + "size_in_bytes": 18417 + }, + { + "_path": "site-packages/pygments/lexers/_css_builtins.py", + "path_type": "hardlink", + "sha256": "aa1982e2d4461b9df3bf3310135aa7efde0bbdb54e0d1b5569cc5608fde42240", + "size_in_bytes": 12449 + }, + { + "_path": "site-packages/pygments/lexers/_googlesql_builtins.py", + "path_type": "hardlink", + "sha256": "9867ce1ae28a8d9a071c0019aba1e973af31d2a2b2731f925ffc060d27123982", + "size_in_bytes": 16135 + }, + { + "_path": "site-packages/pygments/lexers/_julia_builtins.py", + "path_type": "hardlink", + "sha256": "bbabf4c80cd98ea504363888439a8c7dcb28d6bffa111a866e3dda1f0167caa0", + "size_in_bytes": 11886 + }, + { + "_path": "site-packages/pygments/lexers/_lasso_builtins.py", + "path_type": "hardlink", + "sha256": "60efdcfdfd39668c6ca47c42477a16402a5985b00953304906156ebb04e3af97", + "size_in_bytes": 134513 + }, + { + "_path": "site-packages/pygments/lexers/_lilypond_builtins.py", + "path_type": "hardlink", + "sha256": "fbfe22e20a600e07051ef6993092f6b35ac8f5d48d636642eaf3baba5ec79a5d", + "size_in_bytes": 115114 + }, + { + "_path": "site-packages/pygments/lexers/_lua_builtins.py", + "path_type": "hardlink", + "sha256": "32c0d5f6c11b26780aa17499bb4c576b01af77a5e315fd76e67b9704da1f7dd5", + "size_in_bytes": 8111 + }, + { + "_path": "site-packages/pygments/lexers/_luau_builtins.py", + "path_type": "hardlink", + "sha256": "60b523d9b719d026f448190894d5d61c518350592975d389c7eba4ad9c7570c7", + "size_in_bytes": 958 + }, + { + "_path": "site-packages/pygments/lexers/_mapping.py", + "path_type": "hardlink", + "sha256": "61b4090757aa78693ba25e4d80c30f2eb0f7546753c204029774ef2f0b71c310", + "size_in_bytes": 70758 + }, + { + "_path": "site-packages/pygments/lexers/_mql_builtins.py", + "path_type": "hardlink", + "sha256": "0a472f3321d8878539ac6815e808128714674cebf4b66a846ce8957696852eab", + "size_in_bytes": 24716 + }, + { + "_path": "site-packages/pygments/lexers/_mysql_builtins.py", + "path_type": "hardlink", + "sha256": "4aa895615562aed9cde254a0b5f7913f1b55a5cba68d4bef52af67f0939bb90e", + "size_in_bytes": 26876 + }, + { + "_path": "site-packages/pygments/lexers/_openedge_builtins.py", + "path_type": "hardlink", + "sha256": "033175a3a78090c73abe7be6795a8d9d46545628f36cd6248f3ad476d0907b73", + "size_in_bytes": 49401 + }, + { + "_path": "site-packages/pygments/lexers/_php_builtins.py", + "path_type": "hardlink", + "sha256": "f60f962d3dea6d21a8950241ff83d2e855bfafb1d55c15af239396c4ab5bc289", + "size_in_bytes": 108054 + }, + { + "_path": "site-packages/pygments/lexers/_postgres_builtins.py", + "path_type": "hardlink", + "sha256": "4068369814d3860bf82dd5e3166e70aca68a9c253d0ee6e6262ea55c1ef2d8c8", + "size_in_bytes": 13346 + }, + { + "_path": "site-packages/pygments/lexers/_qlik_builtins.py", + "path_type": "hardlink", + "sha256": "dd99024838edc52c570c8f5eae28164cb49472dfdaa7f5b42ea7d98c578a4182", + "size_in_bytes": 12598 + }, + { + "_path": "site-packages/pygments/lexers/_scheme_builtins.py", + "path_type": "hardlink", + "sha256": "3b7051b6de6cb931126d9fdb491790e83d2bd06fd2abf8b8c0271491d52b752d", + "size_in_bytes": 32567 + }, + { + "_path": "site-packages/pygments/lexers/_scilab_builtins.py", + "path_type": "hardlink", + "sha256": "137dd1d2692735cfb9799f5482eeeeec0bffbd4c40690a0c4ed771dcc71ecb15", + "size_in_bytes": 52414 + }, + { + "_path": "site-packages/pygments/lexers/_sourcemod_builtins.py", + "path_type": "hardlink", + "sha256": "f2ab292f108bb1f37d27b37449665136cd00faa24e20644100968d31e59a3814", + "size_in_bytes": 26780 + }, + { + "_path": "site-packages/pygments/lexers/_sql_builtins.py", + "path_type": "hardlink", + "sha256": "7cba61a2707ac2fe8e8adf336a7262131811a0bbd9a055b897d94d1fe3d362fc", + "size_in_bytes": 6770 + }, + { + "_path": "site-packages/pygments/lexers/_stan_builtins.py", + "path_type": "hardlink", + "sha256": "b08a0e360e138cb90637b01bd2d641d4733bb50d3bd7f676738d67f655d9974e", + "size_in_bytes": 16623 + }, + { + "_path": "site-packages/pygments/lexers/_stata_builtins.py", + "path_type": "hardlink", + "sha256": "ca687c1b111c6ba7920a01e7aac2eab22f4eadf46a627b793bcc817a29c9ec31", + "size_in_bytes": 27230 + }, + { + "_path": "site-packages/pygments/lexers/_tsql_builtins.py", + "path_type": "hardlink", + "sha256": "330e949cc0728eed14f8e0604fc69fdc0e2eb5fad2d344e7e650e76b106d8fd7", + "size_in_bytes": 15463 + }, + { + "_path": "site-packages/pygments/lexers/_usd_builtins.py", + "path_type": "hardlink", + "sha256": "486a7f78f7f656e92dac5579f6ae9d7f8993cb1655ec0658b344c91525a80402", + "size_in_bytes": 1661 + }, + { + "_path": "site-packages/pygments/lexers/_vbscript_builtins.py", + "path_type": "hardlink", + "sha256": "4c5b72735d72be90ff3a536bac56dc08e26851891632adc47871c2a70ff324d7", + "size_in_bytes": 4228 + }, + { + "_path": "site-packages/pygments/lexers/_vim_builtins.py", + "path_type": "hardlink", + "sha256": "6c1ea474b14cdf7ba863eb00b6c46e5193a871c69ae200c0b1d160e16004b285", + "size_in_bytes": 57069 + }, + { + "_path": "site-packages/pygments/lexers/actionscript.py", + "path_type": "hardlink", + "sha256": "91b1e1a0397b26357344432fd54bb160144968faf11c39261000b908e98e215c", + "size_in_bytes": 11737 + }, + { + "_path": "site-packages/pygments/lexers/ada.py", + "path_type": "hardlink", + "sha256": "9b63bb758cc955cde2b9281a0be4e2f86877086f899a9662b7f0cf669bb52083", + "size_in_bytes": 5356 + }, + { + "_path": "site-packages/pygments/lexers/agile.py", + "path_type": "hardlink", + "sha256": "0eefaf8e719910f1ee138d17c5330ef972ede7aa5870868a200c48c1c607147d", + "size_in_bytes": 899 + }, + { + "_path": "site-packages/pygments/lexers/algebra.py", + "path_type": "hardlink", + "sha256": "da24121b17d5b815c11c025dcdb6cfbeda6f44e6137f17cc8af0da824f727e1f", + "size_in_bytes": 10032 + }, + { + "_path": "site-packages/pygments/lexers/ambient.py", + "path_type": "hardlink", + "sha256": "f0d93c597e2aac877dce3ff3823241b854f8d324171b6397c45861177474d20f", + "size_in_bytes": 2608 + }, + { + "_path": "site-packages/pygments/lexers/amdgpu.py", + "path_type": "hardlink", + "sha256": "28c0cb75bfb568af5125a36c4a43f2894dc3404fc7763045d296b0ff28893110", + "size_in_bytes": 1726 + }, + { + "_path": "site-packages/pygments/lexers/ampl.py", + "path_type": "hardlink", + "sha256": "20ab8c544e9a5ec6b84baaa9b9cfc3bc4b09989a722833606b4f413c52ef6310", + "size_in_bytes": 4179 + }, + { + "_path": "site-packages/pygments/lexers/apdlexer.py", + "path_type": "hardlink", + "sha256": "a6e4a92c159ebdc89273c1b4c20d98ff2408a0682a3deb345019291489aabcee", + "size_in_bytes": 30803 + }, + { + "_path": "site-packages/pygments/lexers/apl.py", + "path_type": "hardlink", + "sha256": "fa384f62c0554f87242fb0999ae90864d8bab5f68925b064dafbad95ddfbdabb", + "size_in_bytes": 3407 + }, + { + "_path": "site-packages/pygments/lexers/archetype.py", + "path_type": "hardlink", + "sha256": "6ee847d961edc41a30cbf283e523e6e6f807a662e828c755f6d80cb3f6c4e315", + "size_in_bytes": 11577 + }, + { + "_path": "site-packages/pygments/lexers/arrow.py", + "path_type": "hardlink", + "sha256": "7ba99bdc8c788cbed3306354a64f2245b272fd517b558d89d155249e5a3512f0", + "size_in_bytes": 3567 + }, + { + "_path": "site-packages/pygments/lexers/arturo.py", + "path_type": "hardlink", + "sha256": "1a492539a8842533b3f04d3377177f85dd735f0bfb958829f08265eee875de18", + "size_in_bytes": 11417 + }, + { + "_path": "site-packages/pygments/lexers/asc.py", + "path_type": "hardlink", + "sha256": "0af1528bb1580d6e9ebbee6888a19cd0c377685d575590e8148e7ede61e90439", + "size_in_bytes": 1696 + }, + { + "_path": "site-packages/pygments/lexers/asm.py", + "path_type": "hardlink", + "sha256": "8c7277083b6f1e0bb8857e2456fbc9c9c8852d633a1406050cf1bfce3053cab7", + "size_in_bytes": 42219 + }, + { + "_path": "site-packages/pygments/lexers/asn1.py", + "path_type": "hardlink", + "sha256": "30b6a439e04591d84a2abe36787173a27a46213109c51fc6a1df2faa358fbdae", + "size_in_bytes": 4267 + }, + { + "_path": "site-packages/pygments/lexers/automation.py", + "path_type": "hardlink", + "sha256": "81d498b25916f6c6e50dcbcc78ad5acb5e6b6fdbd1b8ae7aa4f389cddc6522f8", + "size_in_bytes": 19834 + }, + { + "_path": "site-packages/pygments/lexers/bare.py", + "path_type": "hardlink", + "sha256": "01da8bf59db49ddd1b84d19689e94b8401de8fa57cffc9b539652408ead2071f", + "size_in_bytes": 3023 + }, + { + "_path": "site-packages/pygments/lexers/basic.py", + "path_type": "hardlink", + "sha256": "36a37121e1e18c152d7a7c02749f3c596104dcdedad7a0c0f60d7f0f599d985d", + "size_in_bytes": 27992 + }, + { + "_path": "site-packages/pygments/lexers/bdd.py", + "path_type": "hardlink", + "sha256": "29eb8ecd704b251c71336815eda32e62c755fda2451f206e17ca6d0695b10f93", + "size_in_bytes": 1644 + }, + { + "_path": "site-packages/pygments/lexers/berry.py", + "path_type": "hardlink", + "sha256": "bc87d3e2c06d9ba6a8eb859d364253549992d3406215d116bdbde86c15c1797f", + "size_in_bytes": 3212 + }, + { + "_path": "site-packages/pygments/lexers/bibtex.py", + "path_type": "hardlink", + "sha256": "b207c5a97c8dc82c5138721ef02d20adeebdaf36c00c02e7a43b536aa1df49ab", + "size_in_bytes": 4814 + }, + { + "_path": "site-packages/pygments/lexers/blueprint.py", + "path_type": "hardlink", + "sha256": "756f8be5b148896c513c36ac85e7b610e6265c8447770b82675cb788df9aebfd", + "size_in_bytes": 6191 + }, + { + "_path": "site-packages/pygments/lexers/boa.py", + "path_type": "hardlink", + "sha256": "56a605d5883f5dd0c0e6d2bf122ba8d6bafb79d881b0a513a41eb1cdafc1e5de", + "size_in_bytes": 3924 + }, + { + "_path": "site-packages/pygments/lexers/bqn.py", + "path_type": "hardlink", + "sha256": "b1ee16d973ec3624f7eb3d009bd5f9178c8d2eb42f308e57f26898e91f5210cf", + "size_in_bytes": 3674 + }, + { + "_path": "site-packages/pygments/lexers/business.py", + "path_type": "hardlink", + "sha256": "3176289a342261a4e69d482343b2d4c63714d62da25438d97573d37aa3a50e33", + "size_in_bytes": 28348 + }, + { + "_path": "site-packages/pygments/lexers/c_cpp.py", + "path_type": "hardlink", + "sha256": "d95890a0b636d98eb17735c39b0cf7d2b31c8a3ec47a636ae2fa5312c7e5eec8", + "size_in_bytes": 18321 + }, + { + "_path": "site-packages/pygments/lexers/c_like.py", + "path_type": "hardlink", + "sha256": "ada7cb350a9c11b7fef7b5690ed48841949299d88c0f8a0161e12cec36720728", + "size_in_bytes": 32024 + }, + { + "_path": "site-packages/pygments/lexers/capnproto.py", + "path_type": "hardlink", + "sha256": "91cdeb4fde4691e426ad6d4b78fe473156fb364f2ca97916e8e26491620761b0", + "size_in_bytes": 2177 + }, + { + "_path": "site-packages/pygments/lexers/carbon.py", + "path_type": "hardlink", + "sha256": "fccfb461ba1f8d932b2486a25caa13eb0a64777ffa7c5abe39d499ed5f7ad48e", + "size_in_bytes": 3214 + }, + { + "_path": "site-packages/pygments/lexers/cddl.py", + "path_type": "hardlink", + "sha256": "ed6ae2daadb229ec56a34083eecd9cec0a0200c6ebc32104e9ffe0cf907ac756", + "size_in_bytes": 5079 + }, + { + "_path": "site-packages/pygments/lexers/chapel.py", + "path_type": "hardlink", + "sha256": "4af6573498a35b482b7854e80c7650d327a8e3fde78b24f1df5233ff22dcb5c9", + "size_in_bytes": 5159 + }, + { + "_path": "site-packages/pygments/lexers/clean.py", + "path_type": "hardlink", + "sha256": "fe85774db9aba65dd2d6984f312ea0c8c5b21991a3e96cb4abc69da5fe6fba76", + "size_in_bytes": 6421 + }, + { + "_path": "site-packages/pygments/lexers/codeql.py", + "path_type": "hardlink", + "sha256": "8405f9d6e59e1b9664f498574a73b13cc6b39c53a9697e199d91d9da4aeb3c69", + "size_in_bytes": 2579 + }, + { + "_path": "site-packages/pygments/lexers/comal.py", + "path_type": "hardlink", + "sha256": "d1f713c95e61dfaccf971a103d65867addb26988b91125e2169c7a11bb2a3f4d", + "size_in_bytes": 3182 + }, + { + "_path": "site-packages/pygments/lexers/compiled.py", + "path_type": "hardlink", + "sha256": "3d18a6cbb79bdb078fed7e9b12e933d496922ee4001133b7e0aee66872c66f10", + "size_in_bytes": 1429 + }, + { + "_path": "site-packages/pygments/lexers/configs.py", + "path_type": "hardlink", + "sha256": "603048595fd1d928916f409bc6897e4bc45189e0df020fd871385cd41999f742", + "size_in_bytes": 50925 + }, + { + "_path": "site-packages/pygments/lexers/console.py", + "path_type": "hardlink", + "sha256": "32b4c89170d843bd73d320dea706e93bd5b05cf4113c700500ebedfe782c7315", + "size_in_bytes": 4183 + }, + { + "_path": "site-packages/pygments/lexers/cplint.py", + "path_type": "hardlink", + "sha256": "c0fb3f661d0e276fd451e17dfe6bbfafe5ffeb90c94963024ca3a63b28d62f3f", + "size_in_bytes": 1392 + }, + { + "_path": "site-packages/pygments/lexers/crystal.py", + "path_type": "hardlink", + "sha256": "93c5f2f13a5f18a4cfbec3f55a293120b49c20b0fc897679a9c78b668a6c2d81", + "size_in_bytes": 15757 + }, + { + "_path": "site-packages/pygments/lexers/csound.py", + "path_type": "hardlink", + "sha256": "eca1e826ff30b6e21ef5daae7ace261459102d42dc190db776067f2817747ff9", + "size_in_bytes": 17001 + }, + { + "_path": "site-packages/pygments/lexers/css.py", + "path_type": "hardlink", + "sha256": "3958ec7742a7f69347ea296d4b88a48f2f679e294f942571f95019dba9f7509f", + "size_in_bytes": 26439 + }, + { + "_path": "site-packages/pygments/lexers/d.py", + "path_type": "hardlink", + "sha256": "79ee682263f505c1d867ddd4c17a07233c3a073b604775820afde4b2ed89fa8d", + "size_in_bytes": 9923 + }, + { + "_path": "site-packages/pygments/lexers/dalvik.py", + "path_type": "hardlink", + "sha256": "d1fe66079cbc834975203da5889ff9a8cd8d8f247f481b3b724b880de35b6e3f", + "size_in_bytes": 4609 + }, + { + "_path": "site-packages/pygments/lexers/data.py", + "path_type": "hardlink", + "sha256": "3212d7a195d831916698a96a2fc455e73a7e794c156f4c85ceccb35d8ae92a2c", + "size_in_bytes": 27049 + }, + { + "_path": "site-packages/pygments/lexers/dax.py", + "path_type": "hardlink", + "sha256": "37ee5fc6e9017c5b45093d8b268ca0d5526c7e57561f15ca2d8dd93cb9cfae28", + "size_in_bytes": 8101 + }, + { + "_path": "site-packages/pygments/lexers/devicetree.py", + "path_type": "hardlink", + "sha256": "4e283eb534aba661b36c6c4dda46b830c4e20b7e38ae86aff40e21a1cf68fe4c", + "size_in_bytes": 4826 + }, + { + "_path": "site-packages/pygments/lexers/diff.py", + "path_type": "hardlink", + "sha256": "fbadbb966b98a49dae51550cfe8ad51a05c91972011925476e696a7e508479a3", + "size_in_bytes": 5385 + }, + { + "_path": "site-packages/pygments/lexers/dns.py", + "path_type": "hardlink", + "sha256": "125cd2377204a11b3583a896327cd5215f07d31f56484175c018e6d9ad01cb11", + "size_in_bytes": 3894 + }, + { + "_path": "site-packages/pygments/lexers/dotnet.py", + "path_type": "hardlink", + "sha256": "1a6a1a3b14a821391874051a549d19d5141ae8cbdc471875810dd7c6012ce17f", + "size_in_bytes": 39444 + }, + { + "_path": "site-packages/pygments/lexers/dsls.py", + "path_type": "hardlink", + "sha256": "6ba25dbf7c35685defa5026b9c5df630d1c097aa4466491e181d5c62ffb1d87c", + "size_in_bytes": 36753 + }, + { + "_path": "site-packages/pygments/lexers/dylan.py", + "path_type": "hardlink", + "sha256": "7e2f264b29e2e1d9c63f9c7572b13a04a36a2d626ce1d0d676692eafe4db6cd7", + "size_in_bytes": 10412 + }, + { + "_path": "site-packages/pygments/lexers/ecl.py", + "path_type": "hardlink", + "sha256": "5c9eba3d4f448e45c9c00e1fd4e7c2d1175f3f8f6ff0deb64595e715554060da", + "size_in_bytes": 6374 + }, + { + "_path": "site-packages/pygments/lexers/eiffel.py", + "path_type": "hardlink", + "sha256": "9b67953c31bd27e55789e09e3b2d12ef31cf8e2147401f45e9b388cbe2b73034", + "size_in_bytes": 2693 + }, + { + "_path": "site-packages/pygments/lexers/elm.py", + "path_type": "hardlink", + "sha256": "5e3dc795b51312411417085e9b8342ba3c79e6d4364d2eb5fca71fe8108f1c02", + "size_in_bytes": 3155 + }, + { + "_path": "site-packages/pygments/lexers/elpi.py", + "path_type": "hardlink", + "sha256": "459a805737717c0fc1a819ad3078fc013c397fd7b6e1228bf9078ed7842e2a4e", + "size_in_bytes": 7904 + }, + { + "_path": "site-packages/pygments/lexers/email.py", + "path_type": "hardlink", + "sha256": "34f9467362fa177296583a29dd93891a950ce8b0e7384a8a663d58246def3f63", + "size_in_bytes": 4807 + }, + { + "_path": "site-packages/pygments/lexers/erlang.py", + "path_type": "hardlink", + "sha256": "d9a525541545b50751d90212b0378a4ce3e31ab57baf5724c972f5eca268b7d7", + "size_in_bytes": 19150 + }, + { + "_path": "site-packages/pygments/lexers/esoteric.py", + "path_type": "hardlink", + "sha256": "b6627d3dad7062d62047ac83aa0a77cc362e5cf1735f0ed22d31ce1ff784de9d", + "size_in_bytes": 10503 + }, + { + "_path": "site-packages/pygments/lexers/ezhil.py", + "path_type": "hardlink", + "sha256": "b5b198b469ea64007c7df9f23dd78c3091ed29827b38072250546b47ff10a573", + "size_in_bytes": 3275 + }, + { + "_path": "site-packages/pygments/lexers/factor.py", + "path_type": "hardlink", + "sha256": "1c152a35cc1de15a65630df449cb82f1881d8a9140622aa34605acc93d2ce314", + "size_in_bytes": 19533 + }, + { + "_path": "site-packages/pygments/lexers/fantom.py", + "path_type": "hardlink", + "sha256": "c3d214d71eb50a875decec6fe43a6f5659153e7fdb7ef54b88ff007b7ebad333", + "size_in_bytes": 10234 + }, + { + "_path": "site-packages/pygments/lexers/felix.py", + "path_type": "hardlink", + "sha256": "0ef3ceb3f126e9f16d5014026995961d6827bc015e06b0def7b0b2f57c90f29b", + "size_in_bytes": 9658 + }, + { + "_path": "site-packages/pygments/lexers/fift.py", + "path_type": "hardlink", + "sha256": "43d38b262be9e2782a16ca3b00f0af5fce61fa085d6e9f59aa93fc18a1f0b353", + "size_in_bytes": 1647 + }, + { + "_path": "site-packages/pygments/lexers/floscript.py", + "path_type": "hardlink", + "sha256": "4dccae0a2bfd6c06fcf71d7feff66aea7521b1db07005d833ec299ea6d56d4d5", + "size_in_bytes": 2670 + }, + { + "_path": "site-packages/pygments/lexers/forth.py", + "path_type": "hardlink", + "sha256": "e1ed0e09f24670496442b1c89e640cb9cbec23d7658ee3f1e05620dfc7728e7a", + "size_in_bytes": 7196 + }, + { + "_path": "site-packages/pygments/lexers/fortran.py", + "path_type": "hardlink", + "sha256": "a2ebce1dd31b8f9ea3e3436b8f6d560917f8acd2a9bb0a61c66b65515b27ce17", + "size_in_bytes": 10385 + }, + { + "_path": "site-packages/pygments/lexers/foxpro.py", + "path_type": "hardlink", + "sha256": "9d5f32c844b7f50a0599336533cc65dccb5e3acbe6b7ac95d65eb1eb19d7a885", + "size_in_bytes": 26298 + }, + { + "_path": "site-packages/pygments/lexers/freefem.py", + "path_type": "hardlink", + "sha256": "66664b2182d7b422b6916a86cc19ab929ef27213b2eef81f6a8ada7d49149752", + "size_in_bytes": 26916 + }, + { + "_path": "site-packages/pygments/lexers/func.py", + "path_type": "hardlink", + "sha256": "66339eae3de78c971a1a71d673f9e95a3c5be03e4efae7710512bb44b1c489b5", + "size_in_bytes": 3703 + }, + { + "_path": "site-packages/pygments/lexers/functional.py", + "path_type": "hardlink", + "sha256": "e26f499409dfa57c52910408acd3a86f6553c229fa84f2c0a96ba1bfd6959008", + "size_in_bytes": 697 + }, + { + "_path": "site-packages/pygments/lexers/futhark.py", + "path_type": "hardlink", + "sha256": "982536caf968245e4b37bb9113ff2b095a80f07008367cb4e075d5c634a23388", + "size_in_bytes": 3746 + }, + { + "_path": "site-packages/pygments/lexers/gcodelexer.py", + "path_type": "hardlink", + "sha256": "b7c24c59a6838d66707468911b0ae9b18b5f8ca4e689bc2547238b0a2259f2ac", + "size_in_bytes": 877 + }, + { + "_path": "site-packages/pygments/lexers/gdscript.py", + "path_type": "hardlink", + "sha256": "54d3b077b29c0d112fa0101fc3ae868f1c50ca03ec1c7d9a91dcd16cf34aaa84", + "size_in_bytes": 7569 + }, + { + "_path": "site-packages/pygments/lexers/gleam.py", + "path_type": "hardlink", + "sha256": "271e8b9d4a5657da668dd4982d432dd7a73751a999fafe57e8272e1215b17fef", + "size_in_bytes": 2395 + }, + { + "_path": "site-packages/pygments/lexers/go.py", + "path_type": "hardlink", + "sha256": "ca71d54adc365d42459548934b852a63ae5f2e4bdc24130dce862d48d4a5fc15", + "size_in_bytes": 3786 + }, + { + "_path": "site-packages/pygments/lexers/grammar_notation.py", + "path_type": "hardlink", + "sha256": "64661cc214af3a8970d49edc03d3dcee1569708b1e95a0a0c70b2f01fe724607", + "size_in_bytes": 8046 + }, + { + "_path": "site-packages/pygments/lexers/graph.py", + "path_type": "hardlink", + "sha256": "5ff22c763c57667e69f43ab870b5f2ab0a380bc7a671803c34fe9567d65305a5", + "size_in_bytes": 4111 + }, + { + "_path": "site-packages/pygments/lexers/graphics.py", + "path_type": "hardlink", + "sha256": "21eaeec6f1104755acbbe6322e90239149e2b0b0f352b93671dd315eb0c26e3c", + "size_in_bytes": 39148 + }, + { + "_path": "site-packages/pygments/lexers/graphql.py", + "path_type": "hardlink", + "sha256": "45613f91f5540c4027bfff926323a2f4825492ceb536f39a92651f58e968af3a", + "size_in_bytes": 5604 + }, + { + "_path": "site-packages/pygments/lexers/graphviz.py", + "path_type": "hardlink", + "sha256": "0d1356c1eb4459ab090ed88b91daa42ac4070ebc89e56f34c140f63c4ea8282b", + "size_in_bytes": 1937 + }, + { + "_path": "site-packages/pygments/lexers/gsql.py", + "path_type": "hardlink", + "sha256": "a734a3e4f778bed34b112fa921dc5a1b4bce553a94584f54b8e530d11ad8fa87", + "size_in_bytes": 3993 + }, + { + "_path": "site-packages/pygments/lexers/hare.py", + "path_type": "hardlink", + "sha256": "782ad13f072cc172fe6474d6365844d40d391bdaf1cd2db4fc8a9275dbf633d6", + "size_in_bytes": 2652 + }, + { + "_path": "site-packages/pygments/lexers/haskell.py", + "path_type": "hardlink", + "sha256": "b2be60ab753bc6dd03d818b8d71753b016a9a275faa2d3f5a8fc91302bb133b1", + "size_in_bytes": 33323 + }, + { + "_path": "site-packages/pygments/lexers/haxe.py", + "path_type": "hardlink", + "sha256": "fcccd02535b1d7c903f5b3ffb27881b2129bb4e643466e0e66789f68e830fda6", + "size_in_bytes": 31169 + }, + { + "_path": "site-packages/pygments/lexers/hdl.py", + "path_type": "hardlink", + "sha256": "da3617ddf45667d98067f404475587e7c4af25a39d610b743a63b1a375f624ad", + "size_in_bytes": 22741 + }, + { + "_path": "site-packages/pygments/lexers/hexdump.py", + "path_type": "hardlink", + "sha256": "56f629fcd4da13ee8d52e486e0531ecf0723c5b3e7033d1f396333af76361a6e", + "size_in_bytes": 3656 + }, + { + "_path": "site-packages/pygments/lexers/html.py", + "path_type": "hardlink", + "sha256": "3baaa4a723b2947da7d598b5ab396606c2045b7d517efcc19fb8ca4da011d8b4", + "size_in_bytes": 21999 + }, + { + "_path": "site-packages/pygments/lexers/idl.py", + "path_type": "hardlink", + "sha256": "5b64111f58fd2cc68dbc2e636fa3243f874b628fce414ea5425080950bde147e", + "size_in_bytes": 15452 + }, + { + "_path": "site-packages/pygments/lexers/igor.py", + "path_type": "hardlink", + "sha256": "4afe4418125e2b2d143b297af8617794179ea1602b55c30326d42d976457458a", + "size_in_bytes": 31636 + }, + { + "_path": "site-packages/pygments/lexers/inferno.py", + "path_type": "hardlink", + "sha256": "72354cc8e83a8e127a9d85f7df767a29a082792d293551efe164f1c85198f138", + "size_in_bytes": 3138 + }, + { + "_path": "site-packages/pygments/lexers/installers.py", + "path_type": "hardlink", + "sha256": "8a82b62543d2264f6f72ca1edcd012bccb7ea5a5ddd7f367ddef1699aa89ec21", + "size_in_bytes": 14494 + }, + { + "_path": "site-packages/pygments/lexers/int_fiction.py", + "path_type": "hardlink", + "sha256": "0548ef5e29548ae305f9eb971100f3419b38e639ff68bb35ede4ca71f129b6b2", + "size_in_bytes": 56547 + }, + { + "_path": "site-packages/pygments/lexers/iolang.py", + "path_type": "hardlink", + "sha256": "90c50152a56f747941efd7b3d291593d17f43608840b649db585307639db13dd", + "size_in_bytes": 1908 + }, + { + "_path": "site-packages/pygments/lexers/j.py", + "path_type": "hardlink", + "sha256": "e7aa946ecd42ef029d67af96a4d9f11e7b4daacc56ae8aa23bb91e236ca8475a", + "size_in_bytes": 4856 + }, + { + "_path": "site-packages/pygments/lexers/javascript.py", + "path_type": "hardlink", + "sha256": "9aec82559400b176e14fb207664a2a0242399b2851687cdee89300478cc82cdb", + "size_in_bytes": 63246 + }, + { + "_path": "site-packages/pygments/lexers/jmespath.py", + "path_type": "hardlink", + "sha256": "ef6e8f0e946bd60d8acbfc79a5939185b5e87d7c647ebe475d0f1e1cc857e718", + "size_in_bytes": 2085 + }, + { + "_path": "site-packages/pygments/lexers/jslt.py", + "path_type": "hardlink", + "sha256": "50e570d49dee2be855456a26a052b68cc4bfc9eba8e62aa06be2e15d4248ebad", + "size_in_bytes": 3703 + }, + { + "_path": "site-packages/pygments/lexers/json5.py", + "path_type": "hardlink", + "sha256": "1b2799e7c0312a42498a21fb26e3e66a40d95eba296ba6c3905460b891e27ea5", + "size_in_bytes": 2505 + }, + { + "_path": "site-packages/pygments/lexers/jsonnet.py", + "path_type": "hardlink", + "sha256": "fd3ed8d7ab16ee716e028185bb2594282ad4c89002e054d6655a1e4add264d79", + "size_in_bytes": 5639 + }, + { + "_path": "site-packages/pygments/lexers/jsx.py", + "path_type": "hardlink", + "sha256": "3b47af1e2a32b9db562e156601746b21f9047792918a89201eef25f7f2a7f2c3", + "size_in_bytes": 2696 + }, + { + "_path": "site-packages/pygments/lexers/julia.py", + "path_type": "hardlink", + "sha256": "174b70320d222c134375e76ca091b8467e4ba0c72256ef5cb9fc9455dc4a40f6", + "size_in_bytes": 11713 + }, + { + "_path": "site-packages/pygments/lexers/jvm.py", + "path_type": "hardlink", + "sha256": "71fe55ecd38b22f076b3b44cf708211126110a8083cab1a346e3e663c6df180c", + "size_in_bytes": 72936 + }, + { + "_path": "site-packages/pygments/lexers/kuin.py", + "path_type": "hardlink", + "sha256": "9f694c8a76bc4ac9297c0d8a6cf6101705493921e0358bb5d14e69cf96226a31", + "size_in_bytes": 11408 + }, + { + "_path": "site-packages/pygments/lexers/kusto.py", + "path_type": "hardlink", + "sha256": "a7251f58b7fd434430aaeef80f23c06d1876d2590f0cb8719c4c43d45565f19e", + "size_in_bytes": 3480 + }, + { + "_path": "site-packages/pygments/lexers/ldap.py", + "path_type": "hardlink", + "sha256": "ff26b8fc89e7488463f9162319a816159243cb535d810528710cd55a3891a7af", + "size_in_bytes": 6554 + }, + { + "_path": "site-packages/pygments/lexers/lean.py", + "path_type": "hardlink", + "sha256": "a8ffe2c1443b3096750b9b37298056f16bbafaeb958f83c01b76b61a18e9f7d5", + "size_in_bytes": 8588 + }, + { + "_path": "site-packages/pygments/lexers/lilypond.py", + "path_type": "hardlink", + "sha256": "a36eb8a2f19916b731f19c292915fe82350408ad70e53f13d27e8ba138cff765", + "size_in_bytes": 9755 + }, + { + "_path": "site-packages/pygments/lexers/lisp.py", + "path_type": "hardlink", + "sha256": "6b9306726b6b59369e123ff952ff1830e0ebddd555eacd6fd7f48c061fc287d4", + "size_in_bytes": 157903 + }, + { + "_path": "site-packages/pygments/lexers/macaulay2.py", + "path_type": "hardlink", + "sha256": "84b343b354ddb9bb9dbeaaa8bd837a6b835ef498e753816f344e8413684f9fc4", + "size_in_bytes": 34139 + }, + { + "_path": "site-packages/pygments/lexers/make.py", + "path_type": "hardlink", + "sha256": "c005742914574c014c9622df00a5c38a1408136540554bd68c567ecae33b6b4f", + "size_in_bytes": 7834 + }, + { + "_path": "site-packages/pygments/lexers/maple.py", + "path_type": "hardlink", + "sha256": "3818ce0cd2e0a9a9f2c39db6084ee7f6d85972d5a2e3b52e6b684f05f8fb285e", + "size_in_bytes": 7963 + }, + { + "_path": "site-packages/pygments/lexers/markup.py", + "path_type": "hardlink", + "sha256": "e133117ee8d7bce13dc625b04e24ff7ead656aee1d292a1761a73585630b611b", + "size_in_bytes": 65264 + }, + { + "_path": "site-packages/pygments/lexers/math.py", + "path_type": "hardlink", + "sha256": "36ca65e8866d0b287d7a089851a85ba164a6cb8709095654071c959c2b85d5a8", + "size_in_bytes": 698 + }, + { + "_path": "site-packages/pygments/lexers/matlab.py", + "path_type": "hardlink", + "sha256": "418541740f8844d72e5a080124d0bd969ab78e05ffd70f46430a6ff74ed57d93", + "size_in_bytes": 133030 + }, + { + "_path": "site-packages/pygments/lexers/maxima.py", + "path_type": "hardlink", + "sha256": "85af9ff89cc692382002be64c6656aeffb894c27291ecb505a7b0b1d82213705", + "size_in_bytes": 2718 + }, + { + "_path": "site-packages/pygments/lexers/meson.py", + "path_type": "hardlink", + "sha256": "669355a7b9521f0247123ee9c17946732f4b7ed75ce8c3202623a86364e77ccf", + "size_in_bytes": 4345 + }, + { + "_path": "site-packages/pygments/lexers/mime.py", + "path_type": "hardlink", + "sha256": "97906c16469ddda809e8a0e0fc81c8ea7534028d18f447308d8a183fcbd00fe8", + "size_in_bytes": 7585 + }, + { + "_path": "site-packages/pygments/lexers/minecraft.py", + "path_type": "hardlink", + "sha256": "6c16cc6eabec5604df3bb081c5fd37a063ffa8e020af0d3a3d2cc7d5017bb71b", + "size_in_bytes": 13701 + }, + { + "_path": "site-packages/pygments/lexers/mips.py", + "path_type": "hardlink", + "sha256": "429801a0c3f3b24d6df747081745bf115f9067c2f08136a94be7d2212c597057", + "size_in_bytes": 4659 + }, + { + "_path": "site-packages/pygments/lexers/ml.py", + "path_type": "hardlink", + "sha256": "b210cf8160114f34c48460de6e557b656da3eb2644781898ab1db3db84833fb0", + "size_in_bytes": 35393 + }, + { + "_path": "site-packages/pygments/lexers/modeling.py", + "path_type": "hardlink", + "sha256": "dbfb9c545cbb678ca82b1f7413df80488f6de2dd4b228790df21daae1821cfe7", + "size_in_bytes": 13764 + }, + { + "_path": "site-packages/pygments/lexers/modula2.py", + "path_type": "hardlink", + "sha256": "7575b428d16edc44e0001b0f32c2217492340ca17e296b53f37d452accf6557c", + "size_in_bytes": 53075 + }, + { + "_path": "site-packages/pygments/lexers/mojo.py", + "path_type": "hardlink", + "sha256": "8a63a583c9900a82b08bfaecb8c8a27d9af3b00b12a93d8a7240acfcc579b951", + "size_in_bytes": 24236 + }, + { + "_path": "site-packages/pygments/lexers/monte.py", + "path_type": "hardlink", + "sha256": "253c7e8d2ac52a5591c00d6ace13ddeb8ec44c648497084fe1832556b7d7c97f", + "size_in_bytes": 6292 + }, + { + "_path": "site-packages/pygments/lexers/mosel.py", + "path_type": "hardlink", + "sha256": "1c460e9998803617bd55d913a41b7b9a13e2fed3c6054915b27cd38761d57552", + "size_in_bytes": 9300 + }, + { + "_path": "site-packages/pygments/lexers/ncl.py", + "path_type": "hardlink", + "sha256": "4595e4c4e2be887b292d7fec1554f4c1ce47eaffa96b890a8213fbf5f24640f4", + "size_in_bytes": 64002 + }, + { + "_path": "site-packages/pygments/lexers/nimrod.py", + "path_type": "hardlink", + "sha256": "2fc5b0e4251a3fea23cb0a106579e30b4f26e417bae1f0729d27f969618868fc", + "size_in_bytes": 6416 + }, + { + "_path": "site-packages/pygments/lexers/nit.py", + "path_type": "hardlink", + "sha256": "c70bb63f8f47bbc63110bee6829579596170e8e605d62260f4356773b1f54979", + "size_in_bytes": 2728 + }, + { + "_path": "site-packages/pygments/lexers/nix.py", + "path_type": "hardlink", + "sha256": "33613e93ef85ee99deb8c00e69ef5a838b2b26c2a1589d5fd5f46e78ee8fb4a3", + "size_in_bytes": 4424 + }, + { + "_path": "site-packages/pygments/lexers/numbair.py", + "path_type": "hardlink", + "sha256": "2993b0f7a4e3ec6972f9ff45f0d03eb5d19de77488b795206e9a2466c7e7cd63", + "size_in_bytes": 1761 + }, + { + "_path": "site-packages/pygments/lexers/oberon.py", + "path_type": "hardlink", + "sha256": "b87d4590f79709f75dd0843ffbe4bc48750d69fd9d9e3890663b484fe8f1bb80", + "size_in_bytes": 4216 + }, + { + "_path": "site-packages/pygments/lexers/objective.py", + "path_type": "hardlink", + "sha256": "28c13e27450bd87258024d9f1cd85fec0a507b85c5f061faa863af600d703d2e", + "size_in_bytes": 23300 + }, + { + "_path": "site-packages/pygments/lexers/ooc.py", + "path_type": "hardlink", + "sha256": "1c48d61dd403564eed45bfd3b846f5fc2e6a8bea5e270c3260154085fe3d312d", + "size_in_bytes": 3005 + }, + { + "_path": "site-packages/pygments/lexers/openscad.py", + "path_type": "hardlink", + "sha256": "b5eda22fc5647d7ba5fcf617973f142b7fd0b4c8dd98d82dd181c2604bdd12d3", + "size_in_bytes": 3703 + }, + { + "_path": "site-packages/pygments/lexers/other.py", + "path_type": "hardlink", + "sha256": "380957cecad50d4c7831adb97f21bdf14e4b681107cadf8b259d881ef3092566", + "size_in_bytes": 1766 + }, + { + "_path": "site-packages/pygments/lexers/parasail.py", + "path_type": "hardlink", + "sha256": "a0f72cedf4583645748ac3d2466c3ed9c3df320cd3b4d3e2e9b24e9bbbeafbda", + "size_in_bytes": 2722 + }, + { + "_path": "site-packages/pygments/lexers/parsers.py", + "path_type": "hardlink", + "sha256": "838b55bdfdfaca14ff687fdbef7ee8d28d63a288dc7fe5dc903d8774da0d6ec4", + "size_in_bytes": 26598 + }, + { + "_path": "site-packages/pygments/lexers/pascal.py", + "path_type": "hardlink", + "sha256": "e1d7b05e4c1cd767ff8a231f74d0ea6f16ffa2a0045f6742cdbe55219eb6579e", + "size_in_bytes": 30992 + }, + { + "_path": "site-packages/pygments/lexers/pawn.py", + "path_type": "hardlink", + "sha256": "69db1afbbb0fb8f93b98eee5074f1ab9a6c4a5e65d35ec15a93060e854bc9829", + "size_in_bytes": 8256 + }, + { + "_path": "site-packages/pygments/lexers/pddl.py", + "path_type": "hardlink", + "sha256": "6bc03691e085f6a350bd56508ab8015797c7e2eddc8ebb5af3e79927cb6cc666", + "size_in_bytes": 2992 + }, + { + "_path": "site-packages/pygments/lexers/perl.py", + "path_type": "hardlink", + "sha256": "b98323e9a9993dac0b7fe2a320283d2cb539f800cacea1182aa8bb5579ef9b49", + "size_in_bytes": 39195 + }, + { + "_path": "site-packages/pygments/lexers/phix.py", + "path_type": "hardlink", + "sha256": "9c4596b79f8ea080daa70e0827f70d2f5f5387c66db7a3884207aea2055e775d", + "size_in_bytes": 23252 + }, + { + "_path": "site-packages/pygments/lexers/php.py", + "path_type": "hardlink", + "sha256": "53ac26c4f33ea52f92635377a9dbf479b5030712c7ebe10520571ab54be0ef8c", + "size_in_bytes": 13171 + }, + { + "_path": "site-packages/pygments/lexers/pointless.py", + "path_type": "hardlink", + "sha256": "80d72e861398f5c12920fc86163321d8322d341d540fc0a68dc79790344ca1d1", + "size_in_bytes": 1977 + }, + { + "_path": "site-packages/pygments/lexers/pony.py", + "path_type": "hardlink", + "sha256": "1caa9fe409e050e75737537556f4a0d234e3dcd500cc604e3dd5f04856a6be63", + "size_in_bytes": 3282 + }, + { + "_path": "site-packages/pygments/lexers/praat.py", + "path_type": "hardlink", + "sha256": "b1f54077bcdf46c23e4dc0a8bae60c5a5714f04071030278c2487466e36c677e", + "size_in_bytes": 12679 + }, + { + "_path": "site-packages/pygments/lexers/procfile.py", + "path_type": "hardlink", + "sha256": "7e1453b6c73230c3dc3dbbf38f156d5e2c759989693bee09b9650bec36f810d2", + "size_in_bytes": 1158 + }, + { + "_path": "site-packages/pygments/lexers/prolog.py", + "path_type": "hardlink", + "sha256": "e18bcf65b0052d635931b661bed22e95689bd0f40b03f4c1f7782390dcb01510", + "size_in_bytes": 12869 + }, + { + "_path": "site-packages/pygments/lexers/promql.py", + "path_type": "hardlink", + "sha256": "d387d2fd1e8705686928d7b758fa7f417808745bc9af9a7a2b14ad658c3bc875", + "size_in_bytes": 4741 + }, + { + "_path": "site-packages/pygments/lexers/prql.py", + "path_type": "hardlink", + "sha256": "5c985df1da4458f0482a6417c7fd3dfb3d4dca8b4b5c8b24a6ecd7dfa1f2907a", + "size_in_bytes": 8750 + }, + { + "_path": "site-packages/pygments/lexers/ptx.py", + "path_type": "hardlink", + "sha256": "74468d4917808c0ca623054cfcc9db758e217779ae2bbf6adb4d2163037bd9cc", + "size_in_bytes": 4504 + }, + { + "_path": "site-packages/pygments/lexers/python.py", + "path_type": "hardlink", + "sha256": "efd03fc89aa3547a7f65e4b5ad8f0f71ce1cc19ffbfb323659691e52666052b0", + "size_in_bytes": 54202 + }, + { + "_path": "site-packages/pygments/lexers/q.py", + "path_type": "hardlink", + "sha256": "d826c962046ef2ecfcc0e4a9e4532bd3ce8a082ec88d246620e0d5634b8aac20", + "size_in_bytes": 6939 + }, + { + "_path": "site-packages/pygments/lexers/qlik.py", + "path_type": "hardlink", + "sha256": "f5be90fba8d779eada211716b6c2ac61608e94185f9a337320de3da54bcc47e2", + "size_in_bytes": 3696 + }, + { + "_path": "site-packages/pygments/lexers/qvt.py", + "path_type": "hardlink", + "sha256": "ae94f9a03e1ac0428cb37b8109b365cd8d730b3ec055ea8cf818a42d3407a3c9", + "size_in_bytes": 6106 + }, + { + "_path": "site-packages/pygments/lexers/r.py", + "path_type": "hardlink", + "sha256": "873814507f600acaaac131bd782b7525531df515b4772e8863f8d3bd19ed17e5", + "size_in_bytes": 6477 + }, + { + "_path": "site-packages/pygments/lexers/rdf.py", + "path_type": "hardlink", + "sha256": "14cd79e1f0759717cea52a5e5ba6d639595de64241804b98c93f6e76df8470ad", + "size_in_bytes": 16063 + }, + { + "_path": "site-packages/pygments/lexers/rebol.py", + "path_type": "hardlink", + "sha256": "090de931a033eb850caa2415ad8a111273a08d4e503de17f1f769a1cd755442f", + "size_in_bytes": 18262 + }, + { + "_path": "site-packages/pygments/lexers/rego.py", + "path_type": "hardlink", + "sha256": "622d06e2c79c4d638bec25212cb0b327d800e922730c9a4f24d8a3de15e2c42d", + "size_in_bytes": 1751 + }, + { + "_path": "site-packages/pygments/lexers/rell.py", + "path_type": "hardlink", + "sha256": "d20652b48f79dda16314cc8c557fd429fc199b3577ba3dd39e5ff9176d013f1d", + "size_in_bytes": 2487 + }, + { + "_path": "site-packages/pygments/lexers/resource.py", + "path_type": "hardlink", + "sha256": "443118ee24afda1810dd5f88d4378e2953ae98d2a016a6d5d8c7bff58db5a35d", + "size_in_bytes": 2930 + }, + { + "_path": "site-packages/pygments/lexers/ride.py", + "path_type": "hardlink", + "sha256": "d7383b90660f29121e932b996377fa395a91957cab5feb11fad1c45f533d9f3e", + "size_in_bytes": 5038 + }, + { + "_path": "site-packages/pygments/lexers/rita.py", + "path_type": "hardlink", + "sha256": "7c234494f8a4e9d0c867319df7a90a81d958e10aa9ff3548f3bc1a4c11cc05f8", + "size_in_bytes": 1130 + }, + { + "_path": "site-packages/pygments/lexers/rnc.py", + "path_type": "hardlink", + "sha256": "3cd7e79d396766336fbc6df704d302a8fcdd03d2d9118bc3b06a1a0ddff69a7f", + "size_in_bytes": 1975 + }, + { + "_path": "site-packages/pygments/lexers/roboconf.py", + "path_type": "hardlink", + "sha256": "97a05e2484be64051bdf3739184b9521bd1e76b4693c598a75f7c4071ef86718", + "size_in_bytes": 2077 + }, + { + "_path": "site-packages/pygments/lexers/robotframework.py", + "path_type": "hardlink", + "sha256": "f2cd54ec695d87344f191eddf3facc486d19273f593a6f8b1aa0531882f0b765", + "size_in_bytes": 18451 + }, + { + "_path": "site-packages/pygments/lexers/ruby.py", + "path_type": "hardlink", + "sha256": "0719dd1bede02e0ef0106bc80a234300cca0411f50b34c6b9aaec3c1fa0bbccb", + "size_in_bytes": 22756 + }, + { + "_path": "site-packages/pygments/lexers/rust.py", + "path_type": "hardlink", + "sha256": "eea0f7286562afeb5459ffdb3c1b78117f25f5a2167bc4db94c08523be68a2b7", + "size_in_bytes": 8263 + }, + { + "_path": "site-packages/pygments/lexers/sas.py", + "path_type": "hardlink", + "sha256": "f6198662198aa3bae2f680a665db28105333eb3dc0c0a0f82dc4d4227e769585", + "size_in_bytes": 9459 + }, + { + "_path": "site-packages/pygments/lexers/savi.py", + "path_type": "hardlink", + "sha256": "1c29658017b7af33ffefed9bd6149411b136758cf4f08cacc5ce837318f77f67", + "size_in_bytes": 4881 + }, + { + "_path": "site-packages/pygments/lexers/scdoc.py", + "path_type": "hardlink", + "sha256": "f67eb84be6ced5d238c7ed8ace1da3ac333a804981e5823b721ea774f078f9cc", + "size_in_bytes": 2527 + }, + { + "_path": "site-packages/pygments/lexers/scripting.py", + "path_type": "hardlink", + "sha256": "73e8bf70c1616041d06596cb8099f48f2883e76bd679957150aeb0155d8589be", + "size_in_bytes": 82959 + }, + { + "_path": "site-packages/pygments/lexers/sgf.py", + "path_type": "hardlink", + "sha256": "c9afec1b84cebc35b0cc433a7088b8d1749b8644ee1c2aafa3eb879cd61f8b94", + "size_in_bytes": 1988 + }, + { + "_path": "site-packages/pygments/lexers/shell.py", + "path_type": "hardlink", + "sha256": "b22e8c027e92ee91dfc97eb9364c10763c6d2ed12ed4ce25ecada5507bf2cd6c", + "size_in_bytes": 36384 + }, + { + "_path": "site-packages/pygments/lexers/sieve.py", + "path_type": "hardlink", + "sha256": "09747d4b59c67954e59f6bb947ad348718240262455554d34c187f9376b0fa99", + "size_in_bytes": 2517 + }, + { + "_path": "site-packages/pygments/lexers/slash.py", + "path_type": "hardlink", + "sha256": "9a8961e6c346f14b617877df4068e31cbc55b72836a02a7807c72f803c9fd34e", + "size_in_bytes": 8487 + }, + { + "_path": "site-packages/pygments/lexers/smalltalk.py", + "path_type": "hardlink", + "sha256": "ab9d8d1de825de98e7d6332425603d2749ce03f0395735142d900f81bfbab8d5", + "size_in_bytes": 7207 + }, + { + "_path": "site-packages/pygments/lexers/smithy.py", + "path_type": "hardlink", + "sha256": "86a1089a8e01fa2d2175d368d6bd24e5e1cb3a502bb515b85b93ec2c1765964e", + "size_in_bytes": 2662 + }, + { + "_path": "site-packages/pygments/lexers/smv.py", + "path_type": "hardlink", + "sha256": "0f9d489fd42bda758589c600397fdb2697858262770549045e7bd73e6034e03e", + "size_in_bytes": 2808 + }, + { + "_path": "site-packages/pygments/lexers/snobol.py", + "path_type": "hardlink", + "sha256": "057ff554f5198be724282625176b2db50a6b1766cb5073a2f1b961227147bfdb", + "size_in_bytes": 2781 + }, + { + "_path": "site-packages/pygments/lexers/solidity.py", + "path_type": "hardlink", + "sha256": "a73d03674c621f0b9f85b43d85d08fac732303b34cb1aea1c59d673be0386371", + "size_in_bytes": 3166 + }, + { + "_path": "site-packages/pygments/lexers/soong.py", + "path_type": "hardlink", + "sha256": "4d5a812732712f00840e66f9022c76fc056e6482d8c8f59c03315bcc834d4003", + "size_in_bytes": 2342 + }, + { + "_path": "site-packages/pygments/lexers/sophia.py", + "path_type": "hardlink", + "sha256": "3009162d8c611c935c737514cd60f75432f35516dfe8801ddaecf8abb0d8df02", + "size_in_bytes": 3379 + }, + { + "_path": "site-packages/pygments/lexers/special.py", + "path_type": "hardlink", + "sha256": "f20a5388b20214dc0871a866dbcda68bc36a8bfea0c1832c01f8c920cd81aba9", + "size_in_bytes": 3588 + }, + { + "_path": "site-packages/pygments/lexers/spice.py", + "path_type": "hardlink", + "sha256": "51cae32b62890c329212010e78b5d36b2a91c22ad676ccb0adf1fd32ac0f3c86", + "size_in_bytes": 2801 + }, + { + "_path": "site-packages/pygments/lexers/sql.py", + "path_type": "hardlink", + "sha256": "cf3fd3159b5fe51dbd72f901146d4f0c9fb428aad8ec58c0f910e4cbe81f3659", + "size_in_bytes": 41656 + }, + { + "_path": "site-packages/pygments/lexers/srcinfo.py", + "path_type": "hardlink", + "sha256": "3078f4d9507b58fdc07283b3d5655802a34cff7a052e311a01d6b4ef99175415", + "size_in_bytes": 1749 + }, + { + "_path": "site-packages/pygments/lexers/stata.py", + "path_type": "hardlink", + "sha256": "2a88e693158794493e1ef9b1237d776b9da7cc7fc91cda9fbfaaf78c9a050f2f", + "size_in_bytes": 6418 + }, + { + "_path": "site-packages/pygments/lexers/supercollider.py", + "path_type": "hardlink", + "sha256": "1feab03fab146a8b5e9ac5f1bae829ba2e8a9d4de3b487437d2ddb1addc9be1e", + "size_in_bytes": 3700 + }, + { + "_path": "site-packages/pygments/lexers/tablegen.py", + "path_type": "hardlink", + "sha256": "af2bb3c3e02b2ddbe5639e582419fa79b3b30e8dcbf149db479c5c641f3132ca", + "size_in_bytes": 4012 + }, + { + "_path": "site-packages/pygments/lexers/tact.py", + "path_type": "hardlink", + "sha256": "61b39660da77d366413cce5a7dfccce3e0ae749e31459c896fefef4830a8cc2a", + "size_in_bytes": 10812 + }, + { + "_path": "site-packages/pygments/lexers/tal.py", + "path_type": "hardlink", + "sha256": "c5962686ff2606bf80de87a81647123fb9c36d7d6bdb590a3a786c2d3b4bddb1", + "size_in_bytes": 2907 + }, + { + "_path": "site-packages/pygments/lexers/tcl.py", + "path_type": "hardlink", + "sha256": "317300a36c0265eab9a11ed5cec35b6a66b0ba7fef30e93680e1039c693ac8e7", + "size_in_bytes": 5515 + }, + { + "_path": "site-packages/pygments/lexers/teal.py", + "path_type": "hardlink", + "sha256": "a60a4f8bdc563ee992afe85e4a9181183714e6cdea374685523da66872c4dcc3", + "size_in_bytes": 3525 + }, + { + "_path": "site-packages/pygments/lexers/templates.py", + "path_type": "hardlink", + "sha256": "9dd24c76e7b7dea43fb61b28aed02b6b57e6ffeb3330de344b96d95c12d8e78c", + "size_in_bytes": 75734 + }, + { + "_path": "site-packages/pygments/lexers/teraterm.py", + "path_type": "hardlink", + "sha256": "60276f20b46af8574e27f1df888918553a07ddce88d9045b4281f5ed0e3d1f1f", + "size_in_bytes": 10045 + }, + { + "_path": "site-packages/pygments/lexers/testing.py", + "path_type": "hardlink", + "sha256": "185e52a5a9c6c2380a2a861aae2df649db5d3965975e37bcc555f9f99cd38cb8", + "size_in_bytes": 10813 + }, + { + "_path": "site-packages/pygments/lexers/text.py", + "path_type": "hardlink", + "sha256": "caaea638bcf73e2cca34c9b8fd8f141e7f6f11e05fa846395bedccedd9358d8b", + "size_in_bytes": 1071 + }, + { + "_path": "site-packages/pygments/lexers/textedit.py", + "path_type": "hardlink", + "sha256": "57e2238747942d35adc774bfeaf4fb25cca340ef82362ae901b12991cccb1821", + "size_in_bytes": 7763 + }, + { + "_path": "site-packages/pygments/lexers/textfmts.py", + "path_type": "hardlink", + "sha256": "5928890f334a09c3ac0684d4e0d098537ded8b96471a2d0fc76f5e1a34faa41d", + "size_in_bytes": 15527 + }, + { + "_path": "site-packages/pygments/lexers/theorem.py", + "path_type": "hardlink", + "sha256": "73e7a0ead2185946f149882b3ad2d97c5c6ba3883dd49700230ac82462cfa285", + "size_in_bytes": 17903 + }, + { + "_path": "site-packages/pygments/lexers/thingsdb.py", + "path_type": "hardlink", + "sha256": "14d2a302b4b5bda74710ddd95da65d0cbaaf706e7d19b17a024e4cf1132c4cb5", + "size_in_bytes": 6257 + }, + { + "_path": "site-packages/pygments/lexers/tlb.py", + "path_type": "hardlink", + "sha256": "bd6b05abf32b22bce01b6abea9dce9728362bfd2a4368c38c7d79bb3dfc70300", + "size_in_bytes": 1453 + }, + { + "_path": "site-packages/pygments/lexers/tls.py", + "path_type": "hardlink", + "sha256": "199d65bd9f0f524d7e2d386ad4aba2a9212732a255aa21e8fc0fb5e9a2ae24e7", + "size_in_bytes": 1543 + }, + { + "_path": "site-packages/pygments/lexers/tnt.py", + "path_type": "hardlink", + "sha256": "30d6137e48b1d31e4bd690d5f15f3318b4bb194f33edbb7ec298816a9d96d3d5", + "size_in_bytes": 10459 + }, + { + "_path": "site-packages/pygments/lexers/trafficscript.py", + "path_type": "hardlink", + "sha256": "d536b0a26e9b28933ebb59187b2db5c456877a9dc3f6497adab57745a1d2bdc2", + "size_in_bytes": 1509 + }, + { + "_path": "site-packages/pygments/lexers/typoscript.py", + "path_type": "hardlink", + "sha256": "75602e398624d17e3113f7f12a0717cfeb0c6251b6c31411e26fddecf5b63d8b", + "size_in_bytes": 8335 + }, + { + "_path": "site-packages/pygments/lexers/typst.py", + "path_type": "hardlink", + "sha256": "66d577ecd0900a84aa10aac085f7ee66d529d640da84a431f0fc4c2eb4761ba9", + "size_in_bytes": 7170 + }, + { + "_path": "site-packages/pygments/lexers/ul4.py", + "path_type": "hardlink", + "sha256": "8e833e512d3ed811164471cae9ec99f98fbedf4e9881b32b7af318d2183c4136", + "size_in_bytes": 10502 + }, + { + "_path": "site-packages/pygments/lexers/unicon.py", + "path_type": "hardlink", + "sha256": "f43f868a528ea8811aa3018799dbc746386aca2811937db401102bf86fec9dec", + "size_in_bytes": 18628 + }, + { + "_path": "site-packages/pygments/lexers/urbi.py", + "path_type": "hardlink", + "sha256": "8fcee4e9f7bad2465d6c9e80240e20f44d27a3510fd1bc49634e9454fd188275", + "size_in_bytes": 6085 + }, + { + "_path": "site-packages/pygments/lexers/usd.py", + "path_type": "hardlink", + "sha256": "b4ff641cf65425c13f7e53ef284b05ef04dc93816e416ef94bc10b8782182442", + "size_in_bytes": 3307 + }, + { + "_path": "site-packages/pygments/lexers/varnish.py", + "path_type": "hardlink", + "sha256": "20d0ad61ba25d7257f357321e7508c0d90da7041e0881dd2991dc7e6e5be1647", + "size_in_bytes": 7476 + }, + { + "_path": "site-packages/pygments/lexers/verification.py", + "path_type": "hardlink", + "sha256": "4084899a6cfb72661a5d9a615b9b28e0f7dd289a34add656ba3fdd7bae2669f9", + "size_in_bytes": 3937 + }, + { + "_path": "site-packages/pygments/lexers/verifpal.py", + "path_type": "hardlink", + "sha256": "d226534166b017d7fb94566714d3d3c18462bba2ffdb93ed108f37b6e08098a6", + "size_in_bytes": 2664 + }, + { + "_path": "site-packages/pygments/lexers/vip.py", + "path_type": "hardlink", + "sha256": "a4ce711687aefb618f5aa015cd925eeb13d8afa5893e5a33548e74f3848743cd", + "size_in_bytes": 5714 + }, + { + "_path": "site-packages/pygments/lexers/vyper.py", + "path_type": "hardlink", + "sha256": "af0db20fd7362fbc8fb57a8a3ddd1177125264af9a25b5b98c46b48077ca10ed", + "size_in_bytes": 5618 + }, + { + "_path": "site-packages/pygments/lexers/web.py", + "path_type": "hardlink", + "sha256": "60caf1a0794a950c1f14995a7bdfd3f45d55a74dd803b216b2682a2f387aa602", + "size_in_bytes": 916 + }, + { + "_path": "site-packages/pygments/lexers/webassembly.py", + "path_type": "hardlink", + "sha256": "638f15741a7c6f8488d743c4b7c6e23a6fa0b5e62098d73f6d147e2afba57e74", + "size_in_bytes": 5701 + }, + { + "_path": "site-packages/pygments/lexers/webidl.py", + "path_type": "hardlink", + "sha256": "31031a645b2496e076f65306a6218fd9fe9fce88dae2f57c16da02185407e9f3", + "size_in_bytes": 10519 + }, + { + "_path": "site-packages/pygments/lexers/webmisc.py", + "path_type": "hardlink", + "sha256": "1a74934877ec0141b2e43605feac0598cb3269b9f34ecb5a106f7a16e6f9ddf9", + "size_in_bytes": 40567 + }, + { + "_path": "site-packages/pygments/lexers/wgsl.py", + "path_type": "hardlink", + "sha256": "be00ed63fab8d93191bdcb324bbbe249a754f03dde1ef6ad7e808d36710fd331", + "size_in_bytes": 11883 + }, + { + "_path": "site-packages/pygments/lexers/whiley.py", + "path_type": "hardlink", + "sha256": "302d95ee8d6cecb2282f2d0593e8bc3b2981a0dd1da4ad813e322b750c2c9d59", + "size_in_bytes": 4020 + }, + { + "_path": "site-packages/pygments/lexers/wowtoc.py", + "path_type": "hardlink", + "sha256": "5e72d2497ee9fd1930648ce59985cef3bddde1bc97f7e03775fbf334be44a1cc", + "size_in_bytes": 4079 + }, + { + "_path": "site-packages/pygments/lexers/wren.py", + "path_type": "hardlink", + "sha256": "da5873c294b6ef15ba9c4458fcd78e0e034df57ea607bbe5de875748f9e0a98f", + "size_in_bytes": 3232 + }, + { + "_path": "site-packages/pygments/lexers/x10.py", + "path_type": "hardlink", + "sha256": "efba40ca886dbfd3c5c0fbc93c682af95c3cb445e8f529f2d4c9d37211694d32", + "size_in_bytes": 1946 + }, + { + "_path": "site-packages/pygments/lexers/xorg.py", + "path_type": "hardlink", + "sha256": "2d4294f75b753a97375bf17ae141b3c749c1f87a8a94ddc29ffead173b79218c", + "size_in_bytes": 928 + }, + { + "_path": "site-packages/pygments/lexers/yang.py", + "path_type": "hardlink", + "sha256": "c88bf0b5e1d60562f6fbccd9b1c9c23c93a7ab7acc39787997126e8f2c00fd9a", + "size_in_bytes": 4502 + }, + { + "_path": "site-packages/pygments/lexers/yara.py", + "path_type": "hardlink", + "sha256": "fc84b3864a3bbfd02127ed5c5883594b21b79b2daf24ec85487c528e6e157536", + "size_in_bytes": 2430 + }, + { + "_path": "site-packages/pygments/lexers/zig.py", + "path_type": "hardlink", + "sha256": "ab4b6ea65a511405124b6f6183f5e2447db60adbded841404f9c68ed334096b9", + "size_in_bytes": 3975 + }, + { + "_path": "site-packages/pygments/modeline.py", + "path_type": "hardlink", + "sha256": "99ef20e6bc9289dbcfb4c04eac3cb63b5b0ca99774da5047318e4a0d979f530b", + "size_in_bytes": 1008 + }, + { + "_path": "site-packages/pygments/plugin.py", + "path_type": "hardlink", + "sha256": "3facc8c3ebe4490d24d56287af36c14e3a7094264f6d1fba41efdd3bd06376ed", + "size_in_bytes": 1928 + }, + { + "_path": "site-packages/pygments/regexopt.py", + "path_type": "hardlink", + "sha256": "776853bdace5a30e73cd920e0959df7841b6098d06ad8fe2807d6409249fee8c", + "size_in_bytes": 3308 + }, + { + "_path": "site-packages/pygments/scanner.py", + "path_type": "hardlink", + "sha256": "0eda0b8b5a4e2a936efba8e26a42694902d48bf7a9dbd490421bfba00c1858c1", + "size_in_bytes": 3095 + }, + { + "_path": "site-packages/pygments/sphinxext.py", + "path_type": "hardlink", + "sha256": "aa6896bf96fbaaae9b3544f6636c197a3576226426bedcc624583a2dc184365d", + "size_in_bytes": 7901 + }, + { + "_path": "site-packages/pygments/style.py", + "path_type": "hardlink", + "sha256": "1eb89edfbddb81653cd5937056364cf86341a3107155ed56d53af733324b7646", + "size_in_bytes": 6411 + }, + { + "_path": "site-packages/pygments/styles/__init__.py", + "path_type": "hardlink", + "sha256": "daf8062a76f2b749dffc248312d3211f1a693d200faf68da7f39791625c5b86b", + "size_in_bytes": 2009 + }, + { + "_path": "site-packages/pygments/styles/_mapping.py", + "path_type": "hardlink", + "sha256": "ea5a2f154136f6dcfa12c5775d8638860a3327bab524bedc7cedd43a58274bcc", + "size_in_bytes": 3312 + }, + { + "_path": "site-packages/pygments/styles/abap.py", + "path_type": "hardlink", + "sha256": "4fb01dd76d4a8f3f196eea61ca1ba550bc17caf5ee6d24ba0b3734303385889f", + "size_in_bytes": 752 + }, + { + "_path": "site-packages/pygments/styles/algol.py", + "path_type": "hardlink", + "sha256": "eafe995cbc4f26c9bfd6a3ea3aee62840b9685593ae3835d3d73dc66a88e4d32", + "size_in_bytes": 2265 + }, + { + "_path": "site-packages/pygments/styles/algol_nu.py", + "path_type": "hardlink", + "sha256": "e7cd4b7f975bdf4de0ef30dbef3f9596f1a514da5b5cc225027ad1071b631adb", + "size_in_bytes": 2286 + }, + { + "_path": "site-packages/pygments/styles/arduino.py", + "path_type": "hardlink", + "sha256": "a051798237db40d06280ac45842ee08942075a5d22782b2186c9bd531088cea8", + "size_in_bytes": 4560 + }, + { + "_path": "site-packages/pygments/styles/autumn.py", + "path_type": "hardlink", + "sha256": "3fd217e6eb630ef74981ebccd24346c04fb0bd5cac461d6580c9233b57610c31", + "size_in_bytes": 2198 + }, + { + "_path": "site-packages/pygments/styles/borland.py", + "path_type": "hardlink", + "sha256": "57ca930fc4ab4b4c0ba21a76b9d222ae58a36c77cfa08956664629ab149d912c", + "size_in_bytes": 1614 + }, + { + "_path": "site-packages/pygments/styles/bw.py", + "path_type": "hardlink", + "sha256": "7b8168e8ac9ac7669186a2ac8ecaaf8b6096ea5914f509e32a83eb1126408fe2", + "size_in_bytes": 1409 + }, + { + "_path": "site-packages/pygments/styles/coffee.py", + "path_type": "hardlink", + "sha256": "d23c5d72d08429b47502acc0e7d7c540ae2c541744aeb464182527e9f3c5e2c8", + "size_in_bytes": 2311 + }, + { + "_path": "site-packages/pygments/styles/colorful.py", + "path_type": "hardlink", + "sha256": "a2991f39c8c54ed0e7f45b72ea880cee8905301e9b034891d15b537413c4f4d1", + "size_in_bytes": 2835 + }, + { + "_path": "site-packages/pygments/styles/default.py", + "path_type": "hardlink", + "sha256": "5852c3b9c2894bf69ce49aaeb668256f3e084dce234d34043a7a8b20ca52b6d0", + "size_in_bytes": 2591 + }, + { + "_path": "site-packages/pygments/styles/dracula.py", + "path_type": "hardlink", + "sha256": "1fe10cd5633723177638163d6f3a0e6ca978233766862adf0d515b27d5ac8b44", + "size_in_bytes": 2185 + }, + { + "_path": "site-packages/pygments/styles/emacs.py", + "path_type": "hardlink", + "sha256": "8846163e042b0d093845d0dff3e83b8f89ada05473a36c5c2af644d72b3d9895", + "size_in_bytes": 2538 + }, + { + "_path": "site-packages/pygments/styles/friendly.py", + "path_type": "hardlink", + "sha256": "4b8dd731ccd6e77b4a7ed99aac42f8fa74eba0f55d37a93c7db36b20dcd1fd05", + "size_in_bytes": 2607 + }, + { + "_path": "site-packages/pygments/styles/friendly_grayscale.py", + "path_type": "hardlink", + "sha256": "7a5d84f34e03124299e80a57b77379153987024221aa4263fa89a113513c99d1", + "size_in_bytes": 2831 + }, + { + "_path": "site-packages/pygments/styles/fruity.py", + "path_type": "hardlink", + "sha256": "9ab3438b1a77f502288ad441a3ec8c3abf2d9d82c0c06774108330d80e8677c8", + "size_in_bytes": 1327 + }, + { + "_path": "site-packages/pygments/styles/gh_dark.py", + "path_type": "hardlink", + "sha256": "c9be04381018b10f60e481843aac99e4b288f8c51bc33df697d581e4470c2da0", + "size_in_bytes": 3593 + }, + { + "_path": "site-packages/pygments/styles/gruvbox.py", + "path_type": "hardlink", + "sha256": "fd066d46af72d6cdcd6000c7a9e93e0d710b42ab9e3a75435ef589ff56931a0a", + "size_in_bytes": 3390 + }, + { + "_path": "site-packages/pygments/styles/igor.py", + "path_type": "hardlink", + "sha256": "40efcce7e675c48c559eeb045382d9af8553fbe9d311156df9ca5f6e73afe329", + "size_in_bytes": 740 + }, + { + "_path": "site-packages/pygments/styles/inkpot.py", + "path_type": "hardlink", + "sha256": "6c9bcd5a292a9c058b8f1d801f8b7fb56e234744ecad4c951571553c07ce8243", + "size_in_bytes": 2407 + }, + { + "_path": "site-packages/pygments/styles/lightbulb.py", + "path_type": "hardlink", + "sha256": "0a70efd661755f99359ac56f452fdd891e2d929d3a13f8e0d2d2bd71d1c41424", + "size_in_bytes": 3175 + }, + { + "_path": "site-packages/pygments/styles/lilypond.py", + "path_type": "hardlink", + "sha256": "8120a26b33cf59f47ff7e055e416077bafb6812a2be2f3879f3de7c85408d900", + "size_in_bytes": 2069 + }, + { + "_path": "site-packages/pygments/styles/lovelace.py", + "path_type": "hardlink", + "sha256": "bd9f92f6d4be4143b07c0d111d8061493444de1d5953e6d99ee316eceea4b32c", + "size_in_bytes": 3181 + }, + { + "_path": "site-packages/pygments/styles/manni.py", + "path_type": "hardlink", + "sha256": "769b090b565e7acd1ef487168aba96b92cd0c700f48c86e3845aae336ddd9963", + "size_in_bytes": 2446 + }, + { + "_path": "site-packages/pygments/styles/material.py", + "path_type": "hardlink", + "sha256": "7b2c80689829d459e3978fbf0f7f7f975c07e425b85b455649c4374348ed0205", + "size_in_bytes": 4204 + }, + { + "_path": "site-packages/pygments/styles/monokai.py", + "path_type": "hardlink", + "sha256": "dc2c09266fd854689bcc58bc9e12bf6f977870dce057ccfe2fa4730b551503b4", + "size_in_bytes": 5187 + }, + { + "_path": "site-packages/pygments/styles/murphy.py", + "path_type": "hardlink", + "sha256": "1ec3ddf349ce6dbdcebf7fbbc8941b9c9af7cfd982cb3df43e39ff9e45a4318a", + "size_in_bytes": 2808 + }, + { + "_path": "site-packages/pygments/styles/native.py", + "path_type": "hardlink", + "sha256": "a1acc42546ee687aaa399479bf1fa32214cf230edd0ba4199cac56fb12ebedfb", + "size_in_bytes": 2046 + }, + { + "_path": "site-packages/pygments/styles/nord.py", + "path_type": "hardlink", + "sha256": "b7b7d98f4e0b520b0b687a62a3ae85a8e18c29bedad950b7b5e5259889cf7d18", + "size_in_bytes": 5394 + }, + { + "_path": "site-packages/pygments/styles/onedark.py", + "path_type": "hardlink", + "sha256": "517acccd5bc0f4e54fece84243980bd02699ae4e63a3f23ce07266ecb10de464", + "size_in_bytes": 2126 + }, + { + "_path": "site-packages/pygments/styles/paraiso_dark.py", + "path_type": "hardlink", + "sha256": "af1e7f8f8827651cb68fede10211665a99e39ddf957f3dd9edf7301174541a6d", + "size_in_bytes": 5665 + }, + { + "_path": "site-packages/pygments/styles/paraiso_light.py", + "path_type": "hardlink", + "sha256": "8844636d845e9aa82c8acbfff538da9c18a0e1b27ffbcd31473e41e69ba131cd", + "size_in_bytes": 5671 + }, + { + "_path": "site-packages/pygments/styles/pastie.py", + "path_type": "hardlink", + "sha256": "9a729e6c5889d9da3d03fc133eae2d2ad830f9342aa5bd253f790d6de990dada", + "size_in_bytes": 2528 + }, + { + "_path": "site-packages/pygments/styles/perldoc.py", + "path_type": "hardlink", + "sha256": "f9ed53e1004440d13f975ed1616f96068c0da6b836b8bfe11638520dc68c8833", + "size_in_bytes": 2233 + }, + { + "_path": "site-packages/pygments/styles/rainbow_dash.py", + "path_type": "hardlink", + "sha256": "60fd873d55c92e63b2f18cfca7cbb919b900cae2b12e5366bba21364131ad4c7", + "size_in_bytes": 2393 + }, + { + "_path": "site-packages/pygments/styles/rrt.py", + "path_type": "hardlink", + "sha256": "bece299d6c26308411d1e19cce9d3a0186b3b18891d0a15c462454cd27f7ad77", + "size_in_bytes": 1295 + }, + { + "_path": "site-packages/pygments/styles/sas.py", + "path_type": "hardlink", + "sha256": "111f898d9814db01095a4e4ad3a8870053e35580f588c92f8e3134ae534eb766", + "size_in_bytes": 1443 + }, + { + "_path": "site-packages/pygments/styles/solarized.py", + "path_type": "hardlink", + "sha256": "55db4b62143bc438ff8931cffc492beab01d31c1377d14ab8259e05526a5eb73", + "size_in_bytes": 4250 + }, + { + "_path": "site-packages/pygments/styles/staroffice.py", + "path_type": "hardlink", + "sha256": "a5e13190806a3e4461a971695bdf67e3db7aa4cc1e848fe90d8554990c2481d0", + "size_in_bytes": 834 + }, + { + "_path": "site-packages/pygments/styles/stata_dark.py", + "path_type": "hardlink", + "sha256": "37a8a65b292a1e84f976b3a7fac551533b7501930a1b71c753e43b2cacf6779d", + "size_in_bytes": 1260 + }, + { + "_path": "site-packages/pygments/styles/stata_light.py", + "path_type": "hardlink", + "sha256": "616ee2878b5e5e812e50722638adab192095c5f9e3e37b6570a3d752cac39118", + "size_in_bytes": 1292 + }, + { + "_path": "site-packages/pygments/styles/tango.py", + "path_type": "hardlink", + "sha256": "01fd16553c691ff714747affb9aebd2438a34cb239686d519814c5ee8d8a4e09", + "size_in_bytes": 7140 + }, + { + "_path": "site-packages/pygments/styles/trac.py", + "path_type": "hardlink", + "sha256": "fa1e6253e2e34a6b7e750ef2e635f02792d0f40051e500f94653d18e19f39aff", + "size_in_bytes": 1984 + }, + { + "_path": "site-packages/pygments/styles/vim.py", + "path_type": "hardlink", + "sha256": "756a82542d984f8e5d2d2a4c4f02c13e4298811b13d7e7057fb647a1cd8f4290", + "size_in_bytes": 2022 + }, + { + "_path": "site-packages/pygments/styles/vs.py", + "path_type": "hardlink", + "sha256": "ec725e861b621c4e6789b8c2debdd7f9a607066e4171c2f7dcb80eff86a71225", + "size_in_bytes": 1133 + }, + { + "_path": "site-packages/pygments/styles/xcode.py", + "path_type": "hardlink", + "sha256": "1e607a68f931be6a38cdae438a384b6f90174b2bfa51b5a7c0e5284543416990", + "size_in_bytes": 1507 + }, + { + "_path": "site-packages/pygments/styles/zenburn.py", + "path_type": "hardlink", + "sha256": "031ee205b333bd540d4e94f761d33008490bfa72179e9afad1a56b4782e96baa", + "size_in_bytes": 2206 + }, + { + "_path": "site-packages/pygments/token.py", + "path_type": "hardlink", + "sha256": "0d58a5e53da5b479138104d4632d5d32d8328a08dabc2b35ca913841fd82ac6a", + "size_in_bytes": 6229 + }, + { + "_path": "site-packages/pygments/unistring.py", + "path_type": "hardlink", + "sha256": "678c381df395521b9e09445191f840a90d9bfbaf54ce4858e31b877af604cb98", + "size_in_bytes": 63211 + }, + { + "_path": "site-packages/pygments/util.py", + "path_type": "hardlink", + "sha256": "ce4f77e6d252a70480f73c4d995d53ba17043f431f6e85e24594864272cf12a9", + "size_in_bytes": 10046 + } + ], + "paths_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/recipe/conda_build_config.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/recipe/conda_build_config.yaml new file mode 100644 index 0000000000000000000000000000000000000000..347ba5f26d9618743be9706177f3dbb76093bfc2 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/recipe/conda_build_config.yaml @@ -0,0 +1,31 @@ +CI: github_actions +c_compiler: gcc +channel_sources: conda-forge +channel_targets: conda-forge main +cpu_optimization_target: nocona +cran_mirror: https://cran.r-project.org +cxx_compiler: gxx +docker_image: quay.io/condaforge/linux-anvil-x86_64:alma9 +extend_keys: +- pin_run_as_build +- extend_keys +- ignore_build_only_deps +- ignore_version +fortran_compiler: gfortran +ignore_build_only_deps: +- python +- numpy +lua: '5' +numpy: '1.26' +perl: 5.26.2 +pin_run_as_build: + python: + max_pin: x.x + min_pin: x.x + r-base: + max_pin: x.x + min_pin: x.x +python: '3.12' +python_min: '3.10' +r_base: '3.5' +target_platform: linux-64 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/recipe/meta.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/recipe/meta.yaml new file mode 100644 index 0000000000000000000000000000000000000000..969ac08c2abf8d6d45824951f974f71c2ef8e5a1 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/recipe/meta.yaml @@ -0,0 +1,88 @@ +# This file created by conda-build 26.1.0 +# meta.yaml template originally from: +# /home/conda/recipe_root, last modified Sun Mar 29 15:04:00 2026 +# ------------------------------------------------ + +package: + name: pygments + version: 2.20.0 +source: + url: https://pypi.org/packages/source/p/pygments/pygments-2.20.0.tar.gz + sha256: 6757cd03768053ff99f3039c1a36d6c0aa0b263438fcab17520b30a303a82b5f +build: + entry_points: + - pygmentize = pygments.cmdline:main + noarch: python + script: /home/conda/feedstock_root/build_artifacts/pygments_1774796700044/_h_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_pl/bin/python + -m pip install . -vv --no-deps --no-build-isolation + number: '0' + string: pyhd8ed1ab_0 +requirements: + host: + - _openmp_mutex 4.5 20_gnu + - bzip2 1.0.8 hda65f42_9 + - ca-certificates 2026.2.25 hbd8a1cb_0 + - editables 0.5 pyhd8ed1ab_1 + - hatchling 1.29.0 pyhcf101f3_0 + - icu 78.3 h33c6efd_0 + - ld_impl_linux-64 2.45.1 default_hbd61a6d_102 + - libexpat 2.7.5 hecca717_0 + - libffi 3.5.2 h3435931_0 + - libgcc 15.2.0 he0feb66_18 + - libgcc-ng 15.2.0 h69a702a_18 + - libgomp 15.2.0 he0feb66_18 + - liblzma 5.8.2 hb03c661_0 + - libnsl 2.0.1 hb9d3cd8_1 + - libsqlite 3.52.0 hf4e2dac_0 + - libstdcxx 15.2.0 h934c35e_18 + - libuuid 2.41.3 h5347b49_0 + - libxcrypt 4.4.36 hd590300_1 + - libzlib 1.3.2 h25fd6f3_2 + - ncurses 6.5 h2d0b736_3 + - openssl 3.6.1 h35e630c_1 + - packaging 26.0 pyhcf101f3_0 + - pathspec 1.0.4 pyhd8ed1ab_0 + - pip 26.0.1 pyh8b19718_0 + - pluggy 1.6.0 pyhf9edf01_1 + - python 3.10.20 h3c07f61_0_cpython + - readline 8.3 h853b02a_0 + - setuptools 82.0.1 pyh332efcf_0 + - tk 8.6.13 noxft_h366c992_103 + - tomli 2.4.1 pyhcf101f3_0 + - trove-classifiers 2026.1.14.14 pyhd8ed1ab_0 + - tzdata 2025c hc9c84f9_1 + - wheel 0.46.3 pyhd8ed1ab_0 + - zstd 1.5.7 hb78ec9c_6 + run: + - python >=3.10 +test: + imports: + - pygments + - pygments.filters + - pygments.formatters + - pygments.lexers + - pygments.plugin + - pygments.styles + commands: + - pip check + - pygmentize -h + requires: + - pip + - python 3.10.* +about: + home: http://pygments.org/ + license: BSD-2-Clause + license_file: LICENSE + summary: Pygments is a generic syntax highlighter suitable for use in code hosting, + forums, wikis or other applications that need to prettify source code. +extra: + recipe-maintainers: + - jakirkham + - ocefpaf + - pelson + - scopatz + final: true + copy_test_source_files: true + flow_run_id: github_23711927601 + remote_url: https://github.com/conda-forge/pygments-feedstock + sha: f4e28944213d3c3d486c24c08936670ab4bc2747 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/recipe/meta.yaml.template b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/recipe/meta.yaml.template new file mode 100644 index 0000000000000000000000000000000000000000..fa2289d55c97bd41486937c6a2e8e8a6568d4bb8 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/recipe/meta.yaml.template @@ -0,0 +1,55 @@ +{% set name = "pygments" %} +{% set version = "2.20.0" %} + +package: + name: {{ name|lower }} + version: {{ version }} + +source: + url: https://pypi.org/packages/source/{{ name[0] }}/{{ name }}/{{ name }}-{{ version }}.tar.gz + sha256: 6757cd03768053ff99f3039c1a36d6c0aa0b263438fcab17520b30a303a82b5f + +build: + entry_points: + - pygmentize = pygments.cmdline:main + noarch: python + script: {{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation + number: 0 + +requirements: + host: + - python {{ python_min }} + - setuptools >=61 + - hatchling + - pip + run: + - python >={{ python_min }} + +test: + imports: + - pygments.styles + - pygments + - pygments.lexers + - pygments.filters + - pygments.formatters + - pygments.plugin + commands: + - pip check + - pygmentize -h + requires: + - pip + - python {{ python_min }} + + +about: + home: http://pygments.org/ + license: BSD-2-Clause + license_file: LICENSE + summary: Pygments is a generic syntax highlighter suitable for use in code hosting, forums, wikis or other applications that need to prettify source code. + +extra: + recipe-maintainers: + - jakirkham + - pelson + - ocefpaf + - scopatz diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/recipe/recipe-scripts-license.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/recipe/recipe-scripts-license.txt new file mode 100644 index 0000000000000000000000000000000000000000..c5aa738f1bd246658c9da9e1bbe2502df6d0e173 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/recipe/recipe-scripts-license.txt @@ -0,0 +1,26 @@ +BSD-3-Clause license +Copyright (c) 2015-2026, conda-forge contributors + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + 3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/repodata_record.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/repodata_record.json new file mode 100644 index 0000000000000000000000000000000000000000..a2cc61d76e542377938734a710a97675ce776c38 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/repodata_record.json @@ -0,0 +1,23 @@ +{ + "arch": null, + "build": "pyhd8ed1ab_0", + "build_number": 0, + "build_string": "pyhd8ed1ab_0", + "channel": "conda-forge", + "constrains": [], + "depends": [ + "python >=3.10" + ], + "fn": "pygments-2.20.0-pyhd8ed1ab_0.conda", + "license": "BSD-2-Clause", + "md5": "16c18772b340887160c79a6acc022db0", + "name": "pygments", + "noarch": "python", + "platform": null, + "sha256": "cf70b2f5ad9ae472b71235e5c8a736c9316df3705746de419b59d442e8348e86", + "size": 893031, + "subdir": "noarch", + "timestamp": 1774796815, + "url": "https://conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0.conda", + "version": "2.20.0" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/test/run_test.bat b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/test/run_test.bat new file mode 100644 index 0000000000000000000000000000000000000000..5cc81b889aee60fdf7f68cef22c72f5a693e1dbb --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/test/run_test.bat @@ -0,0 +1,9 @@ + + +@echo on + +pip check +IF %ERRORLEVEL% NEQ 0 exit /B 1 +pygmentize -h +IF %ERRORLEVEL% NEQ 0 exit /B 1 +exit /B 0 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/test/run_test.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/test/run_test.py new file mode 100644 index 0000000000000000000000000000000000000000..3912baba393988df70f3a7f05c583b29c81cae86 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/test/run_test.py @@ -0,0 +1,18 @@ +print("import: 'pygments.styles'") +import pygments.styles + +print("import: 'pygments'") +import pygments + +print("import: 'pygments.lexers'") +import pygments.lexers + +print("import: 'pygments.filters'") +import pygments.filters + +print("import: 'pygments.formatters'") +import pygments.formatters + +print("import: 'pygments.plugin'") +import pygments.plugin + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/test/run_test.sh b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/test/run_test.sh new file mode 100644 index 0000000000000000000000000000000000000000..831745dedb1a2473da27461a95558d1d67df63f1 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/test/run_test.sh @@ -0,0 +1,9 @@ + + +set -ex + + + +pip check +pygmentize -h +exit 0 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/test/test_time_dependencies.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/test/test_time_dependencies.json new file mode 100644 index 0000000000000000000000000000000000000000..4b1fc82058879d3c6e030c70c12c7473c650d135 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/info/test/test_time_dependencies.json @@ -0,0 +1 @@ +["pip", "python 3.10.*"] \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/INSTALLER b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/INSTALLER new file mode 100644 index 0000000000000000000000000000000000000000..f79e4cb9aaf0b2d9e8ba78861e2071317b2384b3 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/INSTALLER @@ -0,0 +1 @@ +conda \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/METADATA b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/METADATA new file mode 100644 index 0000000000000000000000000000000000000000..3dea62032aff25161bb49b38d237376f18fbaec1 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/METADATA @@ -0,0 +1,57 @@ +Metadata-Version: 2.4 +Name: Pygments +Version: 2.20.0 +Summary: Pygments is a syntax highlighting package written in Python. +Project-URL: Homepage, https://pygments.org +Project-URL: Documentation, https://pygments.org/docs +Project-URL: Source, https://github.com/pygments/pygments +Project-URL: Bug Tracker, https://github.com/pygments/pygments/issues +Project-URL: Changelog, https://github.com/pygments/pygments/blob/master/CHANGES +Author-email: Georg Brandl +Maintainer: Matthäus G. Chajdas +Maintainer-email: Georg Brandl , Jean Abou Samra +License-Expression: BSD-2-Clause +License-File: AUTHORS +License-File: LICENSE +Keywords: syntax highlighting +Classifier: Development Status :: 6 - Mature +Classifier: Intended Audience :: Developers +Classifier: Intended Audience :: End Users/Desktop +Classifier: Intended Audience :: System Administrators +Classifier: Operating System :: OS Independent +Classifier: Programming Language :: Python +Classifier: Programming Language :: Python :: 3 +Classifier: Programming Language :: Python :: 3.9 +Classifier: Programming Language :: Python :: 3.10 +Classifier: Programming Language :: Python :: 3.11 +Classifier: Programming Language :: Python :: 3.12 +Classifier: Programming Language :: Python :: 3.13 +Classifier: Programming Language :: Python :: 3.14 +Classifier: Programming Language :: Python :: Implementation :: CPython +Classifier: Programming Language :: Python :: Implementation :: PyPy +Classifier: Topic :: Text Processing :: Filters +Classifier: Topic :: Utilities +Requires-Python: >=3.9 +Provides-Extra: plugins +Provides-Extra: windows-terminal +Requires-Dist: colorama>=0.4.6; extra == 'windows-terminal' +Description-Content-Type: text/x-rst + +Pygments +~~~~~~~~ + +Pygments is a syntax highlighting package written in Python. + +It is a generic syntax highlighter suitable for use in code hosting, forums, +wikis or other applications that need to prettify source code. Highlights +are: + +* a wide range of over 500 languages and other text formats is supported +* special attention is paid to details, increasing quality by a fair amount +* support for new languages and formats are added easily +* a number of output formats, presently HTML, LaTeX, RTF, SVG, all image + formats that PIL supports and ANSI sequences +* it is usable as a command-line tool and as a library + +Copyright 2006-present by the Pygments team, see ``AUTHORS``. +Licensed under the BSD, see ``LICENSE`` for details. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/RECORD b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/RECORD new file mode 100644 index 0000000000000000000000000000000000000000..684f4ed4373e17198a4493cdbef9fd306963b762 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/RECORD @@ -0,0 +1,688 @@ +../../../bin/pygmentize,sha256=1ey16RhiOwgKxBfd0OzryPsgrbTkDm6MKr_nMRIEOD4,446 +pygments-2.20.0.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +pygments-2.20.0.dist-info/METADATA,sha256=4FKPUbMEJ_rpRyNmK6Yi-NjbKk2NPxNlaY1npSRQqEU,2476 +pygments-2.20.0.dist-info/RECORD,, +pygments-2.20.0.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pygments-2.20.0.dist-info/WHEEL,sha256=QccIxa26bgl1E6uMy58deGWi-0aeIkkangHcxk2kWfw,87 +pygments-2.20.0.dist-info/direct_url.json,sha256=2e8vlI6a6HO2U4X-AxZmf1yN7k_VVOG_TUoj9jb1BHg,104 +pygments-2.20.0.dist-info/entry_points.txt,sha256=uUXw-XhMKBEX4pWcCtpuTTnPhL3h7OEE2jWi51VQsa8,53 +pygments-2.20.0.dist-info/licenses/AUTHORS,sha256=DbYDpfRJn2kMRCVHf_ZkwWbaMl06zDtajU3j2wckQ9A,10873 +pygments-2.20.0.dist-info/licenses/LICENSE,sha256=qdZvHVJt8C4p3Oc0NtNOVuhjL0bCdbvf_HBWnogvnxc,1331 +pygments/__init__.py,sha256=ZzpnXpvnv0c7r_OIS8h7UeaESqYNKMy__pV7KCiWXxw,2962 +pygments/__main__.py,sha256=QZWj0T6TTRsqr-w-0YvVILo1DyAvzzydGCRONwdEzqo,351 +pygments/__pycache__/__init__.cpython-310.pyc,, +pygments/__pycache__/__main__.cpython-310.pyc,, +pygments/__pycache__/cmdline.cpython-310.pyc,, +pygments/__pycache__/console.cpython-310.pyc,, +pygments/__pycache__/filter.cpython-310.pyc,, +pygments/__pycache__/formatter.cpython-310.pyc,, +pygments/__pycache__/lexer.cpython-310.pyc,, +pygments/__pycache__/modeline.cpython-310.pyc,, +pygments/__pycache__/plugin.cpython-310.pyc,, +pygments/__pycache__/regexopt.cpython-310.pyc,, +pygments/__pycache__/scanner.cpython-310.pyc,, +pygments/__pycache__/sphinxext.cpython-310.pyc,, +pygments/__pycache__/style.cpython-310.pyc,, +pygments/__pycache__/token.cpython-310.pyc,, +pygments/__pycache__/unistring.cpython-310.pyc,, +pygments/__pycache__/util.cpython-310.pyc,, +pygments/cmdline.py,sha256=_dOnrta_2GIe8Jg-1Y0pb5vWi8L6QTiJzyoTuHrYrbM,23542 +pygments/console.py,sha256=C189JAwhC1Qh0AKgshzb1wVDzFqBnv1VZ45kTEDIO30,1721 +pygments/filter.py,sha256=1dnbkq2AdC3AkHt3DaXwnOkTBLChl1kR6naSLwnr_tc,1913 +pygments/filters/__init__.py,sha256=03ZYdIYmxnWCh7gNXD7lEQ869Df4kzHnOGM44iJxan8,40349 +pygments/filters/__pycache__/__init__.cpython-310.pyc,, +pygments/formatter.py,sha256=PTBnTW0EHke2vzlAKuvHJkj3-_CMj8duIx-3yVUie-o,4369 +pygments/formatters/__init__.py,sha256=qPG4q5cuaZRGBglmEJVLP4SDv43QI3tAUskj30M-mOY,5352 +pygments/formatters/__pycache__/__init__.cpython-310.pyc,, +pygments/formatters/__pycache__/_mapping.cpython-310.pyc,, +pygments/formatters/__pycache__/bbcode.cpython-310.pyc,, +pygments/formatters/__pycache__/groff.cpython-310.pyc,, +pygments/formatters/__pycache__/html.cpython-310.pyc,, +pygments/formatters/__pycache__/img.cpython-310.pyc,, +pygments/formatters/__pycache__/irc.cpython-310.pyc,, +pygments/formatters/__pycache__/latex.cpython-310.pyc,, +pygments/formatters/__pycache__/other.cpython-310.pyc,, +pygments/formatters/__pycache__/pangomarkup.cpython-310.pyc,, +pygments/formatters/__pycache__/rtf.cpython-310.pyc,, +pygments/formatters/__pycache__/svg.cpython-310.pyc,, +pygments/formatters/__pycache__/terminal.cpython-310.pyc,, +pygments/formatters/__pycache__/terminal256.cpython-310.pyc,, +pygments/formatters/_mapping.py,sha256=1Cw37FuQlNacnxRKmtlPX4nyLoX9_ttko5ZwscNUZZ4,4176 +pygments/formatters/bbcode.py,sha256=lvG1REZJv0pM6VMe-QwLSuo0Yl1Ra_X51wh93fW8A2k,3299 +pygments/formatters/groff.py,sha256=anF3fNbDYwwOlppOUoKTZg4FzzPbZrE4jcJCMd49_1g,5085 +pygments/formatters/html.py,sha256=qe4P6qIV462HkZovS8s5xKKyYXPQQvUjz6Wj7HX1CxY,36053 +pygments/formatters/img.py,sha256=41uSY0pKg9VmKJYrHuavCVgg0z-mg81p28QEMktwf1o,23304 +pygments/formatters/irc.py,sha256=hdOqAvF02bI8CY8_tutnUptBZpWEBLzVAqS4_YA0tew,4907 +pygments/formatters/latex.py,sha256=cQmE1Nj4E9q5N0XQJBqpc6dLtu5UNOtYq3plPyCX1Hk,19261 +pygments/formatters/other.py,sha256=Hq6qY4POBZ_llAWRr1gzSO9UoeYPONlLMBK60RkW4bg,4989 +pygments/formatters/pangomarkup.py,sha256=L4jU6oO18UqEMqXeN5FkPtkisXrXuXq9wcecgy_6dzo,2209 +pygments/formatters/rtf.py,sha256=YQYW8NTrB4XfOjLbQzutyD4j35TimFNZ0T39dET9DOo,11924 +pygments/formatters/svg.py,sha256=oksXT-ZnTHDsn1WtWgBs9V7qmKFswAKx7jV37tb2tYY,7141 +pygments/formatters/terminal.py,sha256=q7jLLanle33eCZkDr4CoHAN-dHBFf1DBhi4FcBQ8_1E,4629 +pygments/formatters/terminal256.py,sha256=PpA_oATHCih3UTjrbfKqIRUcvsyp_TeBaGw3kpIxeBA,11717 +pygments/lexer.py,sha256=gNMYzmdSkTNyWfqiLJ37oUd1KrN_dMXtsPyaX2-n9EA,35154 +pygments/lexers/__init__.py,sha256=G4dtqE5QMEAqoaaD1rwSZZeuqKhMyS4utlMz1szkrTg,12070 +pygments/lexers/__pycache__/__init__.cpython-310.pyc,, +pygments/lexers/__pycache__/_ada_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_asy_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_cl_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_cocoa_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_csound_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_css_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_googlesql_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_julia_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_lasso_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_lilypond_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_lua_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_luau_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_mapping.cpython-310.pyc,, +pygments/lexers/__pycache__/_mql_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_mysql_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_openedge_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_php_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_postgres_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_qlik_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_scheme_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_scilab_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_sourcemod_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_sql_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_stan_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_stata_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_tsql_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_usd_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_vbscript_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/_vim_builtins.cpython-310.pyc,, +pygments/lexers/__pycache__/actionscript.cpython-310.pyc,, +pygments/lexers/__pycache__/ada.cpython-310.pyc,, +pygments/lexers/__pycache__/agile.cpython-310.pyc,, +pygments/lexers/__pycache__/algebra.cpython-310.pyc,, +pygments/lexers/__pycache__/ambient.cpython-310.pyc,, +pygments/lexers/__pycache__/amdgpu.cpython-310.pyc,, +pygments/lexers/__pycache__/ampl.cpython-310.pyc,, +pygments/lexers/__pycache__/apdlexer.cpython-310.pyc,, +pygments/lexers/__pycache__/apl.cpython-310.pyc,, +pygments/lexers/__pycache__/archetype.cpython-310.pyc,, +pygments/lexers/__pycache__/arrow.cpython-310.pyc,, +pygments/lexers/__pycache__/arturo.cpython-310.pyc,, +pygments/lexers/__pycache__/asc.cpython-310.pyc,, +pygments/lexers/__pycache__/asm.cpython-310.pyc,, +pygments/lexers/__pycache__/asn1.cpython-310.pyc,, +pygments/lexers/__pycache__/automation.cpython-310.pyc,, +pygments/lexers/__pycache__/bare.cpython-310.pyc,, +pygments/lexers/__pycache__/basic.cpython-310.pyc,, +pygments/lexers/__pycache__/bdd.cpython-310.pyc,, +pygments/lexers/__pycache__/berry.cpython-310.pyc,, +pygments/lexers/__pycache__/bibtex.cpython-310.pyc,, +pygments/lexers/__pycache__/blueprint.cpython-310.pyc,, +pygments/lexers/__pycache__/boa.cpython-310.pyc,, +pygments/lexers/__pycache__/bqn.cpython-310.pyc,, +pygments/lexers/__pycache__/business.cpython-310.pyc,, +pygments/lexers/__pycache__/c_cpp.cpython-310.pyc,, +pygments/lexers/__pycache__/c_like.cpython-310.pyc,, +pygments/lexers/__pycache__/capnproto.cpython-310.pyc,, +pygments/lexers/__pycache__/carbon.cpython-310.pyc,, +pygments/lexers/__pycache__/cddl.cpython-310.pyc,, +pygments/lexers/__pycache__/chapel.cpython-310.pyc,, +pygments/lexers/__pycache__/clean.cpython-310.pyc,, +pygments/lexers/__pycache__/codeql.cpython-310.pyc,, +pygments/lexers/__pycache__/comal.cpython-310.pyc,, +pygments/lexers/__pycache__/compiled.cpython-310.pyc,, +pygments/lexers/__pycache__/configs.cpython-310.pyc,, +pygments/lexers/__pycache__/console.cpython-310.pyc,, +pygments/lexers/__pycache__/cplint.cpython-310.pyc,, +pygments/lexers/__pycache__/crystal.cpython-310.pyc,, +pygments/lexers/__pycache__/csound.cpython-310.pyc,, +pygments/lexers/__pycache__/css.cpython-310.pyc,, +pygments/lexers/__pycache__/d.cpython-310.pyc,, +pygments/lexers/__pycache__/dalvik.cpython-310.pyc,, +pygments/lexers/__pycache__/data.cpython-310.pyc,, +pygments/lexers/__pycache__/dax.cpython-310.pyc,, +pygments/lexers/__pycache__/devicetree.cpython-310.pyc,, +pygments/lexers/__pycache__/diff.cpython-310.pyc,, +pygments/lexers/__pycache__/dns.cpython-310.pyc,, +pygments/lexers/__pycache__/dotnet.cpython-310.pyc,, +pygments/lexers/__pycache__/dsls.cpython-310.pyc,, +pygments/lexers/__pycache__/dylan.cpython-310.pyc,, +pygments/lexers/__pycache__/ecl.cpython-310.pyc,, +pygments/lexers/__pycache__/eiffel.cpython-310.pyc,, +pygments/lexers/__pycache__/elm.cpython-310.pyc,, +pygments/lexers/__pycache__/elpi.cpython-310.pyc,, +pygments/lexers/__pycache__/email.cpython-310.pyc,, +pygments/lexers/__pycache__/erlang.cpython-310.pyc,, +pygments/lexers/__pycache__/esoteric.cpython-310.pyc,, +pygments/lexers/__pycache__/ezhil.cpython-310.pyc,, +pygments/lexers/__pycache__/factor.cpython-310.pyc,, +pygments/lexers/__pycache__/fantom.cpython-310.pyc,, +pygments/lexers/__pycache__/felix.cpython-310.pyc,, +pygments/lexers/__pycache__/fift.cpython-310.pyc,, +pygments/lexers/__pycache__/floscript.cpython-310.pyc,, +pygments/lexers/__pycache__/forth.cpython-310.pyc,, +pygments/lexers/__pycache__/fortran.cpython-310.pyc,, +pygments/lexers/__pycache__/foxpro.cpython-310.pyc,, +pygments/lexers/__pycache__/freefem.cpython-310.pyc,, +pygments/lexers/__pycache__/func.cpython-310.pyc,, +pygments/lexers/__pycache__/functional.cpython-310.pyc,, +pygments/lexers/__pycache__/futhark.cpython-310.pyc,, +pygments/lexers/__pycache__/gcodelexer.cpython-310.pyc,, +pygments/lexers/__pycache__/gdscript.cpython-310.pyc,, +pygments/lexers/__pycache__/gleam.cpython-310.pyc,, +pygments/lexers/__pycache__/go.cpython-310.pyc,, +pygments/lexers/__pycache__/grammar_notation.cpython-310.pyc,, +pygments/lexers/__pycache__/graph.cpython-310.pyc,, +pygments/lexers/__pycache__/graphics.cpython-310.pyc,, +pygments/lexers/__pycache__/graphql.cpython-310.pyc,, +pygments/lexers/__pycache__/graphviz.cpython-310.pyc,, +pygments/lexers/__pycache__/gsql.cpython-310.pyc,, +pygments/lexers/__pycache__/hare.cpython-310.pyc,, +pygments/lexers/__pycache__/haskell.cpython-310.pyc,, +pygments/lexers/__pycache__/haxe.cpython-310.pyc,, +pygments/lexers/__pycache__/hdl.cpython-310.pyc,, +pygments/lexers/__pycache__/hexdump.cpython-310.pyc,, +pygments/lexers/__pycache__/html.cpython-310.pyc,, +pygments/lexers/__pycache__/idl.cpython-310.pyc,, +pygments/lexers/__pycache__/igor.cpython-310.pyc,, +pygments/lexers/__pycache__/inferno.cpython-310.pyc,, +pygments/lexers/__pycache__/installers.cpython-310.pyc,, +pygments/lexers/__pycache__/int_fiction.cpython-310.pyc,, +pygments/lexers/__pycache__/iolang.cpython-310.pyc,, +pygments/lexers/__pycache__/j.cpython-310.pyc,, +pygments/lexers/__pycache__/javascript.cpython-310.pyc,, +pygments/lexers/__pycache__/jmespath.cpython-310.pyc,, +pygments/lexers/__pycache__/jslt.cpython-310.pyc,, +pygments/lexers/__pycache__/json5.cpython-310.pyc,, +pygments/lexers/__pycache__/jsonnet.cpython-310.pyc,, +pygments/lexers/__pycache__/jsx.cpython-310.pyc,, +pygments/lexers/__pycache__/julia.cpython-310.pyc,, +pygments/lexers/__pycache__/jvm.cpython-310.pyc,, +pygments/lexers/__pycache__/kuin.cpython-310.pyc,, +pygments/lexers/__pycache__/kusto.cpython-310.pyc,, +pygments/lexers/__pycache__/ldap.cpython-310.pyc,, +pygments/lexers/__pycache__/lean.cpython-310.pyc,, +pygments/lexers/__pycache__/lilypond.cpython-310.pyc,, +pygments/lexers/__pycache__/lisp.cpython-310.pyc,, +pygments/lexers/__pycache__/macaulay2.cpython-310.pyc,, +pygments/lexers/__pycache__/make.cpython-310.pyc,, +pygments/lexers/__pycache__/maple.cpython-310.pyc,, +pygments/lexers/__pycache__/markup.cpython-310.pyc,, +pygments/lexers/__pycache__/math.cpython-310.pyc,, +pygments/lexers/__pycache__/matlab.cpython-310.pyc,, +pygments/lexers/__pycache__/maxima.cpython-310.pyc,, +pygments/lexers/__pycache__/meson.cpython-310.pyc,, +pygments/lexers/__pycache__/mime.cpython-310.pyc,, +pygments/lexers/__pycache__/minecraft.cpython-310.pyc,, +pygments/lexers/__pycache__/mips.cpython-310.pyc,, +pygments/lexers/__pycache__/ml.cpython-310.pyc,, +pygments/lexers/__pycache__/modeling.cpython-310.pyc,, +pygments/lexers/__pycache__/modula2.cpython-310.pyc,, +pygments/lexers/__pycache__/mojo.cpython-310.pyc,, +pygments/lexers/__pycache__/monte.cpython-310.pyc,, +pygments/lexers/__pycache__/mosel.cpython-310.pyc,, +pygments/lexers/__pycache__/ncl.cpython-310.pyc,, +pygments/lexers/__pycache__/nimrod.cpython-310.pyc,, +pygments/lexers/__pycache__/nit.cpython-310.pyc,, +pygments/lexers/__pycache__/nix.cpython-310.pyc,, +pygments/lexers/__pycache__/numbair.cpython-310.pyc,, +pygments/lexers/__pycache__/oberon.cpython-310.pyc,, +pygments/lexers/__pycache__/objective.cpython-310.pyc,, +pygments/lexers/__pycache__/ooc.cpython-310.pyc,, +pygments/lexers/__pycache__/openscad.cpython-310.pyc,, +pygments/lexers/__pycache__/other.cpython-310.pyc,, +pygments/lexers/__pycache__/parasail.cpython-310.pyc,, +pygments/lexers/__pycache__/parsers.cpython-310.pyc,, +pygments/lexers/__pycache__/pascal.cpython-310.pyc,, +pygments/lexers/__pycache__/pawn.cpython-310.pyc,, +pygments/lexers/__pycache__/pddl.cpython-310.pyc,, +pygments/lexers/__pycache__/perl.cpython-310.pyc,, +pygments/lexers/__pycache__/phix.cpython-310.pyc,, +pygments/lexers/__pycache__/php.cpython-310.pyc,, +pygments/lexers/__pycache__/pointless.cpython-310.pyc,, +pygments/lexers/__pycache__/pony.cpython-310.pyc,, +pygments/lexers/__pycache__/praat.cpython-310.pyc,, +pygments/lexers/__pycache__/procfile.cpython-310.pyc,, +pygments/lexers/__pycache__/prolog.cpython-310.pyc,, +pygments/lexers/__pycache__/promql.cpython-310.pyc,, +pygments/lexers/__pycache__/prql.cpython-310.pyc,, +pygments/lexers/__pycache__/ptx.cpython-310.pyc,, +pygments/lexers/__pycache__/python.cpython-310.pyc,, +pygments/lexers/__pycache__/q.cpython-310.pyc,, +pygments/lexers/__pycache__/qlik.cpython-310.pyc,, +pygments/lexers/__pycache__/qvt.cpython-310.pyc,, +pygments/lexers/__pycache__/r.cpython-310.pyc,, +pygments/lexers/__pycache__/rdf.cpython-310.pyc,, +pygments/lexers/__pycache__/rebol.cpython-310.pyc,, +pygments/lexers/__pycache__/rego.cpython-310.pyc,, +pygments/lexers/__pycache__/rell.cpython-310.pyc,, +pygments/lexers/__pycache__/resource.cpython-310.pyc,, +pygments/lexers/__pycache__/ride.cpython-310.pyc,, +pygments/lexers/__pycache__/rita.cpython-310.pyc,, +pygments/lexers/__pycache__/rnc.cpython-310.pyc,, +pygments/lexers/__pycache__/roboconf.cpython-310.pyc,, +pygments/lexers/__pycache__/robotframework.cpython-310.pyc,, +pygments/lexers/__pycache__/ruby.cpython-310.pyc,, +pygments/lexers/__pycache__/rust.cpython-310.pyc,, +pygments/lexers/__pycache__/sas.cpython-310.pyc,, +pygments/lexers/__pycache__/savi.cpython-310.pyc,, +pygments/lexers/__pycache__/scdoc.cpython-310.pyc,, +pygments/lexers/__pycache__/scripting.cpython-310.pyc,, +pygments/lexers/__pycache__/sgf.cpython-310.pyc,, +pygments/lexers/__pycache__/shell.cpython-310.pyc,, +pygments/lexers/__pycache__/sieve.cpython-310.pyc,, +pygments/lexers/__pycache__/slash.cpython-310.pyc,, +pygments/lexers/__pycache__/smalltalk.cpython-310.pyc,, +pygments/lexers/__pycache__/smithy.cpython-310.pyc,, +pygments/lexers/__pycache__/smv.cpython-310.pyc,, +pygments/lexers/__pycache__/snobol.cpython-310.pyc,, +pygments/lexers/__pycache__/solidity.cpython-310.pyc,, +pygments/lexers/__pycache__/soong.cpython-310.pyc,, +pygments/lexers/__pycache__/sophia.cpython-310.pyc,, +pygments/lexers/__pycache__/special.cpython-310.pyc,, +pygments/lexers/__pycache__/spice.cpython-310.pyc,, +pygments/lexers/__pycache__/sql.cpython-310.pyc,, +pygments/lexers/__pycache__/srcinfo.cpython-310.pyc,, +pygments/lexers/__pycache__/stata.cpython-310.pyc,, +pygments/lexers/__pycache__/supercollider.cpython-310.pyc,, +pygments/lexers/__pycache__/tablegen.cpython-310.pyc,, +pygments/lexers/__pycache__/tact.cpython-310.pyc,, +pygments/lexers/__pycache__/tal.cpython-310.pyc,, +pygments/lexers/__pycache__/tcl.cpython-310.pyc,, +pygments/lexers/__pycache__/teal.cpython-310.pyc,, +pygments/lexers/__pycache__/templates.cpython-310.pyc,, +pygments/lexers/__pycache__/teraterm.cpython-310.pyc,, +pygments/lexers/__pycache__/testing.cpython-310.pyc,, +pygments/lexers/__pycache__/text.cpython-310.pyc,, +pygments/lexers/__pycache__/textedit.cpython-310.pyc,, +pygments/lexers/__pycache__/textfmts.cpython-310.pyc,, +pygments/lexers/__pycache__/theorem.cpython-310.pyc,, +pygments/lexers/__pycache__/thingsdb.cpython-310.pyc,, +pygments/lexers/__pycache__/tlb.cpython-310.pyc,, +pygments/lexers/__pycache__/tls.cpython-310.pyc,, +pygments/lexers/__pycache__/tnt.cpython-310.pyc,, +pygments/lexers/__pycache__/trafficscript.cpython-310.pyc,, +pygments/lexers/__pycache__/typoscript.cpython-310.pyc,, +pygments/lexers/__pycache__/typst.cpython-310.pyc,, +pygments/lexers/__pycache__/ul4.cpython-310.pyc,, +pygments/lexers/__pycache__/unicon.cpython-310.pyc,, +pygments/lexers/__pycache__/urbi.cpython-310.pyc,, +pygments/lexers/__pycache__/usd.cpython-310.pyc,, +pygments/lexers/__pycache__/varnish.cpython-310.pyc,, +pygments/lexers/__pycache__/verification.cpython-310.pyc,, +pygments/lexers/__pycache__/verifpal.cpython-310.pyc,, +pygments/lexers/__pycache__/vip.cpython-310.pyc,, +pygments/lexers/__pycache__/vyper.cpython-310.pyc,, +pygments/lexers/__pycache__/web.cpython-310.pyc,, +pygments/lexers/__pycache__/webassembly.cpython-310.pyc,, +pygments/lexers/__pycache__/webidl.cpython-310.pyc,, +pygments/lexers/__pycache__/webmisc.cpython-310.pyc,, +pygments/lexers/__pycache__/wgsl.cpython-310.pyc,, +pygments/lexers/__pycache__/whiley.cpython-310.pyc,, +pygments/lexers/__pycache__/wowtoc.cpython-310.pyc,, +pygments/lexers/__pycache__/wren.cpython-310.pyc,, +pygments/lexers/__pycache__/x10.cpython-310.pyc,, +pygments/lexers/__pycache__/xorg.cpython-310.pyc,, +pygments/lexers/__pycache__/yang.cpython-310.pyc,, +pygments/lexers/__pycache__/yara.cpython-310.pyc,, +pygments/lexers/__pycache__/zig.cpython-310.pyc,, +pygments/lexers/_ada_builtins.py,sha256=dZb-lodsSM6L5emLlgLg-rClm2HumvnHK72CetnSRdA,1546 +pygments/lexers/_asy_builtins.py,sha256=zg54fGhgzWXQUk6-qZ6OW5GTL9d4OrnB8SJQkjrD0xs,27290 +pygments/lexers/_cl_builtins.py,sha256=oBF00ZkJyD14LkYuR603EDFIMyitkze12aT7UzDYLYs,13997 +pygments/lexers/_cocoa_builtins.py,sha256=ab6sq-iy5LapE1cNYyl8PJXLg6EINXx-lMRbwERdKYs,105176 +pygments/lexers/_csound_builtins.py,sha256=wuWiQjmEMhaVvsV8b_efsebgU0YKIoMC0ECpOavTCIM,18417 +pygments/lexers/_css_builtins.py,sha256=qhmC4tRGG53zvzMQE1qn794LvbVODRtVacxWCP3kIkA,12449 +pygments/lexers/_googlesql_builtins.py,sha256=mGfOGuKKjZoHHAAZq6Hpc68x0qKycx-SX_wGDScSOYI,16135 +pygments/lexers/_julia_builtins.py,sha256=u6v0yAzZjqUENjiIQ5qMfcso1r_6ERqGbj3aHwFnyqA,11886 +pygments/lexers/_lasso_builtins.py,sha256=YO_c_f05ZoxspHxCR3oWQCpZhbAJUzBJBhVuuwTjr5c,134513 +pygments/lexers/_lilypond_builtins.py,sha256=-_4i4gpgDgcFHvaZMJL2s1rI9dSNY2ZC6vO6ul7Hml0,115114 +pygments/lexers/_lua_builtins.py,sha256=MsDV9sEbJngKoXSZu0xXawGvd6XjFf125nuXBNoffdU,8111 +pygments/lexers/_luau_builtins.py,sha256=YLUj2bcZ0Cb0SBkIlNXWHFGDUFkpddOJx-ukrZx1cMc,958 +pygments/lexers/_mapping.py,sha256=YbQJB1eqeGk7ol5NgMMPLrD3VGdTwgQCl3TvLwtxwxA,70758 +pygments/lexers/_mql_builtins.py,sha256=CkcvMyHYh4U5rGgV6AgShxRnTOv0tmqEbOiVdpaFLqs,24716 +pygments/lexers/_mysql_builtins.py,sha256=SqiVYVVirtnN4lSgtfeRPxtVpcumjUvvUq9n8JObuQ4,26876 +pygments/lexers/_openedge_builtins.py,sha256=AzF1o6eAkMc6vnvmeVqNnUZUVijzbNYkjzrUdtCQe3M,49401 +pygments/lexers/_php_builtins.py,sha256=9g-WLT3qbSGolQJB_4PS6FW_r7HVXBWvI5OWxKtbwok,108054 +pygments/lexers/_postgres_builtins.py,sha256=QGg2mBTThgv4LdXjFm5wrKaKnCU9DubmJi6lXB7y2Mg,13346 +pygments/lexers/_qlik_builtins.py,sha256=3ZkCSDjtxSxXDI9erigWTLSUct_ap_W0LqfZjFeKQYI,12598 +pygments/lexers/_scheme_builtins.py,sha256=O3BRtt5suTESbZ_bSReQ6D0r0G_Sq_i4wCcUkdUrdS0,32567 +pygments/lexers/_scilab_builtins.py,sha256=E33R0mknNc-5eZ9Ugu7u7Av_vUxAaQoMTtdx3MceyxU,52414 +pygments/lexers/_sourcemod_builtins.py,sha256=8qspLxCLsfN9J7N0SWZRNs0A-qJOIGRBAJaNMeWaOBQ,26780 +pygments/lexers/_sql_builtins.py,sha256=fLphonB6wv6Oit8zanJiExgRoLvZoFW4l9lNH-PTYvw,6770 +pygments/lexers/_stan_builtins.py,sha256=sIoONg4TjLkGN7Ab0tZB1HM7tQ071_Z2c41n9lXZl04,16623 +pygments/lexers/_stata_builtins.py,sha256=ymh8GxEca6eSCgHnqsLqsi9OrfRqYnt5O8yBeinJ7DE,27230 +pygments/lexers/_tsql_builtins.py,sha256=Mw6UnMByju0U-OBgT8af3A4utfrS00Tn5lDnaxBtj9c,15463 +pygments/lexers/_usd_builtins.py,sha256=SGp_ePf2VuktrFV59q6df4mTyxZV7AZYs0TJFSWoBAI,1661 +pygments/lexers/_vbscript_builtins.py,sha256=TFtyc11yvpD_OlNrrFbcCOJoUYkWMq3EeHHCpw_zJNc,4228 +pygments/lexers/_vim_builtins.py,sha256=bB6kdLFM33uoY-sAtsRuUZOoccaa4gDAsdFg4WAEsoU,57069 +pygments/lexers/actionscript.py,sha256=kbHhoDl7JjVzREMv1UuxYBRJaPrxHDkmEAC5COmOIVw,11737 +pygments/lexers/ada.py,sha256=m2O7dYzJVc3iuSgaC-Ti-Gh3CG-JmpZit_DPZpu1IIM,5356 +pygments/lexers/agile.py,sha256=Du-vjnGZEPHuE40XxTMO-XLt56pYcIaKIAxIwcYHFH0,899 +pygments/lexers/algebra.py,sha256=2iQSGxfVuBXBHAJdzbbPvtpvROYTfxfMivDagk9yfh8,10032 +pygments/lexers/ambient.py,sha256=8Nk8WX4qrId9zj_zgjJBuFT40yQXG2OXxFhhF3R00g8,2608 +pygments/lexers/amdgpu.py,sha256=KMDLdb-1aK9RJaNsSkPyiU3DQE_HdjBF0paw_yiJMRA,1726 +pygments/lexers/ampl.py,sha256=IKuMVE6aXsa4S6qpuc_DvEsJmJpyKDNga09BPFLvYxA,4179 +pygments/lexers/apdlexer.py,sha256=puSpLBWevciSc8G0wg2Y_yQIoGgqPes0UBkpFImqvO4,30803 +pygments/lexers/apl.py,sha256=-jhPYsBVT4ckL7CZmukIZNi6tfaJJbBk2vutld372rs,3407 +pygments/lexers/archetype.py,sha256=buhH2WHtxBowy_KD5SPm5vgHpmLoKMdV9tgMs_bE4xU,11577 +pygments/lexers/arrow.py,sha256=e6mb3Ix4jL7TMGNUpk8iRbJy_VF7VY2J0VUknlo1EvA,3567 +pygments/lexers/arturo.py,sha256=GkklOaiEJTOz8E0zdxd_hd1zXwv7lYgp8IJl7uh13hg,11417 +pygments/lexers/asc.py,sha256=CvFSi7FYDW6eu-5oiKGc0MN3aF1XVZDoFI5-3mHpBDk,1696 +pygments/lexers/asm.py,sha256=jHJ3CDtvHgu4hX4kVvvJyciFLWM6FAYFDPG_zjBTyrc,42219 +pygments/lexers/asn1.py,sha256=MLakOeBFkdhKKr42eHFzonpGITEJxR_God8vqjWPva4,4267 +pygments/lexers/automation.py,sha256=gdSYslkW9sblDcvMeK1ay15rb9vRuK56pPOJzdxlIvg,19834 +pygments/lexers/bare.py,sha256=AdqL9Z20nd0bhNGWielLhAHej6V8_8m1OWUkCOrSBx8,3023 +pygments/lexers/basic.py,sha256=NqNxIeHhjBUtenwCdJ88WWEE3N7a16DA9g1_D1mdmF0,27992 +pygments/lexers/bdd.py,sha256=KeuOzXBLJRxxM2gV7aMuYsdV_aJFHyBuF8ptBpWxD5M,1644 +pygments/lexers/berry.py,sha256=vIfT4sBtm6ao64WdNkJTVJmS00BiFdEWvb3obBXBeX8,3212 +pygments/lexers/bibtex.py,sha256=sgfFqXyNyCxROHIe8C0gre69rzbADALnpDtTaqHfSas,4814 +pygments/lexers/blueprint.py,sha256=dW-L5bFIiWxRPDashee2EOYmXIRHdwuCZ1y3iN-a6_0,6191 +pygments/lexers/boa.py,sha256=VqYF1Yg_XdDA5tK_Eiuo1rr7ediBsKUTpB6xza_B5d4,3924 +pygments/lexers/bqn.py,sha256=se4W2XPsNiT36z0Am9X5F4yNLrQvMI5X8miY6R9SEM8,3674 +pygments/lexers/business.py,sha256=MXYomjQiYaTmnUgjQ7LUxjcU1i2iVDjZdXPTeqOlDjM,28348 +pygments/lexers/c_cpp.py,sha256=2ViQoLY22Y6xdzXDmwz30rMcij7EemNq4vpTEsfl7sg,18321 +pygments/lexers/c_like.py,sha256=rafLNQqcEbf-97VpDtSIQZSSmdiMD4oBYeEs7DZyByg,32024 +pygments/lexers/capnproto.py,sha256=kc3rT95GkeQmrW1LeP5HMVb7Nk8sqXkW6OJkkWIHYbA,2177 +pygments/lexers/carbon.py,sha256=_M-0YbofjZMrJIaiXKoT6wpkd3_6fFq-OdSZ7V961I4,3214 +pygments/lexers/cddl.py,sha256=7Wri2q2yKexWo0CD7s2c7AoCAMbrwyEE6f_gz5B6x1Y,5079 +pygments/lexers/chapel.py,sha256=SvZXNJijW0greFToDHZQ0yeo4_3niyTx31Iz_yLctck,5159 +pygments/lexers/clean.py,sha256=_oV3Tbmrpl3S1phPMS6gyMWyGZGj6Wy0q8adpf5vunY,6421 +pygments/lexers/codeql.py,sha256=hAX51uWeG5Zk9JhXSnOxPMaznFOpaX4ZnZHZ2krrPGk,2579 +pygments/lexers/comal.py,sha256=0fcTyV5h36zPlxoQPWWGet2yaYi5ESXiFpx6EbsqP00,3182 +pygments/lexers/compiled.py,sha256=PRimy7eb2weP7X6bEukz1JaSLuQAETO34K7maHLGbxA,1429 +pygments/lexers/configs.py,sha256=YDBIWV_R2SiRb0Cbxol-S8RRieDfAg_YcThc1BmZ90I,50925 +pygments/lexers/console.py,sha256=MrTIkXDYQ71z0yDepwbpO9WwXPQRPHAFAOvt_ngscxU,4183 +pygments/lexers/cplint.py,sha256=wPs_Zh0OJ2_UUeF9_mu_r-X_65DJSWMCTKOmOyjWLz8,1392 +pygments/lexers/crystal.py,sha256=k8Xy8TpfGKTPvsP1WikxILScILD8iXZ5qceLZopsLYE,15757 +pygments/lexers/csound.py,sha256=7KHoJv8wtuIe9dques4mFFkQLULcGQ23dgZ_KBd0f_k,17001 +pygments/lexers/css.py,sha256=OVjsd0Kn9pNH6iltS4ikjy9nnilPlCVx-VAZ26n3UJ8,26439 +pygments/lexers/d.py,sha256=ee5oImP1BcHYZ93UwXoHIzw6BztgR3WCCv3ksu2J-o0,9923 +pygments/lexers/dalvik.py,sha256=0f5mB5y8g0l1ID2liJ_5qM2NjyR_SBs7ckuIDeNbbj8,4609 +pygments/lexers/data.py,sha256=MhLXoZXYMZFmmKlqL8RV5zp-eUwVb0yFzsyzXYrpKiw,27049 +pygments/lexers/dax.py,sha256=N-5fxukBfFtFCT2LJoyg1VJsfldWHxXKLY3ZPLnPrig,8101 +pygments/lexers/devicetree.py,sha256=Tig-tTSrpmGzbGxN2ka4MMTiC344roav9A4hoc9o_kw,4826 +pygments/lexers/diff.py,sha256=-627lmuYpJ2uUVUM_orVGgXJGXIBGSVHbmlqflCEeaM,5385 +pygments/lexers/dns.py,sha256=ElzSN3IEoRs1g6iWMnzVIV8H0x9WSEF1wBjm2a0ByxE,3894 +pygments/lexers/dotnet.py,sha256=GmoaOxSoITkYdAUaVJ0Z1RQa6MvcRxh1gQ3XxgEs4X8,39444 +pygments/lexers/dsls.py,sha256=a6Jdv3w1aF3vpQJrnF32MNHAl6pEZkkeGB1cYv-x2Hw,36753 +pygments/lexers/dylan.py,sha256=fi8mSyni4dnGP5x1crE6BKNqLWJs4dDWdmkur-TbbNc,10412 +pygments/lexers/ecl.py,sha256=XJ66PU9EjkXJwA4f1OfC0RdfP49v8N62RZXnFVVAYNo,6374 +pygments/lexers/eiffel.py,sha256=m2eVPDG9J-VXieCeOy0S7zHPjiFHQB9F6bOIy-K3MDQ,2693 +pygments/lexers/elm.py,sha256=Xj3HlbUTEkEUFwhem4NCujx55tQ2TS61_Kcf6BCPHAI,3155 +pygments/lexers/elpi.py,sha256=RZqAVzdxfA_BqBmtMHj8ATw5f9e24SKL-QeO14QuKk4,7904 +pygments/lexers/email.py,sha256=NPlGc2L6F3KWWDop3ZOJGpUM6LDnOEqKZj1YJG3vP2M,4807 +pygments/lexers/erlang.py,sha256=2aUlVBVFtQdR2QISsDeKTOPjGrV7r1ckyXL17KJot9c,19150 +pygments/lexers/esoteric.py,sha256=tmJ9Pa1wYtYgR6yDqgp3zDYuXPFzXw7SLTHOH_eE3p0,10503 +pygments/lexers/ezhil.py,sha256=tbGYtGnqZAB8ffnyPdeMMJHtKYJ7OAciUFRrR_8QpXM,3275 +pygments/lexers/factor.py,sha256=HBUqNcwd4VplYw30ScuC8YgdipFAYiqjRgWsyT0s4xQ,19533 +pygments/lexers/fantom.py,sha256=w9IU1x61Codd7Oxv5DpvVlkVPn_bfvVLiP8Ae3660zM,10234 +pygments/lexers/felix.py,sha256=DvPOs_Em6fFtUBQCaZWWHWgnvAFeBrDe97Cy9XyQ8ps,9658 +pygments/lexers/fift.py,sha256=Q9OLJivp4ngqFso7APCvX85h-ghdbp9ZqpP8GKHws1M,1647 +pygments/lexers/floscript.py,sha256=TcyuCiv9bAb89x1_7_Zq6nUhsdsHAF2DPsKZ6m1W1NU,2670 +pygments/lexers/forth.py,sha256=4e0OCfJGcElkQrHInmQMucvsI9dljuPx4FYg38dyjno,7196 +pygments/lexers/fortran.py,sha256=ouvOHdMbj56j40Nrj21WCRf4rNKpuwphxmtlUVsnzhc,10385 +pygments/lexers/foxpro.py,sha256=nV8yyES39QoFmTNlM8xl3MteOsvmt6yV1l6x6xnXqIU,26298 +pygments/lexers/freefem.py,sha256=ZmZLIYLXtCK2kWqGzBmrkp7ychOy7vgfaorafUkUl1I,26916 +pygments/lexers/func.py,sha256=ZjOerj3njJcaGnHWc_npWjxb4D5O-udxBRK7RLHEibU,3703 +pygments/lexers/functional.py,sha256=4m9JlAnfpXxSkQQIrNOob2VTwin6hPLAqWuhv9aVkAg,697 +pygments/lexers/futhark.py,sha256=mCU2yvloJF5LN7uRE_8rCVqA8HAINny04HXVxjSiM4g,3746 +pygments/lexers/gcodelexer.py,sha256=t8JMWaaDjWZwdGiRGwrpsYtfjKTmibwlRyOLCiJZ8qw,877 +pygments/lexers/gdscript.py,sha256=VNOwd7KcDREvoBAfw66GjxxQygPsHH2akdzRbPNKqoQ,7569 +pygments/lexers/gleam.py,sha256=Jx6LnUpWV9pmjdSYLUMt16c3UamZ-v5X6CcuEhWxf-8,2395 +pygments/lexers/go.py,sha256=ynHVStw2XUJFlUiTS4UqY65fLkvcJBMNzoYtSNSl_BU,3786 +pygments/lexers/grammar_notation.py,sha256=ZGYcwhSvOolw1J7cA9Pc7hVpcIselaCgxwsvAf5yRgc,8046 +pygments/lexers/graph.py,sha256=X_IsdjxXZn5p9Dq4cLXyqwo4C8emcYA8NP6VZ9ZTBaU,4111 +pygments/lexers/graphics.py,sha256=IeruxvEQR1Wsu-YyLpAjkUnisLDzUrk2cd0xXrDCbjw,39148 +pygments/lexers/graphql.py,sha256=RWE_kfVUDEAnv_-SYyOi9IJUks61NvOakmUfWOlorzo,5604 +pygments/lexers/graphviz.py,sha256=DRNWwetEWasJDtiLkdqkKsQHDryJ5W80wUD2PE6oKCs,1937 +pygments/lexers/gsql.py,sha256=pzSj5Pd4vtNLES-pIdxaG0vOVTqUWE9UuOUw0RrY-oc,3993 +pygments/lexers/hare.py,sha256=eCrRPwcswXL-ZHTWNlhE1A05G9rxzS20_IqSddv2M9Y,2652 +pygments/lexers/haskell.py,sha256=sr5gq3U7xt0D2Bi41xdTsBaponX6otP1qPyRMCuxM7E,33323 +pygments/lexers/haxe.py,sha256=_MzQJTWx18kD9bP_sniBshKbtOZDRm4OZnifaOgw_aY,31169 +pygments/lexers/hdl.py,sha256=2jYX3fRWZ9mAZ_QER1WH58SvJaOdYQt0OmOxo3X2JK0,22741 +pygments/lexers/hexdump.py,sha256=VvYp_NTaE-6NUuSG4FMezwcjxbPnAz0fOWMzr3Y2Gm4,3656 +pygments/lexers/html.py,sha256=O6qkpyOylH2n1Zi1qzlmBsIEW31RfvzBn7jKTaAR2LQ,21999 +pygments/lexers/idl.py,sha256=W2QRH1j9LMaNvC5jb6MkP4dLYo_OQU6lQlCAlQveFH4,15452 +pygments/lexers/igor.py,sha256=Sv5EGBJeKy0UOyl6-GF3lBeeoWArVcMDJtQtl2RXRYo,31636 +pygments/lexers/inferno.py,sha256=cjVMyOg6jhJ6nYX333Z6KaCCeS0pNVHv4WTxyFGY8Tg,3138 +pygments/lexers/installers.py,sha256=ioK2JUPSJk9vcsoe3NASvMt-paXd1_Nn3e8WmaqJ7CE,14494 +pygments/lexers/int_fiction.py,sha256=BUjvXilUiuMF-euXEQDzQZs45jn_aLs17eTKcfEptrI,56547 +pygments/lexers/iolang.py,sha256=kMUBUqVvdHlB79ez0pFZPRf0NgiEC2SdtYUwdjnbE90,1908 +pygments/lexers/j.py,sha256=56qUbs1C7wKdZ6-WpNnxHntNqsxWroqiO7keI2yoR1o,4856 +pygments/lexers/javascript.py,sha256=muyCVZQAsXbhT7IHZkoqAkI5myhRaHze6JMAR4zILNs,63246 +pygments/lexers/jmespath.py,sha256=726PDpRr1g2Ky_x5pZORhbXofXxkfr5HXQ8eHMhX5xg,2085 +pygments/lexers/jslt.py,sha256=UOVw1J3uK-hVRWomoFK2jMS_yeuo5iqga-LhXUJI660,3703 +pygments/lexers/json5.py,sha256=GyeZ58AxKkJJiiH7JuPmakDZXropa6bDkFRguJHifqU,2505 +pygments/lexers/jsonnet.py,sha256=_T7Y16sW7nFuAoGFuyWUKCrUyJAC4FTWZVoeSt0mTXk,5639 +pygments/lexers/jsx.py,sha256=O0evHioyudtWLhVmAXRrIfkEd5KRiokgHu8l9_Kn8sM,2696 +pygments/lexers/julia.py,sha256=F0twMg0iLBNDdedsoJG4Rn5LoMciVu9cufyUVdxKQPY,11713 +pygments/lexers/jvm.py,sha256=cf5V7NOLIvB2s7RM9wghESYRCoCDyrGjRuPmY8bfGAw,72936 +pygments/lexers/kuin.py,sha256=n2lMina8SskpfA2KbPYQFwVJOSHgNYu10U5pz5YiajE,11408 +pygments/lexers/kusto.py,sha256=pyUfWLf9Q0Qwqu74DyPAbRh20lkPDLhxnExD1FVl8Z4,3480 +pygments/lexers/ldap.py,sha256=_ya4_InnSIRj-RYjGagWFZJDy1NdgQUocQzVWjiRp68,6554 +pygments/lexers/lean.py,sha256=qP_iwUQ7MJZ1C5s3KYBW8Wu6-uuVj4PAG3a2Ghjp99U,8588 +pygments/lexers/lilypond.py,sha256=o264ovGZFrcx8ZwpKRX-gjUECK1w5T8T0n6LoTjP92U,9755 +pygments/lexers/lisp.py,sha256=a5MGcmtrWTaeEj_5Uv8YMODr3dVV6s1v1_SMBh_Ch9Q,157903 +pygments/lexers/macaulay2.py,sha256=hLNDs1TdubudvqqovYN6a4Ne9JjnU4FvNE6EE2hPn8Q,34139 +pygments/lexers/make.py,sha256=wAV0KRRXTAFMliLfAKXDihQIE2VAVUvWjFZ-yuM7a08,7834 +pygments/lexers/maple.py,sha256=OBjODNLgqanyw522CE7n9thZctWi47Uua2hPBfj7KF4,7963 +pygments/lexers/markup.py,sha256=4TMRfujXvOE9xiWwTiT_fq1lau4dKSoXYac1hWMLYRs,65264 +pygments/lexers/math.py,sha256=Nspl6IZtCyh9egiYUahboWSmy4cJCVZUBxyVnCuF1ag,698 +pygments/lexers/matlab.py,sha256=QYVBdA-IRNcuWggBJNC9lpq3jgX_1w9GQwpv907VfZM,133030 +pygments/lexers/maxima.py,sha256=ha-f-JzGkjggAr5kxmVq7_uJTCcpHstQWnsLHYIhNwU,2718 +pygments/lexers/meson.py,sha256=ZpNVp7lSHwJHEj7pwXlGcy9Lftdc6MMgJiOoY2TnfM8,4345 +pygments/lexers/mime.py,sha256=l5BsFkad3agJ6KDg_IHI6nU0Ao0Y9EcwjYoYP8vQD-g,7585 +pygments/lexers/minecraft.py,sha256=bBbMbqvsVgTfO7CBxf03oGP_qOAgrw06PSzH1QF7txs,13701 +pygments/lexers/mips.py,sha256=QpgBoMPzsk1t90cIF0W_EV-QZ8LwgTapS-fSISxZcFc,4659 +pygments/lexers/ml.py,sha256=shDPgWARTzTEhGDeblV7ZW2j6yZEeBiYqx2z24SDP7A,35393 +pygments/lexers/modeling.py,sha256=2_ucVFy7Z4yoKx90E9-ASI9t4t1LIoeQ3yHarhghz-c,13764 +pygments/lexers/modula2.py,sha256=dXW0KNFu3ETgABsPMsIhdJI0DKF-KWtT831FKsz2VXw,53075 +pygments/lexers/mojo.py,sha256=imOlg8mQCoKwi_rsuMiifZrzsAsSqT2KckCs_MV5uVE,24236 +pygments/lexers/monte.py,sha256=JTx-jSrFKlWRwA1qzhPd647ETGSElwhP4YMlVrfXyX8,6292 +pygments/lexers/mosel.py,sha256=HEYOmZiANhe9VdkTpBt7mhPi_tPGBUkVsnzTh2HVdVI,9300 +pygments/lexers/ncl.py,sha256=RZXkxOK-iHspLX_sFVT0wc5H6v-pa4kKghP79fJGQPQ,64002 +pygments/lexers/nimrod.py,sha256=L8Ww5CUaP-ojywoQZXnjC08m5Be64fBynSf5aWGIaPw,6416 +pygments/lexers/nit.py,sha256=xwu2P49Hu8YxEL7mgpV5WWFw6OYF1iJg9DVnc7H1SXk,2728 +pygments/lexers/nix.py,sha256=M2E-k--F7pneuMAOae9ag4srJsKhWJ1f1fRueO6PtKM,4424 +pygments/lexers/numbair.py,sha256=KZOw96Tj7Gly-f9F8NA-tdGd53SIt5UgbpokZsfnzWM,1761 +pygments/lexers/oberon.py,sha256=uH1FkPeXCfdd0IQ_--S8SHUNaf2dnjiQZjtIT-jxu4A,4216 +pygments/lexers/objective.py,sha256=KME-J0UL2HJYAk2fHNhf7ApQe4XF8GH6qGOvYA1wPS4,23300 +pygments/lexers/ooc.py,sha256=HEjWHdQDVk7tRb_TuEb1_C5qi-peJwwyYBVAhf49MS0,3005 +pygments/lexers/openscad.py,sha256=te2iL8VkfXul_PYXlz8UK3_QtMjdmNgt0YHCYEvdEtM,3703 +pygments/lexers/other.py,sha256=OAlXzsrVDUx4Ma25fyG98U5LaBEHyt-LJZ2IHvMJJWY,1766 +pygments/lexers/parasail.py,sha256=oPcs7fRYNkV0isPSRmw-2cPfMgzTtNPi6bJOm7vq-9o,2722 +pygments/lexers/parsers.py,sha256=g4tVvf36yhT_aH_b737o0o1joojcf-XckD2HdNoNbsQ,26598 +pygments/lexers/pascal.py,sha256=4dewXkwc12f_iiMfdNDqbxb_oqAEX2dCzb5VIZ62V54,30992 +pygments/lexers/pawn.py,sha256=adsa-7sPuPk7mO7lB08auabEpeZdNewVqTBg6FS8mCk,8256 +pygments/lexers/pddl.py,sha256=a8A2keCF9qNQvVZQirgBV5fH4u3cjrta8-eZJ8tsxmY,2992 +pygments/lexers/perl.py,sha256=uYMj6amZPawLf-KjICg9LLU5-ADKzqEYKqi7VXnvm0k,39195 +pygments/lexers/phix.py,sha256=nEWWt5-OoIDapw4IJ_cNL19Th8Ztt6OIQgeuogVed10,23252 +pygments/lexers/php.py,sha256=U6wmxPM-pS-SY1N3qdv0ebUDBxLH6-EFIFcatUvg74w,13171 +pygments/lexers/pointless.py,sha256=gNcuhhOY9cEpIPyGFjMh2DItNB1UD8CmjceXkDRModE,1977 +pygments/lexers/pony.py,sha256=HKqf5AngUOdXN1N1VvSg0jTj3NUAzGBOPdXwSFamvmM,3282 +pygments/lexers/praat.py,sha256=sfVAd7zfRsI-TcCouuYMWlcU8EBxAwJ4wkh0ZuNsZ34,12679 +pygments/lexers/procfile.py,sha256=fhRTtscyMMPcPbvzjxVtXix1mYlpO-4JuWUL7Db4ENI,1158 +pygments/lexers/prolog.py,sha256=4YvPZbAFLWNZMbZhvtIulWib0PQLA_TB93gjkNywFRA,12869 +pygments/lexers/promql.py,sha256=04fS_R6HBWhpKNe3WPp_QXgIdFvJr5p6KxStZYw7yHU,4741 +pygments/lexers/prql.py,sha256=XJhd8dpEWPBIKmQXx_09-z1NyotLXIskpuzX36HykHo,8750 +pygments/lexers/ptx.py,sha256=dEaNSReAjAymIwVM_MnbdY4hd3muK79q200hYwN72cw,4504 +pygments/lexers/python.py,sha256=79A_yJqjVHp_ZeS1rY8Pcc4cwZ_7-zI2WWkeUmZgUrA,54202 +pygments/lexers/q.py,sha256=2CbJYgRu8uz8wOSp5FMr086KCC7IjSRmIODVY0uKrCA,6939 +pygments/lexers/qlik.py,sha256=9b6Q-6jXeeraIRcWtsKsYWCOlBhfmjNzIN49pUvMR-I,3696 +pygments/lexers/qvt.py,sha256=rpT5oD4awEKMs3uBCbNlzY1zCz7AVeqM-BikLTQHo8k,6106 +pygments/lexers/r.py,sha256=hzgUUH9gCsqqwTG9eCt1JVMd9RW0dy6IY_jTvRntF-U,6477 +pygments/lexers/rdf.py,sha256=FM154fB1lxfOpSpeW6bWOVld5kJBgEuYyT9udt-EcK0,16063 +pygments/lexers/rebol.py,sha256=CQ3pMaAz64UMqiQVrYoREnOgjU5QPeF_H3aaHNdVRC8,18262 +pygments/lexers/rego.py,sha256=Yi0G4secTWOL7CUhLLCzJ9gA6SJzDJpPJNij3hXixC0,1751 +pygments/lexers/rell.py,sha256=0gZStI953aFjFMyMVX_UKfwZmzV3uj3Tnl_5F20BPx0,2487 +pygments/lexers/resource.py,sha256=RDEY7iSv2hgQ3V-I1DeOKVOumNKgFqbV2Me_9Y21o10,2930 +pygments/lexers/ride.py,sha256=1zg7kGYPKRIekyuZY3f6OVqRlXyrX-sR-tHEX1M9nz4,5038 +pygments/lexers/rita.py,sha256=fCNElPik6dDIZzGd96kKgdlY4Qqp_zVI87waTBHMBfg,1130 +pygments/lexers/rnc.py,sha256=PNfnnTlnZjNvvG33BNMCqPzdA9LZEYvDsGoaDd_2mn8,1975 +pygments/lexers/roboconf.py,sha256=l6BeJIS-ZAUb3zc5GEuVIb0edrRpPFmKdffEBx74Zxg,2077 +pygments/lexers/robotframework.py,sha256=8s1U7GldhzRPGR7d8_rMSG0ZJz9ZOm-LGqBTGILwt2U,18451 +pygments/lexers/ruby.py,sha256=BxndG-3gLg7wEGvICiNDAMygQR9Qs0xrmq7DwfoLvMs,22756 +pygments/lexers/rust.py,sha256=7qD3KGVir-tUWf_bPBt4EX8l9aIWe8TblMCFI75oorc,8263 +pygments/lexers/sas.py,sha256=9hmGYhmKo7ri9oCmZdsoEFMz6z3AwKD4LcTUIn52lYU,9459 +pygments/lexers/savi.py,sha256=HCllgBe3rzP_7-2b1hSUEbE2dYz08Iysxc6Dcxj3f2c,4881 +pygments/lexers/scdoc.py,sha256=9n64S-bO1dI4x-2Kzh2jrDM6gEmB5YI7ch6ndPB4-cw,2527 +pygments/lexers/scripting.py,sha256=c-i_cMFhYEHQZZbLgJn0jyiD52vWeZVxUK6wFV2Fib4,82959 +pygments/lexers/sgf.py,sha256=ya_sG4TOvDWwzEM6cIi40XSbhkTuHCqvo-uHnNYfi5Q,1988 +pygments/lexers/shell.py,sha256=si6MAn6S7pHfyX65NkwQdjxtLtEu1M4l7K2lUHvyzWw,36384 +pygments/lexers/sieve.py,sha256=CXR9S1nGeVTln2u5R600hxgkAmJFVVTTTBh_k3aw-pk,2517 +pygments/lexers/slash.py,sha256=molh5sNG8UtheHffQGjjHLxVtyg2oCp4B8cvgDyf004,8487 +pygments/lexers/smalltalk.py,sha256=q52NHegl3pjn1jMkJWA9J0nOA_A5VzUULZAPgb-6uNU,7207 +pygments/lexers/smithy.py,sha256=hqEImo4B-i0hddNo1r0k5eHLOlArtRW4W5PsLBdllk4,2662 +pygments/lexers/smv.py,sha256=D51In9Qr2nWFicYAOX_bJpeFgmJ3BUkEXnvXPmA04D4,2808 +pygments/lexers/snobol.py,sha256=BX_1VPUZi-ckKCYlF2sttQprF2bLUHOi8blhInFHv9s,2781 +pygments/lexers/solidity.py,sha256=pz0DZ0xiHwufhbQ9hdCPrHMjA7NMsa6hxZ1nO-A4Y3E,3166 +pygments/lexers/soong.py,sha256=TVqBJzJxLwCEDmb5Aix2_AVuZILYyPWcAzFbzINNQAM,2342 +pygments/lexers/sophia.py,sha256=MAkWLYxhHJNcc3UUzWD3VDLzVRbf6IAd2uz4q7DY3wI,3379 +pygments/lexers/special.py,sha256=8gpTiLICFNwIcahm282mi8Nqi_6gwYMsAfjJIM2Bq6k,3588 +pygments/lexers/spice.py,sha256=UcrjK2KJDDKSEgEOeLXTayqRwirWdsywrfH9MqwPPIY,2801 +pygments/lexers/sql.py,sha256=zz_TFZtf5R29cvkBFG1PDJ-0KKrY7FjA-RDky-gfNlk,41656 +pygments/lexers/srcinfo.py,sha256=MHj02VB7WP3AcoOz1WVYAqNM_3oFLjEaAda075kXVBU,1749 +pygments/lexers/stata.py,sha256=KojmkxWHlEk-HvmxI313a52nzH_JHNqfv6r3jJoFDy8,6418 +pygments/lexers/supercollider.py,sha256=H-qwP6sUaotemsXxuugpui6KnU3jtIdDfS3bGt3Jvh4,3700 +pygments/lexers/tablegen.py,sha256=ryuzw-ArLdvlY55YJBn6ebOzDo3L8UnbR5xcZB8xMso,4012 +pygments/lexers/tact.py,sha256=YbOWYNp302ZBPM5affzM4-CudJ4xRZyJb-_vSDCozCo,10812 +pygments/lexers/tal.py,sha256=xZYmhv8mBr-A3oeoFkcSP7nDbX1r21kKOnhsLTtL3bE,2907 +pygments/lexers/tcl.py,sha256=MXMAo2wCZeq5oR7VzsNbamawun_vMOk2gOEDnGk6yOc,5515 +pygments/lexers/teal.py,sha256=pgpPi9xWPumSr-heSpGBGDcU5s3qN0aFUj2maHLE3MM,3525 +pygments/lexers/templates.py,sha256=ndJMdue33qQ_thsortAra1fm_-szMN40S5bZXBLY54w,75734 +pygments/lexers/teraterm.py,sha256=YCdvILRq-FdOJ_HfiIkYVToH3c6I2QRbQoH17Q49Hx8,10045 +pygments/lexers/testing.py,sha256=GF5SpanGwjgKKoYari32SdtdOWWXXje8xVX5-ZzTjLg,10813 +pygments/lexers/text.py,sha256=yq6mOLz3PizKNMm4_Y8UHn9vEeBfqEY5W-3M7dk1jYs,1071 +pygments/lexers/textedit.py,sha256=V-Ijh0eULTWtx3S_6vT7JcyjQO-CNirpAbEpkczLGCE,7763 +pygments/lexers/textfmts.py,sha256=WSiJDzNKCcOsBoTU4NCYU33ti5ZHGi0Px29eGjT6pB0,15527 +pygments/lexers/theorem.py,sha256=c-eg6tIYWUbxSYgrOtLZfFxro4g91JcAIwrIJGLPooU,17903 +pygments/lexers/thingsdb.py,sha256=FNKjArS1vadHEN3ZXaZdDLqvcG59GbF6Ak5M8RMsTLU,6257 +pygments/lexers/tlb.py,sha256=vWsFq_MrIrzgG2q-qdzpcoNiv9KkNow4x9ebs9_HAwA,1453 +pygments/lexers/tls.py,sha256=GZ1lvZ8PUk1-LThq1KuiqSEnMqJVqiHo_A-16aKuJOc,1543 +pygments/lexers/tnt.py,sha256=MNYTfkix0x5L1pDV8V8zGLS7GU8z7bt-wpiBap2W09U,10459 +pygments/lexers/trafficscript.py,sha256=1Tawom6bKJM-u1kYey21xFaHep3D9kl62rV3RaHSvcI,1509 +pygments/lexers/typoscript.py,sha256=dWAuOYYk0X4xE_fxKgcXz-sMYlG2wxQR4m_d7PW2PYs,8335 +pygments/lexers/typst.py,sha256=ZtV37NCQCoSqEKrAhffuZtUp1kDahKQx8PxMLrR2G6k,7170 +pygments/lexers/ul4.py,sha256=joM-US0-2BEWRHHK6eyZ-Y--306YgbMrevMY0hg8QTY,10502 +pygments/lexers/unicon.py,sha256=9D-GilKOqIEaowGHmdvHRjhqyigRk320ARAr-G_snew,18628 +pygments/lexers/urbi.py,sha256=j87k6fe60kZdbJ6AJA4g9E0no1EP0bxJY06UVP0YgnU,6085 +pygments/lexers/usd.py,sha256=tP9kHPZUJcE_flPvKEsF7wTck4FuQW75S8ELh4IYJEI,3307 +pygments/lexers/varnish.py,sha256=INCtYbol1yV_NXMh51CMDZDacEHgiB3SmR3H5uW-Fkc,7476 +pygments/lexers/verification.py,sha256=QISJmmz7cmYaXZphW5so4PfdKJo0rdZWuj_de64mafk,3937 +pygments/lexers/verifpal.py,sha256=0iZTQWawF9f7lFZnFNPTwYRiu6L_25PtEI83tuCAmKY,2664 +pygments/lexers/vip.py,sha256=pM5xFoeu-2GPWqAVzZJe6xPYr6WJPlozVI5084SHQ80,5714 +pygments/lexers/vyper.py,sha256=rw2yD9c2L7yPtXqKPd0RdxJSZK-aJbW5jEa0gHfKEO0,5618 +pygments/lexers/web.py,sha256=YMrxoHlKlQwfFJlae9_T9F1Vp03YA7IWsmgqLzh6pgI,916 +pygments/lexers/webassembly.py,sha256=Y48VdBp8b4SI10PEt8biOm-gteYgmNc_bRR-KvulfnQ,5701 +pygments/lexers/webidl.py,sha256=MQMaZFskluB29lMGpiGP2f6fzoja4vV8FtoCGFQH6fM,10519 +pygments/lexers/webmisc.py,sha256=GnSTSHfsAUGy5DYF_qwFmMsyabnzTstaEG96Fub53fk,40567 +pygments/lexers/wgsl.py,sha256=vgDtY_q42TGRvcsyS7viSadU8D3eHvatfoCNNnEP0zE,11883 +pygments/lexers/whiley.py,sha256=MC2V7o1s7LIoLy0Fk-i8OymBoN0dpK2BPjIrdQwsnVk,4020 +pygments/lexers/wowtoc.py,sha256=XnLSSX7p_RkwZIzlmYXO873d4byX9-A3dfvzNL5Eocw,4079 +pygments/lexers/wren.py,sha256=2lhzwpS27xW6nERY_NeODgNN9X6mB7vl3odXSPngqY8,3232 +pygments/lexers/x10.py,sha256=77pAyohtv9PFwPvJPGgq-Vw8tEXo9Sny1MnTchFpTTI,1946 +pygments/lexers/xorg.py,sha256=LUKU91t1Opc3W_F64UGzx0nB-HqKlN3Cn_6tFzt5IYw,928 +pygments/lexers/yang.py,sha256=yIvwteHWBWL2-8zZscnCPJOnq3rMOXh5lxJujywA_Zo,4502 +pygments/lexers/yara.py,sha256=_ISzhko7v9AhJ-1cWINZSyG3my2vJOyFSHxSjm4VdTY,2430 +pygments/lexers/zig.py,sha256=q0tuplpRFAUSS29hg_XiRH22Ctve2EFAT5xo7TNAlrk,3975 +pygments/modeline.py,sha256=me8g5rySidvPtMBOrDy2O1sMqZd02lBHMY5KDZefUws,1008 +pygments/plugin.py,sha256=P6zIw-vkSQ0k1WKHrzbBTjpwlCZPbR-6Qe_dO9Bjdu0,1928 +pygments/regexopt.py,sha256=d2hTvazlow5zzZIOCVnfeEG2CY0GrY_igH1kCSSf7ow,3308 +pygments/scanner.py,sha256=DtoLi1pOKpNu-6jiakJpSQLUi_ep29SQQhv7oAwYWME,3095 +pygments/sphinxext.py,sha256=qmiWv5b7qq6bNUT2Y2wZejV2ImQmvtzGJFg6LcGENl0,7901 +pygments/style.py,sha256=Hrie373bgWU81ZNwVjZM-GNBoxBxVe1W1Tr3MzJLdkY,6411 +pygments/styles/__init__.py,sha256=2vgGKnbyt0nf_CSDEtMhHxppPSAPr2jafzl5FiXFuGs,2009 +pygments/styles/__pycache__/__init__.cpython-310.pyc,, +pygments/styles/__pycache__/_mapping.cpython-310.pyc,, +pygments/styles/__pycache__/abap.cpython-310.pyc,, +pygments/styles/__pycache__/algol.cpython-310.pyc,, +pygments/styles/__pycache__/algol_nu.cpython-310.pyc,, +pygments/styles/__pycache__/arduino.cpython-310.pyc,, +pygments/styles/__pycache__/autumn.cpython-310.pyc,, +pygments/styles/__pycache__/borland.cpython-310.pyc,, +pygments/styles/__pycache__/bw.cpython-310.pyc,, +pygments/styles/__pycache__/coffee.cpython-310.pyc,, +pygments/styles/__pycache__/colorful.cpython-310.pyc,, +pygments/styles/__pycache__/default.cpython-310.pyc,, +pygments/styles/__pycache__/dracula.cpython-310.pyc,, +pygments/styles/__pycache__/emacs.cpython-310.pyc,, +pygments/styles/__pycache__/friendly.cpython-310.pyc,, +pygments/styles/__pycache__/friendly_grayscale.cpython-310.pyc,, +pygments/styles/__pycache__/fruity.cpython-310.pyc,, +pygments/styles/__pycache__/gh_dark.cpython-310.pyc,, +pygments/styles/__pycache__/gruvbox.cpython-310.pyc,, +pygments/styles/__pycache__/igor.cpython-310.pyc,, +pygments/styles/__pycache__/inkpot.cpython-310.pyc,, +pygments/styles/__pycache__/lightbulb.cpython-310.pyc,, +pygments/styles/__pycache__/lilypond.cpython-310.pyc,, +pygments/styles/__pycache__/lovelace.cpython-310.pyc,, +pygments/styles/__pycache__/manni.cpython-310.pyc,, +pygments/styles/__pycache__/material.cpython-310.pyc,, +pygments/styles/__pycache__/monokai.cpython-310.pyc,, +pygments/styles/__pycache__/murphy.cpython-310.pyc,, +pygments/styles/__pycache__/native.cpython-310.pyc,, +pygments/styles/__pycache__/nord.cpython-310.pyc,, +pygments/styles/__pycache__/onedark.cpython-310.pyc,, +pygments/styles/__pycache__/paraiso_dark.cpython-310.pyc,, +pygments/styles/__pycache__/paraiso_light.cpython-310.pyc,, +pygments/styles/__pycache__/pastie.cpython-310.pyc,, +pygments/styles/__pycache__/perldoc.cpython-310.pyc,, +pygments/styles/__pycache__/rainbow_dash.cpython-310.pyc,, +pygments/styles/__pycache__/rrt.cpython-310.pyc,, +pygments/styles/__pycache__/sas.cpython-310.pyc,, +pygments/styles/__pycache__/solarized.cpython-310.pyc,, +pygments/styles/__pycache__/staroffice.cpython-310.pyc,, +pygments/styles/__pycache__/stata_dark.cpython-310.pyc,, +pygments/styles/__pycache__/stata_light.cpython-310.pyc,, +pygments/styles/__pycache__/tango.cpython-310.pyc,, +pygments/styles/__pycache__/trac.cpython-310.pyc,, +pygments/styles/__pycache__/vim.cpython-310.pyc,, +pygments/styles/__pycache__/vs.cpython-310.pyc,, +pygments/styles/__pycache__/xcode.cpython-310.pyc,, +pygments/styles/__pycache__/zenburn.cpython-310.pyc,, +pygments/styles/_mapping.py,sha256=6lovFUE29tz6EsV3XYY4hgozJ7q1JL7cfO3UOlgnS8w,3312 +pygments/styles/abap.py,sha256=T7Ad121Kjz8ZbuphyhulULwXyvXubSS6Czc0MDOFiJ8,752 +pygments/styles/algol.py,sha256=6v6ZXLxPJsm_1qPqOu5ihAuWhVk644NdPXPcZqiOTTI,2265 +pygments/styles/algol_nu.py,sha256=581Lf5db303g7zDb7z-VlvGlFNpbXMIlAnrRBxtjGts,2286 +pygments/styles/arduino.py,sha256=oFF5gjfbQNBigKxFhC7giUIHWl0ieCshhsm9UxCIzqg,4560 +pygments/styles/autumn.py,sha256=P9IX5utjDvdJgevM0kNGwE-wvVysRh1lgMkjO1dhDDE,2198 +pygments/styles/borland.py,sha256=V8qTD8SrS0wLohp2udIirlijbHfPoIlWZkYpqxSdkSw,1614 +pygments/styles/bw.py,sha256=e4Fo6Kyax2aRhqKsjsqvi2CW6lkU9QnjKoPrESZAj-I,1409 +pygments/styles/coffee.py,sha256=0jxdctCEKbR1AqzA59fFQK4sVBdErrRkGCUn6fPF4sg,2311 +pygments/styles/colorful.py,sha256=opkfOcjFTtDn9Fty6ogM7okFMB6bA0iR0VtTdBPE9NE,2835 +pygments/styles/default.py,sha256=WFLDucKJS_ac5Jqutmglbz4ITc4jTTQEOnqLIMpSttA,2591 +pygments/styles/dracula.py,sha256=H-EM1WM3Ixd2OBY9bzoObKl4IzdmhirfDVFbJ9Wsi0Q,2185 +pygments/styles/emacs.py,sha256=iEYWPgQrDQk4RdDf8-g7j4mtoFRzo2xcKvZE1ys9mJU,2538 +pygments/styles/friendly.py,sha256=S43XMczW53tKftmarEL4-nTroPVdN6k8fbNrINzR_QU,2607 +pygments/styles/friendly_grayscale.py,sha256=el2E804DEkKZ6ApXt3N5FTmHAkIhqkJj-omhE1E8mdE,2831 +pygments/styles/fruity.py,sha256=mrNDixp39QIoitRBo-yMOr8tnYLAwGd0EIMw2A6Gd8g,1327 +pygments/styles/gh_dark.py,sha256=yb4EOBAYsQ9g5IGEOqyZ5LKI-MUbwz32l9WB5EcMLaA,3593 +pygments/styles/gruvbox.py,sha256=_QZtRq9y1s3NYADHqek-DXELQqueOnVDXvWJ_1aTGgo,3390 +pygments/styles/igor.py,sha256=QO_M5-Z1xIxVnusEU4LZr4VT--nTERVt-cpfbnOv4yk,740 +pygments/styles/inkpot.py,sha256=bJvNWikqnAWLjx2AH4t_tW4jR0TsrUyVFXFVPAfOgkM,2407 +pygments/styles/lightbulb.py,sha256=CnDv1mF1X5k1msVvRS_diR4tkp06E_jg0tK9cdHEFCQ,3175 +pygments/styles/lilypond.py,sha256=gSCiazPPWfR_9-BV5BYHe6-2gSor4vOHnz3nyFQI2QA,2069 +pygments/styles/lovelace.py,sha256=vZ-S9tS-QUOwfA0RHYBhSTRE3h1ZU-bZnuMW7O6ksyw,3181 +pygments/styles/manni.py,sha256=dpsJC1Zees0e9IcWirqWuSzQxwD0jIbjhFquM23dmWM,2446 +pygments/styles/material.py,sha256=eyyAaJgp1Fnjl4-_D39_l1wH5CW4W0VWScQ3Q0jtAgU,4204 +pygments/styles/monokai.py,sha256=3CwJJm_YVGibzFi8nhK_b5d4cNzgV8z-L6RzC1UVA7Q,5187 +pygments/styles/murphy.py,sha256=HsPd80nObb3Ov3-7yJQbnJr3z9mCyz30Pjn_nkWkMYo,2808 +pygments/styles/native.py,sha256=oazEJUbuaHqqOZR5vx-jIhTPIw7dC6QZnKxW-xLr7fs,2046 +pygments/styles/nord.py,sha256=t7fZj04LUgsLaHpio66FqOGMKb7a2VC3teUlmInPfRg,5394 +pygments/styles/onedark.py,sha256=UXrMzVvA9OVP7OhCQ5gL0CaZrk5jo_I84HJm7LEN5GQ,2126 +pygments/styles/paraiso_dark.py,sha256=rx5_j4gnZRy2j-3hAhFmWpnjnd-Vfz3Z7fcwEXRUGm0,5665 +pygments/styles/paraiso_light.py,sha256=iERjbYRemqgsisv_9TjanBig4bJ_-80xRz5B5puhMc0,5671 +pygments/styles/pastie.py,sha256=mnKebFiJ2do9A_wTPq4tKtgw-TQqpb0lP3kNbemQ2to,2528 +pygments/styles/perldoc.py,sha256=-e1T4QBEQNE_l17RYW-WBowNprg2uL_hFjhSDcaMiDM,2233 +pygments/styles/rainbow_dash.py,sha256=YP2HPVXJLmOy8Yz8p8u5GbkAyuKxLlNmu6ITZBMa1Mc,2393 +pygments/styles/rrt.py,sha256=vs4pnWwmMIQR0eGczp06AYazsYiR0KFcRiRUzSf3rXc,1295 +pygments/styles/sas.py,sha256=ER-JjZgU2wEJWk5K06iHAFPjVYD1iMkvjjE0rlNOt2Y,1443 +pygments/styles/solarized.py,sha256=VdtLYhQ7xDj_iTHP_Ekr6rAdMcE3fRSrglngVSal63M,4250 +pygments/styles/staroffice.py,sha256=peExkIBqPkRhqXFpW99n49t6pMwehI_pDYVUmQwkgdA,834 +pygments/styles/stata_dark.py,sha256=N6imWykqHoT5drOn-sVRUzt1AZMKG3HHU-Q7LKz2d50,1260 +pygments/styles/stata_light.py,sha256=YW7ih4teXoEuUHImOK2rGSCVxfnj43tlcKPXUsrDkRg,1292 +pygments/styles/tango.py,sha256=Af0WVTxpH_cUdHr_ua69JDijTLI5aG1RmBTF7o2KTgk,7140 +pygments/styles/trac.py,sha256=-h5iU-LjSmt-dQ7y5jXwJ5LQ9ABR5QD5RlPRjhnzmv8,1984 +pygments/styles/vim.py,sha256=dWqCVC2YT45dLSpMTwLBPkKYgRsT1-cFf7ZHoc2PQpA,2022 +pygments/styles/vs.py,sha256=7HJehhtiHE5nibjC3r3X-aYHBm5BccL33LgO_4anEiU,1133 +pygments/styles/xcode.py,sha256=HmB6aPkxvmo4za5DijhLb5AXSyv6UbWnwOUoRUNBaZA,1507 +pygments/styles/zenburn.py,sha256=Ax7iBbMzvVQNTpT3YdMwCEkL-nIXnpr60aVrR4Lpa6o,2206 +pygments/token.py,sha256=DVil5T2ltHkTgQTUYy1dMtgyigjavCs1ypE4Qf2CrGo,6229 +pygments/unistring.py,sha256=Z4w4HfOVUhueCURRkfhAqQ2b-69UzkhY4xuHevYEy5g,63211 +pygments/util.py,sha256=zk935tJSpwSA9zxNmV1TuhcEP0MfboXiRZSGQnLPEqk,10046 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/REQUESTED b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/REQUESTED new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/WHEEL b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/WHEEL new file mode 100644 index 0000000000000000000000000000000000000000..b1b94fd58e7e9ed0ef3449473bc48de68afcc3fe --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/WHEEL @@ -0,0 +1,4 @@ +Wheel-Version: 1.0 +Generator: hatchling 1.29.0 +Root-Is-Purelib: true +Tag: py3-none-any diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/direct_url.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/direct_url.json new file mode 100644 index 0000000000000000000000000000000000000000..720e85bf5034d8abc2c571bad372921352c7e2d1 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/direct_url.json @@ -0,0 +1 @@ +{"dir_info": {}, "url": "file:///home/conda/feedstock_root/build_artifacts/pygments_1774796700044/work"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/entry_points.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/entry_points.txt new file mode 100644 index 0000000000000000000000000000000000000000..15498e35f53320bd5e1de176928daabf26be0109 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/entry_points.txt @@ -0,0 +1,2 @@ +[console_scripts] +pygmentize = pygments.cmdline:main diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/licenses/AUTHORS b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/licenses/AUTHORS new file mode 100644 index 0000000000000000000000000000000000000000..909089df67ab84b7f0d06a8b0ec0affb962ac60c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/licenses/AUTHORS @@ -0,0 +1,292 @@ +Pygments is written and maintained by Georg Brandl . + +Major developers are Tim Hatch and Armin Ronacher +. + +Other contributors, listed alphabetically, are: + +* Sam Aaron -- Ioke lexer +* Jean Abou Samra -- LilyPond lexer +* João Abecasis -- JSLT lexer +* Ali Afshar -- image formatter +* Thomas Aglassinger -- Easytrieve, JCL, Rexx, Transact-SQL and VBScript + lexers +* Maxence Ahlouche -- PostgreSQL Explain lexer +* Muthiah Annamalai -- Ezhil lexer +* Nikolay Antipov -- OpenSCAD lexer +* Kumar Appaiah -- Debian control lexer +* Andreas Amann -- AppleScript lexer +* Timothy Armstrong -- Dart lexer fixes +* Jeffrey Arnold -- R/S, Rd, BUGS, Jags, and Stan lexers +* Eiríkr Åsheim -- Uxntal lexer +* Jeremy Ashkenas -- CoffeeScript lexer +* José Joaquín Atria -- Praat lexer +* Stefan Matthias Aust -- Smalltalk lexer +* Lucas Bajolet -- Nit lexer +* Ben Bangert -- Mako lexers +* Max Battcher -- Darcs patch lexer +* Thomas Baruchel -- APL lexer +* Tim Baumann -- (Literate) Agda lexer +* Paul Baumgart, 280 North, Inc. -- Objective-J lexer +* Michael Bayer -- Myghty lexers +* Thomas Beale -- Archetype lexers +* John Benediktsson -- Factor lexer +* David Benjamin, Google LLC -- TLS lexer +* Trevor Bergeron -- mIRC formatter +* Vincent Bernat -- LessCSS lexer +* Christopher Bertels -- Fancy lexer +* Sébastien Bigaret -- QVT Operational lexer +* Jarrett Billingsley -- MiniD lexer +* Adam Blinkinsop -- Haskell, Redcode lexers +* Stéphane Blondon -- Procfile, SGF and Sieve lexers +* Frits van Bommel -- assembler lexers +* Pierre Bourdon -- bugfixes +* Martijn Braam -- Kernel log lexer, BARE lexer +* JD Browne, Google LLC -- GoogleSQL lexer +* Matthias Bussonnier -- ANSI style handling for terminal-256 formatter +* chebee7i -- Python traceback lexer improvements +* Hiram Chirino -- Scaml and Jade lexers +* Mauricio Caceres -- SAS and Stata lexers. +* Michael Camilleri, John Gabriele, sogaiu -- Janet lexer +* Daren Chandisingh -- Gleam lexer +* Ian Cooper -- VGL lexer +* David Corbett -- Inform, Jasmin, JSGF, Snowball, and TADS 3 lexers +* Leaf Corcoran -- MoonScript lexer +* Fraser Cormack -- TableGen lexer +* Gabriel Corona -- ASN.1 lexer +* Christopher Creutzig -- MuPAD lexer +* Daniël W. Crompton -- Pike lexer +* Pete Curry -- bugfixes +* Bryan Davis -- EBNF lexer +* Bruno Deferrari -- Shen lexer +* Walter Dörwald -- UL4 lexer +* Luke Drummond -- Meson lexer +* Giedrius Dubinskas -- HTML formatter improvements +* Owen Durni -- Haxe lexer +* Alexander Dutton, Oxford University Computing Services -- SPARQL lexer +* James Edwards -- Terraform lexer +* Nick Efford -- Python 3 lexer +* Sven Efftinge -- Xtend lexer +* Artem Egorkine -- terminal256 formatter +* Matthew Fernandez -- CAmkES lexer +* Paweł Fertyk -- GDScript lexer, HTML formatter improvements +* Michael Ficarra -- CPSA lexer +* James H. Fisher -- PostScript lexer +* Amanda Fitch, Google LLC -- GoogleSQL lexer +* William S. Fulton -- SWIG lexer +* Carlos Galdino -- Elixir and Elixir Console lexers +* Michael Galloy -- IDL lexer +* Naveen Garg -- Autohotkey lexer +* Simon Garnotel -- FreeFem++ lexer +* Laurent Gautier -- R/S lexer +* Alex Gaynor -- PyPy log lexer +* Richard Gerkin -- Igor Pro lexer +* Alain Gilbert -- TypeScript lexer +* Alex Gilding -- BlitzBasic lexer +* GitHub, Inc -- DASM16, Augeas, TOML, and Slash lexers +* Bertrand Goetzmann -- Groovy lexer +* Krzysiek Goj -- Scala lexer +* Rostyslav Golda -- FloScript lexer +* Andrey Golovizin -- BibTeX lexers +* Matt Good -- Genshi, Cheetah lexers +* Michał Górny -- vim modeline support +* Alex Gosse -- TrafficScript lexer +* Patrick Gotthardt -- PHP namespaces support +* Hubert Gruniaux -- C and C++ lexer improvements +* Olivier Guibe -- Asymptote lexer +* Phil Hagelberg -- Fennel lexer +* Florian Hahn -- Boogie lexer +* Martin Harriman -- SNOBOL lexer +* Matthew Harrison -- SVG formatter +* Steven Hazel -- Tcl lexer +* Dan Michael Heggø -- Turtle lexer +* Aslak Hellesøy -- Gherkin lexer +* Greg Hendershott -- Racket lexer +* Justin Hendrick -- ParaSail lexer +* Jordi Gutiérrez Hermoso -- Octave lexer +* David Hess, Fish Software, Inc. -- Objective-J lexer +* Ken Hilton -- Typographic Number Theory and Arrow lexers +* Varun Hiremath -- Debian control lexer +* Rob Hoelz -- Perl 6 lexer +* Doug Hogan -- Mscgen lexer +* Ben Hollis -- Mason lexer +* Max Horn -- GAP lexer +* Fred Hornsey -- OMG IDL Lexer +* Alastair Houghton -- Lexer inheritance facility +* Tim Howard -- BlitzMax lexer +* Dustin Howett -- Logos lexer +* Ivan Inozemtsev -- Fantom lexer +* Hiroaki Itoh -- Shell console rewrite, Lexers for PowerShell session, + MSDOS session, BC, WDiff +* Brian R. Jackson -- Tea lexer +* Alex Jeffery, ChromaWay AB -- Rell lexer +* Christian Jann -- ShellSession lexer +* Jonas Camillus Jeppesen -- Line numbers and line highlighting for + RTF-formatter +* Dennis Kaarsemaker -- sources.list lexer +* Dmitri Kabak -- Inferno Limbo lexer +* Igor Kalnitsky -- vhdl lexer +* Colin Kennedy - USD lexer +* Alexander Kit -- MaskJS lexer +* Pekka Klärck -- Robot Framework lexer +* Gerwin Klein -- Isabelle lexer +* Eric Knibbe -- Lasso lexer +* Stepan Koltsov -- Clay lexer +* Oliver Kopp - Friendly grayscale style +* Adam Koprowski -- Opa lexer +* Benjamin Kowarsch -- Modula-2 lexer +* Domen Kožar -- Nix lexer +* Oleh Krekel -- Emacs Lisp lexer +* Alexander Kriegisch -- Kconfig and AspectJ lexers +* Marek Kubica -- Scheme lexer +* Jochen Kupperschmidt -- Markdown processor +* Gerd Kurzbach -- Modelica lexer +* Jon Larimer, Google Inc. -- Smali lexer +* Olov Lassus -- Dart lexer +* Matt Layman -- TAP lexer +* Dan Lazin, Google LLC -- GoogleSQL lexer +* Kristian Lyngstøl -- Varnish lexers +* Sylvestre Ledru -- Scilab lexer +* Chee Sing Lee -- Flatline lexer +* Mark Lee -- Vala lexer +* Thomas Linder Puls -- Visual Prolog lexer +* Pete Lomax -- Phix lexer +* Valentin Lorentz -- C++ lexer improvements +* Ben Mabey -- Gherkin lexer +* Angus MacArthur -- QML lexer +* Louis Mandel -- X10 lexer +* Louis Marchand -- Eiffel lexer +* Simone Margaritelli -- Hybris lexer +* Tim Martin - World of Warcraft TOC lexer +* Kirk McDonald -- D lexer +* Gordon McGregor -- SystemVerilog lexer +* Stephen McKamey -- Duel/JBST lexer +* Brian McKenna -- F# lexer +* Charles McLaughlin -- Puppet lexer +* Kurt McKee -- Tera Term macro lexer, PostgreSQL updates, MySQL overhaul, JSON lexer +* Joe Eli McIlvain -- Savi lexer +* Lukas Meuser -- BBCode formatter, Lua lexer +* Cat Miller -- Pig lexer +* Paul Miller -- LiveScript lexer +* Hong Minhee -- HTTP lexer +* Michael Mior -- Awk lexer +* Bruce Mitchener -- Dylan lexer rewrite +* Reuben Morais -- SourcePawn lexer +* Jon Morton -- Rust lexer +* Paulo Moura -- Logtalk lexer +* Mher Movsisyan -- DTD lexer +* Dejan Muhamedagic -- Crmsh lexer +* Adrien Nayrat -- PostgreSQL Explain lexer +* Ana Nelson -- Ragel, ANTLR, R console lexers +* David Neto, Google LLC -- WebGPU Shading Language lexer +* Kurt Neufeld -- Markdown lexer +* Nam T. Nguyen -- Monokai style +* Jesper Noehr -- HTML formatter "anchorlinenos" +* Mike Nolta -- Julia lexer +* Avery Nortonsmith -- Pointless lexer +* Jonas Obrist -- BBCode lexer +* Edward O'Callaghan -- Cryptol lexer +* David Oliva -- Rebol lexer +* Pat Pannuto -- nesC lexer +* Jon Parise -- Protocol buffers and Thrift lexers +* Benjamin Peterson -- Test suite refactoring +* Ronny Pfannschmidt -- BBCode lexer +* Dominik Picheta -- Nimrod lexer +* Andrew Pinkham -- RTF Formatter Refactoring +* Clément Prévost -- UrbiScript lexer +* Tanner Prynn -- cmdline -x option and loading lexers from files +* Oleh Prypin -- Crystal lexer (based on Ruby lexer) +* Nick Psaris -- K and Q lexers +* Xidorn Quan -- Web IDL lexer +* Elias Rabel -- Fortran fixed form lexer +* raichoo -- Idris lexer +* Daniel Ramirez -- GDScript lexer +* Kashif Rasul -- CUDA lexer +* Nathan Reed -- HLSL lexer +* Justin Reidy -- MXML lexer +* Jonathon Reinhart, Google LLC -- Soong lexer +* Norman Richards -- JSON lexer +* Corey Richardson -- Rust lexer updates +* Fabrizio Riguzzi -- cplint leder +* Lubomir Rintel -- GoodData MAQL and CL lexers +* Andre Roberge -- Tango style +* Georg Rollinger -- HSAIL lexer +* Michiel Roos -- TypoScript lexer +* Konrad Rudolph -- LaTeX formatter enhancements +* Mario Ruggier -- Evoque lexers +* Miikka Salminen -- Lovelace style, Hexdump lexer, lexer enhancements +* Stou Sandalski -- NumPy, FORTRAN, tcsh and XSLT lexers +* Matteo Sasso -- Common Lisp lexer +* Joe Schafer -- Ada lexer +* Max Schillinger -- TiddlyWiki5 lexer +* Andrew Schmidt -- X++ lexer +* Ken Schutte -- Matlab lexers +* René Schwaiger -- Rainbow Dash style +* Sebastian Schweizer -- Whiley lexer +* Tassilo Schweyer -- Io, MOOCode lexers +* Pablo Seminario -- PromQL lexer +* Ted Shaw -- AutoIt lexer +* Joerg Sieker -- ABAP lexer +* Robert Simmons -- Standard ML lexer +* Kirill Simonov -- YAML lexer +* Corbin Simpson -- Monte lexer +* Ville Skyttä -- ASCII armored lexer +* Alexander Smishlajev -- Visual FoxPro lexer +* Steve Spigarelli -- XQuery lexer +* Jerome St-Louis -- eC lexer +* Camil Staps -- Clean and NuSMV lexers; Solarized style +* James Strachan -- Kotlin lexer +* Tom Stuart -- Treetop lexer +* Colin Sullivan -- SuperCollider lexer +* Ben Swift -- Extempore lexer +* tatt61880 -- Kuin lexer +* Edoardo Tenani -- Arduino lexer +* Tiberius Teng -- default style overhaul +* Jeremy Thurgood -- Erlang, Squid config lexers +* Brian Tiffin -- OpenCOBOL lexer +* Bob Tolbert -- Hy lexer +* Doug Torrance -- Macaulay2 lexer +* Matthias Trute -- Forth lexer +* Tuoa Spi T4 -- Bdd lexer +* Erick Tryzelaar -- Felix lexer +* Alexander Udalov -- Kotlin lexer improvements +* Thomas Van Doren -- Chapel lexer +* Dave Van Ee -- Uxntal lexer updates +* Daniele Varrazzo -- PostgreSQL lexers +* Abe Voelker -- OpenEdge ABL lexer +* Pepijn de Vos -- HTML formatter CTags support +* Matthias Vallentin -- Bro lexer +* Benoît Vinot -- AMPL lexer +* Linh Vu Hong -- RSL lexer +* Taavi Väänänen -- Debian control, PHP lexers +* Immanuel Washington -- Smithy lexer +* Nathan Weizenbaum -- Haml and Sass lexers +* Nathan Whetsell -- Csound lexers +* Dietmar Winkler -- Modelica lexer +* Nils Winter -- Smalltalk lexer +* Davy Wybiral -- Clojure lexer +* Whitney Young -- ObjectiveC lexer +* Diego Zamboni -- CFengine3 lexer +* Enrique Zamudio -- Ceylon lexer +* Alex Zimin -- Nemerle lexer +* Rob Zimmerman -- Kal lexer +* Evgenii Zheltonozhskii -- Maple lexer +* Vincent Zurczak -- Roboconf lexer +* Hubert Gruniaux -- C and C++ lexer improvements +* Thomas Symalla -- AMDGPU Lexer +* 15b3 -- Image Formatter improvements +* Fabian Neumann -- CDDL lexer +* Thomas Duboucher -- CDDL lexer +* Philipp Imhof -- Pango Markup formatter +* Thomas Voss -- Sed lexer +* Martin Fischer -- WCAG contrast testing +* Marc Auberer -- Spice lexer +* Amr Hesham -- Carbon lexer +* diskdance -- Wikitext lexer +* vanillajonathan -- PRQL lexer +* Nikolay Antipov -- OpenSCAD lexer +* Markus Meyer, Nextron Systems -- YARA lexer +* Hannes Römer -- Mojo lexer +* Jan Frederik Schaefer -- PDDL lexer + +Many thanks for all contributions! diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..446a1a805c8a949579fb8a9799f2bec7777349dc --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments-2.20.0.dist-info/licenses/LICENSE @@ -0,0 +1,25 @@ +Copyright (c) 2006-2022 by the respective authors (see AUTHORS file). +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + +* Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + +* Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..3a5ba538b05cab44263485e2ba88ef466f230259 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/__init__.py @@ -0,0 +1,82 @@ +""" + Pygments + ~~~~~~~~ + + Pygments is a syntax highlighting package written in Python. + + It is a generic syntax highlighter for general use in all kinds of software + such as forum systems, wikis or other applications that need to prettify + source code. Highlights are: + + * a wide range of common languages and markup formats is supported + * special attention is paid to details, increasing quality by a fair amount + * support for new languages and formats are added easily + * a number of output formats, presently HTML, LaTeX, RTF, SVG, all image + formats that PIL supports, and ANSI sequences + * it is usable as a command-line tool and as a library + * ... and it highlights even Brainfuck! + + The `Pygments master branch`_ is installable with ``easy_install Pygments==dev``. + + .. _Pygments master branch: + https://github.com/pygments/pygments/archive/master.zip#egg=Pygments-dev + + :copyright: Copyright 2006-present by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" +from io import StringIO, BytesIO + +__version__ = '2.20.0' +__docformat__ = 'restructuredtext' + +__all__ = ['lex', 'format', 'highlight'] + + +def lex(code, lexer): + """ + Lex `code` with the `lexer` (must be a `Lexer` instance) + and return an iterable of tokens. Currently, this only calls + `lexer.get_tokens()`. + """ + try: + return lexer.get_tokens(code) + except TypeError: + # Heuristic to catch a common mistake. + from pygments.lexer import RegexLexer + if isinstance(lexer, type) and issubclass(lexer, RegexLexer): + raise TypeError('lex() argument must be a lexer instance, ' + 'not a class') + raise + + +def format(tokens, formatter, outfile=None): # pylint: disable=redefined-builtin + """ + Format ``tokens`` (an iterable of tokens) with the formatter ``formatter`` + (a `Formatter` instance). + + If ``outfile`` is given and a valid file object (an object with a + ``write`` method), the result will be written to it, otherwise it + is returned as a string. + """ + try: + if not outfile: + realoutfile = getattr(formatter, 'encoding', None) and BytesIO() or StringIO() + formatter.format(tokens, realoutfile) + return realoutfile.getvalue() + else: + formatter.format(tokens, outfile) + except TypeError: + # Heuristic to catch a common mistake. + from pygments.formatter import Formatter + if isinstance(formatter, type) and issubclass(formatter, Formatter): + raise TypeError('format() argument must be a formatter instance, ' + 'not a class') + raise + + +def highlight(code, lexer, formatter, outfile=None): + """ + This is the most high-level highlighting function. It combines `lex` and + `format` in one function. + """ + return format(lex(code, lexer), formatter, outfile) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/__main__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/__main__.py new file mode 100644 index 0000000000000000000000000000000000000000..818bfc3ae6ac4b79e029f714c56101ab2b1076ea --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/__main__.py @@ -0,0 +1,17 @@ +""" + pygments.__main__ + ~~~~~~~~~~~~~~~~~ + + Main entry point for ``python -m pygments``. + + :copyright: Copyright 2006-present by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import sys +import pygments.cmdline + +try: + sys.exit(pygments.cmdline.main(sys.argv)) +except KeyboardInterrupt: + sys.exit(1) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/cmdline.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/cmdline.py new file mode 100644 index 0000000000000000000000000000000000000000..bd4a1fb43926b7f7bdd7ef5028dbe19a9137515a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/cmdline.py @@ -0,0 +1,668 @@ +""" + pygments.cmdline + ~~~~~~~~~~~~~~~~ + + Command line interface. + + :copyright: Copyright 2006-present by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import os +import sys +import shutil +import argparse +from textwrap import dedent + +from pygments import __version__, highlight +from pygments.util import ClassNotFound, OptionError, docstring_headline, \ + guess_decode, guess_decode_from_terminal, terminal_encoding, \ + UnclosingTextIOWrapper +from pygments.lexers import get_all_lexers, get_lexer_by_name, guess_lexer, \ + load_lexer_from_file, get_lexer_for_filename, find_lexer_class_for_filename +from pygments.lexers.special import TextLexer +from pygments.formatters.latex import LatexEmbeddedLexer, LatexFormatter +from pygments.formatters import get_all_formatters, get_formatter_by_name, \ + load_formatter_from_file, get_formatter_for_filename, find_formatter_class +from pygments.formatters.terminal import TerminalFormatter +from pygments.formatters.terminal256 import Terminal256Formatter, TerminalTrueColorFormatter +from pygments.filters import get_all_filters, find_filter_class +from pygments.styles import get_all_styles, get_style_by_name + + +def _parse_options(o_strs): + opts = {} + if not o_strs: + return opts + for o_str in o_strs: + if not o_str.strip(): + continue + o_args = o_str.split(',') + for o_arg in o_args: + o_arg = o_arg.strip() + try: + o_key, o_val = o_arg.split('=', 1) + o_key = o_key.strip() + o_val = o_val.strip() + except ValueError: + opts[o_arg] = True + else: + opts[o_key] = o_val + return opts + + +def _parse_filters(f_strs): + filters = [] + if not f_strs: + return filters + for f_str in f_strs: + if ':' in f_str: + fname, fopts = f_str.split(':', 1) + filters.append((fname, _parse_options([fopts]))) + else: + filters.append((f_str, {})) + return filters + + +def _print_help(what, name): + try: + if what == 'lexer': + cls = get_lexer_by_name(name) + print(f"Help on the {cls.name} lexer:") + print(dedent(cls.__doc__)) + elif what == 'formatter': + cls = find_formatter_class(name) + print(f"Help on the {cls.name} formatter:") + print(dedent(cls.__doc__)) + elif what == 'filter': + cls = find_filter_class(name) + print(f"Help on the {name} filter:") + print(dedent(cls.__doc__)) + return 0 + except (AttributeError, ValueError): + print(f"{what} not found!", file=sys.stderr) + return 1 + + +def _print_list(what): + if what == 'lexer': + print() + print("Lexers:") + print("~~~~~~~") + + info = [] + for fullname, names, exts, _ in get_all_lexers(): + tup = (', '.join(names)+':', fullname, + exts and '(filenames ' + ', '.join(exts) + ')' or '') + info.append(tup) + info.sort() + for i in info: + print(('* {}\n {} {}').format(*i)) + + elif what == 'formatter': + print() + print("Formatters:") + print("~~~~~~~~~~~") + + info = [] + for cls in get_all_formatters(): + doc = docstring_headline(cls) + tup = (', '.join(cls.aliases) + ':', doc, cls.filenames and + '(filenames ' + ', '.join(cls.filenames) + ')' or '') + info.append(tup) + info.sort() + for i in info: + print(('* {}\n {} {}').format(*i)) + + elif what == 'filter': + print() + print("Filters:") + print("~~~~~~~~") + + for name in get_all_filters(): + cls = find_filter_class(name) + print("* " + name + ':') + print(f" {docstring_headline(cls)}") + + elif what == 'style': + print() + print("Styles:") + print("~~~~~~~") + + for name in get_all_styles(): + cls = get_style_by_name(name) + print("* " + name + ':') + print(f" {docstring_headline(cls)}") + + +def _print_list_as_json(requested_items): + import json + result = {} + if 'lexer' in requested_items: + info = {} + for fullname, names, filenames, mimetypes in get_all_lexers(): + info[fullname] = { + 'aliases': names, + 'filenames': filenames, + 'mimetypes': mimetypes + } + result['lexers'] = info + + if 'formatter' in requested_items: + info = {} + for cls in get_all_formatters(): + doc = docstring_headline(cls) + info[cls.name] = { + 'aliases': cls.aliases, + 'filenames': cls.filenames, + 'doc': doc + } + result['formatters'] = info + + if 'filter' in requested_items: + info = {} + for name in get_all_filters(): + cls = find_filter_class(name) + info[name] = { + 'doc': docstring_headline(cls) + } + result['filters'] = info + + if 'style' in requested_items: + info = {} + for name in get_all_styles(): + cls = get_style_by_name(name) + info[name] = { + 'doc': docstring_headline(cls) + } + result['styles'] = info + + json.dump(result, sys.stdout) + +def main_inner(parser, argns): + if argns.help: + parser.print_help() + return 0 + + if argns.V: + print(f'Pygments version {__version__}, (c) 2006-present by Georg Brandl, Matthäus ' + 'Chajdas and contributors.') + return 0 + + def is_only_option(opt): + return not any(v for (k, v) in vars(argns).items() if k != opt) + + # handle ``pygmentize -L`` + if argns.L is not None: + arg_set = set() + for k, v in vars(argns).items(): + if v: + arg_set.add(k) + + arg_set.discard('L') + arg_set.discard('json') + + if arg_set: + parser.print_help(sys.stderr) + return 2 + + # print version + if not argns.json: + main(['', '-V']) + allowed_types = {'lexer', 'formatter', 'filter', 'style'} + largs = [arg.rstrip('s') for arg in argns.L] + if any(arg not in allowed_types for arg in largs): + parser.print_help(sys.stderr) + return 0 + if not largs: + largs = allowed_types + if not argns.json: + for arg in largs: + _print_list(arg) + else: + _print_list_as_json(largs) + return 0 + + # handle ``pygmentize -H`` + if argns.H: + if not is_only_option('H'): + parser.print_help(sys.stderr) + return 2 + what, name = argns.H + if what not in ('lexer', 'formatter', 'filter'): + parser.print_help(sys.stderr) + return 2 + return _print_help(what, name) + + # parse -O options + parsed_opts = _parse_options(argns.O or []) + + # parse -P options + for p_opt in argns.P or []: + try: + name, value = p_opt.split('=', 1) + except ValueError: + parsed_opts[p_opt] = True + else: + parsed_opts[name] = value + + # encodings + inencoding = parsed_opts.get('inencoding', parsed_opts.get('encoding')) + outencoding = parsed_opts.get('outencoding', parsed_opts.get('encoding')) + + # handle ``pygmentize -N`` + if argns.N: + lexer = find_lexer_class_for_filename(argns.N) + if lexer is None: + lexer = TextLexer + + print(lexer.aliases[0]) + return 0 + + # handle ``pygmentize -C`` + if argns.C: + inp = sys.stdin.buffer.read() + try: + lexer = guess_lexer(inp, inencoding=inencoding) + except ClassNotFound: + lexer = TextLexer + + print(lexer.aliases[0]) + return 0 + + # handle ``pygmentize -S`` + S_opt = argns.S + a_opt = argns.a + if S_opt is not None: + f_opt = argns.f + if not f_opt: + parser.print_help(sys.stderr) + return 2 + if argns.l or argns.INPUTFILE: + parser.print_help(sys.stderr) + return 2 + + try: + parsed_opts['style'] = S_opt + fmter = get_formatter_by_name(f_opt, **parsed_opts) + except ClassNotFound as err: + print(err, file=sys.stderr) + return 1 + + print(fmter.get_style_defs(a_opt or '')) + return 0 + + # if no -S is given, -a is not allowed + if argns.a is not None: + parser.print_help(sys.stderr) + return 2 + + # parse -F options + F_opts = _parse_filters(argns.F or []) + + # -x: allow custom (eXternal) lexers and formatters + allow_custom_lexer_formatter = bool(argns.x) + + # select lexer + lexer = None + + # given by name? + lexername = argns.l + if lexername: + # custom lexer, located relative to user's cwd + if allow_custom_lexer_formatter and '.py' in lexername: + try: + filename = None + name = None + if ':' in lexername: + filename, name = lexername.rsplit(':', 1) + + if '.py' in name: + # This can happen on Windows: If the lexername is + # C:\lexer.py -- return to normal load path in that case + name = None + + if filename and name: + lexer = load_lexer_from_file(filename, name, + **parsed_opts) + else: + lexer = load_lexer_from_file(lexername, **parsed_opts) + except ClassNotFound as err: + print('Error:', err, file=sys.stderr) + return 1 + else: + try: + lexer = get_lexer_by_name(lexername, **parsed_opts) + except (OptionError, ClassNotFound) as err: + print('Error:', err, file=sys.stderr) + return 1 + + # read input code + code = None + + if argns.INPUTFILE: + if argns.s: + print('Error: -s option not usable when input file specified', + file=sys.stderr) + return 2 + + infn = argns.INPUTFILE + try: + with open(infn, 'rb') as infp: + code = infp.read() + except Exception as err: + print('Error: cannot read infile:', err, file=sys.stderr) + return 1 + if not inencoding: + code, inencoding = guess_decode(code) + + # do we have to guess the lexer? + if not lexer: + try: + lexer = get_lexer_for_filename(infn, code, **parsed_opts) + except ClassNotFound as err: + if argns.g: + try: + lexer = guess_lexer(code, **parsed_opts) + except ClassNotFound: + lexer = TextLexer(**parsed_opts) + else: + print('Error:', err, file=sys.stderr) + return 1 + except OptionError as err: + print('Error:', err, file=sys.stderr) + return 1 + + elif not argns.s: # treat stdin as full file (-s support is later) + # read code from terminal, always in binary mode since we want to + # decode ourselves and be tolerant with it + code = sys.stdin.buffer.read() # use .buffer to get a binary stream + if not inencoding: + code, inencoding = guess_decode_from_terminal(code, sys.stdin) + # else the lexer will do the decoding + if not lexer: + try: + lexer = guess_lexer(code, **parsed_opts) + except ClassNotFound: + lexer = TextLexer(**parsed_opts) + + else: # -s option needs a lexer with -l + if not lexer: + print('Error: when using -s a lexer has to be selected with -l', + file=sys.stderr) + return 2 + + # process filters + for fname, fopts in F_opts: + try: + lexer.add_filter(fname, **fopts) + except ClassNotFound as err: + print('Error:', err, file=sys.stderr) + return 1 + + # select formatter + outfn = argns.o + fmter = argns.f + if fmter: + # custom formatter, located relative to user's cwd + if allow_custom_lexer_formatter and '.py' in fmter: + try: + filename = None + name = None + if ':' in fmter: + # Same logic as above for custom lexer + filename, name = fmter.rsplit(':', 1) + + if '.py' in name: + name = None + + if filename and name: + fmter = load_formatter_from_file(filename, name, + **parsed_opts) + else: + fmter = load_formatter_from_file(fmter, **parsed_opts) + except ClassNotFound as err: + print('Error:', err, file=sys.stderr) + return 1 + else: + try: + fmter = get_formatter_by_name(fmter, **parsed_opts) + except (OptionError, ClassNotFound) as err: + print('Error:', err, file=sys.stderr) + return 1 + + if outfn: + if not fmter: + try: + fmter = get_formatter_for_filename(outfn, **parsed_opts) + except (OptionError, ClassNotFound) as err: + print('Error:', err, file=sys.stderr) + return 1 + try: + outfile = open(outfn, 'wb') + except Exception as err: + print('Error: cannot open outfile:', err, file=sys.stderr) + return 1 + else: + if not fmter: + if os.environ.get('COLORTERM','') in ('truecolor', '24bit'): + fmter = TerminalTrueColorFormatter(**parsed_opts) + elif '256' in os.environ.get('TERM', ''): + fmter = Terminal256Formatter(**parsed_opts) + else: + fmter = TerminalFormatter(**parsed_opts) + outfile = sys.stdout.buffer + + # determine output encoding if not explicitly selected + if not outencoding: + if outfn: + # output file? use lexer encoding for now (can still be None) + fmter.encoding = inencoding + else: + # else use terminal encoding + fmter.encoding = terminal_encoding(sys.stdout) + + # provide coloring under Windows, if possible + if not outfn and sys.platform in ('win32', 'cygwin') and \ + fmter.name in ('Terminal', 'Terminal256'): # pragma: no cover + # unfortunately colorama doesn't support binary streams on Py3 + outfile = UnclosingTextIOWrapper(outfile, encoding=fmter.encoding) + fmter.encoding = None + try: + import colorama.initialise + except ImportError: + pass + else: + outfile = colorama.initialise.wrap_stream( + outfile, convert=None, strip=None, autoreset=False, wrap=True) + + # When using the LaTeX formatter and the option `escapeinside` is + # specified, we need a special lexer which collects escaped text + # before running the chosen language lexer. + escapeinside = parsed_opts.get('escapeinside', '') + if len(escapeinside) == 2 and isinstance(fmter, LatexFormatter): + left = escapeinside[0] + right = escapeinside[1] + lexer = LatexEmbeddedLexer(left, right, lexer) + + # ... and do it! + if not argns.s: + # process whole input as per normal... + try: + highlight(code, lexer, fmter, outfile) + finally: + if outfn: + outfile.close() + return 0 + else: + # line by line processing of stdin (eg: for 'tail -f')... + try: + while 1: + line = sys.stdin.buffer.readline() + if not line: + break + if not inencoding: + line = guess_decode_from_terminal(line, sys.stdin)[0] + highlight(line, lexer, fmter, outfile) + if hasattr(outfile, 'flush'): + outfile.flush() + return 0 + except KeyboardInterrupt: # pragma: no cover + return 0 + finally: + if outfn: + outfile.close() + + +class HelpFormatter(argparse.HelpFormatter): + def __init__(self, prog, indent_increment=2, max_help_position=16, width=None): + if width is None: + try: + width = shutil.get_terminal_size().columns - 2 + except Exception: + pass + argparse.HelpFormatter.__init__(self, prog, indent_increment, + max_help_position, width) + + +def main(args=sys.argv): + """ + Main command line entry point. + """ + desc = "Highlight an input file and write the result to an output file." + parser = argparse.ArgumentParser(description=desc, add_help=False, + formatter_class=HelpFormatter) + + operation = parser.add_argument_group('Main operation') + lexersel = operation.add_mutually_exclusive_group() + lexersel.add_argument( + '-l', metavar='LEXER', + help='Specify the lexer to use. (Query names with -L.) If not ' + 'given and -g is not present, the lexer is guessed from the filename.') + lexersel.add_argument( + '-g', action='store_true', + help='Guess the lexer from the file contents, or pass through ' + 'as plain text if nothing can be guessed.') + operation.add_argument( + '-F', metavar='FILTER[:options]', action='append', + help='Add a filter to the token stream. (Query names with -L.) ' + 'Filter options are given after a colon if necessary.') + operation.add_argument( + '-f', metavar='FORMATTER', + help='Specify the formatter to use. (Query names with -L.) ' + 'If not given, the formatter is guessed from the output filename, ' + 'and defaults to the terminal formatter if the output is to the ' + 'terminal or an unknown file extension.') + operation.add_argument( + '-O', metavar='OPTION=value[,OPTION=value,...]', action='append', + help='Give options to the lexer and formatter as a comma-separated ' + 'list of key-value pairs. ' + 'Example: `-O bg=light,python=cool`.') + operation.add_argument( + '-P', metavar='OPTION=value', action='append', + help='Give a single option to the lexer and formatter - with this ' + 'you can pass options whose value contains commas and equal signs. ' + 'Example: `-P "heading=Pygments, the Python highlighter"`.') + operation.add_argument( + '-o', metavar='OUTPUTFILE', + help='Where to write the output. Defaults to standard output.') + + operation.add_argument( + 'INPUTFILE', nargs='?', + help='Where to read the input. Defaults to standard input.') + + flags = parser.add_argument_group('Operation flags') + flags.add_argument( + '-v', action='store_true', + help='Print a detailed traceback on unhandled exceptions, which ' + 'is useful for debugging and bug reports.') + flags.add_argument( + '-s', action='store_true', + help='Process lines one at a time until EOF, rather than waiting to ' + 'process the entire file. This only works for stdin, only for lexers ' + 'with no line-spanning constructs, and is intended for streaming ' + 'input such as you get from `tail -f`. ' + 'Example usage: `tail -f sql.log | pygmentize -s -l sql`.') + flags.add_argument( + '-x', action='store_true', + help='Allow custom lexers and formatters to be loaded from a .py file ' + 'relative to the current working directory. For example, ' + '`-l ./customlexer.py -x`. By default, this option expects a file ' + 'with a class named CustomLexer or CustomFormatter; you can also ' + 'specify your own class name with a colon (`-l ./lexer.py:MyLexer`). ' + 'Users should be very careful not to use this option with untrusted ' + 'files, because it will import and run them.') + flags.add_argument('--json', help='Output as JSON. This can ' + 'be only used in conjunction with -L.', + default=False, + action='store_true') + + special_modes_group = parser.add_argument_group( + 'Special modes - do not do any highlighting') + special_modes = special_modes_group.add_mutually_exclusive_group() + special_modes.add_argument( + '-S', metavar='STYLE -f formatter', + help='Print style definitions for STYLE for a formatter ' + 'given with -f. The argument given by -a is formatter ' + 'dependent.') + special_modes.add_argument( + '-L', nargs='*', metavar='WHAT', + help='List lexers, formatters, styles or filters -- ' + 'give additional arguments for the thing(s) you want to list ' + '(e.g. "styles"), or omit them to list everything.') + special_modes.add_argument( + '-N', metavar='FILENAME', + help='Guess and print out a lexer name based solely on the given ' + 'filename. Does not take input or highlight anything. If no specific ' + 'lexer can be determined, "text" is printed.') + special_modes.add_argument( + '-C', action='store_true', + help='Like -N, but print out a lexer name based solely on ' + 'a given content from standard input.') + special_modes.add_argument( + '-H', action='store', nargs=2, metavar=('NAME', 'TYPE'), + help='Print detailed help for the object of type , ' + 'where is one of "lexer", "formatter" or "filter".') + special_modes.add_argument( + '-V', action='store_true', + help='Print the package version.') + special_modes.add_argument( + '-h', '--help', action='store_true', + help='Print this help.') + special_modes_group.add_argument( + '-a', metavar='ARG', + help='Formatter-specific additional argument for the -S (print ' + 'style sheet) mode.') + + argns = parser.parse_args(args[1:]) + + try: + return main_inner(parser, argns) + except BrokenPipeError: + # someone closed our stdout, e.g. by quitting a pager. + return 0 + except Exception: + if argns.v: + print(file=sys.stderr) + print('*' * 65, file=sys.stderr) + print('An unhandled exception occurred while highlighting.', + file=sys.stderr) + print('Please report the whole traceback to the issue tracker at', + file=sys.stderr) + print('.', + file=sys.stderr) + print('*' * 65, file=sys.stderr) + print(file=sys.stderr) + raise + import traceback + info = traceback.format_exception(*sys.exc_info()) + msg = info[-1].strip() + if len(info) >= 3: + # extract relevant file and position info + msg += '\n (f{})'.format(info[-2].split('\n')[0].strip()[1:]) + print(file=sys.stderr) + print('*** Error while highlighting:', file=sys.stderr) + print(msg, file=sys.stderr) + print('*** If this is a bug you want to report, please rerun with -v.', + file=sys.stderr) + return 1 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/console.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/console.py new file mode 100644 index 0000000000000000000000000000000000000000..d9009168cadbe25ba0bb1fc5427a5db0f1582830 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/console.py @@ -0,0 +1,70 @@ +""" + pygments.console + ~~~~~~~~~~~~~~~~ + + Format colored console output. + + :copyright: Copyright 2006-present by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +esc = "\x1b[" + +codes = {} +codes[""] = "" +codes["reset"] = esc + "39;49;00m" + +codes["bold"] = esc + "01m" +codes["faint"] = esc + "02m" +codes["standout"] = esc + "03m" +codes["underline"] = esc + "04m" +codes["blink"] = esc + "05m" +codes["overline"] = esc + "06m" + +dark_colors = ["black", "red", "green", "yellow", "blue", + "magenta", "cyan", "gray"] +light_colors = ["brightblack", "brightred", "brightgreen", "brightyellow", "brightblue", + "brightmagenta", "brightcyan", "white"] + +x = 30 +for dark, light in zip(dark_colors, light_colors): + codes[dark] = esc + "%im" % x + codes[light] = esc + "%im" % (60 + x) + x += 1 + +del dark, light, x + +codes["white"] = codes["bold"] + + +def reset_color(): + return codes["reset"] + + +def colorize(color_key, text): + return codes[color_key] + text + codes["reset"] + + +def ansiformat(attr, text): + """ + Format ``text`` with a color and/or some attributes:: + + color normal color + *color* bold color + _color_ underlined color + +color+ blinking color + """ + result = [] + if attr[:1] == attr[-1:] == '+': + result.append(codes['blink']) + attr = attr[1:-1] + if attr[:1] == attr[-1:] == '*': + result.append(codes['bold']) + attr = attr[1:-1] + if attr[:1] == attr[-1:] == '_': + result.append(codes['underline']) + attr = attr[1:-1] + result.append(codes[attr]) + result.append(text) + result.append(codes['reset']) + return ''.join(result) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/filter.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/filter.py new file mode 100644 index 0000000000000000000000000000000000000000..6c926c26cfcf0ca7579f05affcab46c389595b71 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/filter.py @@ -0,0 +1,70 @@ +""" + pygments.filter + ~~~~~~~~~~~~~~~ + + Module that implements the default filter. + + :copyright: Copyright 2006-present by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + + +def apply_filters(stream, filters, lexer=None): + """ + Use this method to apply an iterable of filters to + a stream. If lexer is given it's forwarded to the + filter, otherwise the filter receives `None`. + """ + def _apply(filter_, stream): + yield from filter_.filter(lexer, stream) + for filter_ in filters: + stream = _apply(filter_, stream) + return stream + + +def simplefilter(f): + """ + Decorator that converts a function into a filter:: + + @simplefilter + def lowercase(self, lexer, stream, options): + for ttype, value in stream: + yield ttype, value.lower() + """ + return type(f.__name__, (FunctionFilter,), { + '__module__': getattr(f, '__module__'), + '__doc__': f.__doc__, + 'function': f, + }) + + +class Filter: + """ + Default filter. Subclass this class or use the `simplefilter` + decorator to create own filters. + """ + + def __init__(self, **options): + self.options = options + + def filter(self, lexer, stream): + raise NotImplementedError() + + +class FunctionFilter(Filter): + """ + Abstract class used by `simplefilter` to create simple + function filters on the fly. The `simplefilter` decorator + automatically creates subclasses of this class for + functions passed to it. + """ + function = None + + def __init__(self, **options): + if not hasattr(self, 'function'): + raise TypeError(f'{self.__class__.__name__!r} used without bound function') + Filter.__init__(self, **options) + + def filter(self, lexer, stream): + # pylint: disable=not-callable + yield from self.function(lexer, stream, self.options) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/filters/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/filters/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..c7ba6adb5b75ac3bf8e9e94868575e6ce770e6c1 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/filters/__init__.py @@ -0,0 +1,942 @@ +""" + pygments.filters + ~~~~~~~~~~~~~~~~ + + Module containing filter lookup functions and default + filters. + + :copyright: Copyright 2006-present by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.token import String, Comment, Keyword, Name, Error, Whitespace, \ + string_to_tokentype +from pygments.filter import Filter +from pygments.util import get_list_opt, get_int_opt, get_bool_opt, \ + get_choice_opt, ClassNotFound, OptionError +from pygments.plugin import find_plugin_filters + + +def find_filter_class(filtername): + """Lookup a filter by name. Return None if not found.""" + if filtername in FILTERS: + return FILTERS[filtername] + for name, cls in find_plugin_filters(): + if name == filtername: + return cls + return None + + +def get_filter_by_name(filtername, **options): + """Return an instantiated filter. + + Options are passed to the filter initializer if wanted. + Raise a ClassNotFound if not found. + """ + cls = find_filter_class(filtername) + if cls: + return cls(**options) + else: + raise ClassNotFound(f'filter {filtername!r} not found') + + +def get_all_filters(): + """Return a generator of all filter names.""" + yield from FILTERS + for name, _ in find_plugin_filters(): + yield name + + +def _replace_special(ttype, value, regex, specialttype, + replacefunc=lambda x: x): + last = 0 + for match in regex.finditer(value): + start, end = match.start(), match.end() + if start != last: + yield ttype, value[last:start] + yield specialttype, replacefunc(value[start:end]) + last = end + if last != len(value): + yield ttype, value[last:] + + +class CodeTagFilter(Filter): + """Highlight special code tags in comments and docstrings. + + Options accepted: + + `codetags` : list of strings + A list of strings that are flagged as code tags. The default is to + highlight ``XXX``, ``TODO``, ``FIXME``, ``BUG`` and ``NOTE``. + + .. versionchanged:: 2.13 + Now recognizes ``FIXME`` by default. + """ + + def __init__(self, **options): + Filter.__init__(self, **options) + tags = get_list_opt(options, 'codetags', + ['XXX', 'TODO', 'FIXME', 'BUG', 'NOTE']) + self.tag_re = re.compile(r'\b({})\b'.format('|'.join([ + re.escape(tag) for tag in tags if tag + ]))) + + def filter(self, lexer, stream): + regex = self.tag_re + for ttype, value in stream: + if ttype in String.Doc or \ + ttype in Comment and \ + ttype not in Comment.Preproc: + yield from _replace_special(ttype, value, regex, Comment.Special) + else: + yield ttype, value + + +class SymbolFilter(Filter): + """Convert mathematical symbols into Unicode characters. + + Examples are ``\\`` in Isabelle or + ``\\longrightarrow`` in LaTeX. + + This is mostly useful for HTML or console output when you want to + approximate the source rendering you'd see in an IDE. + + Options accepted: + + `lang` : string + The symbol language. Must be one of ``'isabelle'`` or + ``'latex'``. The default is ``'isabelle'``. + """ + + latex_symbols = { + '\\alpha' : '\U000003b1', + '\\beta' : '\U000003b2', + '\\gamma' : '\U000003b3', + '\\delta' : '\U000003b4', + '\\varepsilon' : '\U000003b5', + '\\zeta' : '\U000003b6', + '\\eta' : '\U000003b7', + '\\vartheta' : '\U000003b8', + '\\iota' : '\U000003b9', + '\\kappa' : '\U000003ba', + '\\lambda' : '\U000003bb', + '\\mu' : '\U000003bc', + '\\nu' : '\U000003bd', + '\\xi' : '\U000003be', + '\\pi' : '\U000003c0', + '\\varrho' : '\U000003c1', + '\\sigma' : '\U000003c3', + '\\tau' : '\U000003c4', + '\\upsilon' : '\U000003c5', + '\\varphi' : '\U000003c6', + '\\chi' : '\U000003c7', + '\\psi' : '\U000003c8', + '\\omega' : '\U000003c9', + '\\Gamma' : '\U00000393', + '\\Delta' : '\U00000394', + '\\Theta' : '\U00000398', + '\\Lambda' : '\U0000039b', + '\\Xi' : '\U0000039e', + '\\Pi' : '\U000003a0', + '\\Sigma' : '\U000003a3', + '\\Upsilon' : '\U000003a5', + '\\Phi' : '\U000003a6', + '\\Psi' : '\U000003a8', + '\\Omega' : '\U000003a9', + '\\leftarrow' : '\U00002190', + '\\longleftarrow' : '\U000027f5', + '\\rightarrow' : '\U00002192', + '\\longrightarrow' : '\U000027f6', + '\\Leftarrow' : '\U000021d0', + '\\Longleftarrow' : '\U000027f8', + '\\Rightarrow' : '\U000021d2', + '\\Longrightarrow' : '\U000027f9', + '\\leftrightarrow' : '\U00002194', + '\\longleftrightarrow' : '\U000027f7', + '\\Leftrightarrow' : '\U000021d4', + '\\Longleftrightarrow' : '\U000027fa', + '\\mapsto' : '\U000021a6', + '\\longmapsto' : '\U000027fc', + '\\relbar' : '\U00002500', + '\\Relbar' : '\U00002550', + '\\hookleftarrow' : '\U000021a9', + '\\hookrightarrow' : '\U000021aa', + '\\leftharpoondown' : '\U000021bd', + '\\rightharpoondown' : '\U000021c1', + '\\leftharpoonup' : '\U000021bc', + '\\rightharpoonup' : '\U000021c0', + '\\rightleftharpoons' : '\U000021cc', + '\\leadsto' : '\U0000219d', + '\\downharpoonleft' : '\U000021c3', + '\\downharpoonright' : '\U000021c2', + '\\upharpoonleft' : '\U000021bf', + '\\upharpoonright' : '\U000021be', + '\\restriction' : '\U000021be', + '\\uparrow' : '\U00002191', + '\\Uparrow' : '\U000021d1', + '\\downarrow' : '\U00002193', + '\\Downarrow' : '\U000021d3', + '\\updownarrow' : '\U00002195', + '\\Updownarrow' : '\U000021d5', + '\\langle' : '\U000027e8', + '\\rangle' : '\U000027e9', + '\\lceil' : '\U00002308', + '\\rceil' : '\U00002309', + '\\lfloor' : '\U0000230a', + '\\rfloor' : '\U0000230b', + '\\flqq' : '\U000000ab', + '\\frqq' : '\U000000bb', + '\\bot' : '\U000022a5', + '\\top' : '\U000022a4', + '\\wedge' : '\U00002227', + '\\bigwedge' : '\U000022c0', + '\\vee' : '\U00002228', + '\\bigvee' : '\U000022c1', + '\\forall' : '\U00002200', + '\\exists' : '\U00002203', + '\\nexists' : '\U00002204', + '\\neg' : '\U000000ac', + '\\Box' : '\U000025a1', + '\\Diamond' : '\U000025c7', + '\\vdash' : '\U000022a2', + '\\models' : '\U000022a8', + '\\dashv' : '\U000022a3', + '\\surd' : '\U0000221a', + '\\le' : '\U00002264', + '\\ge' : '\U00002265', + '\\ll' : '\U0000226a', + '\\gg' : '\U0000226b', + '\\lesssim' : '\U00002272', + '\\gtrsim' : '\U00002273', + '\\lessapprox' : '\U00002a85', + '\\gtrapprox' : '\U00002a86', + '\\in' : '\U00002208', + '\\notin' : '\U00002209', + '\\subset' : '\U00002282', + '\\supset' : '\U00002283', + '\\subseteq' : '\U00002286', + '\\supseteq' : '\U00002287', + '\\sqsubset' : '\U0000228f', + '\\sqsupset' : '\U00002290', + '\\sqsubseteq' : '\U00002291', + '\\sqsupseteq' : '\U00002292', + '\\cap' : '\U00002229', + '\\bigcap' : '\U000022c2', + '\\cup' : '\U0000222a', + '\\bigcup' : '\U000022c3', + '\\sqcup' : '\U00002294', + '\\bigsqcup' : '\U00002a06', + '\\sqcap' : '\U00002293', + '\\Bigsqcap' : '\U00002a05', + '\\setminus' : '\U00002216', + '\\propto' : '\U0000221d', + '\\uplus' : '\U0000228e', + '\\bigplus' : '\U00002a04', + '\\sim' : '\U0000223c', + '\\doteq' : '\U00002250', + '\\simeq' : '\U00002243', + '\\approx' : '\U00002248', + '\\asymp' : '\U0000224d', + '\\cong' : '\U00002245', + '\\equiv' : '\U00002261', + '\\Join' : '\U000022c8', + '\\bowtie' : '\U00002a1d', + '\\prec' : '\U0000227a', + '\\succ' : '\U0000227b', + '\\preceq' : '\U0000227c', + '\\succeq' : '\U0000227d', + '\\parallel' : '\U00002225', + '\\mid' : '\U000000a6', + '\\pm' : '\U000000b1', + '\\mp' : '\U00002213', + '\\times' : '\U000000d7', + '\\div' : '\U000000f7', + '\\cdot' : '\U000022c5', + '\\star' : '\U000022c6', + '\\circ' : '\U00002218', + '\\dagger' : '\U00002020', + '\\ddagger' : '\U00002021', + '\\lhd' : '\U000022b2', + '\\rhd' : '\U000022b3', + '\\unlhd' : '\U000022b4', + '\\unrhd' : '\U000022b5', + '\\triangleleft' : '\U000025c3', + '\\triangleright' : '\U000025b9', + '\\triangle' : '\U000025b3', + '\\triangleq' : '\U0000225c', + '\\oplus' : '\U00002295', + '\\bigoplus' : '\U00002a01', + '\\otimes' : '\U00002297', + '\\bigotimes' : '\U00002a02', + '\\odot' : '\U00002299', + '\\bigodot' : '\U00002a00', + '\\ominus' : '\U00002296', + '\\oslash' : '\U00002298', + '\\dots' : '\U00002026', + '\\cdots' : '\U000022ef', + '\\sum' : '\U00002211', + '\\prod' : '\U0000220f', + '\\coprod' : '\U00002210', + '\\infty' : '\U0000221e', + '\\int' : '\U0000222b', + '\\oint' : '\U0000222e', + '\\clubsuit' : '\U00002663', + '\\diamondsuit' : '\U00002662', + '\\heartsuit' : '\U00002661', + '\\spadesuit' : '\U00002660', + '\\aleph' : '\U00002135', + '\\emptyset' : '\U00002205', + '\\nabla' : '\U00002207', + '\\partial' : '\U00002202', + '\\flat' : '\U0000266d', + '\\natural' : '\U0000266e', + '\\sharp' : '\U0000266f', + '\\angle' : '\U00002220', + '\\copyright' : '\U000000a9', + '\\textregistered' : '\U000000ae', + '\\textonequarter' : '\U000000bc', + '\\textonehalf' : '\U000000bd', + '\\textthreequarters' : '\U000000be', + '\\textordfeminine' : '\U000000aa', + '\\textordmasculine' : '\U000000ba', + '\\euro' : '\U000020ac', + '\\pounds' : '\U000000a3', + '\\yen' : '\U000000a5', + '\\textcent' : '\U000000a2', + '\\textcurrency' : '\U000000a4', + '\\textdegree' : '\U000000b0', + } + + isabelle_symbols = { + '\\' : '\U0001d7ec', + '\\' : '\U0001d7ed', + '\\' : '\U0001d7ee', + '\\' : '\U0001d7ef', + '\\' : '\U0001d7f0', + '\\' : '\U0001d7f1', + '\\' : '\U0001d7f2', + '\\' : '\U0001d7f3', + '\\' : '\U0001d7f4', + '\\' : '\U0001d7f5', + '\\' : '\U0001d49c', + '\\' : '\U0000212c', + '\\' : '\U0001d49e', + '\\' : '\U0001d49f', + '\\' : '\U00002130', + '\\' : '\U00002131', + '\\' : '\U0001d4a2', + '\\' : '\U0000210b', + '\\' : '\U00002110', + '\\' : '\U0001d4a5', + '\\' : '\U0001d4a6', + '\\' : '\U00002112', + '\\' : '\U00002133', + '\\' : '\U0001d4a9', + '\\' : '\U0001d4aa', + '\\

' : '\U0001d5c9', + '\\' : '\U0001d5ca', + '\\' : '\U0001d5cb', + '\\' : '\U0001d5cc', + '\\' : '\U0001d5cd', + '\\' : '\U0001d5ce', + '\\' : '\U0001d5cf', + '\\' : '\U0001d5d0', + '\\' : '\U0001d5d1', + '\\' : '\U0001d5d2', + '\\' : '\U0001d5d3', + '\\' : '\U0001d504', + '\\' : '\U0001d505', + '\\' : '\U0000212d', + '\\

' : '\U0001d507', + '\\' : '\U0001d508', + '\\' : '\U0001d509', + '\\' : '\U0001d50a', + '\\' : '\U0000210c', + '\\' : '\U00002111', + '\\' : '\U0001d50d', + '\\' : '\U0001d50e', + '\\' : '\U0001d50f', + '\\' : '\U0001d510', + '\\' : '\U0001d511', + '\\' : '\U0001d512', + '\\' : '\U0001d513', + '\\' : '\U0001d514', + '\\' : '\U0000211c', + '\\' : '\U0001d516', + '\\' : '\U0001d517', + '\\' : '\U0001d518', + '\\' : '\U0001d519', + '\\' : '\U0001d51a', + '\\' : '\U0001d51b', + '\\' : '\U0001d51c', + '\\' : '\U00002128', + '\\' : '\U0001d51e', + '\\' : '\U0001d51f', + '\\' : '\U0001d520', + '\\
' : '\U0001d521', + '\\' : '\U0001d522', + '\\' : '\U0001d523', + '\\' : '\U0001d524', + '\\' : '\U0001d525', + '\\' : '\U0001d526', + '\\' : '\U0001d527', + '\\' : '\U0001d528', + '\\' : '\U0001d529', + '\\' : '\U0001d52a', + '\\' : '\U0001d52b', + '\\' : '\U0001d52c', + '\\' : '\U0001d52d', + '\\' : '\U0001d52e', + '\\' : '\U0001d52f', + '\\' : '\U0001d530', + '\\' : '\U0001d531', + '\\' : '\U0001d532', + '\\' : '\U0001d533', + '\\' : '\U0001d534', + '\\' : '\U0001d535', + '\\' : '\U0001d536', + '\\' : '\U0001d537', + '\\' : '\U000003b1', + '\\' : '\U000003b2', + '\\' : '\U000003b3', + '\\' : '\U000003b4', + '\\' : '\U000003b5', + '\\' : '\U000003b6', + '\\' : '\U000003b7', + '\\' : '\U000003b8', + '\\' : '\U000003b9', + '\\' : '\U000003ba', + '\\' : '\U000003bb', + '\\' : '\U000003bc', + '\\' : '\U000003bd', + '\\' : '\U000003be', + '\\' : '\U000003c0', + '\\' : '\U000003c1', + '\\' : '\U000003c3', + '\\' : '\U000003c4', + '\\' : '\U000003c5', + '\\' : '\U000003c6', + '\\' : '\U000003c7', + '\\' : '\U000003c8', + '\\' : '\U000003c9', + '\\' : '\U00000393', + '\\' : '\U00000394', + '\\' : '\U00000398', + '\\' : '\U0000039b', + '\\' : '\U0000039e', + '\\' : '\U000003a0', + '\\' : '\U000003a3', + '\\' : '\U000003a5', + '\\' : '\U000003a6', + '\\' : '\U000003a8', + '\\' : '\U000003a9', + '\\' : '\U0001d539', + '\\' : '\U00002102', + '\\' : '\U00002115', + '\\' : '\U0000211a', + '\\' : '\U0000211d', + '\\' : '\U00002124', + '\\' : '\U00002190', + '\\' : '\U000027f5', + '\\' : '\U00002192', + '\\' : '\U000027f6', + '\\' : '\U000021d0', + '\\' : '\U000027f8', + '\\' : '\U000021d2', + '\\' : '\U000027f9', + '\\' : '\U00002194', + '\\' : '\U000027f7', + '\\' : '\U000021d4', + '\\' : '\U000027fa', + '\\' : '\U000021a6', + '\\' : '\U000027fc', + '\\' : '\U00002500', + '\\' : '\U00002550', + '\\' : '\U000021a9', + '\\' : '\U000021aa', + '\\' : '\U000021bd', + '\\' : '\U000021c1', + '\\' : '\U000021bc', + '\\' : '\U000021c0', + '\\' : '\U000021cc', + '\\' : '\U0000219d', + '\\' : '\U000021c3', + '\\' : '\U000021c2', + '\\' : '\U000021bf', + '\\' : '\U000021be', + '\\' : '\U000021be', + '\\' : '\U00002237', + '\\' : '\U00002191', + '\\' : '\U000021d1', + '\\' : '\U00002193', + '\\' : '\U000021d3', + '\\' : '\U00002195', + '\\' : '\U000021d5', + '\\' : '\U000027e8', + '\\' : '\U000027e9', + '\\' : '\U00002308', + '\\' : '\U00002309', + '\\' : '\U0000230a', + '\\' : '\U0000230b', + '\\' : '\U00002987', + '\\' : '\U00002988', + '\\' : '\U000027e6', + '\\' : '\U000027e7', + '\\' : '\U00002983', + '\\' : '\U00002984', + '\\' : '\U000000ab', + '\\' : '\U000000bb', + '\\' : '\U000022a5', + '\\' : '\U000022a4', + '\\' : '\U00002227', + '\\' : '\U000022c0', + '\\' : '\U00002228', + '\\' : '\U000022c1', + '\\' : '\U00002200', + '\\' : '\U00002203', + '\\' : '\U00002204', + '\\' : '\U000000ac', + '\\' : '\U000025a1', + '\\' : '\U000025c7', + '\\' : '\U000022a2', + '\\' : '\U000022a8', + '\\' : '\U000022a9', + '\\' : '\U000022ab', + '\\' : '\U000022a3', + '\\' : '\U0000221a', + '\\' : '\U00002264', + '\\' : '\U00002265', + '\\' : '\U0000226a', + '\\' : '\U0000226b', + '\\' : '\U00002272', + '\\' : '\U00002273', + '\\' : '\U00002a85', + '\\' : '\U00002a86', + '\\' : '\U00002208', + '\\' : '\U00002209', + '\\' : '\U00002282', + '\\' : '\U00002283', + '\\' : '\U00002286', + '\\' : '\U00002287', + '\\' : '\U0000228f', + '\\' : '\U00002290', + '\\' : '\U00002291', + '\\' : '\U00002292', + '\\' : '\U00002229', + '\\' : '\U000022c2', + '\\' : '\U0000222a', + '\\' : '\U000022c3', + '\\' : '\U00002294', + '\\' : '\U00002a06', + '\\' : '\U00002293', + '\\' : '\U00002a05', + '\\' : '\U00002216', + '\\' : '\U0000221d', + '\\' : '\U0000228e', + '\\' : '\U00002a04', + '\\' : '\U00002260', + '\\' : '\U0000223c', + '\\' : '\U00002250', + '\\' : '\U00002243', + '\\' : '\U00002248', + '\\' : '\U0000224d', + '\\' : '\U00002245', + '\\' : '\U00002323', + '\\' : '\U00002261', + '\\' : '\U00002322', + '\\' : '\U000022c8', + '\\' : '\U00002a1d', + '\\' : '\U0000227a', + '\\' : '\U0000227b', + '\\' : '\U0000227c', + '\\' : '\U0000227d', + '\\' : '\U00002225', + '\\' : '\U000000a6', + '\\' : '\U000000b1', + '\\' : '\U00002213', + '\\' : '\U000000d7', + '\\
' : '\U000000f7', + '\\' : '\U000022c5', + '\\' : '\U000022c6', + '\\' : '\U00002219', + '\\' : '\U00002218', + '\\' : '\U00002020', + '\\' : '\U00002021', + '\\' : '\U000022b2', + '\\' : '\U000022b3', + '\\' : '\U000022b4', + '\\' : '\U000022b5', + '\\' : '\U000025c3', + '\\' : '\U000025b9', + '\\' : '\U000025b3', + '\\' : '\U0000225c', + '\\' : '\U00002295', + '\\' : '\U00002a01', + '\\' : '\U00002297', + '\\' : '\U00002a02', + '\\' : '\U00002299', + '\\' : '\U00002a00', + '\\' : '\U00002296', + '\\' : '\U00002298', + '\\' : '\U00002026', + '\\' : '\U000022ef', + '\\' : '\U00002211', + '\\' : '\U0000220f', + '\\' : '\U00002210', + '\\' : '\U0000221e', + '\\' : '\U0000222b', + '\\' : '\U0000222e', + '\\' : '\U00002663', + '\\' : '\U00002662', + '\\' : '\U00002661', + '\\' : '\U00002660', + '\\' : '\U00002135', + '\\' : '\U00002205', + '\\' : '\U00002207', + '\\' : '\U00002202', + '\\' : '\U0000266d', + '\\' : '\U0000266e', + '\\' : '\U0000266f', + '\\' : '\U00002220', + '\\' : '\U000000a9', + '\\' : '\U000000ae', + '\\' : '\U000000ad', + '\\' : '\U000000af', + '\\' : '\U000000bc', + '\\' : '\U000000bd', + '\\' : '\U000000be', + '\\' : '\U000000aa', + '\\' : '\U000000ba', + '\\
' : '\U000000a7', + '\\' : '\U000000b6', + '\\' : '\U000000a1', + '\\' : '\U000000bf', + '\\' : '\U000020ac', + '\\' : '\U000000a3', + '\\' : '\U000000a5', + '\\' : '\U000000a2', + '\\' : '\U000000a4', + '\\' : '\U000000b0', + '\\' : '\U00002a3f', + '\\' : '\U00002127', + '\\' : '\U000025ca', + '\\' : '\U00002118', + '\\' : '\U00002240', + '\\' : '\U000022c4', + '\\' : '\U000000b4', + '\\' : '\U00000131', + '\\' : '\U000000a8', + '\\' : '\U000000b8', + '\\' : '\U000002dd', + '\\' : '\U000003f5', + '\\' : '\U000023ce', + '\\' : '\U00002039', + '\\' : '\U0000203a', + '\\' : '\U00002302', + '\\<^sub>' : '\U000021e9', + '\\<^sup>' : '\U000021e7', + '\\<^bold>' : '\U00002759', + '\\<^bsub>' : '\U000021d8', + '\\<^esub>' : '\U000021d9', + '\\<^bsup>' : '\U000021d7', + '\\<^esup>' : '\U000021d6', + } + + lang_map = {'isabelle' : isabelle_symbols, 'latex' : latex_symbols} + + def __init__(self, **options): + Filter.__init__(self, **options) + lang = get_choice_opt(options, 'lang', + ['isabelle', 'latex'], 'isabelle') + self.symbols = self.lang_map[lang] + + def filter(self, lexer, stream): + for ttype, value in stream: + if value in self.symbols: + yield ttype, self.symbols[value] + else: + yield ttype, value + + +class KeywordCaseFilter(Filter): + """Convert keywords to lowercase or uppercase or capitalize them. + + This means first letter uppercase, rest lowercase. + + This can be useful e.g. if you highlight Pascal code and want to adapt the + code to your styleguide. + + Options accepted: + + `case` : string + The casing to convert keywords to. Must be one of ``'lower'``, + ``'upper'`` or ``'capitalize'``. The default is ``'lower'``. + """ + + def __init__(self, **options): + Filter.__init__(self, **options) + case = get_choice_opt(options, 'case', + ['lower', 'upper', 'capitalize'], 'lower') + self.convert = getattr(str, case) + + def filter(self, lexer, stream): + for ttype, value in stream: + if ttype in Keyword: + yield ttype, self.convert(value) + else: + yield ttype, value + + +class NameHighlightFilter(Filter): + """Highlight a normal Name (and Name.*) token with a different token type. + + Example:: + + filter = NameHighlightFilter( + names=['foo', 'bar', 'baz'], + tokentype=Name.Function, + ) + + This would highlight the names "foo", "bar" and "baz" + as functions. `Name.Function` is the default token type. + + Options accepted: + + `names` : list of strings + A list of names that should be given the different token type. + There is no default. + `tokentype` : TokenType or string + A token type or a string containing a token type name that is + used for highlighting the strings in `names`. The default is + `Name.Function`. + """ + + def __init__(self, **options): + Filter.__init__(self, **options) + self.names = set(get_list_opt(options, 'names', [])) + tokentype = options.get('tokentype') + if tokentype: + self.tokentype = string_to_tokentype(tokentype) + else: + self.tokentype = Name.Function + + def filter(self, lexer, stream): + for ttype, value in stream: + if ttype in Name and value in self.names: + yield self.tokentype, value + else: + yield ttype, value + + +class ErrorToken(Exception): + pass + + +class RaiseOnErrorTokenFilter(Filter): + """Raise an exception when the lexer generates an error token. + + Options accepted: + + `excclass` : Exception class + The exception class to raise. + The default is `pygments.filters.ErrorToken`. + + .. versionadded:: 0.8 + """ + + def __init__(self, **options): + Filter.__init__(self, **options) + self.exception = options.get('excclass', ErrorToken) + try: + # issubclass() will raise TypeError if first argument is not a class + if not issubclass(self.exception, Exception): + raise TypeError + except TypeError: + raise OptionError('excclass option is not an exception class') + + def filter(self, lexer, stream): + for ttype, value in stream: + if ttype is Error: + raise self.exception(value) + yield ttype, value + + +class VisibleWhitespaceFilter(Filter): + """Convert tabs, newlines and/or spaces to visible characters. + + Options accepted: + + `spaces` : string or bool + If this is a one-character string, spaces will be replaces by this string. + If it is another true value, spaces will be replaced by ``·`` (unicode + MIDDLE DOT). If it is a false value, spaces will not be replaced. The + default is ``False``. + `tabs` : string or bool + The same as for `spaces`, but the default replacement character is ``»`` + (unicode RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK). The default value + is ``False``. Note: this will not work if the `tabsize` option for the + lexer is nonzero, as tabs will already have been expanded then. + `tabsize` : int + If tabs are to be replaced by this filter (see the `tabs` option), this + is the total number of characters that a tab should be expanded to. + The default is ``8``. + `newlines` : string or bool + The same as for `spaces`, but the default replacement character is ``¶`` + (unicode PILCROW SIGN). The default value is ``False``. + `wstokentype` : bool + If true, give whitespace the special `Whitespace` token type. This allows + styling the visible whitespace differently (e.g. greyed out), but it can + disrupt background colors. The default is ``True``. + + .. versionadded:: 0.8 + """ + + def __init__(self, **options): + Filter.__init__(self, **options) + for name, default in [('spaces', '·'), + ('tabs', '»'), + ('newlines', '¶')]: + opt = options.get(name, False) + if isinstance(opt, str) and len(opt) == 1: + setattr(self, name, opt) + else: + setattr(self, name, (opt and default or '')) + tabsize = get_int_opt(options, 'tabsize', 8) + if self.tabs: + self.tabs += ' ' * (tabsize - 1) + if self.newlines: + self.newlines += '\n' + self.wstt = get_bool_opt(options, 'wstokentype', True) + + def filter(self, lexer, stream): + if self.wstt: + spaces = self.spaces or ' ' + tabs = self.tabs or '\t' + newlines = self.newlines or '\n' + regex = re.compile(r'\s') + + def replacefunc(wschar): + if wschar == ' ': + return spaces + elif wschar == '\t': + return tabs + elif wschar == '\n': + return newlines + return wschar + + for ttype, value in stream: + yield from _replace_special(ttype, value, regex, Whitespace, + replacefunc) + else: + spaces, tabs, newlines = self.spaces, self.tabs, self.newlines + # simpler processing + for ttype, value in stream: + if spaces: + value = value.replace(' ', spaces) + if tabs: + value = value.replace('\t', tabs) + if newlines: + value = value.replace('\n', newlines) + yield ttype, value + + +class GobbleFilter(Filter): + """Gobble source code lines (eats initial characters). + + This filter drops the first ``n`` characters off every line of code. This + may be useful when the source code fed to the lexer is indented by a fixed + amount of space that isn't desired in the output. + + Options accepted: + + `n` : int + The number of characters to gobble. + + .. versionadded:: 1.2 + """ + def __init__(self, **options): + Filter.__init__(self, **options) + self.n = get_int_opt(options, 'n', 0) + + def gobble(self, value, left): + if left < len(value): + return value[left:], 0 + else: + return '', left - len(value) + + def filter(self, lexer, stream): + n = self.n + left = n # How many characters left to gobble. + for ttype, value in stream: + # Remove ``left`` tokens from first line, ``n`` from all others. + parts = value.split('\n') + (parts[0], left) = self.gobble(parts[0], left) + for i in range(1, len(parts)): + (parts[i], left) = self.gobble(parts[i], n) + value = '\n'.join(parts) + + if value != '': + yield ttype, value + + +class TokenMergeFilter(Filter): + """Merge consecutive tokens with the same token type in the output stream. + + .. versionadded:: 1.2 + """ + def __init__(self, **options): + Filter.__init__(self, **options) + + def filter(self, lexer, stream): + current_type = None + current_value = None + for ttype, value in stream: + if ttype is current_type: + current_value += value + else: + if current_type is not None: + yield current_type, current_value + current_type = ttype + current_value = value + if current_type is not None: + yield current_type, current_value + + +FILTERS = { + 'codetagify': CodeTagFilter, + 'keywordcase': KeywordCaseFilter, + 'highlight': NameHighlightFilter, + 'raiseonerror': RaiseOnErrorTokenFilter, + 'whitespace': VisibleWhitespaceFilter, + 'gobble': GobbleFilter, + 'tokenmerge': TokenMergeFilter, + 'symbols': SymbolFilter, +} diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatter.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatter.py new file mode 100644 index 0000000000000000000000000000000000000000..4fa603d551c99fab81f2aa29037c3b8b89d0fcd5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatter.py @@ -0,0 +1,129 @@ +""" + pygments.formatter + ~~~~~~~~~~~~~~~~~~ + + Base formatter class. + + :copyright: Copyright 2006-present by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import codecs + +from pygments.util import get_bool_opt +from pygments.styles import get_style_by_name + +__all__ = ['Formatter'] + + +def _lookup_style(style): + if isinstance(style, str): + return get_style_by_name(style) + return style + + +class Formatter: + """ + Converts a token stream to text. + + Formatters should have attributes to help selecting them. These + are similar to the corresponding :class:`~pygments.lexer.Lexer` + attributes. + + .. autoattribute:: name + :no-value: + + .. autoattribute:: aliases + :no-value: + + .. autoattribute:: filenames + :no-value: + + You can pass options as keyword arguments to the constructor. + All formatters accept these basic options: + + ``style`` + The style to use, can be a string or a Style subclass + (default: "default"). Not used by e.g. the + TerminalFormatter. + ``full`` + Tells the formatter to output a "full" document, i.e. + a complete self-contained document. This doesn't have + any effect for some formatters (default: false). + ``title`` + If ``full`` is true, the title that should be used to + caption the document (default: ''). + ``encoding`` + If given, must be an encoding name. This will be used to + convert the Unicode token strings to byte strings in the + output. If it is "" or None, Unicode strings will be written + to the output file, which most file-like objects do not + support (default: None). + ``outencoding`` + Overrides ``encoding`` if given. + + """ + + #: Full name for the formatter, in human-readable form. + name = None + + #: A list of short, unique identifiers that can be used to lookup + #: the formatter from a list, e.g. using :func:`.get_formatter_by_name()`. + aliases = [] + + #: A list of fnmatch patterns that match filenames for which this + #: formatter can produce output. The patterns in this list should be unique + #: among all formatters. + filenames = [] + + #: If True, this formatter outputs Unicode strings when no encoding + #: option is given. + unicodeoutput = True + + def __init__(self, **options): + """ + As with lexers, this constructor takes arbitrary optional arguments, + and if you override it, you should first process your own options, then + call the base class implementation. + """ + self.style = _lookup_style(options.get('style', 'default')) + self.full = get_bool_opt(options, 'full', False) + self.title = options.get('title', '') + self.encoding = options.get('encoding', None) or None + if self.encoding in ('guess', 'chardet'): + # can happen for e.g. pygmentize -O encoding=guess + self.encoding = 'utf-8' + self.encoding = options.get('outencoding') or self.encoding + self.options = options + + def get_style_defs(self, arg=''): + """ + This method must return statements or declarations suitable to define + the current style for subsequent highlighted text (e.g. CSS classes + in the `HTMLFormatter`). + + The optional argument `arg` can be used to modify the generation and + is formatter dependent (it is standardized because it can be given on + the command line). + + This method is called by the ``-S`` :doc:`command-line option `, + the `arg` is then given by the ``-a`` option. + """ + return '' + + def format(self, tokensource, outfile): + """ + This method must format the tokens from the `tokensource` iterable and + write the formatted version to the file object `outfile`. + + Formatter options can control how exactly the tokens are converted. + """ + if self.encoding: + # wrap the outfile in a StreamWriter + outfile = codecs.lookup(self.encoding)[3](outfile) + return self.format_unencoded(tokensource, outfile) + + # Allow writing Formatter[str] or Formatter[bytes]. That's equivalent to + # Formatter. This helps when using third-party type stubs from typeshed. + def __class_getitem__(cls, name): + return cls diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatters/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatters/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..829496dc97e147d159e106ddc12a49e8e416faf1 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatters/__init__.py @@ -0,0 +1,157 @@ +""" + pygments.formatters + ~~~~~~~~~~~~~~~~~~~ + + Pygments formatters. + + :copyright: Copyright 2006-present by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re +import sys +import types +import fnmatch +from os.path import basename + +from pygments.formatters._mapping import FORMATTERS +from pygments.plugin import find_plugin_formatters +from pygments.util import ClassNotFound + +__all__ = ['get_formatter_by_name', 'get_formatter_for_filename', + 'get_all_formatters', 'load_formatter_from_file'] + list(FORMATTERS) + +_formatter_cache = {} # classes by name +_pattern_cache = {} + + +def _fn_matches(fn, glob): + """Return whether the supplied file name fn matches pattern filename.""" + if glob not in _pattern_cache: + pattern = _pattern_cache[glob] = re.compile(fnmatch.translate(glob)) + return pattern.match(fn) + return _pattern_cache[glob].match(fn) + + +def _load_formatters(module_name): + """Load a formatter (and all others in the module too).""" + mod = __import__(module_name, None, None, ['__all__']) + for formatter_name in mod.__all__: + cls = getattr(mod, formatter_name) + _formatter_cache[cls.name] = cls + + +def get_all_formatters(): + """Return a generator for all formatter classes.""" + # NB: this returns formatter classes, not info like get_all_lexers(). + for info in FORMATTERS.values(): + if info[1] not in _formatter_cache: + _load_formatters(info[0]) + yield _formatter_cache[info[1]] + for _, formatter in find_plugin_formatters(): + yield formatter + + +def find_formatter_class(alias): + """Lookup a formatter by alias. + + Returns None if not found. + """ + for module_name, name, aliases, _, _ in FORMATTERS.values(): + if alias in aliases: + if name not in _formatter_cache: + _load_formatters(module_name) + return _formatter_cache[name] + for _, cls in find_plugin_formatters(): + if alias in cls.aliases: + return cls + + +def get_formatter_by_name(_alias, **options): + """ + Return an instance of a :class:`.Formatter` subclass that has `alias` in its + aliases list. The formatter is given the `options` at its instantiation. + + Will raise :exc:`pygments.util.ClassNotFound` if no formatter with that + alias is found. + """ + cls = find_formatter_class(_alias) + if cls is None: + raise ClassNotFound(f"no formatter found for name {_alias!r}") + return cls(**options) + + +def load_formatter_from_file(filename, formattername="CustomFormatter", **options): + """ + Return a `Formatter` subclass instance loaded from the provided file, relative + to the current directory. + + The file is expected to contain a Formatter class named ``formattername`` + (by default, CustomFormatter). Users should be very careful with the input, because + this method is equivalent to running ``eval()`` on the input file. The formatter is + given the `options` at its instantiation. + + :exc:`pygments.util.ClassNotFound` is raised if there are any errors loading + the formatter. + + .. versionadded:: 2.2 + """ + try: + # This empty dict will contain the namespace for the exec'd file + custom_namespace = {} + with open(filename, 'rb') as f: + exec(f.read(), custom_namespace) + # Retrieve the class `formattername` from that namespace + if formattername not in custom_namespace: + raise ClassNotFound(f'no valid {formattername} class found in {filename}') + formatter_class = custom_namespace[formattername] + # And finally instantiate it with the options + return formatter_class(**options) + except OSError as err: + raise ClassNotFound(f'cannot read {filename}: {err}') + except ClassNotFound: + raise + except Exception as err: + raise ClassNotFound(f'error when loading custom formatter: {err}') + + +def get_formatter_for_filename(fn, **options): + """ + Return a :class:`.Formatter` subclass instance that has a filename pattern + matching `fn`. The formatter is given the `options` at its instantiation. + + Will raise :exc:`pygments.util.ClassNotFound` if no formatter for that filename + is found. + """ + fn = basename(fn) + for modname, name, _, filenames, _ in FORMATTERS.values(): + for filename in filenames: + if _fn_matches(fn, filename): + if name not in _formatter_cache: + _load_formatters(modname) + return _formatter_cache[name](**options) + for _name, cls in find_plugin_formatters(): + for filename in cls.filenames: + if _fn_matches(fn, filename): + return cls(**options) + raise ClassNotFound(f"no formatter found for file name {fn!r}") + + +class _automodule(types.ModuleType): + """Automatically import formatters.""" + + def __getattr__(self, name): + info = FORMATTERS.get(name) + if info: + _load_formatters(info[0]) + cls = _formatter_cache[info[1]] + setattr(self, name, cls) + return cls + raise AttributeError(name) + + +oldmod = sys.modules[__name__] +newmod = _automodule(__name__) +newmod.__dict__.update(oldmod.__dict__) +sys.modules[__name__] = newmod +del newmod.newmod, newmod.oldmod, newmod.sys, newmod.types diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatters/_mapping.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatters/_mapping.py new file mode 100644 index 0000000000000000000000000000000000000000..72ca84040b626183e3328679db600c13472021be --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatters/_mapping.py @@ -0,0 +1,23 @@ +# Automatically generated by scripts/gen_mapfiles.py. +# DO NOT EDIT BY HAND; run `tox -e mapfiles` instead. + +FORMATTERS = { + 'BBCodeFormatter': ('pygments.formatters.bbcode', 'BBCode', ('bbcode', 'bb'), (), 'Format tokens with BBcodes. These formatting codes are used by many bulletin boards, so you can highlight your sourcecode with pygments before posting it there.'), + 'BmpImageFormatter': ('pygments.formatters.img', 'img_bmp', ('bmp', 'bitmap'), ('*.bmp',), 'Create a bitmap image from source code. This uses the Python Imaging Library to generate a pixmap from the source code.'), + 'GifImageFormatter': ('pygments.formatters.img', 'img_gif', ('gif',), ('*.gif',), 'Create a GIF image from source code. This uses the Python Imaging Library to generate a pixmap from the source code.'), + 'GroffFormatter': ('pygments.formatters.groff', 'groff', ('groff', 'troff', 'roff'), (), 'Format tokens with groff escapes to change their color and font style.'), + 'HtmlFormatter': ('pygments.formatters.html', 'HTML', ('html',), ('*.html', '*.htm'), "Format tokens as HTML 4 ```` tags. By default, the content is enclosed in a ``
`` tag, itself wrapped in a ``
`` tag (but see the `nowrap` option). The ``
``'s CSS class can be set by the `cssclass` option."), + 'IRCFormatter': ('pygments.formatters.irc', 'IRC', ('irc', 'IRC'), (), 'Format tokens with IRC color sequences'), + 'ImageFormatter': ('pygments.formatters.img', 'img', ('img', 'IMG', 'png'), ('*.png',), 'Create a PNG image from source code. This uses the Python Imaging Library to generate a pixmap from the source code.'), + 'JpgImageFormatter': ('pygments.formatters.img', 'img_jpg', ('jpg', 'jpeg'), ('*.jpg',), 'Create a JPEG image from source code. This uses the Python Imaging Library to generate a pixmap from the source code.'), + 'LatexFormatter': ('pygments.formatters.latex', 'LaTeX', ('latex', 'tex'), ('*.tex',), 'Format tokens as LaTeX code. This needs the `fancyvrb` and `color` standard packages.'), + 'NullFormatter': ('pygments.formatters.other', 'Text only', ('text', 'null'), ('*.txt',), 'Output the text unchanged without any formatting.'), + 'PangoMarkupFormatter': ('pygments.formatters.pangomarkup', 'Pango Markup', ('pango', 'pangomarkup'), (), 'Format tokens as Pango Markup code. It can then be rendered to an SVG.'), + 'RawTokenFormatter': ('pygments.formatters.other', 'Raw tokens', ('raw', 'tokens'), ('*.raw',), 'Format tokens as a raw representation for storing token streams.'), + 'RtfFormatter': ('pygments.formatters.rtf', 'RTF', ('rtf',), ('*.rtf',), 'Format tokens as RTF markup. This formatter automatically outputs full RTF documents with color information and other useful stuff. Perfect for Copy and Paste into Microsoft(R) Word(R) documents.'), + 'SvgFormatter': ('pygments.formatters.svg', 'SVG', ('svg',), ('*.svg',), 'Format tokens as an SVG graphics file. This formatter is still experimental. Each line of code is a ```` element with explicit ``x`` and ``y`` coordinates containing ```` elements with the individual token styles.'), + 'Terminal256Formatter': ('pygments.formatters.terminal256', 'Terminal256', ('terminal256', 'console256', '256'), (), 'Format tokens with ANSI color sequences, for output in a 256-color terminal or console. Like in `TerminalFormatter` color sequences are terminated at newlines, so that paging the output works correctly.'), + 'TerminalFormatter': ('pygments.formatters.terminal', 'Terminal', ('terminal', 'console'), (), 'Format tokens with ANSI color sequences, for output in a text console. Color sequences are terminated at newlines, so that paging the output works correctly.'), + 'TerminalTrueColorFormatter': ('pygments.formatters.terminal256', 'TerminalTrueColor', ('terminal16m', 'console16m', '16m'), (), 'Format tokens with ANSI color sequences, for output in a true-color terminal or console. Like in `TerminalFormatter` color sequences are terminated at newlines, so that paging the output works correctly.'), + 'TestcaseFormatter': ('pygments.formatters.other', 'Testcase', ('testcase',), (), 'Format tokens as appropriate for a new testcase.'), +} diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatters/bbcode.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatters/bbcode.py new file mode 100644 index 0000000000000000000000000000000000000000..90d8d806f202e9dff22e33c431f3e35cefdd6642 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatters/bbcode.py @@ -0,0 +1,108 @@ +""" + pygments.formatters.bbcode + ~~~~~~~~~~~~~~~~~~~~~~~~~~ + + BBcode formatter. + + :copyright: Copyright 2006-present by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + + +from pygments.formatter import Formatter +from pygments.util import get_bool_opt + +__all__ = ['BBCodeFormatter'] + + +class BBCodeFormatter(Formatter): + """ + Format tokens with BBcodes. These formatting codes are used by many + bulletin boards, so you can highlight your sourcecode with pygments before + posting it there. + + This formatter has no support for background colors and borders, as there + are no common BBcode tags for that. + + Some board systems (e.g. phpBB) don't support colors in their [code] tag, + so you can't use the highlighting together with that tag. + Text in a [code] tag usually is shown with a monospace font (which this + formatter can do with the ``monofont`` option) and no spaces (which you + need for indentation) are removed. + + Additional options accepted: + + `style` + The style to use, can be a string or a Style subclass (default: + ``'default'``). + + `codetag` + If set to true, put the output into ``[code]`` tags (default: + ``false``) + + `monofont` + If set to true, add a tag to show the code with a monospace font + (default: ``false``). + """ + name = 'BBCode' + aliases = ['bbcode', 'bb'] + filenames = [] + + def __init__(self, **options): + Formatter.__init__(self, **options) + self._code = get_bool_opt(options, 'codetag', False) + self._mono = get_bool_opt(options, 'monofont', False) + + self.styles = {} + self._make_styles() + + def _make_styles(self): + for ttype, ndef in self.style: + start = end = '' + if ndef['color']: + start += '[color=#{}]'.format(ndef['color']) + end = '[/color]' + end + if ndef['bold']: + start += '[b]' + end = '[/b]' + end + if ndef['italic']: + start += '[i]' + end = '[/i]' + end + if ndef['underline']: + start += '[u]' + end = '[/u]' + end + # there are no common BBcodes for background-color and border + + self.styles[ttype] = start, end + + def format_unencoded(self, tokensource, outfile): + if self._code: + outfile.write('[code]') + if self._mono: + outfile.write('[font=monospace]') + + lastval = '' + lasttype = None + + for ttype, value in tokensource: + while ttype not in self.styles: + ttype = ttype.parent + if ttype == lasttype: + lastval += value + else: + if lastval: + start, end = self.styles[lasttype] + outfile.write(''.join((start, lastval, end))) + lastval = value + lasttype = ttype + + if lastval: + start, end = self.styles[lasttype] + outfile.write(''.join((start, lastval, end))) + + if self._mono: + outfile.write('[/font]') + if self._code: + outfile.write('[/code]') + if self._code or self._mono: + outfile.write('\n') diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatters/groff.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatters/groff.py new file mode 100644 index 0000000000000000000000000000000000000000..f5d3146b45b0103dbad53aa2822757b8102d1c42 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatters/groff.py @@ -0,0 +1,170 @@ +""" + pygments.formatters.groff + ~~~~~~~~~~~~~~~~~~~~~~~~~ + + Formatter for groff output. + + :copyright: Copyright 2006-present by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import math +from pygments.formatter import Formatter +from pygments.util import get_bool_opt, get_int_opt + +__all__ = ['GroffFormatter'] + + +class GroffFormatter(Formatter): + """ + Format tokens with groff escapes to change their color and font style. + + .. versionadded:: 2.11 + + Additional options accepted: + + `style` + The style to use, can be a string or a Style subclass (default: + ``'default'``). + + `monospaced` + If set to true, monospace font will be used (default: ``true``). + + `linenos` + If set to true, print the line numbers (default: ``false``). + + `wrap` + Wrap lines to the specified number of characters. Disabled if set to 0 + (default: ``0``). + """ + + name = 'groff' + aliases = ['groff','troff','roff'] + filenames = [] + + def __init__(self, **options): + Formatter.__init__(self, **options) + + self.monospaced = get_bool_opt(options, 'monospaced', True) + self.linenos = get_bool_opt(options, 'linenos', False) + self._lineno = 0 + self.wrap = get_int_opt(options, 'wrap', 0) + self._linelen = 0 + + self.styles = {} + self._make_styles() + + + def _make_styles(self): + regular = '\\f[CR]' if self.monospaced else '\\f[R]' + bold = '\\f[CB]' if self.monospaced else '\\f[B]' + italic = '\\f[CI]' if self.monospaced else '\\f[I]' + + for ttype, ndef in self.style: + start = end = '' + if ndef['color']: + start += '\\m[{}]'.format(ndef['color']) + end = '\\m[]' + end + if ndef['bold']: + start += bold + end = regular + end + if ndef['italic']: + start += italic + end = regular + end + if ndef['bgcolor']: + start += '\\M[{}]'.format(ndef['bgcolor']) + end = '\\M[]' + end + + self.styles[ttype] = start, end + + + def _define_colors(self, outfile): + colors = set() + for _, ndef in self.style: + if ndef['color'] is not None: + colors.add(ndef['color']) + + for color in sorted(colors): + outfile.write('.defcolor ' + color + ' rgb #' + color + '\n') + + + def _write_lineno(self, outfile): + self._lineno += 1 + outfile.write("%s% 4d " % (self._lineno != 1 and '\n' or '', self._lineno)) + + + def _wrap_line(self, line): + length = len(line.rstrip('\n')) + space = ' ' if self.linenos else '' + newline = '' + + if length > self.wrap: + for i in range(0, math.floor(length / self.wrap)): + chunk = line[i*self.wrap:i*self.wrap+self.wrap] + newline += (chunk + '\n' + space) + remainder = length % self.wrap + if remainder > 0: + newline += line[-remainder-1:] + self._linelen = remainder + elif self._linelen + length > self.wrap: + newline = ('\n' + space) + line + self._linelen = length + else: + newline = line + self._linelen += length + + return newline + + + def _escape_chars(self, text): + text = text.replace('\\', '\\[u005C]'). \ + replace('.', '\\[char46]'). \ + replace('\'', '\\[u0027]'). \ + replace('`', '\\[u0060]'). \ + replace('~', '\\[u007E]') + copy = text + + for char in copy: + if len(char) != len(char.encode()): + uni = char.encode('unicode_escape') \ + .decode()[1:] \ + .replace('x', 'u00') \ + .upper() + text = text.replace(char, '\\[u' + uni[1:] + ']') + + return text + + + def format_unencoded(self, tokensource, outfile): + self._define_colors(outfile) + + outfile.write('.nf\n\\f[CR]\n') + + if self.linenos: + self._write_lineno(outfile) + + for ttype, value in tokensource: + while ttype not in self.styles: + ttype = ttype.parent + start, end = self.styles[ttype] + + for line in value.splitlines(True): + if self.wrap > 0: + line = self._wrap_line(line) + + if start and end: + text = self._escape_chars(line.rstrip('\n')) + if text != '': + outfile.write(''.join((start, text, end))) + else: + outfile.write(self._escape_chars(line.rstrip('\n'))) + + if line.endswith('\n'): + if self.linenos: + self._write_lineno(outfile) + self._linelen = 0 + else: + outfile.write('\n') + self._linelen = 0 + + outfile.write('\n.fi') diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatters/html.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatters/html.py new file mode 100644 index 0000000000000000000000000000000000000000..17e67414520e016127fba1541207f23c19a0d187 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/formatters/html.py @@ -0,0 +1,997 @@ +""" + pygments.formatters.html + ~~~~~~~~~~~~~~~~~~~~~~~~ + + Formatter for HTML output. + + :copyright: Copyright 2006-present by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import functools +import os +import sys +import os.path +from io import StringIO + +from pygments.formatter import Formatter +from pygments.token import Token, Text, STANDARD_TYPES +from pygments.util import get_bool_opt, get_int_opt, get_list_opt + +import html + +try: + import ctags +except ImportError: + ctags = None + +__all__ = ['HtmlFormatter'] + + +_escape_html_table = { + ord('&'): '&', + ord('<'): '<', + ord('>'): '>', + ord('"'): '"', + ord("'"): ''', +} + + +def escape_html(text, table=_escape_html_table): + """Escape &, <, > as well as single and double quotes for HTML.""" + return text.translate(table) + + +def webify(color): + if color.startswith('calc') or color.startswith('var'): + return color + else: + # Check if the color can be shortened from 6 to 3 characters + color = color.upper() + if (len(color) == 6 and + ( color[0] == color[1] + and color[2] == color[3] + and color[4] == color[5])): + return f'#{color[0]}{color[2]}{color[4]}' + else: + return f'#{color}' + + +def _get_ttype_class(ttype): + fname = STANDARD_TYPES.get(ttype) + if fname: + return fname + aname = '' + while fname is None: + aname = '-' + ttype[-1] + aname + ttype = ttype.parent + fname = STANDARD_TYPES.get(ttype) + return fname + aname + + +CSSFILE_TEMPLATE = '''\ +/* +generated by Pygments +Copyright 2006-present by the Pygments team. +Licensed under the BSD license, see LICENSE for details. +*/ +%(styledefs)s +''' + +DOC_HEADER = '''\ + + + + + %(title)s + + + + +

%(title)s

+ +''' + +DOC_HEADER_EXTERNALCSS = '''\ + + + + + %(title)s + + + + +

%(title)s

+ +''' + +DOC_FOOTER = '''\ + + +''' + + +class HtmlFormatter(Formatter): + r""" + Format tokens as HTML 4 ```` tags. By default, the content is enclosed + in a ``
`` tag, itself wrapped in a ``
`` tag (but see the `nowrap` option). + The ``
``'s CSS class can be set by the `cssclass` option. + + If the `linenos` option is set to ``"table"``, the ``
`` is
+    additionally wrapped inside a ```` which has one row and two
+    cells: one containing the line numbers and one containing the code.
+    Example:
+
+    .. sourcecode:: html
+
+        
+
+ + +
+
1
+            2
+
+
def foo(bar):
+              pass
+            
+
+ + (whitespace added to improve clarity). + + A list of lines can be specified using the `hl_lines` option to make these + lines highlighted (as of Pygments 0.11). + + With the `full` option, a complete HTML 4 document is output, including + the style definitions inside a ``$)', _handle_cssblock), + + include('keywords'), + include('inline'), + ], + 'keywords': [ + (words(( + '\\define', '\\end', 'caption', 'created', 'modified', 'tags', + 'title', 'type'), prefix=r'^', suffix=r'\b'), + Keyword), + ], + 'inline': [ + # escape + (r'\\.', Text), + # created or modified date + (r'\d{17}', Number.Integer), + # italics + (r'(\s)(//[^/]+//)((?=\W|\n))', + bygroups(Text, Generic.Emph, Text)), + # superscript + (r'(\s)(\^\^[^\^]+\^\^)', bygroups(Text, Generic.Emph)), + # subscript + (r'(\s)(,,[^,]+,,)', bygroups(Text, Generic.Emph)), + # underscore + (r'(\s)(__[^_]+__)', bygroups(Text, Generic.Strong)), + # bold + (r"(\s)(''[^']+'')((?=\W|\n))", + bygroups(Text, Generic.Strong, Text)), + # strikethrough + (r'(\s)(~~[^~]+~~)((?=\W|\n))', + bygroups(Text, Generic.Deleted, Text)), + # TiddlyWiki variables + (r'<<[^>]+>>', Name.Tag), + (r'\$\$[^$]+\$\$', Name.Tag), + (r'\$\([^)]+\)\$', Name.Tag), + # TiddlyWiki style or class + (r'^@@.*$', Name.Tag), + # HTML tags + (r']+>', Name.Tag), + # inline code + (r'`[^`]+`', String.Backtick), + # HTML escaped symbols + (r'&\S*?;', String.Regex), + # Wiki links + (r'(\[{2})([^]\|]+)(\]{2})', bygroups(Text, Name.Tag, Text)), + # External links + (r'(\[{2})([^]\|]+)(\|)([^]\|]+)(\]{2})', + bygroups(Text, Name.Tag, Text, Name.Attribute, Text)), + # Transclusion + (r'(\{{2})([^}]+)(\}{2})', bygroups(Text, Name.Tag, Text)), + # URLs + (r'(\b.?.?tps?://[^\s"]+)', bygroups(Name.Attribute)), + + # general text, must come last! + (r'[\w]+', Text), + (r'.', Text) + ], + } + + def __init__(self, **options): + self.handlecodeblocks = get_bool_opt(options, 'handlecodeblocks', True) + RegexLexer.__init__(self, **options) + + +class WikitextLexer(RegexLexer): + """ + For MediaWiki Wikitext. + + Parsing Wikitext is tricky, and results vary between different MediaWiki + installations, so we only highlight common syntaxes (built-in or from + popular extensions), and also assume templates produce no unbalanced + syntaxes. + """ + name = 'Wikitext' + url = 'https://www.mediawiki.org/wiki/Wikitext' + aliases = ['wikitext', 'mediawiki'] + filenames = [] + mimetypes = ['text/x-wiki'] + version_added = '2.15' + flags = re.MULTILINE + + def nowiki_tag_rules(tag_name): + return [ + (rf'(?i)()', bygroups(Punctuation, + Name.Tag, Whitespace, Punctuation), '#pop'), + include('entity'), + include('text'), + ] + + def plaintext_tag_rules(tag_name): + return [ + (rf'(?si)(.*?)()', bygroups(Text, + Punctuation, Name.Tag, Whitespace, Punctuation), '#pop'), + ] + + def delegate_tag_rules(tag_name, lexer, **lexer_kwargs): + return [ + (rf'(?i)()', bygroups(Punctuation, + Name.Tag, Whitespace, Punctuation), '#pop'), + (rf'(?si).+?(?=)', using(lexer, **lexer_kwargs)), + ] + + def text_rules(token): + return [ + (r'\w+', token), + (r'[^\S\n]+', token), + (r'(?s).', token), + ] + + def handle_syntaxhighlight(self, match, ctx): + from pygments.lexers import get_lexer_by_name + + attr_content = match.group() + start = 0 + index = 0 + while True: + index = attr_content.find('>', start) + # Exclude comment end (-->) + if attr_content[index-2:index] != '--': + break + start = index + 1 + + if index == -1: + # No tag end + yield from self.get_tokens_unprocessed(attr_content, stack=['root', 'attr']) + return + attr = attr_content[:index] + yield from self.get_tokens_unprocessed(attr, stack=['root', 'attr']) + yield match.start(3) + index, Punctuation, '>' + + lexer = None + content = attr_content[index+1:] + lang_match = re.findall(r'\blang=("|\'|)(\w+)(\1)', attr) + + if len(lang_match) >= 1: + # Pick the last match in case of multiple matches + lang = lang_match[-1][1] + try: + lexer = get_lexer_by_name(lang) + except ClassNotFound: + pass + + if lexer is None: + yield match.start() + index + 1, Text, content + else: + yield from lexer.get_tokens_unprocessed(content) + + def handle_score(self, match, ctx): + attr_content = match.group() + start = 0 + index = 0 + while True: + index = attr_content.find('>', start) + # Exclude comment end (-->) + if attr_content[index-2:index] != '--': + break + start = index + 1 + + if index == -1: + # No tag end + yield from self.get_tokens_unprocessed(attr_content, stack=['root', 'attr']) + return + attr = attr_content[:index] + content = attr_content[index+1:] + yield from self.get_tokens_unprocessed(attr, stack=['root', 'attr']) + yield match.start(3) + index, Punctuation, '>' + + lang_match = re.findall(r'\blang=("|\'|)(\w+)(\1)', attr) + # Pick the last match in case of multiple matches + lang = lang_match[-1][1] if len(lang_match) >= 1 else 'lilypond' + + if lang == 'lilypond': # Case sensitive + yield from LilyPondLexer().get_tokens_unprocessed(content) + else: # ABC + # FIXME: Use ABC lexer in the future + yield match.start() + index + 1, Text, content + + # a-z removed to prevent linter from complaining, REMEMBER to use (?i) + title_char = r' %!"$&\'()*,\-./0-9:;=?@A-Z\\\^_`~+\u0080-\uFFFF' + nbsp_char = r'(?:\t| |&\#0*160;|&\#[Xx]0*[Aa]0;|[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000])' + link_address = r'(?:[0-9.]+|\[[0-9a-f:.]+\]|[^\x00-\x20"<>\[\]\x7F\xA0\u1680\u2000-\u200A\u202F\u205F\u3000\uFFFD])' + link_char_class = r'[^\x00-\x20"<>\[\]\x7F\xA0\u1680\u2000-\u200A\u202F\u205F\u3000\uFFFD]' + double_slashes_i = { + '__FORCETOC__', '__NOCONTENTCONVERT__', '__NOCC__', '__NOEDITSECTION__', '__NOGALLERY__', + '__NOTITLECONVERT__', '__NOTC__', '__NOTOC__', '__TOC__', + } + double_slashes = { + '__EXPECTUNUSEDCATEGORY__', '__HIDDENCAT__', '__INDEX__', '__NEWSECTIONLINK__', + '__NOINDEX__', '__NONEWSECTIONLINK__', '__STATICREDIRECT__', '__NOGLOBAL__', + '__DISAMBIG__', '__EXPECTED_UNCONNECTED_PAGE__', + } + protocols = { + 'bitcoin:', 'ftp://', 'ftps://', 'geo:', 'git://', 'gopher://', 'http://', 'https://', + 'irc://', 'ircs://', 'magnet:', 'mailto:', 'mms://', 'news:', 'nntp://', 'redis://', + 'sftp://', 'sip:', 'sips:', 'sms:', 'ssh://', 'svn://', 'tel:', 'telnet://', 'urn:', + 'worldwind://', 'xmpp:', '//', + } + non_relative_protocols = protocols - {'//'} + html_tags = { + 'abbr', 'b', 'bdi', 'bdo', 'big', 'blockquote', 'br', 'caption', 'center', 'cite', 'code', + 'data', 'dd', 'del', 'dfn', 'div', 'dl', 'dt', 'em', 'font', 'h1', 'h2', 'h3', 'h4', 'h5', + 'h6', 'hr', 'i', 'ins', 'kbd', 'li', 'link', 'mark', 'meta', 'ol', 'p', 'q', 'rb', 'rp', + 'rt', 'rtc', 'ruby', 's', 'samp', 'small', 'span', 'strike', 'strong', 'sub', 'sup', + 'table', 'td', 'th', 'time', 'tr', 'tt', 'u', 'ul', 'var', 'wbr', + } + parser_tags = { + 'graph', 'charinsert', 'rss', 'chem', 'categorytree', 'nowiki', 'inputbox', 'math', + 'hiero', 'score', 'pre', 'ref', 'translate', 'imagemap', 'templatestyles', 'languages', + 'noinclude', 'mapframe', 'section', 'poem', 'syntaxhighlight', 'includeonly', 'tvar', + 'onlyinclude', 'templatedata', 'langconvert', 'timeline', 'dynamicpagelist', 'gallery', + 'maplink', 'ce', 'references', + } + variant_langs = { + # ZhConverter.php + 'zh', 'zh-hans', 'zh-hant', 'zh-cn', 'zh-hk', 'zh-mo', 'zh-my', 'zh-sg', 'zh-tw', + # WuuConverter.php + 'wuu', 'wuu-hans', 'wuu-hant', + # UzConverter.php + 'uz', 'uz-latn', 'uz-cyrl', + # TlyConverter.php + 'tly', 'tly-cyrl', + # TgConverter.php + 'tg', 'tg-latn', + # SrConverter.php + 'sr', 'sr-ec', 'sr-el', + # ShiConverter.php + 'shi', 'shi-tfng', 'shi-latn', + # ShConverter.php + 'sh-latn', 'sh-cyrl', + # KuConverter.php + 'ku', 'ku-arab', 'ku-latn', + # IuConverter.php + 'iu', 'ike-cans', 'ike-latn', + # GanConverter.php + 'gan', 'gan-hans', 'gan-hant', + # EnConverter.php + 'en', 'en-x-piglatin', + # CrhConverter.php + 'crh', 'crh-cyrl', 'crh-latn', + # BanConverter.php + 'ban', 'ban-bali', 'ban-x-dharma', 'ban-x-palmleaf', 'ban-x-pku', + } + magic_vars_i = { + 'ARTICLEPATH', 'INT', 'PAGEID', 'SCRIPTPATH', 'SERVER', 'SERVERNAME', 'STYLEPATH', + } + magic_vars = { + '!', '=', 'BASEPAGENAME', 'BASEPAGENAMEE', 'CASCADINGSOURCES', 'CONTENTLANGUAGE', + 'CONTENTLANG', 'CURRENTDAY', 'CURRENTDAY2', 'CURRENTDAYNAME', 'CURRENTDOW', 'CURRENTHOUR', + 'CURRENTMONTH', 'CURRENTMONTH2', 'CURRENTMONTH1', 'CURRENTMONTHABBREV', 'CURRENTMONTHNAME', + 'CURRENTMONTHNAMEGEN', 'CURRENTTIME', 'CURRENTTIMESTAMP', 'CURRENTVERSION', 'CURRENTWEEK', + 'CURRENTYEAR', 'DIRECTIONMARK', 'DIRMARK', 'FULLPAGENAME', 'FULLPAGENAMEE', 'LOCALDAY', + 'LOCALDAY2', 'LOCALDAYNAME', 'LOCALDOW', 'LOCALHOUR', 'LOCALMONTH', 'LOCALMONTH2', + 'LOCALMONTH1', 'LOCALMONTHABBREV', 'LOCALMONTHNAME', 'LOCALMONTHNAMEGEN', 'LOCALTIME', + 'LOCALTIMESTAMP', 'LOCALWEEK', 'LOCALYEAR', 'NAMESPACE', 'NAMESPACEE', 'NAMESPACENUMBER', + 'NUMBEROFACTIVEUSERS', 'NUMBEROFADMINS', 'NUMBEROFARTICLES', 'NUMBEROFEDITS', + 'NUMBEROFFILES', 'NUMBEROFPAGES', 'NUMBEROFUSERS', 'PAGELANGUAGE', 'PAGENAME', 'PAGENAMEE', + 'REVISIONDAY', 'REVISIONDAY2', 'REVISIONID', 'REVISIONMONTH', 'REVISIONMONTH1', + 'REVISIONSIZE', 'REVISIONTIMESTAMP', 'REVISIONUSER', 'REVISIONYEAR', 'ROOTPAGENAME', + 'ROOTPAGENAMEE', 'SITENAME', 'SUBJECTPAGENAME', 'ARTICLEPAGENAME', 'SUBJECTPAGENAMEE', + 'ARTICLEPAGENAMEE', 'SUBJECTSPACE', 'ARTICLESPACE', 'SUBJECTSPACEE', 'ARTICLESPACEE', + 'SUBPAGENAME', 'SUBPAGENAMEE', 'TALKPAGENAME', 'TALKPAGENAMEE', 'TALKSPACE', 'TALKSPACEE', + } + parser_functions_i = { + 'ANCHORENCODE', 'BIDI', 'CANONICALURL', 'CANONICALURLE', 'FILEPATH', 'FORMATNUM', + 'FULLURL', 'FULLURLE', 'GENDER', 'GRAMMAR', 'INT', r'\#LANGUAGE', 'LC', 'LCFIRST', 'LOCALURL', + 'LOCALURLE', 'NS', 'NSE', 'PADLEFT', 'PADRIGHT', 'PAGEID', 'PLURAL', 'UC', 'UCFIRST', + 'URLENCODE', + } + parser_functions = { + 'BASEPAGENAME', 'BASEPAGENAMEE', 'CASCADINGSOURCES', 'DEFAULTSORT', 'DEFAULTSORTKEY', + 'DEFAULTCATEGORYSORT', 'FULLPAGENAME', 'FULLPAGENAMEE', 'NAMESPACE', 'NAMESPACEE', + 'NAMESPACENUMBER', 'NUMBERINGROUP', 'NUMINGROUP', 'NUMBEROFACTIVEUSERS', 'NUMBEROFADMINS', + 'NUMBEROFARTICLES', 'NUMBEROFEDITS', 'NUMBEROFFILES', 'NUMBEROFPAGES', 'NUMBEROFUSERS', + 'PAGENAME', 'PAGENAMEE', 'PAGESINCATEGORY', 'PAGESINCAT', 'PAGESIZE', 'PROTECTIONEXPIRY', + 'PROTECTIONLEVEL', 'REVISIONDAY', 'REVISIONDAY2', 'REVISIONID', 'REVISIONMONTH', + 'REVISIONMONTH1', 'REVISIONTIMESTAMP', 'REVISIONUSER', 'REVISIONYEAR', 'ROOTPAGENAME', + 'ROOTPAGENAMEE', 'SUBJECTPAGENAME', 'ARTICLEPAGENAME', 'SUBJECTPAGENAMEE', + 'ARTICLEPAGENAMEE', 'SUBJECTSPACE', 'ARTICLESPACE', 'SUBJECTSPACEE', 'ARTICLESPACEE', + 'SUBPAGENAME', 'SUBPAGENAMEE', 'TALKPAGENAME', 'TALKPAGENAMEE', 'TALKSPACE', 'TALKSPACEE', + 'INT', 'DISPLAYTITLE', 'PAGESINNAMESPACE', 'PAGESINNS', + } + + tokens = { + 'root': [ + # Redirects + (r"""(?xi) + (\A\s*?)(\#REDIRECT:?) # may contain a colon + (\s+)(\[\[) (?=[^\]\n]* \]\]$) + """, + bygroups(Whitespace, Keyword, Whitespace, Punctuation), 'redirect-inner'), + # Subheadings + (r'^(={2,6})(.+?)(\1)(\s*$\n)', + bygroups(Generic.Subheading, Generic.Subheading, Generic.Subheading, Whitespace)), + # Headings + (r'^(=.+?=)(\s*$\n)', + bygroups(Generic.Heading, Whitespace)), + # Double-slashed magic words + (words(double_slashes_i, prefix=r'(?i)'), Name.Function.Magic), + (words(double_slashes), Name.Function.Magic), + # Raw URLs + (r'(?i)\b(?:{}){}{}*'.format('|'.join(protocols), + link_address, link_char_class), Name.Label), + # Magic links + (rf'\b(?:RFC|PMID){nbsp_char}+[0-9]+\b', + Name.Function.Magic), + (r"""(?x) + \bISBN {nbsp_char} + (?: 97[89] {nbsp_dash}? )? + (?: [0-9] {nbsp_dash}? ){{9}} # escape format() + [0-9Xx]\b + """.format(nbsp_char=nbsp_char, nbsp_dash=f'(?:-|{nbsp_char})'), Name.Function.Magic), + include('list'), + include('inline'), + include('text'), + ], + 'redirect-inner': [ + (r'(\]\])(\s*?\n)', bygroups(Punctuation, Whitespace), '#pop'), + (r'(\#)([^#]*?)', bygroups(Punctuation, Name.Label)), + (rf'(?i)[{title_char}]+', Name.Tag), + ], + 'list': [ + # Description lists + (r'^;', Keyword, 'dt'), + # Ordered lists, unordered lists and indents + (r'^[#:*]+', Keyword), + # Horizontal rules + (r'^-{4,}', Keyword), + ], + 'inline': [ + # Signatures + (r'~{3,5}', Keyword), + # Entities + include('entity'), + # Bold & italic + (r"('')(''')(?!')", bygroups(Generic.Emph, + Generic.EmphStrong), 'inline-italic-bold'), + (r"'''(?!')", Generic.Strong, 'inline-bold'), + (r"''(?!')", Generic.Emph, 'inline-italic'), + # Comments & parameters & templates + include('replaceable'), + # Media links + ( + r"""(?xi) + (\[\[) + (File|Image) (:) + ((?: [{}] | \{{{{2,3}}[^{{}}]*?\}}{{2,3}} | )*) + (?: (\#) ([{}]*?) )? + """.format(title_char, f'{title_char}#'), + bygroups(Punctuation, Name.Namespace, Punctuation, + using(this, state=['wikilink-name']), Punctuation, Name.Label), + 'medialink-inner' + ), + # Wikilinks + ( + r"""(?xi) + (\[\[)(?!{}) # Should not contain URLs + (?: ([{}]*) (:))? + ((?: [{}] | \{{{{2,3}}[^{{}}]*?\}}{{2,3}} | )*?) + (?: (\#) ([{}]*?) )? + (\]\]) + """.format('|'.join(protocols), title_char.replace('/', ''), + title_char, f'{title_char}#'), + bygroups(Punctuation, Name.Namespace, Punctuation, + using(this, state=['wikilink-name']), Punctuation, Name.Label, Punctuation) + ), + ( + r"""(?xi) + (\[\[)(?!{}) + (?: ([{}]*) (:))? + ((?: [{}] | \{{{{2,3}}[^{{}}]*?\}}{{2,3}} | )*?) + (?: (\#) ([{}]*?) )? + (\|) + """.format('|'.join(protocols), title_char.replace('/', ''), + title_char, f'{title_char}#'), + bygroups(Punctuation, Name.Namespace, Punctuation, + using(this, state=['wikilink-name']), Punctuation, Name.Label, Punctuation), + 'wikilink-inner' + ), + # External links + ( + r"""(?xi) + (\[) + ((?:{}) {} {}*) + (\s*) + """.format('|'.join(protocols), link_address, link_char_class), + bygroups(Punctuation, Name.Label, Whitespace), + 'extlink-inner' + ), + # Tables + (r'^(:*)(\s*?)(\{\|)([^\n]*)$', bygroups(Keyword, + Whitespace, Punctuation, using(this, state=['root', 'attr'])), 'table'), + # HTML tags + (r'(?i)(<)({})\b'.format('|'.join(html_tags)), + bygroups(Punctuation, Name.Tag), 'tag-inner-ordinary'), + (r'(?i)()'.format('|'.join(html_tags)), + bygroups(Punctuation, Name.Tag, Whitespace, Punctuation)), + # + (r'(?i)(<)(nowiki)\b', bygroups(Punctuation, + Name.Tag), ('tag-nowiki', 'tag-inner')), + #
+            (r'(?i)(<)(pre)\b', bygroups(Punctuation,
+             Name.Tag), ('tag-pre', 'tag-inner')),
+            # 
+            (r'(?i)(<)(categorytree)\b', bygroups(
+                Punctuation, Name.Tag), ('tag-categorytree', 'tag-inner')),
+            # 
+            (r'(?i)(<)(hiero)\b', bygroups(Punctuation,
+             Name.Tag), ('tag-hiero', 'tag-inner')),
+            # 
+            (r'(?i)(<)(math)\b', bygroups(Punctuation,
+             Name.Tag), ('tag-math', 'tag-inner')),
+            # 
+            (r'(?i)(<)(chem)\b', bygroups(Punctuation,
+             Name.Tag), ('tag-chem', 'tag-inner')),
+            # 
+            (r'(?i)(<)(ce)\b', bygroups(Punctuation,
+             Name.Tag), ('tag-ce', 'tag-inner')),
+            # 
+            (r'(?i)(<)(charinsert)\b', bygroups(
+                Punctuation, Name.Tag), ('tag-charinsert', 'tag-inner')),
+            # 
+            (r'(?i)(<)(templatedata)\b', bygroups(
+                Punctuation, Name.Tag), ('tag-templatedata', 'tag-inner')),
+            # 
+            (r'(?i)(<)(gallery)\b', bygroups(
+                Punctuation, Name.Tag), ('tag-gallery', 'tag-inner')),
+            # 
+            (r'(?i)(<)(gallery)\b', bygroups(
+                Punctuation, Name.Tag), ('tag-graph', 'tag-inner')),
+            # 
+            (r'(?i)(<)(dynamicpagelist)\b', bygroups(
+                Punctuation, Name.Tag), ('tag-dynamicpagelist', 'tag-inner')),
+            # 
+            (r'(?i)(<)(inputbox)\b', bygroups(
+                Punctuation, Name.Tag), ('tag-inputbox', 'tag-inner')),
+            # 
+            (r'(?i)(<)(rss)\b', bygroups(
+                Punctuation, Name.Tag), ('tag-rss', 'tag-inner')),
+            # 
+            (r'(?i)(<)(imagemap)\b', bygroups(
+                Punctuation, Name.Tag), ('tag-imagemap', 'tag-inner')),
+            # 
+            (r'(?i)()',
+             bygroups(Punctuation, Name.Tag, Whitespace, Punctuation)),
+            (r'(?si)(<)(syntaxhighlight)\b([^>]*?(?.*?)(?=)',
+             bygroups(Punctuation, Name.Tag, handle_syntaxhighlight)),
+            # : Fallback case for self-closing tags
+            (r'(?i)(<)(syntaxhighlight)\b(\s*?)((?:[^>]|-->)*?)(/\s*?(?)*?)(/\s*?(?)*?)(/\s*?(?|\Z)', Comment.Multiline),
+            # Parameters
+            (
+                r"""(?x)
+                (\{{3})
+                    ([^|]*?)
+                    (?=\}{3}|\|)
+                """,
+                bygroups(Punctuation, Name.Variable),
+                'parameter-inner',
+            ),
+            # Magic variables
+            (r'(?i)(\{{\{{)(\s*)({})(\s*)(\}}\}})'.format('|'.join(magic_vars_i)),
+             bygroups(Punctuation, Whitespace, Name.Function, Whitespace, Punctuation)),
+            (r'(\{{\{{)(\s*)({})(\s*)(\}}\}})'.format('|'.join(magic_vars)),
+                bygroups(Punctuation, Whitespace, Name.Function, Whitespace, Punctuation)),
+            # Parser functions & templates
+            (r'\{\{', Punctuation, 'template-begin-space'),
+            #  legacy syntax
+            (r'(?i)(<)(tvar)\b(\|)([^>]*?)(>)', bygroups(Punctuation,
+             Name.Tag, Punctuation, String, Punctuation)),
+            (r'', Punctuation, '#pop'),
+            # 
+            (r'(?i)(<)(tvar)\b', bygroups(Punctuation, Name.Tag), 'tag-inner-ordinary'),
+            (r'(?i)()',
+             bygroups(Punctuation, Name.Tag, Whitespace, Punctuation)),
+        ],
+        'parameter-inner': [
+            (r'\}{3}', Punctuation, '#pop'),
+            (r'\|', Punctuation),
+            include('inline'),
+            include('text'),
+        ],
+        'template-begin-space': [
+            # Templates allow line breaks at the beginning, and due to how MediaWiki handles
+            # comments, an extra state is required to handle things like {{\n\n name}}
+            (r'|\Z)', Comment.Multiline),
+            (r'\s+', Whitespace),
+            # Parser functions
+            (
+                r'(?i)(\#[{}]*?|{})(:)'.format(title_char,
+                                           '|'.join(parser_functions_i)),
+                bygroups(Name.Function, Punctuation), ('#pop', 'template-inner')
+            ),
+            (
+                r'({})(:)'.format('|'.join(parser_functions)),
+                bygroups(Name.Function, Punctuation), ('#pop', 'template-inner')
+            ),
+            # Templates
+            (
+                rf'(?i)([{title_char}]*?)(:)',
+                bygroups(Name.Namespace, Punctuation), ('#pop', 'template-name')
+            ),
+            default(('#pop', 'template-name'),),
+        ],
+        'template-name': [
+            (r'(\s*?)(\|)', bygroups(Text, Punctuation), ('#pop', 'template-inner')),
+            (r'\}\}', Punctuation, '#pop'),
+            (r'\n', Text, '#pop'),
+            include('replaceable'),
+            *text_rules(Name.Tag),
+        ],
+        'template-inner': [
+            (r'\}\}', Punctuation, '#pop'),
+            (r'\|', Punctuation),
+            (
+                r"""(?x)
+                    (?<=\|)
+                    ( (?: (?! \{\{ | \}\} )[^=\|<])*? ) # Exclude templates and tags
+                    (=)
+                """,
+                bygroups(Name.Label, Operator)
+            ),
+            include('inline'),
+            include('text'),
+        ],
+        'table': [
+            # Use [ \t\n\r\0\x0B] instead of \s to follow PHP trim() behavior
+            # Endings
+            (r'^([ \t\n\r\0\x0B]*?)(\|\})',
+             bygroups(Whitespace, Punctuation), '#pop'),
+            # Table rows
+            (r'^([ \t\n\r\0\x0B]*?)(\|-+)(.*)$', bygroups(Whitespace, Punctuation,
+             using(this, state=['root', 'attr']))),
+            # Captions
+            (
+                r"""(?x)
+                ^([ \t\n\r\0\x0B]*?)(\|\+)
+                # Exclude links, template and tags
+                (?: ( (?: (?! \[\[ | \{\{ )[^|\n<] )*? )(\|) )?
+                (.*?)$
+                """,
+                bygroups(Whitespace, Punctuation, using(this, state=[
+                         'root', 'attr']), Punctuation, Generic.Heading),
+            ),
+            # Table data
+            (
+                r"""(?x)
+                ( ^(?:[ \t\n\r\0\x0B]*?)\| | \|\| )
+                (?: ( (?: (?! \[\[ | \{\{ )[^|\n<] )*? )(\|)(?!\|) )?
+                """,
+                bygroups(Punctuation, using(this, state=[
+                         'root', 'attr']), Punctuation),
+            ),
+            # Table headers
+            (
+                r"""(?x)
+                ( ^(?:[ \t\n\r\0\x0B]*?)!  )
+                (?: ( (?: (?! \[\[ | \{\{ )[^|\n<] )*? )(\|)(?!\|) )?
+                """,
+                bygroups(Punctuation, using(this, state=[
+                         'root', 'attr']), Punctuation),
+                'table-header',
+            ),
+            include('list'),
+            include('inline'),
+            include('text'),
+        ],
+        'table-header': [
+            # Requires another state for || handling inside headers
+            (r'\n', Text, '#pop'),
+            (
+                r"""(?x)
+                (!!|\|\|)
+                (?:
+                    ( (?: (?! \[\[ | \{\{ )[^|\n<] )*? )
+                    (\|)(?!\|)
+                )?
+                """,
+                bygroups(Punctuation, using(this, state=[
+                         'root', 'attr']), Punctuation)
+            ),
+            *text_rules(Generic.Subheading),
+        ],
+        'entity': [
+            (r'&\S*?;', Name.Entity),
+        ],
+        'dt': [
+            (r'\n', Text, '#pop'),
+            include('inline'),
+            (r':', Keyword, '#pop'),
+            include('text'),
+        ],
+        'extlink-inner': [
+            (r'\]', Punctuation, '#pop'),
+            include('inline'),
+            include('text'),
+        ],
+        'nowiki-ish': [
+            include('entity'),
+            include('text'),
+        ],
+        'attr': [
+            include('replaceable'),
+            (r'\s+', Whitespace),
+            (r'(=)(\s*)(")', bygroups(Operator, Whitespace, String.Double), 'attr-val-2'),
+            (r"(=)(\s*)(')", bygroups(Operator, Whitespace, String.Single), 'attr-val-1'),
+            (r'(=)(\s*)', bygroups(Operator, Whitespace), 'attr-val-0'),
+            (r'[\w:-]+', Name.Attribute),
+
+        ],
+        'attr-val-0': [
+            (r'\s', Whitespace, '#pop'),
+            include('replaceable'),
+            *text_rules(String),
+        ],
+        'attr-val-1': [
+            (r"'", String.Single, '#pop'),
+            include('replaceable'),
+            *text_rules(String.Single),
+        ],
+        'attr-val-2': [
+            (r'"', String.Double, '#pop'),
+            include('replaceable'),
+            *text_rules(String.Double),
+        ],
+        'tag-inner-ordinary': [
+            (r'/?\s*>', Punctuation, '#pop'),
+            include('tag-attr'),
+        ],
+        'tag-inner': [
+            # Return to root state for self-closing tags
+            (r'/\s*>', Punctuation, '#pop:2'),
+            (r'\s*>', Punctuation, '#pop'),
+            include('tag-attr'),
+        ],
+        # There states below are just like their non-tag variants, the key difference is
+        # they forcibly quit when encountering tag closing markup
+        'tag-attr': [
+            include('replaceable'),
+            (r'\s+', Whitespace),
+            (r'(=)(\s*)(")', bygroups(Operator,
+             Whitespace, String.Double), 'tag-attr-val-2'),
+            (r"(=)(\s*)(')", bygroups(Operator,
+             Whitespace, String.Single), 'tag-attr-val-1'),
+            (r'(=)(\s*)', bygroups(Operator, Whitespace), 'tag-attr-val-0'),
+            (r'[\w:-]+', Name.Attribute),
+
+        ],
+        'tag-attr-val-0': [
+            (r'\s', Whitespace, '#pop'),
+            (r'/?>', Punctuation, '#pop:2'),
+            include('replaceable'),
+            *text_rules(String),
+        ],
+        'tag-attr-val-1': [
+            (r"'", String.Single, '#pop'),
+            (r'/?>', Punctuation, '#pop:2'),
+            include('replaceable'),
+            *text_rules(String.Single),
+        ],
+        'tag-attr-val-2': [
+            (r'"', String.Double, '#pop'),
+            (r'/?>', Punctuation, '#pop:2'),
+            include('replaceable'),
+            *text_rules(String.Double),
+        ],
+        'tag-nowiki': nowiki_tag_rules('nowiki'),
+        'tag-pre': nowiki_tag_rules('pre'),
+        'tag-categorytree': plaintext_tag_rules('categorytree'),
+        'tag-dynamicpagelist': plaintext_tag_rules('dynamicpagelist'),
+        'tag-hiero': plaintext_tag_rules('hiero'),
+        'tag-inputbox': plaintext_tag_rules('inputbox'),
+        'tag-imagemap': plaintext_tag_rules('imagemap'),
+        'tag-charinsert': plaintext_tag_rules('charinsert'),
+        'tag-timeline': plaintext_tag_rules('timeline'),
+        'tag-gallery': plaintext_tag_rules('gallery'),
+        'tag-graph': plaintext_tag_rules('graph'),
+        'tag-rss': plaintext_tag_rules('rss'),
+        'tag-math': delegate_tag_rules('math', TexLexer, state='math'),
+        'tag-chem': delegate_tag_rules('chem', TexLexer, state='math'),
+        'tag-ce': delegate_tag_rules('ce', TexLexer, state='math'),
+        'tag-templatedata': delegate_tag_rules('templatedata', JsonLexer),
+        'text-italic': text_rules(Generic.Emph),
+        'text-bold': text_rules(Generic.Strong),
+        'text-bold-italic': text_rules(Generic.EmphStrong),
+        'text': text_rules(Text),
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/math.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/math.py
new file mode 100644
index 0000000000000000000000000000000000000000..b38c13e1209ae49df646465b00c5fd3df40bf30a
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/math.py
@@ -0,0 +1,21 @@
+"""
+    pygments.lexers.math
+    ~~~~~~~~~~~~~~~~~~~~
+
+    Just export lexers that were contained in this module.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+# ruff: noqa: F401
+from pygments.lexers.python import NumPyLexer
+from pygments.lexers.matlab import MatlabLexer, MatlabSessionLexer, \
+    OctaveLexer, ScilabLexer
+from pygments.lexers.julia import JuliaLexer, JuliaConsoleLexer
+from pygments.lexers.r import RConsoleLexer, SLexer, RdLexer
+from pygments.lexers.modeling import BugsLexer, JagsLexer, StanLexer
+from pygments.lexers.idl import IDLLexer
+from pygments.lexers.algebra import MuPADLexer
+
+__all__ = []
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/matlab.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/matlab.py
new file mode 100644
index 0000000000000000000000000000000000000000..b27f4db63edd75313a76304d7a403f9d62d2b3b2
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/matlab.py
@@ -0,0 +1,3307 @@
+"""
+    pygments.lexers.matlab
+    ~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for Matlab and related languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import Lexer, RegexLexer, bygroups, default, words, \
+    do_insertions, include
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation, Generic, Whitespace
+
+from pygments.lexers import _scilab_builtins
+
+__all__ = ['MatlabLexer', 'MatlabSessionLexer', 'OctaveLexer', 'ScilabLexer']
+
+
+class MatlabLexer(RegexLexer):
+    """
+    For Matlab source code.
+    """
+    name = 'Matlab'
+    aliases = ['matlab']
+    filenames = ['*.m']
+    mimetypes = ['text/matlab']
+    url = 'https://www.mathworks.com/products/matlab.html'
+    version_added = '0.10'
+
+    _operators = r'-|==|~=|<=|>=|<|>|&&|&|~|\|\|?|\.\*|\*|\+|\.\^|\^|\.\\|\./|/|\\'
+
+    tokens = {
+        'expressions': [
+            # operators:
+            (_operators, Operator),
+
+            # numbers (must come before punctuation to handle `.5`; cannot use
+            # `\b` due to e.g. `5. + .5`).  The negative lookahead on operators
+            # avoids including the dot in `1./x` (the dot is part of `./`).
+            (rf'(? and then
+            # (equal | open-parenthesis |  | ).
+            (rf'(?:^|(?<=;))(\s*)(\w+)(\s+)(?!=|\(|{_operators}\s|\s)',
+             bygroups(Whitespace, Name, Whitespace), 'commandargs'),
+
+            include('expressions')
+        ],
+        'blockcomment': [
+            (r'^\s*%\}', Comment.Multiline, '#pop'),
+            (r'^.*\n', Comment.Multiline),
+            (r'.', Comment.Multiline),
+        ],
+        'deffunc': [
+            (r'(\s*)(?:(\S+)(\s*)(=)(\s*))?(.+)(\()(.*)(\))(\s*)',
+             bygroups(Whitespace, Text, Whitespace, Punctuation,
+                      Whitespace, Name.Function, Punctuation, Text,
+                      Punctuation, Whitespace), '#pop'),
+            # function with no args
+            (r'(\s*)([a-zA-Z_]\w*)',
+             bygroups(Whitespace, Name.Function), '#pop'),
+        ],
+        'propattrs': [
+            (r'(\w+)(\s*)(=)(\s*)(\d+)',
+             bygroups(Name.Builtin, Whitespace, Punctuation, Whitespace,
+                      Number)),
+            (r'(\w+)(\s*)(=)(\s*)([a-zA-Z]\w*)',
+             bygroups(Name.Builtin, Whitespace, Punctuation, Whitespace,
+                      Keyword)),
+            (r',', Punctuation),
+            (r'\)', Punctuation, '#pop'),
+            (r'\s+', Whitespace),
+            (r'.', Text),
+        ],
+        'defprops': [
+            (r'%\{\s*\n', Comment.Multiline, 'blockcomment'),
+            (r'%.*$', Comment),
+            (r'(?.
+    """
+    name = 'Matlab session'
+    aliases = ['matlabsession']
+    url = 'https://www.mathworks.com/products/matlab.html'
+    version_added = '0.10'
+    _example = "matlabsession/matlabsession_sample.txt"
+
+    def get_tokens_unprocessed(self, text):
+        mlexer = MatlabLexer(**self.options)
+
+        curcode = ''
+        insertions = []
+        continuation = False
+
+        for match in line_re.finditer(text):
+            line = match.group()
+
+            if line.startswith('>> '):
+                insertions.append((len(curcode),
+                                   [(0, Generic.Prompt, line[:3])]))
+                curcode += line[3:]
+
+            elif line.startswith('>>'):
+                insertions.append((len(curcode),
+                                   [(0, Generic.Prompt, line[:2])]))
+                curcode += line[2:]
+
+            elif line.startswith('???'):
+
+                idx = len(curcode)
+
+                # without is showing error on same line as before...?
+                # line = "\n" + line
+                token = (0, Generic.Traceback, line)
+                insertions.append((idx, [token]))
+            elif continuation and insertions:
+                # line_start is the length of the most recent prompt symbol
+                line_start = len(insertions[-1][-1][-1])
+                # Set leading spaces with the length of the prompt to be a generic prompt
+                # This keeps code aligned when prompts are removed, say with some Javascript
+                if line.startswith(' '*line_start):
+                    insertions.append(
+                        (len(curcode), [(0, Generic.Prompt, line[:line_start])]))
+                    curcode += line[line_start:]
+                else:
+                    curcode += line
+            else:
+                if curcode:
+                    yield from do_insertions(
+                        insertions, mlexer.get_tokens_unprocessed(curcode))
+                    curcode = ''
+                    insertions = []
+
+                yield match.start(), Generic.Output, line
+
+            # Does not allow continuation if a comment is included after the ellipses.
+            # Continues any line that ends with ..., even comments (lines that start with %)
+            if line.strip().endswith('...'):
+                continuation = True
+            else:
+                continuation = False
+
+        if curcode:  # or item:
+            yield from do_insertions(
+                insertions, mlexer.get_tokens_unprocessed(curcode))
+
+
+class OctaveLexer(RegexLexer):
+    """
+    For GNU Octave source code.
+    """
+    name = 'Octave'
+    url = 'https://www.gnu.org/software/octave/index'
+    aliases = ['octave']
+    filenames = ['*.m']
+    mimetypes = ['text/octave']
+    version_added = '1.5'
+
+    # These lists are generated automatically.
+    # Run the following in bash shell:
+    #
+    # First dump all of the Octave manual into a plain text file:
+    #
+    #   $ info octave --subnodes -o octave-manual
+    #
+    # Now grep through it:
+
+    # for i in \
+    #     "Built-in Function" "Command" "Function File" \
+    #     "Loadable Function" "Mapping Function";
+    # do
+    #     perl -e '@name = qw('"$i"');
+    #              print lc($name[0]),"_kw = [\n"';
+    #
+    #     perl -n -e 'print "\"$1\",\n" if /-- '"$i"': .* (\w*) \(/;' \
+    #         octave-manual | sort | uniq ;
+    #     echo "]" ;
+    #     echo;
+    # done
+
+    # taken from Octave Mercurial changeset 8cc154f45e37 (30-jan-2011)
+
+    builtin_kw = (
+        "addlistener", "addpath", "addproperty", "all",
+        "and", "any", "argnames", "argv", "assignin",
+        "atexit", "autoload",
+        "available_graphics_toolkits", "beep_on_error",
+        "bitand", "bitmax", "bitor", "bitshift", "bitxor",
+        "cat", "cell", "cellstr", "char", "class", "clc",
+        "columns", "command_line_path",
+        "completion_append_char", "completion_matches",
+        "complex", "confirm_recursive_rmdir", "cputime",
+        "crash_dumps_octave_core", "ctranspose", "cumprod",
+        "cumsum", "debug_on_error", "debug_on_interrupt",
+        "debug_on_warning", "default_save_options",
+        "dellistener", "diag", "diff", "disp",
+        "doc_cache_file", "do_string_escapes", "double",
+        "drawnow", "e", "echo_executing_commands", "eps",
+        "eq", "errno", "errno_list", "error", "eval",
+        "evalin", "exec", "exist", "exit", "eye", "false",
+        "fclear", "fclose", "fcntl", "fdisp", "feof",
+        "ferror", "feval", "fflush", "fgetl", "fgets",
+        "fieldnames", "file_in_loadpath", "file_in_path",
+        "filemarker", "filesep", "find_dir_in_path",
+        "fixed_point_format", "fnmatch", "fopen", "fork",
+        "formula", "fprintf", "fputs", "fread", "freport",
+        "frewind", "fscanf", "fseek", "fskipl", "ftell",
+        "functions", "fwrite", "ge", "genpath", "get",
+        "getegid", "getenv", "geteuid", "getgid",
+        "getpgrp", "getpid", "getppid", "getuid", "glob",
+        "gt", "gui_mode", "history_control",
+        "history_file", "history_size",
+        "history_timestamp_format_string", "home",
+        "horzcat", "hypot", "ifelse",
+        "ignore_function_time_stamp", "inferiorto",
+        "info_file", "info_program", "inline", "input",
+        "intmax", "intmin", "ipermute",
+        "is_absolute_filename", "isargout", "isbool",
+        "iscell", "iscellstr", "ischar", "iscomplex",
+        "isempty", "isfield", "isfloat", "isglobal",
+        "ishandle", "isieee", "isindex", "isinteger",
+        "islogical", "ismatrix", "ismethod", "isnull",
+        "isnumeric", "isobject", "isreal",
+        "is_rooted_relative_filename", "issorted",
+        "isstruct", "isvarname", "kbhit", "keyboard",
+        "kill", "lasterr", "lasterror", "lastwarn",
+        "ldivide", "le", "length", "link", "linspace",
+        "logical", "lstat", "lt", "make_absolute_filename",
+        "makeinfo_program", "max_recursion_depth", "merge",
+        "methods", "mfilename", "minus", "mislocked",
+        "mkdir", "mkfifo", "mkstemp", "mldivide", "mlock",
+        "mouse_wheel_zoom", "mpower", "mrdivide", "mtimes",
+        "munlock", "nargin", "nargout",
+        "native_float_format", "ndims", "ne", "nfields",
+        "nnz", "norm", "not", "numel", "nzmax",
+        "octave_config_info", "octave_core_file_limit",
+        "octave_core_file_name",
+        "octave_core_file_options", "ones", "or",
+        "output_max_field_width", "output_precision",
+        "page_output_immediately", "page_screen_output",
+        "path", "pathsep", "pause", "pclose", "permute",
+        "pi", "pipe", "plus", "popen", "power",
+        "print_empty_dimensions", "printf",
+        "print_struct_array_contents", "prod",
+        "program_invocation_name", "program_name",
+        "putenv", "puts", "pwd", "quit", "rats", "rdivide",
+        "readdir", "readlink", "read_readline_init_file",
+        "realmax", "realmin", "rehash", "rename",
+        "repelems", "re_read_readline_init_file", "reset",
+        "reshape", "resize", "restoredefaultpath",
+        "rethrow", "rmdir", "rmfield", "rmpath", "rows",
+        "save_header_format_string", "save_precision",
+        "saving_history", "scanf", "set", "setenv",
+        "shell_cmd", "sighup_dumps_octave_core",
+        "sigterm_dumps_octave_core", "silent_functions",
+        "single", "size", "size_equal", "sizemax",
+        "sizeof", "sleep", "source", "sparse_auto_mutate",
+        "split_long_rows", "sprintf", "squeeze", "sscanf",
+        "stat", "stderr", "stdin", "stdout", "strcmp",
+        "strcmpi", "string_fill_char", "strncmp",
+        "strncmpi", "struct", "struct_levels_to_print",
+        "strvcat", "subsasgn", "subsref", "sum", "sumsq",
+        "superiorto", "suppress_verbose_help_message",
+        "symlink", "system", "tic", "tilde_expand",
+        "times", "tmpfile", "tmpnam", "toc", "toupper",
+        "transpose", "true", "typeinfo", "umask", "uminus",
+        "uname", "undo_string_escapes", "unlink", "uplus",
+        "upper", "usage", "usleep", "vec", "vectorize",
+        "vertcat", "waitpid", "warning", "warranty",
+        "whos_line_format", "yes_or_no", "zeros",
+        "inf", "Inf", "nan", "NaN")
+
+    command_kw = ("close", "load", "who", "whos")
+
+    function_kw = (
+        "accumarray", "accumdim", "acosd", "acotd",
+        "acscd", "addtodate", "allchild", "ancestor",
+        "anova", "arch_fit", "arch_rnd", "arch_test",
+        "area", "arma_rnd", "arrayfun", "ascii", "asctime",
+        "asecd", "asind", "assert", "atand",
+        "autoreg_matrix", "autumn", "axes", "axis", "bar",
+        "barh", "bartlett", "bartlett_test", "beep",
+        "betacdf", "betainv", "betapdf", "betarnd",
+        "bicgstab", "bicubic", "binary", "binocdf",
+        "binoinv", "binopdf", "binornd", "bitcmp",
+        "bitget", "bitset", "blackman", "blanks",
+        "blkdiag", "bone", "box", "brighten", "calendar",
+        "cast", "cauchy_cdf", "cauchy_inv", "cauchy_pdf",
+        "cauchy_rnd", "caxis", "celldisp", "center", "cgs",
+        "chisquare_test_homogeneity",
+        "chisquare_test_independence", "circshift", "cla",
+        "clabel", "clf", "clock", "cloglog", "closereq",
+        "colon", "colorbar", "colormap", "colperm",
+        "comet", "common_size", "commutation_matrix",
+        "compan", "compare_versions", "compass",
+        "computer", "cond", "condest", "contour",
+        "contourc", "contourf", "contrast", "conv",
+        "convhull", "cool", "copper", "copyfile", "cor",
+        "corrcoef", "cor_test", "cosd", "cotd", "cov",
+        "cplxpair", "cross", "cscd", "cstrcat", "csvread",
+        "csvwrite", "ctime", "cumtrapz", "curl", "cut",
+        "cylinder", "date", "datenum", "datestr",
+        "datetick", "datevec", "dblquad", "deal",
+        "deblank", "deconv", "delaunay", "delaunayn",
+        "delete", "demo", "detrend", "diffpara", "diffuse",
+        "dir", "discrete_cdf", "discrete_inv",
+        "discrete_pdf", "discrete_rnd", "display",
+        "divergence", "dlmwrite", "dos", "dsearch",
+        "dsearchn", "duplication_matrix", "durbinlevinson",
+        "ellipsoid", "empirical_cdf", "empirical_inv",
+        "empirical_pdf", "empirical_rnd", "eomday",
+        "errorbar", "etime", "etreeplot", "example",
+        "expcdf", "expinv", "expm", "exppdf", "exprnd",
+        "ezcontour", "ezcontourf", "ezmesh", "ezmeshc",
+        "ezplot", "ezpolar", "ezsurf", "ezsurfc", "factor",
+        "factorial", "fail", "fcdf", "feather", "fftconv",
+        "fftfilt", "fftshift", "figure", "fileattrib",
+        "fileparts", "fill", "findall", "findobj",
+        "findstr", "finv", "flag", "flipdim", "fliplr",
+        "flipud", "fpdf", "fplot", "fractdiff", "freqz",
+        "freqz_plot", "frnd", "fsolve",
+        "f_test_regression", "ftp", "fullfile", "fzero",
+        "gamcdf", "gaminv", "gampdf", "gamrnd", "gca",
+        "gcbf", "gcbo", "gcf", "genvarname", "geocdf",
+        "geoinv", "geopdf", "geornd", "getfield", "ginput",
+        "glpk", "gls", "gplot", "gradient",
+        "graphics_toolkit", "gray", "grid", "griddata",
+        "griddatan", "gtext", "gunzip", "gzip", "hadamard",
+        "hamming", "hankel", "hanning", "hggroup",
+        "hidden", "hilb", "hist", "histc", "hold", "hot",
+        "hotelling_test", "housh", "hsv", "hurst",
+        "hygecdf", "hygeinv", "hygepdf", "hygernd",
+        "idivide", "ifftshift", "image", "imagesc",
+        "imfinfo", "imread", "imshow", "imwrite", "index",
+        "info", "inpolygon", "inputname", "interpft",
+        "interpn", "intersect", "invhilb", "iqr", "isa",
+        "isdefinite", "isdir", "is_duplicate_entry",
+        "isequal", "isequalwithequalnans", "isfigure",
+        "ishermitian", "ishghandle", "is_leap_year",
+        "isletter", "ismac", "ismember", "ispc", "isprime",
+        "isprop", "isscalar", "issquare", "isstrprop",
+        "issymmetric", "isunix", "is_valid_file_id",
+        "isvector", "jet", "kendall",
+        "kolmogorov_smirnov_cdf",
+        "kolmogorov_smirnov_test", "kruskal_wallis_test",
+        "krylov", "kurtosis", "laplace_cdf", "laplace_inv",
+        "laplace_pdf", "laplace_rnd", "legend", "legendre",
+        "license", "line", "linkprop", "list_primes",
+        "loadaudio", "loadobj", "logistic_cdf",
+        "logistic_inv", "logistic_pdf", "logistic_rnd",
+        "logit", "loglog", "loglogerr", "logm", "logncdf",
+        "logninv", "lognpdf", "lognrnd", "logspace",
+        "lookfor", "ls_command", "lsqnonneg", "magic",
+        "mahalanobis", "manova", "matlabroot",
+        "mcnemar_test", "mean", "meansq", "median", "menu",
+        "mesh", "meshc", "meshgrid", "meshz", "mexext",
+        "mget", "mkpp", "mode", "moment", "movefile",
+        "mpoles", "mput", "namelengthmax", "nargchk",
+        "nargoutchk", "nbincdf", "nbininv", "nbinpdf",
+        "nbinrnd", "nchoosek", "ndgrid", "newplot", "news",
+        "nonzeros", "normcdf", "normest", "norminv",
+        "normpdf", "normrnd", "now", "nthroot", "null",
+        "ocean", "ols", "onenormest", "optimget",
+        "optimset", "orderfields", "orient", "orth",
+        "pack", "pareto", "parseparams", "pascal", "patch",
+        "pathdef", "pcg", "pchip", "pcolor", "pcr",
+        "peaks", "periodogram", "perl", "perms", "pie",
+        "pink", "planerot", "playaudio", "plot",
+        "plotmatrix", "plotyy", "poisscdf", "poissinv",
+        "poisspdf", "poissrnd", "polar", "poly",
+        "polyaffine", "polyarea", "polyderiv", "polyfit",
+        "polygcd", "polyint", "polyout", "polyreduce",
+        "polyval", "polyvalm", "postpad", "powerset",
+        "ppder", "ppint", "ppjumps", "ppplot", "ppval",
+        "pqpnonneg", "prepad", "primes", "print",
+        "print_usage", "prism", "probit", "qp", "qqplot",
+        "quadcc", "quadgk", "quadl", "quadv", "quiver",
+        "qzhess", "rainbow", "randi", "range", "rank",
+        "ranks", "rat", "reallog", "realpow", "realsqrt",
+        "record", "rectangle_lw", "rectangle_sw",
+        "rectint", "refresh", "refreshdata",
+        "regexptranslate", "repmat", "residue", "ribbon",
+        "rindex", "roots", "rose", "rosser", "rotdim",
+        "rref", "run", "run_count", "rundemos", "run_test",
+        "runtests", "saveas", "saveaudio", "saveobj",
+        "savepath", "scatter", "secd", "semilogx",
+        "semilogxerr", "semilogy", "semilogyerr",
+        "setaudio", "setdiff", "setfield", "setxor",
+        "shading", "shift", "shiftdim", "sign_test",
+        "sinc", "sind", "sinetone", "sinewave", "skewness",
+        "slice", "sombrero", "sortrows", "spaugment",
+        "spconvert", "spdiags", "spearman", "spectral_adf",
+        "spectral_xdf", "specular", "speed", "spencer",
+        "speye", "spfun", "sphere", "spinmap", "spline",
+        "spones", "sprand", "sprandn", "sprandsym",
+        "spring", "spstats", "spy", "sqp", "stairs",
+        "statistics", "std", "stdnormal_cdf",
+        "stdnormal_inv", "stdnormal_pdf", "stdnormal_rnd",
+        "stem", "stft", "strcat", "strchr", "strjust",
+        "strmatch", "strread", "strsplit", "strtok",
+        "strtrim", "strtrunc", "structfun", "studentize",
+        "subplot", "subsindex", "subspace", "substr",
+        "substruct", "summer", "surf", "surface", "surfc",
+        "surfl", "surfnorm", "svds", "swapbytes",
+        "sylvester_matrix", "symvar", "synthesis", "table",
+        "tand", "tar", "tcdf", "tempdir", "tempname",
+        "test", "text", "textread", "textscan", "tinv",
+        "title", "toeplitz", "tpdf", "trace", "trapz",
+        "treelayout", "treeplot", "triangle_lw",
+        "triangle_sw", "tril", "trimesh", "triplequad",
+        "triplot", "trisurf", "triu", "trnd", "tsearchn",
+        "t_test", "t_test_regression", "type", "unidcdf",
+        "unidinv", "unidpdf", "unidrnd", "unifcdf",
+        "unifinv", "unifpdf", "unifrnd", "union", "unique",
+        "unix", "unmkpp", "unpack", "untabify", "untar",
+        "unwrap", "unzip", "u_test", "validatestring",
+        "vander", "var", "var_test", "vech", "ver",
+        "version", "view", "voronoi", "voronoin",
+        "waitforbuttonpress", "wavread", "wavwrite",
+        "wblcdf", "wblinv", "wblpdf", "wblrnd", "weekday",
+        "welch_test", "what", "white", "whitebg",
+        "wienrnd", "wilcoxon_test", "wilkinson", "winter",
+        "xlabel", "xlim", "ylabel", "yulewalker", "zip",
+        "zlabel", "z_test")
+
+    loadable_kw = (
+        "airy", "amd", "balance", "besselh", "besseli",
+        "besselj", "besselk", "bessely", "bitpack",
+        "bsxfun", "builtin", "ccolamd", "cellfun",
+        "cellslices", "chol", "choldelete", "cholinsert",
+        "cholinv", "cholshift", "cholupdate", "colamd",
+        "colloc", "convhulln", "convn", "csymamd",
+        "cummax", "cummin", "daspk", "daspk_options",
+        "dasrt", "dasrt_options", "dassl", "dassl_options",
+        "dbclear", "dbdown", "dbstack", "dbstatus",
+        "dbstop", "dbtype", "dbup", "dbwhere", "det",
+        "dlmread", "dmperm", "dot", "eig", "eigs",
+        "endgrent", "endpwent", "etree", "fft", "fftn",
+        "fftw", "filter", "find", "full", "gcd",
+        "getgrent", "getgrgid", "getgrnam", "getpwent",
+        "getpwnam", "getpwuid", "getrusage", "givens",
+        "gmtime", "gnuplot_binary", "hess", "ifft",
+        "ifftn", "inv", "isdebugmode", "issparse", "kron",
+        "localtime", "lookup", "lsode", "lsode_options",
+        "lu", "luinc", "luupdate", "matrix_type", "max",
+        "min", "mktime", "pinv", "qr", "qrdelete",
+        "qrinsert", "qrshift", "qrupdate", "quad",
+        "quad_options", "qz", "rand", "rande", "randg",
+        "randn", "randp", "randperm", "rcond", "regexp",
+        "regexpi", "regexprep", "schur", "setgrent",
+        "setpwent", "sort", "spalloc", "sparse", "spparms",
+        "sprank", "sqrtm", "strfind", "strftime",
+        "strptime", "strrep", "svd", "svd_driver", "syl",
+        "symamd", "symbfact", "symrcm", "time", "tsearch",
+        "typecast", "urlread", "urlwrite")
+
+    mapping_kw = (
+        "abs", "acos", "acosh", "acot", "acoth", "acsc",
+        "acsch", "angle", "arg", "asec", "asech", "asin",
+        "asinh", "atan", "atanh", "beta", "betainc",
+        "betaln", "bincoeff", "cbrt", "ceil", "conj", "cos",
+        "cosh", "cot", "coth", "csc", "csch", "erf", "erfc",
+        "erfcx", "erfinv", "exp", "finite", "fix", "floor",
+        "fmod", "gamma", "gammainc", "gammaln", "imag",
+        "isalnum", "isalpha", "isascii", "iscntrl",
+        "isdigit", "isfinite", "isgraph", "isinf",
+        "islower", "isna", "isnan", "isprint", "ispunct",
+        "isspace", "isupper", "isxdigit", "lcm", "lgamma",
+        "log", "lower", "mod", "real", "rem", "round",
+        "roundb", "sec", "sech", "sign", "sin", "sinh",
+        "sqrt", "tan", "tanh", "toascii", "tolower", "xor")
+
+    builtin_consts = (
+        "EDITOR", "EXEC_PATH", "I", "IMAGE_PATH", "NA",
+        "OCTAVE_HOME", "OCTAVE_VERSION", "PAGER",
+        "PAGER_FLAGS", "SEEK_CUR", "SEEK_END", "SEEK_SET",
+        "SIG", "S_ISBLK", "S_ISCHR", "S_ISDIR", "S_ISFIFO",
+        "S_ISLNK", "S_ISREG", "S_ISSOCK", "WCONTINUE",
+        "WCOREDUMP", "WEXITSTATUS", "WIFCONTINUED",
+        "WIFEXITED", "WIFSIGNALED", "WIFSTOPPED", "WNOHANG",
+        "WSTOPSIG", "WTERMSIG", "WUNTRACED")
+
+    tokens = {
+        'root': [
+            (r'%\{\s*\n', Comment.Multiline, 'percentblockcomment'),
+            (r'#\{\s*\n', Comment.Multiline, 'hashblockcomment'),
+            (r'[%#].*$', Comment),
+            (r'^\s*function\b', Keyword, 'deffunc'),
+
+            # from 'iskeyword' on hg changeset 8cc154f45e37
+            (words((
+                '__FILE__', '__LINE__', 'break', 'case', 'catch', 'classdef',
+                'continue', 'do', 'else', 'elseif', 'end', 'end_try_catch',
+                'end_unwind_protect', 'endclassdef', 'endevents', 'endfor',
+                'endfunction', 'endif', 'endmethods', 'endproperties', 'endswitch',
+                'endwhile', 'events', 'for', 'function', 'get', 'global', 'if',
+                'methods', 'otherwise', 'persistent', 'properties', 'return',
+                'set', 'static', 'switch', 'try', 'until', 'unwind_protect',
+                'unwind_protect_cleanup', 'while'), suffix=r'\b'),
+             Keyword),
+
+            (words(builtin_kw + command_kw + function_kw + loadable_kw + mapping_kw,
+                   suffix=r'\b'),  Name.Builtin),
+
+            (words(builtin_consts, suffix=r'\b'), Name.Constant),
+
+            # operators in Octave but not Matlab:
+            (r'-=|!=|!|/=|--', Operator),
+            # operators:
+            (r'-|==|~=|<|>|<=|>=|&&|&|~|\|\|?', Operator),
+            # operators in Octave but not Matlab requiring escape for re:
+            (r'\*=|\+=|\^=|\/=|\\=|\*\*|\+\+|\.\*\*', Operator),
+            # operators requiring escape for re:
+            (r'\.\*|\*|\+|\.\^|\^|\.\\|\.\/|\/|\\', Operator),
+
+
+            # punctuation:
+            (r'[\[\](){}:@.,]', Punctuation),
+            (r'=|:|;', Punctuation),
+
+            (r'"[^"]*"', String),
+
+            (r'(\d+\.\d*|\d*\.\d+)([eEf][+-]?[0-9]+)?', Number.Float),
+            (r'\d+[eEf][+-]?[0-9]+', Number.Float),
+            (r'\d+', Number.Integer),
+
+            # quote can be transpose, instead of string:
+            # (not great, but handles common cases...)
+            (r'(?<=[\w)\].])\'+', Operator),
+            (r'(?|<=|>=|&&|&|~|\|\|?', Operator),
+            # operators requiring escape for re:
+            (r'\.\*|\*|\+|\.\^|\^|\.\\|\.\/|\/|\\', Operator),
+
+            # punctuation:
+            (r'[\[\](){}@.,=:;]+', Punctuation),
+
+            (r'"[^"]*"', String),
+
+            # quote can be transpose, instead of string:
+            # (not great, but handles common cases...)
+            (r'(?<=[\w)\].])\'+', Operator),
+            (r'(?', r'<', r'|', r'!', r"'")
+
+    operator_words = ('and', 'or', 'not')
+
+    tokens = {
+        'root': [
+            (r'/\*', Comment.Multiline, 'comment'),
+            (r'"(?:[^"\\]|\\.)*"', String),
+            (r'\(|\)|\[|\]|\{|\}', Punctuation),
+            (r'[,;$]', Punctuation),
+            (words (constants), Name.Constant),
+            (words (keywords), Keyword),
+            (words (operators), Operator),
+            (words (operator_words), Operator.Word),
+            (r'''(?x)
+              ((?:[a-zA-Z_#][\w#]*|`[^`]*`)
+              (?:::[a-zA-Z_#][\w#]*|`[^`]*`)*)(\s*)([(])''',
+             bygroups(Name.Function, Text.Whitespace, Punctuation)),
+            (r'''(?x)
+              (?:[a-zA-Z_#%][\w#%]*|`[^`]*`)
+              (?:::[a-zA-Z_#%][\w#%]*|`[^`]*`)*''', Name.Variable),
+            (r'[-+]?(\d*\.\d+([bdefls][-+]?\d+)?|\d+(\.\d*)?[bdefls][-+]?\d+)', Number.Float),
+            (r'[-+]?\d+', Number.Integer),
+            (r'\s+', Text.Whitespace),
+            (r'.', Text)
+        ],
+        'comment': [
+            (r'[^*/]+', Comment.Multiline),
+            (r'/\*', Comment.Multiline, '#push'),
+            (r'\*/', Comment.Multiline, '#pop'),
+            (r'[*/]', Comment.Multiline)
+        ]
+    }
+
+    def analyse_text (text):
+        strength = 0.0
+        # Input expression terminator.
+        if re.search (r'\$\s*$', text, re.MULTILINE):
+            strength += 0.05
+        # Function definition operator.
+        if ':=' in text:
+            strength += 0.02
+        return strength
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/meson.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/meson.py
new file mode 100644
index 0000000000000000000000000000000000000000..154a2de5a154a139e337d04a62d990b694bb5379
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/meson.py
@@ -0,0 +1,139 @@
+"""
+    pygments.lexers.meson
+    ~~~~~~~~~~~~~~~~~~~~~
+
+    Pygments lexer for the Meson build system
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, words, include
+from pygments.token import Comment, Name, Number, Punctuation, Operator, \
+    Keyword, String, Whitespace
+
+__all__ = ['MesonLexer']
+
+
+class MesonLexer(RegexLexer):
+    """Meson language lexer.
+
+    The grammar definition use to transcribe the syntax was retrieved from
+    https://mesonbuild.com/Syntax.html#grammar for version 0.58.
+    Some of those definitions are improperly transcribed, so the Meson++
+    implementation was also checked: https://github.com/dcbaker/meson-plus-plus.
+    """
+
+    # TODO String interpolation @VARNAME@ inner matches
+    # TODO keyword_arg: value inner matches
+
+    name = 'Meson'
+    url = 'https://mesonbuild.com/'
+    aliases = ['meson', 'meson.build']
+    filenames = ['meson.build', 'meson.options', 'meson_options.txt']
+    mimetypes = ['text/x-meson']
+    version_added = '2.10'
+
+    tokens = {
+        'root': [
+            (r'#.*?$', Comment),
+            (r"'''.*'''", String.Single),
+            (r'[1-9][0-9]*', Number.Integer),
+            (r'0o[0-7]+', Number.Oct),
+            (r'0x[a-fA-F0-9]+', Number.Hex),
+            include('string'),
+            include('keywords'),
+            include('expr'),
+            (r'[a-zA-Z_][a-zA-Z_0-9]*', Name),
+            (r'\s+', Whitespace),
+        ],
+        'string': [
+            (r"[']{3}([']{0,2}([^\\']|\\(.|\n)))*[']{3}", String),
+            (r"'.*?(?`_.
+    """
+
+    name = "MCFunction"
+    url = "https://minecraft.wiki/w/Commands"
+    aliases = ["mcfunction", "mcf"]
+    filenames = ["*.mcfunction"]
+    mimetypes = ["text/mcfunction"]
+    version_added = '2.12'
+
+    # Used to denotate the start of a block comment, borrowed from Github's mcfunction
+    _block_comment_prefix = "[>!]"
+
+    tokens = {
+        "root": [
+            include("names"),
+            include("comments"),
+            include("literals"),
+            include("whitespace"),
+            include("property"),
+            include("operators"),
+            include("selectors"),
+        ],
+
+        "names": [
+            # The start of a command (either beginning of line OR after the run keyword)
+            #  We don't encode a list of keywords since mods, plugins, or even pre-processors
+            #  may add new commands, so we have a 'close-enough' regex which catches them.
+            (r"^(\s*)([a-z_]+)", bygroups(Whitespace, Name.Builtin)),
+            (r"(?<=run)\s+[a-z_]+", Name.Builtin),
+
+            # UUID
+            (r"\b[0-9a-fA-F]+(?:-[0-9a-fA-F]+){4}\b", Name.Variable),
+            include("resource-name"),
+            # normal command names and scoreboards
+            #  there's no way to know the differences unfortuntely
+            (r"[A-Za-z_][\w.#%$]+", Keyword.Constant),
+            (r"[#%$][\w.#%$]+", Name.Variable.Magic),
+        ],
+
+        "resource-name": [
+            # resource names have to be lowercase
+            (r"#?[a-z_][a-z_.-]*:[a-z0-9_./-]+", Name.Function),
+            # similar to above except optional `:``
+            #  a `/` must be present "somewhere"
+            (r"#?[a-z0-9_\.\-]+\/[a-z0-9_\.\-\/]+", Name.Function),
+        ],
+
+        "whitespace": [
+            (r"\s+", Whitespace),
+        ],
+
+        "comments": [
+            (rf"^\s*(#{_block_comment_prefix})", Comment.Multiline,
+             ("comments.block", "comments.block.emphasized")),
+            (r"#.*$", Comment.Single),
+        ],
+        "comments.block": [
+            (rf"^\s*#{_block_comment_prefix}", Comment.Multiline,
+             "comments.block.emphasized"),
+            (r"^\s*#", Comment.Multiline, "comments.block.normal"),
+            default("#pop"),
+        ],
+        "comments.block.normal": [
+            include("comments.block.special"),
+            (r"\S+", Comment.Multiline),
+            (r"\n", Text, "#pop"),
+            include("whitespace"),
+        ],
+        "comments.block.emphasized": [
+            include("comments.block.special"),
+            (r"\S+", String.Doc),
+            (r"\n", Text, "#pop"),
+            include("whitespace"),
+        ],
+        "comments.block.special": [
+            # Params
+            (r"@\S+", Name.Decorator),
+
+            include("resource-name"),
+
+            # Scoreboard player names
+            (r"[#%$][\w.#%$]+", Name.Variable.Magic),
+        ],
+
+        "operators": [
+            (r"[\-~%^?!+*<>\\/|&=.]", Operator),
+        ],
+
+        "literals": [
+            (r"\.\.", Literal),
+            (r"(true|false)", Keyword.Pseudo),
+
+            # these are like unquoted strings and appear in many places
+            (r"[A-Za-z_]+", Name.Variable.Class),
+
+            (r"[0-7]b", Number.Byte),
+            (r"[+-]?\d*\.?\d+([eE]?[+-]?\d+)?[df]?\b", Number.Float),
+            (r"[+-]?\d+\b", Number.Integer),
+            (r'"', String.Double, "literals.string-double"),
+            (r"'", String.Single, "literals.string-single"),
+        ],
+        "literals.string-double": [
+            (r"\\.", String.Escape),
+            (r'[^\\"\n]+', String.Double),
+            (r'"', String.Double, "#pop"),
+        ],
+        "literals.string-single": [
+            (r"\\.", String.Escape),
+            (r"[^\\'\n]+", String.Single),
+            (r"'", String.Single, "#pop"),
+        ],
+
+        "selectors": [
+            (r"@[a-z]", Name.Variable),
+        ],
+
+
+        ## Generic Property Container
+        # There are several, differing instances where the language accepts
+        #  specific contained keys or contained key, value pairings.
+        #
+        # Property Maps:
+        # - Starts with either `[` or `{`
+        # - Key separated by `:` or `=`
+        # - Deliminated by `,`
+        #
+        # Property Lists:
+        # - Starts with `[`
+        # - Deliminated by `,`
+        #
+        # For simplicity, these patterns match a generic, nestable structure
+        #  which follow a key, value pattern. For normal lists, there's only keys.
+        # This allow some "illegal" structures, but we'll accept those for
+        #  sake of simplicity
+        #
+        # Examples:
+        # - `[facing=up, powered=true]` (blockstate)
+        # - `[name="hello world", nbt={key: 1b}]` (selector + nbt)
+        # - `[{"text": "value"}, "literal"]` (json)
+        ##
+        "property": [
+            # This state gets included in root and also several substates
+            # We do this to shortcut the starting of new properties
+            #  within other properties. Lists can have sublists and compounds
+            #  and values can start a new property (see the `difficult_1.txt`
+            #  snippet).
+            (r"\{", Punctuation, ("property.curly", "property.key")),
+            (r"\[", Punctuation, ("property.square", "property.key")),
+        ],
+        "property.curly": [
+            include("whitespace"),
+            include("property"),
+            (r"\}", Punctuation, "#pop"),
+        ],
+        "property.square": [
+            include("whitespace"),
+            include("property"),
+            (r"\]", Punctuation, "#pop"),
+
+            # lists can have sequences of items
+            (r",", Punctuation),
+        ],
+        "property.key": [
+            include("whitespace"),
+
+            # resource names (for advancements)
+            #  can omit `:` to default `minecraft:`
+            # must check if there is a future equals sign if `:` is in the name
+            (r"#?[a-z_][a-z_\.\-]*\:[a-z0-9_\.\-/]+(?=\s*\=)", Name.Attribute, "property.delimiter"),
+            (r"#?[a-z_][a-z0-9_\.\-/]+", Name.Attribute, "property.delimiter"),
+
+            # unquoted NBT key
+            (r"[A-Za-z_\-\+]+", Name.Attribute, "property.delimiter"),
+
+            # quoted JSON or NBT key
+            (r'"', Name.Attribute, "property.delimiter", "literals.string-double"),
+            (r"'", Name.Attribute, "property.delimiter", "literals.string-single"),
+
+            # index for a list
+            (r"-?\d+", Number.Integer, "property.delimiter"),
+
+            default("#pop"),
+        ],
+        "property.key.string-double": [
+            (r"\\.", String.Escape),
+            (r'[^\\"\n]+', Name.Attribute),
+            (r'"', Name.Attribute, "#pop"),
+        ],
+        "property.key.string-single": [
+            (r"\\.", String.Escape),
+            (r"[^\\'\n]+", Name.Attribute),
+            (r"'", Name.Attribute, "#pop"),
+        ],
+        "property.delimiter": [
+            include("whitespace"),
+
+            (r"[:=]!?", Punctuation, "property.value"),
+            (r",", Punctuation),
+
+            default("#pop"),
+        ],
+        "property.value": [
+            include("whitespace"),
+
+            # unquoted resource names are valid literals here
+            (r"#?[a-z_][a-z_\.\-]*\:[a-z0-9_\.\-/]+", Name.Tag),
+            (r"#?[a-z_][a-z0-9_\.\-/]+", Name.Tag),
+
+            include("literals"),
+            include("property"),
+
+            default("#pop"),
+        ],
+    }
+
+
+class MCSchemaLexer(RegexLexer):
+    """Lexer for Minecraft Add-ons data Schemas, an interface structure standard used in Minecraft
+    """
+
+    name = 'MCSchema'
+    url = 'https://learn.microsoft.com/en-us/minecraft/creator/reference/content/schemasreference/'
+    aliases = ['mcschema']
+    filenames = ['*.mcschema']
+    mimetypes = ['text/mcschema']
+    version_added = '2.14'
+
+    tokens = {
+        'commentsandwhitespace': [
+            (r'\s+', Whitespace),
+            (r'//.*?$', Comment.Single),
+            (r'/\*.*?\*/', Comment.Multiline)
+        ],
+        'slashstartsregex': [
+            include('commentsandwhitespace'),
+            (r'/(\\.|[^[/\\\n]|\[(\\.|[^\]\\\n])*])+/'
+             r'([gimuysd]+\b|\B)', String.Regex, '#pop'),
+            (r'(?=/)', Text, ('#pop', 'badregex')),
+            default('#pop')
+        ],
+        'badregex': [
+            (r'\n', Whitespace, '#pop')
+        ],
+        'singlestring': [
+            (r'\\.', String.Escape),
+            (r"'", String.Single, '#pop'),
+            (r"[^\\']+", String.Single),
+        ],
+        'doublestring': [
+            (r'\\.', String.Escape),
+            (r'"', String.Double, '#pop'),
+            (r'[^\\"]+', String.Double),
+        ],
+        'root': [
+            (r'^(?=\s|/|', Comment, '#pop'),
+            (r'[^\-]+|-', Comment),
+        ],
+    }
+
+
+class ReasonLexer(RegexLexer):
+    """
+    For the ReasonML language.
+    """
+
+    name = 'ReasonML'
+    url = 'https://reasonml.github.io/'
+    aliases = ['reasonml', 'reason']
+    filenames = ['*.re', '*.rei']
+    mimetypes = ['text/x-reasonml']
+    version_added = '2.6'
+
+    keywords = (
+        'as', 'assert', 'begin', 'class', 'constraint', 'do', 'done', 'downto',
+        'else', 'end', 'exception', 'external', 'false', 'for', 'fun', 'esfun',
+        'function', 'functor', 'if', 'in', 'include', 'inherit', 'initializer', 'lazy',
+        'let', 'switch', 'module', 'pub', 'mutable', 'new', 'nonrec', 'object', 'of',
+        'open', 'pri', 'rec', 'sig', 'struct', 'then', 'to', 'true', 'try',
+        'type', 'val', 'virtual', 'when', 'while', 'with',
+    )
+    keyopts = (
+        '!=', '#', '&', '&&', r'\(', r'\)', r'\*', r'\+', ',', '-',
+        r'-\.', '=>', r'\.', r'\.\.', r'\.\.\.', ':', '::', ':=', ':>', ';', ';;', '<',
+        '<-', '=', '>', '>]', r'>\}', r'\?', r'\?\?', r'\[', r'\[<', r'\[>',
+        r'\[\|', ']', '_', '`', r'\{', r'\{<', r'\|', r'\|\|', r'\|]', r'\}', '~'
+    )
+
+    operators = r'[!$%&*+\./:<=>?@^|~-]'
+    word_operators = ('and', 'asr', 'land', 'lor', 'lsl', 'lsr', 'lxor', 'mod', 'or')
+    prefix_syms = r'[!?~]'
+    infix_syms = r'[=<>@^|&+\*/$%-]'
+    primitives = ('unit', 'int', 'float', 'bool', 'string', 'char', 'list', 'array')
+
+    tokens = {
+        'escape-sequence': [
+            (r'\\[\\"\'ntbr]', String.Escape),
+            (r'\\[0-9]{3}', String.Escape),
+            (r'\\x[0-9a-fA-F]{2}', String.Escape),
+        ],
+        'root': [
+            (r'\s+', Text),
+            (r'false|true|\(\)|\[\]', Name.Builtin.Pseudo),
+            (r'\b([A-Z][\w\']*)(?=\s*\.)', Name.Namespace, 'dotted'),
+            (r'\b([A-Z][\w\']*)', Name.Class),
+            (r'//.*?\n', Comment.Single),
+            (r'\/\*(?!/)', Comment.Multiline, 'comment'),
+            (r'\b({})\b'.format('|'.join(keywords)), Keyword),
+            (r'({})'.format('|'.join(keyopts[::-1])), Operator.Word),
+            (rf'({infix_syms}|{prefix_syms})?{operators}', Operator),
+            (r'\b({})\b'.format('|'.join(word_operators)), Operator.Word),
+            (r'\b({})\b'.format('|'.join(primitives)), Keyword.Type),
+
+            (r"[^\W\d][\w']*", Name),
+
+            (r'-?\d[\d_]*(.[\d_]*)?([eE][+\-]?\d[\d_]*)', Number.Float),
+            (r'0[xX][\da-fA-F][\da-fA-F_]*', Number.Hex),
+            (r'0[oO][0-7][0-7_]*', Number.Oct),
+            (r'0[bB][01][01_]*', Number.Bin),
+            (r'\d[\d_]*', Number.Integer),
+
+            (r"'(?:(\\[\\\"'ntbr ])|(\\[0-9]{3})|(\\x[0-9a-fA-F]{2}))'",
+             String.Char),
+            (r"'.'", String.Char),
+            (r"'", Keyword),
+
+            (r'"', String.Double, 'string'),
+
+            (r'[~?][a-z][\w\']*:', Name.Variable),
+        ],
+        'comment': [
+            (r'[^/*]+', Comment.Multiline),
+            (r'\/\*', Comment.Multiline, '#push'),
+            (r'\*\/', Comment.Multiline, '#pop'),
+            (r'\*', Comment.Multiline),
+        ],
+        'string': [
+            (r'[^\\"]+', String.Double),
+            include('escape-sequence'),
+            (r'\\\n', String.Double),
+            (r'"', String.Double, '#pop'),
+        ],
+        'dotted': [
+            (r'\s+', Text),
+            (r'\.', Punctuation),
+            (r'[A-Z][\w\']*(?=\s*\.)', Name.Namespace),
+            (r'[A-Z][\w\']*', Name.Class, '#pop'),
+            (r'[a-z_][\w\']*', Name, '#pop'),
+            default('#pop'),
+        ],
+    }
+
+
+class FStarLexer(RegexLexer):
+    """
+    For the F* language.
+    """
+
+    name = 'FStar'
+    url = 'https://www.fstar-lang.org/'
+    aliases = ['fstar']
+    filenames = ['*.fst', '*.fsti']
+    mimetypes = ['text/x-fstar']
+    version_added = '2.7'
+
+    keywords = (
+        'abstract', 'attributes', 'noeq', 'unopteq', 'and'
+        'begin', 'by', 'default', 'effect', 'else', 'end', 'ensures',
+        'exception', 'exists', 'false', 'forall', 'fun', 'function', 'if',
+        'in', 'include', 'inline', 'inline_for_extraction', 'irreducible',
+        'logic', 'match', 'module', 'mutable', 'new', 'new_effect', 'noextract',
+        'of', 'open', 'opaque', 'private', 'range_of', 'reifiable',
+        'reify', 'reflectable', 'requires', 'set_range_of', 'sub_effect',
+        'synth', 'then', 'total', 'true', 'try', 'type', 'unfold', 'unfoldable',
+        'val', 'when', 'with', 'not'
+    )
+    decl_keywords = ('let', 'rec')
+    assume_keywords = ('assume', 'admit', 'assert', 'calc')
+    keyopts = (
+        r'~', r'-', r'/\\', r'\\/', r'<:', r'<@', r'\(\|', r'\|\)', r'#', r'u#',
+        r'&', r'\(', r'\)', r'\(\)', r',', r'~>', r'->', r'<-', r'<--', r'<==>',
+        r'==>', r'\.', r'\?', r'\?\.', r'\.\[', r'\.\(', r'\.\(\|', r'\.\[\|',
+        r'\{:pattern', r':', r'::', r':=', r';', r';;', r'=', r'%\[', r'!\{',
+        r'\[', r'\[@', r'\[\|', r'\|>', r'\]', r'\|\]', r'\{', r'\|', r'\}', r'\$'
+    )
+
+    operators = r'[!$%&*+\./:<=>?@^|~-]'
+    prefix_syms = r'[!?~]'
+    infix_syms = r'[=<>@^|&+\*/$%-]'
+    primitives = ('unit', 'int', 'float', 'bool', 'string', 'char', 'list', 'array')
+
+    tokens = {
+        'escape-sequence': [
+            (r'\\[\\"\'ntbr]', String.Escape),
+            (r'\\[0-9]{3}', String.Escape),
+            (r'\\x[0-9a-fA-F]{2}', String.Escape),
+        ],
+        'root': [
+            (r'\s+', Text),
+            (r'false|true|False|True|\(\)|\[\]', Name.Builtin.Pseudo),
+            (r'\b([A-Z][\w\']*)(?=\s*\.)', Name.Namespace, 'dotted'),
+            (r'\b([A-Z][\w\']*)', Name.Class),
+            (r'\(\*(?![)])', Comment, 'comment'),
+            (r'\/\/.+$', Comment),
+            (r'\b({})\b'.format('|'.join(keywords)), Keyword),
+            (r'\b({})\b'.format('|'.join(assume_keywords)), Name.Exception),
+            (r'\b({})\b'.format('|'.join(decl_keywords)), Keyword.Declaration),
+            (r'({})'.format('|'.join(keyopts[::-1])), Operator),
+            (rf'({infix_syms}|{prefix_syms})?{operators}', Operator),
+            (r'\b({})\b'.format('|'.join(primitives)), Keyword.Type),
+
+            (r"[^\W\d][\w']*", Name),
+
+            (r'-?\d[\d_]*(.[\d_]*)?([eE][+\-]?\d[\d_]*)', Number.Float),
+            (r'0[xX][\da-fA-F][\da-fA-F_]*', Number.Hex),
+            (r'0[oO][0-7][0-7_]*', Number.Oct),
+            (r'0[bB][01][01_]*', Number.Bin),
+            (r'\d[\d_]*', Number.Integer),
+
+            (r"'(?:(\\[\\\"'ntbr ])|(\\[0-9]{3})|(\\x[0-9a-fA-F]{2}))'",
+             String.Char),
+            (r"'.'", String.Char),
+            (r"'", Keyword),  # a stray quote is another syntax element
+            (r"\`([\w\'.]+)\`", Operator.Word),  # for infix applications
+            (r"\`", Keyword),  # for quoting
+            (r'"', String.Double, 'string'),
+
+            (r'[~?][a-z][\w\']*:', Name.Variable),
+        ],
+        'comment': [
+            (r'[^(*)]+', Comment),
+            (r'\(\*', Comment, '#push'),
+            (r'\*\)', Comment, '#pop'),
+            (r'[(*)]', Comment),
+        ],
+        'string': [
+            (r'[^\\"]+', String.Double),
+            include('escape-sequence'),
+            (r'\\\n', String.Double),
+            (r'"', String.Double, '#pop'),
+        ],
+        'dotted': [
+            (r'\s+', Text),
+            (r'\.', Punctuation),
+            (r'[A-Z][\w\']*(?=\s*\.)', Name.Namespace),
+            (r'[A-Z][\w\']*', Name.Class, '#pop'),
+            (r'[a-z_][\w\']*', Name, '#pop'),
+            default('#pop'),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/modeling.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/modeling.py
new file mode 100644
index 0000000000000000000000000000000000000000..4c22aeb0043a31b6231fb031134b12cafe1024fc
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/modeling.py
@@ -0,0 +1,368 @@
+"""
+    pygments.lexers.modeling
+    ~~~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for modeling languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, include, bygroups, using, default
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation, Whitespace
+
+from pygments.lexers.html import HtmlLexer
+from pygments.lexers import _stan_builtins
+
+__all__ = ['ModelicaLexer', 'BugsLexer', 'JagsLexer', 'StanLexer']
+
+
+class ModelicaLexer(RegexLexer):
+    """
+    For Modelica source code.
+    """
+    name = 'Modelica'
+    url = 'http://www.modelica.org/'
+    aliases = ['modelica']
+    filenames = ['*.mo']
+    mimetypes = ['text/x-modelica']
+    version_added = '1.1'
+
+    flags = re.DOTALL | re.MULTILINE
+
+    _name = r"(?:'(?:[^\\']|\\.)+'|[a-zA-Z_]\w*)"
+
+    tokens = {
+        'whitespace': [
+            (r'[\s\ufeff]+', Text),
+            (r'//[^\n]*\n?', Comment.Single),
+            (r'/\*.*?\*/', Comment.Multiline)
+        ],
+        'root': [
+            include('whitespace'),
+            (r'"', String.Double, 'string'),
+            (r'[()\[\]{},;]+', Punctuation),
+            (r'\.?[*^/+-]|\.|<>|[<>:=]=?', Operator),
+            (r'\d+(\.?\d*[eE][-+]?\d+|\.\d*)', Number.Float),
+            (r'\d+', Number.Integer),
+            (r'(abs|acos|actualStream|array|asin|assert|AssertionLevel|atan|'
+             r'atan2|backSample|Boolean|cardinality|cat|ceil|change|Clock|'
+             r'Connections|cos|cosh|cross|delay|diagonal|div|edge|exp|'
+             r'ExternalObject|fill|floor|getInstanceName|hold|homotopy|'
+             r'identity|inStream|integer|Integer|interval|inverse|isPresent|'
+             r'linspace|log|log10|matrix|max|min|mod|ndims|noClock|noEvent|'
+             r'ones|outerProduct|pre|previous|product|Real|reinit|rem|rooted|'
+             r'sample|scalar|semiLinear|shiftSample|sign|sin|sinh|size|skew|'
+             r'smooth|spatialDistribution|sqrt|StateSelect|String|subSample|'
+             r'sum|superSample|symmetric|tan|tanh|terminal|terminate|time|'
+             r'transpose|vector|zeros)\b', Name.Builtin),
+            (r'(algorithm|annotation|break|connect|constant|constrainedby|der|'
+             r'discrete|each|else|elseif|elsewhen|encapsulated|enumeration|'
+             r'equation|exit|expandable|extends|external|firstTick|final|flow|for|if|'
+             r'import|impure|in|initial|inner|input|interval|loop|nondiscrete|outer|'
+             r'output|parameter|partial|protected|public|pure|redeclare|'
+             r'replaceable|return|stream|then|when|while)\b',
+             Keyword.Reserved),
+            (r'(and|not|or)\b', Operator.Word),
+            (r'(block|class|connector|end|function|model|operator|package|'
+             r'record|type)\b', Keyword.Reserved, 'class'),
+            (r'(false|true)\b', Keyword.Constant),
+            (r'within\b', Keyword.Reserved, 'package-prefix'),
+            (_name, Name)
+        ],
+        'class': [
+            include('whitespace'),
+            (r'(function|record)\b', Keyword.Reserved),
+            (r'(if|for|when|while)\b', Keyword.Reserved, '#pop'),
+            (_name, Name.Class, '#pop'),
+            default('#pop')
+        ],
+        'package-prefix': [
+            include('whitespace'),
+            (_name, Name.Namespace, '#pop'),
+            default('#pop')
+        ],
+        'string': [
+            (r'"', String.Double, '#pop'),
+            (r'\\[\'"?\\abfnrtv]', String.Escape),
+            (r'(?i)<\s*html\s*>([^\\"]|\\.)+?(<\s*/\s*html\s*>|(?="))',
+             using(HtmlLexer)),
+            (r'<|\\?[^"\\<]+', String.Double)
+        ]
+    }
+
+
+class BugsLexer(RegexLexer):
+    """
+    Pygments Lexer for OpenBugs and WinBugs
+    models.
+    """
+
+    name = 'BUGS'
+    aliases = ['bugs', 'winbugs', 'openbugs']
+    filenames = ['*.bug']
+    url = 'https://www.mrc-bsu.cam.ac.uk/software/bugs/openbugs'
+    version_added = '1.6'
+
+    _FUNCTIONS = (
+        # Scalar functions
+        'abs', 'arccos', 'arccosh', 'arcsin', 'arcsinh', 'arctan', 'arctanh',
+        'cloglog', 'cos', 'cosh', 'cumulative', 'cut', 'density', 'deviance',
+        'equals', 'expr', 'gammap', 'ilogit', 'icloglog', 'integral', 'log',
+        'logfact', 'loggam', 'logit', 'max', 'min', 'phi', 'post.p.value',
+        'pow', 'prior.p.value', 'probit', 'replicate.post', 'replicate.prior',
+        'round', 'sin', 'sinh', 'solution', 'sqrt', 'step', 'tan', 'tanh',
+        'trunc',
+        # Vector functions
+        'inprod', 'interp.lin', 'inverse', 'logdet', 'mean', 'eigen.vals',
+        'ode', 'prod', 'p.valueM', 'rank', 'ranked', 'replicate.postM',
+        'sd', 'sort', 'sum',
+        # Special
+        'D', 'I', 'F', 'T', 'C')
+    """ OpenBUGS built-in functions
+
+    From http://www.openbugs.info/Manuals/ModelSpecification.html#ContentsAII
+
+    This also includes
+
+    - T, C, I : Truncation and censoring.
+      ``T`` and ``C`` are in OpenBUGS. ``I`` in WinBUGS.
+    - D : ODE
+    - F : Functional http://www.openbugs.info/Examples/Functionals.html
+
+    """
+
+    _DISTRIBUTIONS = ('dbern', 'dbin', 'dcat', 'dnegbin', 'dpois',
+                      'dhyper', 'dbeta', 'dchisqr', 'ddexp', 'dexp',
+                      'dflat', 'dgamma', 'dgev', 'df', 'dggamma', 'dgpar',
+                      'dloglik', 'dlnorm', 'dlogis', 'dnorm', 'dpar',
+                      'dt', 'dunif', 'dweib', 'dmulti', 'ddirch', 'dmnorm',
+                      'dmt', 'dwish')
+    """ OpenBUGS built-in distributions
+
+    Functions from
+    http://www.openbugs.info/Manuals/ModelSpecification.html#ContentsAI
+    """
+
+    tokens = {
+        'whitespace': [
+            (r"\s+", Text),
+        ],
+        'comments': [
+            # Comments
+            (r'#.*$', Comment.Single),
+        ],
+        'root': [
+            # Comments
+            include('comments'),
+            include('whitespace'),
+            # Block start
+            (r'(model)(\s+)(\{)',
+             bygroups(Keyword.Namespace, Text, Punctuation)),
+            # Reserved Words
+            (r'(for|in)(?![\w.])', Keyword.Reserved),
+            # Built-in Functions
+            (r'({})(?=\s*\()'.format(r'|'.join(_FUNCTIONS + _DISTRIBUTIONS)),
+             Name.Builtin),
+            # Regular variable names
+            (r'[A-Za-z][\w.]*', Name),
+            # Number Literals
+            (r'[-+]?[0-9]*\.?[0-9]+([eE][-+]?[0-9]+)?', Number),
+            # Punctuation
+            (r'\[|\]|\(|\)|:|,|;', Punctuation),
+            # Assignment operators
+            # SLexer makes these tokens Operators.
+            (r'<-|~', Operator),
+            # Infix and prefix operators
+            (r'\+|-|\*|/', Operator),
+            # Block
+            (r'[{}]', Punctuation),
+        ]
+    }
+
+    def analyse_text(text):
+        if re.search(r"^\s*model\s*{", text, re.M):
+            return 0.7
+        else:
+            return 0.0
+
+
+class JagsLexer(RegexLexer):
+    """
+    Pygments Lexer for JAGS.
+    """
+
+    name = 'JAGS'
+    aliases = ['jags']
+    filenames = ['*.jag', '*.bug']
+    url = 'https://mcmc-jags.sourceforge.io'
+    version_added = '1.6'
+
+    # JAGS
+    _FUNCTIONS = (
+        'abs', 'arccos', 'arccosh', 'arcsin', 'arcsinh', 'arctan', 'arctanh',
+        'cos', 'cosh', 'cloglog',
+        'equals', 'exp', 'icloglog', 'ifelse', 'ilogit', 'log', 'logfact',
+        'loggam', 'logit', 'phi', 'pow', 'probit', 'round', 'sin', 'sinh',
+        'sqrt', 'step', 'tan', 'tanh', 'trunc', 'inprod', 'interp.lin',
+        'logdet', 'max', 'mean', 'min', 'prod', 'sum', 'sd', 'inverse',
+        'rank', 'sort', 't', 'acos', 'acosh', 'asin', 'asinh', 'atan',
+        # Truncation/Censoring (should I include)
+        'T', 'I')
+    # Distributions with density, probability and quartile functions
+    _DISTRIBUTIONS = tuple(f'[dpq]{x}' for x in
+                           ('bern', 'beta', 'dchiqsqr', 'ddexp', 'dexp',
+                            'df', 'gamma', 'gen.gamma', 'logis', 'lnorm',
+                            'negbin', 'nchisqr', 'norm', 'par', 'pois', 'weib'))
+    # Other distributions without density and probability
+    _OTHER_DISTRIBUTIONS = (
+        'dt', 'dunif', 'dbetabin', 'dbern', 'dbin', 'dcat', 'dhyper',
+        'ddirch', 'dmnorm', 'dwish', 'dmt', 'dmulti', 'dbinom', 'dchisq',
+        'dnbinom', 'dweibull', 'ddirich')
+
+    tokens = {
+        'whitespace': [
+            (r"\s+", Text),
+        ],
+        'names': [
+            # Regular variable names
+            (r'[a-zA-Z][\w.]*\b', Name),
+        ],
+        'comments': [
+            # do not use stateful comments
+            (r'(?s)/\*.*?\*/', Comment.Multiline),
+            # Comments
+            (r'#.*$', Comment.Single),
+        ],
+        'root': [
+            # Comments
+            include('comments'),
+            include('whitespace'),
+            # Block start
+            (r'(model|data)(\s+)(\{)',
+             bygroups(Keyword.Namespace, Text, Punctuation)),
+            (r'var(?![\w.])', Keyword.Declaration),
+            # Reserved Words
+            (r'(for|in)(?![\w.])', Keyword.Reserved),
+            # Builtins
+            # Need to use lookahead because . is a valid char
+            (r'({})(?=\s*\()'.format(r'|'.join(_FUNCTIONS
+                                          + _DISTRIBUTIONS
+                                          + _OTHER_DISTRIBUTIONS)),
+             Name.Builtin),
+            # Names
+            include('names'),
+            # Number Literals
+            (r'[-+]?[0-9]*\.?[0-9]+([eE][-+]?[0-9]+)?', Number),
+            (r'\[|\]|\(|\)|:|,|;', Punctuation),
+            # Assignment operators
+            (r'<-|~', Operator),
+            # # JAGS includes many more than OpenBUGS
+            (r'\+|-|\*|\/|\|\|[&]{2}|[<>=]=?|\^|%.*?%', Operator),
+            (r'[{}]', Punctuation),
+        ]
+    }
+
+    def analyse_text(text):
+        if re.search(r'^\s*model\s*\{', text, re.M):
+            if re.search(r'^\s*data\s*\{', text, re.M):
+                return 0.9
+            elif re.search(r'^\s*var', text, re.M):
+                return 0.9
+            else:
+                return 0.3
+        else:
+            return 0
+
+
+class StanLexer(RegexLexer):
+    """Pygments Lexer for Stan models.
+
+    The Stan modeling language is specified in the *Stan Modeling Language
+    User's Guide and Reference Manual, v2.17.0*,
+    `pdf `__.
+    """
+
+    name = 'Stan'
+    aliases = ['stan']
+    filenames = ['*.stan']
+    url = 'https://mc-stan.org'
+    version_added = '1.6'
+
+    tokens = {
+        'whitespace': [
+            (r"\s+", Text),
+        ],
+        'comments': [
+            (r'(?s)/\*.*?\*/', Comment.Multiline),
+            # Comments
+            (r'(//|#).*$', Comment.Single),
+        ],
+        'root': [
+            (r'"[^"]*"', String),
+            # Comments
+            include('comments'),
+            # block start
+            include('whitespace'),
+            # Block start
+            (r'({})(\s*)(\{{)'.format(r'|'.join(('functions', 'data', r'transformed\s+?data',
+                        'parameters', r'transformed\s+parameters',
+                        'model', r'generated\s+quantities'))),
+             bygroups(Keyword.Namespace, Text, Punctuation)),
+            # target keyword
+            (r'target\s*\+=', Keyword),
+            # jacobian += statement
+            (r'jacobian\s*\+=', Keyword),
+            # Reserved Words
+            (r'({})\b'.format(r'|'.join(_stan_builtins.KEYWORDS)), Keyword),
+            # Truncation
+            (r'T(?=\s*\[)', Keyword),
+            # Data types
+            (r'({})\b'.format(r'|'.join(_stan_builtins.TYPES)), Keyword.Type),
+             # < should be punctuation, but elsewhere I can't tell if it is in
+             # a range constraint
+            (r'(<)(\s*)(upper|lower|offset|multiplier)(\s*)(=)',
+             bygroups(Operator, Whitespace, Keyword, Whitespace, Punctuation)),
+            (r'(,)(\s*)(upper)(\s*)(=)',
+             bygroups(Punctuation, Whitespace, Keyword, Whitespace, Punctuation)),
+            # Punctuation
+            (r"[;,\[\]()]", Punctuation),
+            # Builtin
+            (r'({})(?=\s*\()'.format('|'.join(_stan_builtins.FUNCTIONS)), Name.Builtin),
+            (r'(~)(\s*)({})(?=\s*\()'.format('|'.join(_stan_builtins.DISTRIBUTIONS)),
+                bygroups(Operator, Whitespace, Name.Builtin)),
+            # Special names ending in __, like lp__
+            (r'[A-Za-z]\w*__\b', Name.Builtin.Pseudo),
+            (r'({})\b'.format(r'|'.join(_stan_builtins.RESERVED)), Keyword.Reserved),
+            # user-defined functions
+            (r'[A-Za-z]\w*(?=\s*\()]', Name.Function),
+            # Imaginary Literals
+            (r'[0-9]+(\.[0-9]*)?([eE][+-]?[0-9]+)?i', Number.Float),
+            (r'\.[0-9]+([eE][+-]?[0-9]+)?i', Number.Float),
+            (r'[0-9]+i', Number.Float),
+            # Real Literals
+            (r'[0-9]+(\.[0-9]*)?([eE][+-]?[0-9]+)?', Number.Float),
+            (r'\.[0-9]+([eE][+-]?[0-9]+)?', Number.Float),
+            # Integer Literals
+            (r'[0-9]+', Number.Integer),
+            # Regular variable names
+            (r'[A-Za-z]\w*\b', Name),
+            # Assignment operators
+            (r'<-|(?:\+|-|\.?/|\.?\*|=)?=|~', Operator),
+            # Infix, prefix and postfix operators (and = )
+            (r"\+|-|\.?\*|\.?/|\\|'|\.?\^|!=?|<=?|>=?|\|\||&&|%|\?|:|%/%|!", Operator),
+            # Block delimiters
+            (r'[{}]', Punctuation),
+            # Distribution |
+            (r'\|', Punctuation)
+        ]
+    }
+
+    def analyse_text(text):
+        if re.search(r'^\s*parameters\s*\{', text, re.M):
+            return 1.0
+        else:
+            return 0.0
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/modula2.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/modula2.py
new file mode 100644
index 0000000000000000000000000000000000000000..c0ebd5c14c33767f8374de499baa938b2c943425
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/modula2.py
@@ -0,0 +1,1579 @@
+"""
+    pygments.lexers.modula2
+    ~~~~~~~~~~~~~~~~~~~~~~~
+
+    Multi-Dialect Lexer for Modula-2.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, include
+from pygments.util import get_bool_opt, get_list_opt
+from pygments.token import Text, Comment, Operator, Keyword, Name, \
+    String, Number, Punctuation, Error
+
+__all__ = ['Modula2Lexer']
+
+
+# Multi-Dialect Modula-2 Lexer
+class Modula2Lexer(RegexLexer):
+    """
+    For Modula-2 source code.
+
+    The Modula-2 lexer supports several dialects.  By default, it operates in
+    fallback mode, recognising the *combined* literals, punctuation symbols
+    and operators of all supported dialects, and the *combined* reserved words
+    and builtins of PIM Modula-2, ISO Modula-2 and Modula-2 R10, while not
+    differentiating between library defined identifiers.
+
+    To select a specific dialect, a dialect option may be passed
+    or a dialect tag may be embedded into a source file.
+
+    Dialect Options:
+
+    `m2pim`
+        Select PIM Modula-2 dialect.
+    `m2iso`
+        Select ISO Modula-2 dialect.
+    `m2r10`
+        Select Modula-2 R10 dialect.
+    `objm2`
+        Select Objective Modula-2 dialect.
+
+    The PIM and ISO dialect options may be qualified with a language extension.
+
+    Language Extensions:
+
+    `+aglet`
+        Select Aglet Modula-2 extensions, available with m2iso.
+    `+gm2`
+        Select GNU Modula-2 extensions, available with m2pim.
+    `+p1`
+        Select p1 Modula-2 extensions, available with m2iso.
+    `+xds`
+        Select XDS Modula-2 extensions, available with m2iso.
+
+
+    Passing a Dialect Option via Unix Commandline Interface
+
+    Dialect options may be passed to the lexer using the `dialect` key.
+    Only one such option should be passed. If multiple dialect options are
+    passed, the first valid option is used, any subsequent options are ignored.
+
+    Examples:
+
+    `$ pygmentize -O full,dialect=m2iso -f html -o /path/to/output /path/to/input`
+        Use ISO dialect to render input to HTML output
+    `$ pygmentize -O full,dialect=m2iso+p1 -f rtf -o /path/to/output /path/to/input`
+        Use ISO dialect with p1 extensions to render input to RTF output
+
+
+    Embedding a Dialect Option within a source file
+
+    A dialect option may be embedded in a source file in form of a dialect
+    tag, a specially formatted comment that specifies a dialect option.
+
+    Dialect Tag EBNF::
+
+       dialectTag :
+           OpeningCommentDelim Prefix dialectOption ClosingCommentDelim ;
+
+       dialectOption :
+           'm2pim' | 'm2iso' | 'm2r10' | 'objm2' |
+           'm2iso+aglet' | 'm2pim+gm2' | 'm2iso+p1' | 'm2iso+xds' ;
+
+       Prefix : '!' ;
+
+       OpeningCommentDelim : '(*' ;
+
+       ClosingCommentDelim : '*)' ;
+
+    No whitespace is permitted between the tokens of a dialect tag.
+
+    In the event that a source file contains multiple dialect tags, the first
+    tag that contains a valid dialect option will be used and any subsequent
+    dialect tags will be ignored.  Ideally, a dialect tag should be placed
+    at the beginning of a source file.
+
+    An embedded dialect tag overrides a dialect option set via command line.
+
+    Examples:
+
+    ``(*!m2r10*) DEFINITION MODULE Foobar; ...``
+        Use Modula2 R10 dialect to render this source file.
+    ``(*!m2pim+gm2*) DEFINITION MODULE Bazbam; ...``
+        Use PIM dialect with GNU extensions to render this source file.
+
+
+    Algol Publication Mode:
+
+    In Algol publication mode, source text is rendered for publication of
+    algorithms in scientific papers and academic texts, following the format
+    of the Revised Algol-60 Language Report.  It is activated by passing
+    one of two corresponding styles as an option:
+
+    `algol`
+        render reserved words lowercase underline boldface
+        and builtins lowercase boldface italic
+    `algol_nu`
+        render reserved words lowercase boldface (no underlining)
+        and builtins lowercase boldface italic
+
+    The lexer automatically performs the required lowercase conversion when
+    this mode is activated.
+
+    Example:
+
+    ``$ pygmentize -O full,style=algol -f latex -o /path/to/output /path/to/input``
+        Render input file in Algol publication mode to LaTeX output.
+
+
+    Rendering Mode of First Class ADT Identifiers:
+
+    The rendering of standard library first class ADT identifiers is controlled
+    by option flag "treat_stdlib_adts_as_builtins".
+
+    When this option is turned on, standard library ADT identifiers are rendered
+    as builtins.  When it is turned off, they are rendered as ordinary library
+    identifiers.
+
+    `treat_stdlib_adts_as_builtins` (default: On)
+
+    The option is useful for dialects that support ADTs as first class objects
+    and provide ADTs in the standard library that would otherwise be built-in.
+
+    At present, only Modula-2 R10 supports library ADTs as first class objects
+    and therefore, no ADT identifiers are defined for any other dialects.
+
+    Example:
+
+    ``$ pygmentize -O full,dialect=m2r10,treat_stdlib_adts_as_builtins=Off ...``
+        Render standard library ADTs as ordinary library types.
+
+    .. versionchanged:: 2.1
+       Added multi-dialect support.
+    """
+    name = 'Modula-2'
+    url = 'http://www.modula2.org/'
+    aliases = ['modula2', 'm2']
+    filenames = ['*.def', '*.mod']
+    mimetypes = ['text/x-modula2']
+    version_added = '1.3'
+
+    flags = re.MULTILINE | re.DOTALL
+
+    tokens = {
+        'whitespace': [
+            (r'\n+', Text),  # blank lines
+            (r'\s+', Text),  # whitespace
+        ],
+        'dialecttags': [
+            # PIM Dialect Tag
+            (r'\(\*!m2pim\*\)', Comment.Special),
+            # ISO Dialect Tag
+            (r'\(\*!m2iso\*\)', Comment.Special),
+            # M2R10 Dialect Tag
+            (r'\(\*!m2r10\*\)', Comment.Special),
+            # ObjM2 Dialect Tag
+            (r'\(\*!objm2\*\)', Comment.Special),
+            # Aglet Extensions Dialect Tag
+            (r'\(\*!m2iso\+aglet\*\)', Comment.Special),
+            # GNU Extensions Dialect Tag
+            (r'\(\*!m2pim\+gm2\*\)', Comment.Special),
+            # p1 Extensions Dialect Tag
+            (r'\(\*!m2iso\+p1\*\)', Comment.Special),
+            # XDS Extensions Dialect Tag
+            (r'\(\*!m2iso\+xds\*\)', Comment.Special),
+        ],
+        'identifiers': [
+            (r'([a-zA-Z_$][\w$]*)', Name),
+        ],
+        'prefixed_number_literals': [
+            #
+            # Base-2, whole number
+            (r'0b[01]+(\'[01]+)*', Number.Bin),
+            #
+            # Base-16, whole number
+            (r'0[ux][0-9A-F]+(\'[0-9A-F]+)*', Number.Hex),
+        ],
+        'plain_number_literals': [
+            #
+            # Base-10, real number with exponent
+            (r'[0-9]+(\'[0-9]+)*'  # integral part
+             r'\.[0-9]+(\'[0-9]+)*'  # fractional part
+             r'[eE][+-]?[0-9]+(\'[0-9]+)*',  # exponent
+             Number.Float),
+            #
+            # Base-10, real number without exponent
+            (r'[0-9]+(\'[0-9]+)*'  # integral part
+             r'\.[0-9]+(\'[0-9]+)*',  # fractional part
+             Number.Float),
+            #
+            # Base-10, whole number
+            (r'[0-9]+(\'[0-9]+)*', Number.Integer),
+        ],
+        'suffixed_number_literals': [
+            #
+            # Base-8, whole number
+            (r'[0-7]+B', Number.Oct),
+            #
+            # Base-8, character code
+            (r'[0-7]+C', Number.Oct),
+            #
+            # Base-16, number
+            (r'[0-9A-F]+H', Number.Hex),
+        ],
+        'string_literals': [
+            (r'"(\\\\|\\[^\\]|[^"\\])*"', String.Double),
+            (r"'(\\\\|\\[^\\]|[^'\\])*'", String.Single),
+        ],
+        'digraph_operators': [
+            # Dot Product Operator
+            (r'\*\.', Operator),
+            # Array Concatenation Operator
+            (r'\+>', Operator),  # M2R10 + ObjM2
+            # Inequality Operator
+            (r'<>', Operator),  # ISO + PIM
+            # Less-Or-Equal, Subset
+            (r'<=', Operator),
+            # Greater-Or-Equal, Superset
+            (r'>=', Operator),
+            # Identity Operator
+            (r'==', Operator),  # M2R10 + ObjM2
+            # Type Conversion Operator
+            (r'::', Operator),  # M2R10 + ObjM2
+            # Assignment Symbol
+            (r':=', Operator),
+            # Postfix Increment Mutator
+            (r'\+\+', Operator),  # M2R10 + ObjM2
+            # Postfix Decrement Mutator
+            (r'--', Operator),  # M2R10 + ObjM2
+        ],
+        'unigraph_operators': [
+            # Arithmetic Operators
+            (r'[+-]', Operator),
+            (r'[*/]', Operator),
+            # ISO 80000-2 compliant Set Difference Operator
+            (r'\\', Operator),  # M2R10 + ObjM2
+            # Relational Operators
+            (r'[=#<>]', Operator),
+            # Dereferencing Operator
+            (r'\^', Operator),
+            # Dereferencing Operator Synonym
+            (r'@', Operator),  # ISO
+            # Logical AND Operator Synonym
+            (r'&', Operator),  # PIM + ISO
+            # Logical NOT Operator Synonym
+            (r'~', Operator),  # PIM + ISO
+            # Smalltalk Message Prefix
+            (r'`', Operator),  # ObjM2
+        ],
+        'digraph_punctuation': [
+            # Range Constructor
+            (r'\.\.', Punctuation),
+            # Opening Chevron Bracket
+            (r'<<', Punctuation),  # M2R10 + ISO
+            # Closing Chevron Bracket
+            (r'>>', Punctuation),  # M2R10 + ISO
+            # Blueprint Punctuation
+            (r'->', Punctuation),  # M2R10 + ISO
+            # Distinguish |# and # in M2 R10
+            (r'\|#', Punctuation),
+            # Distinguish ## and # in M2 R10
+            (r'##', Punctuation),
+            # Distinguish |* and * in M2 R10
+            (r'\|\*', Punctuation),
+        ],
+        'unigraph_punctuation': [
+            # Common Punctuation
+            (r'[()\[\]{},.:;|]', Punctuation),
+            # Case Label Separator Synonym
+            (r'!', Punctuation),  # ISO
+            # Blueprint Punctuation
+            (r'\?', Punctuation),  # M2R10 + ObjM2
+        ],
+        'comments': [
+            # Single Line Comment
+            (r'^//.*?\n', Comment.Single),  # M2R10 + ObjM2
+            # Block Comment
+            (r'\(\*([^$].*?)\*\)', Comment.Multiline),
+            # Template Block Comment
+            (r'/\*(.*?)\*/', Comment.Multiline),  # M2R10 + ObjM2
+        ],
+        'pragmas': [
+            # ISO Style Pragmas
+            (r'<\*.*?\*>', Comment.Preproc),  # ISO, M2R10 + ObjM2
+            # Pascal Style Pragmas
+            (r'\(\*\$.*?\*\)', Comment.Preproc),  # PIM
+        ],
+        'root': [
+            include('whitespace'),
+            include('dialecttags'),
+            include('pragmas'),
+            include('comments'),
+            include('identifiers'),
+            include('suffixed_number_literals'),  # PIM + ISO
+            include('prefixed_number_literals'),  # M2R10 + ObjM2
+            include('plain_number_literals'),
+            include('string_literals'),
+            include('digraph_punctuation'),
+            include('digraph_operators'),
+            include('unigraph_punctuation'),
+            include('unigraph_operators'),
+        ]
+    }
+
+#  C o m m o n   D a t a s e t s
+
+    # Common Reserved Words Dataset
+    common_reserved_words = (
+        # 37 common reserved words
+        'AND', 'ARRAY', 'BEGIN', 'BY', 'CASE', 'CONST', 'DEFINITION', 'DIV',
+        'DO', 'ELSE', 'ELSIF', 'END', 'EXIT', 'FOR', 'FROM', 'IF',
+        'IMPLEMENTATION', 'IMPORT', 'IN', 'LOOP', 'MOD', 'MODULE', 'NOT',
+        'OF', 'OR', 'POINTER', 'PROCEDURE', 'RECORD', 'REPEAT', 'RETURN',
+        'SET', 'THEN', 'TO', 'TYPE', 'UNTIL', 'VAR', 'WHILE',
+    )
+
+    # Common Builtins Dataset
+    common_builtins = (
+        # 16 common builtins
+        'ABS', 'BOOLEAN', 'CARDINAL', 'CHAR', 'CHR', 'FALSE', 'INTEGER',
+        'LONGINT', 'LONGREAL', 'MAX', 'MIN', 'NIL', 'ODD', 'ORD', 'REAL',
+        'TRUE',
+    )
+
+    # Common Pseudo-Module Builtins Dataset
+    common_pseudo_builtins = (
+        # 4 common pseudo builtins
+        'ADDRESS', 'BYTE', 'WORD', 'ADR'
+    )
+
+#  P I M   M o d u l a - 2   D a t a s e t s
+
+    # Lexemes to Mark as Error Tokens for PIM Modula-2
+    pim_lexemes_to_reject = (
+        '!', '`', '@', '$', '%', '?', '\\', '==', '++', '--', '::', '*.',
+        '+>', '->', '<<', '>>', '|#', '##',
+    )
+
+    # PIM Modula-2 Additional Reserved Words Dataset
+    pim_additional_reserved_words = (
+        # 3 additional reserved words
+        'EXPORT', 'QUALIFIED', 'WITH',
+    )
+
+    # PIM Modula-2 Additional Builtins Dataset
+    pim_additional_builtins = (
+        # 16 additional builtins
+        'BITSET', 'CAP', 'DEC', 'DISPOSE', 'EXCL', 'FLOAT', 'HALT', 'HIGH',
+        'INC', 'INCL', 'NEW', 'NIL', 'PROC', 'SIZE', 'TRUNC', 'VAL',
+    )
+
+    # PIM Modula-2 Additional Pseudo-Module Builtins Dataset
+    pim_additional_pseudo_builtins = (
+        # 5 additional pseudo builtins
+        'SYSTEM', 'PROCESS', 'TSIZE', 'NEWPROCESS', 'TRANSFER',
+    )
+
+#  I S O   M o d u l a - 2   D a t a s e t s
+
+    # Lexemes to Mark as Error Tokens for ISO Modula-2
+    iso_lexemes_to_reject = (
+        '`', '$', '%', '?', '\\', '==', '++', '--', '::', '*.', '+>', '->',
+        '<<', '>>', '|#', '##',
+    )
+
+    # ISO Modula-2 Additional Reserved Words Dataset
+    iso_additional_reserved_words = (
+        # 9 additional reserved words (ISO 10514-1)
+        'EXCEPT', 'EXPORT', 'FINALLY', 'FORWARD', 'PACKEDSET', 'QUALIFIED',
+        'REM', 'RETRY', 'WITH',
+        # 10 additional reserved words (ISO 10514-2 & ISO 10514-3)
+        'ABSTRACT', 'AS', 'CLASS', 'GUARD', 'INHERIT', 'OVERRIDE', 'READONLY',
+        'REVEAL', 'TRACED', 'UNSAFEGUARDED',
+    )
+
+    # ISO Modula-2 Additional Builtins Dataset
+    iso_additional_builtins = (
+        # 26 additional builtins (ISO 10514-1)
+        'BITSET', 'CAP', 'CMPLX', 'COMPLEX', 'DEC', 'DISPOSE', 'EXCL', 'FLOAT',
+        'HALT', 'HIGH', 'IM', 'INC', 'INCL', 'INT', 'INTERRUPTIBLE',  'LENGTH',
+        'LFLOAT', 'LONGCOMPLEX', 'NEW', 'PROC', 'PROTECTION', 'RE', 'SIZE',
+        'TRUNC', 'UNINTERRUBTIBLE', 'VAL',
+        # 5 additional builtins (ISO 10514-2 & ISO 10514-3)
+        'CREATE', 'DESTROY', 'EMPTY', 'ISMEMBER', 'SELF',
+    )
+
+    # ISO Modula-2 Additional Pseudo-Module Builtins Dataset
+    iso_additional_pseudo_builtins = (
+        # 14 additional builtins (SYSTEM)
+        'SYSTEM', 'BITSPERLOC', 'LOCSPERBYTE', 'LOCSPERWORD', 'LOC',
+        'ADDADR', 'SUBADR', 'DIFADR', 'MAKEADR', 'ADR',
+        'ROTATE', 'SHIFT', 'CAST', 'TSIZE',
+        # 13 additional builtins (COROUTINES)
+        'COROUTINES', 'ATTACH', 'COROUTINE', 'CURRENT', 'DETACH', 'HANDLER',
+        'INTERRUPTSOURCE', 'IOTRANSFER', 'IsATTACHED', 'LISTEN',
+        'NEWCOROUTINE', 'PROT', 'TRANSFER',
+        # 9 additional builtins (EXCEPTIONS)
+        'EXCEPTIONS', 'AllocateSource', 'CurrentNumber', 'ExceptionNumber',
+        'ExceptionSource', 'GetMessage', 'IsCurrentSource',
+        'IsExceptionalExecution', 'RAISE',
+        # 3 additional builtins (TERMINATION)
+        'TERMINATION', 'IsTerminating', 'HasHalted',
+        # 4 additional builtins (M2EXCEPTION)
+        'M2EXCEPTION', 'M2Exceptions', 'M2Exception', 'IsM2Exception',
+        'indexException', 'rangeException', 'caseSelectException',
+        'invalidLocation', 'functionException', 'wholeValueException',
+        'wholeDivException', 'realValueException', 'realDivException',
+        'complexValueException', 'complexDivException', 'protException',
+        'sysException', 'coException', 'exException',
+    )
+
+#  M o d u l a - 2   R 1 0   D a t a s e t s
+
+    # Lexemes to Mark as Error Tokens for Modula-2 R10
+    m2r10_lexemes_to_reject = (
+        '!', '`', '@', '$', '%', '&', '<>',
+    )
+
+    # Modula-2 R10 reserved words in addition to the common set
+    m2r10_additional_reserved_words = (
+        # 12 additional reserved words
+        'ALIAS', 'ARGLIST', 'BLUEPRINT', 'COPY', 'GENLIB', 'INDETERMINATE',
+        'NEW', 'NONE', 'OPAQUE', 'REFERENTIAL', 'RELEASE', 'RETAIN',
+        # 2 additional reserved words with symbolic assembly option
+        'ASM', 'REG',
+    )
+
+    # Modula-2 R10 builtins in addition to the common set
+    m2r10_additional_builtins = (
+        # 26 additional builtins
+        'CARDINAL', 'COUNT', 'EMPTY', 'EXISTS', 'INSERT', 'LENGTH', 'LONGCARD',
+        'OCTET', 'PTR', 'PRED', 'READ', 'READNEW', 'REMOVE', 'RETRIEVE', 'SORT',
+        'STORE', 'SUBSET', 'SUCC', 'TLIMIT', 'TMAX', 'TMIN', 'TRUE', 'TSIZE',
+        'UNICHAR', 'WRITE', 'WRITEF',
+    )
+
+    # Modula-2 R10 Additional Pseudo-Module Builtins Dataset
+    m2r10_additional_pseudo_builtins = (
+        # 13 additional builtins (TPROPERTIES)
+        'TPROPERTIES', 'PROPERTY', 'LITERAL', 'TPROPERTY', 'TLITERAL',
+        'TBUILTIN', 'TDYN', 'TREFC', 'TNIL', 'TBASE', 'TPRECISION',
+        'TMAXEXP', 'TMINEXP',
+        # 4 additional builtins (CONVERSION)
+        'CONVERSION', 'TSXFSIZE', 'SXF', 'VAL',
+        # 35 additional builtins (UNSAFE)
+        'UNSAFE', 'CAST', 'INTRINSIC', 'AVAIL', 'ADD', 'SUB', 'ADDC', 'SUBC',
+        'FETCHADD', 'FETCHSUB', 'SHL', 'SHR', 'ASHR', 'ROTL', 'ROTR', 'ROTLC',
+        'ROTRC', 'BWNOT', 'BWAND', 'BWOR', 'BWXOR', 'BWNAND', 'BWNOR',
+        'SETBIT', 'TESTBIT', 'LSBIT', 'MSBIT', 'CSBITS', 'BAIL', 'HALT',
+        'TODO', 'FFI', 'ADDR', 'VARGLIST', 'VARGC',
+        # 11 additional builtins (ATOMIC)
+        'ATOMIC', 'INTRINSIC', 'AVAIL', 'SWAP', 'CAS', 'INC', 'DEC', 'BWAND',
+        'BWNAND', 'BWOR', 'BWXOR',
+        # 7 additional builtins (COMPILER)
+        'COMPILER', 'DEBUG', 'MODNAME', 'PROCNAME', 'LINENUM', 'DEFAULT',
+        'HASH',
+        # 5 additional builtins (ASSEMBLER)
+        'ASSEMBLER', 'REGISTER', 'SETREG', 'GETREG', 'CODE',
+    )
+
+#  O b j e c t i v e   M o d u l a - 2   D a t a s e t s
+
+    # Lexemes to Mark as Error Tokens for Objective Modula-2
+    objm2_lexemes_to_reject = (
+        '!', '$', '%', '&', '<>',
+    )
+
+    # Objective Modula-2 Extensions
+    # reserved words in addition to Modula-2 R10
+    objm2_additional_reserved_words = (
+        # 16 additional reserved words
+        'BYCOPY', 'BYREF', 'CLASS', 'CONTINUE', 'CRITICAL', 'INOUT', 'METHOD',
+        'ON', 'OPTIONAL', 'OUT', 'PRIVATE', 'PROTECTED', 'PROTOCOL', 'PUBLIC',
+        'SUPER', 'TRY',
+    )
+
+    # Objective Modula-2 Extensions
+    # builtins in addition to Modula-2 R10
+    objm2_additional_builtins = (
+        # 3 additional builtins
+        'OBJECT', 'NO', 'YES',
+    )
+
+    # Objective Modula-2 Extensions
+    # pseudo-module builtins in addition to Modula-2 R10
+    objm2_additional_pseudo_builtins = (
+        # None
+    )
+
+#  A g l e t   M o d u l a - 2   D a t a s e t s
+
+    # Aglet Extensions
+    # reserved words in addition to ISO Modula-2
+    aglet_additional_reserved_words = (
+        # None
+    )
+
+    # Aglet Extensions
+    # builtins in addition to ISO Modula-2
+    aglet_additional_builtins = (
+        # 9 additional builtins
+        'BITSET8', 'BITSET16', 'BITSET32', 'CARDINAL8', 'CARDINAL16',
+        'CARDINAL32', 'INTEGER8', 'INTEGER16', 'INTEGER32',
+    )
+
+    # Aglet Modula-2 Extensions
+    # pseudo-module builtins in addition to ISO Modula-2
+    aglet_additional_pseudo_builtins = (
+        # None
+    )
+
+#  G N U   M o d u l a - 2   D a t a s e t s
+
+    # GNU Extensions
+    # reserved words in addition to PIM Modula-2
+    gm2_additional_reserved_words = (
+        # 10 additional reserved words
+        'ASM', '__ATTRIBUTE__', '__BUILTIN__', '__COLUMN__', '__DATE__',
+        '__FILE__', '__FUNCTION__', '__LINE__', '__MODULE__', 'VOLATILE',
+    )
+
+    # GNU Extensions
+    # builtins in addition to PIM Modula-2
+    gm2_additional_builtins = (
+        # 21 additional builtins
+        'BITSET8', 'BITSET16', 'BITSET32', 'CARDINAL8', 'CARDINAL16',
+        'CARDINAL32', 'CARDINAL64', 'COMPLEX32', 'COMPLEX64', 'COMPLEX96',
+        'COMPLEX128', 'INTEGER8', 'INTEGER16', 'INTEGER32', 'INTEGER64',
+        'REAL8', 'REAL16', 'REAL32', 'REAL96', 'REAL128', 'THROW',
+    )
+
+    # GNU Extensions
+    # pseudo-module builtins in addition to PIM Modula-2
+    gm2_additional_pseudo_builtins = (
+        # None
+    )
+
+#  p 1   M o d u l a - 2   D a t a s e t s
+
+    # p1 Extensions
+    # reserved words in addition to ISO Modula-2
+    p1_additional_reserved_words = (
+        # None
+    )
+
+    # p1 Extensions
+    # builtins in addition to ISO Modula-2
+    p1_additional_builtins = (
+        # None
+    )
+
+    # p1 Modula-2 Extensions
+    # pseudo-module builtins in addition to ISO Modula-2
+    p1_additional_pseudo_builtins = (
+        # 1 additional builtin
+        'BCD',
+    )
+
+#  X D S   M o d u l a - 2   D a t a s e t s
+
+    # XDS Extensions
+    # reserved words in addition to ISO Modula-2
+    xds_additional_reserved_words = (
+        # 1 additional reserved word
+        'SEQ',
+    )
+
+    # XDS Extensions
+    # builtins in addition to ISO Modula-2
+    xds_additional_builtins = (
+        # 9 additional builtins
+        'ASH', 'ASSERT', 'DIFFADR_TYPE', 'ENTIER', 'INDEX', 'LEN',
+        'LONGCARD', 'SHORTCARD', 'SHORTINT',
+    )
+
+    # XDS Modula-2 Extensions
+    # pseudo-module builtins in addition to ISO Modula-2
+    xds_additional_pseudo_builtins = (
+        # 22 additional builtins (SYSTEM)
+        'PROCESS', 'NEWPROCESS', 'BOOL8', 'BOOL16', 'BOOL32', 'CARD8',
+        'CARD16', 'CARD32', 'INT8', 'INT16', 'INT32', 'REF', 'MOVE',
+        'FILL', 'GET', 'PUT', 'CC', 'int', 'unsigned', 'size_t', 'void'
+        # 3 additional builtins (COMPILER)
+        'COMPILER', 'OPTION', 'EQUATION'
+    )
+
+#  P I M   S t a n d a r d   L i b r a r y   D a t a s e t s
+
+    # PIM Modula-2 Standard Library Modules Dataset
+    pim_stdlib_module_identifiers = (
+        'Terminal', 'FileSystem', 'InOut', 'RealInOut', 'MathLib0', 'Storage',
+    )
+
+    # PIM Modula-2 Standard Library Types Dataset
+    pim_stdlib_type_identifiers = (
+        'Flag', 'FlagSet', 'Response', 'Command', 'Lock', 'Permission',
+        'MediumType', 'File', 'FileProc', 'DirectoryProc', 'FileCommand',
+        'DirectoryCommand',
+    )
+
+    # PIM Modula-2 Standard Library Procedures Dataset
+    pim_stdlib_proc_identifiers = (
+        'Read', 'BusyRead', 'ReadAgain', 'Write', 'WriteString', 'WriteLn',
+        'Create', 'Lookup', 'Close', 'Delete', 'Rename', 'SetRead', 'SetWrite',
+        'SetModify', 'SetOpen', 'Doio', 'SetPos', 'GetPos', 'Length', 'Reset',
+        'Again', 'ReadWord', 'WriteWord', 'ReadChar', 'WriteChar',
+        'CreateMedium', 'DeleteMedium', 'AssignName', 'DeassignName',
+        'ReadMedium', 'LookupMedium', 'OpenInput', 'OpenOutput', 'CloseInput',
+        'CloseOutput', 'ReadString', 'ReadInt', 'ReadCard', 'ReadWrd',
+        'WriteInt', 'WriteCard', 'WriteOct', 'WriteHex', 'WriteWrd',
+        'ReadReal', 'WriteReal', 'WriteFixPt', 'WriteRealOct', 'sqrt', 'exp',
+        'ln', 'sin', 'cos', 'arctan', 'entier', 'ALLOCATE', 'DEALLOCATE',
+    )
+
+    # PIM Modula-2 Standard Library Variables Dataset
+    pim_stdlib_var_identifiers = (
+        'Done', 'termCH', 'in', 'out'
+    )
+
+    # PIM Modula-2 Standard Library Constants Dataset
+    pim_stdlib_const_identifiers = (
+        'EOL',
+    )
+
+#  I S O   S t a n d a r d   L i b r a r y   D a t a s e t s
+
+    # ISO Modula-2 Standard Library Modules Dataset
+    iso_stdlib_module_identifiers = (
+        # TO DO
+    )
+
+    # ISO Modula-2 Standard Library Types Dataset
+    iso_stdlib_type_identifiers = (
+        # TO DO
+    )
+
+    # ISO Modula-2 Standard Library Procedures Dataset
+    iso_stdlib_proc_identifiers = (
+        # TO DO
+    )
+
+    # ISO Modula-2 Standard Library Variables Dataset
+    iso_stdlib_var_identifiers = (
+        # TO DO
+    )
+
+    # ISO Modula-2 Standard Library Constants Dataset
+    iso_stdlib_const_identifiers = (
+        # TO DO
+    )
+
+#  M 2   R 1 0   S t a n d a r d   L i b r a r y   D a t a s e t s
+
+    # Modula-2 R10 Standard Library ADTs Dataset
+    m2r10_stdlib_adt_identifiers = (
+        'BCD', 'LONGBCD', 'BITSET', 'SHORTBITSET', 'LONGBITSET',
+        'LONGLONGBITSET', 'COMPLEX', 'LONGCOMPLEX', 'SHORTCARD', 'LONGLONGCARD',
+        'SHORTINT', 'LONGLONGINT', 'POSINT', 'SHORTPOSINT', 'LONGPOSINT',
+        'LONGLONGPOSINT', 'BITSET8', 'BITSET16', 'BITSET32', 'BITSET64',
+        'BITSET128', 'BS8', 'BS16', 'BS32', 'BS64', 'BS128', 'CARDINAL8',
+        'CARDINAL16', 'CARDINAL32', 'CARDINAL64', 'CARDINAL128', 'CARD8',
+        'CARD16', 'CARD32', 'CARD64', 'CARD128', 'INTEGER8', 'INTEGER16',
+        'INTEGER32', 'INTEGER64', 'INTEGER128', 'INT8', 'INT16', 'INT32',
+        'INT64', 'INT128', 'STRING', 'UNISTRING',
+    )
+
+    # Modula-2 R10 Standard Library Blueprints Dataset
+    m2r10_stdlib_blueprint_identifiers = (
+        'ProtoRoot', 'ProtoComputational', 'ProtoNumeric', 'ProtoScalar',
+        'ProtoNonScalar', 'ProtoCardinal', 'ProtoInteger', 'ProtoReal',
+        'ProtoComplex', 'ProtoVector', 'ProtoTuple', 'ProtoCompArray',
+        'ProtoCollection', 'ProtoStaticArray', 'ProtoStaticSet',
+        'ProtoStaticString', 'ProtoArray', 'ProtoString', 'ProtoSet',
+        'ProtoMultiSet', 'ProtoDictionary', 'ProtoMultiDict', 'ProtoExtension',
+        'ProtoIO', 'ProtoCardMath', 'ProtoIntMath', 'ProtoRealMath',
+    )
+
+    # Modula-2 R10 Standard Library Modules Dataset
+    m2r10_stdlib_module_identifiers = (
+        'ASCII', 'BooleanIO', 'CharIO', 'UnicharIO', 'OctetIO',
+        'CardinalIO', 'LongCardIO', 'IntegerIO', 'LongIntIO', 'RealIO',
+        'LongRealIO', 'BCDIO', 'LongBCDIO', 'CardMath', 'LongCardMath',
+        'IntMath', 'LongIntMath', 'RealMath', 'LongRealMath', 'BCDMath',
+        'LongBCDMath', 'FileIO', 'FileSystem', 'Storage', 'IOSupport',
+    )
+
+    # Modula-2 R10 Standard Library Types Dataset
+    m2r10_stdlib_type_identifiers = (
+        'File', 'Status',
+        # TO BE COMPLETED
+    )
+
+    # Modula-2 R10 Standard Library Procedures Dataset
+    m2r10_stdlib_proc_identifiers = (
+        'ALLOCATE', 'DEALLOCATE', 'SIZE',
+        # TO BE COMPLETED
+    )
+
+    # Modula-2 R10 Standard Library Variables Dataset
+    m2r10_stdlib_var_identifiers = (
+        'stdIn', 'stdOut', 'stdErr',
+    )
+
+    # Modula-2 R10 Standard Library Constants Dataset
+    m2r10_stdlib_const_identifiers = (
+        'pi', 'tau',
+    )
+
+#  D i a l e c t s
+
+    # Dialect modes
+    dialects = (
+        'unknown',
+        'm2pim', 'm2iso', 'm2r10', 'objm2',
+        'm2iso+aglet', 'm2pim+gm2', 'm2iso+p1', 'm2iso+xds',
+    )
+
+#   D a t a b a s e s
+
+    # Lexemes to Mark as Errors Database
+    lexemes_to_reject_db = {
+        # Lexemes to reject for unknown dialect
+        'unknown': (
+            # LEAVE THIS EMPTY
+        ),
+        # Lexemes to reject for PIM Modula-2
+        'm2pim': (
+            pim_lexemes_to_reject,
+        ),
+        # Lexemes to reject for ISO Modula-2
+        'm2iso': (
+            iso_lexemes_to_reject,
+        ),
+        # Lexemes to reject for Modula-2 R10
+        'm2r10': (
+            m2r10_lexemes_to_reject,
+        ),
+        # Lexemes to reject for Objective Modula-2
+        'objm2': (
+            objm2_lexemes_to_reject,
+        ),
+        # Lexemes to reject for Aglet Modula-2
+        'm2iso+aglet': (
+            iso_lexemes_to_reject,
+        ),
+        # Lexemes to reject for GNU Modula-2
+        'm2pim+gm2': (
+            pim_lexemes_to_reject,
+        ),
+        # Lexemes to reject for p1 Modula-2
+        'm2iso+p1': (
+            iso_lexemes_to_reject,
+        ),
+        # Lexemes to reject for XDS Modula-2
+        'm2iso+xds': (
+            iso_lexemes_to_reject,
+        ),
+    }
+
+    # Reserved Words Database
+    reserved_words_db = {
+        # Reserved words for unknown dialect
+        'unknown': (
+            common_reserved_words,
+            pim_additional_reserved_words,
+            iso_additional_reserved_words,
+            m2r10_additional_reserved_words,
+        ),
+
+        # Reserved words for PIM Modula-2
+        'm2pim': (
+            common_reserved_words,
+            pim_additional_reserved_words,
+        ),
+
+        # Reserved words for Modula-2 R10
+        'm2iso': (
+            common_reserved_words,
+            iso_additional_reserved_words,
+        ),
+
+        # Reserved words for ISO Modula-2
+        'm2r10': (
+            common_reserved_words,
+            m2r10_additional_reserved_words,
+        ),
+
+        # Reserved words for Objective Modula-2
+        'objm2': (
+            common_reserved_words,
+            m2r10_additional_reserved_words,
+            objm2_additional_reserved_words,
+        ),
+
+        # Reserved words for Aglet Modula-2 Extensions
+        'm2iso+aglet': (
+            common_reserved_words,
+            iso_additional_reserved_words,
+            aglet_additional_reserved_words,
+        ),
+
+        # Reserved words for GNU Modula-2 Extensions
+        'm2pim+gm2': (
+            common_reserved_words,
+            pim_additional_reserved_words,
+            gm2_additional_reserved_words,
+        ),
+
+        # Reserved words for p1 Modula-2 Extensions
+        'm2iso+p1': (
+            common_reserved_words,
+            iso_additional_reserved_words,
+            p1_additional_reserved_words,
+        ),
+
+        # Reserved words for XDS Modula-2 Extensions
+        'm2iso+xds': (
+            common_reserved_words,
+            iso_additional_reserved_words,
+            xds_additional_reserved_words,
+        ),
+    }
+
+    # Builtins Database
+    builtins_db = {
+        # Builtins for unknown dialect
+        'unknown': (
+            common_builtins,
+            pim_additional_builtins,
+            iso_additional_builtins,
+            m2r10_additional_builtins,
+        ),
+
+        # Builtins for PIM Modula-2
+        'm2pim': (
+            common_builtins,
+            pim_additional_builtins,
+        ),
+
+        # Builtins for ISO Modula-2
+        'm2iso': (
+            common_builtins,
+            iso_additional_builtins,
+        ),
+
+        # Builtins for ISO Modula-2
+        'm2r10': (
+            common_builtins,
+            m2r10_additional_builtins,
+        ),
+
+        # Builtins for Objective Modula-2
+        'objm2': (
+            common_builtins,
+            m2r10_additional_builtins,
+            objm2_additional_builtins,
+        ),
+
+        # Builtins for Aglet Modula-2 Extensions
+        'm2iso+aglet': (
+            common_builtins,
+            iso_additional_builtins,
+            aglet_additional_builtins,
+        ),
+
+        # Builtins for GNU Modula-2 Extensions
+        'm2pim+gm2': (
+            common_builtins,
+            pim_additional_builtins,
+            gm2_additional_builtins,
+        ),
+
+        # Builtins for p1 Modula-2 Extensions
+        'm2iso+p1': (
+            common_builtins,
+            iso_additional_builtins,
+            p1_additional_builtins,
+        ),
+
+        # Builtins for XDS Modula-2 Extensions
+        'm2iso+xds': (
+            common_builtins,
+            iso_additional_builtins,
+            xds_additional_builtins,
+        ),
+    }
+
+    # Pseudo-Module Builtins Database
+    pseudo_builtins_db = {
+        # Builtins for unknown dialect
+        'unknown': (
+            common_pseudo_builtins,
+            pim_additional_pseudo_builtins,
+            iso_additional_pseudo_builtins,
+            m2r10_additional_pseudo_builtins,
+        ),
+
+        # Builtins for PIM Modula-2
+        'm2pim': (
+            common_pseudo_builtins,
+            pim_additional_pseudo_builtins,
+        ),
+
+        # Builtins for ISO Modula-2
+        'm2iso': (
+            common_pseudo_builtins,
+            iso_additional_pseudo_builtins,
+        ),
+
+        # Builtins for ISO Modula-2
+        'm2r10': (
+            common_pseudo_builtins,
+            m2r10_additional_pseudo_builtins,
+        ),
+
+        # Builtins for Objective Modula-2
+        'objm2': (
+            common_pseudo_builtins,
+            m2r10_additional_pseudo_builtins,
+            objm2_additional_pseudo_builtins,
+        ),
+
+        # Builtins for Aglet Modula-2 Extensions
+        'm2iso+aglet': (
+            common_pseudo_builtins,
+            iso_additional_pseudo_builtins,
+            aglet_additional_pseudo_builtins,
+        ),
+
+        # Builtins for GNU Modula-2 Extensions
+        'm2pim+gm2': (
+            common_pseudo_builtins,
+            pim_additional_pseudo_builtins,
+            gm2_additional_pseudo_builtins,
+        ),
+
+        # Builtins for p1 Modula-2 Extensions
+        'm2iso+p1': (
+            common_pseudo_builtins,
+            iso_additional_pseudo_builtins,
+            p1_additional_pseudo_builtins,
+        ),
+
+        # Builtins for XDS Modula-2 Extensions
+        'm2iso+xds': (
+            common_pseudo_builtins,
+            iso_additional_pseudo_builtins,
+            xds_additional_pseudo_builtins,
+        ),
+    }
+
+    # Standard Library ADTs Database
+    stdlib_adts_db = {
+        # Empty entry for unknown dialect
+        'unknown': (
+            # LEAVE THIS EMPTY
+        ),
+        # Standard Library ADTs for PIM Modula-2
+        'm2pim': (
+            # No first class library types
+        ),
+
+        # Standard Library ADTs for ISO Modula-2
+        'm2iso': (
+            # No first class library types
+        ),
+
+        # Standard Library ADTs for Modula-2 R10
+        'm2r10': (
+            m2r10_stdlib_adt_identifiers,
+        ),
+
+        # Standard Library ADTs for Objective Modula-2
+        'objm2': (
+            m2r10_stdlib_adt_identifiers,
+        ),
+
+        # Standard Library ADTs for Aglet Modula-2
+        'm2iso+aglet': (
+            # No first class library types
+        ),
+
+        # Standard Library ADTs for GNU Modula-2
+        'm2pim+gm2': (
+            # No first class library types
+        ),
+
+        # Standard Library ADTs for p1 Modula-2
+        'm2iso+p1': (
+            # No first class library types
+        ),
+
+        # Standard Library ADTs for XDS Modula-2
+        'm2iso+xds': (
+            # No first class library types
+        ),
+    }
+
+    # Standard Library Modules Database
+    stdlib_modules_db = {
+        # Empty entry for unknown dialect
+        'unknown': (
+            # LEAVE THIS EMPTY
+        ),
+        # Standard Library Modules for PIM Modula-2
+        'm2pim': (
+            pim_stdlib_module_identifiers,
+        ),
+
+        # Standard Library Modules for ISO Modula-2
+        'm2iso': (
+            iso_stdlib_module_identifiers,
+        ),
+
+        # Standard Library Modules for Modula-2 R10
+        'm2r10': (
+            m2r10_stdlib_blueprint_identifiers,
+            m2r10_stdlib_module_identifiers,
+            m2r10_stdlib_adt_identifiers,
+        ),
+
+        # Standard Library Modules for Objective Modula-2
+        'objm2': (
+            m2r10_stdlib_blueprint_identifiers,
+            m2r10_stdlib_module_identifiers,
+        ),
+
+        # Standard Library Modules for Aglet Modula-2
+        'm2iso+aglet': (
+            iso_stdlib_module_identifiers,
+        ),
+
+        # Standard Library Modules for GNU Modula-2
+        'm2pim+gm2': (
+            pim_stdlib_module_identifiers,
+        ),
+
+        # Standard Library Modules for p1 Modula-2
+        'm2iso+p1': (
+            iso_stdlib_module_identifiers,
+        ),
+
+        # Standard Library Modules for XDS Modula-2
+        'm2iso+xds': (
+            iso_stdlib_module_identifiers,
+        ),
+    }
+
+    # Standard Library Types Database
+    stdlib_types_db = {
+        # Empty entry for unknown dialect
+        'unknown': (
+            # LEAVE THIS EMPTY
+        ),
+        # Standard Library Types for PIM Modula-2
+        'm2pim': (
+            pim_stdlib_type_identifiers,
+        ),
+
+        # Standard Library Types for ISO Modula-2
+        'm2iso': (
+            iso_stdlib_type_identifiers,
+        ),
+
+        # Standard Library Types for Modula-2 R10
+        'm2r10': (
+            m2r10_stdlib_type_identifiers,
+        ),
+
+        # Standard Library Types for Objective Modula-2
+        'objm2': (
+            m2r10_stdlib_type_identifiers,
+        ),
+
+        # Standard Library Types for Aglet Modula-2
+        'm2iso+aglet': (
+            iso_stdlib_type_identifiers,
+        ),
+
+        # Standard Library Types for GNU Modula-2
+        'm2pim+gm2': (
+            pim_stdlib_type_identifiers,
+        ),
+
+        # Standard Library Types for p1 Modula-2
+        'm2iso+p1': (
+            iso_stdlib_type_identifiers,
+        ),
+
+        # Standard Library Types for XDS Modula-2
+        'm2iso+xds': (
+            iso_stdlib_type_identifiers,
+        ),
+    }
+
+    # Standard Library Procedures Database
+    stdlib_procedures_db = {
+        # Empty entry for unknown dialect
+        'unknown': (
+            # LEAVE THIS EMPTY
+        ),
+        # Standard Library Procedures for PIM Modula-2
+        'm2pim': (
+            pim_stdlib_proc_identifiers,
+        ),
+
+        # Standard Library Procedures for ISO Modula-2
+        'm2iso': (
+            iso_stdlib_proc_identifiers,
+        ),
+
+        # Standard Library Procedures for Modula-2 R10
+        'm2r10': (
+            m2r10_stdlib_proc_identifiers,
+        ),
+
+        # Standard Library Procedures for Objective Modula-2
+        'objm2': (
+            m2r10_stdlib_proc_identifiers,
+        ),
+
+        # Standard Library Procedures for Aglet Modula-2
+        'm2iso+aglet': (
+            iso_stdlib_proc_identifiers,
+        ),
+
+        # Standard Library Procedures for GNU Modula-2
+        'm2pim+gm2': (
+            pim_stdlib_proc_identifiers,
+        ),
+
+        # Standard Library Procedures for p1 Modula-2
+        'm2iso+p1': (
+            iso_stdlib_proc_identifiers,
+        ),
+
+        # Standard Library Procedures for XDS Modula-2
+        'm2iso+xds': (
+            iso_stdlib_proc_identifiers,
+        ),
+    }
+
+    # Standard Library Variables Database
+    stdlib_variables_db = {
+        # Empty entry for unknown dialect
+        'unknown': (
+            # LEAVE THIS EMPTY
+        ),
+        # Standard Library Variables for PIM Modula-2
+        'm2pim': (
+            pim_stdlib_var_identifiers,
+        ),
+
+        # Standard Library Variables for ISO Modula-2
+        'm2iso': (
+            iso_stdlib_var_identifiers,
+        ),
+
+        # Standard Library Variables for Modula-2 R10
+        'm2r10': (
+            m2r10_stdlib_var_identifiers,
+        ),
+
+        # Standard Library Variables for Objective Modula-2
+        'objm2': (
+            m2r10_stdlib_var_identifiers,
+        ),
+
+        # Standard Library Variables for Aglet Modula-2
+        'm2iso+aglet': (
+            iso_stdlib_var_identifiers,
+        ),
+
+        # Standard Library Variables for GNU Modula-2
+        'm2pim+gm2': (
+            pim_stdlib_var_identifiers,
+        ),
+
+        # Standard Library Variables for p1 Modula-2
+        'm2iso+p1': (
+            iso_stdlib_var_identifiers,
+        ),
+
+        # Standard Library Variables for XDS Modula-2
+        'm2iso+xds': (
+            iso_stdlib_var_identifiers,
+        ),
+    }
+
+    # Standard Library Constants Database
+    stdlib_constants_db = {
+        # Empty entry for unknown dialect
+        'unknown': (
+            # LEAVE THIS EMPTY
+        ),
+        # Standard Library Constants for PIM Modula-2
+        'm2pim': (
+            pim_stdlib_const_identifiers,
+        ),
+
+        # Standard Library Constants for ISO Modula-2
+        'm2iso': (
+            iso_stdlib_const_identifiers,
+        ),
+
+        # Standard Library Constants for Modula-2 R10
+        'm2r10': (
+            m2r10_stdlib_const_identifiers,
+        ),
+
+        # Standard Library Constants for Objective Modula-2
+        'objm2': (
+            m2r10_stdlib_const_identifiers,
+        ),
+
+        # Standard Library Constants for Aglet Modula-2
+        'm2iso+aglet': (
+            iso_stdlib_const_identifiers,
+        ),
+
+        # Standard Library Constants for GNU Modula-2
+        'm2pim+gm2': (
+            pim_stdlib_const_identifiers,
+        ),
+
+        # Standard Library Constants for p1 Modula-2
+        'm2iso+p1': (
+            iso_stdlib_const_identifiers,
+        ),
+
+        # Standard Library Constants for XDS Modula-2
+        'm2iso+xds': (
+            iso_stdlib_const_identifiers,
+        ),
+    }
+
+#   M e t h o d s
+
+    # initialise a lexer instance
+    def __init__(self, **options):
+        #
+        # check dialect options
+        #
+        dialects = get_list_opt(options, 'dialect', [])
+        #
+        for dialect_option in dialects:
+            if dialect_option in self.dialects[1:-1]:
+                # valid dialect option found
+                self.set_dialect(dialect_option)
+                break
+        #
+        # Fallback Mode (DEFAULT)
+        else:
+            # no valid dialect option
+            self.set_dialect('unknown')
+        #
+        self.dialect_set_by_tag = False
+        #
+        # check style options
+        #
+        styles = get_list_opt(options, 'style', [])
+        #
+        # use lowercase mode for Algol style
+        if 'algol' in styles or 'algol_nu' in styles:
+            self.algol_publication_mode = True
+        else:
+            self.algol_publication_mode = False
+        #
+        # Check option flags
+        #
+        self.treat_stdlib_adts_as_builtins = get_bool_opt(
+            options, 'treat_stdlib_adts_as_builtins', True)
+        #
+        # call superclass initialiser
+        RegexLexer.__init__(self, **options)
+
+    # Set lexer to a specified dialect
+    def set_dialect(self, dialect_id):
+        #
+        # if __debug__:
+        #    print 'entered set_dialect with arg: ', dialect_id
+        #
+        # check dialect name against known dialects
+        if dialect_id not in self.dialects:
+            dialect = 'unknown'  # default
+        else:
+            dialect = dialect_id
+        #
+        # compose lexemes to reject set
+        lexemes_to_reject_set = set()
+        # add each list of reject lexemes for this dialect
+        for list in self.lexemes_to_reject_db[dialect]:
+            lexemes_to_reject_set.update(set(list))
+        #
+        # compose reserved words set
+        reswords_set = set()
+        # add each list of reserved words for this dialect
+        for list in self.reserved_words_db[dialect]:
+            reswords_set.update(set(list))
+        #
+        # compose builtins set
+        builtins_set = set()
+        # add each list of builtins for this dialect excluding reserved words
+        for list in self.builtins_db[dialect]:
+            builtins_set.update(set(list).difference(reswords_set))
+        #
+        # compose pseudo-builtins set
+        pseudo_builtins_set = set()
+        # add each list of builtins for this dialect excluding reserved words
+        for list in self.pseudo_builtins_db[dialect]:
+            pseudo_builtins_set.update(set(list).difference(reswords_set))
+        #
+        # compose ADTs set
+        adts_set = set()
+        # add each list of ADTs for this dialect excluding reserved words
+        for list in self.stdlib_adts_db[dialect]:
+            adts_set.update(set(list).difference(reswords_set))
+        #
+        # compose modules set
+        modules_set = set()
+        # add each list of builtins for this dialect excluding builtins
+        for list in self.stdlib_modules_db[dialect]:
+            modules_set.update(set(list).difference(builtins_set))
+        #
+        # compose types set
+        types_set = set()
+        # add each list of types for this dialect excluding builtins
+        for list in self.stdlib_types_db[dialect]:
+            types_set.update(set(list).difference(builtins_set))
+        #
+        # compose procedures set
+        procedures_set = set()
+        # add each list of procedures for this dialect excluding builtins
+        for list in self.stdlib_procedures_db[dialect]:
+            procedures_set.update(set(list).difference(builtins_set))
+        #
+        # compose variables set
+        variables_set = set()
+        # add each list of variables for this dialect excluding builtins
+        for list in self.stdlib_variables_db[dialect]:
+            variables_set.update(set(list).difference(builtins_set))
+        #
+        # compose constants set
+        constants_set = set()
+        # add each list of constants for this dialect excluding builtins
+        for list in self.stdlib_constants_db[dialect]:
+            constants_set.update(set(list).difference(builtins_set))
+        #
+        # update lexer state
+        self.dialect = dialect
+        self.lexemes_to_reject = lexemes_to_reject_set
+        self.reserved_words = reswords_set
+        self.builtins = builtins_set
+        self.pseudo_builtins = pseudo_builtins_set
+        self.adts = adts_set
+        self.modules = modules_set
+        self.types = types_set
+        self.procedures = procedures_set
+        self.variables = variables_set
+        self.constants = constants_set
+        #
+        # if __debug__:
+        #    print 'exiting set_dialect'
+        #    print ' self.dialect: ', self.dialect
+        #    print ' self.lexemes_to_reject: ', self.lexemes_to_reject
+        #    print ' self.reserved_words: ', self.reserved_words
+        #    print ' self.builtins: ', self.builtins
+        #    print ' self.pseudo_builtins: ', self.pseudo_builtins
+        #    print ' self.adts: ', self.adts
+        #    print ' self.modules: ', self.modules
+        #    print ' self.types: ', self.types
+        #    print ' self.procedures: ', self.procedures
+        #    print ' self.variables: ', self.variables
+        #    print ' self.types: ', self.types
+        #    print ' self.constants: ', self.constants
+
+    # Extracts a dialect name from a dialect tag comment string  and checks
+    # the extracted name against known dialects.  If a match is found,  the
+    # matching name is returned, otherwise dialect id 'unknown' is returned
+    def get_dialect_from_dialect_tag(self, dialect_tag):
+        #
+        # if __debug__:
+        #    print 'entered get_dialect_from_dialect_tag with arg: ', dialect_tag
+        #
+        # constants
+        left_tag_delim = '(*!'
+        right_tag_delim = '*)'
+        left_tag_delim_len = len(left_tag_delim)
+        right_tag_delim_len = len(right_tag_delim)
+        indicator_start = left_tag_delim_len
+        indicator_end = -(right_tag_delim_len)
+        #
+        # check comment string for dialect indicator
+        if len(dialect_tag) > (left_tag_delim_len + right_tag_delim_len) \
+           and dialect_tag.startswith(left_tag_delim) \
+           and dialect_tag.endswith(right_tag_delim):
+            #
+            # if __debug__:
+            #    print 'dialect tag found'
+            #
+            # extract dialect indicator
+            indicator = dialect_tag[indicator_start:indicator_end]
+            #
+            # if __debug__:
+            #    print 'extracted: ', indicator
+            #
+            # check against known dialects
+            for index in range(1, len(self.dialects)):
+                #
+                # if __debug__:
+                #    print 'dialects[', index, ']: ', self.dialects[index]
+                #
+                if indicator == self.dialects[index]:
+                    #
+                    # if __debug__:
+                    #    print 'matching dialect found'
+                    #
+                    # indicator matches known dialect
+                    return indicator
+            else:
+                # indicator does not match any dialect
+                return 'unknown'  # default
+        else:
+            # invalid indicator string
+            return 'unknown'  # default
+
+    # intercept the token stream, modify token attributes and return them
+    def get_tokens_unprocessed(self, text):
+        for index, token, value in RegexLexer.get_tokens_unprocessed(self, text):
+            #
+            # check for dialect tag if dialect has not been set by tag
+            if not self.dialect_set_by_tag and token == Comment.Special:
+                indicated_dialect = self.get_dialect_from_dialect_tag(value)
+                if indicated_dialect != 'unknown':
+                    # token is a dialect indicator
+                    # reset reserved words and builtins
+                    self.set_dialect(indicated_dialect)
+                    self.dialect_set_by_tag = True
+            #
+            # check for reserved words, predefined and stdlib identifiers
+            if token is Name:
+                if value in self.reserved_words:
+                    token = Keyword.Reserved
+                    if self.algol_publication_mode:
+                        value = value.lower()
+                #
+                elif value in self.builtins:
+                    token = Name.Builtin
+                    if self.algol_publication_mode:
+                        value = value.lower()
+                #
+                elif value in self.pseudo_builtins:
+                    token = Name.Builtin.Pseudo
+                    if self.algol_publication_mode:
+                        value = value.lower()
+                #
+                elif value in self.adts:
+                    if not self.treat_stdlib_adts_as_builtins:
+                        token = Name.Namespace
+                    else:
+                        token = Name.Builtin.Pseudo
+                        if self.algol_publication_mode:
+                            value = value.lower()
+                #
+                elif value in self.modules:
+                    token = Name.Namespace
+                #
+                elif value in self.types:
+                    token = Name.Class
+                #
+                elif value in self.procedures:
+                    token = Name.Function
+                #
+                elif value in self.variables:
+                    token = Name.Variable
+                #
+                elif value in self.constants:
+                    token = Name.Constant
+            #
+            elif token in Number:
+                #
+                # mark prefix number literals as error for PIM and ISO dialects
+                if self.dialect not in ('unknown', 'm2r10', 'objm2'):
+                    if "'" in value or value[0:2] in ('0b', '0x', '0u'):
+                        token = Error
+                #
+                elif self.dialect in ('m2r10', 'objm2'):
+                    # mark base-8 number literals as errors for M2 R10 and ObjM2
+                    if token is Number.Oct:
+                        token = Error
+                    # mark suffix base-16 literals as errors for M2 R10 and ObjM2
+                    elif token is Number.Hex and 'H' in value:
+                        token = Error
+                    # mark real numbers with E as errors for M2 R10 and ObjM2
+                    elif token is Number.Float and 'E' in value:
+                        token = Error
+            #
+            elif token in Comment:
+                #
+                # mark single line comment as error for PIM and ISO dialects
+                if token is Comment.Single:
+                    if self.dialect not in ('unknown', 'm2r10', 'objm2'):
+                        token = Error
+                #
+                if token is Comment.Preproc:
+                    # mark ISO pragma as error for PIM dialects
+                    if value.startswith('<*') and \
+                       self.dialect.startswith('m2pim'):
+                        token = Error
+                    # mark PIM pragma as comment for other dialects
+                    elif value.startswith('(*$') and \
+                            self.dialect != 'unknown' and \
+                            not self.dialect.startswith('m2pim'):
+                        token = Comment.Multiline
+            #
+            else:  # token is neither Name nor Comment
+                #
+                # mark lexemes matching the dialect's error token set as errors
+                if value in self.lexemes_to_reject:
+                    token = Error
+                #
+                # substitute lexemes when in Algol mode
+                if self.algol_publication_mode:
+                    if value == '#':
+                        value = '≠'
+                    elif value == '<=':
+                        value = '≤'
+                    elif value == '>=':
+                        value = '≥'
+                    elif value == '==':
+                        value = '≡'
+                    elif value == '*.':
+                        value = '•'
+
+            # return result
+            yield index, token, value
+
+    def analyse_text(text):
+        """It's Pascal-like, but does not use FUNCTION -- uses PROCEDURE
+        instead."""
+
+        # Check if this looks like Pascal, if not, bail out early
+        if not ('(*' in text and '*)' in text and ':=' in text):
+            return
+
+        result = 0
+        # Procedure is in Modula2
+        if re.search(r'\bPROCEDURE\b', text):
+            result += 0.6
+
+        # FUNCTION is only valid in Pascal, but not in Modula2
+        if re.search(r'\bFUNCTION\b', text):
+            result = 0.0
+
+        return result
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/mojo.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/mojo.py
new file mode 100644
index 0000000000000000000000000000000000000000..84aac46694607b0f385fc1aec747c3ffcde7ca74
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/mojo.py
@@ -0,0 +1,707 @@
+"""
+    pygments.lexers.mojo
+    ~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for Mojo and related languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import keyword
+
+from pygments import unistring as uni
+from pygments.lexer import (
+    RegexLexer,
+    bygroups,
+    combined,
+    default,
+    include,
+    this,
+    using,
+    words,
+)
+from pygments.token import (
+    Comment,
+    # Error,
+    Keyword,
+    Name,
+    Number,
+    Operator,
+    Punctuation,
+    String,
+    Text,
+    Whitespace,
+)
+from pygments.util import shebang_matches
+
+__all__ = ["MojoLexer"]
+
+
+class MojoLexer(RegexLexer):
+    """
+    For Mojo source code (version 24.2.1).
+    """
+
+    name = "Mojo"
+    url = "https://docs.modular.com/mojo/"
+    aliases = ["mojo", "🔥"]
+    filenames = [
+        "*.mojo",
+        "*.🔥",
+    ]
+    mimetypes = [
+        "text/x-mojo",
+        "application/x-mojo",
+    ]
+    version_added = "2.18"
+
+    uni_name = f"[{uni.xid_start}][{uni.xid_continue}]*"
+
+    def innerstring_rules(ttype):
+        return [
+            # the old style '%s' % (...) string formatting (still valid in Py3)
+            (
+                r"%(\(\w+\))?[-#0 +]*([0-9]+|[*])?(\.([0-9]+|[*]))?"
+                "[hlL]?[E-GXc-giorsaux%]",
+                String.Interpol,
+            ),
+            # the new style '{}'.format(...) string formatting
+            (
+                r"\{"
+                r"((\w+)((\.\w+)|(\[[^\]]+\]))*)?"  # field name
+                r"(\![sra])?"  # conversion
+                r"(\:(.?[<>=\^])?[-+ ]?#?0?(\d+)?,?(\.\d+)?[E-GXb-gnosx%]?)?"
+                r"\}",
+                String.Interpol,
+            ),
+            # backslashes, quotes and formatting signs must be parsed one at a time
+            (r'[^\\\'"%{\n]+', ttype),
+            (r'[\'"\\]', ttype),
+            # unhandled string formatting sign
+            (r"%|(\{{1,2})", ttype),
+            # newlines are an error (use "nl" state)
+        ]
+
+    def fstring_rules(ttype):
+        return [
+            # Assuming that a '}' is the closing brace after format specifier.
+            # Sadly, this means that we won't detect syntax error. But it's
+            # more important to parse correct syntax correctly, than to
+            # highlight invalid syntax.
+            (r"\}", String.Interpol),
+            (r"\{", String.Interpol, "expr-inside-fstring"),
+            # backslashes, quotes and formatting signs must be parsed one at a time
+            (r'[^\\\'"{}\n]+', ttype),
+            (r'[\'"\\]', ttype),
+            # newlines are an error (use "nl" state)
+        ]
+
+    tokens = {
+        "root": [
+            (r"\s+", Whitespace),
+            (
+                r'^(\s*)([rRuUbB]{,2})("""(?:.|\n)*?""")',
+                bygroups(Whitespace, String.Affix, String.Doc),
+            ),
+            (
+                r"^(\s*)([rRuUbB]{,2})('''(?:.|\n)*?''')",
+                bygroups(Whitespace, String.Affix, String.Doc),
+            ),
+            (r"\A#!.+$", Comment.Hashbang),
+            (r"#.*$", Comment.Single),
+            (r"\\\n", Whitespace),
+            (r"\\", Whitespace),
+            include("keywords"),
+            include("soft-keywords"),
+            # In the original PR, all the below here used ((?:\s|\\\s)+) to
+            # designate whitespace, but I can't find any example of this being
+            # needed in the example file, so we're replacing it with `\s+`.
+            (
+                r"(alias)(\s+)",
+                bygroups(Keyword, Whitespace),
+                "varname",  # TODO varname the right fit?
+            ),
+            (r"(var)(\s+)", bygroups(Keyword, Whitespace), "varname"),
+            (r"(def)(\s+)", bygroups(Keyword, Whitespace), "funcname"),
+            (r"(fn)(\s+)", bygroups(Keyword, Whitespace), "funcname"),
+            (
+                r"(class)(\s+)",
+                bygroups(Keyword, Whitespace),
+                "classname",
+            ),  # not implemented yet
+            (r"(struct)(\s+)", bygroups(Keyword, Whitespace), "structname"),
+            (r"(trait)(\s+)", bygroups(Keyword, Whitespace), "structname"),
+            (r"(from)(\s+)", bygroups(Keyword.Namespace, Whitespace), "fromimport"),
+            (r"(import)(\s+)", bygroups(Keyword.Namespace, Whitespace), "import"),
+            include("expr"),
+        ],
+        "expr": [
+            # raw f-strings
+            (
+                '(?i)(rf|fr)(""")',
+                bygroups(String.Affix, String.Double),
+                combined("rfstringescape", "tdqf"),
+            ),
+            (
+                "(?i)(rf|fr)(''')",
+                bygroups(String.Affix, String.Single),
+                combined("rfstringescape", "tsqf"),
+            ),
+            (
+                '(?i)(rf|fr)(")',
+                bygroups(String.Affix, String.Double),
+                combined("rfstringescape", "dqf"),
+            ),
+            (
+                "(?i)(rf|fr)(')",
+                bygroups(String.Affix, String.Single),
+                combined("rfstringescape", "sqf"),
+            ),
+            # non-raw f-strings
+            (
+                '([fF])(""")',
+                bygroups(String.Affix, String.Double),
+                combined("fstringescape", "tdqf"),
+            ),
+            (
+                "([fF])(''')",
+                bygroups(String.Affix, String.Single),
+                combined("fstringescape", "tsqf"),
+            ),
+            (
+                '([fF])(")',
+                bygroups(String.Affix, String.Double),
+                combined("fstringescape", "dqf"),
+            ),
+            (
+                "([fF])(')",
+                bygroups(String.Affix, String.Single),
+                combined("fstringescape", "sqf"),
+            ),
+            # raw bytes and strings
+            ('(?i)(rb|br|r)(""")', bygroups(String.Affix, String.Double), "tdqs"),
+            ("(?i)(rb|br|r)(''')", bygroups(String.Affix, String.Single), "tsqs"),
+            ('(?i)(rb|br|r)(")', bygroups(String.Affix, String.Double), "dqs"),
+            ("(?i)(rb|br|r)(')", bygroups(String.Affix, String.Single), "sqs"),
+            # non-raw strings
+            (
+                '([uU]?)(""")',
+                bygroups(String.Affix, String.Double),
+                combined("stringescape", "tdqs"),
+            ),
+            (
+                "([uU]?)(''')",
+                bygroups(String.Affix, String.Single),
+                combined("stringescape", "tsqs"),
+            ),
+            (
+                '([uU]?)(")',
+                bygroups(String.Affix, String.Double),
+                combined("stringescape", "dqs"),
+            ),
+            (
+                "([uU]?)(')",
+                bygroups(String.Affix, String.Single),
+                combined("stringescape", "sqs"),
+            ),
+            # non-raw bytes
+            (
+                '([bB])(""")',
+                bygroups(String.Affix, String.Double),
+                combined("bytesescape", "tdqs"),
+            ),
+            (
+                "([bB])(''')",
+                bygroups(String.Affix, String.Single),
+                combined("bytesescape", "tsqs"),
+            ),
+            (
+                '([bB])(")',
+                bygroups(String.Affix, String.Double),
+                combined("bytesescape", "dqs"),
+            ),
+            (
+                "([bB])(')",
+                bygroups(String.Affix, String.Single),
+                combined("bytesescape", "sqs"),
+            ),
+            (r"[^\S\n]+", Text),
+            include("numbers"),
+            (r"!=|==|<<|>>|:=|[-~+/*%=<>&^|.]", Operator),
+            (r"([]{}:\(\),;[])+", Punctuation),
+            (r"(in|is|and|or|not)\b", Operator.Word),
+            include("expr-keywords"),
+            include("builtins"),
+            include("magicfuncs"),
+            include("magicvars"),
+            include("name"),
+        ],
+        "expr-inside-fstring": [
+            (r"[{([]", Punctuation, "expr-inside-fstring-inner"),
+            # without format specifier
+            (
+                r"(=\s*)?"  # debug (https://bugs.python.org/issue36817)
+                r"(\![sraf])?"  # conversion
+                r"\}",
+                String.Interpol,
+                "#pop",
+            ),
+            # with format specifier
+            # we'll catch the remaining '}' in the outer scope
+            (
+                r"(=\s*)?"  # debug (https://bugs.python.org/issue36817)
+                r"(\![sraf])?"  # conversion
+                r":",
+                String.Interpol,
+                "#pop",
+            ),
+            (r"\s+", Whitespace),  # allow new lines
+            include("expr"),
+        ],
+        "expr-inside-fstring-inner": [
+            (r"[{([]", Punctuation, "expr-inside-fstring-inner"),
+            (r"[])}]", Punctuation, "#pop"),
+            (r"\s+", Whitespace),  # allow new lines
+            include("expr"),
+        ],
+        "expr-keywords": [
+            # Based on https://docs.python.org/3/reference/expressions.html
+            (
+                words(
+                    (
+                        "async for",  # TODO https://docs.modular.com/mojo/roadmap#no-async-for-or-async-with
+                        "async with",  # TODO https://docs.modular.com/mojo/roadmap#no-async-for-or-async-with
+                        "await",
+                        "else",
+                        "for",
+                        "if",
+                        "lambda",
+                        "yield",
+                        "yield from",
+                    ),
+                    suffix=r"\b",
+                ),
+                Keyword,
+            ),
+            (words(("True", "False", "None"), suffix=r"\b"), Keyword.Constant),
+        ],
+        "keywords": [
+            (
+                words(
+                    (
+                        "assert",
+                        "async",
+                        "await",
+                        "borrowed",
+                        "break",
+                        "continue",
+                        "del",
+                        "elif",
+                        "else",
+                        "except",
+                        "finally",
+                        "for",
+                        "global",
+                        "if",
+                        "lambda",
+                        "pass",
+                        "raise",
+                        "nonlocal",
+                        "return",
+                        "try",
+                        "while",
+                        "yield",
+                        "yield from",
+                        "as",
+                        "with",
+                    ),
+                    suffix=r"\b",
+                ),
+                Keyword,
+            ),
+            (words(("True", "False", "None"), suffix=r"\b"), Keyword.Constant),
+        ],
+        "soft-keywords": [
+            # `match`, `case` and `_` soft keywords
+            (
+                r"(^[ \t]*)"  # at beginning of line + possible indentation
+                r"(match|case)\b"  # a possible keyword
+                r"(?![ \t]*(?:"  # not followed by...
+                r"[:,;=^&|@~)\]}]|(?:" +  # characters and keywords that mean this isn't
+                # pattern matching (but None/True/False is ok)
+                r"|".join(k for k in keyword.kwlist if k[0].islower())
+                + r")\b))",
+                bygroups(Whitespace, Keyword),
+                "soft-keywords-inner",
+            ),
+        ],
+        "soft-keywords-inner": [
+            # optional `_` keyword
+            (r"(\s+)([^\n_]*)(_\b)", bygroups(Whitespace, using(this), Keyword)),
+            default("#pop"),
+        ],
+        "builtins": [
+            (
+                words(
+                    (
+                        "__import__",
+                        "abs",
+                        "aiter",
+                        "all",
+                        "any",
+                        "bin",
+                        "bool",
+                        "bytearray",
+                        "breakpoint",
+                        "bytes",
+                        "callable",
+                        "chr",
+                        "classmethod",
+                        "compile",
+                        "complex",
+                        "delattr",
+                        "dict",
+                        "dir",
+                        "divmod",
+                        "enumerate",
+                        "eval",
+                        "filter",
+                        "float",
+                        "format",
+                        "frozenset",
+                        "getattr",
+                        "globals",
+                        "hasattr",
+                        "hash",
+                        "hex",
+                        "id",
+                        "input",
+                        "int",
+                        "isinstance",
+                        "issubclass",
+                        "iter",
+                        "len",
+                        "list",
+                        "locals",
+                        "map",
+                        "max",
+                        "memoryview",
+                        "min",
+                        "next",
+                        "object",
+                        "oct",
+                        "open",
+                        "ord",
+                        "pow",
+                        "print",
+                        "property",
+                        "range",
+                        "repr",
+                        "reversed",
+                        "round",
+                        "set",
+                        "setattr",
+                        "slice",
+                        "sorted",
+                        "staticmethod",
+                        "str",
+                        "sum",
+                        "super",
+                        "tuple",
+                        "type",
+                        "vars",
+                        "zip",
+                        # Mojo builtin types: https://docs.modular.com/mojo/stdlib/builtin/
+                        "AnyType",
+                        "Coroutine",
+                        "DType",
+                        "Error",
+                        "Int",
+                        "List",
+                        "ListLiteral",
+                        "Scalar",
+                        "Int8",
+                        "UInt8",
+                        "Int16",
+                        "UInt16",
+                        "Int32",
+                        "UInt32",
+                        "Int64",
+                        "UInt64",
+                        "BFloat16",
+                        "Float16",
+                        "Float32",
+                        "Float64",
+                        "SIMD",
+                        "String",
+                        "Tensor",
+                        "Tuple",
+                        "Movable",
+                        "Copyable",
+                        "CollectionElement",
+                    ),
+                    prefix=r"(?>',
+    # Binary augmented
+    '+=', '-=', '*=', '/=', '%=', '**=', '&=', '|=', '^=', '<<=', '>>=',
+    # Comparison
+    '==', '!=', '<', '<=', '>', '>=', '<=>',
+    # Patterns and assignment
+    ':=', '?', '=~', '!~', '=>',
+    # Calls and sends
+    '.', '<-', '->',
+]
+_escape_pattern = (
+    r'(?:\\x[0-9a-fA-F]{2}|\\u[0-9a-fA-F]{4}|\\U[0-9a-fA-F]{8}|'
+    r'\\["\'\\bftnr])')
+# _char = _escape_chars + [('.', String.Char)]
+_identifier = r'[_a-zA-Z]\w*'
+
+_constants = [
+    # Void constants
+    'null',
+    # Bool constants
+    'false', 'true',
+    # Double constants
+    'Infinity', 'NaN',
+    # Special objects
+    'M', 'Ref', 'throw', 'traceln',
+]
+
+_guards = [
+    'Any', 'Binding', 'Bool', 'Bytes', 'Char', 'DeepFrozen', 'Double',
+    'Empty', 'Int', 'List', 'Map', 'Near', 'NullOk', 'Same', 'Selfless',
+    'Set', 'Str', 'SubrangeGuard', 'Transparent', 'Void',
+]
+
+_safeScope = [
+    '_accumulateList', '_accumulateMap', '_auditedBy', '_bind',
+    '_booleanFlow', '_comparer', '_equalizer', '_iterForever', '_loop',
+    '_makeBytes', '_makeDouble', '_makeFinalSlot', '_makeInt', '_makeList',
+    '_makeMap', '_makeMessageDesc', '_makeOrderedSpace', '_makeParamDesc',
+    '_makeProtocolDesc', '_makeSourceSpan', '_makeString', '_makeVarSlot',
+    '_makeVerbFacet', '_mapExtract', '_matchSame', '_quasiMatcher',
+    '_slotToBinding', '_splitList', '_suchThat', '_switchFailed',
+    '_validateFor', 'b__quasiParser', 'eval', 'import', 'm__quasiParser',
+    'makeBrandPair', 'makeLazySlot', 'safeScope', 'simple__quasiParser',
+]
+
+
+class MonteLexer(RegexLexer):
+    """
+    Lexer for the Monte programming language.
+    """
+    name = 'Monte'
+    url = 'https://monte.readthedocs.io/'
+    aliases = ['monte']
+    filenames = ['*.mt']
+    version_added = '2.2'
+
+    tokens = {
+        'root': [
+            # Comments
+            (r'#[^\n]*\n', Comment),
+
+            # Docstrings
+            # Apologies for the non-greedy matcher here.
+            (r'/\*\*.*?\*/', String.Doc),
+
+            # `var` declarations
+            (r'\bvar\b', Keyword.Declaration, 'var'),
+
+            # `interface` declarations
+            (r'\binterface\b', Keyword.Declaration, 'interface'),
+
+            # method declarations
+            (words(_methods, prefix='\\b', suffix='\\b'),
+             Keyword, 'method'),
+
+            # All other declarations
+            (words(_declarations, prefix='\\b', suffix='\\b'),
+             Keyword.Declaration),
+
+            # Keywords
+            (words(_keywords, prefix='\\b', suffix='\\b'), Keyword),
+
+            # Literals
+            ('[+-]?0x[_0-9a-fA-F]+', Number.Hex),
+            (r'[+-]?[_0-9]+\.[_0-9]*([eE][+-]?[_0-9]+)?', Number.Float),
+            ('[+-]?[_0-9]+', Number.Integer),
+            ("'", String.Double, 'char'),
+            ('"', String.Double, 'string'),
+
+            # Quasiliterals
+            ('`', String.Backtick, 'ql'),
+
+            # Operators
+            (words(_operators), Operator),
+
+            # Verb operators
+            (_identifier + '=', Operator.Word),
+
+            # Safe scope constants
+            (words(_constants, prefix='\\b', suffix='\\b'),
+             Keyword.Pseudo),
+
+            # Safe scope guards
+            (words(_guards, prefix='\\b', suffix='\\b'), Keyword.Type),
+
+            # All other safe scope names
+            (words(_safeScope, prefix='\\b', suffix='\\b'),
+             Name.Builtin),
+
+            # Identifiers
+            (_identifier, Name),
+
+            # Punctuation
+            (r'\(|\)|\{|\}|\[|\]|:|,', Punctuation),
+
+            # Whitespace
+            (' +', Whitespace),
+
+            # Definite lexer errors
+            ('=', Error),
+        ],
+        'char': [
+            # It is definitely an error to have a char of width == 0.
+            ("'", Error, 'root'),
+            (_escape_pattern, String.Escape, 'charEnd'),
+            ('.', String.Char, 'charEnd'),
+        ],
+        'charEnd': [
+            ("'", String.Char, '#pop:2'),
+            # It is definitely an error to have a char of width > 1.
+            ('.', Error),
+        ],
+        # The state of things coming into an interface.
+        'interface': [
+            (' +', Whitespace),
+            (_identifier, Name.Class, '#pop'),
+            include('root'),
+        ],
+        # The state of things coming into a method.
+        'method': [
+            (' +', Whitespace),
+            (_identifier, Name.Function, '#pop'),
+            include('root'),
+        ],
+        'string': [
+            ('"', String.Double, 'root'),
+            (_escape_pattern, String.Escape),
+            (r'\n', String.Double),
+            ('.', String.Double),
+        ],
+        'ql': [
+            ('`', String.Backtick, 'root'),
+            (r'\$' + _escape_pattern, String.Escape),
+            (r'\$\$', String.Escape),
+            (r'@@', String.Escape),
+            (r'\$\{', String.Interpol, 'qlNest'),
+            (r'@\{', String.Interpol, 'qlNest'),
+            (r'\$' + _identifier, Name),
+            ('@' + _identifier, Name),
+            ('.', String.Backtick),
+        ],
+        'qlNest': [
+            (r'\}', String.Interpol, '#pop'),
+            include('root'),
+        ],
+        # The state of things immediately following `var`.
+        'var': [
+            (' +', Whitespace),
+            (_identifier, Name.Variable, '#pop'),
+            include('root'),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/mosel.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/mosel.py
new file mode 100644
index 0000000000000000000000000000000000000000..912f478773cb575412a937448e709bef101069e3
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/mosel.py
@@ -0,0 +1,447 @@
+"""
+    pygments.lexers.mosel
+    ~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for the mosel language.
+    http://www.fico.com/en/products/fico-xpress-optimization
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, words
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation
+
+__all__ = ['MoselLexer']
+
+FUNCTIONS = (
+    # core functions
+    '_',
+    'abs',
+    'arctan',
+    'asproc',
+    'assert',
+    'bitflip',
+    'bitneg',
+    'bitset',
+    'bitshift',
+    'bittest',
+    'bitval',
+    'ceil',
+    'cos',
+    'create',
+    'currentdate',
+    'currenttime',
+    'cutelt',
+    'cutfirst',
+    'cuthead',
+    'cutlast',
+    'cuttail',
+    'datablock',
+    'delcell',
+    'exists',
+    'exit',
+    'exp',
+    'exportprob',
+    'fclose',
+    'fflush',
+    'finalize',
+    'findfirst',
+    'findlast',
+    'floor',
+    'fopen',
+    'fselect',
+    'fskipline',
+    'fwrite',
+    'fwrite_',
+    'fwriteln',
+    'fwriteln_',
+    'getact',
+    'getcoeff',
+    'getcoeffs',
+    'getdual',
+    'getelt',
+    'getfid',
+    'getfirst',
+    'getfname',
+    'gethead',
+    'getlast',
+    'getobjval',
+    'getparam',
+    'getrcost',
+    'getreadcnt',
+    'getreverse',
+    'getsize',
+    'getslack',
+    'getsol',
+    'gettail',
+    'gettype',
+    'getvars',
+    'isdynamic',
+    'iseof',
+    'isfinite',
+    'ishidden',
+    'isinf',
+    'isnan',
+    'isodd',
+    'ln',
+    'localsetparam',
+    'log',
+    'makesos1',
+    'makesos2',
+    'maxlist',
+    'memoryuse',
+    'minlist',
+    'newmuid',
+    'publish',
+    'random',
+    'read',
+    'readln',
+    'reset',
+    'restoreparam',
+    'reverse',
+    'round',
+    'setcoeff',
+    'sethidden',
+    'setioerr',
+    'setmatherr',
+    'setname',
+    'setparam',
+    'setrandseed',
+    'setrange',
+    'settype',
+    'sin',
+    'splithead',
+    'splittail',
+    'sqrt',
+    'strfmt',
+    'substr',
+    'timestamp',
+    'unpublish',
+    'versionnum',
+    'versionstr',
+    'write',
+    'write_',
+    'writeln',
+    'writeln_',
+
+    # mosel exam mmxprs | sed -n -e "s/ [pf][a-z]* \([a-zA-Z0-9_]*\).*/'\1',/p" | sort -u
+    'addcut',
+    'addcuts',
+    'addmipsol',
+    'basisstability',
+    'calcsolinfo',
+    'clearmipdir',
+    'clearmodcut',
+    'command',
+    'copysoltoinit',
+    'crossoverlpsol',
+    'defdelayedrows',
+    'defsecurevecs',
+    'delcuts',
+    'dropcuts',
+    'estimatemarginals',
+    'fixglobal',
+    'flushmsgq',
+    'getbstat',
+    'getcnlist',
+    'getcplist',
+    'getdualray',
+    'getiis',
+    'getiissense',
+    'getiistype',
+    'getinfcause',
+    'getinfeas',
+    'getlb',
+    'getlct',
+    'getleft',
+    'getloadedlinctrs',
+    'getloadedmpvars',
+    'getname',
+    'getprimalray',
+    'getprobstat',
+    'getrange',
+    'getright',
+    'getsensrng',
+    'getsize',
+    'getsol',
+    'gettype',
+    'getub',
+    'getvars',
+    'gety',
+    'hasfeature',
+    'implies',
+    'indicator',
+    'initglobal',
+    'ishidden',
+    'isiisvalid',
+    'isintegral',
+    'loadbasis',
+    'loadcuts',
+    'loadlpsol',
+    'loadmipsol',
+    'loadprob',
+    'maximise',
+    'maximize',
+    'minimise',
+    'minimize',
+    'postsolve',
+    'readbasis',
+    'readdirs',
+    'readsol',
+    'refinemipsol',
+    'rejectintsol',
+    'repairinfeas',
+    'repairinfeas_deprec',
+    'resetbasis',
+    'resetiis',
+    'resetsol',
+    'savebasis',
+    'savemipsol',
+    'savesol',
+    'savestate',
+    'selectsol',
+    'setarchconsistency',
+    'setbstat',
+    'setcallback',
+    'setcbcutoff',
+    'setgndata',
+    'sethidden',
+    'setlb',
+    'setmipdir',
+    'setmodcut',
+    'setsol',
+    'setub',
+    'setucbdata',
+    'stopoptimise',
+    'stopoptimize',
+    'storecut',
+    'storecuts',
+    'unloadprob',
+    'uselastbarsol',
+    'writebasis',
+    'writedirs',
+    'writeprob',
+    'writesol',
+    'xor',
+    'xprs_addctr',
+    'xprs_addindic',
+
+    # mosel exam mmsystem | sed -n -e "s/ [pf][a-z]* \([a-zA-Z0-9_]*\).*/'\1',/p" | sort -u
+    'addmonths',
+    'copytext',
+    'cuttext',
+    'deltext',
+    'endswith',
+    'erase',
+    'expandpath',
+    'fcopy',
+    'fdelete',
+    'findfiles',
+    'findtext',
+    'fmove',
+    'formattext',
+    'getasnumber',
+    'getchar',
+    'getcwd',
+    'getdate',
+    'getday',
+    'getdaynum',
+    'getdays',
+    'getdirsep',
+    'getdsoparam',
+    'getendparse',
+    'getenv',
+    'getfsize',
+    'getfstat',
+    'getftime',
+    'gethour',
+    'getminute',
+    'getmonth',
+    'getmsec',
+    'getoserrmsg',
+    'getoserror',
+    'getpathsep',
+    'getqtype',
+    'getsecond',
+    'getsepchar',
+    'getsize',
+    'getstart',
+    'getsucc',
+    'getsysinfo',
+    'getsysstat',
+    'gettime',
+    'gettmpdir',
+    'gettrim',
+    'getweekday',
+    'getyear',
+    'inserttext',
+    'isvalid',
+    'jointext',
+    'makedir',
+    'makepath',
+    'newtar',
+    'newzip',
+    'nextfield',
+    'openpipe',
+    'parseextn',
+    'parseint',
+    'parsereal',
+    'parsetext',
+    'pastetext',
+    'pathmatch',
+    'pathsplit',
+    'qsort',
+    'quote',
+    'readtextline',
+    'regmatch',
+    'regreplace',
+    'removedir',
+    'removefiles',
+    'setchar',
+    'setdate',
+    'setday',
+    'setdsoparam',
+    'setendparse',
+    'setenv',
+    'sethour',
+    'setminute',
+    'setmonth',
+    'setmsec',
+    'setoserror',
+    'setqtype',
+    'setsecond',
+    'setsepchar',
+    'setstart',
+    'setsucc',
+    'settime',
+    'settrim',
+    'setyear',
+    'sleep',
+    'splittext',
+    'startswith',
+    'system',
+    'tarlist',
+    'textfmt',
+    'tolower',
+    'toupper',
+    'trim',
+    'untar',
+    'unzip',
+    'ziplist',
+
+    # mosel exam mmjobs | sed -n -e "s/ [pf][a-z]* \([a-zA-Z0-9_]*\).*/'\1',/p" | sort -u
+    'canceltimer',
+    'clearaliases',
+    'compile',
+    'connect',
+    'detach',
+    'disconnect',
+    'dropnextevent',
+    'findxsrvs',
+    'getaliases',
+    'getannidents',
+    'getannotations',
+    'getbanner',
+    'getclass',
+    'getdsoprop',
+    'getdsopropnum',
+    'getexitcode',
+    'getfromgid',
+    'getfromid',
+    'getfromuid',
+    'getgid',
+    'gethostalias',
+    'getid',
+    'getmodprop',
+    'getmodpropnum',
+    'getnextevent',
+    'getnode',
+    'getrmtid',
+    'getstatus',
+    'getsysinfo',
+    'gettimer',
+    'getuid',
+    'getvalue',
+    'isqueueempty',
+    'load',
+    'nullevent',
+    'peeknextevent',
+    'resetmodpar',
+    'run',
+    'send',
+    'setcontrol',
+    'setdefstream',
+    'setgid',
+    'sethostalias',
+    'setmodpar',
+    'settimer',
+    'setuid',
+    'setworkdir',
+    'stop',
+    'unload',
+    'wait',
+    'waitexpired',
+    'waitfor',
+    'waitforend',
+)
+
+
+class MoselLexer(RegexLexer):
+    """
+    For the Mosel optimization language.
+    """
+    name = 'Mosel'
+    aliases = ['mosel']
+    filenames = ['*.mos']
+    url = 'https://www.fico.com/fico-xpress-optimization/docs/latest/mosel/mosel_lang/dhtml/moselreflang.html'
+    version_added = '2.6'
+
+    tokens = {
+        'root': [
+            (r'\n', Text),
+            (r'\s+', Text.Whitespace),
+            (r'!.*?\n', Comment.Single),
+            (r'\(!(.|\n)*?!\)', Comment.Multiline),
+            (words((
+                'and', 'as', 'break', 'case', 'count', 'declarations', 'do',
+                'dynamic', 'elif', 'else', 'end-', 'end', 'evaluation', 'false',
+                'forall', 'forward', 'from', 'function', 'hashmap', 'if',
+                'imports', 'include', 'initialisations', 'initializations', 'inter',
+                'max', 'min', 'model', 'namespace', 'next', 'not', 'nsgroup',
+                'nssearch', 'of', 'options', 'or', 'package', 'parameters',
+                'procedure', 'public', 'prod', 'record', 'repeat', 'requirements',
+                'return', 'sum', 'then', 'to', 'true', 'union', 'until', 'uses',
+                'version', 'while', 'with'), prefix=r'\b', suffix=r'\b'),
+             Keyword.Builtin),
+            (words((
+                'range', 'array', 'set', 'list', 'mpvar', 'mpproblem', 'linctr',
+                'nlctr', 'integer', 'string', 'real', 'boolean', 'text', 'time',
+                'date', 'datetime', 'returned', 'Model', 'Mosel', 'counter',
+                'xmldoc', 'is_sos1', 'is_sos2', 'is_integer', 'is_binary',
+                'is_continuous', 'is_free', 'is_semcont', 'is_semint',
+                'is_partint'), prefix=r'\b', suffix=r'\b'),
+             Keyword.Type),
+            (r'(\+|\-|\*|/|=|<=|>=|\||\^|<|>|<>|\.\.|\.|:=|::|:|in|mod|div)',
+             Operator),
+            (r'[()\[\]{},;]+', Punctuation),
+            (words(FUNCTIONS,  prefix=r'\b', suffix=r'\b'), Name.Function),
+            (r'(\d+\.(?!\.)\d*|\.(?!.)\d+)([eE][+-]?\d+)?', Number.Float),
+            (r'\d+([eE][+-]?\d+)?', Number.Integer),
+            (r'[+-]?Infinity', Number.Integer),
+            (r'0[xX][0-9a-fA-F]+', Number),
+            (r'"', String.Double, 'double_quote'),
+            (r'\'', String.Single, 'single_quote'),
+            (r'(\w+|(\.(?!\.)))', Text),
+        ],
+        'single_quote': [
+            (r'\'', String.Single, '#pop'),
+            (r'[^\']+', String.Single),
+        ],
+        'double_quote': [
+            (r'(\\"|\\[0-7]{1,3}\D|\\[abfnrtv]|\\\\)', String.Escape),
+            (r'\"', String.Double, '#pop'),
+            (r'[^"\\]+', String.Double),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/ncl.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/ncl.py
new file mode 100644
index 0000000000000000000000000000000000000000..a2729efba6e23c1d9d3ca86c8971649f2e964c17
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/ncl.py
@@ -0,0 +1,894 @@
+"""
+    pygments.lexers.ncl
+    ~~~~~~~~~~~~~~~~~~~
+
+    Lexers for NCAR Command Language.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, include, words
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation
+
+__all__ = ['NCLLexer']
+
+
+class NCLLexer(RegexLexer):
+    """
+    Lexer for NCL code.
+    """
+    name = 'NCL'
+    aliases = ['ncl']
+    filenames = ['*.ncl']
+    mimetypes = ['text/ncl']
+    url = 'https://www.ncl.ucar.edu'
+    version_added = '2.2'
+
+    flags = re.MULTILINE
+
+    tokens = {
+        'root': [
+            (r';.*\n', Comment),
+            include('strings'),
+            include('core'),
+            (r'[a-zA-Z_]\w*', Name),
+            include('nums'),
+            (r'[\s]+', Text),
+        ],
+        'core': [
+            # Statements
+            (words((
+                'begin', 'break', 'continue', 'create', 'defaultapp', 'do',
+                'else', 'end', 'external', 'exit', 'True', 'False', 'file', 'function',
+                'getvalues', 'graphic', 'group', 'if', 'list', 'load', 'local',
+                'new', '_Missing', 'Missing', 'noparent', 'procedure',
+                'quit', 'QUIT', 'Quit', 'record', 'return', 'setvalues', 'stop',
+                'then', 'while'), prefix=r'\b', suffix=r'\s*\b'),
+             Keyword),
+
+            # Data Types
+            (words((
+                'ubyte', 'uint', 'uint64', 'ulong', 'string', 'byte',
+                'character', 'double', 'float', 'integer', 'int64', 'logical',
+                'long', 'short', 'ushort', 'enumeric', 'numeric', 'snumeric'),
+                prefix=r'\b', suffix=r'\s*\b'),
+             Keyword.Type),
+
+            # Operators
+            (r'[\%^*+\-/<>]', Operator),
+
+            # punctuation:
+            (r'[\[\]():@$!&|.,\\{}]', Punctuation),
+            (r'[=:]', Punctuation),
+
+            # Intrinsics
+            (words((
+                'abs', 'acos', 'addfile', 'addfiles', 'all', 'angmom_atm', 'any',
+                'area_conserve_remap', 'area_hi2lores', 'area_poly_sphere',
+                'asciiread', 'asciiwrite', 'asin', 'atan', 'atan2', 'attsetvalues',
+                'avg', 'betainc', 'bin_avg', 'bin_sum', 'bw_bandpass_filter',
+                'cancor', 'cbinread', 'cbinwrite', 'cd_calendar', 'cd_inv_calendar',
+                'cdfbin_p', 'cdfbin_pr', 'cdfbin_s', 'cdfbin_xn', 'cdfchi_p',
+                'cdfchi_x', 'cdfgam_p', 'cdfgam_x', 'cdfnor_p', 'cdfnor_x',
+                'cdft_p', 'cdft_t', 'ceil', 'center_finite_diff',
+                'center_finite_diff_n', 'cfftb', 'cfftf', 'cfftf_frq_reorder',
+                'charactertodouble', 'charactertofloat', 'charactertointeger',
+                'charactertolong', 'charactertoshort', 'charactertostring',
+                'chartodouble', 'chartofloat', 'chartoint', 'chartointeger',
+                'chartolong', 'chartoshort', 'chartostring', 'chiinv', 'clear',
+                'color_index_to_rgba', 'conform', 'conform_dims', 'cos', 'cosh',
+                'count_unique_values', 'covcorm', 'covcorm_xy', 'craybinnumrec',
+                'craybinrecread', 'create_graphic', 'csa1', 'csa1d', 'csa1s',
+                'csa1x', 'csa1xd', 'csa1xs', 'csa2', 'csa2d', 'csa2l', 'csa2ld',
+                'csa2ls', 'csa2lx', 'csa2lxd', 'csa2lxs', 'csa2s', 'csa2x',
+                'csa2xd', 'csa2xs', 'csa3', 'csa3d', 'csa3l', 'csa3ld', 'csa3ls',
+                'csa3lx', 'csa3lxd', 'csa3lxs', 'csa3s', 'csa3x', 'csa3xd',
+                'csa3xs', 'csc2s', 'csgetp', 'css2c', 'cssetp', 'cssgrid', 'csstri',
+                'csvoro', 'cumsum', 'cz2ccm', 'datatondc', 'day_of_week',
+                'day_of_year', 'days_in_month', 'default_fillvalue', 'delete',
+                'depth_to_pres', 'destroy', 'determinant', 'dewtemp_trh',
+                'dgeevx_lapack', 'dim_acumrun_n', 'dim_avg', 'dim_avg_n',
+                'dim_avg_wgt', 'dim_avg_wgt_n', 'dim_cumsum', 'dim_cumsum_n',
+                'dim_gamfit_n', 'dim_gbits', 'dim_max', 'dim_max_n', 'dim_median',
+                'dim_median_n', 'dim_min', 'dim_min_n', 'dim_num', 'dim_num_n',
+                'dim_numrun_n', 'dim_pqsort', 'dim_pqsort_n', 'dim_product',
+                'dim_product_n', 'dim_rmsd', 'dim_rmsd_n', 'dim_rmvmean',
+                'dim_rmvmean_n', 'dim_rmvmed', 'dim_rmvmed_n', 'dim_spi_n',
+                'dim_standardize', 'dim_standardize_n', 'dim_stat4', 'dim_stat4_n',
+                'dim_stddev', 'dim_stddev_n', 'dim_sum', 'dim_sum_n', 'dim_sum_wgt',
+                'dim_sum_wgt_n', 'dim_variance', 'dim_variance_n', 'dimsizes',
+                'doubletobyte', 'doubletochar', 'doubletocharacter',
+                'doubletofloat', 'doubletoint', 'doubletointeger', 'doubletolong',
+                'doubletoshort', 'dpres_hybrid_ccm', 'dpres_plevel', 'draw',
+                'draw_color_palette', 'dsgetp', 'dsgrid2', 'dsgrid2d', 'dsgrid2s',
+                'dsgrid3', 'dsgrid3d', 'dsgrid3s', 'dspnt2', 'dspnt2d', 'dspnt2s',
+                'dspnt3', 'dspnt3d', 'dspnt3s', 'dssetp', 'dtrend', 'dtrend_msg',
+                'dtrend_msg_n', 'dtrend_n', 'dtrend_quadratic',
+                'dtrend_quadratic_msg_n', 'dv2uvf', 'dv2uvg', 'dz_height',
+                'echo_off', 'echo_on', 'eof2data', 'eof_varimax', 'eofcor',
+                'eofcor_pcmsg', 'eofcor_ts', 'eofcov', 'eofcov_pcmsg', 'eofcov_ts',
+                'eofunc', 'eofunc_ts', 'eofunc_varimax', 'equiv_sample_size', 'erf',
+                'erfc', 'esacr', 'esacv', 'esccr', 'esccv', 'escorc', 'escorc_n',
+                'escovc', 'exit', 'exp', 'exp_tapersh', 'exp_tapersh_wgts',
+                'exp_tapershC', 'ezfftb', 'ezfftb_n', 'ezfftf', 'ezfftf_n',
+                'f2fosh', 'f2foshv', 'f2fsh', 'f2fshv', 'f2gsh', 'f2gshv', 'fabs',
+                'fbindirread', 'fbindirwrite', 'fbinnumrec', 'fbinread',
+                'fbinrecread', 'fbinrecwrite', 'fbinwrite', 'fft2db', 'fft2df',
+                'fftshift', 'fileattdef', 'filechunkdimdef', 'filedimdef',
+                'fileexists', 'filegrpdef', 'filevarattdef', 'filevarchunkdef',
+                'filevarcompressleveldef', 'filevardef', 'filevardimsizes',
+                'filwgts_lancos', 'filwgts_lanczos', 'filwgts_normal',
+                'floattobyte', 'floattochar', 'floattocharacter', 'floattoint',
+                'floattointeger', 'floattolong', 'floattoshort', 'floor',
+                'fluxEddy', 'fo2fsh', 'fo2fshv', 'fourier_info', 'frame', 'fspan',
+                'ftcurv', 'ftcurvd', 'ftcurvi', 'ftcurvp', 'ftcurvpi', 'ftcurvps',
+                'ftcurvs', 'ftest', 'ftgetp', 'ftkurv', 'ftkurvd', 'ftkurvp',
+                'ftkurvpd', 'ftsetp', 'ftsurf', 'g2fsh', 'g2fshv', 'g2gsh',
+                'g2gshv', 'gamma', 'gammainc', 'gaus', 'gaus_lobat',
+                'gaus_lobat_wgt', 'gc_aangle', 'gc_clkwise', 'gc_dangle',
+                'gc_inout', 'gc_latlon', 'gc_onarc', 'gc_pnt2gc', 'gc_qarea',
+                'gc_tarea', 'generate_2d_array', 'get_color_index',
+                'get_color_rgba', 'get_cpu_time', 'get_isolines', 'get_ncl_version',
+                'get_script_name', 'get_script_prefix_name', 'get_sphere_radius',
+                'get_unique_values', 'getbitsone', 'getenv', 'getfiledimsizes',
+                'getfilegrpnames', 'getfilepath', 'getfilevaratts',
+                'getfilevarchunkdimsizes', 'getfilevardims', 'getfilevardimsizes',
+                'getfilevarnames', 'getfilevartypes', 'getvaratts', 'getvardims',
+                'gradsf', 'gradsg', 'greg2jul', 'grid2triple', 'hlsrgb', 'hsvrgb',
+                'hydro', 'hyi2hyo', 'idsfft', 'igradsf', 'igradsg', 'ilapsf',
+                'ilapsg', 'ilapvf', 'ilapvg', 'ind', 'ind_resolve', 'int2p',
+                'int2p_n', 'integertobyte', 'integertochar', 'integertocharacter',
+                'integertoshort', 'inttobyte', 'inttochar', 'inttoshort',
+                'inverse_matrix', 'isatt', 'isbigendian', 'isbyte', 'ischar',
+                'iscoord', 'isdefined', 'isdim', 'isdimnamed', 'isdouble',
+                'isenumeric', 'isfile', 'isfilepresent', 'isfilevar',
+                'isfilevaratt', 'isfilevarcoord', 'isfilevardim', 'isfloat',
+                'isfunc', 'isgraphic', 'isint', 'isint64', 'isinteger',
+                'isleapyear', 'islogical', 'islong', 'ismissing', 'isnan_ieee',
+                'isnumeric', 'ispan', 'isproc', 'isshort', 'issnumeric', 'isstring',
+                'isubyte', 'isuint', 'isuint64', 'isulong', 'isunlimited',
+                'isunsigned', 'isushort', 'isvar', 'jul2greg', 'kmeans_as136',
+                'kolsm2_n', 'kron_product', 'lapsf', 'lapsg', 'lapvf', 'lapvg',
+                'latlon2utm', 'lclvl', 'lderuvf', 'lderuvg', 'linint1', 'linint1_n',
+                'linint2', 'linint2_points', 'linmsg', 'linmsg_n', 'linrood_latwgt',
+                'linrood_wgt', 'list_files', 'list_filevars', 'list_hlus',
+                'list_procfuncs', 'list_vars', 'ListAppend', 'ListCount',
+                'ListGetType', 'ListIndex', 'ListIndexFromName', 'ListPop',
+                'ListPush', 'ListSetType', 'loadscript', 'local_max', 'local_min',
+                'log', 'log10', 'longtobyte', 'longtochar', 'longtocharacter',
+                'longtoint', 'longtointeger', 'longtoshort', 'lspoly', 'lspoly_n',
+                'mask', 'max', 'maxind', 'min', 'minind', 'mixed_layer_depth',
+                'mixhum_ptd', 'mixhum_ptrh', 'mjo_cross_coh2pha',
+                'mjo_cross_segment', 'moc_globe_atl', 'monthday', 'natgrid',
+                'natgridd', 'natgrids', 'ncargpath', 'ncargversion', 'ndctodata',
+                'ndtooned', 'new', 'NewList', 'ngezlogo', 'nggcog', 'nggetp',
+                'nglogo', 'ngsetp', 'NhlAddAnnotation', 'NhlAddData',
+                'NhlAddOverlay', 'NhlAddPrimitive', 'NhlAppGetDefaultParentId',
+                'NhlChangeWorkstation', 'NhlClassName', 'NhlClearWorkstation',
+                'NhlDataPolygon', 'NhlDataPolyline', 'NhlDataPolymarker',
+                'NhlDataToNDC', 'NhlDestroy', 'NhlDraw', 'NhlFrame', 'NhlFreeColor',
+                'NhlGetBB', 'NhlGetClassResources', 'NhlGetErrorObjectId',
+                'NhlGetNamedColorIndex', 'NhlGetParentId',
+                'NhlGetParentWorkstation', 'NhlGetWorkspaceObjectId',
+                'NhlIsAllocatedColor', 'NhlIsApp', 'NhlIsDataComm', 'NhlIsDataItem',
+                'NhlIsDataSpec', 'NhlIsTransform', 'NhlIsView', 'NhlIsWorkstation',
+                'NhlName', 'NhlNDCPolygon', 'NhlNDCPolyline', 'NhlNDCPolymarker',
+                'NhlNDCToData', 'NhlNewColor', 'NhlNewDashPattern', 'NhlNewMarker',
+                'NhlPalGetDefined', 'NhlRemoveAnnotation', 'NhlRemoveData',
+                'NhlRemoveOverlay', 'NhlRemovePrimitive', 'NhlSetColor',
+                'NhlSetDashPattern', 'NhlSetMarker', 'NhlUpdateData',
+                'NhlUpdateWorkstation', 'nice_mnmxintvl', 'nngetaspectd',
+                'nngetaspects', 'nngetp', 'nngetsloped', 'nngetslopes', 'nngetwts',
+                'nngetwtsd', 'nnpnt', 'nnpntd', 'nnpntend', 'nnpntendd',
+                'nnpntinit', 'nnpntinitd', 'nnpntinits', 'nnpnts', 'nnsetp', 'num',
+                'obj_anal_ic', 'omega_ccm', 'onedtond', 'overlay', 'paleo_outline',
+                'pdfxy_bin', 'poisson_grid_fill', 'pop_remap', 'potmp_insitu_ocn',
+                'prcwater_dp', 'pres2hybrid', 'pres_hybrid_ccm', 'pres_sigma',
+                'print', 'print_table', 'printFileVarSummary', 'printVarSummary',
+                'product', 'pslec', 'pslhor', 'pslhyp', 'qsort', 'rand',
+                'random_chi', 'random_gamma', 'random_normal', 'random_setallseed',
+                'random_uniform', 'rcm2points', 'rcm2rgrid', 'rdsstoi',
+                'read_colormap_file', 'reg_multlin', 'regcoef', 'regCoef_n',
+                'regline', 'relhum', 'replace_ieeenan', 'reshape', 'reshape_ind',
+                'rgba_to_color_index', 'rgbhls', 'rgbhsv', 'rgbyiq', 'rgrid2rcm',
+                'rhomb_trunc', 'rip_cape_2d', 'rip_cape_3d', 'round', 'rtest',
+                'runave', 'runave_n', 'set_default_fillvalue', 'set_sphere_radius',
+                'setfileoption', 'sfvp2uvf', 'sfvp2uvg', 'shaec', 'shagc',
+                'shgetnp', 'shgetp', 'shgrid', 'shorttobyte', 'shorttochar',
+                'shorttocharacter', 'show_ascii', 'shsec', 'shsetp', 'shsgc',
+                'shsgc_R42', 'sigma2hybrid', 'simpeq', 'simpne', 'sin',
+                'sindex_yrmo', 'sinh', 'sizeof', 'sleep', 'smth9', 'snindex_yrmo',
+                'solve_linsys', 'span_color_indexes', 'span_color_rgba',
+                'sparse_matrix_mult', 'spcorr', 'spcorr_n', 'specx_anal',
+                'specxy_anal', 'spei', 'sprintf', 'sprinti', 'sqrt', 'sqsort',
+                'srand', 'stat2', 'stat4', 'stat_medrng', 'stat_trim',
+                'status_exit', 'stdatmus_p2tdz', 'stdatmus_z2tdp', 'stddev',
+                'str_capital', 'str_concat', 'str_fields_count', 'str_get_cols',
+                'str_get_dq', 'str_get_field', 'str_get_nl', 'str_get_sq',
+                'str_get_tab', 'str_index_of_substr', 'str_insert', 'str_is_blank',
+                'str_join', 'str_left_strip', 'str_lower', 'str_match',
+                'str_match_ic', 'str_match_ic_regex', 'str_match_ind',
+                'str_match_ind_ic', 'str_match_ind_ic_regex', 'str_match_ind_regex',
+                'str_match_regex', 'str_right_strip', 'str_split',
+                'str_split_by_length', 'str_split_csv', 'str_squeeze', 'str_strip',
+                'str_sub_str', 'str_switch', 'str_upper', 'stringtochar',
+                'stringtocharacter', 'stringtodouble', 'stringtofloat',
+                'stringtoint', 'stringtointeger', 'stringtolong', 'stringtoshort',
+                'strlen', 'student_t', 'sum', 'svd_lapack', 'svdcov', 'svdcov_sv',
+                'svdstd', 'svdstd_sv', 'system', 'systemfunc', 'tan', 'tanh',
+                'taper', 'taper_n', 'tdclrs', 'tdctri', 'tdcudp', 'tdcurv',
+                'tddtri', 'tdez2d', 'tdez3d', 'tdgetp', 'tdgrds', 'tdgrid',
+                'tdgtrs', 'tdinit', 'tditri', 'tdlbla', 'tdlblp', 'tdlbls',
+                'tdline', 'tdlndp', 'tdlnpa', 'tdlpdp', 'tdmtri', 'tdotri',
+                'tdpara', 'tdplch', 'tdprpa', 'tdprpi', 'tdprpt', 'tdsetp',
+                'tdsort', 'tdstri', 'tdstrs', 'tdttri', 'thornthwaite', 'tobyte',
+                'tochar', 'todouble', 'tofloat', 'toint', 'toint64', 'tointeger',
+                'tolong', 'toshort', 'tosigned', 'tostring', 'tostring_with_format',
+                'totype', 'toubyte', 'touint', 'touint64', 'toulong', 'tounsigned',
+                'toushort', 'trend_manken', 'tri_trunc', 'triple2grid',
+                'triple2grid2d', 'trop_wmo', 'ttest', 'typeof', 'undef',
+                'unique_string', 'update', 'ushorttoint', 'ut_calendar',
+                'ut_inv_calendar', 'utm2latlon', 'uv2dv_cfd', 'uv2dvf', 'uv2dvg',
+                'uv2sfvpf', 'uv2sfvpg', 'uv2vr_cfd', 'uv2vrdvf', 'uv2vrdvg',
+                'uv2vrf', 'uv2vrg', 'v5d_close', 'v5d_create', 'v5d_setLowLev',
+                'v5d_setUnits', 'v5d_write', 'v5d_write_var', 'variance', 'vhaec',
+                'vhagc', 'vhsec', 'vhsgc', 'vibeta', 'vinth2p', 'vinth2p_ecmwf',
+                'vinth2p_ecmwf_nodes', 'vinth2p_nodes', 'vintp2p_ecmwf', 'vr2uvf',
+                'vr2uvg', 'vrdv2uvf', 'vrdv2uvg', 'wavelet', 'wavelet_default',
+                'weibull', 'wgt_area_smooth', 'wgt_areaave', 'wgt_areaave2',
+                'wgt_arearmse', 'wgt_arearmse2', 'wgt_areasum2', 'wgt_runave',
+                'wgt_runave_n', 'wgt_vert_avg_beta', 'wgt_volave', 'wgt_volave_ccm',
+                'wgt_volrmse', 'wgt_volrmse_ccm', 'where', 'wk_smooth121', 'wmbarb',
+                'wmbarbmap', 'wmdrft', 'wmgetp', 'wmlabs', 'wmsetp', 'wmstnm',
+                'wmvect', 'wmvectmap', 'wmvlbl', 'wrf_avo', 'wrf_cape_2d',
+                'wrf_cape_3d', 'wrf_dbz', 'wrf_eth', 'wrf_helicity', 'wrf_ij_to_ll',
+                'wrf_interp_1d', 'wrf_interp_2d_xy', 'wrf_interp_3d_z',
+                'wrf_latlon_to_ij', 'wrf_ll_to_ij', 'wrf_omega', 'wrf_pvo',
+                'wrf_rh', 'wrf_slp', 'wrf_smooth_2d', 'wrf_td', 'wrf_tk',
+                'wrf_updraft_helicity', 'wrf_uvmet', 'wrf_virtual_temp',
+                'wrf_wetbulb', 'wrf_wps_close_int', 'wrf_wps_open_int',
+                'wrf_wps_rddata_int', 'wrf_wps_rdhead_int', 'wrf_wps_read_int',
+                'wrf_wps_write_int', 'write_matrix', 'write_table', 'yiqrgb',
+                'z2geouv', 'zonal_mpsi', 'addfiles_GetVar', 'advect_variable',
+                'area_conserve_remap_Wrap', 'area_hi2lores_Wrap',
+                'array_append_record', 'assignFillValue', 'byte2flt',
+                'byte2flt_hdf', 'calcDayAnomTLL', 'calcMonAnomLLLT',
+                'calcMonAnomLLT', 'calcMonAnomTLL', 'calcMonAnomTLLL',
+                'calculate_monthly_values', 'cd_convert', 'changeCase',
+                'changeCaseChar', 'clmDayTLL', 'clmDayTLLL', 'clmMon2clmDay',
+                'clmMonLLLT', 'clmMonLLT', 'clmMonTLL', 'clmMonTLLL', 'closest_val',
+                'copy_VarAtts', 'copy_VarCoords', 'copy_VarCoords_1',
+                'copy_VarCoords_2', 'copy_VarMeta', 'copyatt', 'crossp3',
+                'cshstringtolist', 'cssgrid_Wrap', 'dble2flt', 'decimalPlaces',
+                'delete_VarAtts', 'dim_avg_n_Wrap', 'dim_avg_wgt_n_Wrap',
+                'dim_avg_wgt_Wrap', 'dim_avg_Wrap', 'dim_cumsum_n_Wrap',
+                'dim_cumsum_Wrap', 'dim_max_n_Wrap', 'dim_min_n_Wrap',
+                'dim_rmsd_n_Wrap', 'dim_rmsd_Wrap', 'dim_rmvmean_n_Wrap',
+                'dim_rmvmean_Wrap', 'dim_rmvmed_n_Wrap', 'dim_rmvmed_Wrap',
+                'dim_standardize_n_Wrap', 'dim_standardize_Wrap',
+                'dim_stddev_n_Wrap', 'dim_stddev_Wrap', 'dim_sum_n_Wrap',
+                'dim_sum_wgt_n_Wrap', 'dim_sum_wgt_Wrap', 'dim_sum_Wrap',
+                'dim_variance_n_Wrap', 'dim_variance_Wrap', 'dpres_plevel_Wrap',
+                'dtrend_leftdim', 'dv2uvF_Wrap', 'dv2uvG_Wrap', 'eof_north',
+                'eofcor_Wrap', 'eofcov_Wrap', 'eofunc_north', 'eofunc_ts_Wrap',
+                'eofunc_varimax_reorder', 'eofunc_varimax_Wrap', 'eofunc_Wrap',
+                'epsZero', 'f2fosh_Wrap', 'f2foshv_Wrap', 'f2fsh_Wrap',
+                'f2fshv_Wrap', 'f2gsh_Wrap', 'f2gshv_Wrap', 'fbindirSwap',
+                'fbinseqSwap1', 'fbinseqSwap2', 'flt2dble', 'flt2string',
+                'fo2fsh_Wrap', 'fo2fshv_Wrap', 'g2fsh_Wrap', 'g2fshv_Wrap',
+                'g2gsh_Wrap', 'g2gshv_Wrap', 'generate_resample_indices',
+                'generate_sample_indices', 'generate_unique_indices',
+                'genNormalDist', 'get1Dindex', 'get1Dindex_Collapse',
+                'get1Dindex_Exclude', 'get_file_suffix', 'GetFillColor',
+                'GetFillColorIndex', 'getFillValue', 'getind_latlon2d',
+                'getVarDimNames', 'getVarFillValue', 'grib_stime2itime',
+                'hyi2hyo_Wrap', 'ilapsF_Wrap', 'ilapsG_Wrap', 'ind_nearest_coord',
+                'indStrSubset', 'int2dble', 'int2flt', 'int2p_n_Wrap', 'int2p_Wrap',
+                'isMonotonic', 'isStrSubset', 'latGau', 'latGauWgt', 'latGlobeF',
+                'latGlobeFo', 'latRegWgt', 'linint1_n_Wrap', 'linint1_Wrap',
+                'linint2_points_Wrap', 'linint2_Wrap', 'local_max_1d',
+                'local_min_1d', 'lonFlip', 'lonGlobeF', 'lonGlobeFo', 'lonPivot',
+                'merge_levels_sfc', 'mod', 'month_to_annual',
+                'month_to_annual_weighted', 'month_to_season', 'month_to_season12',
+                'month_to_seasonN', 'monthly_total_to_daily_mean', 'nameDim',
+                'natgrid_Wrap', 'NewCosWeight', 'niceLatLon2D', 'NormCosWgtGlobe',
+                'numAsciiCol', 'numAsciiRow', 'numeric2int',
+                'obj_anal_ic_deprecated', 'obj_anal_ic_Wrap', 'omega_ccm_driver',
+                'omega_to_w', 'oneDtostring', 'pack_values', 'pattern_cor', 'pdfx',
+                'pdfxy', 'pdfxy_conform', 'pot_temp', 'pot_vort_hybrid',
+                'pot_vort_isobaric', 'pres2hybrid_Wrap', 'print_clock',
+                'printMinMax', 'quadroots', 'rcm2points_Wrap', 'rcm2rgrid_Wrap',
+                'readAsciiHead', 'readAsciiTable', 'reg_multlin_stats',
+                'region_ind', 'regline_stats', 'relhum_ttd', 'replaceSingleChar',
+                'RGBtoCmap', 'rgrid2rcm_Wrap', 'rho_mwjf', 'rm_single_dims',
+                'rmAnnCycle1D', 'rmInsufData', 'rmMonAnnCycLLLT', 'rmMonAnnCycLLT',
+                'rmMonAnnCycTLL', 'runave_n_Wrap', 'runave_Wrap', 'short2flt',
+                'short2flt_hdf', 'shsgc_R42_Wrap', 'sign_f90', 'sign_matlab',
+                'smth9_Wrap', 'smthClmDayTLL', 'smthClmDayTLLL', 'SqrtCosWeight',
+                'stat_dispersion', 'static_stability', 'stdMonLLLT', 'stdMonLLT',
+                'stdMonTLL', 'stdMonTLLL', 'symMinMaxPlt', 'table_attach_columns',
+                'table_attach_rows', 'time_to_newtime', 'transpose',
+                'triple2grid_Wrap', 'ut_convert', 'uv2dvF_Wrap', 'uv2dvG_Wrap',
+                'uv2vrF_Wrap', 'uv2vrG_Wrap', 'vr2uvF_Wrap', 'vr2uvG_Wrap',
+                'w_to_omega', 'wallClockElapseTime', 'wave_number_spc',
+                'wgt_areaave_Wrap', 'wgt_runave_leftdim', 'wgt_runave_n_Wrap',
+                'wgt_runave_Wrap', 'wgt_vertical_n', 'wind_component',
+                'wind_direction', 'yyyyddd_to_yyyymmdd', 'yyyymm_time',
+                'yyyymm_to_yyyyfrac', 'yyyymmdd_time', 'yyyymmdd_to_yyyyddd',
+                'yyyymmdd_to_yyyyfrac', 'yyyymmddhh_time', 'yyyymmddhh_to_yyyyfrac',
+                'zonal_mpsi_Wrap', 'zonalAve', 'calendar_decode2', 'cd_string',
+                'kf_filter', 'run_cor', 'time_axis_labels', 'ut_string',
+                'wrf_contour', 'wrf_map', 'wrf_map_overlay', 'wrf_map_overlays',
+                'wrf_map_resources', 'wrf_map_zoom', 'wrf_overlay', 'wrf_overlays',
+                'wrf_user_getvar', 'wrf_user_ij_to_ll', 'wrf_user_intrp2d',
+                'wrf_user_intrp3d', 'wrf_user_latlon_to_ij', 'wrf_user_list_times',
+                'wrf_user_ll_to_ij', 'wrf_user_unstagger', 'wrf_user_vert_interp',
+                'wrf_vector', 'gsn_add_annotation', 'gsn_add_polygon',
+                'gsn_add_polyline', 'gsn_add_polymarker',
+                'gsn_add_shapefile_polygons', 'gsn_add_shapefile_polylines',
+                'gsn_add_shapefile_polymarkers', 'gsn_add_text', 'gsn_attach_plots',
+                'gsn_blank_plot', 'gsn_contour', 'gsn_contour_map',
+                'gsn_contour_shade', 'gsn_coordinates', 'gsn_create_labelbar',
+                'gsn_create_legend', 'gsn_create_text',
+                'gsn_csm_attach_zonal_means', 'gsn_csm_blank_plot',
+                'gsn_csm_contour', 'gsn_csm_contour_map', 'gsn_csm_contour_map_ce',
+                'gsn_csm_contour_map_overlay', 'gsn_csm_contour_map_polar',
+                'gsn_csm_hov', 'gsn_csm_lat_time', 'gsn_csm_map', 'gsn_csm_map_ce',
+                'gsn_csm_map_polar', 'gsn_csm_pres_hgt',
+                'gsn_csm_pres_hgt_streamline', 'gsn_csm_pres_hgt_vector',
+                'gsn_csm_streamline', 'gsn_csm_streamline_contour_map',
+                'gsn_csm_streamline_contour_map_ce',
+                'gsn_csm_streamline_contour_map_polar', 'gsn_csm_streamline_map',
+                'gsn_csm_streamline_map_ce', 'gsn_csm_streamline_map_polar',
+                'gsn_csm_streamline_scalar', 'gsn_csm_streamline_scalar_map',
+                'gsn_csm_streamline_scalar_map_ce',
+                'gsn_csm_streamline_scalar_map_polar', 'gsn_csm_time_lat',
+                'gsn_csm_vector', 'gsn_csm_vector_map', 'gsn_csm_vector_map_ce',
+                'gsn_csm_vector_map_polar', 'gsn_csm_vector_scalar',
+                'gsn_csm_vector_scalar_map', 'gsn_csm_vector_scalar_map_ce',
+                'gsn_csm_vector_scalar_map_polar', 'gsn_csm_x2y', 'gsn_csm_x2y2',
+                'gsn_csm_xy', 'gsn_csm_xy2', 'gsn_csm_xy3', 'gsn_csm_y',
+                'gsn_define_colormap', 'gsn_draw_colormap', 'gsn_draw_named_colors',
+                'gsn_histogram', 'gsn_labelbar_ndc', 'gsn_legend_ndc', 'gsn_map',
+                'gsn_merge_colormaps', 'gsn_open_wks', 'gsn_panel', 'gsn_polygon',
+                'gsn_polygon_ndc', 'gsn_polyline', 'gsn_polyline_ndc',
+                'gsn_polymarker', 'gsn_polymarker_ndc', 'gsn_retrieve_colormap',
+                'gsn_reverse_colormap', 'gsn_streamline', 'gsn_streamline_map',
+                'gsn_streamline_scalar', 'gsn_streamline_scalar_map', 'gsn_table',
+                'gsn_text', 'gsn_text_ndc', 'gsn_vector', 'gsn_vector_map',
+                'gsn_vector_scalar', 'gsn_vector_scalar_map', 'gsn_xy', 'gsn_y',
+                'hsv2rgb', 'maximize_output', 'namedcolor2rgb', 'namedcolor2rgba',
+                'reset_device_coordinates', 'span_named_colors'), prefix=r'\b'),
+             Name.Builtin),
+
+            # Resources
+            (words((
+                'amDataXF', 'amDataYF', 'amJust', 'amOn', 'amOrthogonalPosF',
+                'amParallelPosF', 'amResizeNotify', 'amSide', 'amTrackData',
+                'amViewId', 'amZone', 'appDefaultParent', 'appFileSuffix',
+                'appResources', 'appSysDir', 'appUsrDir', 'caCopyArrays',
+                'caXArray', 'caXCast', 'caXMaxV', 'caXMinV', 'caXMissingV',
+                'caYArray', 'caYCast', 'caYMaxV', 'caYMinV', 'caYMissingV',
+                'cnCellFillEdgeColor', 'cnCellFillMissingValEdgeColor',
+                'cnConpackParams', 'cnConstFEnableFill', 'cnConstFLabelAngleF',
+                'cnConstFLabelBackgroundColor', 'cnConstFLabelConstantSpacingF',
+                'cnConstFLabelFont', 'cnConstFLabelFontAspectF',
+                'cnConstFLabelFontColor', 'cnConstFLabelFontHeightF',
+                'cnConstFLabelFontQuality', 'cnConstFLabelFontThicknessF',
+                'cnConstFLabelFormat', 'cnConstFLabelFuncCode', 'cnConstFLabelJust',
+                'cnConstFLabelOn', 'cnConstFLabelOrthogonalPosF',
+                'cnConstFLabelParallelPosF', 'cnConstFLabelPerimColor',
+                'cnConstFLabelPerimOn', 'cnConstFLabelPerimSpaceF',
+                'cnConstFLabelPerimThicknessF', 'cnConstFLabelSide',
+                'cnConstFLabelString', 'cnConstFLabelTextDirection',
+                'cnConstFLabelZone', 'cnConstFUseInfoLabelRes',
+                'cnExplicitLabelBarLabelsOn', 'cnExplicitLegendLabelsOn',
+                'cnExplicitLineLabelsOn', 'cnFillBackgroundColor', 'cnFillColor',
+                'cnFillColors', 'cnFillDotSizeF', 'cnFillDrawOrder', 'cnFillMode',
+                'cnFillOn', 'cnFillOpacityF', 'cnFillPalette', 'cnFillPattern',
+                'cnFillPatterns', 'cnFillScaleF', 'cnFillScales', 'cnFixFillBleed',
+                'cnGridBoundFillColor', 'cnGridBoundFillPattern',
+                'cnGridBoundFillScaleF', 'cnGridBoundPerimColor',
+                'cnGridBoundPerimDashPattern', 'cnGridBoundPerimOn',
+                'cnGridBoundPerimThicknessF', 'cnHighLabelAngleF',
+                'cnHighLabelBackgroundColor', 'cnHighLabelConstantSpacingF',
+                'cnHighLabelCount', 'cnHighLabelFont', 'cnHighLabelFontAspectF',
+                'cnHighLabelFontColor', 'cnHighLabelFontHeightF',
+                'cnHighLabelFontQuality', 'cnHighLabelFontThicknessF',
+                'cnHighLabelFormat', 'cnHighLabelFuncCode', 'cnHighLabelPerimColor',
+                'cnHighLabelPerimOn', 'cnHighLabelPerimSpaceF',
+                'cnHighLabelPerimThicknessF', 'cnHighLabelString', 'cnHighLabelsOn',
+                'cnHighLowLabelOverlapMode', 'cnHighUseLineLabelRes',
+                'cnInfoLabelAngleF', 'cnInfoLabelBackgroundColor',
+                'cnInfoLabelConstantSpacingF', 'cnInfoLabelFont',
+                'cnInfoLabelFontAspectF', 'cnInfoLabelFontColor',
+                'cnInfoLabelFontHeightF', 'cnInfoLabelFontQuality',
+                'cnInfoLabelFontThicknessF', 'cnInfoLabelFormat',
+                'cnInfoLabelFuncCode', 'cnInfoLabelJust', 'cnInfoLabelOn',
+                'cnInfoLabelOrthogonalPosF', 'cnInfoLabelParallelPosF',
+                'cnInfoLabelPerimColor', 'cnInfoLabelPerimOn',
+                'cnInfoLabelPerimSpaceF', 'cnInfoLabelPerimThicknessF',
+                'cnInfoLabelSide', 'cnInfoLabelString', 'cnInfoLabelTextDirection',
+                'cnInfoLabelZone', 'cnLabelBarEndLabelsOn', 'cnLabelBarEndStyle',
+                'cnLabelDrawOrder', 'cnLabelMasking', 'cnLabelScaleFactorF',
+                'cnLabelScaleValueF', 'cnLabelScalingMode', 'cnLegendLevelFlags',
+                'cnLevelCount', 'cnLevelFlag', 'cnLevelFlags', 'cnLevelSelectionMode',
+                'cnLevelSpacingF', 'cnLevels', 'cnLineColor', 'cnLineColors',
+                'cnLineDashPattern', 'cnLineDashPatterns', 'cnLineDashSegLenF',
+                'cnLineDrawOrder', 'cnLineLabelAngleF', 'cnLineLabelBackgroundColor',
+                'cnLineLabelConstantSpacingF', 'cnLineLabelCount',
+                'cnLineLabelDensityF', 'cnLineLabelFont', 'cnLineLabelFontAspectF',
+                'cnLineLabelFontColor', 'cnLineLabelFontColors',
+                'cnLineLabelFontHeightF', 'cnLineLabelFontQuality',
+                'cnLineLabelFontThicknessF', 'cnLineLabelFormat',
+                'cnLineLabelFuncCode', 'cnLineLabelInterval', 'cnLineLabelPerimColor',
+                'cnLineLabelPerimOn', 'cnLineLabelPerimSpaceF',
+                'cnLineLabelPerimThicknessF', 'cnLineLabelPlacementMode',
+                'cnLineLabelStrings', 'cnLineLabelsOn', 'cnLinePalette',
+                'cnLineThicknessF', 'cnLineThicknesses', 'cnLinesOn',
+                'cnLowLabelAngleF', 'cnLowLabelBackgroundColor',
+                'cnLowLabelConstantSpacingF', 'cnLowLabelCount', 'cnLowLabelFont',
+                'cnLowLabelFontAspectF', 'cnLowLabelFontColor',
+                'cnLowLabelFontHeightF', 'cnLowLabelFontQuality',
+                'cnLowLabelFontThicknessF', 'cnLowLabelFormat', 'cnLowLabelFuncCode',
+                'cnLowLabelPerimColor', 'cnLowLabelPerimOn', 'cnLowLabelPerimSpaceF',
+                'cnLowLabelPerimThicknessF', 'cnLowLabelString', 'cnLowLabelsOn',
+                'cnLowUseHighLabelRes', 'cnMaxDataValueFormat', 'cnMaxLevelCount',
+                'cnMaxLevelValF', 'cnMaxPointDistanceF', 'cnMinLevelValF',
+                'cnMissingValFillColor', 'cnMissingValFillPattern',
+                'cnMissingValFillScaleF', 'cnMissingValPerimColor',
+                'cnMissingValPerimDashPattern', 'cnMissingValPerimGridBoundOn',
+                'cnMissingValPerimOn', 'cnMissingValPerimThicknessF',
+                'cnMonoFillColor', 'cnMonoFillPattern', 'cnMonoFillScale',
+                'cnMonoLevelFlag', 'cnMonoLineColor', 'cnMonoLineDashPattern',
+                'cnMonoLineLabelFontColor', 'cnMonoLineThickness', 'cnNoDataLabelOn',
+                'cnNoDataLabelString', 'cnOutOfRangeFillColor',
+                'cnOutOfRangeFillPattern', 'cnOutOfRangeFillScaleF',
+                'cnOutOfRangePerimColor', 'cnOutOfRangePerimDashPattern',
+                'cnOutOfRangePerimOn', 'cnOutOfRangePerimThicknessF',
+                'cnRasterCellSizeF', 'cnRasterMinCellSizeF', 'cnRasterModeOn',
+                'cnRasterSampleFactorF', 'cnRasterSmoothingOn', 'cnScalarFieldData',
+                'cnSmoothingDistanceF', 'cnSmoothingOn', 'cnSmoothingTensionF',
+                'cnSpanFillPalette', 'cnSpanLinePalette', 'ctCopyTables',
+                'ctXElementSize', 'ctXMaxV', 'ctXMinV', 'ctXMissingV', 'ctXTable',
+                'ctXTableLengths', 'ctXTableType', 'ctYElementSize', 'ctYMaxV',
+                'ctYMinV', 'ctYMissingV', 'ctYTable', 'ctYTableLengths',
+                'ctYTableType', 'dcDelayCompute', 'errBuffer',
+                'errFileName', 'errFilePtr', 'errLevel', 'errPrint', 'errUnitNumber',
+                'gsClipOn', 'gsColors', 'gsEdgeColor', 'gsEdgeDashPattern',
+                'gsEdgeDashSegLenF', 'gsEdgeThicknessF', 'gsEdgesOn',
+                'gsFillBackgroundColor', 'gsFillColor', 'gsFillDotSizeF',
+                'gsFillIndex', 'gsFillLineThicknessF', 'gsFillOpacityF',
+                'gsFillScaleF', 'gsFont', 'gsFontAspectF', 'gsFontColor',
+                'gsFontHeightF', 'gsFontOpacityF', 'gsFontQuality',
+                'gsFontThicknessF', 'gsLineColor', 'gsLineDashPattern',
+                'gsLineDashSegLenF', 'gsLineLabelConstantSpacingF', 'gsLineLabelFont',
+                'gsLineLabelFontAspectF', 'gsLineLabelFontColor',
+                'gsLineLabelFontHeightF', 'gsLineLabelFontQuality',
+                'gsLineLabelFontThicknessF', 'gsLineLabelFuncCode',
+                'gsLineLabelString', 'gsLineOpacityF', 'gsLineThicknessF',
+                'gsMarkerColor', 'gsMarkerIndex', 'gsMarkerOpacityF', 'gsMarkerSizeF',
+                'gsMarkerThicknessF', 'gsSegments', 'gsTextAngleF',
+                'gsTextConstantSpacingF', 'gsTextDirection', 'gsTextFuncCode',
+                'gsTextJustification', 'gsnAboveYRefLineBarColors',
+                'gsnAboveYRefLineBarFillScales', 'gsnAboveYRefLineBarPatterns',
+                'gsnAboveYRefLineColor', 'gsnAddCyclic', 'gsnAttachBorderOn',
+                'gsnAttachPlotsXAxis', 'gsnBelowYRefLineBarColors',
+                'gsnBelowYRefLineBarFillScales', 'gsnBelowYRefLineBarPatterns',
+                'gsnBelowYRefLineColor', 'gsnBoxMargin', 'gsnCenterString',
+                'gsnCenterStringFontColor', 'gsnCenterStringFontHeightF',
+                'gsnCenterStringFuncCode', 'gsnCenterStringOrthogonalPosF',
+                'gsnCenterStringParallelPosF', 'gsnContourLineThicknessesScale',
+                'gsnContourNegLineDashPattern', 'gsnContourPosLineDashPattern',
+                'gsnContourZeroLineThicknessF', 'gsnDebugWriteFileName', 'gsnDraw',
+                'gsnFrame', 'gsnHistogramBarWidthPercent', 'gsnHistogramBinIntervals',
+                'gsnHistogramBinMissing', 'gsnHistogramBinWidth',
+                'gsnHistogramClassIntervals', 'gsnHistogramCompare',
+                'gsnHistogramComputePercentages',
+                'gsnHistogramComputePercentagesNoMissing',
+                'gsnHistogramDiscreteBinValues', 'gsnHistogramDiscreteClassValues',
+                'gsnHistogramHorizontal', 'gsnHistogramMinMaxBinsOn',
+                'gsnHistogramNumberOfBins', 'gsnHistogramPercentSign',
+                'gsnHistogramSelectNiceIntervals', 'gsnLeftString',
+                'gsnLeftStringFontColor', 'gsnLeftStringFontHeightF',
+                'gsnLeftStringFuncCode', 'gsnLeftStringOrthogonalPosF',
+                'gsnLeftStringParallelPosF', 'gsnMajorLatSpacing',
+                'gsnMajorLonSpacing', 'gsnMaskLambertConformal',
+                'gsnMaskLambertConformalOutlineOn', 'gsnMaximize',
+                'gsnMinorLatSpacing', 'gsnMinorLonSpacing', 'gsnPanelBottom',
+                'gsnPanelCenter', 'gsnPanelDebug', 'gsnPanelFigureStrings',
+                'gsnPanelFigureStringsBackgroundFillColor',
+                'gsnPanelFigureStringsFontHeightF', 'gsnPanelFigureStringsJust',
+                'gsnPanelFigureStringsPerimOn', 'gsnPanelLabelBar', 'gsnPanelLeft',
+                'gsnPanelMainFont', 'gsnPanelMainFontColor',
+                'gsnPanelMainFontHeightF', 'gsnPanelMainString', 'gsnPanelRight',
+                'gsnPanelRowSpec', 'gsnPanelScalePlotIndex', 'gsnPanelTop',
+                'gsnPanelXF', 'gsnPanelXWhiteSpacePercent', 'gsnPanelYF',
+                'gsnPanelYWhiteSpacePercent', 'gsnPaperHeight', 'gsnPaperMargin',
+                'gsnPaperOrientation', 'gsnPaperWidth', 'gsnPolar',
+                'gsnPolarLabelDistance', 'gsnPolarLabelFont',
+                'gsnPolarLabelFontHeightF', 'gsnPolarLabelSpacing', 'gsnPolarTime',
+                'gsnPolarUT', 'gsnRightString', 'gsnRightStringFontColor',
+                'gsnRightStringFontHeightF', 'gsnRightStringFuncCode',
+                'gsnRightStringOrthogonalPosF', 'gsnRightStringParallelPosF',
+                'gsnScalarContour', 'gsnScale', 'gsnShape', 'gsnSpreadColorEnd',
+                'gsnSpreadColorStart', 'gsnSpreadColors', 'gsnStringFont',
+                'gsnStringFontColor', 'gsnStringFontHeightF', 'gsnStringFuncCode',
+                'gsnTickMarksOn', 'gsnXAxisIrregular2Linear', 'gsnXAxisIrregular2Log',
+                'gsnXRefLine', 'gsnXRefLineColor', 'gsnXRefLineDashPattern',
+                'gsnXRefLineThicknessF', 'gsnXYAboveFillColors', 'gsnXYBarChart',
+                'gsnXYBarChartBarWidth', 'gsnXYBarChartColors',
+                'gsnXYBarChartColors2', 'gsnXYBarChartFillDotSizeF',
+                'gsnXYBarChartFillLineThicknessF', 'gsnXYBarChartFillOpacityF',
+                'gsnXYBarChartFillScaleF', 'gsnXYBarChartOutlineOnly',
+                'gsnXYBarChartOutlineThicknessF', 'gsnXYBarChartPatterns',
+                'gsnXYBarChartPatterns2', 'gsnXYBelowFillColors', 'gsnXYFillColors',
+                'gsnXYFillOpacities', 'gsnXYLeftFillColors', 'gsnXYRightFillColors',
+                'gsnYAxisIrregular2Linear', 'gsnYAxisIrregular2Log', 'gsnYRefLine',
+                'gsnYRefLineColor', 'gsnYRefLineColors', 'gsnYRefLineDashPattern',
+                'gsnYRefLineDashPatterns', 'gsnYRefLineThicknessF',
+                'gsnYRefLineThicknesses', 'gsnZonalMean', 'gsnZonalMeanXMaxF',
+                'gsnZonalMeanXMinF', 'gsnZonalMeanYRefLine', 'lbAutoManage',
+                'lbBottomMarginF', 'lbBoxCount', 'lbBoxEndCapStyle', 'lbBoxFractions',
+                'lbBoxLineColor', 'lbBoxLineDashPattern', 'lbBoxLineDashSegLenF',
+                'lbBoxLineThicknessF', 'lbBoxLinesOn', 'lbBoxMajorExtentF',
+                'lbBoxMinorExtentF', 'lbBoxSeparatorLinesOn', 'lbBoxSizing',
+                'lbFillBackground', 'lbFillColor', 'lbFillColors', 'lbFillDotSizeF',
+                'lbFillLineThicknessF', 'lbFillPattern', 'lbFillPatterns',
+                'lbFillScaleF', 'lbFillScales', 'lbJustification', 'lbLabelAlignment',
+                'lbLabelAngleF', 'lbLabelAutoStride', 'lbLabelBarOn',
+                'lbLabelConstantSpacingF', 'lbLabelDirection', 'lbLabelFont',
+                'lbLabelFontAspectF', 'lbLabelFontColor', 'lbLabelFontHeightF',
+                'lbLabelFontQuality', 'lbLabelFontThicknessF', 'lbLabelFuncCode',
+                'lbLabelJust', 'lbLabelOffsetF', 'lbLabelPosition', 'lbLabelStride',
+                'lbLabelStrings', 'lbLabelsOn', 'lbLeftMarginF', 'lbMaxLabelLenF',
+                'lbMinLabelSpacingF', 'lbMonoFillColor', 'lbMonoFillPattern',
+                'lbMonoFillScale', 'lbOrientation', 'lbPerimColor',
+                'lbPerimDashPattern', 'lbPerimDashSegLenF', 'lbPerimFill',
+                'lbPerimFillColor', 'lbPerimOn', 'lbPerimThicknessF',
+                'lbRasterFillOn', 'lbRightMarginF', 'lbTitleAngleF',
+                'lbTitleConstantSpacingF', 'lbTitleDirection', 'lbTitleExtentF',
+                'lbTitleFont', 'lbTitleFontAspectF', 'lbTitleFontColor',
+                'lbTitleFontHeightF', 'lbTitleFontQuality', 'lbTitleFontThicknessF',
+                'lbTitleFuncCode', 'lbTitleJust', 'lbTitleOffsetF', 'lbTitleOn',
+                'lbTitlePosition', 'lbTitleString', 'lbTopMarginF', 'lgAutoManage',
+                'lgBottomMarginF', 'lgBoxBackground', 'lgBoxLineColor',
+                'lgBoxLineDashPattern', 'lgBoxLineDashSegLenF', 'lgBoxLineThicknessF',
+                'lgBoxLinesOn', 'lgBoxMajorExtentF', 'lgBoxMinorExtentF',
+                'lgDashIndex', 'lgDashIndexes', 'lgItemCount', 'lgItemOrder',
+                'lgItemPlacement', 'lgItemPositions', 'lgItemType', 'lgItemTypes',
+                'lgJustification', 'lgLabelAlignment', 'lgLabelAngleF',
+                'lgLabelAutoStride', 'lgLabelConstantSpacingF', 'lgLabelDirection',
+                'lgLabelFont', 'lgLabelFontAspectF', 'lgLabelFontColor',
+                'lgLabelFontHeightF', 'lgLabelFontQuality', 'lgLabelFontThicknessF',
+                'lgLabelFuncCode', 'lgLabelJust', 'lgLabelOffsetF', 'lgLabelPosition',
+                'lgLabelStride', 'lgLabelStrings', 'lgLabelsOn', 'lgLeftMarginF',
+                'lgLegendOn', 'lgLineColor', 'lgLineColors', 'lgLineDashSegLenF',
+                'lgLineDashSegLens', 'lgLineLabelConstantSpacingF', 'lgLineLabelFont',
+                'lgLineLabelFontAspectF', 'lgLineLabelFontColor',
+                'lgLineLabelFontColors', 'lgLineLabelFontHeightF',
+                'lgLineLabelFontHeights', 'lgLineLabelFontQuality',
+                'lgLineLabelFontThicknessF', 'lgLineLabelFuncCode',
+                'lgLineLabelStrings', 'lgLineLabelsOn', 'lgLineThicknessF',
+                'lgLineThicknesses', 'lgMarkerColor', 'lgMarkerColors',
+                'lgMarkerIndex', 'lgMarkerIndexes', 'lgMarkerSizeF', 'lgMarkerSizes',
+                'lgMarkerThicknessF', 'lgMarkerThicknesses', 'lgMonoDashIndex',
+                'lgMonoItemType', 'lgMonoLineColor', 'lgMonoLineDashSegLen',
+                'lgMonoLineLabelFontColor', 'lgMonoLineLabelFontHeight',
+                'lgMonoLineThickness', 'lgMonoMarkerColor', 'lgMonoMarkerIndex',
+                'lgMonoMarkerSize', 'lgMonoMarkerThickness', 'lgOrientation',
+                'lgPerimColor', 'lgPerimDashPattern', 'lgPerimDashSegLenF',
+                'lgPerimFill', 'lgPerimFillColor', 'lgPerimOn', 'lgPerimThicknessF',
+                'lgRightMarginF', 'lgTitleAngleF', 'lgTitleConstantSpacingF',
+                'lgTitleDirection', 'lgTitleExtentF', 'lgTitleFont',
+                'lgTitleFontAspectF', 'lgTitleFontColor', 'lgTitleFontHeightF',
+                'lgTitleFontQuality', 'lgTitleFontThicknessF', 'lgTitleFuncCode',
+                'lgTitleJust', 'lgTitleOffsetF', 'lgTitleOn', 'lgTitlePosition',
+                'lgTitleString', 'lgTopMarginF', 'mpAreaGroupCount',
+                'mpAreaMaskingOn', 'mpAreaNames', 'mpAreaTypes', 'mpBottomAngleF',
+                'mpBottomMapPosF', 'mpBottomNDCF', 'mpBottomNPCF',
+                'mpBottomPointLatF', 'mpBottomPointLonF', 'mpBottomWindowF',
+                'mpCenterLatF', 'mpCenterLonF', 'mpCenterRotF', 'mpCountyLineColor',
+                'mpCountyLineDashPattern', 'mpCountyLineDashSegLenF',
+                'mpCountyLineThicknessF', 'mpDataBaseVersion', 'mpDataResolution',
+                'mpDataSetName', 'mpDefaultFillColor', 'mpDefaultFillPattern',
+                'mpDefaultFillScaleF', 'mpDynamicAreaGroups', 'mpEllipticalBoundary',
+                'mpFillAreaSpecifiers', 'mpFillBoundarySets', 'mpFillColor',
+                'mpFillColors', 'mpFillColors-default', 'mpFillDotSizeF',
+                'mpFillDrawOrder', 'mpFillOn', 'mpFillPatternBackground',
+                'mpFillPattern', 'mpFillPatterns', 'mpFillPatterns-default',
+                'mpFillScaleF', 'mpFillScales', 'mpFillScales-default',
+                'mpFixedAreaGroups', 'mpGeophysicalLineColor',
+                'mpGeophysicalLineDashPattern', 'mpGeophysicalLineDashSegLenF',
+                'mpGeophysicalLineThicknessF', 'mpGreatCircleLinesOn',
+                'mpGridAndLimbDrawOrder', 'mpGridAndLimbOn', 'mpGridLatSpacingF',
+                'mpGridLineColor', 'mpGridLineDashPattern', 'mpGridLineDashSegLenF',
+                'mpGridLineThicknessF', 'mpGridLonSpacingF', 'mpGridMaskMode',
+                'mpGridMaxLatF', 'mpGridPolarLonSpacingF', 'mpGridSpacingF',
+                'mpInlandWaterFillColor', 'mpInlandWaterFillPattern',
+                'mpInlandWaterFillScaleF', 'mpLabelDrawOrder', 'mpLabelFontColor',
+                'mpLabelFontHeightF', 'mpLabelsOn', 'mpLambertMeridianF',
+                'mpLambertParallel1F', 'mpLambertParallel2F', 'mpLandFillColor',
+                'mpLandFillPattern', 'mpLandFillScaleF', 'mpLeftAngleF',
+                'mpLeftCornerLatF', 'mpLeftCornerLonF', 'mpLeftMapPosF',
+                'mpLeftNDCF', 'mpLeftNPCF', 'mpLeftPointLatF',
+                'mpLeftPointLonF', 'mpLeftWindowF', 'mpLimbLineColor',
+                'mpLimbLineDashPattern', 'mpLimbLineDashSegLenF',
+                'mpLimbLineThicknessF', 'mpLimitMode', 'mpMaskAreaSpecifiers',
+                'mpMaskOutlineSpecifiers', 'mpMaxLatF', 'mpMaxLonF',
+                'mpMinLatF', 'mpMinLonF', 'mpMonoFillColor', 'mpMonoFillPattern',
+                'mpMonoFillScale', 'mpNationalLineColor', 'mpNationalLineDashPattern',
+                'mpNationalLineThicknessF', 'mpOceanFillColor', 'mpOceanFillPattern',
+                'mpOceanFillScaleF', 'mpOutlineBoundarySets', 'mpOutlineDrawOrder',
+                'mpOutlineMaskingOn', 'mpOutlineOn', 'mpOutlineSpecifiers',
+                'mpPerimDrawOrder', 'mpPerimLineColor', 'mpPerimLineDashPattern',
+                'mpPerimLineDashSegLenF', 'mpPerimLineThicknessF', 'mpPerimOn',
+                'mpPolyMode', 'mpProjection', 'mpProvincialLineColor',
+                'mpProvincialLineDashPattern', 'mpProvincialLineDashSegLenF',
+                'mpProvincialLineThicknessF', 'mpRelativeCenterLat',
+                'mpRelativeCenterLon', 'mpRightAngleF', 'mpRightCornerLatF',
+                'mpRightCornerLonF', 'mpRightMapPosF', 'mpRightNDCF',
+                'mpRightNPCF', 'mpRightPointLatF', 'mpRightPointLonF',
+                'mpRightWindowF', 'mpSatelliteAngle1F', 'mpSatelliteAngle2F',
+                'mpSatelliteDistF', 'mpShapeMode', 'mpSpecifiedFillColors',
+                'mpSpecifiedFillDirectIndexing', 'mpSpecifiedFillPatterns',
+                'mpSpecifiedFillPriority', 'mpSpecifiedFillScales',
+                'mpTopAngleF', 'mpTopMapPosF', 'mpTopNDCF', 'mpTopNPCF',
+                'mpTopPointLatF', 'mpTopPointLonF', 'mpTopWindowF',
+                'mpUSStateLineColor', 'mpUSStateLineDashPattern',
+                'mpUSStateLineDashSegLenF', 'mpUSStateLineThicknessF',
+                'pmAnnoManagers', 'pmAnnoViews', 'pmLabelBarDisplayMode',
+                'pmLabelBarHeightF', 'pmLabelBarKeepAspect', 'pmLabelBarOrthogonalPosF',
+                'pmLabelBarParallelPosF', 'pmLabelBarSide', 'pmLabelBarWidthF',
+                'pmLabelBarZone', 'pmLegendDisplayMode', 'pmLegendHeightF',
+                'pmLegendKeepAspect', 'pmLegendOrthogonalPosF',
+                'pmLegendParallelPosF', 'pmLegendSide', 'pmLegendWidthF',
+                'pmLegendZone', 'pmOverlaySequenceIds', 'pmTickMarkDisplayMode',
+                'pmTickMarkZone', 'pmTitleDisplayMode', 'pmTitleZone',
+                'prGraphicStyle', 'prPolyType', 'prXArray', 'prYArray',
+                'sfCopyData', 'sfDataArray', 'sfDataMaxV', 'sfDataMinV',
+                'sfElementNodes', 'sfExchangeDimensions', 'sfFirstNodeIndex',
+                'sfMissingValueV', 'sfXArray', 'sfXCActualEndF', 'sfXCActualStartF',
+                'sfXCEndIndex', 'sfXCEndSubsetV', 'sfXCEndV', 'sfXCStartIndex',
+                'sfXCStartSubsetV', 'sfXCStartV', 'sfXCStride', 'sfXCellBounds',
+                'sfYArray', 'sfYCActualEndF', 'sfYCActualStartF', 'sfYCEndIndex',
+                'sfYCEndSubsetV', 'sfYCEndV', 'sfYCStartIndex', 'sfYCStartSubsetV',
+                'sfYCStartV', 'sfYCStride', 'sfYCellBounds', 'stArrowLengthF',
+                'stArrowStride', 'stCrossoverCheckCount',
+                'stExplicitLabelBarLabelsOn', 'stLabelBarEndLabelsOn',
+                'stLabelFormat', 'stLengthCheckCount', 'stLevelColors',
+                'stLevelCount', 'stLevelPalette', 'stLevelSelectionMode',
+                'stLevelSpacingF', 'stLevels', 'stLineColor', 'stLineOpacityF',
+                'stLineStartStride', 'stLineThicknessF', 'stMapDirection',
+                'stMaxLevelCount', 'stMaxLevelValF', 'stMinArrowSpacingF',
+                'stMinDistanceF', 'stMinLevelValF', 'stMinLineSpacingF',
+                'stMinStepFactorF', 'stMonoLineColor', 'stNoDataLabelOn',
+                'stNoDataLabelString', 'stScalarFieldData', 'stScalarMissingValColor',
+                'stSpanLevelPalette', 'stStepSizeF', 'stStreamlineDrawOrder',
+                'stUseScalarArray', 'stVectorFieldData', 'stZeroFLabelAngleF',
+                'stZeroFLabelBackgroundColor', 'stZeroFLabelConstantSpacingF',
+                'stZeroFLabelFont', 'stZeroFLabelFontAspectF',
+                'stZeroFLabelFontColor', 'stZeroFLabelFontHeightF',
+                'stZeroFLabelFontQuality', 'stZeroFLabelFontThicknessF',
+                'stZeroFLabelFuncCode', 'stZeroFLabelJust', 'stZeroFLabelOn',
+                'stZeroFLabelOrthogonalPosF', 'stZeroFLabelParallelPosF',
+                'stZeroFLabelPerimColor', 'stZeroFLabelPerimOn',
+                'stZeroFLabelPerimSpaceF', 'stZeroFLabelPerimThicknessF',
+                'stZeroFLabelSide', 'stZeroFLabelString', 'stZeroFLabelTextDirection',
+                'stZeroFLabelZone', 'tfDoNDCOverlay', 'tfPlotManagerOn',
+                'tfPolyDrawList', 'tfPolyDrawOrder', 'tiDeltaF', 'tiMainAngleF',
+                'tiMainConstantSpacingF', 'tiMainDirection', 'tiMainFont',
+                'tiMainFontAspectF', 'tiMainFontColor', 'tiMainFontHeightF',
+                'tiMainFontQuality', 'tiMainFontThicknessF', 'tiMainFuncCode',
+                'tiMainJust', 'tiMainOffsetXF', 'tiMainOffsetYF', 'tiMainOn',
+                'tiMainPosition', 'tiMainSide', 'tiMainString', 'tiUseMainAttributes',
+                'tiXAxisAngleF', 'tiXAxisConstantSpacingF', 'tiXAxisDirection',
+                'tiXAxisFont', 'tiXAxisFontAspectF', 'tiXAxisFontColor',
+                'tiXAxisFontHeightF', 'tiXAxisFontQuality', 'tiXAxisFontThicknessF',
+                'tiXAxisFuncCode', 'tiXAxisJust', 'tiXAxisOffsetXF',
+                'tiXAxisOffsetYF', 'tiXAxisOn', 'tiXAxisPosition', 'tiXAxisSide',
+                'tiXAxisString', 'tiYAxisAngleF', 'tiYAxisConstantSpacingF',
+                'tiYAxisDirection', 'tiYAxisFont', 'tiYAxisFontAspectF',
+                'tiYAxisFontColor', 'tiYAxisFontHeightF', 'tiYAxisFontQuality',
+                'tiYAxisFontThicknessF', 'tiYAxisFuncCode', 'tiYAxisJust',
+                'tiYAxisOffsetXF', 'tiYAxisOffsetYF', 'tiYAxisOn', 'tiYAxisPosition',
+                'tiYAxisSide', 'tiYAxisString', 'tmBorderLineColor',
+                'tmBorderThicknessF', 'tmEqualizeXYSizes', 'tmLabelAutoStride',
+                'tmSciNoteCutoff', 'tmXBAutoPrecision', 'tmXBBorderOn',
+                'tmXBDataLeftF', 'tmXBDataRightF', 'tmXBFormat', 'tmXBIrrTensionF',
+                'tmXBIrregularPoints', 'tmXBLabelAngleF', 'tmXBLabelConstantSpacingF',
+                'tmXBLabelDeltaF', 'tmXBLabelDirection', 'tmXBLabelFont',
+                'tmXBLabelFontAspectF', 'tmXBLabelFontColor', 'tmXBLabelFontHeightF',
+                'tmXBLabelFontQuality', 'tmXBLabelFontThicknessF',
+                'tmXBLabelFuncCode', 'tmXBLabelJust', 'tmXBLabelStride', 'tmXBLabels',
+                'tmXBLabelsOn', 'tmXBMajorLengthF', 'tmXBMajorLineColor',
+                'tmXBMajorOutwardLengthF', 'tmXBMajorThicknessF', 'tmXBMaxLabelLenF',
+                'tmXBMaxTicks', 'tmXBMinLabelSpacingF', 'tmXBMinorLengthF',
+                'tmXBMinorLineColor', 'tmXBMinorOn', 'tmXBMinorOutwardLengthF',
+                'tmXBMinorPerMajor', 'tmXBMinorThicknessF', 'tmXBMinorValues',
+                'tmXBMode', 'tmXBOn', 'tmXBPrecision', 'tmXBStyle', 'tmXBTickEndF',
+                'tmXBTickSpacingF', 'tmXBTickStartF', 'tmXBValues', 'tmXMajorGrid',
+                'tmXMajorGridLineColor', 'tmXMajorGridLineDashPattern',
+                'tmXMajorGridThicknessF', 'tmXMinorGrid', 'tmXMinorGridLineColor',
+                'tmXMinorGridLineDashPattern', 'tmXMinorGridThicknessF',
+                'tmXTAutoPrecision', 'tmXTBorderOn', 'tmXTDataLeftF',
+                'tmXTDataRightF', 'tmXTFormat', 'tmXTIrrTensionF',
+                'tmXTIrregularPoints', 'tmXTLabelAngleF', 'tmXTLabelConstantSpacingF',
+                'tmXTLabelDeltaF', 'tmXTLabelDirection', 'tmXTLabelFont',
+                'tmXTLabelFontAspectF', 'tmXTLabelFontColor', 'tmXTLabelFontHeightF',
+                'tmXTLabelFontQuality', 'tmXTLabelFontThicknessF',
+                'tmXTLabelFuncCode', 'tmXTLabelJust', 'tmXTLabelStride', 'tmXTLabels',
+                'tmXTLabelsOn', 'tmXTMajorLengthF', 'tmXTMajorLineColor',
+                'tmXTMajorOutwardLengthF', 'tmXTMajorThicknessF', 'tmXTMaxLabelLenF',
+                'tmXTMaxTicks', 'tmXTMinLabelSpacingF', 'tmXTMinorLengthF',
+                'tmXTMinorLineColor', 'tmXTMinorOn', 'tmXTMinorOutwardLengthF',
+                'tmXTMinorPerMajor', 'tmXTMinorThicknessF', 'tmXTMinorValues',
+                'tmXTMode', 'tmXTOn', 'tmXTPrecision', 'tmXTStyle', 'tmXTTickEndF',
+                'tmXTTickSpacingF', 'tmXTTickStartF', 'tmXTValues', 'tmXUseBottom',
+                'tmYLAutoPrecision', 'tmYLBorderOn', 'tmYLDataBottomF',
+                'tmYLDataTopF', 'tmYLFormat', 'tmYLIrrTensionF',
+                'tmYLIrregularPoints', 'tmYLLabelAngleF', 'tmYLLabelConstantSpacingF',
+                'tmYLLabelDeltaF', 'tmYLLabelDirection', 'tmYLLabelFont',
+                'tmYLLabelFontAspectF', 'tmYLLabelFontColor', 'tmYLLabelFontHeightF',
+                'tmYLLabelFontQuality', 'tmYLLabelFontThicknessF',
+                'tmYLLabelFuncCode', 'tmYLLabelJust', 'tmYLLabelStride', 'tmYLLabels',
+                'tmYLLabelsOn', 'tmYLMajorLengthF', 'tmYLMajorLineColor',
+                'tmYLMajorOutwardLengthF', 'tmYLMajorThicknessF', 'tmYLMaxLabelLenF',
+                'tmYLMaxTicks', 'tmYLMinLabelSpacingF', 'tmYLMinorLengthF',
+                'tmYLMinorLineColor', 'tmYLMinorOn', 'tmYLMinorOutwardLengthF',
+                'tmYLMinorPerMajor', 'tmYLMinorThicknessF', 'tmYLMinorValues',
+                'tmYLMode', 'tmYLOn', 'tmYLPrecision', 'tmYLStyle', 'tmYLTickEndF',
+                'tmYLTickSpacingF', 'tmYLTickStartF', 'tmYLValues', 'tmYMajorGrid',
+                'tmYMajorGridLineColor', 'tmYMajorGridLineDashPattern',
+                'tmYMajorGridThicknessF', 'tmYMinorGrid', 'tmYMinorGridLineColor',
+                'tmYMinorGridLineDashPattern', 'tmYMinorGridThicknessF',
+                'tmYRAutoPrecision', 'tmYRBorderOn', 'tmYRDataBottomF',
+                'tmYRDataTopF', 'tmYRFormat', 'tmYRIrrTensionF',
+                'tmYRIrregularPoints', 'tmYRLabelAngleF', 'tmYRLabelConstantSpacingF',
+                'tmYRLabelDeltaF', 'tmYRLabelDirection', 'tmYRLabelFont',
+                'tmYRLabelFontAspectF', 'tmYRLabelFontColor', 'tmYRLabelFontHeightF',
+                'tmYRLabelFontQuality', 'tmYRLabelFontThicknessF',
+                'tmYRLabelFuncCode', 'tmYRLabelJust', 'tmYRLabelStride', 'tmYRLabels',
+                'tmYRLabelsOn', 'tmYRMajorLengthF', 'tmYRMajorLineColor',
+                'tmYRMajorOutwardLengthF', 'tmYRMajorThicknessF', 'tmYRMaxLabelLenF',
+                'tmYRMaxTicks', 'tmYRMinLabelSpacingF', 'tmYRMinorLengthF',
+                'tmYRMinorLineColor', 'tmYRMinorOn', 'tmYRMinorOutwardLengthF',
+                'tmYRMinorPerMajor', 'tmYRMinorThicknessF', 'tmYRMinorValues',
+                'tmYRMode', 'tmYROn', 'tmYRPrecision', 'tmYRStyle', 'tmYRTickEndF',
+                'tmYRTickSpacingF', 'tmYRTickStartF', 'tmYRValues', 'tmYUseLeft',
+                'trGridType', 'trLineInterpolationOn',
+                'trXAxisType', 'trXCoordPoints', 'trXInterPoints', 'trXLog',
+                'trXMaxF', 'trXMinF', 'trXReverse', 'trXSamples', 'trXTensionF',
+                'trYAxisType', 'trYCoordPoints', 'trYInterPoints', 'trYLog',
+                'trYMaxF', 'trYMinF', 'trYReverse', 'trYSamples', 'trYTensionF',
+                'txAngleF', 'txBackgroundFillColor', 'txConstantSpacingF', 'txDirection',
+                'txFont', 'HLU-Fonts', 'txFontAspectF', 'txFontColor',
+                'txFontHeightF', 'txFontOpacityF', 'txFontQuality',
+                'txFontThicknessF', 'txFuncCode', 'txJust', 'txPerimColor',
+                'txPerimDashLengthF', 'txPerimDashPattern', 'txPerimOn',
+                'txPerimSpaceF', 'txPerimThicknessF', 'txPosXF', 'txPosYF',
+                'txString', 'vcExplicitLabelBarLabelsOn', 'vcFillArrowEdgeColor',
+                'vcFillArrowEdgeThicknessF', 'vcFillArrowFillColor',
+                'vcFillArrowHeadInteriorXF', 'vcFillArrowHeadMinFracXF',
+                'vcFillArrowHeadMinFracYF', 'vcFillArrowHeadXF', 'vcFillArrowHeadYF',
+                'vcFillArrowMinFracWidthF', 'vcFillArrowWidthF', 'vcFillArrowsOn',
+                'vcFillOverEdge', 'vcGlyphOpacityF', 'vcGlyphStyle',
+                'vcLabelBarEndLabelsOn', 'vcLabelFontColor', 'vcLabelFontHeightF',
+                'vcLabelsOn', 'vcLabelsUseVectorColor', 'vcLevelColors',
+                'vcLevelCount', 'vcLevelPalette', 'vcLevelSelectionMode',
+                'vcLevelSpacingF', 'vcLevels', 'vcLineArrowColor',
+                'vcLineArrowHeadMaxSizeF', 'vcLineArrowHeadMinSizeF',
+                'vcLineArrowThicknessF', 'vcMagnitudeFormat',
+                'vcMagnitudeScaleFactorF', 'vcMagnitudeScaleValueF',
+                'vcMagnitudeScalingMode', 'vcMapDirection', 'vcMaxLevelCount',
+                'vcMaxLevelValF', 'vcMaxMagnitudeF', 'vcMinAnnoAngleF',
+                'vcMinAnnoArrowAngleF', 'vcMinAnnoArrowEdgeColor',
+                'vcMinAnnoArrowFillColor', 'vcMinAnnoArrowLineColor',
+                'vcMinAnnoArrowMinOffsetF', 'vcMinAnnoArrowSpaceF',
+                'vcMinAnnoArrowUseVecColor', 'vcMinAnnoBackgroundColor',
+                'vcMinAnnoConstantSpacingF', 'vcMinAnnoExplicitMagnitudeF',
+                'vcMinAnnoFont', 'vcMinAnnoFontAspectF', 'vcMinAnnoFontColor',
+                'vcMinAnnoFontHeightF', 'vcMinAnnoFontQuality',
+                'vcMinAnnoFontThicknessF', 'vcMinAnnoFuncCode', 'vcMinAnnoJust',
+                'vcMinAnnoOn', 'vcMinAnnoOrientation', 'vcMinAnnoOrthogonalPosF',
+                'vcMinAnnoParallelPosF', 'vcMinAnnoPerimColor', 'vcMinAnnoPerimOn',
+                'vcMinAnnoPerimSpaceF', 'vcMinAnnoPerimThicknessF', 'vcMinAnnoSide',
+                'vcMinAnnoString1', 'vcMinAnnoString1On', 'vcMinAnnoString2',
+                'vcMinAnnoString2On', 'vcMinAnnoTextDirection', 'vcMinAnnoZone',
+                'vcMinDistanceF', 'vcMinFracLengthF', 'vcMinLevelValF',
+                'vcMinMagnitudeF', 'vcMonoFillArrowEdgeColor',
+                'vcMonoFillArrowFillColor', 'vcMonoLineArrowColor',
+                'vcMonoWindBarbColor', 'vcNoDataLabelOn', 'vcNoDataLabelString',
+                'vcPositionMode', 'vcRefAnnoAngleF', 'vcRefAnnoArrowAngleF',
+                'vcRefAnnoArrowEdgeColor', 'vcRefAnnoArrowFillColor',
+                'vcRefAnnoArrowLineColor', 'vcRefAnnoArrowMinOffsetF',
+                'vcRefAnnoArrowSpaceF', 'vcRefAnnoArrowUseVecColor',
+                'vcRefAnnoBackgroundColor', 'vcRefAnnoConstantSpacingF',
+                'vcRefAnnoExplicitMagnitudeF', 'vcRefAnnoFont',
+                'vcRefAnnoFontAspectF', 'vcRefAnnoFontColor', 'vcRefAnnoFontHeightF',
+                'vcRefAnnoFontQuality', 'vcRefAnnoFontThicknessF',
+                'vcRefAnnoFuncCode', 'vcRefAnnoJust', 'vcRefAnnoOn',
+                'vcRefAnnoOrientation', 'vcRefAnnoOrthogonalPosF',
+                'vcRefAnnoParallelPosF', 'vcRefAnnoPerimColor', 'vcRefAnnoPerimOn',
+                'vcRefAnnoPerimSpaceF', 'vcRefAnnoPerimThicknessF', 'vcRefAnnoSide',
+                'vcRefAnnoString1', 'vcRefAnnoString1On', 'vcRefAnnoString2',
+                'vcRefAnnoString2On', 'vcRefAnnoTextDirection', 'vcRefAnnoZone',
+                'vcRefLengthF', 'vcRefMagnitudeF', 'vcScalarFieldData',
+                'vcScalarMissingValColor', 'vcScalarValueFormat',
+                'vcScalarValueScaleFactorF', 'vcScalarValueScaleValueF',
+                'vcScalarValueScalingMode', 'vcSpanLevelPalette', 'vcUseRefAnnoRes',
+                'vcUseScalarArray', 'vcVectorDrawOrder', 'vcVectorFieldData',
+                'vcWindBarbCalmCircleSizeF', 'vcWindBarbColor',
+                'vcWindBarbLineThicknessF', 'vcWindBarbScaleFactorF',
+                'vcWindBarbTickAngleF', 'vcWindBarbTickLengthF',
+                'vcWindBarbTickSpacingF', 'vcZeroFLabelAngleF',
+                'vcZeroFLabelBackgroundColor', 'vcZeroFLabelConstantSpacingF',
+                'vcZeroFLabelFont', 'vcZeroFLabelFontAspectF',
+                'vcZeroFLabelFontColor', 'vcZeroFLabelFontHeightF',
+                'vcZeroFLabelFontQuality', 'vcZeroFLabelFontThicknessF',
+                'vcZeroFLabelFuncCode', 'vcZeroFLabelJust', 'vcZeroFLabelOn',
+                'vcZeroFLabelOrthogonalPosF', 'vcZeroFLabelParallelPosF',
+                'vcZeroFLabelPerimColor', 'vcZeroFLabelPerimOn',
+                'vcZeroFLabelPerimSpaceF', 'vcZeroFLabelPerimThicknessF',
+                'vcZeroFLabelSide', 'vcZeroFLabelString', 'vcZeroFLabelTextDirection',
+                'vcZeroFLabelZone', 'vfCopyData', 'vfDataArray',
+                'vfExchangeDimensions', 'vfExchangeUVData', 'vfMagMaxV', 'vfMagMinV',
+                'vfMissingUValueV', 'vfMissingVValueV', 'vfPolarData',
+                'vfSingleMissingValue', 'vfUDataArray', 'vfUMaxV', 'vfUMinV',
+                'vfVDataArray', 'vfVMaxV', 'vfVMinV', 'vfXArray', 'vfXCActualEndF',
+                'vfXCActualStartF', 'vfXCEndIndex', 'vfXCEndSubsetV', 'vfXCEndV',
+                'vfXCStartIndex', 'vfXCStartSubsetV', 'vfXCStartV', 'vfXCStride',
+                'vfYArray', 'vfYCActualEndF', 'vfYCActualStartF', 'vfYCEndIndex',
+                'vfYCEndSubsetV', 'vfYCEndV', 'vfYCStartIndex', 'vfYCStartSubsetV',
+                'vfYCStartV', 'vfYCStride', 'vpAnnoManagerId', 'vpClipOn',
+                'vpHeightF', 'vpKeepAspect', 'vpOn', 'vpUseSegments', 'vpWidthF',
+                'vpXF', 'vpYF', 'wkAntiAlias', 'wkBackgroundColor', 'wkBackgroundOpacityF',
+                'wkColorMapLen', 'wkColorMap', 'wkColorModel', 'wkDashTableLength',
+                'wkDefGraphicStyleId', 'wkDeviceLowerX', 'wkDeviceLowerY',
+                'wkDeviceUpperX', 'wkDeviceUpperY', 'wkFileName', 'wkFillTableLength',
+                'wkForegroundColor', 'wkFormat', 'wkFullBackground', 'wkGksWorkId',
+                'wkHeight', 'wkMarkerTableLength', 'wkMetaName', 'wkOrientation',
+                'wkPDFFileName', 'wkPDFFormat', 'wkPDFResolution', 'wkPSFileName',
+                'wkPSFormat', 'wkPSResolution', 'wkPaperHeightF', 'wkPaperSize',
+                'wkPaperWidthF', 'wkPause', 'wkTopLevelViews', 'wkViews',
+                'wkVisualType', 'wkWidth', 'wkWindowId', 'wkXColorMode', 'wsCurrentSize',
+                'wsMaximumSize', 'wsThresholdSize', 'xyComputeXMax',
+                'xyComputeXMin', 'xyComputeYMax', 'xyComputeYMin', 'xyCoordData',
+                'xyCoordDataSpec', 'xyCurveDrawOrder', 'xyDashPattern',
+                'xyDashPatterns', 'xyExplicitLabels', 'xyExplicitLegendLabels',
+                'xyLabelMode', 'xyLineColor', 'xyLineColors', 'xyLineDashSegLenF',
+                'xyLineLabelConstantSpacingF', 'xyLineLabelFont',
+                'xyLineLabelFontAspectF', 'xyLineLabelFontColor',
+                'xyLineLabelFontColors', 'xyLineLabelFontHeightF',
+                'xyLineLabelFontQuality', 'xyLineLabelFontThicknessF',
+                'xyLineLabelFuncCode', 'xyLineThicknessF', 'xyLineThicknesses',
+                'xyMarkLineMode', 'xyMarkLineModes', 'xyMarker', 'xyMarkerColor',
+                'xyMarkerColors', 'xyMarkerSizeF', 'xyMarkerSizes',
+                'xyMarkerThicknessF', 'xyMarkerThicknesses', 'xyMarkers',
+                'xyMonoDashPattern', 'xyMonoLineColor', 'xyMonoLineLabelFontColor',
+                'xyMonoLineThickness', 'xyMonoMarkLineMode', 'xyMonoMarker',
+                'xyMonoMarkerColor', 'xyMonoMarkerSize', 'xyMonoMarkerThickness',
+                'xyXIrrTensionF', 'xyXIrregularPoints', 'xyXStyle', 'xyYIrrTensionF',
+                'xyYIrregularPoints', 'xyYStyle'), prefix=r'\b'),
+             Name.Builtin),
+
+            # Booleans
+            (r'\.(True|False)\.', Name.Builtin),
+            # Comparing Operators
+            (r'\.(eq|ne|lt|le|gt|ge|not|and|or|xor)\.', Operator.Word),
+        ],
+
+        'strings': [
+            (r'(?s)"(\\\\|\\[0-7]+|\\.|[^"\\])*"', String.Double),
+        ],
+
+        'nums': [
+            (r'\d+(?![.e])(_[a-z]\w+)?', Number.Integer),
+            (r'[+-]?\d*\.\d+(e[-+]?\d+)?(_[a-z]\w+)?', Number.Float),
+            (r'[+-]?\d+\.\d*(e[-+]?\d+)?(_[a-z]\w+)?', Number.Float),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/nimrod.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/nimrod.py
new file mode 100644
index 0000000000000000000000000000000000000000..b99e246d707f30d4c0c3fab50d7293fcd34e3510
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/nimrod.py
@@ -0,0 +1,199 @@
+"""
+    pygments.lexers.nimrod
+    ~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for the Nim language (formerly known as Nimrod).
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, include, default, bygroups
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation, Error
+
+__all__ = ['NimrodLexer']
+
+
+class NimrodLexer(RegexLexer):
+    """
+    For Nim source code.
+    """
+
+    name = 'Nimrod'
+    url = 'http://nim-lang.org/'
+    aliases = ['nimrod', 'nim']
+    filenames = ['*.nim', '*.nimrod']
+    mimetypes = ['text/x-nim']
+    version_added = '1.5'
+
+    flags = re.MULTILINE | re.IGNORECASE
+
+    def underscorize(words):
+        newWords = []
+        new = []
+        for word in words:
+            for ch in word:
+                new.append(ch)
+                new.append("_?")
+            newWords.append(''.join(new))
+            new = []
+        return "|".join(newWords)
+
+    keywords = [
+        'addr', 'and', 'as', 'asm', 'bind', 'block', 'break', 'case',
+        'cast', 'concept', 'const', 'continue', 'converter', 'defer', 'discard',
+        'distinct', 'div', 'do', 'elif', 'else', 'end', 'enum', 'except',
+        'export', 'finally', 'for', 'if', 'in', 'yield', 'interface',
+        'is', 'isnot', 'iterator', 'let', 'mixin', 'mod',
+        'not', 'notin', 'object', 'of', 'or', 'out', 'ptr', 'raise',
+        'ref', 'return', 'shl', 'shr', 'static', 'try',
+        'tuple', 'type', 'using', 'when', 'while', 'xor'
+    ]
+
+    keywordsPseudo = [
+        'nil', 'true', 'false'
+    ]
+
+    opWords = [
+        'and', 'or', 'not', 'xor', 'shl', 'shr', 'div', 'mod', 'in',
+        'notin', 'is', 'isnot'
+    ]
+
+    types = [
+        'int', 'int8', 'int16', 'int32', 'int64', 'float', 'float32', 'float64',
+        'bool', 'char', 'range', 'array', 'seq', 'set', 'string'
+    ]
+
+    tokens = {
+        'root': [
+            # Comments
+            (r'##\[', String.Doc, 'doccomment'),
+            (r'##.*$', String.Doc),
+            (r'#\[', Comment.Multiline, 'comment'),
+            (r'#.*$', Comment),
+
+            # Pragmas
+            (r'\{\.', String.Other, 'pragma'),
+
+            # Operators
+            (r'[*=><+\-/@$~&%!?|\\\[\]]', Operator),
+            (r'\.\.|\.|,|\[\.|\.\]|\{\.|\.\}|\(\.|\.\)|\{|\}|\(|\)|:|\^|`|;',
+             Punctuation),
+
+            # Case statement branch
+            (r'(\n\s*)(of)(\s)', bygroups(Text.Whitespace, Keyword,
+                                          Text.Whitespace), 'casebranch'),
+
+            # Strings
+            (r'(?:[\w]+)"', String, 'rdqs'),
+            (r'"""', String.Double, 'tdqs'),
+            ('"', String, 'dqs'),
+
+            # Char
+            ("'", String.Char, 'chars'),
+
+            # Keywords
+            (rf'({underscorize(opWords)})\b', Operator.Word),
+            (r'(proc|func|method|macro|template)(\s)(?![(\[\]])',
+             bygroups(Keyword, Text.Whitespace), 'funcname'),
+            (rf'({underscorize(keywords)})\b', Keyword),
+            (r'({})\b'.format(underscorize(['from', 'import', 'include', 'export'])),
+             Keyword.Namespace),
+            (r'(v_?a_?r)\b', Keyword.Declaration),
+            (rf'({underscorize(types)})\b', Name.Builtin),
+            (rf'({underscorize(keywordsPseudo)})\b', Keyword.Pseudo),
+
+            # Identifiers
+            (r'\b((?![_\d])\w)(((?!_)\w)|(_(?!_)\w))*', Name),
+
+            # Numbers
+            (r'[0-9][0-9_]*(?=([e.]|\'f(32|64)))',
+             Number.Float, ('float-suffix', 'float-number')),
+            (r'0x[a-f0-9][a-f0-9_]*', Number.Hex, 'int-suffix'),
+            (r'0b[01][01_]*', Number.Bin, 'int-suffix'),
+            (r'0o[0-7][0-7_]*', Number.Oct, 'int-suffix'),
+            (r'[0-9][0-9_]*', Number.Integer, 'int-suffix'),
+
+            # Whitespace
+            (r'\s+', Text.Whitespace),
+            (r'.+$', Error),
+        ],
+        'chars': [
+            (r'\\([\\abcefnrtvl"\']|x[a-f0-9]{2}|[0-9]{1,3})', String.Escape),
+            (r"'", String.Char, '#pop'),
+            (r".", String.Char)
+        ],
+        'strings': [
+            (r'(?|>=|>>|>|<=|<<|<|\+|-|=|/|\*|%|\+=|-=|!|@', Operator),
+            (r'\(|\)|\[|\]|,|\.\.\.|\.\.|\.|::|:', Punctuation),
+            (r'`\{[^`]*`\}', Text),  # Extern blocks won't be Lexed by Nit
+            (r'[\r\n\t ]+', Text),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/nix.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/nix.py
new file mode 100644
index 0000000000000000000000000000000000000000..16572afe48a097271dcf017a1d1f53e89b000916
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/nix.py
@@ -0,0 +1,144 @@
+"""
+    pygments.lexers.nix
+    ~~~~~~~~~~~~~~~~~~~
+
+    Lexers for the NixOS Nix language.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, include
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation, Literal
+
+__all__ = ['NixLexer']
+
+
+class NixLexer(RegexLexer):
+    """
+    For the Nix language.
+    """
+
+    name = 'Nix'
+    url = 'http://nixos.org/nix/'
+    aliases = ['nixos', 'nix']
+    filenames = ['*.nix']
+    mimetypes = ['text/x-nix']
+    version_added = '2.0'
+
+    keywords = ['rec', 'with', 'let', 'in', 'inherit', 'assert', 'if',
+                'else', 'then', '...']
+    builtins = ['import', 'abort', 'baseNameOf', 'dirOf', 'isNull', 'builtins',
+                'map', 'removeAttrs', 'throw', 'toString', 'derivation']
+    operators = ['++', '+', '?', '.', '!', '//', '==', '/',
+                 '!=', '&&', '||', '->', '=', '<', '>', '*', '-']
+
+    punctuations = ["(", ")", "[", "]", ";", "{", "}", ":", ",", "@"]
+
+    tokens = {
+        'root': [
+            # comments starting with #
+            (r'#.*$', Comment.Single),
+
+            # multiline comments
+            (r'/\*', Comment.Multiline, 'comment'),
+
+            # whitespace
+            (r'\s+', Text),
+
+            # keywords
+            ('({})'.format('|'.join(re.escape(entry) + '\\b' for entry in keywords)), Keyword),
+
+            # highlight the builtins
+            ('({})'.format('|'.join(re.escape(entry) + '\\b' for entry in builtins)),
+             Name.Builtin),
+
+            (r'\b(true|false|null)\b', Name.Constant),
+
+            # floats
+            (r'-?(\d+\.\d*|\.\d+)([eE][-+]?\d+)?', Number.Float),
+
+            # integers
+            (r'-?[0-9]+', Number.Integer),
+
+            # paths
+            (r'[\w.+-]*(\/[\w.+-]+)+', Literal),
+            (r'~(\/[\w.+-]+)+', Literal),
+            (r'\<[\w.+-]+(\/[\w.+-]+)*\>', Literal),
+
+            # operators
+            ('({})'.format('|'.join(re.escape(entry) for entry in operators)),
+             Operator),
+
+            # word operators
+            (r'\b(or|and)\b', Operator.Word),
+
+            (r'\{', Punctuation, 'block'),
+
+            # punctuations
+            ('({})'.format('|'.join(re.escape(entry) for entry in punctuations)), Punctuation),
+
+            # strings
+            (r'"', String.Double, 'doublequote'),
+            (r"''", String.Multiline, 'multiline'),
+
+            # urls
+            (r'[a-zA-Z][a-zA-Z0-9\+\-\.]*\:[\w%/?:@&=+$,\\.!~*\'-]+', Literal),
+
+            # names of variables
+            (r'[\w-]+(?=\s*=)', String.Symbol),
+            (r'[a-zA-Z_][\w\'-]*', Text),
+
+            (r"\$\{", String.Interpol, 'antiquote'),
+        ],
+        'comment': [
+            (r'[^/*]+', Comment.Multiline),
+            (r'/\*', Comment.Multiline, '#push'),
+            (r'\*/', Comment.Multiline, '#pop'),
+            (r'[*/]', Comment.Multiline),
+        ],
+        'multiline': [
+            (r"''(\$|'|\\n|\\r|\\t|\\)", String.Escape),
+            (r"''", String.Multiline, '#pop'),
+            (r'\$\{', String.Interpol, 'antiquote'),
+            (r"[^'\$]+", String.Multiline),
+            (r"\$[^\{']", String.Multiline),
+            (r"'[^']", String.Multiline),
+            (r"\$(?=')", String.Multiline),
+        ],
+        'doublequote': [
+            (r'\\(\\|"|\$|n)', String.Escape),
+            (r'"', String.Double, '#pop'),
+            (r'\$\{', String.Interpol, 'antiquote'),
+            (r'[^"\\\$]+', String.Double),
+            (r'\$[^\{"]', String.Double),
+            (r'\$(?=")', String.Double),
+            (r'\\', String.Double),
+        ],
+        'antiquote': [
+            (r"\}", String.Interpol, '#pop'),
+            # TODO: we should probably escape also here ''${ \${
+            (r"\$\{", String.Interpol, '#push'),
+            include('root'),
+        ],
+        'block': [
+            (r"\}", Punctuation, '#pop'),
+            include('root'),
+        ],
+    }
+
+    def analyse_text(text):
+        rv = 0.0
+        # TODO: let/in
+        if re.search(r'import.+?<[^>]+>', text):
+            rv += 0.4
+        if re.search(r'mkDerivation\s+(\(|\{|rec)', text):
+            rv += 0.4
+        if re.search(r'=\s+mkIf\s+', text):
+            rv += 0.4
+        if re.search(r'\{[a-zA-Z,\s]+\}:', text):
+            rv += 0.1
+        return rv
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/numbair.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/numbair.py
new file mode 100644
index 0000000000000000000000000000000000000000..28395b41a4d302aadba80c4413293dd288779407
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/numbair.py
@@ -0,0 +1,63 @@
+"""
+    pygments.lexers.numbair
+    ~~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for other Numba Intermediate Representation.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, include, bygroups, words
+from pygments.token import Whitespace, Name, String,  Punctuation, Keyword, \
+    Operator, Number
+
+__all__ = ["NumbaIRLexer"]
+
+class NumbaIRLexer(RegexLexer):
+    """
+    Lexer for Numba IR
+    """
+    name = 'Numba_IR'
+    url = "https://numba.readthedocs.io/en/stable/developer/architecture.html#stage-2-generate-the-numba-ir"
+    aliases = ['numba_ir', 'numbair']
+    filenames = ['*.numba_ir']
+    mimetypes = ['text/x-numba_ir', 'text/x-numbair']
+    version_added = '2.19'
+
+    identifier = r'\$[a-zA-Z0-9._]+'
+    fun_or_var = r'([a-zA-Z_]+[a-zA-Z0-9]*)'
+
+    tokens = {
+        'root' : [
+            (r'(label)(\ [0-9]+)(:)$',
+                bygroups(Keyword, Name.Label, Punctuation)),
+
+            (r'=', Operator),
+            include('whitespace'),
+            include('keyword'),
+
+            (identifier, Name.Variable),
+            (fun_or_var + r'(\()',
+                bygroups(Name.Function, Punctuation)),
+            (fun_or_var + r'(\=)',
+                bygroups(Name.Attribute, Punctuation)),
+            (fun_or_var, Name.Constant),
+            (r'[0-9]+', Number),
+
+            # 
+            (r'<[^>\n]*>', String),
+
+            (r'[=<>{}\[\]()*.,!\':]|x\b', Punctuation)
+        ],
+
+        'keyword':[
+            (words((
+                'del', 'jump', 'call', 'branch',
+            ), suffix=' '), Keyword),
+        ],
+
+        'whitespace': [
+            (r'(\n|\s)+', Whitespace),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/oberon.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/oberon.py
new file mode 100644
index 0000000000000000000000000000000000000000..11cf571dfd6097354117f2842246eeb06ff696ea
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/oberon.py
@@ -0,0 +1,120 @@
+"""
+    pygments.lexers.oberon
+    ~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for Oberon family languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, include, words
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation
+
+__all__ = ['ComponentPascalLexer']
+
+
+class ComponentPascalLexer(RegexLexer):
+    """
+    For Component Pascal source code.
+    """
+    name = 'Component Pascal'
+    aliases = ['componentpascal', 'cp']
+    filenames = ['*.cp', '*.cps']
+    mimetypes = ['text/x-component-pascal']
+    url = 'https://blackboxframework.org'
+    version_added = '2.1'
+
+    flags = re.MULTILINE | re.DOTALL
+
+    tokens = {
+        'root': [
+            include('whitespace'),
+            include('comments'),
+            include('punctuation'),
+            include('numliterals'),
+            include('strings'),
+            include('operators'),
+            include('builtins'),
+            include('identifiers'),
+        ],
+        'whitespace': [
+            (r'\n+', Text),  # blank lines
+            (r'\s+', Text),  # whitespace
+        ],
+        'comments': [
+            (r'\(\*([^$].*?)\*\)', Comment.Multiline),
+            # TODO: nested comments (* (* ... *) ... (* ... *) *) not supported!
+        ],
+        'punctuation': [
+            (r'[()\[\]{},.:;|]', Punctuation),
+        ],
+        'numliterals': [
+            (r'[0-9A-F]+X\b', Number.Hex),                 # char code
+            (r'[0-9A-F]+[HL]\b', Number.Hex),              # hexadecimal number
+            (r'[0-9]+\.[0-9]+E[+-][0-9]+', Number.Float),  # real number
+            (r'[0-9]+\.[0-9]+', Number.Float),             # real number
+            (r'[0-9]+', Number.Integer),                   # decimal whole number
+        ],
+        'strings': [
+            (r"'[^\n']*'", String),  # single quoted string
+            (r'"[^\n"]*"', String),  # double quoted string
+        ],
+        'operators': [
+            # Arithmetic Operators
+            (r'[+-]', Operator),
+            (r'[*/]', Operator),
+            # Relational Operators
+            (r'[=#<>]', Operator),
+            # Dereferencing Operator
+            (r'\^', Operator),
+            # Logical AND Operator
+            (r'&', Operator),
+            # Logical NOT Operator
+            (r'~', Operator),
+            # Assignment Symbol
+            (r':=', Operator),
+            # Range Constructor
+            (r'\.\.', Operator),
+            (r'\$', Operator),
+        ],
+        'identifiers': [
+            (r'([a-zA-Z_$][\w$]*)', Name),
+        ],
+        'builtins': [
+            (words((
+                'ANYPTR', 'ANYREC', 'BOOLEAN', 'BYTE', 'CHAR', 'INTEGER', 'LONGINT',
+                'REAL', 'SET', 'SHORTCHAR', 'SHORTINT', 'SHORTREAL'
+                ), suffix=r'\b'), Keyword.Type),
+            (words((
+                'ABS', 'ABSTRACT', 'ARRAY', 'ASH', 'ASSERT', 'BEGIN', 'BITS', 'BY',
+                'CAP', 'CASE', 'CHR', 'CLOSE', 'CONST', 'DEC', 'DIV', 'DO', 'ELSE',
+                'ELSIF', 'EMPTY', 'END', 'ENTIER', 'EXCL', 'EXIT', 'EXTENSIBLE', 'FOR',
+                'HALT', 'IF', 'IMPORT', 'IN', 'INC', 'INCL', 'IS', 'LEN', 'LIMITED',
+                'LONG', 'LOOP', 'MAX', 'MIN', 'MOD', 'MODULE', 'NEW', 'ODD', 'OF',
+                'OR', 'ORD', 'OUT', 'POINTER', 'PROCEDURE', 'RECORD', 'REPEAT', 'RETURN',
+                'SHORT', 'SHORTCHAR', 'SHORTINT', 'SIZE', 'THEN', 'TYPE', 'TO', 'UNTIL',
+                'VAR', 'WHILE', 'WITH'
+                ), suffix=r'\b'), Keyword.Reserved),
+            (r'(TRUE|FALSE|NIL|INF)\b', Keyword.Constant),
+        ]
+    }
+
+    def analyse_text(text):
+        """The only other lexer using .cp is the C++ one, so we check if for
+        a few common Pascal keywords here. Those are unfortunately quite
+        common across various business languages as well."""
+        result = 0
+        if 'BEGIN' in text:
+            result += 0.01
+        if 'END' in text:
+            result += 0.01
+        if 'PROCEDURE' in text:
+            result += 0.01
+        if 'MODULE' in text:
+            result += 0.01
+
+        return result
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/objective.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/objective.py
new file mode 100644
index 0000000000000000000000000000000000000000..ce281fbd198802ba63742086f850b339d82e3b0d
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/objective.py
@@ -0,0 +1,513 @@
+"""
+    pygments.lexers.objective
+    ~~~~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for Objective-C family languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, include, bygroups, using, this, words, \
+    inherit, default
+from pygments.token import Text, Keyword, Name, String, Operator, \
+    Number, Punctuation, Literal, Comment, Whitespace
+
+from pygments.lexers.c_cpp import CLexer, CppLexer
+
+__all__ = ['ObjectiveCLexer', 'ObjectiveCppLexer', 'LogosLexer', 'SwiftLexer']
+
+
+def objective(baselexer):
+    """
+    Generate a subclass of baselexer that accepts the Objective-C syntax
+    extensions.
+    """
+
+    # Have to be careful not to accidentally match JavaDoc/Doxygen syntax here,
+    # since that's quite common in ordinary C/C++ files.  It's OK to match
+    # JavaDoc/Doxygen keywords that only apply to Objective-C, mind.
+    #
+    # The upshot of this is that we CANNOT match @class or @interface
+    _oc_keywords = re.compile(r'@(?:end|implementation|protocol)')
+
+    # Matches [ ? identifier  ( identifier ? ] |  identifier? : )
+    # (note the identifier is *optional* when there is a ':'!)
+    _oc_message = re.compile(r'\[\s*[a-zA-Z_]\w*\s+'
+                             r'(?:[a-zA-Z_]\w*\s*\]|'
+                             r'(?:[a-zA-Z_]\w*)?:)')
+
+    class GeneratedObjectiveCVariant(baselexer):
+        """
+        Implements Objective-C syntax on top of an existing C family lexer.
+        """
+
+        tokens = {
+            'statements': [
+                (r'@"', String, 'string'),
+                (r'@(YES|NO)', Number),
+                (r"@'(\\.|\\[0-7]{1,3}|\\x[a-fA-F0-9]{1,2}|[^\\\'\n])'", String.Char),
+                (r'@(\d+\.\d*|\.\d+|\d+)[eE][+-]?\d+[lL]?', Number.Float),
+                (r'@(\d+\.\d*|\.\d+|\d+[fF])[fF]?', Number.Float),
+                (r'@0x[0-9a-fA-F]+[Ll]?', Number.Hex),
+                (r'@0[0-7]+[Ll]?', Number.Oct),
+                (r'@\d+[Ll]?', Number.Integer),
+                (r'@\(', Literal, 'literal_number'),
+                (r'@\[', Literal, 'literal_array'),
+                (r'@\{', Literal, 'literal_dictionary'),
+                (words((
+                    '@selector', '@private', '@protected', '@public', '@encode',
+                    '@synchronized', '@try', '@throw', '@catch', '@finally',
+                    '@end', '@property', '@synthesize', '__bridge', '__bridge_transfer',
+                    '__autoreleasing', '__block', '__weak', '__strong', 'weak', 'strong',
+                    'copy', 'retain', 'assign', 'unsafe_unretained', 'atomic', 'nonatomic',
+                    'readonly', 'readwrite', 'setter', 'getter', 'typeof', 'in',
+                    'out', 'inout', 'release', 'class', '@dynamic', '@optional',
+                    '@required', '@autoreleasepool', '@import'), suffix=r'\b'),
+                 Keyword),
+                (words(('id', 'instancetype', 'Class', 'IMP', 'SEL', 'BOOL',
+                        'IBOutlet', 'IBAction', 'unichar'), suffix=r'\b'),
+                 Keyword.Type),
+                (r'@(true|false|YES|NO)\n', Name.Builtin),
+                (r'(YES|NO|nil|self|super)\b', Name.Builtin),
+                # Carbon types
+                (r'(Boolean|UInt8|SInt8|UInt16|SInt16|UInt32|SInt32)\b', Keyword.Type),
+                # Carbon built-ins
+                (r'(TRUE|FALSE)\b', Name.Builtin),
+                (r'(@interface|@implementation)(\s+)', bygroups(Keyword, Text),
+                 ('#pop', 'oc_classname')),
+                (r'(@class|@protocol)(\s+)', bygroups(Keyword, Text),
+                 ('#pop', 'oc_forward_classname')),
+                # @ can also prefix other expressions like @{...} or @(...)
+                (r'@', Punctuation),
+                inherit,
+            ],
+            'oc_classname': [
+                # interface definition that inherits
+                (r'([a-zA-Z$_][\w$]*)(\s*:\s*)([a-zA-Z$_][\w$]*)?(\s*)(\{)',
+                 bygroups(Name.Class, Text, Name.Class, Text, Punctuation),
+                 ('#pop', 'oc_ivars')),
+                (r'([a-zA-Z$_][\w$]*)(\s*:\s*)([a-zA-Z$_][\w$]*)?',
+                 bygroups(Name.Class, Text, Name.Class), '#pop'),
+                # interface definition for a category
+                (r'([a-zA-Z$_][\w$]*)(\s*)(\([a-zA-Z$_][\w$]*\))(\s*)(\{)',
+                 bygroups(Name.Class, Text, Name.Label, Text, Punctuation),
+                 ('#pop', 'oc_ivars')),
+                (r'([a-zA-Z$_][\w$]*)(\s*)(\([a-zA-Z$_][\w$]*\))',
+                 bygroups(Name.Class, Text, Name.Label), '#pop'),
+                # simple interface / implementation
+                (r'([a-zA-Z$_][\w$]*)(\s*)(\{)',
+                 bygroups(Name.Class, Text, Punctuation), ('#pop', 'oc_ivars')),
+                (r'([a-zA-Z$_][\w$]*)', Name.Class, '#pop')
+            ],
+            'oc_forward_classname': [
+                (r'([a-zA-Z$_][\w$]*)(\s*,\s*)',
+                 bygroups(Name.Class, Text), 'oc_forward_classname'),
+                (r'([a-zA-Z$_][\w$]*)(\s*;?)',
+                 bygroups(Name.Class, Text), '#pop')
+            ],
+            'oc_ivars': [
+                include('whitespace'),
+                include('statements'),
+                (';', Punctuation),
+                (r'\{', Punctuation, '#push'),
+                (r'\}', Punctuation, '#pop'),
+            ],
+            'root': [
+                # methods
+                (r'^([-+])(\s*)'                         # method marker
+                 r'(\(.*?\))?(\s*)'                      # return type
+                 r'([a-zA-Z$_][\w$]*:?)',        # begin of method name
+                 bygroups(Punctuation, Text, using(this),
+                          Text, Name.Function),
+                 'method'),
+                inherit,
+            ],
+            'method': [
+                include('whitespace'),
+                # TODO unsure if ellipses are allowed elsewhere, see
+                # discussion in Issue 789
+                (r',', Punctuation),
+                (r'\.\.\.', Punctuation),
+                (r'(\(.*?\))(\s*)([a-zA-Z$_][\w$]*)',
+                 bygroups(using(this), Text, Name.Variable)),
+                (r'[a-zA-Z$_][\w$]*:', Name.Function),
+                (';', Punctuation, '#pop'),
+                (r'\{', Punctuation, 'function'),
+                default('#pop'),
+            ],
+            'literal_number': [
+                (r'\(', Punctuation, 'literal_number_inner'),
+                (r'\)', Literal, '#pop'),
+                include('statement'),
+            ],
+            'literal_number_inner': [
+                (r'\(', Punctuation, '#push'),
+                (r'\)', Punctuation, '#pop'),
+                include('statement'),
+            ],
+            'literal_array': [
+                (r'\[', Punctuation, 'literal_array_inner'),
+                (r'\]', Literal, '#pop'),
+                include('statement'),
+            ],
+            'literal_array_inner': [
+                (r'\[', Punctuation, '#push'),
+                (r'\]', Punctuation, '#pop'),
+                include('statement'),
+            ],
+            'literal_dictionary': [
+                (r'\}', Literal, '#pop'),
+                include('statement'),
+            ],
+        }
+
+        def analyse_text(text):
+            if _oc_keywords.search(text):
+                return 1.0
+            elif '@"' in text:  # strings
+                return 0.8
+            elif re.search('@[0-9]+', text):
+                return 0.7
+            elif _oc_message.search(text):
+                return 0.8
+            return 0
+
+        def get_tokens_unprocessed(self, text, stack=('root',)):
+            from pygments.lexers._cocoa_builtins import COCOA_INTERFACES, \
+                COCOA_PROTOCOLS, COCOA_PRIMITIVES
+
+            for index, token, value in \
+                    baselexer.get_tokens_unprocessed(self, text, stack):
+                if token is Name or token is Name.Class:
+                    if value in COCOA_INTERFACES or value in COCOA_PROTOCOLS \
+                       or value in COCOA_PRIMITIVES:
+                        token = Name.Builtin.Pseudo
+
+                yield index, token, value
+
+    return GeneratedObjectiveCVariant
+
+
+class ObjectiveCLexer(objective(CLexer)):
+    """
+    For Objective-C source code with preprocessor directives.
+    """
+
+    name = 'Objective-C'
+    url = 'https://developer.apple.com/library/archive/documentation/Cocoa/Conceptual/ProgrammingWithObjectiveC/Introduction/Introduction.html'
+    aliases = ['objective-c', 'objectivec', 'obj-c', 'objc']
+    filenames = ['*.m', '*.h']
+    mimetypes = ['text/x-objective-c']
+    version_added = ''
+    priority = 0.05    # Lower than C
+
+
+class ObjectiveCppLexer(objective(CppLexer)):
+    """
+    For Objective-C++ source code with preprocessor directives.
+    """
+
+    name = 'Objective-C++'
+    aliases = ['objective-c++', 'objectivec++', 'obj-c++', 'objc++']
+    filenames = ['*.mm', '*.hh']
+    mimetypes = ['text/x-objective-c++']
+    version_added = ''
+    priority = 0.05    # Lower than C++
+
+
+class LogosLexer(ObjectiveCppLexer):
+    """
+    For Logos + Objective-C source code with preprocessor directives.
+    """
+
+    name = 'Logos'
+    aliases = ['logos']
+    filenames = ['*.x', '*.xi', '*.xm', '*.xmi']
+    mimetypes = ['text/x-logos']
+    version_added = '1.6'
+    priority = 0.25
+
+    tokens = {
+        'statements': [
+            (r'(%orig|%log)\b', Keyword),
+            (r'(%c)\b(\()(\s*)([a-zA-Z$_][\w$]*)(\s*)(\))',
+             bygroups(Keyword, Punctuation, Text, Name.Class, Text, Punctuation)),
+            (r'(%init)\b(\()',
+             bygroups(Keyword, Punctuation), 'logos_init_directive'),
+            (r'(%init)(?=\s*;)', bygroups(Keyword)),
+            (r'(%hook|%group)(\s+)([a-zA-Z$_][\w$]+)',
+             bygroups(Keyword, Text, Name.Class), '#pop'),
+            (r'(%subclass)(\s+)', bygroups(Keyword, Text),
+             ('#pop', 'logos_classname')),
+            inherit,
+        ],
+        'logos_init_directive': [
+            (r'\s+', Text),
+            (',', Punctuation, ('logos_init_directive', '#pop')),
+            (r'([a-zA-Z$_][\w$]*)(\s*)(=)(\s*)([^);]*)',
+             bygroups(Name.Class, Text, Punctuation, Text, Text)),
+            (r'([a-zA-Z$_][\w$]*)', Name.Class),
+            (r'\)', Punctuation, '#pop'),
+        ],
+        'logos_classname': [
+            (r'([a-zA-Z$_][\w$]*)(\s*:\s*)([a-zA-Z$_][\w$]*)?',
+             bygroups(Name.Class, Text, Name.Class), '#pop'),
+            (r'([a-zA-Z$_][\w$]*)', Name.Class, '#pop')
+        ],
+        'root': [
+            (r'(%subclass)(\s+)', bygroups(Keyword, Text),
+             'logos_classname'),
+            (r'(%hook|%group)(\s+)([a-zA-Z$_][\w$]+)',
+             bygroups(Keyword, Text, Name.Class)),
+            (r'(%config)(\s*\(\s*)(\w+)(\s*=)(.*?)(\)\s*)',
+             bygroups(Keyword, Text, Name.Variable, Text, String, Text)),
+            (r'(%ctor)(\s*)(\{)', bygroups(Keyword, Text, Punctuation),
+             'function'),
+            (r'(%new)(\s*)(\()(.*?)(\))',
+             bygroups(Keyword, Text, Keyword, String, Keyword)),
+            (r'(\s*)(%end)(\s*)', bygroups(Text, Keyword, Text)),
+            inherit,
+        ],
+    }
+
+    _logos_keywords = re.compile(r'%(?:hook|ctor|init|c\()')
+
+    def analyse_text(text):
+        if LogosLexer._logos_keywords.search(text):
+            return 1.0
+        return 0
+
+
+class SwiftLexer(RegexLexer):
+    """
+    For Swift source.
+    """
+    name = 'Swift'
+    url = 'https://www.swift.org/'
+    filenames = ['*.swift']
+    aliases = ['swift']
+    mimetypes = ['text/x-swift']
+    version_added = '2.0'
+
+    tokens = {
+        'root': [
+            # Whitespace and Comments
+            (r'\n', Text),
+            (r'\s+', Whitespace),
+            (r'//', Comment.Single, 'comment-single'),
+            (r'/\*', Comment.Multiline, 'comment-multi'),
+            (r'#(if|elseif|else|endif|available)\b', Comment.Preproc, 'preproc'),
+
+            # Keywords
+            include('keywords'),
+
+            # Global Types
+            (words((
+                'Array', 'AutoreleasingUnsafeMutablePointer', 'BidirectionalReverseView',
+                'Bit', 'Bool', 'CFunctionPointer', 'COpaquePointer', 'CVaListPointer',
+                'Character', 'ClosedInterval', 'CollectionOfOne', 'ContiguousArray',
+                'Dictionary', 'DictionaryGenerator', 'DictionaryIndex', 'Double',
+                'EmptyCollection', 'EmptyGenerator', 'EnumerateGenerator',
+                'EnumerateSequence', 'FilterCollectionView',
+                'FilterCollectionViewIndex', 'FilterGenerator', 'FilterSequenceView',
+                'Float', 'Float80', 'FloatingPointClassification', 'GeneratorOf',
+                'GeneratorOfOne', 'GeneratorSequence', 'HalfOpenInterval', 'HeapBuffer',
+                'HeapBufferStorage', 'ImplicitlyUnwrappedOptional', 'IndexingGenerator',
+                'Int', 'Int16', 'Int32', 'Int64', 'Int8', 'LazyBidirectionalCollection',
+                'LazyForwardCollection', 'LazyRandomAccessCollection',
+                'LazySequence', 'MapCollectionView', 'MapSequenceGenerator',
+                'MapSequenceView', 'MirrorDisposition', 'ObjectIdentifier', 'OnHeap',
+                'Optional', 'PermutationGenerator', 'QuickLookObject',
+                'RandomAccessReverseView', 'Range', 'RangeGenerator', 'RawByte', 'Repeat',
+                'ReverseBidirectionalIndex', 'ReverseRandomAccessIndex', 'SequenceOf',
+                'SinkOf', 'Slice', 'StaticString', 'StrideThrough', 'StrideThroughGenerator',
+                'StrideTo', 'StrideToGenerator', 'String', 'UInt', 'UInt16', 'UInt32',
+                'UInt64', 'UInt8', 'UTF16', 'UTF32', 'UTF8', 'UnicodeDecodingResult',
+                'UnicodeScalar', 'Unmanaged', 'UnsafeBufferPointer',
+                'UnsafeBufferPointerGenerator', 'UnsafeMutableBufferPointer',
+                'UnsafeMutablePointer', 'UnsafePointer', 'Zip2', 'ZipGenerator2',
+                # Protocols
+                'AbsoluteValuable', 'AnyObject', 'ArrayLiteralConvertible',
+                'BidirectionalIndexType', 'BitwiseOperationsType',
+                'BooleanLiteralConvertible', 'BooleanType', 'CVarArgType',
+                'CollectionType', 'Comparable', 'DebugPrintable',
+                'DictionaryLiteralConvertible', 'Equatable',
+                'ExtendedGraphemeClusterLiteralConvertible',
+                'ExtensibleCollectionType', 'FloatLiteralConvertible',
+                'FloatingPointType', 'ForwardIndexType', 'GeneratorType', 'Hashable',
+                'IntegerArithmeticType', 'IntegerLiteralConvertible', 'IntegerType',
+                'IntervalType', 'MirrorType', 'MutableCollectionType', 'MutableSliceable',
+                'NilLiteralConvertible', 'OutputStreamType', 'Printable',
+                'RandomAccessIndexType', 'RangeReplaceableCollectionType',
+                'RawOptionSetType', 'RawRepresentable', 'Reflectable', 'SequenceType',
+                'SignedIntegerType', 'SignedNumberType', 'SinkType', 'Sliceable',
+                'Streamable', 'Strideable', 'StringInterpolationConvertible',
+                'StringLiteralConvertible', 'UnicodeCodecType',
+                'UnicodeScalarLiteralConvertible', 'UnsignedIntegerType',
+                '_ArrayBufferType', '_BidirectionalIndexType', '_CocoaStringType',
+                '_CollectionType', '_Comparable', '_ExtensibleCollectionType',
+                '_ForwardIndexType', '_Incrementable', '_IntegerArithmeticType',
+                '_IntegerType', '_ObjectiveCBridgeable', '_RandomAccessIndexType',
+                '_RawOptionSetType', '_SequenceType', '_Sequence_Type',
+                '_SignedIntegerType', '_SignedNumberType', '_Sliceable', '_Strideable',
+                '_SwiftNSArrayRequiredOverridesType', '_SwiftNSArrayType',
+                '_SwiftNSCopyingType', '_SwiftNSDictionaryRequiredOverridesType',
+                '_SwiftNSDictionaryType', '_SwiftNSEnumeratorType',
+                '_SwiftNSFastEnumerationType', '_SwiftNSStringRequiredOverridesType',
+                '_SwiftNSStringType', '_UnsignedIntegerType',
+                # Variables
+                'C_ARGC', 'C_ARGV', 'Process',
+                # Typealiases
+                'Any', 'AnyClass', 'BooleanLiteralType', 'CBool', 'CChar', 'CChar16',
+                'CChar32', 'CDouble', 'CFloat', 'CInt', 'CLong', 'CLongLong', 'CShort',
+                'CSignedChar', 'CUnsignedInt', 'CUnsignedLong', 'CUnsignedShort',
+                'CWideChar', 'ExtendedGraphemeClusterType', 'Float32', 'Float64',
+                'FloatLiteralType', 'IntMax', 'IntegerLiteralType', 'StringLiteralType',
+                'UIntMax', 'UWord', 'UnicodeScalarType', 'Void', 'Word',
+                # Foundation/Cocoa
+                'NSErrorPointer', 'NSObjectProtocol', 'Selector'), suffix=r'\b'),
+             Name.Builtin),
+            # Functions
+            (words((
+                'abs', 'advance', 'alignof', 'alignofValue', 'assert', 'assertionFailure',
+                'contains', 'count', 'countElements', 'debugPrint', 'debugPrintln',
+                'distance', 'dropFirst', 'dropLast', 'dump', 'enumerate', 'equal',
+                'extend', 'fatalError', 'filter', 'find', 'first', 'getVaList', 'indices',
+                'insert', 'isEmpty', 'join', 'last', 'lazy', 'lexicographicalCompare',
+                'map', 'max', 'maxElement', 'min', 'minElement', 'numericCast', 'overlaps',
+                'partition', 'precondition', 'preconditionFailure', 'prefix', 'print',
+                'println', 'reduce', 'reflect', 'removeAll', 'removeAtIndex', 'removeLast',
+                'removeRange', 'reverse', 'sizeof', 'sizeofValue', 'sort', 'sorted',
+                'splice', 'split', 'startsWith', 'stride', 'strideof', 'strideofValue',
+                'suffix', 'swap', 'toDebugString', 'toString', 'transcode',
+                'underestimateCount', 'unsafeAddressOf', 'unsafeBitCast', 'unsafeDowncast',
+                'withExtendedLifetime', 'withUnsafeMutablePointer',
+                'withUnsafeMutablePointers', 'withUnsafePointer', 'withUnsafePointers',
+                'withVaList'), suffix=r'\b'),
+             Name.Builtin.Pseudo),
+
+            # Implicit Block Variables
+            (r'\$\d+', Name.Variable),
+
+            # Binary Literal
+            (r'0b[01_]+', Number.Bin),
+            # Octal Literal
+            (r'0o[0-7_]+', Number.Oct),
+            # Hexadecimal Literal
+            (r'0x[0-9a-fA-F_]+', Number.Hex),
+            # Decimal Literal
+            (r'[0-9][0-9_]*(\.[0-9_]+[eE][+\-]?[0-9_]+|'
+             r'\.[0-9_]*|[eE][+\-]?[0-9_]+)', Number.Float),
+            (r'[0-9][0-9_]*', Number.Integer),
+            # String Literal
+            (r'"""', String, 'string-multi'),
+            (r'"', String, 'string'),
+
+            # Operators and Punctuation
+            (r'[(){}\[\].,:;=@#`?]|->|[<&?](?=\w)|(?<=\w)[>!?]', Punctuation),
+            (r'[/=\-+!*%<>&|^?~]+', Operator),
+
+            # Identifier
+            (r'[a-zA-Z_]\w*', Name)
+        ],
+        'keywords': [
+            (words((
+                'as', 'async', 'await', 'break', 'case', 'catch', 'continue', 'default', 'defer',
+                'do', 'else', 'fallthrough', 'for', 'guard', 'if', 'in', 'is',
+                'repeat', 'return', '#selector', 'switch', 'throw', 'try',
+                'where', 'while'), suffix=r'\b'),
+             Keyword),
+            (r'@availability\([^)]+\)', Keyword.Reserved),
+            (words((
+                'associativity', 'convenience', 'dynamic', 'didSet', 'final',
+                'get', 'indirect', 'infix', 'inout', 'lazy', 'left', 'mutating',
+                'none', 'nonmutating', 'optional', 'override', 'postfix',
+                'precedence', 'prefix', 'Protocol', 'required', 'rethrows',
+                'right', 'set', 'throws', 'Type', 'unowned', 'weak', 'willSet',
+                '@availability', '@autoclosure', '@noreturn',
+                '@NSApplicationMain', '@NSCopying', '@NSManaged', '@objc',
+                '@UIApplicationMain', '@IBAction', '@IBDesignable',
+                '@IBInspectable', '@IBOutlet'), suffix=r'\b'),
+             Keyword.Reserved),
+            (r'(as|dynamicType|false|is|nil|self|Self|super|true|__COLUMN__'
+             r'|__FILE__|__FUNCTION__|__LINE__|_'
+             r'|#(?:file|line|column|function))\b', Keyword.Constant),
+            (r'import\b', Keyword.Declaration, 'module'),
+            (r'(class|enum|extension|struct|protocol)(\s+)([a-zA-Z_]\w*)',
+             bygroups(Keyword.Declaration, Whitespace, Name.Class)),
+            (r'(func)(\s+)([a-zA-Z_]\w*)',
+             bygroups(Keyword.Declaration, Whitespace, Name.Function)),
+            (r'(var|let)(\s+)([a-zA-Z_]\w*)', bygroups(Keyword.Declaration,
+             Whitespace, Name.Variable)),
+            (words((
+                'actor', 'associatedtype', 'class', 'deinit', 'enum', 'extension', 'func', 'import',
+                'init', 'internal', 'let', 'operator', 'private', 'protocol', 'public',
+                'static', 'struct', 'subscript', 'typealias', 'var'), suffix=r'\b'),
+             Keyword.Declaration)
+        ],
+        'comment': [
+            (r':param: [a-zA-Z_]\w*|:returns?:|(FIXME|MARK|TODO):',
+             Comment.Special)
+        ],
+
+        # Nested
+        'comment-single': [
+            (r'\n', Whitespace, '#pop'),
+            include('comment'),
+            (r'[^\n]+', Comment.Single)
+        ],
+        'comment-multi': [
+            include('comment'),
+            (r'[^*/]+', Comment.Multiline),
+            (r'/\*', Comment.Multiline, '#push'),
+            (r'\*/', Comment.Multiline, '#pop'),
+            (r'[*/]+', Comment.Multiline)
+        ],
+        'module': [
+            (r'\n', Whitespace, '#pop'),
+            (r'[a-zA-Z_]\w*', Name.Class),
+            include('root')
+        ],
+        'preproc': [
+            (r'\n', Whitespace, '#pop'),
+            include('keywords'),
+            (r'[A-Za-z]\w*', Comment.Preproc),
+            include('root')
+        ],
+        'string': [
+            (r'"', String, '#pop'),
+            include("string-common"),
+        ],
+        'string-multi': [
+            (r'"""', String, '#pop'),
+            include("string-common"),
+        ],
+        'string-common': [
+            (r'\\\(', String.Interpol, 'string-intp'),
+            (r"""\\['"\\nrt]|\\x[0-9a-fA-F]{2}|\\[0-7]{1,3}"""
+             r"""|\\u[0-9a-fA-F]{4}|\\U[0-9a-fA-F]{8}""", String.Escape),
+            (r'[^\\"]+', String),
+            (r'\\', String)
+        ],
+        'string-intp': [
+            (r'\(', String.Interpol, '#push'),
+            (r'\)', String.Interpol, '#pop'),
+            include('root')
+        ]
+    }
+
+    def get_tokens_unprocessed(self, text):
+        from pygments.lexers._cocoa_builtins import COCOA_INTERFACES, \
+            COCOA_PROTOCOLS, COCOA_PRIMITIVES
+
+        for index, token, value in \
+                RegexLexer.get_tokens_unprocessed(self, text):
+            if token is Name or token is Name.Class:
+                if value in COCOA_INTERFACES or value in COCOA_PROTOCOLS \
+                   or value in COCOA_PRIMITIVES:
+                    token = Name.Builtin.Pseudo
+
+            yield index, token, value
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/ooc.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/ooc.py
new file mode 100644
index 0000000000000000000000000000000000000000..f6aea8c830689523903c913699927004208652bb
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/ooc.py
@@ -0,0 +1,84 @@
+"""
+    pygments.lexers.ooc
+    ~~~~~~~~~~~~~~~~~~~
+
+    Lexers for the Ooc language.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, bygroups, words
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation
+
+__all__ = ['OocLexer']
+
+
+class OocLexer(RegexLexer):
+    """
+    For Ooc source code
+    """
+    name = 'Ooc'
+    url = 'https://ooc-lang.github.io/'
+    aliases = ['ooc']
+    filenames = ['*.ooc']
+    mimetypes = ['text/x-ooc']
+    version_added = '1.2'
+
+    tokens = {
+        'root': [
+            (words((
+                'class', 'interface', 'implement', 'abstract', 'extends', 'from',
+                'this', 'super', 'new', 'const', 'final', 'static', 'import',
+                'use', 'extern', 'inline', 'proto', 'break', 'continue',
+                'fallthrough', 'operator', 'if', 'else', 'for', 'while', 'do',
+                'switch', 'case', 'as', 'in', 'version', 'return', 'true',
+                'false', 'null'), prefix=r'\b', suffix=r'\b'),
+             Keyword),
+            (r'include\b', Keyword, 'include'),
+            (r'(cover)([ \t]+)(from)([ \t]+)(\w+[*@]?)',
+             bygroups(Keyword, Text, Keyword, Text, Name.Class)),
+            (r'(func)((?:[ \t]|\\\n)+)(~[a-z_]\w*)',
+             bygroups(Keyword, Text, Name.Function)),
+            (r'\bfunc\b', Keyword),
+            # Note: %= not listed on https://ooc-lang.github.io/docs/lang/operators/
+            (r'//.*', Comment),
+            (r'(?s)/\*.*?\*/', Comment.Multiline),
+            (r'(==?|\+=?|-[=>]?|\*=?|/=?|:=|!=?|%=?|\?|>{1,3}=?|<{1,3}=?|\.\.|'
+             r'&&?|\|\|?|\^=?)', Operator),
+            (r'(\.)([ \t]*)([a-z]\w*)', bygroups(Operator, Text,
+                                                 Name.Function)),
+            (r'[A-Z][A-Z0-9_]+', Name.Constant),
+            (r'[A-Z]\w*([@*]|\[[ \t]*\])?', Name.Class),
+
+            (r'([a-z]\w*(?:~[a-z]\w*)?)((?:[ \t]|\\\n)*)(?=\()',
+             bygroups(Name.Function, Text)),
+            (r'[a-z]\w*', Name.Variable),
+
+            # : introduces types
+            (r'[:(){}\[\];,]', Punctuation),
+
+            (r'0x[0-9a-fA-F]+', Number.Hex),
+            (r'0c[0-9]+', Number.Oct),
+            (r'0b[01]+', Number.Bin),
+            (r'[0-9_]\.[0-9_]*(?!\.)', Number.Float),
+            (r'[0-9_]+', Number.Decimal),
+
+            (r'"(?:\\.|\\[0-7]{1,3}|\\x[a-fA-F0-9]{1,2}|[^\\"])*"',
+             String.Double),
+            (r"'(?:\\.|\\[0-9]{1,3}|\\x[a-fA-F0-9]{1,2}|[^\\\'\n])'",
+             String.Char),
+            (r'@', Punctuation),  # pointer dereference
+            (r'\.', Punctuation),  # imports or chain operator
+
+            (r'\\[ \t\n]', Text),
+            (r'[ \t]+', Text),
+        ],
+        'include': [
+            (r'[\w/]+', Name),
+            (r',', Punctuation),
+            (r'[ \t]', Text),
+            (r'[;\n]', Text, '#pop'),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/openscad.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/openscad.py
new file mode 100644
index 0000000000000000000000000000000000000000..1ec8fea051ca0d0c1e13a281158bfe85c63ec365
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/openscad.py
@@ -0,0 +1,96 @@
+"""
+    pygments.lexers.openscad
+    ~~~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for the OpenSCAD languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, bygroups, words, include
+from pygments.token import Text, Comment, Punctuation, Operator, Keyword, Name, Number, Whitespace, Literal, String
+
+__all__ = ['OpenScadLexer']
+
+
+class OpenScadLexer(RegexLexer):
+    """For openSCAD code.
+    """
+    name = "OpenSCAD"
+    url = "https://openscad.org/"
+    aliases = ["openscad"]
+    filenames = ["*.scad"]
+    mimetypes = ["application/x-openscad"]
+    version_added = '2.16'
+
+    tokens = {
+        "root": [
+            (r"[^\S\n]+", Whitespace),
+            (r'//', Comment.Single, 'comment-single'),
+            (r'/\*', Comment.Multiline, 'comment-multi'),
+            (r"[{}\[\]\(\),;:]", Punctuation),
+            (r"[*!#%\-+=?/]", Operator),
+            (r"<=|<|==|!=|>=|>|&&|\|\|", Operator),
+            (r"\$(f[asn]|t|vp[rtd]|children)", Operator),
+            (r"(undef|PI)\b", Keyword.Constant),
+            (
+                r"(use|include)((?:\s|\\\\s)+)",
+                bygroups(Keyword.Namespace, Text),
+                "includes",
+            ),
+            (r"(module)(\s*)([^\s\(]+)",
+             bygroups(Keyword.Namespace, Whitespace, Name.Namespace)),
+            (r"(function)(\s*)([^\s\(]+)",
+             bygroups(Keyword.Declaration, Whitespace, Name.Function)),
+            (words(("true", "false"), prefix=r"\b", suffix=r"\b"), Literal),
+            (words((
+                "function", "module", "include", "use", "for",
+                "intersection_for", "if", "else", "return"
+                ), prefix=r"\b", suffix=r"\b"), Keyword
+            ),
+            (words((
+                "circle", "square", "polygon", "text", "sphere", "cube",
+                "cylinder", "polyhedron", "translate", "rotate", "scale",
+                "resize", "mirror", "multmatrix", "color", "offset", "hull",
+                "minkowski", "union", "difference", "intersection", "abs",
+                "sign", "sin", "cos", "tan", "acos", "asin", "atan", "atan2",
+                "floor", "round", "ceil", "ln", "log", "pow", "sqrt", "exp",
+                "rands", "min", "max", "concat", "lookup", "str", "chr",
+                "search", "version", "version_num", "norm", "cross",
+                "parent_module", "echo", "import", "import_dxf",
+                "dxf_linear_extrude", "linear_extrude", "rotate_extrude",
+                "surface", "projection", "render", "dxf_cross",
+                "dxf_dim", "let", "assign", "len"
+                ), prefix=r"\b", suffix=r"\b"),
+                Name.Builtin
+            ),
+            (r"\bchildren\b", Name.Builtin.Pseudo),
+            (r'""".*?"""', String.Double),
+            (r'"(\\\\|\\[^\\]|[^"\\])*"', String.Double),
+            (r"-?\d+(\.\d+)?(e[+-]?\d+)?", Number),
+            (r"\w+", Name),
+        ],
+        "includes": [
+            (
+                r"(<)([^>]*)(>)",
+                bygroups(Punctuation, Comment.PreprocFile, Punctuation),
+            ),
+        ],
+        'comment': [
+            (r':param: [a-zA-Z_]\w*|:returns?:|(FIXME|MARK|TODO):',
+             Comment.Special)
+        ],
+        'comment-single': [
+            (r'\n', Text, '#pop'),
+            include('comment'),
+            (r'[^\n]+', Comment.Single)
+        ],
+        'comment-multi': [
+            include('comment'),
+            (r'[^*/]+', Comment.Multiline),
+            (r'/\*', Comment.Multiline, '#push'),
+            (r'\*/', Comment.Multiline, '#pop'),
+            (r'[*/]', Comment.Multiline)
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/other.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/other.py
new file mode 100644
index 0000000000000000000000000000000000000000..8767d73037b75095486aa46ad3b89a002156fc8b
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/other.py
@@ -0,0 +1,41 @@
+"""
+    pygments.lexers.other
+    ~~~~~~~~~~~~~~~~~~~~~
+
+    Just export lexer classes previously contained in this module.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+# ruff: noqa: F401
+from pygments.lexers.sql import SqlLexer, MySqlLexer, SqliteConsoleLexer
+from pygments.lexers.shell import BashLexer, BashSessionLexer, BatchLexer, \
+    TcshLexer
+from pygments.lexers.robotframework import RobotFrameworkLexer
+from pygments.lexers.testing import GherkinLexer
+from pygments.lexers.esoteric import BrainfuckLexer, BefungeLexer, RedcodeLexer
+from pygments.lexers.prolog import LogtalkLexer
+from pygments.lexers.snobol import SnobolLexer
+from pygments.lexers.rebol import RebolLexer
+from pygments.lexers.configs import KconfigLexer, Cfengine3Lexer
+from pygments.lexers.modeling import ModelicaLexer
+from pygments.lexers.scripting import AppleScriptLexer, MOOCodeLexer, \
+    HybrisLexer
+from pygments.lexers.graphics import PostScriptLexer, GnuplotLexer, \
+    AsymptoteLexer, PovrayLexer
+from pygments.lexers.business import ABAPLexer, OpenEdgeLexer, \
+    GoodDataCLLexer, MaqlLexer
+from pygments.lexers.automation import AutoItLexer, AutohotkeyLexer
+from pygments.lexers.dsls import ProtoBufLexer, BroLexer, PuppetLexer, \
+    MscgenLexer, VGLLexer
+from pygments.lexers.basic import CbmBasicV2Lexer
+from pygments.lexers.pawn import SourcePawnLexer, PawnLexer
+from pygments.lexers.ecl import ECLLexer
+from pygments.lexers.urbi import UrbiscriptLexer
+from pygments.lexers.smalltalk import SmalltalkLexer, NewspeakLexer
+from pygments.lexers.installers import NSISLexer, RPMSpecLexer
+from pygments.lexers.textedit import AwkLexer
+from pygments.lexers.smv import NuSMVLexer
+
+__all__ = []
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/parasail.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/parasail.py
new file mode 100644
index 0000000000000000000000000000000000000000..9b409609f8b1ea3211f0364273dd8280b65e0d0c
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/parasail.py
@@ -0,0 +1,78 @@
+"""
+    pygments.lexers.parasail
+    ~~~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for ParaSail.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, include
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation, Literal
+
+__all__ = ['ParaSailLexer']
+
+
+class ParaSailLexer(RegexLexer):
+    """
+    For ParaSail source code.
+    """
+
+    name = 'ParaSail'
+    url = 'http://www.parasail-lang.org'
+    aliases = ['parasail']
+    filenames = ['*.psi', '*.psl']
+    mimetypes = ['text/x-parasail']
+    version_added = '2.1'
+
+    flags = re.MULTILINE
+
+    tokens = {
+        'root': [
+            (r'[^\S\n]+', Text),
+            (r'//.*?\n', Comment.Single),
+            (r'\b(and|or|xor)=', Operator.Word),
+            (r'\b(and(\s+then)?|or(\s+else)?|xor|rem|mod|'
+             r'(is|not)\s+null)\b',
+             Operator.Word),
+            # Keywords
+            (r'\b(abs|abstract|all|block|class|concurrent|const|continue|'
+             r'each|end|exit|extends|exports|forward|func|global|implements|'
+             r'import|in|interface|is|lambda|locked|new|not|null|of|op|'
+             r'optional|private|queued|ref|return|reverse|separate|some|'
+             r'type|until|var|with|'
+             # Control flow
+             r'if|then|else|elsif|case|for|while|loop)\b',
+             Keyword.Reserved),
+            (r'(abstract\s+)?(interface|class|op|func|type)',
+             Keyword.Declaration),
+            # Literals
+            (r'"[^"]*"', String),
+            (r'\\[\'ntrf"0]', String.Escape),
+            (r'#[a-zA-Z]\w*', Literal),       # Enumeration
+            include('numbers'),
+            (r"'[^']'", String.Char),
+            (r'[a-zA-Z]\w*', Name),
+            # Operators and Punctuation
+            (r'(<==|==>|<=>|\*\*=|<\|=|<<=|>>=|==|!=|=\?|<=|>=|'
+             r'\*\*|<<|>>|=>|:=|\+=|-=|\*=|\|=|\||/=|\+|-|\*|/|'
+             r'\.\.|<\.\.|\.\.<|<\.\.<)',
+             Operator),
+            (r'(<|>|\[|\]|\(|\)|\||:|;|,|.|\{|\}|->)',
+             Punctuation),
+            (r'\n+', Text),
+        ],
+        'numbers': [
+            (r'\d[0-9_]*#[0-9a-fA-F][0-9a-fA-F_]*#', Number.Hex),  # any base
+            (r'0[xX][0-9a-fA-F][0-9a-fA-F_]*', Number.Hex),        # C-like hex
+            (r'0[bB][01][01_]*', Number.Bin),                      # C-like bin
+            (r'\d[0-9_]*\.\d[0-9_]*[eE][+-]\d[0-9_]*',             # float exp
+             Number.Float),
+            (r'\d[0-9_]*\.\d[0-9_]*', Number.Float),               # float
+            (r'\d[0-9_]*', Number.Integer),                        # integer
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/parsers.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/parsers.py
new file mode 100644
index 0000000000000000000000000000000000000000..baa49b05407cbb85e9f0b72d653fd862f0323d34
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/parsers.py
@@ -0,0 +1,798 @@
+"""
+    pygments.lexers.parsers
+    ~~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for parser generators.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, DelegatingLexer, \
+    include, bygroups, using
+from pygments.token import Punctuation, Other, Text, Comment, Operator, \
+    Keyword, Name, String, Number, Whitespace
+from pygments.lexers.jvm import JavaLexer
+from pygments.lexers.c_cpp import CLexer, CppLexer
+from pygments.lexers.objective import ObjectiveCLexer
+from pygments.lexers.d import DLexer
+from pygments.lexers.dotnet import CSharpLexer
+from pygments.lexers.ruby import RubyLexer
+from pygments.lexers.python import PythonLexer
+from pygments.lexers.perl import PerlLexer
+
+__all__ = ['RagelLexer', 'RagelEmbeddedLexer', 'RagelCLexer', 'RagelDLexer',
+           'RagelCppLexer', 'RagelObjectiveCLexer', 'RagelRubyLexer',
+           'RagelJavaLexer', 'AntlrLexer', 'AntlrPythonLexer',
+           'AntlrPerlLexer', 'AntlrRubyLexer', 'AntlrCppLexer',
+           'AntlrCSharpLexer', 'AntlrObjectiveCLexer',
+           'AntlrJavaLexer', 'AntlrActionScriptLexer',
+           'TreetopLexer', 'EbnfLexer']
+
+
+class RagelLexer(RegexLexer):
+    """A pure `Ragel `_ lexer.
+
+    Use this for fragments of Ragel.  For ``.rl`` files, use
+    :class:`RagelEmbeddedLexer` instead (or one of the language-specific
+    subclasses).
+    """
+
+    name = 'Ragel'
+    url = 'http://www.colm.net/open-source/ragel/'
+    aliases = ['ragel']
+    filenames = []
+    version_added = '1.1'
+
+    tokens = {
+        'whitespace': [
+            (r'\s+', Whitespace)
+        ],
+        'comments': [
+            (r'\#.*$', Comment),
+        ],
+        'keywords': [
+            (r'(access|action|alphtype)\b', Keyword),
+            (r'(getkey|write|machine|include)\b', Keyword),
+            (r'(any|ascii|extend|alpha|digit|alnum|lower|upper)\b', Keyword),
+            (r'(xdigit|cntrl|graph|print|punct|space|zlen|empty)\b', Keyword)
+        ],
+        'numbers': [
+            (r'0x[0-9A-Fa-f]+', Number.Hex),
+            (r'[+-]?[0-9]+', Number.Integer),
+        ],
+        'literals': [
+            (r'"(\\\\|\\[^\\]|[^"\\])*"', String.Double),
+            (r"'(\\\\|\\[^\\]|[^'\\])*'", String.Single),
+            (r'\[(\\\\|\\[^\\]|[^\\\]])*\]', String),          # square bracket literals
+            (r'/(?!\*)(\\\\|\\[^\\]|[^/\\])*/', String.Regex),  # regular expressions
+        ],
+        'identifiers': [
+            (r'[a-zA-Z_]\w*', Name.Variable),
+        ],
+        'operators': [
+            (r',', Operator),                           # Join
+            (r'\||&|--?', Operator),                    # Union, Intersection and Subtraction
+            (r'\.|<:|:>>?', Operator),                  # Concatention
+            (r':', Operator),                           # Label
+            (r'->', Operator),                          # Epsilon Transition
+            (r'(>|\$|%|<|@|<>)(/|eof\b)', Operator),    # EOF Actions
+            (r'(>|\$|%|<|@|<>)(!|err\b)', Operator),    # Global Error Actions
+            (r'(>|\$|%|<|@|<>)(\^|lerr\b)', Operator),  # Local Error Actions
+            (r'(>|\$|%|<|@|<>)(~|to\b)', Operator),     # To-State Actions
+            (r'(>|\$|%|<|@|<>)(\*|from\b)', Operator),  # From-State Actions
+            (r'>|@|\$|%', Operator),                    # Transition Actions and Priorities
+            (r'\*|\?|\+|\{[0-9]*,[0-9]*\}', Operator),  # Repetition
+            (r'!|\^', Operator),                        # Negation
+            (r'\(|\)', Operator),                       # Grouping
+        ],
+        'root': [
+            include('literals'),
+            include('whitespace'),
+            include('comments'),
+            include('keywords'),
+            include('numbers'),
+            include('identifiers'),
+            include('operators'),
+            (r'\{', Punctuation, 'host'),
+            (r'=', Operator),
+            (r';', Punctuation),
+        ],
+        'host': [
+            (r'(' + r'|'.join((  # keep host code in largest possible chunks
+                r'[^{}\'"/#]+',  # exclude unsafe characters
+                r'[^\\]\\[{}]',  # allow escaped { or }
+
+                # strings and comments may safely contain unsafe characters
+                r'"(\\\\|\\[^\\]|[^"\\])*"',
+                r"'(\\\\|\\[^\\]|[^'\\])*'",
+                r'//.*$\n?',            # single line comment
+                r'/\*(.|\n)*?\*/',      # multi-line javadoc-style comment
+                r'\#.*$\n?',            # ruby comment
+
+                # regular expression: There's no reason for it to start
+                # with a * and this stops confusion with comments.
+                r'/(?!\*)(\\\\|\\[^\\]|[^/\\])*/',
+
+                # / is safe now that we've handled regex and javadoc comments
+                r'/',
+            )) + r')+', Other),
+
+            (r'\{', Punctuation, '#push'),
+            (r'\}', Punctuation, '#pop'),
+        ],
+    }
+
+
+class RagelEmbeddedLexer(RegexLexer):
+    """
+    A lexer for Ragel embedded in a host language file.
+
+    This will only highlight Ragel statements. If you want host language
+    highlighting then call the language-specific Ragel lexer.
+    """
+
+    name = 'Embedded Ragel'
+    aliases = ['ragel-em']
+    filenames = ['*.rl']
+    url = 'http://www.colm.net/open-source/ragel/'
+    version_added = '1.1'
+
+    tokens = {
+        'root': [
+            (r'(' + r'|'.join((   # keep host code in largest possible chunks
+                r'[^%\'"/#]+',    # exclude unsafe characters
+                r'%(?=[^%]|$)',   # a single % sign is okay, just not 2 of them
+
+                # strings and comments may safely contain unsafe characters
+                r'"(\\\\|\\[^\\]|[^"\\])*"',
+                r"'(\\\\|\\[^\\]|[^'\\])*'",
+                r'/\*(.|\n)*?\*/',      # multi-line javadoc-style comment
+                r'//.*$\n?',  # single line comment
+                r'\#.*$\n?',  # ruby/ragel comment
+                r'/(?!\*)(\\\\|\\[^\\]|[^/\\])*/',  # regular expression
+
+                # / is safe now that we've handled regex and javadoc comments
+                r'/',
+            )) + r')+', Other),
+
+            # Single Line FSM.
+            # Please don't put a quoted newline in a single line FSM.
+            # That's just mean. It will break this.
+            (r'(%%)(?![{%])(.*)($|;)(\n?)', bygroups(Punctuation,
+                                                     using(RagelLexer),
+                                                     Punctuation, Text)),
+
+            # Multi Line FSM.
+            (r'(%%%%|%%)\{', Punctuation, 'multi-line-fsm'),
+        ],
+        'multi-line-fsm': [
+            (r'(' + r'|'.join((  # keep ragel code in largest possible chunks.
+                r'(' + r'|'.join((
+                    r'[^}\'"\[/#]',   # exclude unsafe characters
+                    r'\}(?=[^%]|$)',   # } is okay as long as it's not followed by %
+                    r'\}%(?=[^%]|$)',  # ...well, one %'s okay, just not two...
+                    r'[^\\]\\[{}]',   # ...and } is okay if it's escaped
+
+                    # allow / if it's preceded with one of these symbols
+                    # (ragel EOF actions)
+                    r'(>|\$|%|<|@|<>)/',
+
+                    # specifically allow regex followed immediately by *
+                    # so it doesn't get mistaken for a comment
+                    r'/(?!\*)(\\\\|\\[^\\]|[^/\\])*/\*',
+
+                    # allow / as long as it's not followed by another / or by a *
+                    r'/(?=[^/*]|$)',
+
+                    # We want to match as many of these as we can in one block.
+                    # Not sure if we need the + sign here,
+                    # does it help performance?
+                )) + r')+',
+
+                # strings and comments may safely contain unsafe characters
+                r'"(\\\\|\\[^\\]|[^"\\])*"',
+                r"'(\\\\|\\[^\\]|[^'\\])*'",
+                r"\[(\\\\|\\[^\\]|[^\]\\])*\]",  # square bracket literal
+                r'/\*(.|\n)*?\*/',          # multi-line javadoc-style comment
+                r'//.*$\n?',                # single line comment
+                r'\#.*$\n?',                # ruby/ragel comment
+            )) + r')+', using(RagelLexer)),
+
+            (r'\}%%', Punctuation, '#pop'),
+        ]
+    }
+
+    def analyse_text(text):
+        return '@LANG: indep' in text
+
+
+class RagelRubyLexer(DelegatingLexer):
+    """
+    A lexer for Ragel in a Ruby host file.
+    """
+
+    name = 'Ragel in Ruby Host'
+    aliases = ['ragel-ruby', 'ragel-rb']
+    filenames = ['*.rl']
+    url = 'http://www.colm.net/open-source/ragel/'
+    version_added = '1.1'
+
+    def __init__(self, **options):
+        super().__init__(RubyLexer, RagelEmbeddedLexer, **options)
+
+    def analyse_text(text):
+        return '@LANG: ruby' in text
+
+
+class RagelCLexer(DelegatingLexer):
+    """
+    A lexer for Ragel in a C host file.
+    """
+
+    name = 'Ragel in C Host'
+    aliases = ['ragel-c']
+    filenames = ['*.rl']
+    url = 'http://www.colm.net/open-source/ragel/'
+    version_added = '1.1'
+
+    def __init__(self, **options):
+        super().__init__(CLexer, RagelEmbeddedLexer, **options)
+
+    def analyse_text(text):
+        return '@LANG: c' in text
+
+
+class RagelDLexer(DelegatingLexer):
+    """
+    A lexer for Ragel in a D host file.
+    """
+
+    name = 'Ragel in D Host'
+    aliases = ['ragel-d']
+    filenames = ['*.rl']
+    url = 'http://www.colm.net/open-source/ragel/'
+    version_added = '1.1'
+
+    def __init__(self, **options):
+        super().__init__(DLexer, RagelEmbeddedLexer, **options)
+
+    def analyse_text(text):
+        return '@LANG: d' in text
+
+
+class RagelCppLexer(DelegatingLexer):
+    """
+    A lexer for Ragel in a C++ host file.
+    """
+
+    name = 'Ragel in CPP Host'
+    aliases = ['ragel-cpp']
+    filenames = ['*.rl']
+    url = 'http://www.colm.net/open-source/ragel/'
+    version_added = '1.1'
+
+    def __init__(self, **options):
+        super().__init__(CppLexer, RagelEmbeddedLexer, **options)
+
+    def analyse_text(text):
+        return '@LANG: c++' in text
+
+
+class RagelObjectiveCLexer(DelegatingLexer):
+    """
+    A lexer for Ragel in an Objective C host file.
+    """
+
+    name = 'Ragel in Objective C Host'
+    aliases = ['ragel-objc']
+    filenames = ['*.rl']
+    url = 'http://www.colm.net/open-source/ragel/'
+    version_added = '1.1'
+
+    def __init__(self, **options):
+        super().__init__(ObjectiveCLexer, RagelEmbeddedLexer, **options)
+
+    def analyse_text(text):
+        return '@LANG: objc' in text
+
+
+class RagelJavaLexer(DelegatingLexer):
+    """
+    A lexer for Ragel in a Java host file.
+    """
+
+    name = 'Ragel in Java Host'
+    aliases = ['ragel-java']
+    filenames = ['*.rl']
+    url = 'http://www.colm.net/open-source/ragel/'
+    version_added = '1.1'
+
+    def __init__(self, **options):
+        super().__init__(JavaLexer, RagelEmbeddedLexer, **options)
+
+    def analyse_text(text):
+        return '@LANG: java' in text
+
+
+class AntlrLexer(RegexLexer):
+    """
+    Generic ANTLR Lexer.
+    Should not be called directly, instead
+    use DelegatingLexer for your target language.
+    """
+
+    name = 'ANTLR'
+    aliases = ['antlr']
+    filenames = []
+    url = 'https://www.antlr.org'
+    version_added = '1.1'
+
+    _id = r'[A-Za-z]\w*'
+    _TOKEN_REF = r'[A-Z]\w*'
+    _RULE_REF = r'[a-z]\w*'
+    _STRING_LITERAL = r'\'(?:\\\\|\\\'|[^\']*)\''
+    _INT = r'[0-9]+'
+
+    tokens = {
+        'whitespace': [
+            (r'\s+', Whitespace),
+        ],
+        'comments': [
+            (r'//.*$', Comment),
+            (r'/\*(.|\n)*?\*/', Comment),
+        ],
+        'root': [
+            include('whitespace'),
+            include('comments'),
+
+            (r'(lexer|parser|tree)?(\s*)(grammar\b)(\s*)(' + _id + ')(;)',
+             bygroups(Keyword, Whitespace, Keyword, Whitespace, Name.Class,
+                      Punctuation)),
+            # optionsSpec
+            (r'options\b', Keyword, 'options'),
+            # tokensSpec
+            (r'tokens\b', Keyword, 'tokens'),
+            # attrScope
+            (r'(scope)(\s*)(' + _id + r')(\s*)(\{)',
+             bygroups(Keyword, Whitespace, Name.Variable, Whitespace,
+                      Punctuation), 'action'),
+            # exception
+            (r'(catch|finally)\b', Keyword, 'exception'),
+            # action
+            (r'(@' + _id + r')(\s*)(::)?(\s*)(' + _id + r')(\s*)(\{)',
+             bygroups(Name.Label, Whitespace, Punctuation, Whitespace,
+                      Name.Label, Whitespace, Punctuation), 'action'),
+            # rule
+            (r'((?:protected|private|public|fragment)\b)?(\s*)(' + _id + ')(!)?',
+             bygroups(Keyword, Whitespace, Name.Label, Punctuation),
+             ('rule-alts', 'rule-prelims')),
+        ],
+        'exception': [
+            (r'\n', Whitespace, '#pop'),
+            (r'\s', Whitespace),
+            include('comments'),
+
+            (r'\[', Punctuation, 'nested-arg-action'),
+            (r'\{', Punctuation, 'action'),
+        ],
+        'rule-prelims': [
+            include('whitespace'),
+            include('comments'),
+
+            (r'returns\b', Keyword),
+            (r'\[', Punctuation, 'nested-arg-action'),
+            (r'\{', Punctuation, 'action'),
+            # throwsSpec
+            (r'(throws)(\s+)(' + _id + ')',
+             bygroups(Keyword, Whitespace, Name.Label)),
+            (r'(,)(\s*)(' + _id + ')',
+             bygroups(Punctuation, Whitespace, Name.Label)),  # Additional throws
+            # optionsSpec
+            (r'options\b', Keyword, 'options'),
+            # ruleScopeSpec - scope followed by target language code or name of action
+            # TODO finish implementing other possibilities for scope
+            # L173 ANTLRv3.g from ANTLR book
+            (r'(scope)(\s+)(\{)', bygroups(Keyword, Whitespace, Punctuation),
+             'action'),
+            (r'(scope)(\s+)(' + _id + r')(\s*)(;)',
+             bygroups(Keyword, Whitespace, Name.Label, Whitespace, Punctuation)),
+            # ruleAction
+            (r'(@' + _id + r')(\s*)(\{)',
+             bygroups(Name.Label, Whitespace, Punctuation), 'action'),
+            # finished prelims, go to rule alts!
+            (r':', Punctuation, '#pop')
+        ],
+        'rule-alts': [
+            include('whitespace'),
+            include('comments'),
+
+            # These might need to go in a separate 'block' state triggered by (
+            (r'options\b', Keyword, 'options'),
+            (r':', Punctuation),
+
+            # literals
+            (r'"(\\\\|\\[^\\]|[^"\\])*"', String.Double),
+            (r"'(\\\\|\\[^\\]|[^'\\])*'", String.Single),
+            (r'<<([^>]|>[^>])>>', String),
+            # identifiers
+            # Tokens start with capital letter.
+            (r'\$?[A-Z_]\w*', Name.Constant),
+            # Rules start with small letter.
+            (r'\$?[a-z_]\w*', Name.Variable),
+            # operators
+            (r'(\+|\||->|=>|=|\(|\)|\.\.|\.|\?|\*|\^|!|\#|~)', Operator),
+            (r',', Punctuation),
+            (r'\[', Punctuation, 'nested-arg-action'),
+            (r'\{', Punctuation, 'action'),
+            (r';', Punctuation, '#pop')
+        ],
+        'tokens': [
+            include('whitespace'),
+            include('comments'),
+            (r'\{', Punctuation),
+            (r'(' + _TOKEN_REF + r')(\s*)(=)?(\s*)(' + _STRING_LITERAL
+             + r')?(\s*)(;)',
+             bygroups(Name.Label, Whitespace, Punctuation, Whitespace,
+                      String, Whitespace, Punctuation)),
+            (r'\}', Punctuation, '#pop'),
+        ],
+        'options': [
+            include('whitespace'),
+            include('comments'),
+            (r'\{', Punctuation),
+            (r'(' + _id + r')(\s*)(=)(\s*)(' +
+             '|'.join((_id, _STRING_LITERAL, _INT, r'\*')) + r')(\s*)(;)',
+             bygroups(Name.Variable, Whitespace, Punctuation, Whitespace,
+                      Text, Whitespace, Punctuation)),
+            (r'\}', Punctuation, '#pop'),
+        ],
+        'action': [
+            (r'(' + r'|'.join((    # keep host code in largest possible chunks
+                r'[^${}\'"/\\]+',  # exclude unsafe characters
+
+                # strings and comments may safely contain unsafe characters
+                r'"(\\\\|\\[^\\]|[^"\\])*"',
+                r"'(\\\\|\\[^\\]|[^'\\])*'",
+                r'//.*$\n?',            # single line comment
+                r'/\*(.|\n)*?\*/',      # multi-line javadoc-style comment
+
+                # regular expression: There's no reason for it to start
+                # with a * and this stops confusion with comments.
+                r'/(?!\*)(\\\\|\\[^\\]|[^/\\])*/',
+
+                # backslashes are okay, as long as we are not backslashing a %
+                r'\\(?!%)',
+
+                # Now that we've handled regex and javadoc comments
+                # it's safe to let / through.
+                r'/',
+            )) + r')+', Other),
+            (r'(\\)(%)', bygroups(Punctuation, Other)),
+            (r'(\$[a-zA-Z]+)(\.?)(text|value)?',
+             bygroups(Name.Variable, Punctuation, Name.Property)),
+            (r'\{', Punctuation, '#push'),
+            (r'\}', Punctuation, '#pop'),
+        ],
+        'nested-arg-action': [
+            (r'(' + r'|'.join((    # keep host code in largest possible chunks.
+                r'[^$\[\]\'"/]+',  # exclude unsafe characters
+
+                # strings and comments may safely contain unsafe characters
+                r'"(\\\\|\\[^\\]|[^"\\])*"',
+                r"'(\\\\|\\[^\\]|[^'\\])*'",
+                r'//.*$\n?',            # single line comment
+                r'/\*(.|\n)*?\*/',      # multi-line javadoc-style comment
+
+                # regular expression: There's no reason for it to start
+                # with a * and this stops confusion with comments.
+                r'/(?!\*)(\\\\|\\[^\\]|[^/\\])*/',
+
+                # Now that we've handled regex and javadoc comments
+                # it's safe to let / through.
+                r'/',
+            )) + r')+', Other),
+
+
+            (r'\[', Punctuation, '#push'),
+            (r'\]', Punctuation, '#pop'),
+            (r'(\$[a-zA-Z]+)(\.?)(text|value)?',
+             bygroups(Name.Variable, Punctuation, Name.Property)),
+            (r'(\\\\|\\\]|\\\[|[^\[\]])+', Other),
+        ]
+    }
+
+    def analyse_text(text):
+        return re.search(r'^\s*grammar\s+[a-zA-Z0-9]+\s*;', text, re.M)
+
+
+# http://www.antlr.org/wiki/display/ANTLR3/Code+Generation+Targets
+
+class AntlrCppLexer(DelegatingLexer):
+    """
+    ANTLR with C++ Target
+    """
+
+    name = 'ANTLR With CPP Target'
+    aliases = ['antlr-cpp']
+    filenames = ['*.G', '*.g']
+    url = 'https://www.antlr.org'
+    version_added = '1.1'
+
+    def __init__(self, **options):
+        super().__init__(CppLexer, AntlrLexer, **options)
+
+    def analyse_text(text):
+        return AntlrLexer.analyse_text(text) and \
+            re.search(r'^\s*language\s*=\s*C\s*;', text, re.M)
+
+
+class AntlrObjectiveCLexer(DelegatingLexer):
+    """
+    ANTLR with Objective-C Target
+    """
+
+    name = 'ANTLR With ObjectiveC Target'
+    aliases = ['antlr-objc']
+    filenames = ['*.G', '*.g']
+    url = 'https://www.antlr.org'
+    version_added = '1.1'
+
+    def __init__(self, **options):
+        super().__init__(ObjectiveCLexer, AntlrLexer, **options)
+
+    def analyse_text(text):
+        return AntlrLexer.analyse_text(text) and \
+            re.search(r'^\s*language\s*=\s*ObjC\s*;', text)
+
+
+class AntlrCSharpLexer(DelegatingLexer):
+    """
+    ANTLR with C# Target
+    """
+
+    name = 'ANTLR With C# Target'
+    aliases = ['antlr-csharp', 'antlr-c#']
+    filenames = ['*.G', '*.g']
+    url = 'https://www.antlr.org'
+    version_added = '1.1'
+
+    def __init__(self, **options):
+        super().__init__(CSharpLexer, AntlrLexer, **options)
+
+    def analyse_text(text):
+        return AntlrLexer.analyse_text(text) and \
+            re.search(r'^\s*language\s*=\s*CSharp2\s*;', text, re.M)
+
+
+class AntlrPythonLexer(DelegatingLexer):
+    """
+    ANTLR with Python Target
+    """
+
+    name = 'ANTLR With Python Target'
+    aliases = ['antlr-python']
+    filenames = ['*.G', '*.g']
+    url = 'https://www.antlr.org'
+    version_added = '1.1'
+
+    def __init__(self, **options):
+        super().__init__(PythonLexer, AntlrLexer, **options)
+
+    def analyse_text(text):
+        return AntlrLexer.analyse_text(text) and \
+            re.search(r'^\s*language\s*=\s*Python\s*;', text, re.M)
+
+
+class AntlrJavaLexer(DelegatingLexer):
+    """
+    ANTLR with Java Target
+    """
+
+    name = 'ANTLR With Java Target'
+    aliases = ['antlr-java']
+    filenames = ['*.G', '*.g']
+    url = 'https://www.antlr.org'
+    version_added = '1.1'
+
+    def __init__(self, **options):
+        super().__init__(JavaLexer, AntlrLexer, **options)
+
+    def analyse_text(text):
+        # Antlr language is Java by default
+        return AntlrLexer.analyse_text(text) and 0.9
+
+
+class AntlrRubyLexer(DelegatingLexer):
+    """
+    ANTLR with Ruby Target
+    """
+
+    name = 'ANTLR With Ruby Target'
+    aliases = ['antlr-ruby', 'antlr-rb']
+    filenames = ['*.G', '*.g']
+    url = 'https://www.antlr.org'
+    version_added = '1.1'
+
+    def __init__(self, **options):
+        super().__init__(RubyLexer, AntlrLexer, **options)
+
+    def analyse_text(text):
+        return AntlrLexer.analyse_text(text) and \
+            re.search(r'^\s*language\s*=\s*Ruby\s*;', text, re.M)
+
+
+class AntlrPerlLexer(DelegatingLexer):
+    """
+    ANTLR with Perl Target
+    """
+
+    name = 'ANTLR With Perl Target'
+    aliases = ['antlr-perl']
+    filenames = ['*.G', '*.g']
+    url = 'https://www.antlr.org'
+    version_added = '1.1'
+
+    def __init__(self, **options):
+        super().__init__(PerlLexer, AntlrLexer, **options)
+
+    def analyse_text(text):
+        return AntlrLexer.analyse_text(text) and \
+            re.search(r'^\s*language\s*=\s*Perl5\s*;', text, re.M)
+
+
+class AntlrActionScriptLexer(DelegatingLexer):
+    """
+    ANTLR with ActionScript Target
+    """
+
+    name = 'ANTLR With ActionScript Target'
+    aliases = ['antlr-actionscript', 'antlr-as']
+    filenames = ['*.G', '*.g']
+    url = 'https://www.antlr.org'
+    version_added = '1.1'
+
+    def __init__(self, **options):
+        from pygments.lexers.actionscript import ActionScriptLexer
+        super().__init__(ActionScriptLexer, AntlrLexer, **options)
+
+    def analyse_text(text):
+        return AntlrLexer.analyse_text(text) and \
+            re.search(r'^\s*language\s*=\s*ActionScript\s*;', text, re.M)
+
+
+class TreetopBaseLexer(RegexLexer):
+    """
+    A base lexer for `Treetop `_ grammars.
+    Not for direct use; use :class:`TreetopLexer` instead.
+
+    .. versionadded:: 1.6
+    """
+
+    tokens = {
+        'root': [
+            include('space'),
+            (r'require[ \t]+[^\n\r]+[\n\r]', Other),
+            (r'module\b', Keyword.Namespace, 'module'),
+            (r'grammar\b', Keyword, 'grammar'),
+        ],
+        'module': [
+            include('space'),
+            include('end'),
+            (r'module\b', Keyword, '#push'),
+            (r'grammar\b', Keyword, 'grammar'),
+            (r'[A-Z]\w*(?:::[A-Z]\w*)*', Name.Namespace),
+        ],
+        'grammar': [
+            include('space'),
+            include('end'),
+            (r'rule\b', Keyword, 'rule'),
+            (r'include\b', Keyword, 'include'),
+            (r'[A-Z]\w*', Name),
+        ],
+        'include': [
+            include('space'),
+            (r'[A-Z]\w*(?:::[A-Z]\w*)*', Name.Class, '#pop'),
+        ],
+        'rule': [
+            include('space'),
+            include('end'),
+            (r'"(\\\\|\\[^\\]|[^"\\])*"', String.Double),
+            (r"'(\\\\|\\[^\\]|[^'\\])*'", String.Single),
+            (r'([A-Za-z_]\w*)(:)', bygroups(Name.Label, Punctuation)),
+            (r'[A-Za-z_]\w*', Name),
+            (r'[()]', Punctuation),
+            (r'[?+*/&!~]', Operator),
+            (r'\[(?:\\.|\[:\^?[a-z]+:\]|[^\\\]])+\]', String.Regex),
+            (r'([0-9]*)(\.\.)([0-9]*)',
+             bygroups(Number.Integer, Operator, Number.Integer)),
+            (r'(<)([^>]+)(>)', bygroups(Punctuation, Name.Class, Punctuation)),
+            (r'\{', Punctuation, 'inline_module'),
+            (r'\.', String.Regex),
+        ],
+        'inline_module': [
+            (r'\{', Other, 'ruby'),
+            (r'\}', Punctuation, '#pop'),
+            (r'[^{}]+', Other),
+        ],
+        'ruby': [
+            (r'\{', Other, '#push'),
+            (r'\}', Other, '#pop'),
+            (r'[^{}]+', Other),
+        ],
+        'space': [
+            (r'[ \t\n\r]+', Whitespace),
+            (r'#[^\n]*', Comment.Single),
+        ],
+        'end': [
+            (r'end\b', Keyword, '#pop'),
+        ],
+    }
+
+
+class TreetopLexer(DelegatingLexer):
+    """
+    A lexer for Treetop grammars.
+    """
+
+    name = 'Treetop'
+    aliases = ['treetop']
+    filenames = ['*.treetop', '*.tt']
+    url = 'https://cjheath.github.io/treetop'
+    version_added = '1.6'
+
+    def __init__(self, **options):
+        super().__init__(RubyLexer, TreetopBaseLexer, **options)
+
+
+class EbnfLexer(RegexLexer):
+    """
+    Lexer for `ISO/IEC 14977 EBNF
+    `_
+    grammars.
+    """
+
+    name = 'EBNF'
+    aliases = ['ebnf']
+    filenames = ['*.ebnf']
+    mimetypes = ['text/x-ebnf']
+    url = 'https://en.wikipedia.org/wiki/Extended_Backus%E2%80%93Naur_Form'
+    version_added = '2.0'
+
+    tokens = {
+        'root': [
+            include('whitespace'),
+            include('comment_start'),
+            include('identifier'),
+            (r'=', Operator, 'production'),
+        ],
+        'production': [
+            include('whitespace'),
+            include('comment_start'),
+            include('identifier'),
+            (r'"[^"]*"', String.Double),
+            (r"'[^']*'", String.Single),
+            (r'(\?[^?]*\?)', Name.Entity),
+            (r'[\[\]{}(),|]', Punctuation),
+            (r'-', Operator),
+            (r';', Punctuation, '#pop'),
+            (r'\.', Punctuation, '#pop'),
+        ],
+        'whitespace': [
+            (r'\s+', Text),
+        ],
+        'comment_start': [
+            (r'\(\*', Comment.Multiline, 'comment'),
+        ],
+        'comment': [
+            (r'[^*)]', Comment.Multiline),
+            include('comment_start'),
+            (r'\*\)', Comment.Multiline, '#pop'),
+            (r'[*)]', Comment.Multiline),
+        ],
+        'identifier': [
+            (r'([a-zA-Z][\w \-]*)', Keyword),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/pascal.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/pascal.py
new file mode 100644
index 0000000000000000000000000000000000000000..ad8a0aec62a515a601b0b866ae4d64cf62c28afb
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/pascal.py
@@ -0,0 +1,644 @@
+"""
+    pygments.lexers.pascal
+    ~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for Pascal family languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import Lexer
+from pygments.util import get_bool_opt, get_list_opt
+from pygments.token import Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation, Error, Whitespace
+from pygments.scanner import Scanner
+
+# compatibility import
+from pygments.lexers.modula2 import Modula2Lexer # noqa: F401
+
+__all__ = ['DelphiLexer', 'PortugolLexer']
+
+
+class PortugolLexer(Lexer):
+    """For Portugol, a Pascal dialect with keywords in Portuguese."""
+    name = 'Portugol'
+    aliases = ['portugol']
+    filenames = ['*.alg', '*.portugol']
+    mimetypes = []
+    url = "https://www.apoioinformatica.inf.br/produtos/visualg/linguagem"
+    version_added = ''
+
+    def __init__(self, **options):
+        Lexer.__init__(self, **options)
+        self.lexer = DelphiLexer(**options, portugol=True)
+
+    def get_tokens_unprocessed(self, text):
+        return self.lexer.get_tokens_unprocessed(text)
+
+
+class DelphiLexer(Lexer):
+    """
+    For Delphi (Borland Object Pascal),
+    Turbo Pascal and Free Pascal source code.
+
+    Additional options accepted:
+
+    `turbopascal`
+        Highlight Turbo Pascal specific keywords (default: ``True``).
+    `delphi`
+        Highlight Borland Delphi specific keywords (default: ``True``).
+    `freepascal`
+        Highlight Free Pascal specific keywords (default: ``True``).
+    `units`
+        A list of units that should be considered builtin, supported are
+        ``System``, ``SysUtils``, ``Classes`` and ``Math``.
+        Default is to consider all of them builtin.
+    """
+    name = 'Delphi'
+    aliases = ['delphi', 'pas', 'pascal', 'objectpascal']
+    filenames = ['*.pas', '*.dpr']
+    mimetypes = ['text/x-pascal']
+    url = 'https://www.embarcadero.com/products/delphi'
+    version_added = ''
+
+    TURBO_PASCAL_KEYWORDS = (
+        'absolute', 'and', 'array', 'asm', 'begin', 'break', 'case',
+        'const', 'constructor', 'continue', 'destructor', 'div', 'do',
+        'downto', 'else', 'end', 'file', 'for', 'function', 'goto',
+        'if', 'implementation', 'in', 'inherited', 'inline', 'interface',
+        'label', 'mod', 'nil', 'not', 'object', 'of', 'on', 'operator',
+        'or', 'packed', 'procedure', 'program', 'record', 'reintroduce',
+        'repeat', 'self', 'set', 'shl', 'shr', 'string', 'then', 'to',
+        'type', 'unit', 'until', 'uses', 'var', 'while', 'with', 'xor'
+    )
+
+    DELPHI_KEYWORDS = (
+        'as', 'class', 'except', 'exports', 'finalization', 'finally',
+        'initialization', 'is', 'library', 'on', 'property', 'raise',
+        'threadvar', 'try'
+    )
+
+    FREE_PASCAL_KEYWORDS = (
+        'dispose', 'exit', 'false', 'new', 'true'
+    )
+
+    BLOCK_KEYWORDS = {
+        'begin', 'class', 'const', 'constructor', 'destructor', 'end',
+        'finalization', 'function', 'implementation', 'initialization',
+        'label', 'library', 'operator', 'procedure', 'program', 'property',
+        'record', 'threadvar', 'type', 'unit', 'uses', 'var'
+    }
+
+    FUNCTION_MODIFIERS = {
+        'alias', 'cdecl', 'export', 'inline', 'interrupt', 'nostackframe',
+        'pascal', 'register', 'safecall', 'softfloat', 'stdcall',
+        'varargs', 'name', 'dynamic', 'near', 'virtual', 'external',
+        'override', 'assembler'
+    }
+
+    # XXX: those aren't global. but currently we know no way for defining
+    #      them just for the type context.
+    DIRECTIVES = {
+        'absolute', 'abstract', 'assembler', 'cppdecl', 'default', 'far',
+        'far16', 'forward', 'index', 'oldfpccall', 'private', 'protected',
+        'published', 'public'
+    }
+
+    BUILTIN_TYPES = {
+        'ansichar', 'ansistring', 'bool', 'boolean', 'byte', 'bytebool',
+        'cardinal', 'char', 'comp', 'currency', 'double', 'dword',
+        'extended', 'int64', 'integer', 'iunknown', 'longbool', 'longint',
+        'longword', 'pansichar', 'pansistring', 'pbool', 'pboolean',
+        'pbyte', 'pbytearray', 'pcardinal', 'pchar', 'pcomp', 'pcurrency',
+        'pdate', 'pdatetime', 'pdouble', 'pdword', 'pextended', 'phandle',
+        'pint64', 'pinteger', 'plongint', 'plongword', 'pointer',
+        'ppointer', 'pshortint', 'pshortstring', 'psingle', 'psmallint',
+        'pstring', 'pvariant', 'pwidechar', 'pwidestring', 'pword',
+        'pwordarray', 'pwordbool', 'real', 'real48', 'shortint',
+        'shortstring', 'single', 'smallint', 'string', 'tclass', 'tdate',
+        'tdatetime', 'textfile', 'thandle', 'tobject', 'ttime', 'variant',
+        'widechar', 'widestring', 'word', 'wordbool'
+    }
+
+    BUILTIN_UNITS = {
+        'System': (
+            'abs', 'acquireexceptionobject', 'addr', 'ansitoutf8',
+            'append', 'arctan', 'assert', 'assigned', 'assignfile',
+            'beginthread', 'blockread', 'blockwrite', 'break', 'chdir',
+            'chr', 'close', 'closefile', 'comptocurrency', 'comptodouble',
+            'concat', 'continue', 'copy', 'cos', 'dec', 'delete',
+            'dispose', 'doubletocomp', 'endthread', 'enummodules',
+            'enumresourcemodules', 'eof', 'eoln', 'erase', 'exceptaddr',
+            'exceptobject', 'exclude', 'exit', 'exp', 'filepos', 'filesize',
+            'fillchar', 'finalize', 'findclasshinstance', 'findhinstance',
+            'findresourcehinstance', 'flush', 'frac', 'freemem',
+            'get8087cw', 'getdir', 'getlasterror', 'getmem',
+            'getmemorymanager', 'getmodulefilename', 'getvariantmanager',
+            'halt', 'hi', 'high', 'inc', 'include', 'initialize', 'insert',
+            'int', 'ioresult', 'ismemorymanagerset', 'isvariantmanagerset',
+            'length', 'ln', 'lo', 'low', 'mkdir', 'move', 'new', 'odd',
+            'olestrtostring', 'olestrtostrvar', 'ord', 'paramcount',
+            'paramstr', 'pi', 'pos', 'pred', 'ptr', 'pucs4chars', 'random',
+            'randomize', 'read', 'readln', 'reallocmem',
+            'releaseexceptionobject', 'rename', 'reset', 'rewrite', 'rmdir',
+            'round', 'runerror', 'seek', 'seekeof', 'seekeoln',
+            'set8087cw', 'setlength', 'setlinebreakstyle',
+            'setmemorymanager', 'setstring', 'settextbuf',
+            'setvariantmanager', 'sin', 'sizeof', 'slice', 'sqr', 'sqrt',
+            'str', 'stringofchar', 'stringtoolestr', 'stringtowidechar',
+            'succ', 'swap', 'trunc', 'truncate', 'typeinfo',
+            'ucs4stringtowidestring', 'unicodetoutf8', 'uniquestring',
+            'upcase', 'utf8decode', 'utf8encode', 'utf8toansi',
+            'utf8tounicode', 'val', 'vararrayredim', 'varclear',
+            'widecharlentostring', 'widecharlentostrvar',
+            'widechartostring', 'widechartostrvar',
+            'widestringtoucs4string', 'write', 'writeln'
+        ),
+        'SysUtils': (
+            'abort', 'addexitproc', 'addterminateproc', 'adjustlinebreaks',
+            'allocmem', 'ansicomparefilename', 'ansicomparestr',
+            'ansicomparetext', 'ansidequotedstr', 'ansiextractquotedstr',
+            'ansilastchar', 'ansilowercase', 'ansilowercasefilename',
+            'ansipos', 'ansiquotedstr', 'ansisamestr', 'ansisametext',
+            'ansistrcomp', 'ansistricomp', 'ansistrlastchar', 'ansistrlcomp',
+            'ansistrlicomp', 'ansistrlower', 'ansistrpos', 'ansistrrscan',
+            'ansistrscan', 'ansistrupper', 'ansiuppercase',
+            'ansiuppercasefilename', 'appendstr', 'assignstr', 'beep',
+            'booltostr', 'bytetocharindex', 'bytetocharlen', 'bytetype',
+            'callterminateprocs', 'changefileext', 'charlength',
+            'chartobyteindex', 'chartobytelen', 'comparemem', 'comparestr',
+            'comparetext', 'createdir', 'createguid', 'currentyear',
+            'currtostr', 'currtostrf', 'date', 'datetimetofiledate',
+            'datetimetostr', 'datetimetostring', 'datetimetosystemtime',
+            'datetimetotimestamp', 'datetostr', 'dayofweek', 'decodedate',
+            'decodedatefully', 'decodetime', 'deletefile', 'directoryexists',
+            'diskfree', 'disksize', 'disposestr', 'encodedate', 'encodetime',
+            'exceptionerrormessage', 'excludetrailingbackslash',
+            'excludetrailingpathdelimiter', 'expandfilename',
+            'expandfilenamecase', 'expanduncfilename', 'extractfiledir',
+            'extractfiledrive', 'extractfileext', 'extractfilename',
+            'extractfilepath', 'extractrelativepath', 'extractshortpathname',
+            'fileage', 'fileclose', 'filecreate', 'filedatetodatetime',
+            'fileexists', 'filegetattr', 'filegetdate', 'fileisreadonly',
+            'fileopen', 'fileread', 'filesearch', 'fileseek', 'filesetattr',
+            'filesetdate', 'filesetreadonly', 'filewrite', 'finalizepackage',
+            'findclose', 'findcmdlineswitch', 'findfirst', 'findnext',
+            'floattocurr', 'floattodatetime', 'floattodecimal', 'floattostr',
+            'floattostrf', 'floattotext', 'floattotextfmt', 'fmtloadstr',
+            'fmtstr', 'forcedirectories', 'format', 'formatbuf', 'formatcurr',
+            'formatdatetime', 'formatfloat', 'freeandnil', 'getcurrentdir',
+            'getenvironmentvariable', 'getfileversion', 'getformatsettings',
+            'getlocaleformatsettings', 'getmodulename', 'getpackagedescription',
+            'getpackageinfo', 'gettime', 'guidtostring', 'incamonth',
+            'includetrailingbackslash', 'includetrailingpathdelimiter',
+            'incmonth', 'initializepackage', 'interlockeddecrement',
+            'interlockedexchange', 'interlockedexchangeadd',
+            'interlockedincrement', 'inttohex', 'inttostr', 'isdelimiter',
+            'isequalguid', 'isleapyear', 'ispathdelimiter', 'isvalidident',
+            'languages', 'lastdelimiter', 'loadpackage', 'loadstr',
+            'lowercase', 'msecstotimestamp', 'newstr', 'nextcharindex', 'now',
+            'outofmemoryerror', 'quotedstr', 'raiselastoserror',
+            'raiselastwin32error', 'removedir', 'renamefile', 'replacedate',
+            'replacetime', 'safeloadlibrary', 'samefilename', 'sametext',
+            'setcurrentdir', 'showexception', 'sleep', 'stralloc', 'strbufsize',
+            'strbytetype', 'strcat', 'strcharlength', 'strcomp', 'strcopy',
+            'strdispose', 'strecopy', 'strend', 'strfmt', 'stricomp',
+            'stringreplace', 'stringtoguid', 'strlcat', 'strlcomp', 'strlcopy',
+            'strlen', 'strlfmt', 'strlicomp', 'strlower', 'strmove', 'strnew',
+            'strnextchar', 'strpas', 'strpcopy', 'strplcopy', 'strpos',
+            'strrscan', 'strscan', 'strtobool', 'strtobooldef', 'strtocurr',
+            'strtocurrdef', 'strtodate', 'strtodatedef', 'strtodatetime',
+            'strtodatetimedef', 'strtofloat', 'strtofloatdef', 'strtoint',
+            'strtoint64', 'strtoint64def', 'strtointdef', 'strtotime',
+            'strtotimedef', 'strupper', 'supports', 'syserrormessage',
+            'systemtimetodatetime', 'texttofloat', 'time', 'timestamptodatetime',
+            'timestamptomsecs', 'timetostr', 'trim', 'trimleft', 'trimright',
+            'tryencodedate', 'tryencodetime', 'tryfloattocurr', 'tryfloattodatetime',
+            'trystrtobool', 'trystrtocurr', 'trystrtodate', 'trystrtodatetime',
+            'trystrtofloat', 'trystrtoint', 'trystrtoint64', 'trystrtotime',
+            'unloadpackage', 'uppercase', 'widecomparestr', 'widecomparetext',
+            'widefmtstr', 'wideformat', 'wideformatbuf', 'widelowercase',
+            'widesamestr', 'widesametext', 'wideuppercase', 'win32check',
+            'wraptext'
+        ),
+        'Classes': (
+            'activateclassgroup', 'allocatehwnd', 'bintohex', 'checksynchronize',
+            'collectionsequal', 'countgenerations', 'deallocatehwnd', 'equalrect',
+            'extractstrings', 'findclass', 'findglobalcomponent', 'getclass',
+            'groupdescendantswith', 'hextobin', 'identtoint',
+            'initinheritedcomponent', 'inttoident', 'invalidpoint',
+            'isuniqueglobalcomponentname', 'linestart', 'objectbinarytotext',
+            'objectresourcetotext', 'objecttexttobinary', 'objecttexttoresource',
+            'pointsequal', 'readcomponentres', 'readcomponentresex',
+            'readcomponentresfile', 'rect', 'registerclass', 'registerclassalias',
+            'registerclasses', 'registercomponents', 'registerintegerconsts',
+            'registernoicon', 'registernonactivex', 'smallpoint', 'startclassgroup',
+            'teststreamformat', 'unregisterclass', 'unregisterclasses',
+            'unregisterintegerconsts', 'unregistermoduleclasses',
+            'writecomponentresfile'
+        ),
+        'Math': (
+            'arccos', 'arccosh', 'arccot', 'arccoth', 'arccsc', 'arccsch', 'arcsec',
+            'arcsech', 'arcsin', 'arcsinh', 'arctan2', 'arctanh', 'ceil',
+            'comparevalue', 'cosecant', 'cosh', 'cot', 'cotan', 'coth', 'csc',
+            'csch', 'cycletodeg', 'cycletograd', 'cycletorad', 'degtocycle',
+            'degtograd', 'degtorad', 'divmod', 'doubledecliningbalance',
+            'ensurerange', 'floor', 'frexp', 'futurevalue', 'getexceptionmask',
+            'getprecisionmode', 'getroundmode', 'gradtocycle', 'gradtodeg',
+            'gradtorad', 'hypot', 'inrange', 'interestpayment', 'interestrate',
+            'internalrateofreturn', 'intpower', 'isinfinite', 'isnan', 'iszero',
+            'ldexp', 'lnxp1', 'log10', 'log2', 'logn', 'max', 'maxintvalue',
+            'maxvalue', 'mean', 'meanandstddev', 'min', 'minintvalue', 'minvalue',
+            'momentskewkurtosis', 'netpresentvalue', 'norm', 'numberofperiods',
+            'payment', 'periodpayment', 'poly', 'popnstddev', 'popnvariance',
+            'power', 'presentvalue', 'radtocycle', 'radtodeg', 'radtograd',
+            'randg', 'randomrange', 'roundto', 'samevalue', 'sec', 'secant',
+            'sech', 'setexceptionmask', 'setprecisionmode', 'setroundmode',
+            'sign', 'simpleroundto', 'sincos', 'sinh', 'slndepreciation', 'stddev',
+            'sum', 'sumint', 'sumofsquares', 'sumsandsquares', 'syddepreciation',
+            'tan', 'tanh', 'totalvariance', 'variance'
+        )
+    }
+
+    ASM_REGISTERS = {
+        'ah', 'al', 'ax', 'bh', 'bl', 'bp', 'bx', 'ch', 'cl', 'cr0',
+        'cr1', 'cr2', 'cr3', 'cr4', 'cs', 'cx', 'dh', 'di', 'dl', 'dr0',
+        'dr1', 'dr2', 'dr3', 'dr4', 'dr5', 'dr6', 'dr7', 'ds', 'dx',
+        'eax', 'ebp', 'ebx', 'ecx', 'edi', 'edx', 'es', 'esi', 'esp',
+        'fs', 'gs', 'mm0', 'mm1', 'mm2', 'mm3', 'mm4', 'mm5', 'mm6',
+        'mm7', 'si', 'sp', 'ss', 'st0', 'st1', 'st2', 'st3', 'st4', 'st5',
+        'st6', 'st7', 'xmm0', 'xmm1', 'xmm2', 'xmm3', 'xmm4', 'xmm5',
+        'xmm6', 'xmm7'
+    }
+
+    ASM_INSTRUCTIONS = {
+        'aaa', 'aad', 'aam', 'aas', 'adc', 'add', 'and', 'arpl', 'bound',
+        'bsf', 'bsr', 'bswap', 'bt', 'btc', 'btr', 'bts', 'call', 'cbw',
+        'cdq', 'clc', 'cld', 'cli', 'clts', 'cmc', 'cmova', 'cmovae',
+        'cmovb', 'cmovbe', 'cmovc', 'cmovcxz', 'cmove', 'cmovg',
+        'cmovge', 'cmovl', 'cmovle', 'cmovna', 'cmovnae', 'cmovnb',
+        'cmovnbe', 'cmovnc', 'cmovne', 'cmovng', 'cmovnge', 'cmovnl',
+        'cmovnle', 'cmovno', 'cmovnp', 'cmovns', 'cmovnz', 'cmovo',
+        'cmovp', 'cmovpe', 'cmovpo', 'cmovs', 'cmovz', 'cmp', 'cmpsb',
+        'cmpsd', 'cmpsw', 'cmpxchg', 'cmpxchg486', 'cmpxchg8b', 'cpuid',
+        'cwd', 'cwde', 'daa', 'das', 'dec', 'div', 'emms', 'enter', 'hlt',
+        'ibts', 'icebp', 'idiv', 'imul', 'in', 'inc', 'insb', 'insd',
+        'insw', 'int', 'int01', 'int03', 'int1', 'int3', 'into', 'invd',
+        'invlpg', 'iret', 'iretd', 'iretw', 'ja', 'jae', 'jb', 'jbe',
+        'jc', 'jcxz', 'jcxz', 'je', 'jecxz', 'jg', 'jge', 'jl', 'jle',
+        'jmp', 'jna', 'jnae', 'jnb', 'jnbe', 'jnc', 'jne', 'jng', 'jnge',
+        'jnl', 'jnle', 'jno', 'jnp', 'jns', 'jnz', 'jo', 'jp', 'jpe',
+        'jpo', 'js', 'jz', 'lahf', 'lar', 'lcall', 'lds', 'lea', 'leave',
+        'les', 'lfs', 'lgdt', 'lgs', 'lidt', 'ljmp', 'lldt', 'lmsw',
+        'loadall', 'loadall286', 'lock', 'lodsb', 'lodsd', 'lodsw',
+        'loop', 'loope', 'loopne', 'loopnz', 'loopz', 'lsl', 'lss', 'ltr',
+        'mov', 'movd', 'movq', 'movsb', 'movsd', 'movsw', 'movsx',
+        'movzx', 'mul', 'neg', 'nop', 'not', 'or', 'out', 'outsb', 'outsd',
+        'outsw', 'pop', 'popa', 'popad', 'popaw', 'popf', 'popfd', 'popfw',
+        'push', 'pusha', 'pushad', 'pushaw', 'pushf', 'pushfd', 'pushfw',
+        'rcl', 'rcr', 'rdmsr', 'rdpmc', 'rdshr', 'rdtsc', 'rep', 'repe',
+        'repne', 'repnz', 'repz', 'ret', 'retf', 'retn', 'rol', 'ror',
+        'rsdc', 'rsldt', 'rsm', 'sahf', 'sal', 'salc', 'sar', 'sbb',
+        'scasb', 'scasd', 'scasw', 'seta', 'setae', 'setb', 'setbe',
+        'setc', 'setcxz', 'sete', 'setg', 'setge', 'setl', 'setle',
+        'setna', 'setnae', 'setnb', 'setnbe', 'setnc', 'setne', 'setng',
+        'setnge', 'setnl', 'setnle', 'setno', 'setnp', 'setns', 'setnz',
+        'seto', 'setp', 'setpe', 'setpo', 'sets', 'setz', 'sgdt', 'shl',
+        'shld', 'shr', 'shrd', 'sidt', 'sldt', 'smi', 'smint', 'smintold',
+        'smsw', 'stc', 'std', 'sti', 'stosb', 'stosd', 'stosw', 'str',
+        'sub', 'svdc', 'svldt', 'svts', 'syscall', 'sysenter', 'sysexit',
+        'sysret', 'test', 'ud1', 'ud2', 'umov', 'verr', 'verw', 'wait',
+        'wbinvd', 'wrmsr', 'wrshr', 'xadd', 'xbts', 'xchg', 'xlat',
+        'xlatb', 'xor'
+    }
+
+    PORTUGOL_KEYWORDS = (
+        'aleatorio',
+        'algoritmo',
+        'arquivo',
+        'ate',
+        'caso',
+        'cronometro',
+        'debug',
+        'e',
+        'eco',
+        'enquanto',
+        'entao',
+        'escolha',
+        'escreva',
+        'escreval',
+        'faca',
+        'falso',
+        'fimalgoritmo',
+        'fimenquanto',
+        'fimescolha',
+        'fimfuncao',
+        'fimpara',
+        'fimprocedimento',
+        'fimrepita',
+        'fimse',
+        'funcao',
+        'inicio',
+        'int',
+        'interrompa',
+        'leia',
+        'limpatela',
+        'mod',
+        'nao',
+        'ou',
+        'outrocaso',
+        'para',
+        'passo',
+        'pausa',
+        'procedimento',
+        'repita',
+        'retorne',
+        'se',
+        'senao',
+        'timer',
+        'var',
+        'vetor',
+        'verdadeiro',
+        'xou',
+        'div',
+        'mod',
+        'abs',
+        'arccos',
+        'arcsen',
+        'arctan',
+        'cos',
+        'cotan',
+        'Exp',
+        'grauprad',
+        'int',
+        'log',
+        'logn',
+        'pi',
+        'quad',
+        'radpgrau',
+        'raizq',
+        'rand',
+        'randi',
+        'sen',
+        'Tan',
+        'asc',
+        'carac',
+        'caracpnum',
+        'compr',
+        'copia',
+        'maiusc',
+        'minusc',
+        'numpcarac',
+        'pos',
+    )
+
+    PORTUGOL_BUILTIN_TYPES = {
+        'inteiro', 'real', 'caractere', 'logico'
+    }
+
+    def __init__(self, **options):
+        Lexer.__init__(self, **options)
+        self.keywords = set()
+        self.builtins = set()
+        if get_bool_opt(options, 'portugol', False):
+            self.keywords.update(self.PORTUGOL_KEYWORDS)
+            self.builtins.update(self.PORTUGOL_BUILTIN_TYPES)
+            self.is_portugol = True
+        else:
+            self.is_portugol = False
+
+            if get_bool_opt(options, 'turbopascal', True):
+                self.keywords.update(self.TURBO_PASCAL_KEYWORDS)
+            if get_bool_opt(options, 'delphi', True):
+                self.keywords.update(self.DELPHI_KEYWORDS)
+            if get_bool_opt(options, 'freepascal', True):
+                self.keywords.update(self.FREE_PASCAL_KEYWORDS)
+            for unit in get_list_opt(options, 'units', list(self.BUILTIN_UNITS)):
+                self.builtins.update(self.BUILTIN_UNITS[unit])
+
+    def get_tokens_unprocessed(self, text):
+        scanner = Scanner(text, re.DOTALL | re.MULTILINE | re.IGNORECASE)
+        stack = ['initial']
+        in_function_block = False
+        in_property_block = False
+        was_dot = False
+        next_token_is_function = False
+        next_token_is_property = False
+        collect_labels = False
+        block_labels = set()
+        brace_balance = [0, 0]
+
+        while not scanner.eos:
+            token = Error
+
+            if stack[-1] == 'initial':
+                if scanner.scan(r'\s+'):
+                    token = Whitespace
+                elif not self.is_portugol and scanner.scan(r'\{.*?\}|\(\*.*?\*\)'):
+                    if scanner.match.startswith('$'):
+                        token = Comment.Preproc
+                    else:
+                        token = Comment.Multiline
+                elif scanner.scan(r'//.*?$'):
+                    token = Comment.Single
+                elif self.is_portugol and scanner.scan(r'(<\-)|(>=)|(<=)|%|<|>|-|\+|\*|\=|(<>)|\/|\.|:|,'):
+                    token = Operator
+                elif not self.is_portugol and scanner.scan(r'[-+*\/=<>:;,.@\^]'):
+                    token = Operator
+                    # stop label highlighting on next ";"
+                    if collect_labels and scanner.match == ';':
+                        collect_labels = False
+                elif scanner.scan(r'[\(\)\[\]]+'):
+                    token = Punctuation
+                    # abort function naming ``foo = Function(...)``
+                    next_token_is_function = False
+                    # if we are in a function block we count the open
+                    # braces because ootherwise it's impossible to
+                    # determine the end of the modifier context
+                    if in_function_block or in_property_block:
+                        if scanner.match == '(':
+                            brace_balance[0] += 1
+                        elif scanner.match == ')':
+                            brace_balance[0] -= 1
+                        elif scanner.match == '[':
+                            brace_balance[1] += 1
+                        elif scanner.match == ']':
+                            brace_balance[1] -= 1
+                elif scanner.scan(r'[A-Za-z_][A-Za-z_0-9]*'):
+                    lowercase_name = scanner.match.lower()
+                    if lowercase_name == 'result':
+                        token = Name.Builtin.Pseudo
+                    elif lowercase_name in self.keywords:
+                        token = Keyword
+                        # if we are in a special block and a
+                        # block ending keyword occurs (and the parenthesis
+                        # is balanced) we end the current block context
+                        if self.is_portugol:
+                            if lowercase_name in ('funcao', 'procedimento'):
+                                in_function_block = True
+                                next_token_is_function = True
+                        else:
+                            if (in_function_block or in_property_block) and \
+                                    lowercase_name in self.BLOCK_KEYWORDS and \
+                                    brace_balance[0] <= 0 and \
+                                    brace_balance[1] <= 0:
+                                in_function_block = False
+                                in_property_block = False
+                                brace_balance = [0, 0]
+                                block_labels = set()
+                            if lowercase_name in ('label', 'goto'):
+                                collect_labels = True
+                            elif lowercase_name == 'asm':
+                                stack.append('asm')
+                            elif lowercase_name == 'property':
+                                in_property_block = True
+                                next_token_is_property = True
+                            elif lowercase_name in ('procedure', 'operator',
+                                                    'function', 'constructor',
+                                                    'destructor'):
+                                in_function_block = True
+                                next_token_is_function = True
+                    # we are in a function block and the current name
+                    # is in the set of registered modifiers. highlight
+                    # it as pseudo keyword
+                    elif not self.is_portugol and in_function_block and \
+                            lowercase_name in self.FUNCTION_MODIFIERS:
+                        token = Keyword.Pseudo
+                    # if we are in a property highlight some more
+                    # modifiers
+                    elif not self.is_portugol and in_property_block and \
+                            lowercase_name in ('read', 'write'):
+                        token = Keyword.Pseudo
+                        next_token_is_function = True
+                    # if the last iteration set next_token_is_function
+                    # to true we now want this name highlighted as
+                    # function. so do that and reset the state
+                    elif next_token_is_function:
+                        # Look if the next token is a dot. If yes it's
+                        # not a function, but a class name and the
+                        # part after the dot a function name
+                        if not self.is_portugol and scanner.test(r'\s*\.\s*'):
+                            token = Name.Class
+                        # it's not a dot, our job is done
+                        else:
+                            token = Name.Function
+                            next_token_is_function = False
+
+                            if self.is_portugol:
+                                block_labels.add(scanner.match.lower())
+
+                    # same for properties
+                    elif not self.is_portugol and next_token_is_property:
+                        token = Name.Property
+                        next_token_is_property = False
+                    # Highlight this token as label and add it
+                    # to the list of known labels
+                    elif not self.is_portugol and collect_labels:
+                        token = Name.Label
+                        block_labels.add(scanner.match.lower())
+                    # name is in list of known labels
+                    elif lowercase_name in block_labels:
+                        token = Name.Label
+                    elif self.is_portugol and lowercase_name in self.PORTUGOL_BUILTIN_TYPES:
+                        token = Keyword.Type
+                    elif not self.is_portugol and lowercase_name in self.BUILTIN_TYPES:
+                        token = Keyword.Type
+                    elif not self.is_portugol and lowercase_name in self.DIRECTIVES:
+                        token = Keyword.Pseudo
+                    # builtins are just builtins if the token
+                    # before isn't a dot
+                    elif not self.is_portugol and not was_dot and lowercase_name in self.builtins:
+                        token = Name.Builtin
+                    else:
+                        token = Name
+                elif self.is_portugol and scanner.scan(r"\""):
+                    token = String
+                    stack.append('string')
+                elif not self.is_portugol and scanner.scan(r"'"):
+                    token = String
+                    stack.append('string')
+                elif not self.is_portugol and scanner.scan(r'\#(\d+|\$[0-9A-Fa-f]+)'):
+                    token = String.Char
+                elif not self.is_portugol and scanner.scan(r'\$[0-9A-Fa-f]+'):
+                    token = Number.Hex
+                elif scanner.scan(r'\d+(?![eE]|\.[^.])'):
+                    token = Number.Integer
+                elif scanner.scan(r'\d+(\.\d+([eE][+-]?\d+)?|[eE][+-]?\d+)'):
+                    token = Number.Float
+                else:
+                    # if the stack depth is deeper than once, pop
+                    if len(stack) > 1:
+                        stack.pop()
+                    scanner.get_char()
+
+            elif stack[-1] == 'string':
+                if self.is_portugol:
+                    if scanner.scan(r"''"):
+                        token = String.Escape
+                    elif scanner.scan(r"\""):
+                        token = String
+                        stack.pop()
+                    elif scanner.scan(r"[^\"]*"):
+                        token = String
+                    else:
+                        scanner.get_char()
+                        stack.pop()
+                else:
+                    if scanner.scan(r"''"):
+                        token = String.Escape
+                    elif scanner.scan(r"'"):
+                        token = String
+                        stack.pop()
+                    elif scanner.scan(r"[^']*"):
+                        token = String
+                    else:
+                        scanner.get_char()
+                        stack.pop()
+            elif not self.is_portugol and stack[-1] == 'asm':
+                if scanner.scan(r'\s+'):
+                    token = Whitespace
+                elif scanner.scan(r'end'):
+                    token = Keyword
+                    stack.pop()
+                elif scanner.scan(r'\{.*?\}|\(\*.*?\*\)'):
+                    if scanner.match.startswith('$'):
+                        token = Comment.Preproc
+                    else:
+                        token = Comment.Multiline
+                elif scanner.scan(r'//.*?$'):
+                    token = Comment.Single
+                elif scanner.scan(r"'"):
+                    token = String
+                    stack.append('string')
+                elif scanner.scan(r'@@[A-Za-z_][A-Za-z_0-9]*'):
+                    token = Name.Label
+                elif scanner.scan(r'[A-Za-z_][A-Za-z_0-9]*'):
+                    lowercase_name = scanner.match.lower()
+                    if lowercase_name in self.ASM_INSTRUCTIONS:
+                        token = Keyword
+                    elif lowercase_name in self.ASM_REGISTERS:
+                        token = Name.Builtin
+                    else:
+                        token = Name
+                elif scanner.scan(r'[-+*\/=<>:;,.@\^]+'):
+                    token = Operator
+                elif scanner.scan(r'[\(\)\[\]]+'):
+                    token = Punctuation
+                elif scanner.scan(r'\$[0-9A-Fa-f]+'):
+                    token = Number.Hex
+                elif scanner.scan(r'\d+(?![eE]|\.[^.])'):
+                    token = Number.Integer
+                elif scanner.scan(r'\d+(\.\d+([eE][+-]?\d+)?|[eE][+-]?\d+)'):
+                    token = Number.Float
+                else:
+                    scanner.get_char()
+                    stack.pop()
+
+            # save the dot!!!11
+            if not self.is_portugol and scanner.match.strip():
+                was_dot = scanner.match == '.'
+
+            yield scanner.start_pos, token, scanner.match or ''
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/pawn.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/pawn.py
new file mode 100644
index 0000000000000000000000000000000000000000..9b4234c3a274ed46b01f0aee17df86e7868e1502
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/pawn.py
@@ -0,0 +1,202 @@
+"""
+    pygments.lexers.pawn
+    ~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for the Pawn languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation
+from pygments.util import get_bool_opt
+
+__all__ = ['SourcePawnLexer', 'PawnLexer']
+
+
+class SourcePawnLexer(RegexLexer):
+    """
+    For SourcePawn source code with preprocessor directives.
+    """
+    name = 'SourcePawn'
+    aliases = ['sp']
+    filenames = ['*.sp']
+    mimetypes = ['text/x-sourcepawn']
+    url = 'https://github.com/alliedmodders/sourcepawn'
+    version_added = '1.6'
+
+    #: optional Comment or Whitespace
+    _ws = r'(?:\s|//.*?\n|/\*.*?\*/)+'
+    #: only one /* */ style comment
+    _ws1 = r'\s*(?:/[*].*?[*]/\s*)*'
+
+    tokens = {
+        'root': [
+            # preprocessor directives: without whitespace
+            (r'^#if\s+0', Comment.Preproc, 'if0'),
+            ('^#', Comment.Preproc, 'macro'),
+            # or with whitespace
+            ('^' + _ws1 + r'#if\s+0', Comment.Preproc, 'if0'),
+            ('^' + _ws1 + '#', Comment.Preproc, 'macro'),
+            (r'\n', Text),
+            (r'\s+', Text),
+            (r'\\\n', Text),  # line continuation
+            (r'/(\\\n)?/(\n|(.|\n)*?[^\\]\n)', Comment.Single),
+            (r'/(\\\n)?\*(.|\n)*?\*(\\\n)?/', Comment.Multiline),
+            (r'[{}]', Punctuation),
+            (r'L?"', String, 'string'),
+            (r"L?'(\\.|\\[0-7]{1,3}|\\x[a-fA-F0-9]{1,2}|[^\\\'\n])'", String.Char),
+            (r'(\d+\.\d*|\.\d+|\d+)[eE][+-]?\d+[LlUu]*', Number.Float),
+            (r'(\d+\.\d*|\.\d+|\d+[fF])[fF]?', Number.Float),
+            (r'0x[0-9a-fA-F]+[LlUu]*', Number.Hex),
+            (r'0[0-7]+[LlUu]*', Number.Oct),
+            (r'\d+[LlUu]*', Number.Integer),
+            (r'[~!%^&*+=|?:<>/-]', Operator),
+            (r'[()\[\],.;]', Punctuation),
+            (r'(case|const|continue|native|'
+             r'default|else|enum|for|if|new|operator|'
+             r'public|return|sizeof|static|decl|struct|switch)\b', Keyword),
+            (r'(bool|Float)\b', Keyword.Type),
+            (r'(true|false)\b', Keyword.Constant),
+            (r'[a-zA-Z_]\w*', Name),
+        ],
+        'string': [
+            (r'"', String, '#pop'),
+            (r'\\([\\abfnrtv"\']|x[a-fA-F0-9]{2,4}|[0-7]{1,3})', String.Escape),
+            (r'[^\\"\n]+', String),  # all other characters
+            (r'\\\n', String),       # line continuation
+            (r'\\', String),         # stray backslash
+        ],
+        'macro': [
+            (r'[^/\n]+', Comment.Preproc),
+            (r'/\*(.|\n)*?\*/', Comment.Multiline),
+            (r'//.*?\n', Comment.Single, '#pop'),
+            (r'/', Comment.Preproc),
+            (r'(?<=\\)\n', Comment.Preproc),
+            (r'\n', Comment.Preproc, '#pop'),
+        ],
+        'if0': [
+            (r'^\s*#if.*?(?/-]', Operator),
+            (r'[()\[\],.;]', Punctuation),
+            (r'(switch|case|default|const|new|static|char|continue|break|'
+             r'if|else|for|while|do|operator|enum|'
+             r'public|return|sizeof|tagof|state|goto)\b', Keyword),
+            (r'(bool|Float)\b', Keyword.Type),
+            (r'(true|false)\b', Keyword.Constant),
+            (r'[a-zA-Z_]\w*', Name),
+        ],
+        'string': [
+            (r'"', String, '#pop'),
+            (r'\\([\\abfnrtv"\']|x[a-fA-F0-9]{2,4}|[0-7]{1,3})', String.Escape),
+            (r'[^\\"\n]+', String),  # all other characters
+            (r'\\\n', String),       # line continuation
+            (r'\\', String),         # stray backslash
+        ],
+        'macro': [
+            (r'[^/\n]+', Comment.Preproc),
+            (r'/\*(.|\n)*?\*/', Comment.Multiline),
+            (r'//.*?\n', Comment.Single, '#pop'),
+            (r'/', Comment.Preproc),
+            (r'(?<=\\)\n', Comment.Preproc),
+            (r'\n', Comment.Preproc, '#pop'),
+        ],
+        'if0': [
+            (r'^\s*#if.*?(?<-]', Operator),
+            (r'[a-zA-Z][a-zA-Z0-9_-]*', Name),
+            (r'\?[a-zA-Z][a-zA-Z0-9_-]*', Name.Variable),
+            (r'[0-9]+\.[0-9]+', Number.Float),
+            (r'[0-9]+', Number.Integer),
+        ],
+        'keywords': [
+            (words((
+                ':requirements', ':types', ':constants',
+                ':predicates', ':functions', ':action', ':agent',
+                ':parameters', ':precondition', ':effect',
+                ':durative-action', ':duration', ':condition',
+                ':derived', ':domain', ':objects', ':init',
+                ':goal', ':metric', ':length', ':serial', ':parallel',
+                # the following are requirements
+                ':strips', ':typing', ':negative-preconditions',
+                ':disjunctive-preconditions', ':equality',
+                ':existential-preconditions', ':universal-preconditions',
+                ':conditional-effects', ':fluents', ':numeric-fluents',
+                ':object-fluents', ':adl', ':durative-actions',
+                ':continuous-effects', ':derived-predicates',
+                ':time-intial-literals', ':preferences',
+                ':constraints', ':action-costs', ':multi-agent',
+                ':unfactored-privacy', ':factored-privacy',
+                ':non-deterministic'
+                ), suffix=r'\b'), Keyword)
+        ],
+        'builtins': [
+            (words((
+                'define', 'domain', 'object', 'either', 'and',
+                'forall', 'preference', 'imply', 'or', 'exists',
+                'not', 'when', 'assign', 'scale-up', 'scale-down',
+                'increase', 'decrease', 'at', 'over', 'start',
+                'end', 'all', 'problem', 'always', 'sometime',
+                'within', 'at-most-once', 'sometime-after',
+                'sometime-before', 'always-within', 'hold-during',
+                'hold-after', 'minimize', 'maximize',
+                'total-time', 'is-violated'), suffix=r'\b'),
+                Name.Builtin)
+        ]
+    }
+
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/perl.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/perl.py
new file mode 100644
index 0000000000000000000000000000000000000000..7448d2a1e2bb822837079cfec4690b56825bf0b7
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/perl.py
@@ -0,0 +1,733 @@
+"""
+    pygments.lexers.perl
+    ~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for Perl, Raku and related languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, ExtendedRegexLexer, include, bygroups, \
+    using, this, default, words
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation, Whitespace
+from pygments.util import shebang_matches
+
+__all__ = ['PerlLexer', 'Perl6Lexer']
+
+
+class PerlLexer(RegexLexer):
+    """
+    For Perl source code.
+    """
+
+    name = 'Perl'
+    url = 'https://www.perl.org'
+    aliases = ['perl', 'pl']
+    filenames = ['*.pl', '*.pm', '*.t', '*.perl']
+    mimetypes = ['text/x-perl', 'application/x-perl']
+    version_added = ''
+
+    flags = re.DOTALL | re.MULTILINE
+    # TODO: give this to a perl guy who knows how to parse perl...
+    tokens = {
+        'balanced-regex': [
+            (r'/(\\\\|\\[^\\]|[^\\/])*/[egimosx]*', String.Regex, '#pop'),
+            (r'!(\\\\|\\[^\\]|[^\\!])*![egimosx]*', String.Regex, '#pop'),
+            (r'\\(\\\\|[^\\])*\\[egimosx]*', String.Regex, '#pop'),
+            (r'\{(\\\\|\\[^\\]|[^\\}])*\}[egimosx]*', String.Regex, '#pop'),
+            (r'<(\\\\|\\[^\\]|[^\\>])*>[egimosx]*', String.Regex, '#pop'),
+            (r'\[(\\\\|\\[^\\]|[^\\\]])*\][egimosx]*', String.Regex, '#pop'),
+            (r'\((\\\\|\\[^\\]|[^\\)])*\)[egimosx]*', String.Regex, '#pop'),
+            (r'@(\\\\|\\[^\\]|[^\\@])*@[egimosx]*', String.Regex, '#pop'),
+            (r'%(\\\\|\\[^\\]|[^\\%])*%[egimosx]*', String.Regex, '#pop'),
+            (r'\$(\\\\|\\[^\\]|[^\\$])*\$[egimosx]*', String.Regex, '#pop'),
+        ],
+        'root': [
+            (r'\A\#!.+?$', Comment.Hashbang),
+            (r'\#.*?$', Comment.Single),
+            (r'^=[a-zA-Z0-9]+\s+.*?\n=cut', Comment.Multiline),
+            (words((
+                'case', 'continue', 'do', 'else', 'elsif', 'for', 'foreach',
+                'if', 'last', 'my', 'next', 'our', 'redo', 'reset', 'then',
+                'unless', 'until', 'while', 'print', 'new', 'BEGIN',
+                'CHECK', 'INIT', 'END', 'return'), suffix=r'\b'),
+             Keyword),
+            (r'(format)(\s+)(\w+)(\s*)(=)(\s*\n)',
+             bygroups(Keyword, Whitespace, Name, Whitespace, Punctuation, Whitespace), 'format'),
+            (r'(eq|lt|gt|le|ge|ne|not|and|or|cmp)\b', Operator.Word),
+            # common delimiters
+            (r's/(\\\\|\\[^\\]|[^\\/])*/(\\\\|\\[^\\]|[^\\/])*/[egimosx]*',
+                String.Regex),
+            (r's!(\\\\|\\!|[^!])*!(\\\\|\\!|[^!])*![egimosx]*', String.Regex),
+            (r's\\(\\\\|[^\\])*\\(\\\\|[^\\])*\\[egimosx]*', String.Regex),
+            (r's@(\\\\|\\[^\\]|[^\\@])*@(\\\\|\\[^\\]|[^\\@])*@[egimosx]*',
+                String.Regex),
+            (r's%(\\\\|\\[^\\]|[^\\%])*%(\\\\|\\[^\\]|[^\\%])*%[egimosx]*',
+                String.Regex),
+            # balanced delimiters
+            (r's\{(\\\\|\\[^\\]|[^\\}])*\}\s*', String.Regex, 'balanced-regex'),
+            (r's<(\\\\|\\[^\\]|[^\\>])*>\s*', String.Regex, 'balanced-regex'),
+            (r's\[(\\\\|\\[^\\]|[^\\\]])*\]\s*', String.Regex,
+                'balanced-regex'),
+            (r's\((\\\\|\\[^\\]|[^\\)])*\)\s*', String.Regex,
+                'balanced-regex'),
+
+            (r'm?/(\\\\|\\[^\\]|[^\\/\n])*/[gcimosx]*', String.Regex),
+            (r'm(?=[/!\\{<\[(@%$])', String.Regex, 'balanced-regex'),
+            (r'((?<==~)|(?<=\())\s*/(\\\\|\\[^\\]|[^\\/])*/[gcimosx]*',
+                String.Regex),
+            (r'\s+', Whitespace),
+            (words((
+                'abs', 'accept', 'alarm', 'atan2', 'bind', 'binmode', 'bless', 'caller', 'chdir',
+                'chmod', 'chomp', 'chop', 'chown', 'chr', 'chroot', 'close', 'closedir', 'connect',
+                'continue', 'cos', 'crypt', 'dbmclose', 'dbmopen', 'defined', 'delete', 'die',
+                'dump', 'each', 'endgrent', 'endhostent', 'endnetent', 'endprotoent',
+                'endpwent', 'endservent', 'eof', 'eval', 'exec', 'exists', 'exit', 'exp', 'fcntl',
+                'fileno', 'flock', 'fork', 'format', 'formline', 'getc', 'getgrent', 'getgrgid',
+                'getgrnam', 'gethostbyaddr', 'gethostbyname', 'gethostent', 'getlogin',
+                'getnetbyaddr', 'getnetbyname', 'getnetent', 'getpeername', 'getpgrp',
+                'getppid', 'getpriority', 'getprotobyname', 'getprotobynumber',
+                'getprotoent', 'getpwent', 'getpwnam', 'getpwuid', 'getservbyname',
+                'getservbyport', 'getservent', 'getsockname', 'getsockopt', 'glob', 'gmtime',
+                'goto', 'grep', 'hex', 'import', 'index', 'int', 'ioctl', 'join', 'keys', 'kill', 'last',
+                'lc', 'lcfirst', 'length', 'link', 'listen', 'local', 'localtime', 'log', 'lstat',
+                'map', 'mkdir', 'msgctl', 'msgget', 'msgrcv', 'msgsnd', 'my', 'next', 'oct', 'open',
+                'opendir', 'ord', 'our', 'pack', 'pipe', 'pop', 'pos', 'printf',
+                'prototype', 'push', 'quotemeta', 'rand', 'read', 'readdir',
+                'readline', 'readlink', 'readpipe', 'recv', 'redo', 'ref', 'rename',
+                'reverse', 'rewinddir', 'rindex', 'rmdir', 'scalar', 'seek', 'seekdir',
+                'select', 'semctl', 'semget', 'semop', 'send', 'setgrent', 'sethostent', 'setnetent',
+                'setpgrp', 'setpriority', 'setprotoent', 'setpwent', 'setservent',
+                'setsockopt', 'shift', 'shmctl', 'shmget', 'shmread', 'shmwrite', 'shutdown',
+                'sin', 'sleep', 'socket', 'socketpair', 'sort', 'splice', 'split', 'sprintf', 'sqrt',
+                'srand', 'stat', 'study', 'substr', 'symlink', 'syscall', 'sysopen', 'sysread',
+                'sysseek', 'system', 'syswrite', 'tell', 'telldir', 'tie', 'tied', 'time', 'times', 'tr',
+                'truncate', 'uc', 'ucfirst', 'umask', 'undef', 'unlink', 'unpack', 'unshift', 'untie',
+                'utime', 'values', 'vec', 'wait', 'waitpid', 'wantarray', 'warn', 'write'), suffix=r'\b'),
+             Name.Builtin),
+            (r'((__(DATA|DIE|WARN)__)|(STD(IN|OUT|ERR)))\b', Name.Builtin.Pseudo),
+            (r'(<<)([\'"]?)([a-zA-Z_]\w*)(\2;?\n.*?\n)(\3)(\n)',
+             bygroups(String, String, String.Delimiter, String, String.Delimiter, Whitespace)),
+            (r'__END__', Comment.Preproc, 'end-part'),
+            (r'\$\^[ADEFHILMOPSTWX]', Name.Variable.Global),
+            (r"\$[\\\"\[\]'&`+*.,;=%~?@$!<>(^|/-](?!\w)", Name.Variable.Global),
+            (r'[$@%#]+', Name.Variable, 'varname'),
+            (r'0_?[0-7]+(_[0-7]+)*', Number.Oct),
+            (r'0x[0-9A-Fa-f]+(_[0-9A-Fa-f]+)*', Number.Hex),
+            (r'0b[01]+(_[01]+)*', Number.Bin),
+            (r'(?i)(\d*(_\d*)*\.\d+(_\d*)*|\d+(_\d*)*\.\d+(_\d*)*)(e[+-]?\d+)?',
+             Number.Float),
+            (r'(?i)\d+(_\d*)*e[+-]?\d+(_\d*)*', Number.Float),
+            (r'\d+(_\d+)*', Number.Integer),
+            (r"'(\\\\|\\[^\\]|[^'\\])*'", String),
+            (r'"(\\\\|\\[^\\]|[^"\\])*"', String),
+            (r'`(\\\\|\\[^\\]|[^`\\])*`', String.Backtick),
+            (r'<([^\s>]+)>', String.Regex),
+            (r'(q|qq|qw|qr|qx)\{', String.Other, 'cb-string'),
+            (r'(q|qq|qw|qr|qx)\(', String.Other, 'rb-string'),
+            (r'(q|qq|qw|qr|qx)\[', String.Other, 'sb-string'),
+            (r'(q|qq|qw|qr|qx)\<', String.Other, 'lt-string'),
+            (r'(q|qq|qw|qr|qx)([\W_])(.|\n)*?\2', String.Other),
+            (r'(package)(\s+)([a-zA-Z_]\w*(?:::[a-zA-Z_]\w*)*)',
+             bygroups(Keyword, Whitespace, Name.Namespace)),
+            (r'(use|require|no)(\s+)([a-zA-Z_]\w*(?:::[a-zA-Z_]\w*)*)',
+             bygroups(Keyword, Whitespace, Name.Namespace)),
+            (r'(sub)(\s+)', bygroups(Keyword, Whitespace), 'funcname'),
+            (words((
+                'no', 'package', 'require', 'use'), suffix=r'\b'),
+             Keyword),
+            (r'(\[\]|\*\*|::|<<|>>|>=|<=>|<=|={3}|!=|=~|'
+             r'!~|&&?|\|\||\.{1,3})', Operator),
+            (r'[-+/*%=<>&^|!\\~]=?', Operator),
+            (r'[()\[\]:;,<>/?{}]', Punctuation),  # yes, there's no shortage
+                                                  # of punctuation in Perl!
+            (r'(?=\w)', Name, 'name'),
+        ],
+        'format': [
+            (r'\.\n', String.Interpol, '#pop'),
+            (r'[^\n]*\n', String.Interpol),
+        ],
+        'varname': [
+            (r'\s+', Whitespace),
+            (r'\{', Punctuation, '#pop'),    # hash syntax?
+            (r'\)|,', Punctuation, '#pop'),  # argument specifier
+            (r'\w+::', Name.Namespace),
+            (r'[\w:]+', Name.Variable, '#pop'),
+        ],
+        'name': [
+            (r'[a-zA-Z_]\w*(::[a-zA-Z_]\w*)*(::)?(?=\s*->)', Name.Namespace, '#pop'),
+            (r'[a-zA-Z_]\w*(::[a-zA-Z_]\w*)*::', Name.Namespace, '#pop'),
+            (r'[\w:]+', Name, '#pop'),
+            (r'[A-Z_]+(?=\W)', Name.Constant, '#pop'),
+            (r'(?=\W)', Text, '#pop'),
+        ],
+        'funcname': [
+            (r'[a-zA-Z_]\w*[!?]?', Name.Function),
+            (r'\s+', Whitespace),
+            # argument declaration
+            (r'(\([$@%]*\))(\s*)', bygroups(Punctuation, Whitespace)),
+            (r';', Punctuation, '#pop'),
+            (r'.*?\{', Punctuation, '#pop'),
+        ],
+        'cb-string': [
+            (r'\\[{}\\]', String.Other),
+            (r'\\', String.Other),
+            (r'\{', String.Other, 'cb-string'),
+            (r'\}', String.Other, '#pop'),
+            (r'[^{}\\]+', String.Other)
+        ],
+        'rb-string': [
+            (r'\\[()\\]', String.Other),
+            (r'\\', String.Other),
+            (r'\(', String.Other, 'rb-string'),
+            (r'\)', String.Other, '#pop'),
+            (r'[^()]+', String.Other)
+        ],
+        'sb-string': [
+            (r'\\[\[\]\\]', String.Other),
+            (r'\\', String.Other),
+            (r'\[', String.Other, 'sb-string'),
+            (r'\]', String.Other, '#pop'),
+            (r'[^\[\]]+', String.Other)
+        ],
+        'lt-string': [
+            (r'\\[<>\\]', String.Other),
+            (r'\\', String.Other),
+            (r'\<', String.Other, 'lt-string'),
+            (r'\>', String.Other, '#pop'),
+            (r'[^<>]+', String.Other)
+        ],
+        'end-part': [
+            (r'.+', Comment.Preproc, '#pop')
+        ]
+    }
+
+    def analyse_text(text):
+        if shebang_matches(text, r'perl'):
+            return True
+
+        result = 0
+
+        if re.search(r'(?:my|our)\s+[$@%(]', text):
+            result += 0.9
+
+        if ':=' in text:
+            # := is not valid Perl, but it appears in unicon, so we should
+            # become less confident if we think we found Perl with :=
+            result /= 2
+
+        return result
+
+
+class Perl6Lexer(ExtendedRegexLexer):
+    """
+    For Raku (a.k.a. Perl 6) source code.
+    """
+
+    name = 'Perl6'
+    url = 'https://www.raku.org'
+    aliases = ['perl6', 'pl6', 'raku']
+    filenames = ['*.pl', '*.pm', '*.nqp', '*.p6', '*.6pl', '*.p6l', '*.pl6',
+                 '*.6pm', '*.p6m', '*.pm6', '*.t', '*.raku', '*.rakumod',
+                 '*.rakutest', '*.rakudoc']
+    mimetypes = ['text/x-perl6', 'application/x-perl6']
+    version_added = '2.0'
+    flags = re.MULTILINE | re.DOTALL
+
+    PERL6_IDENTIFIER_RANGE = r"['\w:-]"
+
+    PERL6_KEYWORDS = (
+        #Phasers
+        'BEGIN','CATCH','CHECK','CLOSE','CONTROL','DOC','END','ENTER','FIRST',
+        'INIT','KEEP','LAST','LEAVE','NEXT','POST','PRE','QUIT','UNDO',
+        #Keywords
+        'anon','augment','but','class','constant','default','does','else',
+        'elsif','enum','for','gather','given','grammar','has','if','import',
+        'is','let','loop','made','make','method','module','multi','my','need',
+        'orwith','our','proceed','proto','repeat','require','return',
+        'return-rw','returns','role','rule','state','sub','submethod','subset',
+        'succeed','supersede','token','try','unit','unless','until','use',
+        'when','while','with','without',
+        #Traits
+        'export','native','repr','required','rw','symbol',
+    )
+
+    PERL6_BUILTINS = (
+        'ACCEPTS','abs','abs2rel','absolute','accept','accessed','acos',
+        'acosec','acosech','acosh','acotan','acotanh','acquire','act','action',
+        'actions','add','add_attribute','add_enum_value','add_fallback',
+        'add_method','add_parent','add_private_method','add_role','add_trustee',
+        'adverb','after','all','allocate','allof','allowed','alternative-names',
+        'annotations','antipair','antipairs','any','anyof','app_lifetime',
+        'append','arch','archname','args','arity','Array','asec','asech','asin',
+        'asinh','ASSIGN-KEY','ASSIGN-POS','assuming','ast','at','atan','atan2',
+        'atanh','AT-KEY','atomic-assign','atomic-dec-fetch','atomic-fetch',
+        'atomic-fetch-add','atomic-fetch-dec','atomic-fetch-inc',
+        'atomic-fetch-sub','atomic-inc-fetch','AT-POS','attributes','auth',
+        'await','backtrace','Bag','BagHash','bail-out','base','basename',
+        'base-repeating','batch','BIND-KEY','BIND-POS','bind-stderr',
+        'bind-stdin','bind-stdout','bind-udp','bits','bless','block','Bool',
+        'bool-only','bounds','break','Bridge','broken','BUILD','build-date',
+        'bytes','cache','callframe','calling-package','CALL-ME','callsame',
+        'callwith','can','cancel','candidates','cando','can-ok','canonpath',
+        'caps','caption','Capture','cas','catdir','categorize','categorize-list',
+        'catfile','catpath','cause','ceiling','cglobal','changed','Channel',
+        'chars','chdir','child','child-name','child-typename','chmod','chomp',
+        'chop','chr','chrs','chunks','cis','classify','classify-list','cleanup',
+        'clone','close','closed','close-stdin','cmp-ok','code','codes','collate',
+        'column','comb','combinations','command','comment','compiler','Complex',
+        'compose','compose_type','composer','condition','config',
+        'configure_destroy','configure_type_checking','conj','connect',
+        'constraints','construct','contains','contents','copy','cos','cosec',
+        'cosech','cosh','cotan','cotanh','count','count-only','cpu-cores',
+        'cpu-usage','CREATE','create_type','cross','cue','curdir','curupdir','d',
+        'Date','DateTime','day','daycount','day-of-month','day-of-week',
+        'day-of-year','days-in-month','declaration','decode','decoder','deepmap',
+        'default','defined','DEFINITE','delayed','DELETE-KEY','DELETE-POS',
+        'denominator','desc','DESTROY','destroyers','devnull','diag',
+        'did-you-mean','die','dies-ok','dir','dirname','dir-sep','DISTROnames',
+        'do','does','does-ok','done','done-testing','duckmap','dynamic','e',
+        'eager','earlier','elems','emit','enclosing','encode','encoder',
+        'encoding','end','ends-with','enum_from_value','enum_value_list',
+        'enum_values','enums','eof','EVAL','eval-dies-ok','EVALFILE',
+        'eval-lives-ok','exception','excludes-max','excludes-min','EXISTS-KEY',
+        'EXISTS-POS','exit','exitcode','exp','expected','explicitly-manage',
+        'expmod','extension','f','fail','fails-like','fc','feature','file',
+        'filename','find_method','find_method_qualified','finish','first','flat',
+        'flatmap','flip','floor','flunk','flush','fmt','format','formatter',
+        'freeze','from','from-list','from-loop','from-posix','full',
+        'full-barrier','get','get_value','getc','gist','got','grab','grabpairs',
+        'grep','handle','handled','handles','hardware','has_accessor','Hash',
+        'head','headers','hh-mm-ss','hidden','hides','hour','how','hyper','id',
+        'illegal','im','in','indent','index','indices','indir','infinite',
+        'infix','infix:<+>','infix:<->','install_method_cache','Instant',
+        'instead','Int','int-bounds','interval','in-timezone','invalid-str',
+        'invert','invocant','IO','IO::Notification.watch-path','is_trusted',
+        'is_type','isa','is-absolute','isa-ok','is-approx','is-deeply',
+        'is-hidden','is-initial-thread','is-int','is-lazy','is-leap-year',
+        'isNaN','isnt','is-prime','is-relative','is-routine','is-setting',
+        'is-win','item','iterator','join','keep','kept','KERNELnames','key',
+        'keyof','keys','kill','kv','kxxv','l','lang','last','lastcall','later',
+        'lazy','lc','leading','level','like','line','lines','link','List',
+        'listen','live','lives-ok','local','lock','log','log10','lookup','lsb',
+        'made','MAIN','make','Map','match','max','maxpairs','merge','message',
+        'method','method_table','methods','migrate','min','minmax','minpairs',
+        'minute','misplaced','Mix','MixHash','mkdir','mode','modified','month',
+        'move','mro','msb','multi','multiness','my','name','named','named_names',
+        'narrow','nativecast','native-descriptor','nativesizeof','new','new_type',
+        'new-from-daycount','new-from-pairs','next','nextcallee','next-handle',
+        'nextsame','nextwith','NFC','NFD','NFKC','NFKD','nl-in','nl-out',
+        'nodemap','nok','none','norm','not','note','now','nude','Num',
+        'numerator','Numeric','of','offset','offset-in-hours','offset-in-minutes',
+        'ok','old','on-close','one','on-switch','open','opened','operation',
+        'optional','ord','ords','orig','os-error','osname','out-buffer','pack',
+        'package','package-kind','package-name','packages','pair','pairs',
+        'pairup','parameter','params','parent','parent-name','parents','parse',
+        'parse-base','parsefile','parse-names','parts','pass','path','path-sep',
+        'payload','peer-host','peer-port','periods','perl','permutations','phaser',
+        'pick','pickpairs','pid','placeholder','plan','plus','polar','poll',
+        'polymod','pop','pos','positional','posix','postfix','postmatch',
+        'precomp-ext','precomp-target','pred','prefix','prematch','prepend',
+        'print','printf','print-nl','print-to','private','private_method_table',
+        'proc','produce','Promise','prompt','protect','pull-one','push',
+        'push-all','push-at-least','push-exactly','push-until-lazy','put',
+        'qualifier-type','quit','r','race','radix','rand','range','Rat','raw',
+        're','read','readchars','readonly','ready','Real','reallocate','reals',
+        'reason','rebless','receive','recv','redispatcher','redo','reduce',
+        'rel2abs','relative','release','rename','repeated','replacement',
+        'report','reserved','resolve','restore','result','resume','rethrow',
+        'reverse','right','rindex','rmdir','role','roles_to_compose','rolish',
+        'roll','rootdir','roots','rotate','rotor','round','roundrobin',
+        'routine-type','run','rwx','s','samecase','samemark','samewith','say',
+        'schedule-on','scheduler','scope','sec','sech','second','seek','self',
+        'send','Set','set_hidden','set_name','set_package','set_rw','set_value',
+        'SetHash','set-instruments','setup_finalization','shape','share','shell',
+        'shift','sibling','sigil','sign','signal','signals','signature','sin',
+        'sinh','sink','sink-all','skip','skip-at-least','skip-at-least-pull-one',
+        'skip-one','skip-rest','sleep','sleep-timer','sleep-until','Slip','slurp',
+        'slurp-rest','slurpy','snap','snapper','so','socket-host','socket-port',
+        'sort','source','source-package','spawn','SPEC','splice','split',
+        'splitdir','splitpath','sprintf','spurt','sqrt','squish','srand','stable',
+        'start','started','starts-with','status','stderr','stdout','Str',
+        'sub_signature','subbuf','subbuf-rw','subname','subparse','subst',
+        'subst-mutate','substr','substr-eq','substr-rw','subtest','succ','sum',
+        'Supply','symlink','t','tail','take','take-rw','tan','tanh','tap',
+        'target','target-name','tc','tclc','tell','then','throttle','throw',
+        'throws-like','timezone','tmpdir','to','today','todo','toggle','to-posix',
+        'total','trailing','trans','tree','trim','trim-leading','trim-trailing',
+        'truncate','truncated-to','trusts','try_acquire','trying','twigil','type',
+        'type_captures','typename','uc','udp','uncaught_handler','unimatch',
+        'uniname','uninames','uniparse','uniprop','uniprops','unique','unival',
+        'univals','unlike','unlink','unlock','unpack','unpolar','unshift',
+        'unwrap','updir','USAGE','use-ok','utc','val','value','values','VAR',
+        'variable','verbose-config','version','VMnames','volume','vow','w','wait',
+        'warn','watch','watch-path','week','weekday-of-month','week-number',
+        'week-year','WHAT','when','WHERE','WHEREFORE','WHICH','WHO',
+        'whole-second','WHY','wordcase','words','workaround','wrap','write',
+        'write-to','x','yada','year','yield','yyyy-mm-dd','z','zip','zip-latest',
+
+    )
+
+    PERL6_BUILTIN_CLASSES = (
+        #Booleans
+        'False','True',
+        #Classes
+        'Any','Array','Associative','AST','atomicint','Attribute','Backtrace',
+        'Backtrace::Frame','Bag','Baggy','BagHash','Blob','Block','Bool','Buf',
+        'Callable','CallFrame','Cancellation','Capture','CArray','Channel','Code',
+        'compiler','Complex','ComplexStr','Cool','CurrentThreadScheduler',
+        'Cursor','Date','Dateish','DateTime','Distro','Duration','Encoding',
+        'Exception','Failure','FatRat','Grammar','Hash','HyperWhatever','Instant',
+        'Int','int16','int32','int64','int8','IntStr','IO','IO::ArgFiles',
+        'IO::CatHandle','IO::Handle','IO::Notification','IO::Path',
+        'IO::Path::Cygwin','IO::Path::QNX','IO::Path::Unix','IO::Path::Win32',
+        'IO::Pipe','IO::Socket','IO::Socket::Async','IO::Socket::INET','IO::Spec',
+        'IO::Spec::Cygwin','IO::Spec::QNX','IO::Spec::Unix','IO::Spec::Win32',
+        'IO::Special','Iterable','Iterator','Junction','Kernel','Label','List',
+        'Lock','Lock::Async','long','longlong','Macro','Map','Match',
+        'Metamodel::AttributeContainer','Metamodel::C3MRO','Metamodel::ClassHOW',
+        'Metamodel::EnumHOW','Metamodel::Finalization','Metamodel::MethodContainer',
+        'Metamodel::MROBasedMethodDispatch','Metamodel::MultipleInheritance',
+        'Metamodel::Naming','Metamodel::Primitives','Metamodel::PrivateMethodContainer',
+        'Metamodel::RoleContainer','Metamodel::Trusting','Method','Mix','MixHash',
+        'Mixy','Mu','NFC','NFD','NFKC','NFKD','Nil','Num','num32','num64',
+        'Numeric','NumStr','ObjAt','Order','Pair','Parameter','Perl','Pod::Block',
+        'Pod::Block::Code','Pod::Block::Comment','Pod::Block::Declarator',
+        'Pod::Block::Named','Pod::Block::Para','Pod::Block::Table','Pod::Heading',
+        'Pod::Item','Pointer','Positional','PositionalBindFailover','Proc',
+        'Proc::Async','Promise','Proxy','PseudoStash','QuantHash','Range','Rat',
+        'Rational','RatStr','Real','Regex','Routine','Scalar','Scheduler',
+        'Semaphore','Seq','Set','SetHash','Setty','Signature','size_t','Slip',
+        'Stash','Str','StrDistance','Stringy','Sub','Submethod','Supplier',
+        'Supplier::Preserving','Supply','Systemic','Tap','Telemetry',
+        'Telemetry::Instrument::Thread','Telemetry::Instrument::Usage',
+        'Telemetry::Period','Telemetry::Sampler','Thread','ThreadPoolScheduler',
+        'UInt','uint16','uint32','uint64','uint8','Uni','utf8','Variable',
+        'Version','VM','Whatever','WhateverCode','WrapHandle'
+    )
+
+    PERL6_OPERATORS = (
+        'X', 'Z', 'after', 'also', 'and', 'andthen', 'before', 'cmp', 'div',
+        'eq', 'eqv', 'extra', 'ff', 'fff', 'ge', 'gt', 'le', 'leg', 'lt', 'm',
+        'mm', 'mod', 'ne', 'or', 'orelse', 'rx', 's', 'tr', 'x', 'xor', 'xx',
+        '++', '--', '**', '!', '+', '-', '~', '?', '|', '||', '+^', '~^', '?^',
+        '^', '*', '/', '%', '%%', '+&', '+<', '+>', '~&', '~<', '~>', '?&',
+        'gcd', 'lcm', '+', '-', '+|', '+^', '~|', '~^', '?|', '?^',
+        '~', '&', '^', 'but', 'does', '<=>', '..', '..^', '^..', '^..^',
+        '!=', '==', '<', '<=', '>', '>=', '~~', '===', '!eqv',
+        '&&', '||', '^^', '//', 'min', 'max', '??', '!!', 'ff', 'fff', 'so',
+        'not', '<==', '==>', '<<==', '==>>','unicmp',
+    )
+
+    # Perl 6 has a *lot* of possible bracketing characters
+    # this list was lifted from STD.pm6 (https://github.com/perl6/std)
+    PERL6_BRACKETS = {
+        '\u0028': '\u0029', '\u003c': '\u003e', '\u005b': '\u005d',
+        '\u007b': '\u007d', '\u00ab': '\u00bb', '\u0f3a': '\u0f3b',
+        '\u0f3c': '\u0f3d', '\u169b': '\u169c', '\u2018': '\u2019',
+        '\u201a': '\u2019', '\u201b': '\u2019', '\u201c': '\u201d',
+        '\u201e': '\u201d', '\u201f': '\u201d', '\u2039': '\u203a',
+        '\u2045': '\u2046', '\u207d': '\u207e', '\u208d': '\u208e',
+        '\u2208': '\u220b', '\u2209': '\u220c', '\u220a': '\u220d',
+        '\u2215': '\u29f5', '\u223c': '\u223d', '\u2243': '\u22cd',
+        '\u2252': '\u2253', '\u2254': '\u2255', '\u2264': '\u2265',
+        '\u2266': '\u2267', '\u2268': '\u2269', '\u226a': '\u226b',
+        '\u226e': '\u226f', '\u2270': '\u2271', '\u2272': '\u2273',
+        '\u2274': '\u2275', '\u2276': '\u2277', '\u2278': '\u2279',
+        '\u227a': '\u227b', '\u227c': '\u227d', '\u227e': '\u227f',
+        '\u2280': '\u2281', '\u2282': '\u2283', '\u2284': '\u2285',
+        '\u2286': '\u2287', '\u2288': '\u2289', '\u228a': '\u228b',
+        '\u228f': '\u2290', '\u2291': '\u2292', '\u2298': '\u29b8',
+        '\u22a2': '\u22a3', '\u22a6': '\u2ade', '\u22a8': '\u2ae4',
+        '\u22a9': '\u2ae3', '\u22ab': '\u2ae5', '\u22b0': '\u22b1',
+        '\u22b2': '\u22b3', '\u22b4': '\u22b5', '\u22b6': '\u22b7',
+        '\u22c9': '\u22ca', '\u22cb': '\u22cc', '\u22d0': '\u22d1',
+        '\u22d6': '\u22d7', '\u22d8': '\u22d9', '\u22da': '\u22db',
+        '\u22dc': '\u22dd', '\u22de': '\u22df', '\u22e0': '\u22e1',
+        '\u22e2': '\u22e3', '\u22e4': '\u22e5', '\u22e6': '\u22e7',
+        '\u22e8': '\u22e9', '\u22ea': '\u22eb', '\u22ec': '\u22ed',
+        '\u22f0': '\u22f1', '\u22f2': '\u22fa', '\u22f3': '\u22fb',
+        '\u22f4': '\u22fc', '\u22f6': '\u22fd', '\u22f7': '\u22fe',
+        '\u2308': '\u2309', '\u230a': '\u230b', '\u2329': '\u232a',
+        '\u23b4': '\u23b5', '\u2768': '\u2769', '\u276a': '\u276b',
+        '\u276c': '\u276d', '\u276e': '\u276f', '\u2770': '\u2771',
+        '\u2772': '\u2773', '\u2774': '\u2775', '\u27c3': '\u27c4',
+        '\u27c5': '\u27c6', '\u27d5': '\u27d6', '\u27dd': '\u27de',
+        '\u27e2': '\u27e3', '\u27e4': '\u27e5', '\u27e6': '\u27e7',
+        '\u27e8': '\u27e9', '\u27ea': '\u27eb', '\u2983': '\u2984',
+        '\u2985': '\u2986', '\u2987': '\u2988', '\u2989': '\u298a',
+        '\u298b': '\u298c', '\u298d': '\u298e', '\u298f': '\u2990',
+        '\u2991': '\u2992', '\u2993': '\u2994', '\u2995': '\u2996',
+        '\u2997': '\u2998', '\u29c0': '\u29c1', '\u29c4': '\u29c5',
+        '\u29cf': '\u29d0', '\u29d1': '\u29d2', '\u29d4': '\u29d5',
+        '\u29d8': '\u29d9', '\u29da': '\u29db', '\u29f8': '\u29f9',
+        '\u29fc': '\u29fd', '\u2a2b': '\u2a2c', '\u2a2d': '\u2a2e',
+        '\u2a34': '\u2a35', '\u2a3c': '\u2a3d', '\u2a64': '\u2a65',
+        '\u2a79': '\u2a7a', '\u2a7d': '\u2a7e', '\u2a7f': '\u2a80',
+        '\u2a81': '\u2a82', '\u2a83': '\u2a84', '\u2a8b': '\u2a8c',
+        '\u2a91': '\u2a92', '\u2a93': '\u2a94', '\u2a95': '\u2a96',
+        '\u2a97': '\u2a98', '\u2a99': '\u2a9a', '\u2a9b': '\u2a9c',
+        '\u2aa1': '\u2aa2', '\u2aa6': '\u2aa7', '\u2aa8': '\u2aa9',
+        '\u2aaa': '\u2aab', '\u2aac': '\u2aad', '\u2aaf': '\u2ab0',
+        '\u2ab3': '\u2ab4', '\u2abb': '\u2abc', '\u2abd': '\u2abe',
+        '\u2abf': '\u2ac0', '\u2ac1': '\u2ac2', '\u2ac3': '\u2ac4',
+        '\u2ac5': '\u2ac6', '\u2acd': '\u2ace', '\u2acf': '\u2ad0',
+        '\u2ad1': '\u2ad2', '\u2ad3': '\u2ad4', '\u2ad5': '\u2ad6',
+        '\u2aec': '\u2aed', '\u2af7': '\u2af8', '\u2af9': '\u2afa',
+        '\u2e02': '\u2e03', '\u2e04': '\u2e05', '\u2e09': '\u2e0a',
+        '\u2e0c': '\u2e0d', '\u2e1c': '\u2e1d', '\u2e20': '\u2e21',
+        '\u3008': '\u3009', '\u300a': '\u300b', '\u300c': '\u300d',
+        '\u300e': '\u300f', '\u3010': '\u3011', '\u3014': '\u3015',
+        '\u3016': '\u3017', '\u3018': '\u3019', '\u301a': '\u301b',
+        '\u301d': '\u301e', '\ufd3e': '\ufd3f', '\ufe17': '\ufe18',
+        '\ufe35': '\ufe36', '\ufe37': '\ufe38', '\ufe39': '\ufe3a',
+        '\ufe3b': '\ufe3c', '\ufe3d': '\ufe3e', '\ufe3f': '\ufe40',
+        '\ufe41': '\ufe42', '\ufe43': '\ufe44', '\ufe47': '\ufe48',
+        '\ufe59': '\ufe5a', '\ufe5b': '\ufe5c', '\ufe5d': '\ufe5e',
+        '\uff08': '\uff09', '\uff1c': '\uff1e', '\uff3b': '\uff3d',
+        '\uff5b': '\uff5d', '\uff5f': '\uff60', '\uff62': '\uff63',
+    }
+
+    def _build_word_match(words, boundary_regex_fragment=None, prefix='', suffix=''):
+        if boundary_regex_fragment is None:
+            return r'\b(' + prefix + r'|'.join(re.escape(x) for x in words) + \
+                suffix + r')\b'
+        else:
+            return r'(? 0:
+                    next_open_pos = text.find(opening_chars, search_pos + n_chars)
+                    next_close_pos = text.find(closing_chars, search_pos + n_chars)
+
+                    if next_close_pos == -1:
+                        next_close_pos = len(text)
+                        nesting_level = 0
+                    elif next_open_pos != -1 and next_open_pos < next_close_pos:
+                        nesting_level += 1
+                        search_pos = next_open_pos
+                    else:  # next_close_pos < next_open_pos
+                        nesting_level -= 1
+                        search_pos = next_close_pos
+
+                end_pos = next_close_pos
+
+            if end_pos < 0:     # if we didn't find a closer, just highlight the
+                                # rest of the text in this class
+                end_pos = len(text)
+
+            if adverbs is not None and re.search(r':to\b', adverbs):
+                heredoc_terminator = text[match.start('delimiter') + n_chars:end_pos]
+                end_heredoc = re.search(r'^\s*' + re.escape(heredoc_terminator) +
+                                        r'\s*$', text[end_pos:], re.MULTILINE)
+
+                if end_heredoc:
+                    end_pos += end_heredoc.end()
+                else:
+                    end_pos = len(text)
+
+            yield match.start(), token_class, text[match.start():end_pos + n_chars]
+            context.pos = end_pos + n_chars
+
+        return callback
+
+    def opening_brace_callback(lexer, match, context):
+        stack = context.stack
+
+        yield match.start(), Text, context.text[match.start():match.end()]
+        context.pos = match.end()
+
+        # if we encounter an opening brace and we're one level
+        # below a token state, it means we need to increment
+        # the nesting level for braces so we know later when
+        # we should return to the token rules.
+        if len(stack) > 2 and stack[-2] == 'token':
+            context.perl6_token_nesting_level += 1
+
+    def closing_brace_callback(lexer, match, context):
+        stack = context.stack
+
+        yield match.start(), Text, context.text[match.start():match.end()]
+        context.pos = match.end()
+
+        # if we encounter a free closing brace and we're one level
+        # below a token state, it means we need to check the nesting
+        # level to see if we need to return to the token state.
+        if len(stack) > 2 and stack[-2] == 'token':
+            context.perl6_token_nesting_level -= 1
+            if context.perl6_token_nesting_level == 0:
+                stack.pop()
+
+    def embedded_perl6_callback(lexer, match, context):
+        context.perl6_token_nesting_level = 1
+        yield match.start(), Text, context.text[match.start():match.end()]
+        context.pos = match.end()
+        context.stack.append('root')
+
+    # If you're modifying these rules, be careful if you need to process '{' or '}'
+    # characters. We have special logic for processing these characters (due to the fact
+    # that you can nest Perl 6 code in regex blocks), so if you need to process one of
+    # them, make sure you also process the corresponding one!
+    tokens = {
+        'common': [
+            (r'#[`|=](?P(?P[' + ''.join(PERL6_BRACKETS) + r'])(?P=first_char)*)',
+             brackets_callback(Comment.Multiline)),
+            (r'#[^\n]*$', Comment.Single),
+            (r'^(\s*)=begin\s+(\w+)\b.*?^\1=end\s+\2', Comment.Multiline),
+            (r'^(\s*)=for.*?\n\s*?\n', Comment.Multiline),
+            (r'^=.*?\n\s*?\n', Comment.Multiline),
+            (r'(regex|token|rule)(\s*' + PERL6_IDENTIFIER_RANGE + '+:sym)',
+             bygroups(Keyword, Name), 'token-sym-brackets'),
+            (r'(regex|token|rule)(?!' + PERL6_IDENTIFIER_RANGE + r')(\s*' + PERL6_IDENTIFIER_RANGE + '+)?',
+             bygroups(Keyword, Name), 'pre-token'),
+            # deal with a special case in the Perl 6 grammar (role q { ... })
+            (r'(role)(\s+)(q)(\s*)', bygroups(Keyword, Whitespace, Name, Whitespace)),
+            (_build_word_match(PERL6_KEYWORDS, PERL6_IDENTIFIER_RANGE), Keyword),
+            (_build_word_match(PERL6_BUILTIN_CLASSES, PERL6_IDENTIFIER_RANGE, suffix='(?::[UD])?'),
+             Name.Builtin),
+            (_build_word_match(PERL6_BUILTINS, PERL6_IDENTIFIER_RANGE), Name.Builtin),
+            # copied from PerlLexer
+            (r'[$@%&][.^:?=!~]?' + PERL6_IDENTIFIER_RANGE + '+(?:<<.*?>>|<.*?>|«.*?»)*',
+             Name.Variable),
+            (r'\$[!/](?:<<.*?>>|<.*?>|«.*?»)*', Name.Variable.Global),
+            (r'::\?\w+', Name.Variable.Global),
+            (r'[$@%&]\*' + PERL6_IDENTIFIER_RANGE + '+(?:<<.*?>>|<.*?>|«.*?»)*',
+             Name.Variable.Global),
+            (r'\$(?:<.*?>)+', Name.Variable),
+            (r'(?:q|qq|Q)[a-zA-Z]?\s*(?P:[\w\s:]+)?\s*(?P(?P[^0-9a-zA-Z:\s])'
+             r'(?P=first_char)*)', brackets_callback(String)),
+            # copied from PerlLexer
+            (r'0_?[0-7]+(_[0-7]+)*', Number.Oct),
+            (r'0x[0-9A-Fa-f]+(_[0-9A-Fa-f]+)*', Number.Hex),
+            (r'0b[01]+(_[01]+)*', Number.Bin),
+            (r'(?i)(\d*(_\d*)*\.\d+(_\d*)*|\d+(_\d*)*\.\d+(_\d*)*)(e[+-]?\d+)?',
+             Number.Float),
+            (r'(?i)\d+(_\d*)*e[+-]?\d+(_\d*)*', Number.Float),
+            (r'\d+(_\d+)*', Number.Integer),
+            (r'(?<=~~)\s*/(?:\\\\|\\/|.)*?/', String.Regex),
+            (r'(?<=[=(,])\s*/(?:\\\\|\\/|.)*?/', String.Regex),
+            (r'm\w+(?=\()', Name),
+            (r'(?:m|ms|rx)\s*(?P:[\w\s:]+)?\s*(?P(?P[^\w:\s])'
+             r'(?P=first_char)*)', brackets_callback(String.Regex)),
+            (r'(?:s|ss|tr)\s*(?::[\w\s:]+)?\s*/(?:\\\\|\\/|.)*?/(?:\\\\|\\/|.)*?/',
+             String.Regex),
+            (r'<[^\s=].*?\S>', String),
+            (_build_word_match(PERL6_OPERATORS), Operator),
+            (r'\w' + PERL6_IDENTIFIER_RANGE + '*', Name),
+            (r"'(\\\\|\\[^\\]|[^'\\])*'", String),
+            (r'"(\\\\|\\[^\\]|[^"\\])*"', String),
+        ],
+        'root': [
+            include('common'),
+            (r'\{', opening_brace_callback),
+            (r'\}', closing_brace_callback),
+            (r'.+?', Text),
+        ],
+        'pre-token': [
+            include('common'),
+            (r'\{', Text, ('#pop', 'token')),
+            (r'.+?', Text),
+        ],
+        'token-sym-brackets': [
+            (r'(?P(?P[' + ''.join(PERL6_BRACKETS) + '])(?P=first_char)*)',
+             brackets_callback(Name), ('#pop', 'pre-token')),
+            default(('#pop', 'pre-token')),
+        ],
+        'token': [
+            (r'\}', Text, '#pop'),
+            (r'(?<=:)(?:my|our|state|constant|temp|let).*?;', using(this)),
+            # make sure that quotes in character classes aren't treated as strings
+            (r'<(?:[-!?+.]\s*)?\[.*?\]>', String.Regex),
+            # make sure that '#' characters in quotes aren't treated as comments
+            (r"(?my|our)\s+)?(?:module|class|role|enum|grammar)', line)
+            if class_decl:
+                if saw_perl_decl or class_decl.group('scope') is not None:
+                    return True
+                rating = 0.05
+                continue
+            break
+
+        if ':=' in text:
+            # Same logic as above for PerlLexer
+            rating /= 2
+
+        return rating
+
+    def __init__(self, **options):
+        super().__init__(**options)
+        self.encoding = options.get('encoding', 'utf-8')
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/phix.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/phix.py
new file mode 100644
index 0000000000000000000000000000000000000000..c4cb35d5b13c96d4619a2801715117b788b47226
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/phix.py
@@ -0,0 +1,363 @@
+"""
+    pygments.lexers.phix
+    ~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for Phix.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, words
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Whitespace
+
+__all__ = ['PhixLexer']
+
+
+class PhixLexer(RegexLexer):
+    """
+    Pygments Lexer for Phix files (.exw).
+    See http://phix.x10.mx
+    """
+
+    name = 'Phix'
+    url = 'http://phix.x10.mx'
+    aliases = ['phix']
+    filenames = ['*.exw']
+    mimetypes = ['text/x-phix']
+    version_added = '2.14'
+
+    flags = re.MULTILINE    # nb: **NOT** re.DOTALL! (totally spanners comment handling)
+
+    preproc = (
+        'ifdef', 'elsifdef', 'elsedef'
+    )
+    # Note these lists are auto-generated by pwa/p2js.exw, when pwa\src\p2js_keywords.e (etc)
+    #     change, though of course subsequent copy/commit/pull requests are all manual steps.
+    types = (
+        'string', 'nullable_string', 'atom_string', 'atom', 'bool', 'boolean',
+        'cdCanvan', 'cdCanvas', 'complex', 'CURLcode', 'dictionary', 'int',
+        'integer', 'Ihandle', 'Ihandles', 'Ihandln', 'mpfr', 'mpq', 'mpz',
+        'mpz_or_string', 'number', 'rid_string', 'seq', 'sequence', 'timedate',
+        'object'
+    )
+    keywords = (
+        'abstract', 'class', 'continue', 'export', 'extends', 'nullable',
+        'private', 'public', 'static', 'struct', 'trace',
+        'and', 'break', 'by', 'case', 'catch', 'const', 'constant', 'debug',
+        'default', 'do', 'else', 'elsif', 'end', 'enum', 'exit', 'fallthru',
+        'fallthrough', 'for', 'forward', 'function', 'global', 'if', 'in',
+        'include', 'js', 'javascript', 'javascript_semantics', 'let', 'not',
+        'or', 'procedure', 'profile', 'profile_time', 'return', 'safe_mode',
+        'switch', 'then', 'to', 'try', 'type', 'type_check', 'until', 'warning',
+        'while', 'with', 'without', 'xor'
+    )
+    routines = (
+        'abort', 'abs', 'adjust_timedate', 'and_bits', 'and_bitsu', 'apply',
+        'append', 'arccos', 'arcsin', 'arctan', 'assert', 'atan2',
+        'atom_to_float32', 'atom_to_float64', 'bankers_rounding', 'beep',
+        'begins', 'binary_search', 'bits_to_int', 'bk_color', 'bytes_to_int',
+        'call_func', 'call_proc', 'cdCanvasActivate', 'cdCanvasArc',
+        'cdCanvasBegin', 'cdCanvasBox', 'cdCanvasChord', 'cdCanvasCircle',
+        'cdCanvasClear', 'cdCanvasEnd', 'cdCanvasFlush', 'cdCanvasFont',
+        'cdCanvasGetImageRGB', 'cdCanvasGetSize', 'cdCanvasGetTextAlignment',
+        'cdCanvasGetTextSize', 'cdCanvasLine', 'cdCanvasMark',
+        'cdCanvasMarkSize', 'cdCanvasMultiLineVectorText', 'cdCanvasPixel',
+        'cdCanvasRect', 'cdCanvasRoundedBox', 'cdCanvasRoundedRect',
+        'cdCanvasSector', 'cdCanvasSetAttribute', 'cdCanvasSetBackground',
+        'cdCanvasSetFillMode', 'cdCanvasSetForeground',
+        'cdCanvasSetInteriorStyle', 'cdCanvasSetLineStyle',
+        'cdCanvasSetLineWidth', 'cdCanvasSetTextAlignment', 'cdCanvasText',
+        'cdCanvasSetTextOrientation', 'cdCanvasGetTextOrientation',
+        'cdCanvasVectorText', 'cdCanvasVectorTextDirection',
+        'cdCanvasVectorTextSize', 'cdCanvasVertex', 'cdCreateCanvas',
+        'cdDecodeAlpha', 'cdDecodeColor', 'cdDecodeColorAlpha', 'cdEncodeAlpha',
+        'cdEncodeColor', 'cdEncodeColorAlpha', 'cdKillCanvas', 'cdVersion',
+        'cdVersionDate', 'ceil', 'change_timezone', 'choose', 'clear_screen',
+        'columnize', 'command_line', 'compare', 'complex_abs', 'complex_add',
+        'complex_arg', 'complex_conjugate', 'complex_cos', 'complex_cosh',
+        'complex_div', 'complex_exp', 'complex_imag', 'complex_inv',
+        'complex_log', 'complex_mul', 'complex_neg', 'complex_new',
+        'complex_norm', 'complex_power', 'complex_rho', 'complex_real',
+        'complex_round', 'complex_sin', 'complex_sinh', 'complex_sprint',
+        'complex_sqrt', 'complex_sub', 'complex_theta', 'concat', 'cos',
+        'crash', 'custom_sort', 'date', 'day_of_week', 'day_of_year',
+        'days_in_month', 'decode_base64', 'decode_flags', 'deep_copy', 'deld',
+        'deserialize', 'destroy_dict', 'destroy_queue', 'destroy_stack',
+        'dict_name', 'dict_size', 'elapsed', 'elapsed_short', 'encode_base64',
+        'equal', 'even', 'exp', 'extract', 'factorial', 'factors',
+        'file_size_k', 'find', 'find_all', 'find_any', 'find_replace', 'filter',
+        'flatten', 'float32_to_atom', 'float64_to_atom', 'floor',
+        'format_timedate', 'free_console', 'from_polar', 'gcd', 'get_file_base',
+        'get_file_extension', 'get_file_name', 'get_file_name_and_path',
+        'get_file_path', 'get_file_path_and_name', 'get_maxprime', 'get_prime',
+        'get_primes', 'get_primes_le', 'get_proper_dir', 'get_proper_path',
+        'get_rand', 'get_routine_info', 'get_test_abort', 'get_test_logfile',
+        'get_test_pause', 'get_test_verbosity', 'get_tzid', 'getd', 'getdd',
+        'getd_all_keys', 'getd_by_index', 'getd_index', 'getd_partial_key',
+        'glAttachShader', 'glBindBuffer', 'glBindTexture', 'glBufferData',
+        'glCanvasSpecialText', 'glClear', 'glClearColor', 'glColor',
+        'glCompileShader', 'glCreateBuffer', 'glCreateProgram',
+        'glCreateShader', 'glCreateTexture', 'glDeleteProgram',
+        'glDeleteShader', 'glDrawArrays', 'glEnable',
+        'glEnableVertexAttribArray', 'glFloat32Array', 'glInt32Array',
+        'glFlush', 'glGetAttribLocation', 'glGetError', 'glGetProgramInfoLog',
+        'glGetProgramParameter', 'glGetShaderInfoLog', 'glGetShaderParameter',
+        'glGetUniformLocation', 'glLinkProgram', 'glLoadIdentity',
+        'glMatrixMode', 'glOrtho', 'glRotatef', 'glShadeModel',
+        'glShaderSource', 'glSimpleA7texcoords', 'glTexImage2Dc',
+        'glTexParameteri', 'glTranslate', 'glUniform1f', 'glUniform1i',
+        'glUniformMatrix4fv', 'glUseProgram', 'glVertex',
+        'glVertexAttribPointer', 'glViewport', 'head', 'hsv_to_rgb', 'iff',
+        'iif', 'include_file', 'incl0de_file', 'insert', 'instance',
+        'int_to_bits', 'int_to_bytes', 'is_dict', 'is_integer', 's_leap_year',
+        'is_prime', 'is_prime2', 'islower', 'isupper', 'Icallback',
+        'iup_isdouble', 'iup_isprint', 'iup_XkeyBase', 'IupAppend', 'IupAlarm',
+        'IupBackgroundBox', 'IupButton', 'IupCalendar', 'IupCanvas',
+        'IupClipboard', 'IupClose', 'IupCloseOnEscape', 'IupControlsOpen',
+        'IupDatePick', 'IupDestroy', 'IupDialog', 'IupDrawArc', 'IupDrawBegin',
+        'IupDrawEnd', 'IupDrawGetSize', 'IupDrawGetTextSize', 'IupDrawLine',
+        'IupDrawRectangle', 'IupDrawText', 'IupExpander', 'IupFill',
+        'IupFlatLabel', 'IupFlatList', 'IupFlatTree', 'IupFlush', 'IupFrame',
+        'IupGetAttribute', 'IupGetAttributeId', 'IupGetAttributePtr',
+        'IupGetBrother', 'IupGetChild', 'IupGetChildCount', 'IupGetClassName',
+        'IupGetDialog', 'IupGetDialogChild', 'IupGetDouble', 'IupGetFocus',
+        'IupGetGlobal', 'IupGetGlobalInt', 'IupGetGlobalIntInt', 'IupGetInt',
+        'IupGetInt2', 'IupGetIntId', 'IupGetIntInt', 'IupGetParent',
+        'IupGLCanvas', 'IupGLCanvasOpen', 'IupGLMakeCurrent', 'IupGraph',
+        'IupHbox', 'IupHide', 'IupImage', 'IupImageRGBA', 'IupItem',
+        'iupKeyCodeToName', 'IupLabel', 'IupLink', 'IupList', 'IupMap',
+        'IupMenu', 'IupMenuItem', 'IupMessage', 'IupMessageDlg', 'IupMultiBox',
+        'IupMultiLine', 'IupNextField', 'IupNormaliser', 'IupOpen',
+        'IupPlayInput', 'IupPopup', 'IupPreviousField', 'IupProgressBar',
+        'IupRadio', 'IupRecordInput', 'IupRedraw', 'IupRefresh',
+        'IupRefreshChildren', 'IupSeparator', 'IupSetAttribute',
+        'IupSetAttributes', 'IupSetAttributeHandle', 'IupSetAttributeId',
+        'IupSetAttributePtr', 'IupSetCallback', 'IupSetCallbacks',
+        'IupSetDouble', 'IupSetFocus', 'IupSetGlobal', 'IupSetGlobalInt',
+        'IupSetGlobalFunction', 'IupSetHandle', 'IupSetInt',
+        'IupSetStrAttribute', 'IupSetStrGlobal', 'IupShow', 'IupShowXY',
+        'IupSplit', 'IupStoreAttribute', 'IupSubmenu', 'IupTable',
+        'IupTableClearSelected', 'IupTableClick_cb', 'IupTableGetSelected',
+        'IupTableResize_cb', 'IupTableSetData', 'IupTabs', 'IupText',
+        'IupTimer', 'IupToggle', 'IupTreeAddNodes', 'IupTreeView', 'IupUpdate',
+        'IupValuator', 'IupVbox', 'join', 'join_by', 'join_path', 'k_perm',
+        'largest', 'lcm', 'length', 'log', 'log10', 'log2', 'lower',
+        'm4_crossProduct', 'm4_inverse', 'm4_lookAt', 'm4_multiply',
+        'm4_normalize', 'm4_perspective', 'm4_subtractVectors', 'm4_xRotate',
+        'm4_yRotate', 'machine_bits', 'machine_word', 'match', 'match_all',
+        'match_replace', 'max', 'maxsq', 'min', 'minsq', 'mod', 'mpfr_add',
+        'mpfr_ceil', 'mpfr_cmp', 'mpfr_cmp_si', 'mpfr_const_pi', 'mpfr_div',
+        'mpfr_div_si', 'mpfr_div_z', 'mpfr_floor', 'mpfr_free', 'mpfr_get_d',
+        'mpfr_get_default_precision', 'mpfr_get_default_rounding_mode',
+        'mpfr_get_fixed', 'mpfr_get_precision', 'mpfr_get_si', 'mpfr_init',
+        'mpfr_inits', 'mpfr_init_set', 'mpfr_init_set_q', 'mpfr_init_set_z',
+        'mpfr_mul', 'mpfr_mul_si', 'mpfr_pow_si', 'mpfr_set', 'mpfr_set_d',
+        'mpfr_set_default_precision', 'mpfr_set_default_rounding_mode',
+        'mpfr_set_precision', 'mpfr_set_q', 'mpfr_set_si', 'mpfr_set_str',
+        'mpfr_set_z', 'mpfr_si_div', 'mpfr_si_sub', 'mpfr_sqrt', 'mpfr_sub',
+        'mpfr_sub_si', 'mpq_abs', 'mpq_add', 'mpq_add_si', 'mpq_canonicalize',
+        'mpq_cmp', 'mpq_cmp_si', 'mpq_div', 'mpq_div_2exp', 'mpq_free',
+        'mpq_get_den', 'mpq_get_num', 'mpq_get_str', 'mpq_init', 'mpq_init_set',
+        'mpq_init_set_si', 'mpq_init_set_str', 'mpq_init_set_z', 'mpq_inits',
+        'mpq_inv', 'mpq_mul', 'mpq_neg', 'mpq_set', 'mpq_set_si', 'mpq_set_str',
+        'mpq_set_z', 'mpq_sub', 'mpz_abs', 'mpz_add', 'mpz_addmul',
+        'mpz_addmul_ui', 'mpz_addmul_si', 'mpz_add_si', 'mpz_add_ui', 'mpz_and',
+        'mpz_bin_uiui', 'mpz_cdiv_q', 'mpz_cmp', 'mpz_cmp_si', 'mpz_divexact',
+        'mpz_divexact_ui', 'mpz_divisible_p', 'mpz_divisible_ui_p', 'mpz_even',
+        'mpz_fac_ui', 'mpz_factorstring', 'mpz_fdiv_q', 'mpz_fdiv_q_2exp',
+        'mpz_fdiv_q_ui', 'mpz_fdiv_qr', 'mpz_fdiv_r', 'mpz_fdiv_ui',
+        'mpz_fib_ui', 'mpz_fib2_ui', 'mpz_fits_atom', 'mpz_fits_integer',
+        'mpz_free', 'mpz_gcd', 'mpz_gcd_ui', 'mpz_get_atom', 'mpz_get_integer',
+        'mpz_get_short_str', 'mpz_get_str', 'mpz_init', 'mpz_init_set',
+        'mpz_inits', 'mpz_invert', 'mpz_lcm', 'mpz_lcm_ui', 'mpz_max',
+        'mpz_min', 'mpz_mod', 'mpz_mod_ui', 'mpz_mul', 'mpz_mul_2exp',
+        'mpz_mul_d', 'mpz_mul_si', 'mpz_neg', 'mpz_nthroot', 'mpz_odd',
+        'mpz_pollard_rho', 'mpz_pow_ui', 'mpz_powm', 'mpz_powm_ui', 'mpz_prime',
+        'mpz_prime_factors', 'mpz_prime_mr', 'mpz_rand', 'mpz_rand_ui',
+        'mpz_re_compose', 'mpz_remove', 'mpz_scan0', 'mpz_scan1', 'mpz_set',
+        'mpz_set_d', 'mpz_set_si', 'mpz_set_str', 'mpz_set_v', 'mpz_sign',
+        'mpz_sizeinbase', 'mpz_sqrt', 'mpz_sub', 'mpz_sub_si', 'mpz_sub_ui',
+        'mpz_si_sub', 'mpz_tdiv_q_2exp', 'mpz_tdiv_r_2exp', 'mpz_tstbit',
+        'mpz_ui_pow_ui', 'mpz_xor', 'named_dict', 'new_dict', 'new_queue',
+        'new_stack', 'not_bits', 'not_bitsu', 'odd', 'or_all', 'or_allu',
+        'or_bits', 'or_bitsu', 'ord', 'ordinal', 'ordinant',
+        'override_timezone', 'pad', 'pad_head', 'pad_tail', 'parse_date_string',
+        'papply', 'peep', 'peepn', 'peep_dict', 'permute', 'permutes',
+        'platform', 'pop', 'popn', 'pop_dict', 'power', 'pp', 'ppEx', 'ppExf',
+        'ppf', 'ppOpt', 'pq_add', 'pq_destroy', 'pq_empty', 'pq_new', 'pq_peek',
+        'pq_pop', 'pq_pop_data', 'pq_size', 'prepend', 'prime_factors',
+        'printf', 'product', 'proper', 'push', 'pushn', 'putd', 'puts',
+        'queue_empty', 'queue_size', 'rand', 'rand_range', 'reinstate',
+        'remainder', 'remove', 'remove_all', 'repeat', 'repeatch', 'replace',
+        'requires', 'reverse', 'rfind', 'rgb', 'rmatch', 'rmdr', 'rnd', 'round',
+        'routine_id', 'scanf', 'serialize', 'series', 'set_rand',
+        'set_test_abort', 'set_test_logfile', 'set_test_module',
+        'set_test_pause', 'set_test_verbosity', 'set_timedate_formats',
+        'set_timezone', 'setd', 'setd_default', 'shorten', 'sha256',
+        'shift_bits', 'shuffle', 'sign', 'sin', 'smallest', 'sort',
+        'sort_columns', 'speak', 'splice', 'split', 'split_any', 'split_by',
+        'sprint', 'sprintf', 'sq_abs', 'sq_add', 'sq_and', 'sq_and_bits',
+        'sq_arccos', 'sq_arcsin', 'sq_arctan', 'sq_atom', 'sq_ceil', 'sq_cmp',
+        'sq_cos', 'sq_div', 'sq_even', 'sq_eq', 'sq_floor', 'sq_floor_div',
+        'sq_ge', 'sq_gt', 'sq_int', 'sq_le', 'sq_log', 'sq_log10', 'sq_log2',
+        'sq_lt', 'sq_max', 'sq_min', 'sq_mod', 'sq_mul', 'sq_ne', 'sq_not',
+        'sq_not_bits', 'sq_odd', 'sq_or', 'sq_or_bits', 'sq_power', 'sq_rand',
+        'sq_remainder', 'sq_rmdr', 'sq_rnd', 'sq_round', 'sq_seq', 'sq_sign',
+        'sq_sin', 'sq_sqrt', 'sq_str', 'sq_sub', 'sq_tan', 'sq_trunc',
+        'sq_uminus', 'sq_xor', 'sq_xor_bits', 'sqrt', 'square_free',
+        'stack_empty', 'stack_size', 'substitute', 'substitute_all', 'sum',
+        'tail', 'tan', 'test_equal', 'test_fail', 'test_false',
+        'test_not_equal', 'test_pass', 'test_summary', 'test_true',
+        'text_color', 'throw', 'time', 'timedate_diff', 'timedelta',
+        'to_integer', 'to_number', 'to_rgb', 'to_string', 'traverse_dict',
+        'traverse_dict_partial_key', 'trim', 'trim_head', 'trim_tail', 'trunc',
+        'tagset', 'tagstart', 'typeof', 'unique', 'unix_dict', 'upper',
+        'utf8_to_utf32', 'utf32_to_utf8', 'version', 'vlookup', 'vslice',
+        'wglGetProcAddress', 'wildcard_file', 'wildcard_match', 'with_rho',
+        'with_theta', 'xml_new_doc', 'xml_new_element', 'xml_set_attribute',
+        'xml_sprint', 'xor_bits', 'xor_bitsu',
+        'accept', 'allocate', 'allocate_string', 'allow_break', 'ARM',
+        'atom_to_float80', 'c_func', 'c_proc', 'call_back', 'chdir',
+        'check_break', 'clearDib', 'close', 'closesocket', 'console',
+        'copy_file', 'create', 'create_directory', 'create_thread',
+        'curl_easy_cleanup', 'curl_easy_get_file', 'curl_easy_init',
+        'curl_easy_perform', 'curl_easy_perform_ex', 'curl_easy_setopt',
+        'curl_easy_strerror', 'curl_global_cleanup', 'curl_global_init',
+        'curl_slist_append', 'curl_slist_free_all', 'current_dir', 'cursor',
+        'define_c_func', 'define_c_proc', 'delete', 'delete_cs', 'delete_file',
+        'dir', 'DLL', 'drawDib', 'drawShadedPolygonToDib', 'ELF32', 'ELF64',
+        'enter_cs', 'eval', 'exit_thread', 'free', 'file_exists', 'final',
+        'float80_to_atom', 'format', 'get_bytes', 'get_file_date',
+        'get_file_size', 'get_file_type', 'get_interpreter', 'get_key',
+        'get_socket_error', 'get_text', 'get_thread_exitcode', 'get_thread_id',
+        'getc', 'getenv', 'gets', 'getsockaddr', 'glBegin', 'glCallList',
+        'glFrustum', 'glGenLists', 'glGetString', 'glLight', 'glMaterial',
+        'glNewList', 'glNormal', 'glPopMatrix', 'glPushMatrix', 'glRotate',
+        'glEnd', 'glEndList', 'glTexImage2D', 'goto', 'GUI', 'icons', 'ilASM',
+        'include_files', 'include_paths', 'init_cs', 'ip_to_string',
+        'IupConfig', 'IupConfigDialogClosed', 'IupConfigDialogShow',
+        'IupConfigGetVariableInt', 'IupConfigLoad', 'IupConfigSave',
+        'IupConfigSetVariableInt', 'IupExitLoop', 'IupFileDlg', 'IupFileList',
+        'IupGLSwapBuffers', 'IupHelp', 'IupLoopStep', 'IupMainLoop',
+        'IupNormalizer', 'IupPlot', 'IupPlotAdd', 'IupPlotBegin', 'IupPlotEnd',
+        'IupPlotInsert', 'IupSaveImage', 'IupTreeGetUserId', 'IupUser',
+        'IupVersion', 'IupVersionDate', 'IupVersionNumber', 'IupVersionShow',
+        'killDib', 'leave_cs', 'listen', 'manifest', 'mem_copy', 'mem_set',
+        'mpfr_gamma', 'mpfr_printf', 'mpfr_sprintf', 'mpz_export', 'mpz_import',
+        'namespace', 'new', 'newDib', 'open', 'open_dll', 'PE32', 'PE64',
+        'peek', 'peek_string', 'peek1s', 'peek1u', 'peek2s', 'peek2u', 'peek4s',
+        'peek4u', 'peek8s', 'peek8u', 'peekNS', 'peekns', 'peeknu', 'poke',
+        'poke2', 'poke4', 'poke8', 'pokeN', 'poke_string', 'poke_wstring',
+        'position', 'progress', 'prompt_number', 'prompt_string', 'read_file',
+        'read_lines', 'recv', 'resume_thread', 'seek', 'select', 'send',
+        'setHandler', 'shutdown', 'sleep', 'SO', 'sockaddr_in', 'socket',
+        'split_path', 'suspend_thread', 'system', 'system_exec', 'system_open',
+        'system_wait', 'task_clock_start', 'task_clock_stop', 'task_create',
+        'task_delay', 'task_list', 'task_schedule', 'task_self', 'task_status',
+        'task_suspend', 'task_yield', 'thread_safe_string', 'try_cs',
+        'utf8_to_utf16', 'utf16_to_utf8', 'utf16_to_utf32', 'utf32_to_utf16',
+        'video_config', 'WSACleanup', 'wait_thread', 'walk_dir', 'where',
+        'write_lines', 'wait_key'
+    )
+    constants = (
+        'ANY_QUEUE', 'ASCENDING', 'BLACK', 'BLOCK_CURSOR', 'BLUE',
+        'BRIGHT_CYAN', 'BRIGHT_BLUE', 'BRIGHT_GREEN', 'BRIGHT_MAGENTA',
+        'BRIGHT_RED', 'BRIGHT_WHITE', 'BROWN', 'C_DWORD', 'C_INT', 'C_POINTER',
+        'C_USHORT', 'C_WORD', 'CD_AMBER', 'CD_BLACK', 'CD_BLUE', 'CD_BOLD',
+        'CD_BOLD_ITALIC', 'CD_BOX', 'CD_CENTER', 'CD_CIRCLE', 'CD_CLOSED_LINES',
+        'CD_CONTINUOUS', 'CD_CUSTOM', 'CD_CYAN', 'CD_DARK_BLUE', 'CD_DARK_CYAN',
+        'CD_DARK_GRAY', 'CD_DARK_GREY', 'CD_DARK_GREEN', 'CD_DARK_MAGENTA',
+        'CD_DARK_RED', 'CD_DARK_YELLOW', 'CD_DASH_DOT', 'CD_DASH_DOT_DOT',
+        'CD_DASHED', 'CD_DBUFFER', 'CD_DEG2RAD', 'CD_DIAMOND', 'CD_DOTTED',
+        'CD_EAST', 'CD_EVENODD', 'CD_FILL', 'CD_GL', 'CD_GRAY', 'CD_GREY',
+        'CD_GREEN', 'CD_HATCH', 'CD_HOLLOW', 'CD_HOLLOW_BOX',
+        'CD_HOLLOW_CIRCLE', 'CD_HOLLOW_DIAMOND', 'CD_INDIGO', 'CD_ITALIC',
+        'CD_IUP', 'CD_IUPDBUFFER', 'CD_LIGHT_BLUE', 'CD_LIGHT_GRAY',
+        'CD_LIGHT_GREY', 'CD_LIGHT_GREEN', 'CD_LIGHT_PARCHMENT', 'CD_MAGENTA',
+        'CD_NAVY', 'CD_NORTH', 'CD_NORTH_EAST', 'CD_NORTH_WEST', 'CD_OLIVE',
+        'CD_OPEN_LINES', 'CD_ORANGE', 'CD_PARCHMENT', 'CD_PATTERN',
+        'CD_PRINTER', 'CD_PURPLE', 'CD_PLAIN', 'CD_PLUS', 'CD_QUERY',
+        'CD_RAD2DEG', 'CD_RED', 'CD_SILVER', 'CD_SOLID', 'CD_SOUTH_EAST',
+        'CD_SOUTH_WEST', 'CD_STAR', 'CD_STIPPLE', 'CD_STRIKEOUT',
+        'CD_UNDERLINE', 'CD_WEST', 'CD_WHITE', 'CD_WINDING', 'CD_VIOLET',
+        'CD_X', 'CD_YELLOW', 'CURLE_OK', 'CURLOPT_MAIL_FROM',
+        'CURLOPT_MAIL_RCPT', 'CURLOPT_PASSWORD', 'CURLOPT_READDATA',
+        'CURLOPT_READFUNCTION', 'CURLOPT_SSL_VERIFYPEER',
+        'CURLOPT_SSL_VERIFYHOST', 'CURLOPT_UPLOAD', 'CURLOPT_URL',
+        'CURLOPT_USE_SSL', 'CURLOPT_USERNAME', 'CURLOPT_VERBOSE',
+        'CURLOPT_WRITEFUNCTION', 'CURLUSESSL_ALL', 'CYAN', 'D_NAME',
+        'D_ATTRIBUTES', 'D_SIZE', 'D_YEAR', 'D_MONTH', 'D_DAY', 'D_HOUR',
+        'D_MINUTE', 'D_SECOND', 'D_CREATION', 'D_LASTACCESS', 'D_MODIFICATION',
+        'DT_YEAR', 'DT_MONTH', 'DT_DAY', 'DT_HOUR', 'DT_MINUTE', 'DT_SECOND',
+        'DT_DOW', 'DT_MSEC', 'DT_DOY', 'DT_GMT', 'EULER', 'E_CODE', 'E_ADDR',
+        'E_LINE', 'E_RTN', 'E_NAME', 'E_FILE', 'E_PATH', 'E_USER', 'false',
+        'False', 'FALSE', 'FIFO_QUEUE', 'FILETYPE_DIRECTORY', 'FILETYPE_FILE',
+        'GET_EOF', 'GET_FAIL', 'GET_IGNORE', 'GET_SUCCESS',
+        'GL_AMBIENT_AND_DIFFUSE', 'GL_ARRAY_BUFFER', 'GL_CLAMP',
+        'GL_CLAMP_TO_BORDER', 'GL_CLAMP_TO_EDGE', 'GL_COLOR_BUFFER_BIT',
+        'GL_COMPILE', 'GL_COMPILE_STATUS', 'GL_CULL_FACE',
+        'GL_DEPTH_BUFFER_BIT', 'GL_DEPTH_TEST', 'GL_EXTENSIONS', 'GL_FLAT',
+        'GL_FLOAT', 'GL_FRAGMENT_SHADER', 'GL_FRONT', 'GL_LIGHT0',
+        'GL_LIGHTING', 'GL_LINEAR', 'GL_LINK_STATUS', 'GL_MODELVIEW',
+        'GL_NEAREST', 'GL_NO_ERROR', 'GL_NORMALIZE', 'GL_POSITION',
+        'GL_PROJECTION', 'GL_QUAD_STRIP', 'GL_QUADS', 'GL_RENDERER',
+        'GL_REPEAT', 'GL_RGB', 'GL_RGBA', 'GL_SMOOTH', 'GL_STATIC_DRAW',
+        'GL_TEXTURE_2D', 'GL_TEXTURE_MAG_FILTER', 'GL_TEXTURE_MIN_FILTER',
+        'GL_TEXTURE_WRAP_S', 'GL_TEXTURE_WRAP_T', 'GL_TRIANGLES',
+        'GL_UNSIGNED_BYTE', 'GL_VENDOR', 'GL_VERSION', 'GL_VERTEX_SHADER',
+        'GRAY', 'GREEN', 'GT_LF_STRIPPED', 'GT_WHOLE_FILE', 'INVLN10',
+        'IUP_CLOSE', 'IUP_CONTINUE', 'IUP_DEFAULT', 'IUP_BLACK', 'IUP_BLUE',
+        'IUP_BUTTON1', 'IUP_BUTTON3', 'IUP_CENTER', 'IUP_CYAN', 'IUP_DARK_BLUE',
+        'IUP_DARK_CYAN', 'IUP_DARK_GRAY', 'IUP_DARK_GREY', 'IUP_DARK_GREEN',
+        'IUP_DARK_MAGENTA', 'IUP_DARK_RED', 'IUP_GRAY', 'IUP_GREY', 'IUP_GREEN',
+        'IUP_IGNORE', 'IUP_INDIGO', 'IUP_MAGENTA', 'IUP_MASK_INT',
+        'IUP_MASK_UINT', 'IUP_MOUSEPOS', 'IUP_NAVY', 'IUP_OLIVE', 'IUP_RECTEXT',
+        'IUP_RED', 'IUP_LIGHT_BLUE', 'IUP_LIGHT_GRAY', 'IUP_LIGHT_GREY',
+        'IUP_LIGHT_GREEN', 'IUP_ORANGE', 'IUP_PARCHMENT', 'IUP_PURPLE',
+        'IUP_SILVER', 'IUP_TEAL', 'IUP_VIOLET', 'IUP_WHITE', 'IUP_YELLOW',
+        'K_BS', 'K_cA', 'K_cC', 'K_cD', 'K_cF5', 'K_cK', 'K_cM', 'K_cN', 'K_cO',
+        'K_cP', 'K_cR', 'K_cS', 'K_cT', 'K_cW', 'K_CR', 'K_DEL', 'K_DOWN',
+        'K_END', 'K_ESC', 'K_F1', 'K_F2', 'K_F3', 'K_F4', 'K_F5', 'K_F6',
+        'K_F7', 'K_F8', 'K_F9', 'K_F10', 'K_F11', 'K_F12', 'K_HOME', 'K_INS',
+        'K_LEFT', 'K_MIDDLE', 'K_PGDN', 'K_PGUP', 'K_RIGHT', 'K_SP', 'K_TAB',
+        'K_UP', 'K_h', 'K_i', 'K_j', 'K_p', 'K_r', 'K_s', 'JS', 'LIFO_QUEUE',
+        'LINUX', 'MAX_HEAP', 'MAGENTA', 'MIN_HEAP', 'Nan', 'NO_CURSOR', 'null',
+        'NULL', 'PI', 'pp_Ascii', 'pp_Brkt', 'pp_Date', 'pp_File', 'pp_FltFmt',
+        'pp_Indent', 'pp_IntCh', 'pp_IntFmt', 'pp_Maxlen', 'pp_Nest',
+        'pp_Pause', 'pp_Q22', 'pp_StrFmt', 'RED', 'SEEK_OK', 'SLASH',
+        'TEST_ABORT', 'TEST_CRASH', 'TEST_PAUSE', 'TEST_PAUSE_FAIL',
+        'TEST_QUIET', 'TEST_SHOW_ALL', 'TEST_SHOW_FAILED', 'TEST_SUMMARY',
+        'true', 'True', 'TRUE', 'VC_SCRNLINES', 'WHITE', 'WINDOWS', 'YELLOW'
+    )
+
+    tokens = {
+        'root': [
+            (r"\s+", Whitespace),
+            (r'/\*|--/\*|#\[', Comment.Multiline, 'comment'),
+            (r'(?://|--|#!).*$', Comment.Single),
+#Alt:
+#           (r'//.*$|--.*$|#!.*$', Comment.Single),
+            (r'"([^"\\]|\\.)*"', String.Other),
+            (r'\'[^\']*\'', String.Other),
+            (r'`[^`]*`', String.Other),
+
+            (words(types, prefix=r'\b', suffix=r'\b'), Name.Function),
+            (words(routines, prefix=r'\b', suffix=r'\b'), Name.Function),
+            (words(preproc, prefix=r'\b', suffix=r'\b'), Keyword.Declaration),
+            (words(keywords, prefix=r'\b', suffix=r'\b'), Keyword.Declaration),
+            (words(constants, prefix=r'\b', suffix=r'\b'), Name.Constant),
+            # Aside: Phix only supports/uses the ascii/non-unicode tilde
+            (r'!=|==|<<|>>|:=|[-~+/*%=<>&^|\.(){},?:\[\]$\\;#]', Operator),
+            (r'[\w-]+', Text)
+        ],
+        'comment': [
+            (r'[^*/#]+', Comment.Multiline),
+            (r'/\*|#\[', Comment.Multiline, '#push'),
+            (r'\*/|#\]', Comment.Multiline, '#pop'),
+            (r'[*/#]', Comment.Multiline)
+        ]
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/php.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/php.py
new file mode 100644
index 0000000000000000000000000000000000000000..ac935c4717498a7c2c3acb40156f80c2fc69d901
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/php.py
@@ -0,0 +1,335 @@
+"""
+    pygments.lexers.php
+    ~~~~~~~~~~~~~~~~~~~
+
+    Lexers for PHP and related languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import Lexer, RegexLexer, include, bygroups, default, \
+    using, this, words, do_insertions, line_re
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation, Other, Generic
+from pygments.util import get_bool_opt, get_list_opt, shebang_matches
+
+__all__ = ['ZephirLexer', 'PsyshConsoleLexer', 'PhpLexer']
+
+
+class ZephirLexer(RegexLexer):
+    """
+    For Zephir language source code.
+
+    Zephir is a compiled high level language aimed
+    to the creation of C-extensions for PHP.
+    """
+
+    name = 'Zephir'
+    url = 'http://zephir-lang.com/'
+    aliases = ['zephir']
+    filenames = ['*.zep']
+    version_added = '2.0'
+
+    zephir_keywords = ['fetch', 'echo', 'isset', 'empty']
+    zephir_type = ['bit', 'bits', 'string']
+
+    flags = re.DOTALL | re.MULTILINE
+
+    tokens = {
+        'commentsandwhitespace': [
+            (r'\s+', Text),
+            (r'//.*?\n', Comment.Single),
+            (r'/\*.*?\*/', Comment.Multiline)
+        ],
+        'slashstartsregex': [
+            include('commentsandwhitespace'),
+            (r'/(\\.|[^[/\\\n]|\[(\\.|[^\]\\\n])*])+/'
+             r'([gim]+\b|\B)', String.Regex, '#pop'),
+            (r'/', Operator, '#pop'),
+            default('#pop')
+        ],
+        'badregex': [
+            (r'\n', Text, '#pop')
+        ],
+        'root': [
+            (r'^(?=\s|/)', Text, 'slashstartsregex'),
+            include('commentsandwhitespace'),
+            (r'\+\+|--|~|&&|\?|:|\|\||\\(?=\n)|'
+             r'(<<|>>>?|==?|!=?|->|[-<>+*%&|^/])=?', Operator, 'slashstartsregex'),
+            (r'[{(\[;,]', Punctuation, 'slashstartsregex'),
+            (r'[})\].]', Punctuation),
+            (r'(for|in|while|do|break|return|continue|switch|case|default|if|else|loop|'
+             r'require|inline|throw|try|catch|finally|new|delete|typeof|instanceof|void|'
+             r'namespace|use|extends|this|fetch|isset|unset|echo|fetch|likely|unlikely|'
+             r'empty)\b', Keyword, 'slashstartsregex'),
+            (r'(var|let|with|function)\b', Keyword.Declaration, 'slashstartsregex'),
+            (r'(abstract|boolean|bool|char|class|const|double|enum|export|extends|final|'
+             r'native|goto|implements|import|int|string|interface|long|ulong|char|uchar|'
+             r'float|unsigned|private|protected|public|short|static|self|throws|reverse|'
+             r'transient|volatile|readonly)\b', Keyword.Reserved),
+            (r'(true|false|null|undefined)\b', Keyword.Constant),
+            (r'(Array|Boolean|Date|_REQUEST|_COOKIE|_SESSION|'
+             r'_GET|_POST|_SERVER|this|stdClass|range|count|iterator|'
+             r'window)\b', Name.Builtin),
+            (r'[$a-zA-Z_][\w\\]*', Name.Other),
+            (r'[0-9][0-9]*\.[0-9]+([eE][0-9]+)?[fd]?', Number.Float),
+            (r'0x[0-9a-fA-F]+', Number.Hex),
+            (r'[0-9]+', Number.Integer),
+            (r'"(\\\\|\\[^\\]|[^"\\])*"', String.Double),
+            (r"'(\\\\|\\[^\\]|[^'\\])*'", String.Single),
+        ]
+    }
+
+
+class PsyshConsoleLexer(Lexer):
+    """
+    For PsySH console output, such as:
+
+    .. sourcecode:: psysh
+
+        >>> $greeting = function($name): string {
+        ...     return "Hello, {$name}";
+        ... };
+        => Closure($name): string {#2371 …3}
+        >>> $greeting('World')
+        => "Hello, World"
+    """
+    name = 'PsySH console session for PHP'
+    url = 'https://psysh.org/'
+    aliases = ['psysh']
+    version_added = '2.7'
+
+    def __init__(self, **options):
+        options['startinline'] = True
+        Lexer.__init__(self, **options)
+
+    def get_tokens_unprocessed(self, text):
+        phplexer = PhpLexer(**self.options)
+        curcode = ''
+        insertions = []
+        for match in line_re.finditer(text):
+            line = match.group()
+            if line.startswith('>>> ') or line.startswith('... '):
+                insertions.append((len(curcode),
+                                   [(0, Generic.Prompt, line[:4])]))
+                curcode += line[4:]
+            elif line.rstrip() == '...':
+                insertions.append((len(curcode),
+                                   [(0, Generic.Prompt, '...')]))
+                curcode += line[3:]
+            else:
+                if curcode:
+                    yield from do_insertions(
+                        insertions, phplexer.get_tokens_unprocessed(curcode))
+                    curcode = ''
+                    insertions = []
+                yield match.start(), Generic.Output, line
+        if curcode:
+            yield from do_insertions(insertions,
+                                     phplexer.get_tokens_unprocessed(curcode))
+
+
+class PhpLexer(RegexLexer):
+    """
+    For PHP source code.
+    For PHP embedded in HTML, use the `HtmlPhpLexer`.
+
+    Additional options accepted:
+
+    `startinline`
+        If given and ``True`` the lexer starts highlighting with
+        php code (i.e.: no starting ``>> from pygments.lexers._php_builtins import MODULES
+            >>> MODULES.keys()
+            ['PHP Options/Info', 'Zip', 'dba', ...]
+
+        In fact the names of those modules match the module names from
+        the php documentation.
+    """
+
+    name = 'PHP'
+    url = 'https://www.php.net/'
+    aliases = ['php', 'php3', 'php4', 'php5']
+    filenames = ['*.php', '*.php[345]', '*.inc']
+    mimetypes = ['text/x-php']
+    version_added = ''
+
+    # Note that a backslash is included, PHP uses a backslash as a namespace
+    # separator.
+    _ident_inner = r'(?:[\\_a-z]|[^\x00-\x7f])(?:[\\\w]|[^\x00-\x7f])*'
+    # But not inside strings.
+    _ident_nons = r'(?:[_a-z]|[^\x00-\x7f])(?:\w|[^\x00-\x7f])*'
+
+    flags = re.IGNORECASE | re.DOTALL | re.MULTILINE
+    tokens = {
+        'root': [
+            (r'<\?(php)?', Comment.Preproc, 'php'),
+            (r'[^<]+', Other),
+            (r'<', Other)
+        ],
+        'php': [
+            (r'\?>', Comment.Preproc, '#pop'),
+            (r'(<<<)([\'"]?)(' + _ident_nons + r')(\2\n.*?\n\s*)(\3)(;?)(\n)',
+             bygroups(String, String, String.Delimiter, String, String.Delimiter,
+                      Punctuation, Text)),
+            (r'\s+', Text),
+            (r'#\[', Punctuation, 'attribute'),
+            (r'#.*?\n', Comment.Single),
+            (r'//.*?\n', Comment.Single),
+            # put the empty comment here, it is otherwise seen as
+            # the start of a docstring
+            (r'/\*\*/', Comment.Multiline),
+            (r'/\*\*.*?\*/', String.Doc),
+            (r'/\*.*?\*/', Comment.Multiline),
+            (r'(->|::)(\s*)(' + _ident_nons + ')',
+             bygroups(Operator, Text, Name.Attribute)),
+            (r'[~!%^&*+=|:.<>/@-]+', Operator),
+            (r'\?', Operator),  # don't add to the charclass above!
+            (r'[\[\]{}();,]+', Punctuation),
+            (r'(new)(\s+)(class)\b', bygroups(Keyword, Text, Keyword)),
+            (r'(class)(\s+)', bygroups(Keyword, Text), 'classname'),
+            (r'(function)(\s*)(?=\()', bygroups(Keyword, Text)),
+            (r'(function)(\s+)(&?)(\s*)',
+             bygroups(Keyword, Text, Operator, Text), 'functionname'),
+            (r'(const)(\s+)(' + _ident_inner + ')',
+             bygroups(Keyword, Text, Name.Constant)),
+            # source: https://www.php.net/manual/en/reserved.keywords.php
+            (r'(and|E_PARSE|old_function|E_ERROR|or|as|E_WARNING|parent|'
+             r'eval|PHP_OS|break|exit|case|extends|PHP_VERSION|cfunction|'
+             r'FALSE|print|for|require|continue|foreach|require_once|'
+             r'declare|return|default|static|do|switch|die|stdClass|'
+             r'echo|else|TRUE|elseif|var|empty|if|xor|enddeclare|include|'
+             r'virtual|endfor|include_once|while|endforeach|global|'
+             r'endif|list|endswitch|new|endwhile|not|'
+             r'array|E_ALL|NULL|final|php_user_filter|interface|'
+             r'implements|public|private|protected|abstract|clone|try|'
+             r'catch|throw|this|use|namespace|trait|yield( from)?|'
+             r'finally|match|readonly)\b', Keyword),
+            (r'(true|false|null)\b', Keyword.Constant),
+            include('magicconstants'),
+            (r'\$\{', Name.Variable, 'variablevariable'),
+            (r'\$+' + _ident_inner, Name.Variable),
+            (_ident_inner, Name.Other),
+            (r'(\d+\.\d*|\d*\.\d+)(e[+-]?[0-9]+)?', Number.Float),
+            (r'\d+e[+-]?[0-9]+', Number.Float),
+            (r'0[0-7]+', Number.Oct),
+            (r'0x[a-f0-9]+', Number.Hex),
+            (r'\d+', Number.Integer),
+            (r'0b[01]+', Number.Bin),
+            (r"'([^'\\]*(?:\\.[^'\\]*)*)'", String.Single),
+            (r'`([^`\\]*(?:\\.[^`\\]*)*)`', String.Backtick),
+            (r'"', String.Double, 'string'),
+        ],
+        'variablevariable': [
+            (r'\}', Name.Variable, '#pop'),
+            include('php')
+        ],
+        'magicfuncs': [
+            # source: http://php.net/manual/en/language.oop5.magic.php
+            (words((
+                '__construct', '__destruct', '__call', '__callStatic', '__get', '__set',
+                '__isset', '__unset', '__sleep', '__wakeup', '__toString', '__invoke',
+                '__set_state', '__clone', '__debugInfo',), suffix=r'\b'),
+             Name.Function.Magic),
+        ],
+        'magicconstants': [
+            # source: https://www.php.net/manual/en/language.constants.magic.php
+            (words((
+                '__LINE__', '__FILE__', '__DIR__', '__FUNCTION__', '__CLASS__',
+                '__TRAIT__', '__METHOD__', '__NAMESPACE__', '__PROPERTY__',),
+                suffix=r'\b'),
+             Name.Constant),
+        ],
+        'classname': [
+            (_ident_inner, Name.Class, '#pop')
+        ],
+        'functionname': [
+            include('magicfuncs'),
+            (_ident_inner, Name.Function, '#pop'),
+            default('#pop')
+        ],
+        'string': [
+            (r'"', String.Double, '#pop'),
+            (r'[^{$"\\]+', String.Double),
+            (r'\\([nrt"$\\]|[0-7]{1,3}|x[0-9a-f]{1,2})', String.Escape),
+            (r'\$' + _ident_nons + r'(\[\S+?\]|->' + _ident_nons + ')?',
+             String.Interpol),
+            (r'(\{\$\{)(.*?)(\}\})',
+             bygroups(String.Interpol, using(this, _startinline=True),
+                      String.Interpol)),
+            (r'(\{)(\$.*?)(\})',
+             bygroups(String.Interpol, using(this, _startinline=True),
+                      String.Interpol)),
+            (r'(\$\{)(\S+)(\})',
+             bygroups(String.Interpol, Name.Variable, String.Interpol)),
+            (r'[${\\]', String.Double)
+        ],
+        'attribute': [
+            (r'\]', Punctuation, '#pop'),
+            (r'\(', Punctuation, 'attributeparams'),
+            (_ident_inner, Name.Decorator),
+            include('php')
+        ],
+        'attributeparams': [
+            (r'\)', Punctuation, '#pop'),
+            include('php')
+        ],
+    }
+
+    def __init__(self, **options):
+        self.funcnamehighlighting = get_bool_opt(
+            options, 'funcnamehighlighting', True)
+        self.disabledmodules = get_list_opt(
+            options, 'disabledmodules', ['unknown'])
+        self.startinline = get_bool_opt(options, 'startinline', False)
+
+        # private option argument for the lexer itself
+        if '_startinline' in options:
+            self.startinline = options.pop('_startinline')
+
+        # collect activated functions in a set
+        self._functions = set()
+        if self.funcnamehighlighting:
+            from pygments.lexers._php_builtins import MODULES
+            for key, value in MODULES.items():
+                if key not in self.disabledmodules:
+                    self._functions.update(value)
+        RegexLexer.__init__(self, **options)
+
+    def get_tokens_unprocessed(self, text):
+        stack = ['root']
+        if self.startinline:
+            stack.append('php')
+        for index, token, value in \
+                RegexLexer.get_tokens_unprocessed(self, text, stack):
+            if token is Name.Other:
+                if value in self._functions:
+                    yield index, Name.Builtin, value
+                    continue
+            yield index, token, value
+
+    def analyse_text(text):
+        if shebang_matches(text, r'php'):
+            return True
+        rv = 0.0
+        if re.search(r'<\?(?!xml)', text):
+            rv += 0.3
+        return rv
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/pointless.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/pointless.py
new file mode 100644
index 0000000000000000000000000000000000000000..aab0a5684fe7b6c7c37372fefbf48630d2c96d4f
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/pointless.py
@@ -0,0 +1,70 @@
+"""
+    pygments.lexers.pointless
+    ~~~~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for Pointless.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, words
+from pygments.token import Comment, Error, Keyword, Name, Number, Operator, \
+    Punctuation, String, Text
+
+__all__ = ['PointlessLexer']
+
+
+class PointlessLexer(RegexLexer):
+    """
+    For Pointless source code.
+    """
+
+    name = 'Pointless'
+    url = 'https://ptls.dev'
+    aliases = ['pointless']
+    filenames = ['*.ptls']
+    version_added = '2.7'
+
+    ops = words([
+        "+", "-", "*", "/", "**", "%", "+=", "-=", "*=",
+        "/=", "**=", "%=", "|>", "=", "==", "!=", "<", ">",
+        "<=", ">=", "=>", "$", "++",
+    ])
+
+    keywords = words([
+        "if", "then", "else", "where", "with", "cond",
+        "case", "and", "or", "not", "in", "as", "for",
+        "requires", "throw", "try", "catch", "when",
+        "yield", "upval",
+    ], suffix=r'\b')
+
+    tokens = {
+        'root': [
+            (r'[ \n\r]+', Text),
+            (r'--.*$', Comment.Single),
+            (r'"""', String, 'multiString'),
+            (r'"', String, 'string'),
+            (r'[\[\](){}:;,.]', Punctuation),
+            (ops, Operator),
+            (keywords, Keyword),
+            (r'\d+|\d*\.\d+', Number),
+            (r'(true|false)\b', Name.Builtin),
+            (r'[A-Z][a-zA-Z0-9]*\b', String.Symbol),
+            (r'output\b', Name.Variable.Magic),
+            (r'(export|import)\b', Keyword.Namespace),
+            (r'[a-z][a-zA-Z0-9]*\b', Name.Variable)
+        ],
+        'multiString': [
+            (r'\\.', String.Escape),
+            (r'"""', String, '#pop'),
+            (r'"', String),
+            (r'[^\\"]+', String),
+        ],
+        'string': [
+            (r'\\.', String.Escape),
+            (r'"', String, '#pop'),
+            (r'\n', Error),
+            (r'[^\\"]+', String),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/pony.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/pony.py
new file mode 100644
index 0000000000000000000000000000000000000000..62d16d7d651b3395c761ecef98fe3f43d59ca33d
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/pony.py
@@ -0,0 +1,93 @@
+"""
+    pygments.lexers.pony
+    ~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for Pony and related languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, bygroups, words
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation
+
+__all__ = ['PonyLexer']
+
+
+class PonyLexer(RegexLexer):
+    """
+    For Pony source code.
+    """
+
+    name = 'Pony'
+    aliases = ['pony']
+    filenames = ['*.pony']
+    url = 'https://www.ponylang.io'
+    version_added = '2.4'
+
+    _caps = r'(iso|trn|ref|val|box|tag)'
+
+    tokens = {
+        'root': [
+            (r'\n', Text),
+            (r'[^\S\n]+', Text),
+            (r'//.*\n', Comment.Single),
+            (r'/\*', Comment.Multiline, 'nested_comment'),
+            (r'"""(?:.|\n)*?"""', String.Doc),
+            (r'"', String, 'string'),
+            (r'\'.*\'', String.Char),
+            (r'=>|[]{}:().~;,|&!^?[]', Punctuation),
+            (words((
+                'addressof', 'and', 'as', 'consume', 'digestof', 'is', 'isnt',
+                'not', 'or'),
+                suffix=r'\b'),
+             Operator.Word),
+            (r'!=|==|<<|>>|[-+/*%=<>]', Operator),
+            (words((
+                'box', 'break', 'compile_error', 'compile_intrinsic',
+                'continue', 'do', 'else', 'elseif', 'embed', 'end', 'error',
+                'for', 'if', 'ifdef', 'in', 'iso', 'lambda', 'let', 'match',
+                'object', 'recover', 'ref', 'repeat', 'return', 'tag', 'then',
+                'this', 'trn', 'try', 'until', 'use', 'var', 'val', 'where',
+                'while', 'with', '#any', '#read', '#send', '#share'),
+                suffix=r'\b'),
+             Keyword),
+            (r'(actor|class|struct|primitive|interface|trait|type)((?:\s)+)',
+             bygroups(Keyword, Text), 'typename'),
+            (r'(new|fun|be)((?:\s)+)', bygroups(Keyword, Text), 'methodname'),
+            (words((
+                'I8', 'U8', 'I16', 'U16', 'I32', 'U32', 'I64', 'U64', 'I128',
+                'U128', 'ILong', 'ULong', 'ISize', 'USize', 'F32', 'F64',
+                'Bool', 'Pointer', 'None', 'Any', 'Array', 'String',
+                'Iterator'),
+                suffix=r'\b'),
+             Name.Builtin.Type),
+            (r'_?[A-Z]\w*', Name.Type),
+            (r'(\d+\.\d*|\.\d+|\d+)[eE][+-]?\d+', Number.Float),
+            (r'0x[0-9a-fA-F]+', Number.Hex),
+            (r'\d+', Number.Integer),
+            (r'(true|false)\b', Name.Builtin),
+            (r'_\d*', Name),
+            (r'_?[a-z][\w\']*', Name)
+        ],
+        'typename': [
+            (_caps + r'?((?:\s)*)(_?[A-Z]\w*)',
+             bygroups(Keyword, Text, Name.Class), '#pop')
+        ],
+        'methodname': [
+            (_caps + r'?((?:\s)*)(_?[a-z]\w*)',
+             bygroups(Keyword, Text, Name.Function), '#pop')
+        ],
+        'nested_comment': [
+            (r'[^*/]+', Comment.Multiline),
+            (r'/\*', Comment.Multiline, '#push'),
+            (r'\*/', Comment.Multiline, '#pop'),
+            (r'[*/]', Comment.Multiline)
+        ],
+        'string': [
+            (r'"', String, '#pop'),
+            (r'\\"', String),
+            (r'[^\\"]+', String)
+        ]
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/praat.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/praat.py
new file mode 100644
index 0000000000000000000000000000000000000000..c50e9279f88c4f235262f748f62563b099f58d0b
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/praat.py
@@ -0,0 +1,303 @@
+"""
+    pygments.lexers.praat
+    ~~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for Praat
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, words, bygroups, include
+from pygments.token import Name, Text, Comment, Keyword, String, Punctuation, \
+    Number, Operator, Whitespace
+
+__all__ = ['PraatLexer']
+
+
+class PraatLexer(RegexLexer):
+    """
+    For Praat scripts.
+    """
+
+    name = 'Praat'
+    url = 'http://www.praat.org'
+    aliases = ['praat']
+    filenames = ['*.praat', '*.proc', '*.psc']
+    version_added = '2.1'
+
+    keywords = (
+        'if', 'then', 'else', 'elsif', 'elif', 'endif', 'fi', 'for', 'from', 'to',
+        'endfor', 'endproc', 'while', 'endwhile', 'repeat', 'until', 'select', 'plus',
+        'minus', 'demo', 'assert', 'stopwatch', 'nocheck', 'nowarn', 'noprogress',
+        'editor', 'endeditor', 'clearinfo',
+    )
+
+    functions_string = (
+        'backslashTrigraphsToUnicode', 'chooseDirectory', 'chooseReadFile',
+        'chooseWriteFile', 'date', 'demoKey', 'do', 'environment', 'extractLine',
+        'extractWord', 'fixed', 'info', 'left', 'mid', 'percent', 'readFile', 'replace',
+        'replace_regex', 'right', 'selected', 'string', 'unicodeToBackslashTrigraphs',
+    )
+
+    functions_numeric = (
+        'abs', 'appendFile', 'appendFileLine', 'appendInfo', 'appendInfoLine', 'arccos',
+        'arccosh', 'arcsin', 'arcsinh', 'arctan', 'arctan2', 'arctanh', 'barkToHertz',
+        'beginPause', 'beginSendPraat', 'besselI', 'besselK', 'beta', 'beta2',
+        'binomialP', 'binomialQ', 'boolean', 'ceiling', 'chiSquareP', 'chiSquareQ',
+        'choice', 'comment', 'cos', 'cosh', 'createDirectory', 'deleteFile',
+        'demoClicked', 'demoClickedIn', 'demoCommandKeyPressed',
+        'demoExtraControlKeyPressed', 'demoInput', 'demoKeyPressed',
+        'demoOptionKeyPressed', 'demoShiftKeyPressed', 'demoShow', 'demoWaitForInput',
+        'demoWindowTitle', 'demoX', 'demoY', 'differenceLimensToPhon', 'do', 'editor',
+        'endPause', 'endSendPraat', 'endsWith', 'erb', 'erbToHertz', 'erf', 'erfc',
+        'exitScript', 'exp', 'extractNumber', 'fileReadable', 'fisherP', 'fisherQ',
+        'floor', 'gaussP', 'gaussQ', 'hertzToBark', 'hertzToErb', 'hertzToMel',
+        'hertzToSemitones', 'imax', 'imin', 'incompleteBeta', 'incompleteGammaP', 'index',
+        'index_regex', 'integer', 'invBinomialP', 'invBinomialQ', 'invChiSquareQ', 'invFisherQ',
+        'invGaussQ', 'invSigmoid', 'invStudentQ', 'length', 'ln', 'lnBeta', 'lnGamma',
+        'log10', 'log2', 'max', 'melToHertz', 'min', 'minusObject', 'natural', 'number',
+        'numberOfColumns', 'numberOfRows', 'numberOfSelected', 'objectsAreIdentical',
+        'option', 'optionMenu', 'pauseScript', 'phonToDifferenceLimens', 'plusObject',
+        'positive', 'randomBinomial', 'randomGauss', 'randomInteger', 'randomPoisson',
+        'randomUniform', 'real', 'readFile', 'removeObject', 'rindex', 'rindex_regex',
+        'round', 'runScript', 'runSystem', 'runSystem_nocheck', 'selectObject',
+        'selected', 'semitonesToHertz', 'sentence', 'sentencetext', 'sigmoid', 'sin', 'sinc',
+        'sincpi', 'sinh', 'soundPressureToPhon', 'sqrt', 'startsWith', 'studentP',
+        'studentQ', 'tan', 'tanh', 'text', 'variableExists', 'word', 'writeFile', 'writeFileLine',
+        'writeInfo', 'writeInfoLine',
+    )
+
+    functions_array = (
+        'linear', 'randomGauss', 'randomInteger', 'randomUniform', 'zero',
+    )
+
+    objects = (
+        'Activation', 'AffineTransform', 'AmplitudeTier', 'Art', 'Artword',
+        'Autosegment', 'BarkFilter', 'BarkSpectrogram', 'CCA', 'Categories',
+        'Cepstrogram', 'Cepstrum', 'Cepstrumc', 'ChebyshevSeries', 'ClassificationTable',
+        'Cochleagram', 'Collection', 'ComplexSpectrogram', 'Configuration', 'Confusion',
+        'ContingencyTable', 'Corpus', 'Correlation', 'Covariance',
+        'CrossCorrelationTable', 'CrossCorrelationTables', 'DTW', 'DataModeler',
+        'Diagonalizer', 'Discriminant', 'Dissimilarity', 'Distance', 'Distributions',
+        'DurationTier', 'EEG', 'ERP', 'ERPTier', 'EditCostsTable', 'EditDistanceTable',
+        'Eigen', 'Excitation', 'Excitations', 'ExperimentMFC', 'FFNet', 'FeatureWeights',
+        'FileInMemory', 'FilesInMemory', 'Formant', 'FormantFilter', 'FormantGrid',
+        'FormantModeler', 'FormantPoint', 'FormantTier', 'GaussianMixture', 'HMM',
+        'HMM_Observation', 'HMM_ObservationSequence', 'HMM_State', 'HMM_StateSequence',
+        'Harmonicity', 'ISpline', 'Index', 'Intensity', 'IntensityTier', 'IntervalTier',
+        'KNN', 'KlattGrid', 'KlattTable', 'LFCC', 'LPC', 'Label', 'LegendreSeries',
+        'LinearRegression', 'LogisticRegression', 'LongSound', 'Ltas', 'MFCC', 'MSpline',
+        'ManPages', 'Manipulation', 'Matrix', 'MelFilter', 'MelSpectrogram',
+        'MixingMatrix', 'Movie', 'Network', 'Object', 'OTGrammar', 'OTHistory', 'OTMulti',
+        'PCA', 'PairDistribution', 'ParamCurve', 'Pattern', 'Permutation', 'Photo',
+        'Pitch', 'PitchModeler', 'PitchTier', 'PointProcess', 'Polygon', 'Polynomial',
+        'PowerCepstrogram', 'PowerCepstrum', 'Procrustes', 'RealPoint', 'RealTier',
+        'ResultsMFC', 'Roots', 'SPINET', 'SSCP', 'SVD', 'Salience', 'ScalarProduct',
+        'Similarity', 'SimpleString', 'SortedSetOfString', 'Sound', 'Speaker',
+        'Spectrogram', 'Spectrum', 'SpectrumTier', 'SpeechSynthesizer', 'SpellingChecker',
+        'Strings', 'StringsIndex', 'Table', 'TableOfReal', 'TextGrid', 'TextInterval',
+        'TextPoint', 'TextTier', 'Tier', 'Transition', 'VocalTract', 'VocalTractTier',
+        'Weight', 'WordList',
+    )
+
+    variables_numeric = (
+        'macintosh', 'windows', 'unix', 'praatVersion', 'pi', 'e', 'undefined',
+    )
+
+    variables_string = (
+        'praatVersion', 'tab', 'shellDirectory', 'homeDirectory',
+        'preferencesDirectory', 'newline', 'temporaryDirectory',
+        'defaultDirectory',
+    )
+
+    object_attributes = (
+        'ncol', 'nrow', 'xmin', 'ymin', 'xmax', 'ymax', 'nx', 'ny', 'dx', 'dy',
+    )
+
+    tokens = {
+        'root': [
+            (r'(\s+)(#.*?$)',  bygroups(Whitespace, Comment.Single)),
+            (r'^#.*?$',        Comment.Single),
+            (r';[^\n]*',       Comment.Single),
+            (r'\s+',           Whitespace),
+
+            (r'\bprocedure\b', Keyword,       'procedure_definition'),
+            (r'\bcall\b',      Keyword,       'procedure_call'),
+            (r'@',             Name.Function, 'procedure_call'),
+
+            include('function_call'),
+
+            (words(keywords, suffix=r'\b'), Keyword),
+
+            (r'(\bform\b)(\s+)([^\n]+)',
+             bygroups(Keyword, Whitespace, String), 'old_form'),
+
+            (r'(print(?:line|tab)?|echo|exit|asserterror|pause|send(?:praat|socket)|'
+             r'include|execute|system(?:_nocheck)?)(\s+)',
+             bygroups(Keyword, Whitespace), 'string_unquoted'),
+
+            (r'(goto|label)(\s+)(\w+)', bygroups(Keyword, Whitespace, Name.Label)),
+
+            include('variable_name'),
+            include('number'),
+
+            (r'"', String, 'string'),
+
+            (words((objects), suffix=r'(?=\s+\S+\n)'), Name.Class, 'string_unquoted'),
+
+            (r'\b[A-Z]', Keyword, 'command'),
+            (r'(\.{3}|[)(,])', Punctuation),
+        ],
+        'command': [
+            (r'( ?[\w()-]+ ?)', Keyword),
+
+            include('string_interpolated'),
+
+            (r'\.{3}', Keyword, ('#pop', 'old_arguments')),
+            (r':', Keyword, ('#pop', 'comma_list')),
+            (r'\s', Whitespace, '#pop'),
+        ],
+        'procedure_call': [
+            (r'\s+', Whitespace),
+            (r'([\w.]+)(?:(:)|(?:(\s*)(\()))',
+             bygroups(Name.Function, Punctuation,
+                      Text.Whitespace, Punctuation), '#pop'),
+            (r'([\w.]+)', Name.Function, ('#pop', 'old_arguments')),
+        ],
+        'procedure_definition': [
+            (r'\s', Whitespace),
+            (r'([\w.]+)(\s*?[(:])',
+             bygroups(Name.Function, Whitespace), '#pop'),
+            (r'([\w.]+)([^\n]*)',
+             bygroups(Name.Function, Text), '#pop'),
+        ],
+        'function_call': [
+            (words(functions_string, suffix=r'\$(?=\s*[:(])'), Name.Function, 'function'),
+            (words(functions_array, suffix=r'#(?=\s*[:(])'),   Name.Function, 'function'),
+            (words(functions_numeric, suffix=r'(?=\s*[:(])'),  Name.Function, 'function'),
+        ],
+        'function': [
+            (r'\s+',   Whitespace),
+            (r':',     Punctuation, ('#pop', 'comma_list')),
+            (r'\s*\(', Punctuation, ('#pop', 'comma_list')),
+        ],
+        'comma_list': [
+            (r'(\s*\n\s*)(\.{3})', bygroups(Whitespace, Punctuation)),
+
+            (r'(\s*)(?:([)\]])|(\n))', bygroups(
+                Whitespace, Punctuation, Whitespace), '#pop'),
+
+            (r'\s+', Whitespace),
+            (r'"',   String, 'string'),
+            (r'\b(if|then|else|fi|endif)\b', Keyword),
+
+            include('function_call'),
+            include('variable_name'),
+            include('operator'),
+            include('number'),
+
+            (r'[()]', Text),
+            (r',', Punctuation),
+        ],
+        'old_arguments': [
+            (r'\n', Whitespace, '#pop'),
+
+            include('variable_name'),
+            include('operator'),
+            include('number'),
+
+            (r'"', String, 'string'),
+            (r'[^\n]', Text),
+        ],
+        'number': [
+            (r'\n', Whitespace, '#pop'),
+            (r'\b\d+(\.\d*)?([eE][-+]?\d+)?%?', Number),
+        ],
+        'object_reference': [
+            include('string_interpolated'),
+            (r'([a-z][a-zA-Z0-9_]*|\d+)', Name.Builtin),
+
+            (words(object_attributes, prefix=r'\.'), Name.Builtin, '#pop'),
+
+            (r'\$', Name.Builtin),
+            (r'\[', Text, '#pop'),
+        ],
+        'variable_name': [
+            include('operator'),
+            include('number'),
+
+            (words(variables_string,  suffix=r'\$'), Name.Variable.Global),
+            (words(variables_numeric,
+             suffix=r'(?=[^a-zA-Z0-9_."\'$#\[:(]|\s|^|$)'),
+             Name.Variable.Global),
+
+            (words(objects, prefix=r'\b', suffix=r"(_)"),
+             bygroups(Name.Builtin, Name.Builtin),
+             'object_reference'),
+
+            (r'\.?_?[a-z][\w.]*(\$|#)?', Text),
+            (r'[\[\]]', Punctuation, 'comma_list'),
+
+            include('string_interpolated'),
+        ],
+        'operator': [
+            (r'([+\/*<>=!-]=?|[&*|][&*|]?|\^|<>)',       Operator),
+            (r'(?', Punctuation),
+            (r'"(?:\\x[0-9a-fA-F]+\\|\\u[0-9a-fA-F]{4}|\\U[0-9a-fA-F]{8}|'
+             r'\\[0-7]+\\|\\["\\abcefnrstv]|[^\\"])*"', String.Double),
+            (r"'(?:''|[^'])*'", String.Atom),  # quoted atom
+            # Needs to not be followed by an atom.
+            # (r'=(?=\s|[a-zA-Z\[])', Operator),
+            (r'is\b', Operator),
+            (r'(<|>|=<|>=|==|=:=|=|/|//|\*|\+|-)(?=\s|[a-zA-Z0-9\[])',
+             Operator),
+            (r'(mod|div|not)\b', Operator),
+            (r'_', Keyword),  # The don't-care variable
+            (r'([a-z]+)(:)', bygroups(Name.Namespace, Punctuation)),
+            (r'([a-z\u00c0-\u1fff\u3040-\ud7ff\ue000-\uffef]'
+             r'[\w$\u00c0-\u1fff\u3040-\ud7ff\ue000-\uffef]*)'
+             r'(\s*)(:-|-->)',
+             bygroups(Name.Function, Text, Operator)),  # function defn
+            (r'([a-z\u00c0-\u1fff\u3040-\ud7ff\ue000-\uffef]'
+             r'[\w$\u00c0-\u1fff\u3040-\ud7ff\ue000-\uffef]*)'
+             r'(\s*)(\()',
+             bygroups(Name.Function, Text, Punctuation)),
+            (r'[a-z\u00c0-\u1fff\u3040-\ud7ff\ue000-\uffef]'
+             r'[\w$\u00c0-\u1fff\u3040-\ud7ff\ue000-\uffef]*',
+             String.Atom),  # atom, characters
+            # This one includes !
+            (r'[#&*+\-./:<=>?@\\^~\u00a1-\u00bf\u2010-\u303f]+',
+             String.Atom),  # atom, graphics
+            (r'[A-Z_]\w*', Name.Variable),
+            (r'\s+|[\u2000-\u200f\ufff0-\ufffe\uffef]', Text),
+        ],
+        'nested-comment': [
+            (r'\*/', Comment.Multiline, '#pop'),
+            (r'/\*', Comment.Multiline, '#push'),
+            (r'[^*/]+', Comment.Multiline),
+            (r'[*/]', Comment.Multiline),
+        ],
+    }
+
+    def analyse_text(text):
+        """Competes with IDL and Visual Prolog on *.pro"""
+        if ':-' in text:
+            # Visual Prolog also uses :-
+            return 0.5
+        else:
+            return 0
+
+
+class LogtalkLexer(RegexLexer):
+    """
+    For Logtalk source code.
+    """
+
+    name = 'Logtalk'
+    url = 'http://logtalk.org/'
+    aliases = ['logtalk']
+    filenames = ['*.lgt', '*.logtalk']
+    mimetypes = ['text/x-logtalk']
+    version_added = '0.10'
+
+    tokens = {
+        'root': [
+            # Directives
+            (r'^\s*:-\s', Punctuation, 'directive'),
+            # Comments
+            (r'%.*?\n', Comment),
+            (r'/\*(.|\n)*?\*/', Comment),
+            # Whitespace
+            (r'\n', Text),
+            (r'\s+', Text),
+            # Numbers
+            (r"0'[\\]?.", Number),
+            (r'0b[01]+', Number.Bin),
+            (r'0o[0-7]+', Number.Oct),
+            (r'0x[0-9a-fA-F]+', Number.Hex),
+            (r'\d+\.?\d*((e|E)(\+|-)?\d+)?', Number),
+            # Variables
+            (r'([A-Z_][a-zA-Z0-9_]*)', Name.Variable),
+            # Event handlers
+            (r'(after|before)(?=[(])', Keyword),
+            # Message forwarding handler
+            (r'forward(?=[(])', Keyword),
+            # Execution-context methods
+            (r'(context|parameter|this|se(lf|nder))(?=[(])', Keyword),
+            # Reflection
+            (r'(current_predicate|predicate_property)(?=[(])', Keyword),
+            # DCGs and term expansion
+            (r'(expand_(goal|term)|(goal|term)_expansion|phrase)(?=[(])', Keyword),
+            # Entity
+            (r'(abolish|c(reate|urrent))_(object|protocol|category)(?=[(])', Keyword),
+            (r'(object|protocol|category)_property(?=[(])', Keyword),
+            # Entity relations
+            (r'co(mplements_object|nforms_to_protocol)(?=[(])', Keyword),
+            (r'extends_(object|protocol|category)(?=[(])', Keyword),
+            (r'imp(lements_protocol|orts_category)(?=[(])', Keyword),
+            (r'(instantiat|specializ)es_class(?=[(])', Keyword),
+            # Events
+            (r'(current_event|(abolish|define)_events)(?=[(])', Keyword),
+            # Flags
+            (r'(create|current|set)_logtalk_flag(?=[(])', Keyword),
+            # Compiling, loading, and library paths
+            (r'logtalk_(compile|l(ibrary_path|oad|oad_context)|make(_target_action)?)(?=[(])', Keyword),
+            (r'\blogtalk_make\b', Keyword),
+            # Database
+            (r'(clause|retract(all)?)(?=[(])', Keyword),
+            (r'a(bolish|ssert(a|z))(?=[(])', Keyword),
+            # Control constructs
+            (r'(ca(ll|tch)|throw)(?=[(])', Keyword),
+            (r'(fa(il|lse)|true|(instantiation|system)_error)\b', Keyword),
+            (r'(uninstantiation|type|domain|existence|permission|representation|evaluation|resource|syntax)_error(?=[(])', Keyword),
+            # All solutions
+            (r'((bag|set)of|f(ind|or)all)(?=[(])', Keyword),
+            # Multi-threading predicates
+            (r'threaded(_(ca(ll|ncel)|once|ignore|exit|peek|wait|notify))?(?=[(])', Keyword),
+            # Engine predicates
+            (r'threaded_engine(_(create|destroy|self|next|next_reified|yield|post|fetch))?(?=[(])', Keyword),
+            # Term unification
+            (r'(subsumes_term|unify_with_occurs_check)(?=[(])', Keyword),
+            # Term creation and decomposition
+            (r'(functor|arg|copy_term|numbervars|term_variables)(?=[(])', Keyword),
+            # Evaluable functors
+            (r'(div|rem|m(ax|in|od)|abs|sign)(?=[(])', Keyword),
+            (r'float(_(integer|fractional)_part)?(?=[(])', Keyword),
+            (r'(floor|t(an|runcate)|round|ceiling)(?=[(])', Keyword),
+            # Other arithmetic functors
+            (r'(cos|a(cos|sin|tan|tan2)|exp|log|s(in|qrt)|xor)(?=[(])', Keyword),
+            # Term testing
+            (r'(var|atom(ic)?|integer|float|c(allable|ompound)|n(onvar|umber)|ground|acyclic_term)(?=[(])', Keyword),
+            # Term comparison
+            (r'compare(?=[(])', Keyword),
+            # Stream selection and control
+            (r'(curren|se)t_(in|out)put(?=[(])', Keyword),
+            (r'(open|close)(?=[(])', Keyword),
+            (r'flush_output(?=[(])', Keyword),
+            (r'(at_end_of_stream|flush_output)\b', Keyword),
+            (r'(stream_property|at_end_of_stream|set_stream_position)(?=[(])', Keyword),
+            # Character and byte input/output
+            (r'(nl|(get|peek|put)_(byte|c(har|ode)))(?=[(])', Keyword),
+            (r'\bnl\b', Keyword),
+            # Term input/output
+            (r'read(_term)?(?=[(])', Keyword),
+            (r'write(q|_(canonical|term))?(?=[(])', Keyword),
+            (r'(current_)?op(?=[(])', Keyword),
+            (r'(current_)?char_conversion(?=[(])', Keyword),
+            # Atomic term processing
+            (r'atom_(length|c(hars|o(ncat|des)))(?=[(])', Keyword),
+            (r'(char_code|sub_atom)(?=[(])', Keyword),
+            (r'number_c(har|ode)s(?=[(])', Keyword),
+            # Implementation defined hooks functions
+            (r'(se|curren)t_prolog_flag(?=[(])', Keyword),
+            (r'\bhalt\b', Keyword),
+            (r'halt(?=[(])', Keyword),
+            # Message sending operators
+            (r'(::|:|\^\^)', Operator),
+            # External call
+            (r'[{}]', Keyword),
+            # Logic and control
+            (r'(ignore|once)(?=[(])', Keyword),
+            (r'\brepeat\b', Keyword),
+            # Sorting
+            (r'(key)?sort(?=[(])', Keyword),
+            # Bitwise functors
+            (r'(>>|<<|/\\|\\\\|\\)', Operator),
+            # Predicate aliases
+            (r'\bas\b', Operator),
+            # Arithmetic evaluation
+            (r'\bis\b', Keyword),
+            # Arithmetic comparison
+            (r'(=:=|=\\=|<|=<|>=|>)', Operator),
+            # Term creation and decomposition
+            (r'=\.\.', Operator),
+            # Term unification
+            (r'(=|\\=)', Operator),
+            # Term comparison
+            (r'(==|\\==|@=<|@<|@>=|@>)', Operator),
+            # Evaluable functors
+            (r'(//|[-+*/])', Operator),
+            (r'\b(e|pi|div|mod|rem)\b', Operator),
+            # Other arithmetic functors
+            (r'\b\*\*\b', Operator),
+            # DCG rules
+            (r'-->', Operator),
+            # Control constructs
+            (r'([!;]|->)', Operator),
+            # Logic and control
+            (r'\\+', Operator),
+            # Mode operators
+            (r'[?@]', Operator),
+            # Existential quantifier
+            (r'\^', Operator),
+            # Punctuation
+            (r'[()\[\],.|]', Text),
+            # Atoms
+            (r"[a-z][a-zA-Z0-9_]*", Text),
+            (r"'", String, 'quoted_atom'),
+            # Double-quoted terms
+            (r'"', String, 'double_quoted_term'),
+        ],
+
+        'quoted_atom': [
+            (r"''", String),
+            (r"'", String, '#pop'),
+            (r'\\([\\abfnrtv"\']|(x[a-fA-F0-9]+|[0-7]+)\\)', String.Escape),
+            (r"[^\\'\n]+", String),
+            (r'\\', String),
+        ],
+
+        'double_quoted_term': [
+            (r'""', String),
+            (r'"', String, '#pop'),
+            (r'\\([\\abfnrtv"\']|(x[a-fA-F0-9]+|[0-7]+)\\)', String.Escape),
+            (r'[^\\"\n]+', String),
+            (r'\\', String),
+        ],
+
+        'directive': [
+            # Conditional compilation directives
+            (r'(el)?if(?=[(])', Keyword, 'root'),
+            (r'(e(lse|ndif))(?=[.])', Keyword, 'root'),
+            # Entity directives
+            (r'(category|object|protocol)(?=[(])', Keyword, 'entityrelations'),
+            (r'(end_(category|object|protocol))(?=[.])', Keyword, 'root'),
+            # Predicate scope directives
+            (r'(public|protected|private)(?=[(])', Keyword, 'root'),
+            # Other directives
+            (r'e(n(coding|sure_loaded)|xport)(?=[(])', Keyword, 'root'),
+            (r'in(clude|itialization|fo)(?=[(])', Keyword, 'root'),
+            (r'(built_in|dynamic|synchronized|threaded)(?=[.])', Keyword, 'root'),
+            (r'(alias|d(ynamic|iscontiguous)|m(eta_(non_terminal|predicate)|ode|ultifile)|s(et_(logtalk|prolog)_flag|ynchronized))(?=[(])', Keyword, 'root'),
+            (r'op(?=[(])', Keyword, 'root'),
+            (r'(c(alls|oinductive)|module|reexport|use(s|_module))(?=[(])', Keyword, 'root'),
+            (r'[a-z][a-zA-Z0-9_]*(?=[(])', Text, 'root'),
+            (r'[a-z][a-zA-Z0-9_]*(?=[.])', Text, 'root'),
+        ],
+
+        'entityrelations': [
+            (r'(complements|extends|i(nstantiates|mp(lements|orts))|specializes)(?=[(])', Keyword),
+            # Numbers
+            (r"0'[\\]?.", Number),
+            (r'0b[01]+', Number.Bin),
+            (r'0o[0-7]+', Number.Oct),
+            (r'0x[0-9a-fA-F]+', Number.Hex),
+            (r'\d+\.?\d*((e|E)(\+|-)?\d+)?', Number),
+            # Variables
+            (r'([A-Z_][a-zA-Z0-9_]*)', Name.Variable),
+            # Atoms
+            (r"[a-z][a-zA-Z0-9_]*", Text),
+            (r"'", String, 'quoted_atom'),
+            # Double-quoted terms
+            (r'"', String, 'double_quoted_term'),
+            # End of entity-opening directive
+            (r'([)]\.)', Text, 'root'),
+            # Scope operator
+            (r'(::)', Operator),
+            # Punctuation
+            (r'[()\[\],.|]', Text),
+            # Comments
+            (r'%.*?\n', Comment),
+            (r'/\*(.|\n)*?\*/', Comment),
+            # Whitespace
+            (r'\n', Text),
+            (r'\s+', Text),
+        ]
+    }
+
+    def analyse_text(text):
+        if ':- object(' in text:
+            return 1.0
+        elif ':- protocol(' in text:
+            return 1.0
+        elif ':- category(' in text:
+            return 1.0
+        elif re.search(r'^:-\s[a-z]', text, re.M):
+            return 0.9
+        else:
+            return 0.0
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/promql.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/promql.py
new file mode 100644
index 0000000000000000000000000000000000000000..5cfa73fe1e619918e80828ab1529f268938adcd0
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/promql.py
@@ -0,0 +1,176 @@
+"""
+    pygments.lexers.promql
+    ~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for Prometheus Query Language.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, bygroups, default, words
+from pygments.token import Comment, Keyword, Name, Number, Operator, \
+    Punctuation, String, Whitespace
+
+__all__ = ["PromQLLexer"]
+
+
+class PromQLLexer(RegexLexer):
+    """
+    For PromQL queries.
+
+    For details about the grammar see:
+    https://github.com/prometheus/prometheus/tree/master/promql/parser
+
+    .. versionadded: 2.7
+    """
+
+    name = "PromQL"
+    url = 'https://prometheus.io/docs/prometheus/latest/querying/basics/'
+    aliases = ["promql"]
+    filenames = ["*.promql"]
+    version_added = ''
+
+    base_keywords = (
+        words(
+            (
+                "bool",
+                "by",
+                "group_left",
+                "group_right",
+                "ignoring",
+                "offset",
+                "on",
+                "without",
+            ),
+            suffix=r"\b",
+        ),
+        Keyword,
+    )
+
+    aggregator_keywords = (
+        words(
+            (
+                "sum",
+                "min",
+                "max",
+                "avg",
+                "group",
+                "stddev",
+                "stdvar",
+                "count",
+                "count_values",
+                "bottomk",
+                "topk",
+                "quantile",
+            ),
+            suffix=r"\b",
+        ),
+        Keyword,
+    )
+
+    function_keywords = (
+        words(
+            (
+                "abs",
+                "absent",
+                "absent_over_time",
+                "avg_over_time",
+                "ceil",
+                "changes",
+                "clamp_max",
+                "clamp_min",
+                "count_over_time",
+                "day_of_month",
+                "day_of_week",
+                "days_in_month",
+                "delta",
+                "deriv",
+                "exp",
+                "floor",
+                "histogram_quantile",
+                "holt_winters",
+                "hour",
+                "idelta",
+                "increase",
+                "irate",
+                "label_join",
+                "label_replace",
+                "ln",
+                "log10",
+                "log2",
+                "max_over_time",
+                "min_over_time",
+                "minute",
+                "month",
+                "predict_linear",
+                "quantile_over_time",
+                "rate",
+                "resets",
+                "round",
+                "scalar",
+                "sort",
+                "sort_desc",
+                "sqrt",
+                "stddev_over_time",
+                "stdvar_over_time",
+                "sum_over_time",
+                "time",
+                "timestamp",
+                "vector",
+                "year",
+            ),
+            suffix=r"\b",
+        ),
+        Keyword.Reserved,
+    )
+
+    tokens = {
+        "root": [
+            (r"\n", Whitespace),
+            (r"\s+", Whitespace),
+            (r",", Punctuation),
+            # Keywords
+            base_keywords,
+            aggregator_keywords,
+            function_keywords,
+            # Offsets
+            (r"[1-9][0-9]*[smhdwy]", String),
+            # Numbers
+            (r"-?[0-9]+\.[0-9]+", Number.Float),
+            (r"-?[0-9]+", Number.Integer),
+            # Comments
+            (r"#.*?$", Comment.Single),
+            # Operators
+            (r"(\+|\-|\*|\/|\%|\^)", Operator),
+            (r"==|!=|>=|<=|<|>", Operator),
+            (r"and|or|unless", Operator.Word),
+            # Metrics
+            (r"[_a-zA-Z][a-zA-Z0-9_]+", Name.Variable),
+            # Params
+            (r'(["\'])(.*?)(["\'])', bygroups(Punctuation, String, Punctuation)),
+            # Other states
+            (r"\(", Operator, "function"),
+            (r"\)", Operator),
+            (r"\{", Punctuation, "labels"),
+            (r"\[", Punctuation, "range"),
+        ],
+        "labels": [
+            (r"\}", Punctuation, "#pop"),
+            (r"\n", Whitespace),
+            (r"\s+", Whitespace),
+            (r",", Punctuation),
+            (r'([_a-zA-Z][a-zA-Z0-9_]*?)(\s*?)(=~|!=|=|!~)(\s*?)("|\')(.*?)("|\')',
+             bygroups(Name.Label, Whitespace, Operator, Whitespace,
+                      Punctuation, String, Punctuation)),
+        ],
+        "range": [
+            (r"\]", Punctuation, "#pop"),
+            (r"[1-9][0-9]*[smhdwy]", String),
+        ],
+        "function": [
+            (r"\)", Operator, "#pop"),
+            (r"\(", Operator, "#push"),
+            default("#pop"),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/prql.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/prql.py
new file mode 100644
index 0000000000000000000000000000000000000000..a62cb6bcd1a9ff89660b996ebda8106f687d296a
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/prql.py
@@ -0,0 +1,251 @@
+"""
+    pygments.lexers.prql
+    ~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for the PRQL query language.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, combined, words, include, bygroups
+from pygments.token import Comment, Literal, Keyword, Name, Number, Operator, \
+    Punctuation, String, Text, Whitespace
+
+__all__ = ['PrqlLexer']
+
+
+class PrqlLexer(RegexLexer):
+    """
+    For PRQL source code.
+
+    grammar: https://github.com/PRQL/prql/tree/main/grammars
+    """
+
+    name = 'PRQL'
+    url = 'https://prql-lang.org/'
+    aliases = ['prql']
+    filenames = ['*.prql']
+    mimetypes = ['application/prql', 'application/x-prql']
+    version_added = '2.17'
+
+    builtinTypes = words((
+        "bool",
+        "int",
+        "int8", "int16", "int32", "int64", "int128",
+        "float",
+        "text",
+        "set"), suffix=r'\b')
+
+    def innerstring_rules(ttype):
+        return [
+            # the new style '{}'.format(...) string formatting
+            (r'\{'
+             r'((\w+)((\.\w+)|(\[[^\]]+\]))*)?'  # field name
+             r'(\:(.?[<>=\^])?[-+ ]?#?0?(\d+)?,?(\.\d+)?[E-GXb-gnosx%]?)?'
+             r'\}', String.Interpol),
+
+            (r'[^\\\'"%{\n]+', ttype),
+            (r'[\'"\\]', ttype),
+            (r'%|(\{{1,2})', ttype)
+        ]
+
+    def fstring_rules(ttype):
+        return [
+            (r'\}', String.Interpol),
+            (r'\{', String.Interpol, 'expr-inside-fstring'),
+            (r'[^\\\'"{}\n]+', ttype),
+            (r'[\'"\\]', ttype),
+        ]
+
+    tokens = {
+        'root': [
+
+            # Comments
+            (r'#!.*', String.Doc),
+            (r'#.*', Comment.Single),
+
+            # Whitespace
+            (r'\s+', Whitespace),
+
+            # Modules
+            (r'^(\s*)(module)(\s*)',
+             bygroups(Whitespace, Keyword.Namespace, Whitespace),
+             'imports'),
+
+            (builtinTypes, Keyword.Type),
+
+            # Main
+            (r'^prql ', Keyword.Reserved),
+
+            ('let', Keyword.Declaration),
+
+            include('keywords'),
+            include('expr'),
+
+            # Transforms
+            (r'^[A-Za-z_][a-zA-Z0-9_]*', Keyword),
+        ],
+        'expr': [
+            # non-raw f-strings
+            ('(f)(""")', bygroups(String.Affix, String.Double),
+             combined('fstringescape', 'tdqf')),
+            ("(f)(''')", bygroups(String.Affix, String.Single),
+             combined('fstringescape', 'tsqf')),
+            ('(f)(")', bygroups(String.Affix, String.Double),
+             combined('fstringescape', 'dqf')),
+            ("(f)(')", bygroups(String.Affix, String.Single),
+             combined('fstringescape', 'sqf')),
+
+            # non-raw s-strings
+            ('(s)(""")', bygroups(String.Affix, String.Double),
+             combined('stringescape', 'tdqf')),
+            ("(s)(''')", bygroups(String.Affix, String.Single),
+             combined('stringescape', 'tsqf')),
+            ('(s)(")', bygroups(String.Affix, String.Double),
+             combined('stringescape', 'dqf')),
+            ("(s)(')", bygroups(String.Affix, String.Single),
+             combined('stringescape', 'sqf')),
+
+            # raw strings
+            ('(?i)(r)(""")',
+             bygroups(String.Affix, String.Double), 'tdqs'),
+            ("(?i)(r)(''')",
+             bygroups(String.Affix, String.Single), 'tsqs'),
+            ('(?i)(r)(")',
+             bygroups(String.Affix, String.Double), 'dqs'),
+            ("(?i)(r)(')",
+             bygroups(String.Affix, String.Single), 'sqs'),
+
+            # non-raw strings
+            ('"""', String.Double, combined('stringescape', 'tdqs')),
+            ("'''", String.Single, combined('stringescape', 'tsqs')),
+            ('"', String.Double, combined('stringescape', 'dqs')),
+            ("'", String.Single, combined('stringescape', 'sqs')),
+
+            # Time and dates
+            (r'@\d{4}-\d{2}-\d{2}T\d{2}(:\d{2})?(:\d{2})?(\.\d{1,6})?(Z|[+-]\d{1,2}(:\d{1,2})?)?', Literal.Date),
+            (r'@\d{4}-\d{2}-\d{2}', Literal.Date),
+            (r'@\d{2}(:\d{2})?(:\d{2})?(\.\d{1,6})?(Z|[+-]\d{1,2}(:\d{1,2})?)?', Literal.Date),
+
+            (r'[^\S\n]+', Text),
+            include('numbers'),
+            (r'->|=>|==|!=|>=|<=|~=|&&|\|\||\?\?|\/\/', Operator),
+            (r'[-~+/*%=<>&^|.@]', Operator),
+            (r'[]{}:(),;[]', Punctuation),
+            include('functions'),
+
+            # Variable Names
+            (r'[A-Za-z_][a-zA-Z0-9_]*', Name.Variable),
+        ],
+        'numbers': [
+            (r'(\d(?:_?\d)*\.(?:\d(?:_?\d)*)?|(?:\d(?:_?\d)*)?\.\d(?:_?\d)*)'
+             r'([eE][+-]?\d(?:_?\d)*)?', Number.Float),
+            (r'\d(?:_?\d)*[eE][+-]?\d(?:_?\d)*j?', Number.Float),
+            (r'0[oO](?:_?[0-7])+', Number.Oct),
+            (r'0[bB](?:_?[01])+', Number.Bin),
+            (r'0[xX](?:_?[a-fA-F0-9])+', Number.Hex),
+            (r'\d(?:_?\d)*', Number.Integer),
+        ],
+        'fstringescape': [
+            include('stringescape'),
+        ],
+        'bytesescape': [
+            (r'\\([\\bfnrt"\']|\n|x[a-fA-F0-9]{2}|[0-7]{1,3})', String.Escape)
+        ],
+        'stringescape': [
+            (r'\\(N\{.*?\}|u\{[a-fA-F0-9]{1,6}\})', String.Escape),
+            include('bytesescape')
+        ],
+        'fstrings-single': fstring_rules(String.Single),
+        'fstrings-double': fstring_rules(String.Double),
+        'strings-single': innerstring_rules(String.Single),
+        'strings-double': innerstring_rules(String.Double),
+        'dqf': [
+            (r'"', String.Double, '#pop'),
+            (r'\\\\|\\"|\\\n', String.Escape),  # included here for raw strings
+            include('fstrings-double')
+        ],
+        'sqf': [
+            (r"'", String.Single, '#pop'),
+            (r"\\\\|\\'|\\\n", String.Escape),  # included here for raw strings
+            include('fstrings-single')
+        ],
+        'dqs': [
+            (r'"', String.Double, '#pop'),
+            (r'\\\\|\\"|\\\n', String.Escape),  # included here for raw strings
+            include('strings-double')
+        ],
+        'sqs': [
+            (r"'", String.Single, '#pop'),
+            (r"\\\\|\\'|\\\n", String.Escape),  # included here for raw strings
+            include('strings-single')
+        ],
+        'tdqf': [
+            (r'"""', String.Double, '#pop'),
+            include('fstrings-double'),
+            (r'\n', String.Double)
+        ],
+        'tsqf': [
+            (r"'''", String.Single, '#pop'),
+            include('fstrings-single'),
+            (r'\n', String.Single)
+        ],
+        'tdqs': [
+            (r'"""', String.Double, '#pop'),
+            include('strings-double'),
+            (r'\n', String.Double)
+        ],
+        'tsqs': [
+            (r"'''", String.Single, '#pop'),
+            include('strings-single'),
+            (r'\n', String.Single)
+        ],
+
+        'expr-inside-fstring': [
+            (r'[{([]', Punctuation, 'expr-inside-fstring-inner'),
+            # without format specifier
+            (r'(=\s*)?'         # debug (https://bugs.python.org/issue36817)
+             r'\}', String.Interpol, '#pop'),
+            # with format specifier
+            # we'll catch the remaining '}' in the outer scope
+            (r'(=\s*)?'         # debug (https://bugs.python.org/issue36817)
+             r':', String.Interpol, '#pop'),
+            (r'\s+', Whitespace),  # allow new lines
+            include('expr'),
+        ],
+        'expr-inside-fstring-inner': [
+            (r'[{([]', Punctuation, 'expr-inside-fstring-inner'),
+            (r'[])}]', Punctuation, '#pop'),
+            (r'\s+', Whitespace),  # allow new lines
+            include('expr'),
+        ],
+        'keywords': [
+            (words((
+                'into', 'case', 'type', 'module', 'internal',
+            ), suffix=r'\b'),
+                Keyword),
+            (words(('true', 'false', 'null'), suffix=r'\b'), Keyword.Constant),
+        ],
+        'functions': [
+            (words((
+                "min", "max", "sum", "average", "stddev", "every", "any",
+                "concat_array", "count", "lag", "lead", "first", "last",
+                "rank", "rank_dense", "row_number", "round", "as", "in",
+                "tuple_every", "tuple_map", "tuple_zip", "_eq", "_is_null",
+                "from_text", "lower", "upper", "read_parquet", "read_csv"),
+                suffix=r'\b'),
+             Name.Function),
+        ],
+
+        'comment': [
+            (r'-(?!\})', Comment.Multiline),
+            (r'\{-', Comment.Multiline, 'comment'),
+            (r'[^-}]', Comment.Multiline),
+            (r'-\}', Comment.Multiline, '#pop'),
+        ],
+
+        'imports': [
+            (r'\w+(\.\w+)*', Name.Class, '#pop'),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/ptx.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/ptx.py
new file mode 100644
index 0000000000000000000000000000000000000000..685c7357ecb2548069d3b5506fae5f8ba8ceb65b
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/ptx.py
@@ -0,0 +1,119 @@
+"""
+    pygments.lexers.ptx
+    ~~~~~~~~~~~~~~~~~~~
+
+    Lexer for other PTX language.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, include, words
+from pygments.token import Comment, Keyword, Name, String, Number, \
+    Punctuation, Whitespace, Operator
+
+__all__ = ["PtxLexer"]
+
+
+class PtxLexer(RegexLexer):
+    """
+    For NVIDIA `PTX `_
+    source.
+    """
+    name = 'PTX'
+    url = "https://docs.nvidia.com/cuda/parallel-thread-execution/"
+    filenames = ['*.ptx']
+    aliases = ['ptx']
+    mimetypes = ['text/x-ptx']
+    version_added = '2.16'
+
+    #: optional Comment or Whitespace
+    string = r'"[^"]*?"'
+    followsym = r'[a-zA-Z0-9_$]'
+    identifier = r'([-a-zA-Z$._][\w\-$.]*|' + string + ')'
+    block_label = r'(' + identifier + r'|(\d+))'
+
+    tokens = {
+        'root': [
+            include('whitespace'),
+
+            (block_label + r'\s*:', Name.Label),
+
+            include('keyword'),
+
+            (r'%' + identifier, Name.Variable),
+            (r'%\d+', Name.Variable.Anonymous),
+            (r'c?' + string, String),
+            (identifier, Name.Variable),
+            (r';', Punctuation),
+            (r'[*+-/]', Operator),
+
+            (r'0[xX][a-fA-F0-9]+', Number),
+            (r'-?\d+(?:[.]\d+)?(?:[eE][-+]?\d+(?:[.]\d+)?)?', Number),
+
+            (r'[=<>{}\[\]()*.,!]|x\b', Punctuation)
+
+        ],
+        'whitespace': [
+            (r'(\n|\s+)+', Whitespace),
+            (r'//.*?\n', Comment)
+        ],
+
+        'keyword': [
+            # Instruction keywords
+            (words((
+                'abs', 'discard', 'min', 'shf', 'vadd',
+                'activemask', 'div', 'mma', 'shfl', 'vadd2',
+                'add', 'dp2a', 'mov', 'shl', 'vadd4',
+                'addc', 'dp4a', 'movmatrix', 'shr', 'vavrg2',
+                'alloca', 'elect', 'mul', 'sin', 'vavrg4',
+                'and', 'ex2', 'mul24', 'slct', 'vmad',
+                'applypriority', 'exit', 'multimem', 'sqrt', 'vmax',
+                'atom', 'fence', 'nanosleep', 'st', 'vmax2',
+                'bar', 'fma', 'neg', 'stackrestore', 'vmax4',
+                'barrier', 'fns', 'not', 'stacksave', 'vmin',
+                'bfe', 'getctarank', 'or', 'stmatrix', 'vmin2',
+                'bfi', 'griddepcontrol', 'pmevent', 'sub', 'vmin4',
+                'bfind', 'isspacep', 'popc', 'subc', 'vote',
+                'bmsk', 'istypep', 'prefetch', 'suld', 'vset',
+                'bra', 'ld', 'prefetchu', 'suq', 'vset2',
+                'brev', 'ldmatrix', 'prmt', 'sured', 'vset4',
+                'brkpt', 'ldu', 'rcp', 'sust', 'vshl',
+                'brx', 'lg2', 'red', 'szext', 'vshr',
+                'call', 'lop3', 'redux', 'tanh', 'vsub',
+                'clz', 'mad', 'rem', 'testp', 'vsub2',
+                'cnot', 'mad24', 'ret', 'tex', 'vsub4',
+                'copysign', 'madc', 'rsqrt', 'tld4', 'wgmma',
+                'cos', 'mapa', 'sad', 'trap', 'wmma',
+                'cp', 'match', 'selp', 'txq', 'xor',
+                'createpolicy', 'max', 'set', 'vabsdiff', 'cvt',
+                'mbarrier', 'setmaxnreg', 'vabsdiff2', 'cvta',
+                'membar', 'setp', 'vabsdiff4')), Keyword),
+            # State Spaces and Suffixes
+            (words((
+                'reg', '.sreg', '.const', '.global',
+                '.local', '.param', '.shared', '.tex',
+                '.wide', '.loc'
+            )), Keyword.Pseudo),
+            # PTX Directives
+            (words((
+                '.address_size', '.explicitcluster', '.maxnreg', '.section',
+                '.alias', '.extern', '.maxntid', '.shared',
+                '.align', '.file', '.minnctapersm', '.sreg',
+                '.branchtargets', '.func', '.noreturn', '.target',
+                '.callprototype', '.global', '.param', '.tex',
+                '.calltargets', '.loc', '.pragma', '.version',
+                '.common', '.local', '.reg', '.visible',
+                '.const', '.maxclusterrank', '.reqnctapercluster', '.weak',
+                '.entry', '.maxnctapersm', '.reqntid')), Keyword.Reserved),
+            # Fundamental Types
+            (words((
+                '.s8', '.s16', '.s32', '.s64',
+                '.u8', '.u16', '.u32', '.u64',
+                '.f16', '.f16x2', '.f32', '.f64',
+                '.b8', '.b16', '.b32', '.b64',
+                '.pred'
+            )), Keyword.Type)
+        ],
+
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/python.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/python.py
new file mode 100644
index 0000000000000000000000000000000000000000..b296c8dbe4ed35625167711800abd9642b61c84b
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/python.py
@@ -0,0 +1,1204 @@
+"""
+    pygments.lexers.python
+    ~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for Python and related languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import keyword
+
+from pygments.lexer import DelegatingLexer, RegexLexer, include, \
+    bygroups, using, default, words, combined, this
+from pygments.util import get_bool_opt, shebang_matches
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation, Generic, Other, Error, Whitespace
+from pygments import unistring as uni
+
+__all__ = ['PythonLexer', 'PythonConsoleLexer', 'PythonTracebackLexer',
+           'Python2Lexer', 'Python2TracebackLexer',
+           'CythonLexer', 'DgLexer', 'NumPyLexer']
+
+
+class PythonLexer(RegexLexer):
+    """
+    For Python source code (version 3.x).
+
+    .. versionchanged:: 2.5
+       This is now the default ``PythonLexer``.  It is still available as the
+       alias ``Python3Lexer``.
+    """
+
+    name = 'Python'
+    url = 'https://www.python.org'
+    aliases = ['python', 'py', 'sage', 'python3', 'py3', 'bazel', 'starlark', 'pyi']
+    filenames = [
+        '*.py',
+        '*.pyw',
+        # Type stubs
+        '*.pyi',
+        # Jython
+        '*.jy',
+        # Sage
+        '*.sage',
+        # SCons
+        '*.sc',
+        'SConstruct',
+        'SConscript',
+        # Skylark/Starlark (used by Bazel, Buck, and Pants)
+        '*.bzl',
+        'BUCK',
+        'BUILD',
+        'BUILD.bazel',
+        'WORKSPACE',
+        # Twisted Application infrastructure
+        '*.tac',
+        # Execubot level format
+        '*.pye',
+    ]
+    mimetypes = ['text/x-python', 'application/x-python',
+                 'text/x-python3', 'application/x-python3']
+    version_added = '0.10'
+
+    uni_name = f"[{uni.xid_start}][{uni.xid_continue}]*"
+
+    def innerstring_rules(ttype):
+        return [
+            # the old style '%s' % (...) string formatting (still valid in Py3)
+            (r'%(\(\w+\))?[-#0 +]*([0-9]+|[*])?(\.([0-9]+|[*]))?'
+             '[hlL]?[E-GXc-giorsaux%]', String.Interpol),
+            # the new style '{}'.format(...) string formatting
+            (r'\{'
+             r'((\w+)((\.\w+)|(\[[^\]]+\]))*)?'  # field name
+             r'(\![sra])?'                       # conversion
+             r'(\:(.?[<>=\^])?[-+ ]?#?0?(\d+)?,?(\.\d+)?[E-GXb-gnosx%]?)?'
+             r'\}', String.Interpol),
+
+            # backslashes, quotes and formatting signs must be parsed one at a time
+            (r'[^\\\'"%{\n]+', ttype),
+            (r'[\'"\\]', ttype),
+            # unhandled string formatting sign
+            (r'%|(\{{1,2})', ttype)
+            # newlines are an error (use "nl" state)
+        ]
+
+    def fstring_rules(ttype):
+        return [
+            # Assuming that a '}' is the closing brace after format specifier.
+            # Sadly, this means that we won't detect syntax error. But it's
+            # more important to parse correct syntax correctly, than to
+            # highlight invalid syntax.
+            (r'\}', String.Interpol),
+            (r'\{', String.Interpol, 'expr-inside-fstring'),
+            # backslashes, quotes and formatting signs must be parsed one at a time
+            (r'[^\\\'"{}\n]+', ttype),
+            (r'[\'"\\]', ttype),
+            # newlines are an error (use "nl" state)
+        ]
+
+    tokens = {
+        'root': [
+            (r'\n', Whitespace),
+            (r'^(\s*)([rRuUbB]{,2})("""(?:.|\n)*?""")',
+             bygroups(Whitespace, String.Affix, String.Doc)),
+            (r"^(\s*)([rRuUbB]{,2})('''(?:.|\n)*?''')",
+             bygroups(Whitespace, String.Affix, String.Doc)),
+            (r'\A#!.+$', Comment.Hashbang),
+            (r'#.*$', Comment.Single),
+            (r'\\\n', Text),
+            (r'\\', Text),
+            include('keywords'),
+            include('soft-keywords'),
+            (r'(def)((?:\s|\\\s)+)', bygroups(Keyword, Whitespace), 'funcname'),
+            (r'(class)((?:\s|\\\s)+)', bygroups(Keyword, Whitespace), 'classname'),
+            (r'(from)((?:\s|\\\s)+)', bygroups(Keyword.Namespace, Whitespace),
+             'fromimport'),
+            (r'(import)((?:\s|\\\s)+)', bygroups(Keyword.Namespace, Whitespace),
+             'import'),
+            include('expr'),
+        ],
+        'expr': [
+            # raw f-strings and t-strings
+            ('(?i)(r[ft]|[ft]r)(""")',
+             bygroups(String.Affix, String.Double),
+             combined('rfstringescape', 'tdqf')),
+            ("(?i)(r[ft]|[ft]r)(''')",
+             bygroups(String.Affix, String.Single),
+             combined('rfstringescape', 'tsqf')),
+            ('(?i)(r[ft]|[ft]r)(")',
+             bygroups(String.Affix, String.Double),
+             combined('rfstringescape', 'dqf')),
+            ("(?i)(r[ft]|[ft]r)(')",
+             bygroups(String.Affix, String.Single),
+             combined('rfstringescape', 'sqf')),
+            # non-raw f-strings and t-strings
+            ('([fFtT])(""")', bygroups(String.Affix, String.Double),
+             combined('fstringescape', 'tdqf')),
+            ("([fFtT])(''')", bygroups(String.Affix, String.Single),
+             combined('fstringescape', 'tsqf')),
+            ('([fFtT])(")', bygroups(String.Affix, String.Double),
+             combined('fstringescape', 'dqf')),
+            ("([fFtT])(')", bygroups(String.Affix, String.Single),
+             combined('fstringescape', 'sqf')),
+            # raw bytes and strings
+            ('(?i)(rb|br|r)(""")',
+             bygroups(String.Affix, String.Double), 'tdqs'),
+            ("(?i)(rb|br|r)(''')",
+             bygroups(String.Affix, String.Single), 'tsqs'),
+            ('(?i)(rb|br|r)(")',
+             bygroups(String.Affix, String.Double), 'dqs'),
+            ("(?i)(rb|br|r)(')",
+             bygroups(String.Affix, String.Single), 'sqs'),
+            # non-raw strings
+            ('([uU]?)(""")', bygroups(String.Affix, String.Double),
+             combined('stringescape', 'tdqs')),
+            ("([uU]?)(''')", bygroups(String.Affix, String.Single),
+             combined('stringescape', 'tsqs')),
+            ('([uU]?)(")', bygroups(String.Affix, String.Double),
+             combined('stringescape', 'dqs')),
+            ("([uU]?)(')", bygroups(String.Affix, String.Single),
+             combined('stringescape', 'sqs')),
+            # non-raw bytes
+            ('([bB])(""")', bygroups(String.Affix, String.Double),
+             combined('bytesescape', 'tdqs')),
+            ("([bB])(''')", bygroups(String.Affix, String.Single),
+             combined('bytesescape', 'tsqs')),
+            ('([bB])(")', bygroups(String.Affix, String.Double),
+             combined('bytesescape', 'dqs')),
+            ("([bB])(')", bygroups(String.Affix, String.Single),
+             combined('bytesescape', 'sqs')),
+
+            (r'[^\S\n]+', Text),
+            include('numbers'),
+            (r'!=|==|<<|>>|:=|[-~+/*%=<>&^|.]', Operator),
+            (r'[]{}:(),;[]', Punctuation),
+            (r'(in|is|and|or|not)\b', Operator.Word),
+            include('expr-keywords'),
+            include('builtins'),
+            include('magicfuncs'),
+            include('magicvars'),
+            include('name'),
+        ],
+        'expr-inside-fstring': [
+            (r'[{([]', Punctuation, 'expr-inside-fstring-inner'),
+            # without format specifier
+            (r'(=\s*)?'         # debug (https://bugs.python.org/issue36817)
+             r'(\![sraf])?'     # conversion
+             r'\}', String.Interpol, '#pop'),
+            # with format specifier
+            # we'll catch the remaining '}' in the outer scope
+            (r'(=\s*)?'         # debug (https://bugs.python.org/issue36817)
+             r'(\![sraf])?'     # conversion
+             r':', String.Interpol, '#pop'),
+            (r'\s+', Whitespace),  # allow new lines
+            include('expr'),
+        ],
+        'expr-inside-fstring-inner': [
+            (r'[{([]', Punctuation, 'expr-inside-fstring-inner'),
+            (r'[])}]', Punctuation, '#pop'),
+            (r'\s+', Whitespace),  # allow new lines
+            include('expr'),
+        ],
+        'expr-keywords': [
+            # Based on https://docs.python.org/3/reference/expressions.html
+            (words((
+                'async for', 'await', 'else', 'for', 'if', 'lambda',
+                'yield', 'yield from'), suffix=r'\b'),
+             Keyword),
+            (words(('True', 'False', 'None'), suffix=r'\b'), Keyword.Constant),
+        ],
+        'keywords': [
+            (words((
+                'assert', 'async', 'await', 'break', 'continue', 'del', 'elif',
+                'else', 'except', 'finally', 'for', 'global', 'if', 'lambda',
+                'pass', 'raise', 'nonlocal', 'return', 'try', 'while', 'yield',
+                'yield from', 'as', 'with'), suffix=r'\b'),
+             Keyword),
+            (words(('True', 'False', 'None'), suffix=r'\b'), Keyword.Constant),
+        ],
+        'soft-keywords': [
+            # `match`, `case` and `_` soft keywords
+            (r'(^[ \t]*)'              # at beginning of line + possible indentation
+             r'(match|case)\b'         # a possible keyword
+             r'(?![ \t]*(?:'           # not followed by...
+             r'[:,;=^&|@~)\]}]|(?:' +  # characters and keywords that mean this isn't
+                                       # pattern matching (but None/True/False is ok)
+             r'|'.join(k for k in keyword.kwlist if k[0].islower()) + r')\b))',
+             bygroups(Text, Keyword), 'soft-keywords-inner'),
+        ],
+        'soft-keywords-inner': [
+            # optional `_` keyword
+            (r'(\s+)([^\n_]*)(_\b)', bygroups(Whitespace, using(this), Keyword)),
+            default('#pop')
+        ],
+        'builtins': [
+            (words((
+                '__import__', 'abs', 'aiter', 'all', 'any', 'bin', 'bool', 'bytearray',
+                'breakpoint', 'bytes', 'callable', 'chr', 'classmethod', 'compile',
+                'complex', 'delattr', 'dict', 'dir', 'divmod', 'enumerate', 'eval',
+                'filter', 'float', 'format', 'frozenset', 'getattr', 'globals',
+                'hasattr', 'hash', 'hex', 'id', 'input', 'int', 'isinstance',
+                'issubclass', 'iter', 'len', 'list', 'locals', 'map', 'max',
+                'memoryview', 'min', 'next', 'object', 'oct', 'open', 'ord', 'pow',
+                'print', 'property', 'range', 'repr', 'reversed', 'round', 'set',
+                'setattr', 'slice', 'sorted', 'staticmethod', 'str', 'sum', 'super',
+                'tuple', 'type', 'vars', 'zip'), prefix=r'(?>|[-~+/*%=<>&^|.]', Operator),
+            include('keywords'),
+            (r'(def)((?:\s|\\\s)+)', bygroups(Keyword, Whitespace), 'funcname'),
+            (r'(class)((?:\s|\\\s)+)', bygroups(Keyword, Whitespace), 'classname'),
+            (r'(from)((?:\s|\\\s)+)', bygroups(Keyword.Namespace, Whitespace),
+             'fromimport'),
+            (r'(import)((?:\s|\\\s)+)', bygroups(Keyword.Namespace, Whitespace),
+             'import'),
+            include('builtins'),
+            include('magicfuncs'),
+            include('magicvars'),
+            include('backtick'),
+            ('([rR]|[uUbB][rR]|[rR][uUbB])(""")',
+             bygroups(String.Affix, String.Double), 'tdqs'),
+            ("([rR]|[uUbB][rR]|[rR][uUbB])(''')",
+             bygroups(String.Affix, String.Single), 'tsqs'),
+            ('([rR]|[uUbB][rR]|[rR][uUbB])(")',
+             bygroups(String.Affix, String.Double), 'dqs'),
+            ("([rR]|[uUbB][rR]|[rR][uUbB])(')",
+             bygroups(String.Affix, String.Single), 'sqs'),
+            ('([uUbB]?)(""")', bygroups(String.Affix, String.Double),
+             combined('stringescape', 'tdqs')),
+            ("([uUbB]?)(''')", bygroups(String.Affix, String.Single),
+             combined('stringescape', 'tsqs')),
+            ('([uUbB]?)(")', bygroups(String.Affix, String.Double),
+             combined('stringescape', 'dqs')),
+            ("([uUbB]?)(')", bygroups(String.Affix, String.Single),
+             combined('stringescape', 'sqs')),
+            include('name'),
+            include('numbers'),
+        ],
+        'keywords': [
+            (words((
+                'assert', 'break', 'continue', 'del', 'elif', 'else', 'except',
+                'exec', 'finally', 'for', 'global', 'if', 'lambda', 'pass',
+                'print', 'raise', 'return', 'try', 'while', 'yield',
+                'yield from', 'as', 'with'), suffix=r'\b'),
+             Keyword),
+        ],
+        'builtins': [
+            (words((
+                '__import__', 'abs', 'all', 'any', 'apply', 'basestring', 'bin',
+                'bool', 'buffer', 'bytearray', 'bytes', 'callable', 'chr', 'classmethod',
+                'cmp', 'coerce', 'compile', 'complex', 'delattr', 'dict', 'dir', 'divmod',
+                'enumerate', 'eval', 'execfile', 'exit', 'file', 'filter', 'float',
+                'frozenset', 'getattr', 'globals', 'hasattr', 'hash', 'hex', 'id',
+                'input', 'int', 'intern', 'isinstance', 'issubclass', 'iter', 'len',
+                'list', 'locals', 'long', 'map', 'max', 'min', 'next', 'object',
+                'oct', 'open', 'ord', 'pow', 'property', 'range', 'raw_input', 'reduce',
+                'reload', 'repr', 'reversed', 'round', 'set', 'setattr', 'slice',
+                'sorted', 'staticmethod', 'str', 'sum', 'super', 'tuple', 'type',
+                'unichr', 'unicode', 'vars', 'xrange', 'zip'),
+                prefix=r'(?>> )(.*\n)', bygroups(Generic.Prompt, Other.Code), 'continuations'),
+            # This happens, e.g., when tracebacks are embedded in documentation;
+            # trailing whitespaces are often stripped in such contexts.
+            (r'(>>>)(\n)', bygroups(Generic.Prompt, Whitespace)),
+            (r'(\^C)?Traceback \(most recent call last\):\n', Other.Traceback, 'traceback'),
+            # SyntaxError starts with this
+            (r'  File "[^"]+", line \d+', Other.Traceback, 'traceback'),
+            (r'.*\n', Generic.Output),
+        ],
+        'continuations': [
+            (r'(\.\.\. )(.*\n)', bygroups(Generic.Prompt, Other.Code)),
+            # See above.
+            (r'(\.\.\.)(\n)', bygroups(Generic.Prompt, Whitespace)),
+            default('#pop'),
+        ],
+        'traceback': [
+            # As soon as we see a traceback, consume everything until the next
+            # >>> prompt.
+            (r'(?=>>>( |$))', Text, '#pop'),
+            (r'(KeyboardInterrupt)(\n)', bygroups(Name.Class, Whitespace)),
+            (r'.*\n', Other.Traceback),
+        ],
+    }
+
+
+class PythonConsoleLexer(DelegatingLexer):
+    """
+    For Python console output or doctests, such as:
+
+    .. sourcecode:: pycon
+
+        >>> a = 'foo'
+        >>> print(a)
+        foo
+        >>> 1 / 0
+        Traceback (most recent call last):
+          File "", line 1, in 
+        ZeroDivisionError: integer division or modulo by zero
+
+    Additional options:
+
+    `python3`
+        Use Python 3 lexer for code.  Default is ``True``.
+
+        .. versionadded:: 1.0
+        .. versionchanged:: 2.5
+           Now defaults to ``True``.
+    """
+
+    name = 'Python console session'
+    aliases = ['pycon', 'python-console']
+    mimetypes = ['text/x-python-doctest']
+    url = 'https://python.org'
+    version_added = ''
+
+    def __init__(self, **options):
+        python3 = get_bool_opt(options, 'python3', True)
+        if python3:
+            pylexer = PythonLexer
+            tblexer = PythonTracebackLexer
+        else:
+            pylexer = Python2Lexer
+            tblexer = Python2TracebackLexer
+        # We have two auxiliary lexers. Use DelegatingLexer twice with
+        # different tokens.  TODO: DelegatingLexer should support this
+        # directly, by accepting a tuplet of auxiliary lexers and a tuple of
+        # distinguishing tokens. Then we wouldn't need this intermediary
+        # class.
+        class _ReplaceInnerCode(DelegatingLexer):
+            def __init__(self, **options):
+                super().__init__(pylexer, _PythonConsoleLexerBase, Other.Code, **options)
+        super().__init__(tblexer, _ReplaceInnerCode, Other.Traceback, **options)
+
+
+class PythonTracebackLexer(RegexLexer):
+    """
+    For Python 3.x tracebacks, with support for chained exceptions.
+
+    .. versionchanged:: 2.5
+       This is now the default ``PythonTracebackLexer``.  It is still available
+       as the alias ``Python3TracebackLexer``.
+    """
+
+    name = 'Python Traceback'
+    aliases = ['pytb', 'py3tb']
+    filenames = ['*.pytb', '*.py3tb']
+    mimetypes = ['text/x-python-traceback', 'text/x-python3-traceback']
+    url = 'https://python.org'
+    version_added = '1.0'
+
+    tokens = {
+        'root': [
+            (r'\n', Whitespace),
+            (r'^(\^C)?Traceback \(most recent call last\):\n', Generic.Traceback, 'intb'),
+            (r'^During handling of the above exception, another '
+             r'exception occurred:\n\n', Generic.Traceback),
+            (r'^The above exception was the direct cause of the '
+             r'following exception:\n\n', Generic.Traceback),
+            (r'^(?=  File "[^"]+", line \d+)', Generic.Traceback, 'intb'),
+            (r'^.*\n', Other),
+        ],
+        'intb': [
+            (r'^(  File )("[^"]+")(, line )(\d+)(, in )(.+)(\n)',
+             bygroups(Text, Name.Builtin, Text, Number, Text, Name, Whitespace)),
+            (r'^(  File )("[^"]+")(, line )(\d+)(\n)',
+             bygroups(Text, Name.Builtin, Text, Number, Whitespace)),
+            (r'^(    )(.+)(\n)',
+             bygroups(Whitespace, using(PythonLexer), Whitespace), 'markers'),
+            (r'^([ \t]*)(\.\.\.)(\n)',
+             bygroups(Whitespace, Comment, Whitespace)),  # for doctests...
+            (r'^([^:]+)(: )(.+)(\n)',
+             bygroups(Generic.Error, Text, Name, Whitespace), '#pop'),
+            (r'^([a-zA-Z_][\w.]*)(:?\n)',
+             bygroups(Generic.Error, Whitespace), '#pop'),
+            default('#pop'),
+        ],
+        'markers': [
+            # Either `PEP 657 `
+            # error locations in Python 3.11+, or single-caret markers
+            # for syntax errors before that.
+            (r'^( {4,})([~^]+)(\n)',
+             bygroups(Whitespace, Punctuation.Marker, Whitespace),
+             '#pop'),
+            default('#pop'),
+        ],
+    }
+
+
+Python3TracebackLexer = PythonTracebackLexer
+
+
+class Python2TracebackLexer(RegexLexer):
+    """
+    For Python tracebacks.
+
+    .. versionchanged:: 2.5
+       This class has been renamed from ``PythonTracebackLexer``.
+       ``PythonTracebackLexer`` now refers to the Python 3 variant.
+    """
+
+    name = 'Python 2.x Traceback'
+    aliases = ['py2tb']
+    filenames = ['*.py2tb']
+    mimetypes = ['text/x-python2-traceback']
+    url = 'https://python.org'
+    version_added = '0.7'
+
+    tokens = {
+        'root': [
+            # Cover both (most recent call last) and (innermost last)
+            # The optional ^C allows us to catch keyboard interrupt signals.
+            (r'^(\^C)?(Traceback.*\n)',
+             bygroups(Text, Generic.Traceback), 'intb'),
+            # SyntaxError starts with this.
+            (r'^(?=  File "[^"]+", line \d+)', Generic.Traceback, 'intb'),
+            (r'^.*\n', Other),
+        ],
+        'intb': [
+            (r'^(  File )("[^"]+")(, line )(\d+)(, in )(.+)(\n)',
+             bygroups(Text, Name.Builtin, Text, Number, Text, Name, Whitespace)),
+            (r'^(  File )("[^"]+")(, line )(\d+)(\n)',
+             bygroups(Text, Name.Builtin, Text, Number, Whitespace)),
+            (r'^(    )(.+)(\n)',
+             bygroups(Text, using(Python2Lexer), Whitespace), 'marker'),
+            (r'^([ \t]*)(\.\.\.)(\n)',
+             bygroups(Text, Comment, Whitespace)),  # for doctests...
+            (r'^([^:]+)(: )(.+)(\n)',
+             bygroups(Generic.Error, Text, Name, Whitespace), '#pop'),
+            (r'^([a-zA-Z_]\w*)(:?\n)',
+             bygroups(Generic.Error, Whitespace), '#pop')
+        ],
+        'marker': [
+            # For syntax errors.
+            (r'( {4,})(\^)', bygroups(Text, Punctuation.Marker), '#pop'),
+            default('#pop'),
+        ],
+    }
+
+
+class CythonLexer(RegexLexer):
+    """
+    For Pyrex and Cython source code.
+    """
+
+    name = 'Cython'
+    url = 'https://cython.org'
+    aliases = ['cython', 'pyx', 'pyrex']
+    filenames = ['*.pyx', '*.pxd', '*.pxi']
+    mimetypes = ['text/x-cython', 'application/x-cython']
+    version_added = '1.1'
+
+    tokens = {
+        'root': [
+            (r'\n', Whitespace),
+            (r'^(\s*)("""(?:.|\n)*?""")', bygroups(Whitespace, String.Doc)),
+            (r"^(\s*)('''(?:.|\n)*?''')", bygroups(Whitespace, String.Doc)),
+            (r'[^\S\n]+', Text),
+            (r'#.*$', Comment),
+            (r'[]{}:(),;[]', Punctuation),
+            (r'\\\n', Whitespace),
+            (r'\\', Text),
+            (r'(in|is|and|or|not)\b', Operator.Word),
+            (r'(<)([a-zA-Z0-9.?]+)(>)',
+             bygroups(Punctuation, Keyword.Type, Punctuation)),
+            (r'!=|==|<<|>>|[-~+/*%=<>&^|.?]', Operator),
+            (r'(from)(\d+)(<=)(\s+)(<)(\d+)(:)',
+             bygroups(Keyword, Number.Integer, Operator, Whitespace, Operator,
+                      Name, Punctuation)),
+            include('keywords'),
+            (r'(def|property)(\s+)', bygroups(Keyword, Whitespace), 'funcname'),
+            (r'(cp?def)(\s+)', bygroups(Keyword, Whitespace), 'cdef'),
+            # (should actually start a block with only cdefs)
+            (r'(cdef)(:)', bygroups(Keyword, Punctuation)),
+            (r'(class|cppclass|struct)(\s+)', bygroups(Keyword, Whitespace), 'classname'),
+            (r'(from)(\s+)', bygroups(Keyword, Whitespace), 'fromimport'),
+            (r'(c?import)(\s+)', bygroups(Keyword, Whitespace), 'import'),
+            include('builtins'),
+            include('backtick'),
+            ('(?:[rR]|[uU][rR]|[rR][uU])"""', String, 'tdqs'),
+            ("(?:[rR]|[uU][rR]|[rR][uU])'''", String, 'tsqs'),
+            ('(?:[rR]|[uU][rR]|[rR][uU])"', String, 'dqs'),
+            ("(?:[rR]|[uU][rR]|[rR][uU])'", String, 'sqs'),
+            ('[uU]?"""', String, combined('stringescape', 'tdqs')),
+            ("[uU]?'''", String, combined('stringescape', 'tsqs')),
+            ('[uU]?"', String, combined('stringescape', 'dqs')),
+            ("[uU]?'", String, combined('stringescape', 'sqs')),
+            include('name'),
+            include('numbers'),
+        ],
+        'keywords': [
+            (words((
+                'assert', 'async', 'await', 'break', 'by', 'continue', 'ctypedef', 'del',
+                'elif', 'else', 'except', 'except?', 'exec', 'finally', 'for', 'fused', 'gil',
+                'global', 'if', 'include', 'lambda', 'namespace', 'new', 'noexcept','nogil',
+                'pass', 'print', 'raise', 'return', 'try', 'while', 'yield', 'as', 'with'),
+             suffix=r'\b'),
+             Keyword),
+             (words(('True', 'False', 'None', 'NULL'), suffix=r'\b'), Keyword.Constant),
+            (r'(DEF|IF|ELIF|ELSE)\b', Comment.Preproc),
+        ],
+        'builtins': [
+            (words((
+                '__import__', 'abs', 'all', 'any', 'apply', 'basestring', 'bin', 'bint',
+                'bool', 'buffer', 'bytearray', 'bytes', 'callable', 'char', 'chr',
+                'classmethod', 'cmp', 'coerce', 'compile', 'complex', 'delattr',
+                'dict', 'dir', 'divmod', 'double', 'enumerate', 'eval', 'execfile', 'exit',
+                'file', 'filter', 'float', 'frozenset', 'getattr', 'globals',
+                'hasattr', 'hash', 'hex', 'id', 'input', 'int', 'intern', 'isinstance',
+                'issubclass', 'iter', 'len', 'list', 'locals', 'long', 'map', 'max',
+                'min', 'next', 'object', 'oct', 'open', 'ord', 'pow', 'property',
+                'Py_ssize_t', 'range', 'raw_input', 'reduce', 'reload', 'repr', 'reversed',
+                'round', 'set', 'setattr', 'size_t', 'slice', 'sorted', 'staticmethod',
+                'ssize_t', 'str', 'sum', 'super', 'tuple', 'type', 'unichr', 'unicode',
+                'unsigned', 'vars', 'xrange', 'zip'), prefix=r'(??/\\:']?:)(\s*)(\{)",
+             bygroups(Name.Function, Whitespace, Operator, Whitespace, Punctuation),
+             "functions"),
+            # Variable Names
+            (r"([.]?[a-zA-Z][\w.]*)(\s*)([-.~=!@#$%^&*_+|,<>?/\\:']?:)",
+             bygroups(Name.Variable, Whitespace, Operator)),
+            # Functions
+            (r"\{", Punctuation, "functions"),
+            # Parentheses
+            (r"\(", Punctuation, "parentheses"),
+            # Brackets
+            (r"\[", Punctuation, "brackets"),
+            # Errors
+            (r"'`([a-zA-Z][\w.]*)?", Name.Exception),
+            # File Symbols
+            (r"`:([a-zA-Z/][\w./]*)?", String.Symbol),
+            # Symbols
+            (r"`([a-zA-Z][\w.]*)?", String.Symbol),
+            # Numbers
+            include("numbers"),
+            # Variable Names
+            (r"[a-zA-Z][\w.]*", Name),
+            # Operators
+            (r"[-=+*#$%@!~^&:.,<>'\\|/?_]", Operator),
+            # Punctuation
+            (r";", Punctuation),
+        ],
+        "functions": [
+            include("root"),
+            (r"\}", Punctuation, "#pop"),
+        ],
+        "parentheses": [
+            include("root"),
+            (r"\)", Punctuation, "#pop"),
+        ],
+        "brackets": [
+            include("root"),
+            (r"\]", Punctuation, "#pop"),
+        ],
+        "numbers": [
+            # Binary Values
+            (r"[01]+b", Number.Bin),
+            # Nulls/Infinities
+            (r"0[nNwW][cefghijmndzuvtp]?", Number),
+            # Timestamps
+            ((r"(?:[0-9]{4}[.][0-9]{2}[.][0-9]{2}|[0-9]+)"
+              "D(?:[0-9](?:[0-9](?::[0-9]{2}"
+              "(?::[0-9]{2}(?:[.][0-9]*)?)?)?)?)?"), Literal.Date),
+            # Datetimes
+            ((r"[0-9]{4}[.][0-9]{2}"
+              "(?:m|[.][0-9]{2}(?:T(?:[0-9]{2}:[0-9]{2}"
+              "(?::[0-9]{2}(?:[.][0-9]*)?)?)?)?)"), Literal.Date),
+            # Times
+            (r"[0-9]{2}:[0-9]{2}(?::[0-9]{2}(?:[.][0-9]{1,3})?)?",
+             Literal.Date),
+            # GUIDs
+            (r"[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}",
+             Number.Hex),
+            # Byte Vectors
+            (r"0x[0-9a-fA-F]+", Number.Hex),
+            # Floats
+            (r"([0-9]*[.]?[0-9]+|[0-9]+[.]?[0-9]*)[eE][+-]?[0-9]+[ef]?",
+             Number.Float),
+            (r"([0-9]*[.][0-9]+|[0-9]+[.][0-9]*)[ef]?", Number.Float),
+            (r"[0-9]+[ef]", Number.Float),
+            # Characters
+            (r"[0-9]+c", Number),
+            # Integers
+            (r"[0-9]+[ihtuv]", Number.Integer),
+            # Long Integers
+            (r"[0-9]+[jnp]?", Number.Integer.Long),
+        ],
+        "comments": [
+            (r"[^\\]+", Comment.Multiline),
+            (r"^\\", Comment.Multiline, "#pop"),
+            (r"\\", Comment.Multiline),
+        ],
+        "strings": [
+            (r'[^"\\]+', String.Double),
+            (r"\\.", String.Escape),
+            (r'"', String.Double, "#pop"),
+        ],
+    }
+
+
+class QLexer(KLexer):
+    """
+    For `Q `_ source code.
+    """
+
+    name = "Q"
+    aliases = ["q"]
+    filenames = ["*.q"]
+    version_added = '2.12'
+
+    tokens = {
+        "root": [
+            (words(("aj", "aj0", "ajf", "ajf0", "all", "and", "any", "asc",
+                    "asof", "attr", "avgs", "ceiling", "cols", "count", "cross",
+                    "csv", "cut", "deltas", "desc", "differ", "distinct", "dsave",
+                    "each", "ej", "ema", "eval", "except", "fby", "fills", "first",
+                    "fkeys", "flip", "floor", "get", "group", "gtime", "hclose",
+                    "hcount", "hdel", "hsym", "iasc", "idesc", "ij", "ijf",
+                    "inter", "inv", "key", "keys", "lj", "ljf", "load", "lower",
+                    "lsq", "ltime", "ltrim", "mavg", "maxs", "mcount", "md5",
+                    "mdev", "med", "meta", "mins", "mmax", "mmin", "mmu", "mod",
+                    "msum", "neg", "next", "not", "null", "or", "over", "parse",
+                    "peach", "pj", "prds", "prior", "prev", "rand", "rank", "ratios",
+                    "raze", "read0", "read1", "reciprocal", "reval", "reverse",
+                    "rload", "rotate", "rsave", "rtrim", "save", "scan", "scov",
+                    "sdev", "set", "show", "signum", "ssr", "string", "sublist",
+                    "sums", "sv", "svar", "system", "tables", "til", "trim", "txf",
+                    "type", "uj", "ujf", "ungroup", "union", "upper", "upsert",
+                    "value", "view", "views", "vs", "where", "wj", "wj1", "ww",
+                    "xasc", "xbar", "xcol", "xcols", "xdesc", "xgroup", "xkey",
+                    "xlog", "xprev", "xrank"),
+                    suffix=r"\b"), Name.Builtin,
+            ),
+            inherit,
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/qlik.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/qlik.py
new file mode 100644
index 0000000000000000000000000000000000000000..6972ed9d03bf447f6215fbba65e96eb4455a8248
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/qlik.py
@@ -0,0 +1,117 @@
+"""
+    pygments.lexers.qlik
+    ~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for the qlik scripting language
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, include, bygroups, words
+from pygments.token import Comment, Keyword, Name, Number, Operator, \
+    Punctuation, String, Text
+from pygments.lexers._qlik_builtins import OPERATORS_LIST, STATEMENT_LIST, \
+    SCRIPT_FUNCTIONS, CONSTANT_LIST
+
+__all__ = ["QlikLexer"]
+
+
+class QlikLexer(RegexLexer):
+    """
+    Lexer for qlik code, including .qvs files
+    """
+
+    name = "Qlik"
+    aliases = ["qlik", "qlikview", "qliksense", "qlikscript"]
+    filenames = ["*.qvs", "*.qvw"]
+    url = "https://qlik.com"
+    version_added = '2.12'
+
+    flags = re.IGNORECASE
+
+    tokens = {
+        # Handle multi-line comments
+        "comment": [
+            (r"\*/", Comment.Multiline, "#pop"),
+            (r"[^*]+", Comment.Multiline),
+        ],
+        # Handle numbers
+        "numerics": [
+            (r"\b\d+\.\d+(e\d+)?[fd]?\b", Number.Float),
+            (r"\b\d+\b", Number.Integer),
+        ],
+        # Handle variable names in things
+        "interp": [
+            (
+                r"(\$\()(\w+)(\))",
+                bygroups(String.Interpol, Name.Variable, String.Interpol),
+            ),
+        ],
+        # Handle strings
+        "string": [
+            (r"'", String, "#pop"),
+            include("interp"),
+            (r"[^'$]+", String),
+            (r"\$", String),
+        ],
+        #
+        "assignment": [
+            (r";", Punctuation, "#pop"),
+            include("root"),
+        ],
+        "field_name_quote": [
+            (r'"', String.Symbol, "#pop"),
+            include("interp"),
+            (r"[^\"$]+", String.Symbol),
+            (r"\$", String.Symbol),
+        ],
+        "field_name_bracket": [
+            (r"\]", String.Symbol, "#pop"),
+            include("interp"),
+            (r"[^\]$]+", String.Symbol),
+            (r"\$", String.Symbol),
+        ],
+        "function": [(r"\)", Punctuation, "#pop"), include("root")],
+        "root": [
+            # Whitespace and comments
+            (r"\s+", Text.Whitespace),
+            (r"/\*", Comment.Multiline, "comment"),
+            (r"//.*\n", Comment.Single),
+            # variable assignment
+            (r"(let|set)(\s+)", bygroups(Keyword.Declaration, Text.Whitespace),
+             "assignment"),
+            # Word operators
+            (words(OPERATORS_LIST["words"], prefix=r"\b", suffix=r"\b"),
+             Operator.Word),
+            # Statements
+            (words(STATEMENT_LIST, suffix=r"\b"), Keyword),
+            # Table names
+            (r"[a-z]\w*:", Keyword.Declaration),
+            # Constants
+            (words(CONSTANT_LIST, suffix=r"\b"), Keyword.Constant),
+            # Functions
+            (words(SCRIPT_FUNCTIONS, suffix=r"(?=\s*\()"), Name.Builtin,
+             "function"),
+            # interpolation - e.g. $(variableName)
+            include("interp"),
+            # Quotes denote a field/file name
+            (r'"', String.Symbol, "field_name_quote"),
+            # Square brackets denote a field/file name
+            (r"\[", String.Symbol, "field_name_bracket"),
+            # Strings
+            (r"'", String, "string"),
+            # Numbers
+            include("numerics"),
+            # Operator symbols
+            (words(OPERATORS_LIST["symbols"]), Operator),
+            # Strings denoted by single quotes
+            (r"'.+?'", String),
+            # Words as text
+            (r"\b\w+\b", Text),
+            # Basic punctuation
+            (r"[,;.()\\/]", Punctuation),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/qvt.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/qvt.py
new file mode 100644
index 0000000000000000000000000000000000000000..02d6fcf7d21003379377858820df83389a2b21c5
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/qvt.py
@@ -0,0 +1,153 @@
+"""
+    pygments.lexers.qvt
+    ~~~~~~~~~~~~~~~~~~~
+
+    Lexer for QVT Operational language.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, bygroups, include, combined, default, \
+    words
+from pygments.token import Text, Comment, Operator, Keyword, Punctuation, \
+    Name, String, Number
+
+__all__ = ['QVToLexer']
+
+
+class QVToLexer(RegexLexer):
+    """
+    For the QVT Operational Mapping language.
+
+    Reference for implementing this: «Meta Object Facility (MOF) 2.0
+    Query/View/Transformation Specification», Version 1.1 - January 2011
+    (https://www.omg.org/spec/QVT/1.1/), see §8.4, «Concrete Syntax» in
+    particular.
+
+    Notable tokens assignments:
+
+    - Name.Class is assigned to the identifier following any of the following
+      keywords: metamodel, class, exception, primitive, enum, transformation
+      or library
+
+    - Name.Function is assigned to the names of mappings and queries
+
+    - Name.Builtin.Pseudo is assigned to the pre-defined variables 'this',
+      'self' and 'result'.
+    """
+    # With obvious borrowings & inspiration from the Java, Python and C lexers
+
+    name = 'QVTO'
+    aliases = ['qvto', 'qvt']
+    filenames = ['*.qvto']
+    url = 'https://www.omg.org/spec/QVT/1.1'
+    version_added = ''
+
+    tokens = {
+        'root': [
+            (r'\n', Text),
+            (r'[^\S\n]+', Text),
+            (r'(--|//)(\s*)(directive:)?(.*)$',
+             bygroups(Comment, Comment, Comment.Preproc, Comment)),
+            # Uncomment the following if you want to distinguish between
+            # '/*' and '/**', à la javadoc
+            # (r'/[*]{2}(.|\n)*?[*]/', Comment.Multiline),
+            (r'/[*](.|\n)*?[*]/', Comment.Multiline),
+            (r'\\\n', Text),
+            (r'(and|not|or|xor|##?)\b', Operator.Word),
+            (r'(:{1,2}=|[-+]=)\b', Operator.Word),
+            (r'(@|<<|>>)\b', Keyword),  # stereotypes
+            (r'!=|<>|==|=|!->|->|>=|<=|[.]{3}|[+/*%=<>&|.~]', Operator),
+            (r'[]{}:(),;[]', Punctuation),
+            (r'(true|false|unlimited|null)\b', Keyword.Constant),
+            (r'(this|self|result)\b', Name.Builtin.Pseudo),
+            (r'(var)\b', Keyword.Declaration),
+            (r'(from|import)\b', Keyword.Namespace, 'fromimport'),
+            (r'(metamodel|class|exception|primitive|enum|transformation|'
+             r'library)(\s+)(\w+)',
+             bygroups(Keyword.Word, Text, Name.Class)),
+            (r'(exception)(\s+)(\w+)',
+             bygroups(Keyword.Word, Text, Name.Exception)),
+            (r'(main)\b', Name.Function),
+            (r'(mapping|helper|query)(\s+)',
+             bygroups(Keyword.Declaration, Text), 'operation'),
+            (r'(assert)(\s+)\b', bygroups(Keyword, Text), 'assert'),
+            (r'(Bag|Collection|Dict|OrderedSet|Sequence|Set|Tuple|List)\b',
+             Keyword.Type),
+            include('keywords'),
+            ('"', String, combined('stringescape', 'dqs')),
+            ("'", String, combined('stringescape', 'sqs')),
+            include('name'),
+            include('numbers'),
+            # (r'([a-zA-Z_]\w*)(::)([a-zA-Z_]\w*)',
+            # bygroups(Text, Text, Text)),
+        ],
+
+        'fromimport': [
+            (r'(?:[ \t]|\\\n)+', Text),
+            (r'[a-zA-Z_][\w.]*', Name.Namespace),
+            default('#pop'),
+        ],
+
+        'operation': [
+            (r'::', Text),
+            (r'(.*::)([a-zA-Z_]\w*)([ \t]*)(\()',
+             bygroups(Text, Name.Function, Text, Punctuation), '#pop')
+        ],
+
+        'assert': [
+            (r'(warning|error|fatal)\b', Keyword, '#pop'),
+            default('#pop'),  # all else: go back
+        ],
+
+        'keywords': [
+            (words((
+                'abstract', 'access', 'any', 'assert', 'blackbox', 'break',
+                'case', 'collect', 'collectNested', 'collectOne', 'collectselect',
+                'collectselectOne', 'composes', 'compute', 'configuration',
+                'constructor', 'continue', 'datatype', 'default', 'derived',
+                'disjuncts', 'do', 'elif', 'else', 'end', 'endif', 'except',
+                'exists', 'extends', 'forAll', 'forEach', 'forOne', 'from', 'if',
+                'implies', 'in', 'inherits', 'init', 'inout', 'intermediate',
+                'invresolve', 'invresolveIn', 'invresolveone', 'invresolveoneIn',
+                'isUnique', 'iterate', 'late', 'let', 'literal', 'log', 'map',
+                'merges', 'modeltype', 'new', 'object', 'one', 'ordered', 'out',
+                'package', 'population', 'property', 'raise', 'readonly',
+                'references', 'refines', 'reject', 'resolve', 'resolveIn',
+                'resolveone', 'resolveoneIn', 'return', 'select', 'selectOne',
+                'sortedBy', 'static', 'switch', 'tag', 'then', 'try', 'typedef',
+                'unlimited', 'uses', 'when', 'where', 'while', 'with', 'xcollect',
+                'xmap', 'xselect'), suffix=r'\b'), Keyword),
+        ],
+
+        # There is no need to distinguish between String.Single and
+        # String.Double: 'strings' is factorised for 'dqs' and 'sqs'
+        'strings': [
+            (r'[^\\\'"\n]+', String),
+            # quotes, percents and backslashes must be parsed one at a time
+            (r'[\'"\\]', String),
+        ],
+        'stringescape': [
+            (r'\\([\\btnfr"\']|u[0-3][0-7]{2}|u[0-7]{1,2})', String.Escape)
+        ],
+        'dqs': [  # double-quoted string
+            (r'"', String, '#pop'),
+            (r'\\\\|\\"', String.Escape),
+            include('strings')
+        ],
+        'sqs': [  # single-quoted string
+            (r"'", String, '#pop'),
+            (r"\\\\|\\'", String.Escape),
+            include('strings')
+        ],
+        'name': [
+            (r'[a-zA-Z_]\w*', Name),
+        ],
+        # numbers: excerpt taken from the python lexer
+        'numbers': [
+            (r'(\d+\.\d*|\d*\.\d+)([eE][+-]?[0-9]+)?', Number.Float),
+            (r'\d+[eE][+-]?[0-9]+', Number.Float),
+            (r'\d+', Number.Integer)
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/r.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/r.py
new file mode 100644
index 0000000000000000000000000000000000000000..7dcc148a9cb52683e928a307444dd5bfd311a45f
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/r.py
@@ -0,0 +1,196 @@
+"""
+    pygments.lexers.r
+    ~~~~~~~~~~~~~~~~~
+
+    Lexers for the R/S languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import Lexer, RegexLexer, include, do_insertions
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation, Generic, Whitespace
+
+__all__ = ['RConsoleLexer', 'SLexer', 'RdLexer']
+
+
+line_re  = re.compile('.*?\n')
+
+
+class RConsoleLexer(Lexer):
+    """
+    For R console transcripts or R CMD BATCH output files.
+    """
+
+    name = 'RConsole'
+    aliases = ['rconsole', 'rout']
+    filenames = ['*.Rout']
+    url = 'https://www.r-project.org'
+    version_added = ''
+    _example = "rconsole/r-console-transcript.Rout"
+
+    def get_tokens_unprocessed(self, text):
+        slexer = SLexer(**self.options)
+
+        current_code_block = ''
+        insertions = []
+
+        for match in line_re.finditer(text):
+            line = match.group()
+            if line.startswith('>') or line.startswith('+'):
+                # Colorize the prompt as such,
+                # then put rest of line into current_code_block
+                insertions.append((len(current_code_block),
+                                   [(0, Generic.Prompt, line[:2])]))
+                current_code_block += line[2:]
+            else:
+                # We have reached a non-prompt line!
+                # If we have stored prompt lines, need to process them first.
+                if current_code_block:
+                    # Weave together the prompts and highlight code.
+                    yield from do_insertions(
+                        insertions, slexer.get_tokens_unprocessed(current_code_block))
+                    # Reset vars for next code block.
+                    current_code_block = ''
+                    insertions = []
+                # Now process the actual line itself, this is output from R.
+                yield match.start(), Generic.Output, line
+
+        # If we happen to end on a code block with nothing after it, need to
+        # process the last code block. This is neither elegant nor DRY so
+        # should be changed.
+        if current_code_block:
+            yield from do_insertions(
+                insertions, slexer.get_tokens_unprocessed(current_code_block))
+
+
+class SLexer(RegexLexer):
+    """
+    For S, S-plus, and R source code.
+    """
+
+    name = 'S'
+    aliases = ['splus', 's', 'r']
+    filenames = ['*.S', '*.R', '.Rhistory', '.Rprofile', '.Renviron']
+    mimetypes = ['text/S-plus', 'text/S', 'text/x-r-source', 'text/x-r',
+                 'text/x-R', 'text/x-r-history', 'text/x-r-profile']
+    url = 'https://www.r-project.org'
+    version_added = '0.10'
+
+    valid_name = r'`[^`\\]*(?:\\.[^`\\]*)*`|(?:[a-zA-Z]|\.[A-Za-z_.])[\w.]*|\.'
+    tokens = {
+        'comments': [
+            (r'#.*$', Comment.Single),
+        ],
+        'valid_name': [
+            (valid_name, Name),
+        ],
+        'function_name': [
+            (rf'({valid_name})\s*(?=\()', Name.Function),
+        ],
+        'punctuation': [
+            (r'\[{1,2}|\]{1,2}|\(|\)|;|,', Punctuation),
+        ],
+        'keywords': [
+            (r'(if|else|for|while|repeat|in|next|break|return|switch|function)'
+             r'(?![\w.])',
+             Keyword.Reserved),
+        ],
+        'operators': [
+            (r'<>?|-|==|<=|>=|\|>|<|>|&&?|!=|\|\|?|\?', Operator),
+            (r'\*|\+|\^|/|!|%[^%]*%|=|~|\$|@|:{1,3}', Operator),
+        ],
+        'builtin_symbols': [
+            (r'(NULL|NA(_(integer|real|complex|character)_)?|'
+             r'letters|LETTERS|Inf|TRUE|FALSE|NaN|pi|\.\.(\.|[0-9]+))'
+             r'(?![\w.])',
+             Keyword.Constant),
+            (r'(T|F)\b', Name.Builtin.Pseudo),
+        ],
+        'numbers': [
+            # hex number
+            (r'0[xX][a-fA-F0-9]+([pP][0-9]+)?[Li]?', Number.Hex),
+            # decimal number
+            (r'[+-]?([0-9]+(\.[0-9]+)?|\.[0-9]+|\.)([eE][+-]?[0-9]+)?[Li]?',
+             Number),
+        ],
+        'statements': [
+            include('comments'),
+            # whitespaces
+            (r'\s+', Whitespace),
+            (r'\'', String, 'string_squote'),
+            (r'\"', String, 'string_dquote'),
+            include('builtin_symbols'),
+            include('keywords'),
+            include('function_name'),
+            include('valid_name'),
+            include('numbers'),
+            include('punctuation'),
+            include('operators'),
+        ],
+        'root': [
+            # calls:
+            include('statements'),
+            # blocks:
+            (r'\{|\}', Punctuation),
+            # (r'\{', Punctuation, 'block'),
+            (r'.', Text),
+        ],
+        # 'block': [
+        #    include('statements'),
+        #    ('\{', Punctuation, '#push'),
+        #    ('\}', Punctuation, '#pop')
+        # ],
+        'string_squote': [
+            (r'([^\'\\]|\\.)*\'', String, '#pop'),
+        ],
+        'string_dquote': [
+            (r'([^"\\]|\\.)*"', String, '#pop'),
+        ],
+    }
+
+    def analyse_text(text):
+        if re.search(r'[a-z0-9_\])\s]<-(?!-)', text):
+            return 0.11
+
+
+class RdLexer(RegexLexer):
+    """
+    Pygments Lexer for R documentation (Rd) files
+
+    This is a very minimal implementation, highlighting little more
+    than the macros. A description of Rd syntax is found in `Writing R
+    Extensions `_
+    and `Parsing Rd files `_.
+    """
+    name = 'Rd'
+    aliases = ['rd']
+    filenames = ['*.Rd']
+    mimetypes = ['text/x-r-doc']
+    url = 'http://cran.r-project.org/doc/manuals/R-exts.html'
+    version_added = '1.6'
+
+    # To account for verbatim / LaTeX-like / and R-like areas
+    # would require parsing.
+    tokens = {
+        'root': [
+            # catch escaped brackets and percent sign
+            (r'\\[\\{}%]', String.Escape),
+            # comments
+            (r'%.*$', Comment),
+            # special macros with no arguments
+            (r'\\(?:cr|l?dots|R|tab)\b', Keyword.Constant),
+            # macros
+            (r'\\[a-zA-Z]+\b', Keyword),
+            # special preprocessor macros
+            (r'^\s*#(?:ifn?def|endif).*\b', Comment.Preproc),
+            # non-escaped brackets
+            (r'[{}]', Name.Builtin),
+            # everything else
+            (r'[^\\%\n{}]+', Text),
+            (r'.', Text),
+        ]
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rdf.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rdf.py
new file mode 100644
index 0000000000000000000000000000000000000000..f2ecf7a11f3072e3f009c22ebd0808905e2fbbcf
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rdf.py
@@ -0,0 +1,468 @@
+"""
+    pygments.lexers.rdf
+    ~~~~~~~~~~~~~~~~~~~
+
+    Lexers for semantic web and RDF query languages and markup.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, bygroups, default
+from pygments.token import Keyword, Punctuation, String, Number, Operator, \
+    Generic, Whitespace, Name, Literal, Comment, Text
+
+__all__ = ['SparqlLexer', 'TurtleLexer', 'ShExCLexer']
+
+
+class SparqlLexer(RegexLexer):
+    """
+    Lexer for SPARQL query language.
+    """
+    name = 'SPARQL'
+    aliases = ['sparql']
+    filenames = ['*.rq', '*.sparql']
+    mimetypes = ['application/sparql-query']
+    url = 'https://www.w3.org/TR/sparql11-query'
+    version_added = '2.0'
+
+    # character group definitions ::
+
+    PN_CHARS_BASE_GRP = ('a-zA-Z'
+                         '\u00c0-\u00d6'
+                         '\u00d8-\u00f6'
+                         '\u00f8-\u02ff'
+                         '\u0370-\u037d'
+                         '\u037f-\u1fff'
+                         '\u200c-\u200d'
+                         '\u2070-\u218f'
+                         '\u2c00-\u2fef'
+                         '\u3001-\ud7ff'
+                         '\uf900-\ufdcf'
+                         '\ufdf0-\ufffd')
+
+    PN_CHARS_U_GRP = (PN_CHARS_BASE_GRP + '_')
+
+    PN_CHARS_GRP = (PN_CHARS_U_GRP +
+                    r'\-' +
+                    r'0-9' +
+                    '\u00b7' +
+                    '\u0300-\u036f' +
+                    '\u203f-\u2040')
+
+    HEX_GRP = '0-9A-Fa-f'
+
+    PN_LOCAL_ESC_CHARS_GRP = r' _~.\-!$&"()*+,;=/?#@%'
+
+    # terminal productions ::
+
+    PN_CHARS_BASE = '[' + PN_CHARS_BASE_GRP + ']'
+
+    PN_CHARS_U = '[' + PN_CHARS_U_GRP + ']'
+
+    PN_CHARS = '[' + PN_CHARS_GRP + ']'
+
+    HEX = '[' + HEX_GRP + ']'
+
+    PN_LOCAL_ESC_CHARS = '[' + PN_LOCAL_ESC_CHARS_GRP + ']'
+
+    IRIREF = r'<(?:[^<>"{}|^`\\\x00-\x20])*>'
+
+    BLANK_NODE_LABEL = '_:[0-9' + PN_CHARS_U_GRP + '](?:[' + PN_CHARS_GRP + \
+                       '.]*' + PN_CHARS + ')?'
+
+    PN_PREFIX = PN_CHARS_BASE + '(?:[' + PN_CHARS_GRP + '.]*' + PN_CHARS + ')?'
+
+    VARNAME = '[0-9' + PN_CHARS_U_GRP + '][' + PN_CHARS_U_GRP + \
+              '0-9\u00b7\u0300-\u036f\u203f-\u2040]*'
+
+    PERCENT = '%' + HEX + HEX
+
+    PN_LOCAL_ESC = r'\\' + PN_LOCAL_ESC_CHARS
+
+    PLX = '(?:' + PERCENT + ')|(?:' + PN_LOCAL_ESC + ')'
+
+    PN_LOCAL = ('(?:[' + PN_CHARS_U_GRP + ':0-9' + ']|' + PLX + ')' +
+                '(?:(?:[' + PN_CHARS_GRP + '.:]|' + PLX + ')*(?:[' +
+                PN_CHARS_GRP + ':]|' + PLX + '))?')
+
+    EXPONENT = r'[eE][+-]?\d+'
+
+    # Lexer token definitions ::
+
+    tokens = {
+        'root': [
+            (r'\s+', Text),
+            # keywords ::
+            (r'(?i)(select|construct|describe|ask|where|filter|group\s+by|minus|'
+             r'distinct|reduced|from\s+named|from|order\s+by|desc|asc|limit|'
+             r'offset|values|bindings|load|into|clear|drop|create|add|move|copy|'
+             r'insert\s+data|delete\s+data|delete\s+where|with|delete|insert|'
+             r'using\s+named|using|graph|default|named|all|optional|service|'
+             r'silent|bind|undef|union|not\s+in|in|as|having|to|prefix|base)\b', Keyword),
+            (r'(a)\b', Keyword),
+            # IRIs ::
+            ('(' + IRIREF + ')', Name.Label),
+            # blank nodes ::
+            ('(' + BLANK_NODE_LABEL + ')', Name.Label),
+            #  # variables ::
+            ('[?$]' + VARNAME, Name.Variable),
+            # prefixed names ::
+            (r'(' + PN_PREFIX + r')?(\:)(' + PN_LOCAL + r')?',
+             bygroups(Name.Namespace, Punctuation, Name.Tag)),
+            # function names ::
+            (r'(?i)(str|lang|langmatches|datatype|bound|iri|uri|bnode|rand|abs|'
+             r'ceil|floor|round|concat|strlen|ucase|lcase|encode_for_uri|'
+             r'contains|strstarts|strends|strbefore|strafter|year|month|day|'
+             r'hours|minutes|seconds|timezone|tz|now|uuid|struuid|md5|sha1|sha256|sha384|'
+             r'sha512|coalesce|if|strlang|strdt|sameterm|isiri|isuri|isblank|'
+             r'isliteral|isnumeric|regex|substr|replace|exists|not\s+exists|'
+             r'count|sum|min|max|avg|sample|group_concat|separator)\b',
+             Name.Function),
+            # boolean literals ::
+            (r'(true|false)', Keyword.Constant),
+            # double literals ::
+            (r'[+\-]?(\d+\.\d*' + EXPONENT + r'|\.?\d+' + EXPONENT + ')', Number.Float),
+            # decimal literals ::
+            (r'[+\-]?(\d+\.\d*|\.\d+)', Number.Float),
+            # integer literals ::
+            (r'[+\-]?\d+', Number.Integer),
+            # operators ::
+            (r'(\|\||&&|=|\*|\-|\+|/|!=|<=|>=|!|<|>)', Operator),
+            # punctuation characters ::
+            (r'[(){}.;,:^\[\]]', Punctuation),
+            # line comments ::
+            (r'#[^\n]*', Comment),
+            # strings ::
+            (r'"""', String, 'triple-double-quoted-string'),
+            (r'"', String, 'single-double-quoted-string'),
+            (r"'''", String, 'triple-single-quoted-string'),
+            (r"'", String, 'single-single-quoted-string'),
+        ],
+        'triple-double-quoted-string': [
+            (r'"""', String, 'end-of-string'),
+            (r'[^\\]+', String),
+            (r'\\', String, 'string-escape'),
+        ],
+        'single-double-quoted-string': [
+            (r'"', String, 'end-of-string'),
+            (r'[^"\\\n]+', String),
+            (r'\\', String, 'string-escape'),
+        ],
+        'triple-single-quoted-string': [
+            (r"'''", String, 'end-of-string'),
+            (r'[^\\]+', String),
+            (r'\\', String.Escape, 'string-escape'),
+        ],
+        'single-single-quoted-string': [
+            (r"'", String, 'end-of-string'),
+            (r"[^'\\\n]+", String),
+            (r'\\', String, 'string-escape'),
+        ],
+        'string-escape': [
+            (r'u' + HEX + '{4}', String.Escape, '#pop'),
+            (r'U' + HEX + '{8}', String.Escape, '#pop'),
+            (r'.', String.Escape, '#pop'),
+        ],
+        'end-of-string': [
+            (r'(@)([a-zA-Z]+(?:-[a-zA-Z0-9]+)*)',
+             bygroups(Operator, Name.Function), '#pop:2'),
+            (r'\^\^', Operator, '#pop:2'),
+            default('#pop:2'),
+        ],
+    }
+
+
+class TurtleLexer(RegexLexer):
+    """
+    Lexer for Turtle data language.
+    """
+    name = 'Turtle'
+    aliases = ['turtle']
+    filenames = ['*.ttl']
+    mimetypes = ['text/turtle', 'application/x-turtle']
+    url = 'https://www.w3.org/TR/turtle'
+    version_added = '2.1'
+
+    # character group definitions ::
+    PN_CHARS_BASE_GRP = ('a-zA-Z'
+                         '\u00c0-\u00d6'
+                         '\u00d8-\u00f6'
+                         '\u00f8-\u02ff'
+                         '\u0370-\u037d'
+                         '\u037f-\u1fff'
+                         '\u200c-\u200d'
+                         '\u2070-\u218f'
+                         '\u2c00-\u2fef'
+                         '\u3001-\ud7ff'
+                         '\uf900-\ufdcf'
+                         '\ufdf0-\ufffd')
+
+    PN_CHARS_U_GRP = (PN_CHARS_BASE_GRP + '_')
+
+    PN_CHARS_GRP = (PN_CHARS_U_GRP +
+                    r'\-' +
+                    r'0-9' +
+                    '\u00b7' +
+                    '\u0300-\u036f' +
+                    '\u203f-\u2040')
+
+    PN_CHARS = '[' + PN_CHARS_GRP + ']'
+
+    PN_CHARS_BASE = '[' + PN_CHARS_BASE_GRP + ']'
+
+    PN_PREFIX = PN_CHARS_BASE + '(?:[' + PN_CHARS_GRP + '.]*' + PN_CHARS + ')?'
+
+    HEX_GRP = '0-9A-Fa-f'
+
+    HEX = '[' + HEX_GRP + ']'
+
+    PERCENT = '%' + HEX + HEX
+
+    PN_LOCAL_ESC_CHARS_GRP = r' _~.\-!$&"()*+,;=/?#@%'
+
+    PN_LOCAL_ESC_CHARS = '[' + PN_LOCAL_ESC_CHARS_GRP + ']'
+
+    PN_LOCAL_ESC = r'\\' + PN_LOCAL_ESC_CHARS
+
+    PLX = '(?:' + PERCENT + ')|(?:' + PN_LOCAL_ESC + ')'
+
+    PN_LOCAL = ('(?:[' + PN_CHARS_U_GRP + ':0-9' + ']|' + PLX + ')' +
+                '(?:(?:[' + PN_CHARS_GRP + '.:]|' + PLX + ')*(?:[' +
+                PN_CHARS_GRP + ':]|' + PLX + '))?')
+
+    patterns = {
+        'PNAME_NS': r'((?:[a-zA-Z][\w-]*)?\:)',  # Simplified character range
+        'IRIREF': r'(<[^<>"{}|^`\\\x00-\x20]*>)'
+    }
+
+    tokens = {
+        'root': [
+            (r'\s+', Text),
+
+            # Base / prefix
+            (r'(@base|BASE)(\s+){IRIREF}(\s*)(\.?)'.format(**patterns),
+             bygroups(Keyword, Whitespace, Name.Variable, Whitespace,
+                      Punctuation)),
+            (r'(@prefix|PREFIX)(\s+){PNAME_NS}(\s+){IRIREF}(\s*)(\.?)'.format(**patterns),
+             bygroups(Keyword, Whitespace, Name.Namespace, Whitespace,
+                      Name.Variable, Whitespace, Punctuation)),
+
+            # The shorthand predicate 'a'
+            (r'(?<=\s)a(?=\s)', Keyword.Type),
+
+            # IRIREF
+            (r'{IRIREF}'.format(**patterns), Name.Variable),
+
+            # PrefixedName
+            (r'(' + PN_PREFIX + r')?(\:)(' + PN_LOCAL + r')?',
+             bygroups(Name.Namespace, Punctuation, Name.Tag)),
+
+            # BlankNodeLabel
+            (r'(_)(:)([' + PN_CHARS_U_GRP + r'0-9]([' + PN_CHARS_GRP + r'.]*' + PN_CHARS + ')?)',
+             bygroups(Name.Namespace, Punctuation, Name.Tag)),
+
+            # Comment
+            (r'#([^\n]+|$)', Comment),
+
+            (r'\b(true|false)\b', Literal),
+            (r'[+\-]?\d*\.\d+', Number.Float),
+            (r'[+\-]?\d*(:?\.\d+)?E[+\-]?\d+', Number.Float),
+            (r'[+\-]?\d+', Number.Integer),
+            (r'[\[\](){}.;,:^]', Punctuation),
+
+            (r'"""', String, 'triple-double-quoted-string'),
+            (r'"', String, 'single-double-quoted-string'),
+            (r"'''", String, 'triple-single-quoted-string'),
+            (r"'", String, 'single-single-quoted-string'),
+        ],
+        'triple-double-quoted-string': [
+            (r'"""', String, 'end-of-string'),
+            (r'[^\\]+(?=""")', String),
+            (r'\\', String, 'string-escape'),
+        ],
+        'single-double-quoted-string': [
+            (r'"', String, 'end-of-string'),
+            (r'[^"\\\n]+', String),
+            (r'\\', String, 'string-escape'),
+        ],
+        'triple-single-quoted-string': [
+            (r"'''", String, 'end-of-string'),
+            (r"[^\\]+(?=''')", String),
+            (r'\\', String, 'string-escape'),
+        ],
+        'single-single-quoted-string': [
+            (r"'", String, 'end-of-string'),
+            (r"[^'\\\n]+", String),
+            (r'\\', String, 'string-escape'),
+        ],
+        'string-escape': [
+            (r'.', String, '#pop'),
+        ],
+        'end-of-string': [
+            (r'(@)([a-zA-Z]+(?:-[a-zA-Z0-9]+)*)',
+             bygroups(Operator, Generic.Emph), '#pop:2'),
+
+            (r'(\^\^){IRIREF}'.format(**patterns), bygroups(Operator, Generic.Emph), '#pop:2'),
+
+            default('#pop:2'),
+
+        ],
+    }
+
+    # Turtle and Tera Term macro files share the same file extension
+    # but each has a recognizable and distinct syntax.
+    def analyse_text(text):
+        for t in ('@base ', 'BASE ', '@prefix ', 'PREFIX '):
+            if re.search(rf'^\s*{t}', text):
+                return 0.80
+
+
+class ShExCLexer(RegexLexer):
+    """
+    Lexer for ShExC shape expressions language syntax.
+    """
+    name = 'ShExC'
+    aliases = ['shexc', 'shex']
+    filenames = ['*.shex']
+    mimetypes = ['text/shex']
+    url = 'https://shex.io/shex-semantics/#shexc'
+    version_added = ''
+
+    # character group definitions ::
+
+    PN_CHARS_BASE_GRP = ('a-zA-Z'
+                         '\u00c0-\u00d6'
+                         '\u00d8-\u00f6'
+                         '\u00f8-\u02ff'
+                         '\u0370-\u037d'
+                         '\u037f-\u1fff'
+                         '\u200c-\u200d'
+                         '\u2070-\u218f'
+                         '\u2c00-\u2fef'
+                         '\u3001-\ud7ff'
+                         '\uf900-\ufdcf'
+                         '\ufdf0-\ufffd')
+
+    PN_CHARS_U_GRP = (PN_CHARS_BASE_GRP + '_')
+
+    PN_CHARS_GRP = (PN_CHARS_U_GRP +
+                    r'\-' +
+                    r'0-9' +
+                    '\u00b7' +
+                    '\u0300-\u036f' +
+                    '\u203f-\u2040')
+
+    HEX_GRP = '0-9A-Fa-f'
+
+    PN_LOCAL_ESC_CHARS_GRP = r"_~.\-!$&'()*+,;=/?#@%"
+
+    # terminal productions ::
+
+    PN_CHARS_BASE = '[' + PN_CHARS_BASE_GRP + ']'
+
+    PN_CHARS_U = '[' + PN_CHARS_U_GRP + ']'
+
+    PN_CHARS = '[' + PN_CHARS_GRP + ']'
+
+    HEX = '[' + HEX_GRP + ']'
+
+    PN_LOCAL_ESC_CHARS = '[' + PN_LOCAL_ESC_CHARS_GRP + ']'
+
+    UCHAR_NO_BACKSLASH = '(?:u' + HEX + '{4}|U' + HEX + '{8})'
+
+    UCHAR = r'\\' + UCHAR_NO_BACKSLASH
+
+    IRIREF = r'<(?:[^\x00-\x20<>"{}|^`\\]|' + UCHAR + ')*>'
+
+    BLANK_NODE_LABEL = '_:[0-9' + PN_CHARS_U_GRP + '](?:[' + PN_CHARS_GRP + \
+                       '.]*' + PN_CHARS + ')?'
+
+    PN_PREFIX = PN_CHARS_BASE + '(?:[' + PN_CHARS_GRP + '.]*' + PN_CHARS + ')?'
+
+    PERCENT = '%' + HEX + HEX
+
+    PN_LOCAL_ESC = r'\\' + PN_LOCAL_ESC_CHARS
+
+    PLX = '(?:' + PERCENT + ')|(?:' + PN_LOCAL_ESC + ')'
+
+    PN_LOCAL = ('(?:[' + PN_CHARS_U_GRP + ':0-9' + ']|' + PLX + ')' +
+                '(?:(?:[' + PN_CHARS_GRP + '.:]|' + PLX + ')*(?:[' +
+                PN_CHARS_GRP + ':]|' + PLX + '))?')
+
+    EXPONENT = r'[eE][+-]?\d+'
+
+    # Lexer token definitions ::
+
+    tokens = {
+        'root': [
+            (r'\s+', Text),
+            # keywords ::
+            (r'(?i)(base|prefix|start|external|'
+             r'literal|iri|bnode|nonliteral|length|minlength|maxlength|'
+             r'mininclusive|minexclusive|maxinclusive|maxexclusive|'
+             r'totaldigits|fractiondigits|'
+             r'closed|extra)\b', Keyword),
+            (r'(a)\b', Keyword),
+            # IRIs ::
+            ('(' + IRIREF + ')', Name.Label),
+            # blank nodes ::
+            ('(' + BLANK_NODE_LABEL + ')', Name.Label),
+            # prefixed names ::
+            (r'(' + PN_PREFIX + r')?(\:)(' + PN_LOCAL + ')?',
+             bygroups(Name.Namespace, Punctuation, Name.Tag)),
+            # boolean literals ::
+            (r'(true|false)', Keyword.Constant),
+            # double literals ::
+            (r'[+\-]?(\d+\.\d*' + EXPONENT + r'|\.?\d+' + EXPONENT + ')', Number.Float),
+            # decimal literals ::
+            (r'[+\-]?(\d+\.\d*|\.\d+)', Number.Float),
+            # integer literals ::
+            (r'[+\-]?\d+', Number.Integer),
+            # operators ::
+            (r'[@|$&=*+?^\-~]', Operator),
+            # operator keywords ::
+            (r'(?i)(and|or|not)\b', Operator.Word),
+            # punctuation characters ::
+            (r'[(){}.;,:^\[\]]', Punctuation),
+            # line comments ::
+            (r'#[^\n]*', Comment),
+            # strings ::
+            (r'"""', String, 'triple-double-quoted-string'),
+            (r'"', String, 'single-double-quoted-string'),
+            (r"'''", String, 'triple-single-quoted-string'),
+            (r"'", String, 'single-single-quoted-string'),
+        ],
+        'triple-double-quoted-string': [
+            (r'"""', String, 'end-of-string'),
+            (r'[^\\]+', String),
+            (r'\\', String, 'string-escape'),
+        ],
+        'single-double-quoted-string': [
+            (r'"', String, 'end-of-string'),
+            (r'[^"\\\n]+', String),
+            (r'\\', String, 'string-escape'),
+        ],
+        'triple-single-quoted-string': [
+            (r"'''", String, 'end-of-string'),
+            (r'[^\\]+', String),
+            (r'\\', String.Escape, 'string-escape'),
+        ],
+        'single-single-quoted-string': [
+            (r"'", String, 'end-of-string'),
+            (r"[^'\\\n]+", String),
+            (r'\\', String, 'string-escape'),
+        ],
+        'string-escape': [
+            (UCHAR_NO_BACKSLASH, String.Escape, '#pop'),
+            (r'.', String.Escape, '#pop'),
+        ],
+        'end-of-string': [
+            (r'(@)([a-zA-Z]+(?:-[a-zA-Z0-9]+)*)',
+             bygroups(Operator, Name.Function), '#pop:2'),
+            (r'\^\^', Operator, '#pop:2'),
+            default('#pop:2'),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rebol.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rebol.py
new file mode 100644
index 0000000000000000000000000000000000000000..fcff62be14de1f3d89c43600daa10f33e7acbc8a
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rebol.py
@@ -0,0 +1,419 @@
+"""
+    pygments.lexers.rebol
+    ~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for the REBOL and related languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, bygroups
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Generic, Whitespace
+
+__all__ = ['RebolLexer', 'RedLexer']
+
+
+class RebolLexer(RegexLexer):
+    """
+    A REBOL lexer.
+    """
+    name = 'REBOL'
+    aliases = ['rebol']
+    filenames = ['*.r', '*.r3', '*.reb']
+    mimetypes = ['text/x-rebol']
+    url = 'http://www.rebol.com'
+    version_added = '1.1'
+
+    flags = re.IGNORECASE | re.MULTILINE
+
+    escape_re = r'(?:\^\([0-9a-f]{1,4}\)*)'
+
+    def word_callback(lexer, match):
+        word = match.group()
+
+        if re.match(".*:$", word):
+            yield match.start(), Generic.Subheading, word
+        elif re.match(
+            r'(native|alias|all|any|as-string|as-binary|bind|bound\?|case|'
+            r'catch|checksum|comment|debase|dehex|exclude|difference|disarm|'
+            r'either|else|enbase|foreach|remove-each|form|free|get|get-env|if|'
+            r'in|intersect|loop|minimum-of|maximum-of|mold|new-line|'
+            r'new-line\?|not|now|prin|print|reduce|compose|construct|repeat|'
+            r'reverse|save|script\?|set|shift|switch|throw|to-hex|trace|try|'
+            r'type\?|union|unique|unless|unprotect|unset|until|use|value\?|'
+            r'while|compress|decompress|secure|open|close|read|read-io|'
+            r'write-io|write|update|query|wait|input\?|exp|log-10|log-2|'
+            r'log-e|square-root|cosine|sine|tangent|arccosine|arcsine|'
+            r'arctangent|protect|lowercase|uppercase|entab|detab|connected\?|'
+            r'browse|launch|stats|get-modes|set-modes|to-local-file|'
+            r'to-rebol-file|encloak|decloak|create-link|do-browser|bind\?|'
+            r'hide|draw|show|size-text|textinfo|offset-to-caret|'
+            r'caret-to-offset|local-request-file|rgb-to-hsv|hsv-to-rgb|'
+            r'crypt-strength\?|dh-make-key|dh-generate-key|dh-compute-key|'
+            r'dsa-make-key|dsa-generate-key|dsa-make-signature|'
+            r'dsa-verify-signature|rsa-make-key|rsa-generate-key|'
+            r'rsa-encrypt)$', word):
+            yield match.start(), Name.Builtin, word
+        elif re.match(
+            r'(add|subtract|multiply|divide|remainder|power|and~|or~|xor~|'
+            r'minimum|maximum|negate|complement|absolute|random|head|tail|'
+            r'next|back|skip|at|pick|first|second|third|fourth|fifth|sixth|'
+            r'seventh|eighth|ninth|tenth|last|path|find|select|make|to|copy\*|'
+            r'insert|remove|change|poke|clear|trim|sort|min|max|abs|cp|'
+            r'copy)$', word):
+            yield match.start(), Name.Function, word
+        elif re.match(
+            r'(error|source|input|license|help|install|echo|Usage|with|func|'
+            r'throw-on-error|function|does|has|context|probe|\?\?|as-pair|'
+            r'mod|modulo|round|repend|about|set-net|append|join|rejoin|reform|'
+            r'remold|charset|array|replace|move|extract|forskip|forall|alter|'
+            r'first+|also|take|for|forever|dispatch|attempt|what-dir|'
+            r'change-dir|clean-path|list-dir|dirize|rename|split-path|delete|'
+            r'make-dir|delete-dir|in-dir|confirm|dump-obj|upgrade|what|'
+            r'build-tag|process-source|build-markup|decode-cgi|read-cgi|'
+            r'write-user|save-user|set-user-name|protect-system|parse-xml|'
+            r'cvs-date|cvs-version|do-boot|get-net-info|desktop|layout|'
+            r'scroll-para|get-face|alert|set-face|uninstall|unfocus|'
+            r'request-dir|center-face|do-events|net-error|decode-url|'
+            r'parse-header|parse-header-date|parse-email-addrs|import-email|'
+            r'send|build-attach-body|resend|show-popup|hide-popup|open-events|'
+            r'find-key-face|do-face|viewtop|confine|find-window|'
+            r'insert-event-func|remove-event-func|inform|dump-pane|dump-face|'
+            r'flag-face|deflag-face|clear-fields|read-net|vbug|path-thru|'
+            r'read-thru|load-thru|do-thru|launch-thru|load-image|'
+            r'request-download|do-face-alt|set-font|set-para|get-style|'
+            r'set-style|make-face|stylize|choose|hilight-text|hilight-all|'
+            r'unlight-text|focus|scroll-drag|clear-face|reset-face|scroll-face|'
+            r'resize-face|load-stock|load-stock-block|notify|request|flash|'
+            r'request-color|request-pass|request-text|request-list|'
+            r'request-date|request-file|dbug|editor|link-relative-path|'
+            r'emailer|parse-error)$', word):
+            yield match.start(), Keyword.Namespace, word
+        elif re.match(
+            r'(halt|quit|do|load|q|recycle|call|run|ask|parse|view|unview|'
+            r'return|exit|break)$', word):
+            yield match.start(), Name.Exception, word
+        elif re.match('REBOL$', word):
+            yield match.start(), Generic.Heading, word
+        elif re.match("to-.*", word):
+            yield match.start(), Keyword, word
+        elif re.match(r'(\+|-|\*|/|//|\*\*|and|or|xor|=\?|=|==|<>|<|>|<=|>=)$',
+                      word):
+            yield match.start(), Operator, word
+        elif re.match(r".*\?$", word):
+            yield match.start(), Keyword, word
+        elif re.match(r".*\!$", word):
+            yield match.start(), Keyword.Type, word
+        elif re.match("'.*", word):
+            yield match.start(), Name.Variable.Instance, word  # lit-word
+        elif re.match("#.*", word):
+            yield match.start(), Name.Label, word  # issue
+        elif re.match("%.*", word):
+            yield match.start(), Name.Decorator, word  # file
+        else:
+            yield match.start(), Name.Variable, word
+
+    tokens = {
+        'root': [
+            (r'\s+', Text),
+            (r'#"', String.Char, 'char'),
+            (r'#\{[0-9a-f]*\}', Number.Hex),
+            (r'2#\{', Number.Hex, 'bin2'),
+            (r'64#\{[0-9a-z+/=\s]*\}', Number.Hex),
+            (r'"', String, 'string'),
+            (r'\{', String, 'string2'),
+            (r';#+.*\n', Comment.Special),
+            (r';\*+.*\n', Comment.Preproc),
+            (r';.*\n', Comment),
+            (r'%"', Name.Decorator, 'stringFile'),
+            (r'%[^(^{")\s\[\]]+', Name.Decorator),
+            (r'[+-]?([a-z]{1,3})?\$\d+(\.\d+)?', Number.Float),  # money
+            (r'[+-]?\d+\:\d+(\:\d+)?(\.\d+)?', String.Other),    # time
+            (r'\d+[\-/][0-9a-z]+[\-/]\d+(\/\d+\:\d+((\:\d+)?'
+             r'([.\d+]?([+-]?\d+:\d+)?)?)?)?', String.Other),   # date
+            (r'\d+(\.\d+)+\.\d+', Keyword.Constant),             # tuple
+            (r'\d+X\d+', Keyword.Constant),                   # pair
+            (r'[+-]?\d+(\'\d+)?([.,]\d*)?E[+-]?\d+', Number.Float),
+            (r'[+-]?\d+(\'\d+)?[.,]\d*', Number.Float),
+            (r'[+-]?\d+(\'\d+)?', Number),
+            (r'[\[\]()]', Generic.Strong),
+            (r'[a-z]+[^(^{"\s:)]*://[^(^{"\s)]*', Name.Decorator),  # url
+            (r'mailto:[^(^{"@\s)]+@[^(^{"@\s)]+', Name.Decorator),  # url
+            (r'[^(^{"@\s)]+@[^(^{"@\s)]+', Name.Decorator),         # email
+            (r'comment\s"', Comment, 'commentString1'),
+            (r'comment\s\{', Comment, 'commentString2'),
+            (r'comment\s\[', Comment, 'commentBlock'),
+            (r'comment\s[^(\s{"\[]+', Comment),
+            (r'/[^(^{")\s/[\]]*', Name.Attribute),
+            (r'([^(^{")\s/[\]]+)(?=[:({"\s/\[\]])', word_callback),
+            (r'<[\w:.-]*>', Name.Tag),
+            (r'<[^(<>\s")]+', Name.Tag, 'tag'),
+            (r'([^(^{")\s]+)', Text),
+        ],
+        'string': [
+            (r'[^(^")]+', String),
+            (escape_re, String.Escape),
+            (r'[(|)]+', String),
+            (r'\^.', String.Escape),
+            (r'"', String, '#pop'),
+        ],
+        'string2': [
+            (r'[^(^{})]+', String),
+            (escape_re, String.Escape),
+            (r'[(|)]+', String),
+            (r'\^.', String.Escape),
+            (r'\{', String, '#push'),
+            (r'\}', String, '#pop'),
+        ],
+        'stringFile': [
+            (r'[^(^")]+', Name.Decorator),
+            (escape_re, Name.Decorator),
+            (r'\^.', Name.Decorator),
+            (r'"', Name.Decorator, '#pop'),
+        ],
+        'char': [
+            (escape_re + '"', String.Char, '#pop'),
+            (r'\^."', String.Char, '#pop'),
+            (r'."', String.Char, '#pop'),
+        ],
+        'tag': [
+            (escape_re, Name.Tag),
+            (r'"', Name.Tag, 'tagString'),
+            (r'[^(<>\r\n")]+', Name.Tag),
+            (r'>', Name.Tag, '#pop'),
+        ],
+        'tagString': [
+            (r'[^(^")]+', Name.Tag),
+            (escape_re, Name.Tag),
+            (r'[(|)]+', Name.Tag),
+            (r'\^.', Name.Tag),
+            (r'"', Name.Tag, '#pop'),
+        ],
+        'tuple': [
+            (r'(\d+\.)+', Keyword.Constant),
+            (r'\d+', Keyword.Constant, '#pop'),
+        ],
+        'bin2': [
+            (r'\s+', Number.Hex),
+            (r'([01]\s*){8}', Number.Hex),
+            (r'\}', Number.Hex, '#pop'),
+        ],
+        'commentString1': [
+            (r'[^(^")]+', Comment),
+            (escape_re, Comment),
+            (r'[(|)]+', Comment),
+            (r'\^.', Comment),
+            (r'"', Comment, '#pop'),
+        ],
+        'commentString2': [
+            (r'[^(^{})]+', Comment),
+            (escape_re, Comment),
+            (r'[(|)]+', Comment),
+            (r'\^.', Comment),
+            (r'\{', Comment, '#push'),
+            (r'\}', Comment, '#pop'),
+        ],
+        'commentBlock': [
+            (r'\[', Comment, '#push'),
+            (r'\]', Comment, '#pop'),
+            (r'"', Comment, "commentString1"),
+            (r'\{', Comment, "commentString2"),
+            (r'[^(\[\]"{)]+', Comment),
+        ],
+    }
+
+    def analyse_text(text):
+        """
+        Check if code contains REBOL header and so it probably not R code
+        """
+        if re.match(r'^\s*REBOL\s*\[', text, re.IGNORECASE):
+            # The code starts with REBOL header
+            return 1.0
+        elif re.search(r'\s*REBOL\s*\[', text, re.IGNORECASE):
+            # The code contains REBOL header but also some text before it
+            return 0.5
+
+
+class RedLexer(RegexLexer):
+    """
+    A Red-language lexer.
+    """
+    name = 'Red'
+    aliases = ['red', 'red/system']
+    filenames = ['*.red', '*.reds']
+    mimetypes = ['text/x-red', 'text/x-red-system']
+    url = 'https://www.red-lang.org'
+    version_added = '2.0'
+
+    flags = re.IGNORECASE | re.MULTILINE
+
+    escape_re = r'(?:\^\([0-9a-f]{1,4}\)*)'
+
+    def word_callback(lexer, match):
+        word = match.group()
+
+        if re.match(".*:$", word):
+            yield match.start(), Generic.Subheading, word
+        elif re.match(r'(if|unless|either|any|all|while|until|loop|repeat|'
+                      r'foreach|forall|func|function|does|has|switch|'
+                      r'case|reduce|compose|get|set|print|prin|equal\?|'
+                      r'not-equal\?|strict-equal\?|lesser\?|greater\?|lesser-or-equal\?|'
+                      r'greater-or-equal\?|same\?|not|type\?|stats|'
+                      r'bind|union|replace|charset|routine)$', word):
+            yield match.start(), Name.Builtin, word
+        elif re.match(r'(make|random|reflect|to|form|mold|absolute|add|divide|multiply|negate|'
+                      r'power|remainder|round|subtract|even\?|odd\?|and~|complement|or~|xor~|'
+                      r'append|at|back|change|clear|copy|find|head|head\?|index\?|insert|'
+                      r'length\?|next|pick|poke|remove|reverse|select|sort|skip|swap|tail|tail\?|'
+                      r'take|trim|create|close|delete|modify|open|open\?|query|read|rename|'
+                      r'update|write)$', word):
+            yield match.start(), Name.Function, word
+        elif re.match(r'(yes|on|no|off|true|false|tab|cr|lf|newline|escape|slash|sp|space|null|'
+                      r'none|crlf|dot|null-byte)$', word):
+            yield match.start(), Name.Builtin.Pseudo, word
+        elif re.match(r'(#system-global|#include|#enum|#define|#either|#if|#import|#export|'
+                      r'#switch|#default|#get-definition)$', word):
+            yield match.start(), Keyword.Namespace, word
+        elif re.match(r'(system|halt|quit|quit-return|do|load|q|recycle|call|run|ask|parse|'
+                      r'raise-error|return|exit|break|alias|push|pop|probe|\?\?|spec-of|body-of|'
+                      r'quote|forever)$', word):
+            yield match.start(), Name.Exception, word
+        elif re.match(r'(action\?|block\?|char\?|datatype\?|file\?|function\?|get-path\?|zero\?|'
+                      r'get-word\?|integer\?|issue\?|lit-path\?|lit-word\?|logic\?|native\?|'
+                      r'op\?|paren\?|path\?|refinement\?|set-path\?|set-word\?|string\?|unset\?|'
+                      r'any-struct\?|none\?|word\?|any-series\?)$', word):
+            yield match.start(), Keyword, word
+        elif re.match(r'(JNICALL|stdcall|cdecl|infix)$', word):
+            yield match.start(), Keyword.Namespace, word
+        elif re.match("to-.*", word):
+            yield match.start(), Keyword, word
+        elif re.match(r'(\+|-\*\*|-|\*\*|//|/|\*|and|or|xor|=\?|===|==|=|<>|<=|>=|'
+                      r'<<<|>>>|<<|>>|<|>%)$', word):
+            yield match.start(), Operator, word
+        elif re.match(r".*\!$", word):
+            yield match.start(), Keyword.Type, word
+        elif re.match("'.*", word):
+            yield match.start(), Name.Variable.Instance, word  # lit-word
+        elif re.match("#.*", word):
+            yield match.start(), Name.Label, word  # issue
+        elif re.match("%.*", word):
+            yield match.start(), Name.Decorator, word  # file
+        elif re.match(":.*", word):
+            yield match.start(), Generic.Subheading, word  # get-word
+        else:
+            yield match.start(), Name.Variable, word
+
+    tokens = {
+        'root': [
+            (r'\s+', Text),
+            (r'#"', String.Char, 'char'),
+            (r'#\{[0-9a-f\s]*\}', Number.Hex),
+            (r'2#\{', Number.Hex, 'bin2'),
+            (r'64#\{[0-9a-z+/=\s]*\}', Number.Hex),
+            (r'([0-9a-f]+)(h)((\s)|(?=[\[\]{}"()]))',
+             bygroups(Number.Hex, Name.Variable, Whitespace)),
+            (r'"', String, 'string'),
+            (r'\{', String, 'string2'),
+            (r';#+.*\n', Comment.Special),
+            (r';\*+.*\n', Comment.Preproc),
+            (r';.*\n', Comment),
+            (r'%"', Name.Decorator, 'stringFile'),
+            (r'%[^(^{")\s\[\]]+', Name.Decorator),
+            (r'[+-]?([a-z]{1,3})?\$\d+(\.\d+)?', Number.Float),  # money
+            (r'[+-]?\d+\:\d+(\:\d+)?(\.\d+)?', String.Other),    # time
+            (r'\d+[\-/][0-9a-z]+[\-/]\d+(/\d+:\d+((:\d+)?'
+             r'([\.\d+]?([+-]?\d+:\d+)?)?)?)?', String.Other),   # date
+            (r'\d+(\.\d+)+\.\d+', Keyword.Constant),             # tuple
+            (r'\d+X\d+', Keyword.Constant),                   # pair
+            (r'[+-]?\d+(\'\d+)?([.,]\d*)?E[+-]?\d+', Number.Float),
+            (r'[+-]?\d+(\'\d+)?[.,]\d*', Number.Float),
+            (r'[+-]?\d+(\'\d+)?', Number),
+            (r'[\[\]()]', Generic.Strong),
+            (r'[a-z]+[^(^{"\s:)]*://[^(^{"\s)]*', Name.Decorator),  # url
+            (r'mailto:[^(^{"@\s)]+@[^(^{"@\s)]+', Name.Decorator),  # url
+            (r'[^(^{"@\s)]+@[^(^{"@\s)]+', Name.Decorator),         # email
+            (r'comment\s"', Comment, 'commentString1'),
+            (r'comment\s\{', Comment, 'commentString2'),
+            (r'comment\s\[', Comment, 'commentBlock'),
+            (r'comment\s[^(\s{"\[]+', Comment),
+            (r'/[^(^{^")\s/[\]]*', Name.Attribute),
+            (r'([^(^{^")\s/[\]]+)(?=[:({"\s/\[\]])', word_callback),
+            (r'<[\w:.-]*>', Name.Tag),
+            (r'<[^(<>\s")]+', Name.Tag, 'tag'),
+            (r'([^(^{")\s]+)', Text),
+        ],
+        'string': [
+            (r'[^(^")]+', String),
+            (escape_re, String.Escape),
+            (r'[(|)]+', String),
+            (r'\^.', String.Escape),
+            (r'"', String, '#pop'),
+        ],
+        'string2': [
+            (r'[^(^{})]+', String),
+            (escape_re, String.Escape),
+            (r'[(|)]+', String),
+            (r'\^.', String.Escape),
+            (r'\{', String, '#push'),
+            (r'\}', String, '#pop'),
+        ],
+        'stringFile': [
+            (r'[^(^")]+', Name.Decorator),
+            (escape_re, Name.Decorator),
+            (r'\^.', Name.Decorator),
+            (r'"', Name.Decorator, '#pop'),
+        ],
+        'char': [
+            (escape_re + '"', String.Char, '#pop'),
+            (r'\^."', String.Char, '#pop'),
+            (r'."', String.Char, '#pop'),
+        ],
+        'tag': [
+            (escape_re, Name.Tag),
+            (r'"', Name.Tag, 'tagString'),
+            (r'[^(<>\r\n")]+', Name.Tag),
+            (r'>', Name.Tag, '#pop'),
+        ],
+        'tagString': [
+            (r'[^(^")]+', Name.Tag),
+            (escape_re, Name.Tag),
+            (r'[(|)]+', Name.Tag),
+            (r'\^.', Name.Tag),
+            (r'"', Name.Tag, '#pop'),
+        ],
+        'tuple': [
+            (r'(\d+\.)+', Keyword.Constant),
+            (r'\d+', Keyword.Constant, '#pop'),
+        ],
+        'bin2': [
+            (r'\s+', Number.Hex),
+            (r'([01]\s*){8}', Number.Hex),
+            (r'\}', Number.Hex, '#pop'),
+        ],
+        'commentString1': [
+            (r'[^(^")]+', Comment),
+            (escape_re, Comment),
+            (r'[(|)]+', Comment),
+            (r'\^.', Comment),
+            (r'"', Comment, '#pop'),
+        ],
+        'commentString2': [
+            (r'[^(^{})]+', Comment),
+            (escape_re, Comment),
+            (r'[(|)]+', Comment),
+            (r'\^.', Comment),
+            (r'\{', Comment, '#push'),
+            (r'\}', Comment, '#pop'),
+        ],
+        'commentBlock': [
+            (r'\[', Comment, '#push'),
+            (r'\]', Comment, '#pop'),
+            (r'"', Comment, "commentString1"),
+            (r'\{', Comment, "commentString2"),
+            (r'[^(\[\]"{)]+', Comment),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rego.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rego.py
new file mode 100644
index 0000000000000000000000000000000000000000..b2e8b75473ce1f8b72a94f7de904d9f3b23c3a9f
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rego.py
@@ -0,0 +1,57 @@
+"""
+    pygments.lexers.rego
+    ~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for the Rego policy languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, words
+from pygments.token import Comment, Operator, Keyword, Name, String, Number, Punctuation, Whitespace
+
+class RegoLexer(RegexLexer):
+    """
+    For Rego source.
+    """
+    name = 'Rego'
+    url = 'https://www.openpolicyagent.org/docs/latest/policy-language/'
+    filenames = ['*.rego']
+    aliases = ['rego']
+    mimetypes = ['text/x-rego']
+    version_added = '2.19'
+
+    reserved_words = (
+        'as', 'contains', 'data', 'default', 'else', 'every', 'false',
+        'if', 'in', 'import', 'package', 'not', 'null',
+        'some', 'true', 'with'
+    )
+
+    builtins = (
+        # https://www.openpolicyagent.org/docs/latest/philosophy/#the-opa-document-model
+        'data',  # Global variable for accessing base and virtual documents
+        'input', # Represents synchronously pushed base documents
+    )
+
+    tokens = {
+        'root': [
+            (r'\n', Whitespace),
+            (r'\s+', Whitespace),
+            (r'#.*?$', Comment.Single),
+            (words(reserved_words, suffix=r'\b'), Keyword),
+            (words(builtins, suffix=r'\b'), Name.Builtin),
+            (r'[a-zA-Z_][a-zA-Z0-9_]*', Name),
+            (r'"(\\\\|\\"|[^"])*"', String.Double),
+            (r'`[^`]*`', String.Backtick),
+            (r'-?\d+(\.\d+)?', Number),
+            (r'(==|!=|<=|>=|:=)', Operator),  # Compound operators
+            (r'[=<>+\-*/%&|]', Operator),     # Single-character operators
+            (r'[\[\]{}(),.:;]', Punctuation),
+        ]
+    }
+
+__all__ = ['RegoLexer']
+
+
+
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rell.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rell.py
new file mode 100644
index 0000000000000000000000000000000000000000..8d54ed2a5162448386aa30d1d2f2f99f9e836c20
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rell.py
@@ -0,0 +1,68 @@
+"""
+    pygments.lexers.rell
+    ~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for the Rell language.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, bygroups, default, words
+from pygments.token import Comment, Keyword, Name, String, Number, \
+        Punctuation, Whitespace
+
+__all__ = ['RellLexer']
+
+
+class RellLexer(RegexLexer):
+    """
+    A Lexer for Rell.
+    """
+    name = 'Rell'
+    url = 'https://docs.chromia.com/rell/rell-intro'
+    aliases = ['rell']
+    filenames = ['*.rell']
+    mimetypes = ['text/x-rell']
+    version_added = '2.20'
+
+    ident = r'[a-zA-Z_][a-zA-Z0-9_]*'
+
+    tokens = {
+        'root': [
+            (words((
+                'big_integer', 'boolean', 'byte_array', 'decimal', 'gtv',
+                'integer', 'json', 'list', 'map', 'mutable', 'set', 'text',
+                'virtual'), suffix=r'\b'),
+             Keyword.Type),
+            (r'(false|true|null)\b', Keyword.Constant),
+            (r'(entity|enum|namespace|object|struct)\b', Keyword.Declaration),
+            (r'(function|operation|query)\b', Keyword.Declaration, 'function'),
+            (words((
+                'abstract', 'and', 'break', 'continue', 'create', 'delete',
+                'else', 'for', 'if', 'import', 'in', 'index', 'key', 'limit',
+                'module', 'not', 'offset', 'or', 'override', 'return', 'update',
+                'val', 'var', 'when', 'while'), suffix=r'\b'),
+             Keyword.Reserved),
+            (r'//.*?$', Comment.Single),
+            (r'/\*(.|\n|\r)*?\*/', Comment.Multiline),
+            (r'"(\\\\|\\"|[^"])*"', String.Double),
+            (r'\'(\\\\|\\\'|[^\\\'])*\'', String.Single),
+            (r'-?[0-9]*\.[0-9]+([eE][+-][0-9]+)?', Number.Float),
+            (r'-?[0-9]+([eE][+-][0-9]+|[lL])?', Number.Integer),
+            (r'x(\'[a-fA-F0-9]*\'|"[a-fA-F0-9]*")', String.Binary),
+            (r'(\.)([ \n\t\r]*)(' + ident + ')',
+                bygroups(Punctuation, Whitespace, Name.Attribute)),
+            (r'[{}():;,]+', Punctuation),
+            (r'[ \n\t\r]+', Whitespace),
+            (r'@[a-zA-Z_][a-zA-Z0-9_]*', Name.Decorator),
+            (r'[~^*!%&\[\]<>|+=/?\-@\$]', Punctuation.Marker),
+            (ident, Name),
+            (r'(\.)+', Punctuation),
+        ],
+        'function': [
+            (r'[ \n\t\r]+', Whitespace),
+            (ident, Name.Function, '#pop'),
+            default('#pop'),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/resource.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/resource.py
new file mode 100644
index 0000000000000000000000000000000000000000..eb6cb4a2ee6b9a661613d68fcd8f1fc2d77e96a2
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/resource.py
@@ -0,0 +1,83 @@
+"""
+    pygments.lexers.resource
+    ~~~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for resource definition files.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, bygroups, words
+from pygments.token import Comment, String, Number, Operator, Text, \
+    Keyword, Name
+
+__all__ = ['ResourceLexer']
+
+
+class ResourceLexer(RegexLexer):
+    """Lexer for ICU Resource bundles.
+    """
+    name = 'ResourceBundle'
+    aliases = ['resourcebundle', 'resource']
+    filenames = []
+    url = 'https://unicode-org.github.io/icu/userguide/locale/resources.html'
+    version_added = '2.0'
+
+    _types = (':table', ':array', ':string', ':bin', ':import', ':intvector',
+              ':int', ':alias')
+
+    flags = re.MULTILINE | re.IGNORECASE
+    tokens = {
+        'root': [
+            (r'//.*?$', Comment),
+            (r'"', String, 'string'),
+            (r'-?\d+', Number.Integer),
+            (r'[,{}]', Operator),
+            (r'([^\s{{:]+)(\s*)({}?)'.format('|'.join(_types)),
+             bygroups(Name, Text, Keyword)),
+            (r'\s+', Text),
+            (words(_types), Keyword),
+        ],
+        'string': [
+            (r'(\\x[0-9a-f]{2}|\\u[0-9a-f]{4}|\\U00[0-9a-f]{6}|'
+             r'\\[0-7]{1,3}|\\c.|\\[abtnvfre\'"?\\]|\\\{|[^"{\\])+', String),
+            (r'\{', String.Escape, 'msgname'),
+            (r'"', String, '#pop')
+        ],
+        'msgname': [
+            (r'([^{},]+)(\s*)', bygroups(Name, String.Escape), ('#pop', 'message'))
+        ],
+        'message': [
+            (r'\{', String.Escape, 'msgname'),
+            (r'\}', String.Escape, '#pop'),
+            (r'(,)(\s*)([a-z]+)(\s*\})',
+             bygroups(Operator, String.Escape, Keyword, String.Escape), '#pop'),
+            (r'(,)(\s*)([a-z]+)(\s*)(,)(\s*)(offset)(\s*)(:)(\s*)(-?\d+)(\s*)',
+             bygroups(Operator, String.Escape, Keyword, String.Escape, Operator,
+                      String.Escape, Operator.Word, String.Escape, Operator,
+                      String.Escape, Number.Integer, String.Escape), 'choice'),
+            (r'(,)(\s*)([a-z]+)(\s*)(,)(\s*)',
+             bygroups(Operator, String.Escape, Keyword, String.Escape, Operator,
+                      String.Escape), 'choice'),
+            (r'\s+', String.Escape)
+        ],
+        'choice': [
+            (r'(=|<|>|<=|>=|!=)(-?\d+)(\s*\{)',
+             bygroups(Operator, Number.Integer, String.Escape), 'message'),
+            (r'([a-z]+)(\s*\{)', bygroups(Keyword.Type, String.Escape), 'str'),
+            (r'\}', String.Escape, ('#pop', '#pop')),
+            (r'\s+', String.Escape)
+        ],
+        'str': [
+            (r'\}', String.Escape, '#pop'),
+            (r'\{', String.Escape, 'msgname'),
+            (r'[^{}]+', String)
+        ]
+    }
+
+    def analyse_text(text):
+        if text.startswith('root:table'):
+            return 1.0
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/ride.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/ride.py
new file mode 100644
index 0000000000000000000000000000000000000000..1ed8f38412baa74fc0ed6b53709cdcb41afeb893
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/ride.py
@@ -0,0 +1,138 @@
+"""
+    pygments.lexers.ride
+    ~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for the Ride programming language.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, words, include
+from pygments.token import Comment, Keyword, Name, Number, Punctuation, \
+    String, Text
+
+__all__ = ['RideLexer']
+
+
+class RideLexer(RegexLexer):
+    """
+    For Ride source code.
+    """
+
+    name = 'Ride'
+    aliases = ['ride']
+    filenames = ['*.ride']
+    mimetypes = ['text/x-ride']
+    url = 'https://docs.waves.tech/en/ride'
+    version_added = '2.6'
+
+    validName = r'[a-zA-Z_][a-zA-Z0-9_\']*'
+
+    builtinOps = (
+        '||', '|', '>=', '>', '==', '!',
+        '=', '<=', '<', '::', ':+', ':', '!=', '/',
+        '.', '=>', '-', '+', '*', '&&', '%', '++',
+    )
+
+    globalVariablesName = (
+        'NOALG', 'MD5', 'SHA1', 'SHA224', 'SHA256', 'SHA384', 'SHA512',
+        'SHA3224', 'SHA3256', 'SHA3384', 'SHA3512', 'nil', 'this', 'unit',
+        'height', 'lastBlock', 'Buy', 'Sell', 'CEILING', 'FLOOR', 'DOWN',
+        'HALFDOWN', 'HALFEVEN', 'HALFUP', 'UP',
+    )
+
+    typesName = (
+        'Unit', 'Int', 'Boolean', 'ByteVector', 'String', 'Address', 'Alias',
+        'Transfer', 'AssetPair', 'DataEntry', 'Order', 'Transaction',
+        'GenesisTransaction', 'PaymentTransaction', 'ReissueTransaction',
+        'BurnTransaction', 'MassTransferTransaction', 'ExchangeTransaction',
+        'TransferTransaction', 'SetAssetScriptTransaction',
+        'InvokeScriptTransaction', 'IssueTransaction', 'LeaseTransaction',
+        'LeaseCancelTransaction', 'CreateAliasTransaction',
+        'SetScriptTransaction', 'SponsorFeeTransaction', 'DataTransaction',
+        'WriteSet', 'AttachedPayment', 'ScriptTransfer', 'TransferSet',
+        'ScriptResult', 'Invocation', 'Asset', 'BlockInfo', 'Issue', 'Reissue',
+        'Burn', 'NoAlg', 'Md5', 'Sha1', 'Sha224', 'Sha256', 'Sha384', 'Sha512',
+        'Sha3224', 'Sha3256', 'Sha3384', 'Sha3512', 'BinaryEntry',
+        'BooleanEntry', 'IntegerEntry', 'StringEntry', 'List', 'Ceiling',
+        'Down', 'Floor', 'HalfDown', 'HalfEven', 'HalfUp', 'Up',
+    )
+
+    functionsName = (
+        'fraction', 'size', 'toBytes', 'take', 'drop', 'takeRight', 'dropRight',
+        'toString', 'isDefined', 'extract', 'throw', 'getElement', 'value',
+        'cons', 'toUtf8String', 'toInt', 'indexOf', 'lastIndexOf', 'split',
+        'parseInt', 'parseIntValue', 'keccak256', 'blake2b256', 'sha256',
+        'sigVerify', 'toBase58String', 'fromBase58String', 'toBase64String',
+        'fromBase64String', 'transactionById', 'transactionHeightById',
+        'getInteger', 'getBoolean', 'getBinary', 'getString',
+        'addressFromPublicKey', 'addressFromString', 'addressFromRecipient',
+        'assetBalance', 'wavesBalance', 'getIntegerValue', 'getBooleanValue',
+        'getBinaryValue', 'getStringValue', 'addressFromStringValue',
+        'assetInfo', 'rsaVerify', 'checkMerkleProof', 'median',
+        'valueOrElse', 'valueOrErrorMessage', 'contains', 'log', 'pow',
+        'toBase16String', 'fromBase16String', 'blockInfoByHeight',
+        'transferTransactionById',
+    )
+
+    reservedWords = words((
+        'match', 'case', 'else', 'func', 'if',
+        'let', 'then', '@Callable', '@Verifier',
+    ), suffix=r'\b')
+
+    tokens = {
+        'root': [
+            # Comments
+            (r'#.*', Comment.Single),
+            # Whitespace
+            (r'\s+', Text),
+            # Strings
+            (r'"', String, 'doublequote'),
+            (r'utf8\'', String, 'utf8quote'),
+            (r'base(58|64|16)\'', String, 'singlequote'),
+            # Keywords
+            (reservedWords, Keyword.Reserved),
+            (r'\{-#.*?#-\}', Keyword.Reserved),
+            (r'FOLD<\d+>', Keyword.Reserved),
+            # Types
+            (words(typesName), Keyword.Type),
+            # Main
+            # (specialName, Keyword.Reserved),
+            # Prefix Operators
+            (words(builtinOps, prefix=r'\(', suffix=r'\)'), Name.Function),
+            # Infix Operators
+            (words(builtinOps), Name.Function),
+            (words(globalVariablesName), Name.Function),
+            (words(functionsName), Name.Function),
+            # Numbers
+            include('numbers'),
+            # Variable Names
+            (validName, Name.Variable),
+            # Parens
+            (r'[,()\[\]{}]', Punctuation),
+        ],
+
+        'doublequote': [
+            (r'\\u[0-9a-fA-F]{4}', String.Escape),
+            (r'\\[nrfvb\\"]', String.Escape),
+            (r'[^"]', String),
+            (r'"', String, '#pop'),
+        ],
+
+        'utf8quote': [
+            (r'\\u[0-9a-fA-F]{4}', String.Escape),
+            (r'\\[nrfvb\\\']', String.Escape),
+            (r'[^\']', String),
+            (r'\'', String, '#pop'),
+        ],
+
+        'singlequote': [
+            (r'[^\']', String),
+            (r'\'', String, '#pop'),
+        ],
+
+        'numbers': [
+            (r'_?\d+', Number.Integer),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rita.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rita.py
new file mode 100644
index 0000000000000000000000000000000000000000..99a574c2a1a4d83050389f07dbb5052a3c39b180
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rita.py
@@ -0,0 +1,42 @@
+"""
+    pygments.lexers.rita
+    ~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for RITA language
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer
+from pygments.token import Comment, Operator, Keyword, Name, Literal, \
+    Punctuation, Whitespace
+
+__all__ = ['RitaLexer']
+
+
+class RitaLexer(RegexLexer):
+    """
+    Lexer for RITA.
+    """
+    name = 'Rita'
+    url = 'https://github.com/zaibacu/rita-dsl'
+    filenames = ['*.rita']
+    aliases = ['rita']
+    mimetypes = ['text/rita']
+    version_added = '2.11'
+
+    tokens = {
+        'root': [
+            (r'\n', Whitespace),
+            (r'\s+', Whitespace),
+            (r'#(.*?)\n', Comment.Single),
+            (r'@(.*?)\n', Operator),  # Yes, whole line as an operator
+            (r'"(\w|\d|\s|(\\")|[\'_\-./,\?\!])+?"', Literal),
+            (r'\'(\w|\d|\s|(\\\')|["_\-./,\?\!])+?\'', Literal),
+            (r'([A-Z_]+)', Keyword),
+            (r'([a-z0-9_]+)', Name),
+            (r'((->)|[!?+*|=])', Operator),
+            (r'[\(\),\{\}]', Punctuation)
+        ]
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rnc.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rnc.py
new file mode 100644
index 0000000000000000000000000000000000000000..7ddd33e44474451c6f1cff5a9ac35eb40df3783a
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rnc.py
@@ -0,0 +1,66 @@
+"""
+    pygments.lexers.rnc
+    ~~~~~~~~~~~~~~~~~~~
+
+    Lexer for Relax-NG Compact syntax
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Punctuation
+
+__all__ = ['RNCCompactLexer']
+
+
+class RNCCompactLexer(RegexLexer):
+    """
+    For RelaxNG-compact syntax.
+    """
+
+    name = 'Relax-NG Compact'
+    url = 'http://relaxng.org'
+    aliases = ['rng-compact', 'rnc']
+    filenames = ['*.rnc']
+    version_added = '2.2'
+
+    tokens = {
+        'root': [
+            (r'namespace\b', Keyword.Namespace),
+            (r'(?:default|datatypes)\b', Keyword.Declaration),
+            (r'##.*$', Comment.Preproc),
+            (r'#.*$', Comment.Single),
+            (r'"[^"]*"', String.Double),
+            # TODO single quoted strings and escape sequences outside of
+            # double-quoted strings
+            (r'(?:element|attribute|mixed)\b', Keyword.Declaration, 'variable'),
+            (r'(text\b|xsd:[^ ]+)', Keyword.Type, 'maybe_xsdattributes'),
+            (r'[,?&*=|~]|>>', Operator),
+            (r'[(){}]', Punctuation),
+            (r'.', Text),
+        ],
+
+        # a variable has been declared using `element` or `attribute`
+        'variable': [
+            (r'[^{]+', Name.Variable),
+            (r'\{', Punctuation, '#pop'),
+        ],
+
+        # after an xsd: declaration there may be attributes
+        'maybe_xsdattributes': [
+            (r'\{', Punctuation, 'xsdattributes'),
+            (r'\}', Punctuation, '#pop'),
+            (r'.', Text),
+        ],
+
+        # attributes take the form { key1 = value1 key2 = value2 ... }
+        'xsdattributes': [
+            (r'[^ =}]', Name.Attribute),
+            (r'=', Operator),
+            (r'"[^"]*"', String.Double),
+            (r'\}', Punctuation, '#pop'),
+            (r'.', Text),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/roboconf.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/roboconf.py
new file mode 100644
index 0000000000000000000000000000000000000000..bf0570cc37161e82e34a31113731d723b662128f
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/roboconf.py
@@ -0,0 +1,81 @@
+"""
+    pygments.lexers.roboconf
+    ~~~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for Roboconf DSL.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, words, re
+from pygments.token import Text, Operator, Keyword, Name, Comment
+
+__all__ = ['RoboconfGraphLexer', 'RoboconfInstancesLexer']
+
+
+class RoboconfGraphLexer(RegexLexer):
+    """
+    Lexer for Roboconf graph files.
+    """
+    name = 'Roboconf Graph'
+    aliases = ['roboconf-graph']
+    filenames = ['*.graph']
+    url = 'https://roboconf.github.io/en/user-guide/graph-definition.html'
+    version_added = '2.1'
+
+    flags = re.IGNORECASE | re.MULTILINE
+    tokens = {
+        'root': [
+            # Skip white spaces
+            (r'\s+', Text),
+
+            # There is one operator
+            (r'=', Operator),
+
+            # Keywords
+            (words(('facet', 'import'), suffix=r'\s*\b', prefix=r'\b'), Keyword),
+            (words((
+                'installer', 'extends', 'exports', 'imports', 'facets',
+                'children'), suffix=r'\s*:?', prefix=r'\b'), Name),
+
+            # Comments
+            (r'#.*\n', Comment),
+
+            # Default
+            (r'[^#]', Text),
+            (r'.*\n', Text)
+        ]
+    }
+
+
+class RoboconfInstancesLexer(RegexLexer):
+    """
+    Lexer for Roboconf instances files.
+    """
+    name = 'Roboconf Instances'
+    aliases = ['roboconf-instances']
+    filenames = ['*.instances']
+    url = 'https://roboconf.github.io'
+    version_added = '2.1'
+
+    flags = re.IGNORECASE | re.MULTILINE
+    tokens = {
+        'root': [
+
+            # Skip white spaces
+            (r'\s+', Text),
+
+            # Keywords
+            (words(('instance of', 'import'), suffix=r'\s*\b', prefix=r'\b'), Keyword),
+            (words(('name', 'count'), suffix=r's*:?', prefix=r'\b'), Name),
+            (r'\s*[\w.-]+\s*:', Name),
+
+            # Comments
+            (r'#.*\n', Comment),
+
+            # Default
+            (r'[^#]', Text),
+            (r'.*\n', Text)
+        ]
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/robotframework.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/robotframework.py
new file mode 100644
index 0000000000000000000000000000000000000000..a481136cc7b8c08182e10fc5c57d9aa41ceedaf1
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/robotframework.py
@@ -0,0 +1,551 @@
+"""
+    pygments.lexers.robotframework
+    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for Robot Framework.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+#  Copyright 2012 Nokia Siemens Networks Oyj
+#
+#  Licensed under the Apache License, Version 2.0 (the "License");
+#  you may not use this file except in compliance with the License.
+#  You may obtain a copy of the License at
+#
+#      http://www.apache.org/licenses/LICENSE-2.0
+#
+#  Unless required by applicable law or agreed to in writing, software
+#  distributed under the License is distributed on an "AS IS" BASIS,
+#  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+#  See the License for the specific language governing permissions and
+#  limitations under the License.
+
+import re
+
+from pygments.lexer import Lexer
+from pygments.token import Token
+
+__all__ = ['RobotFrameworkLexer']
+
+
+HEADING = Token.Generic.Heading
+SETTING = Token.Keyword.Namespace
+IMPORT = Token.Name.Namespace
+TC_KW_NAME = Token.Generic.Subheading
+KEYWORD = Token.Name.Function
+ARGUMENT = Token.String
+VARIABLE = Token.Name.Variable
+COMMENT = Token.Comment
+SEPARATOR = Token.Punctuation
+SYNTAX = Token.Punctuation
+GHERKIN = Token.Generic.Emph
+ERROR = Token.Error
+
+
+def normalize(string, remove=''):
+    string = string.lower()
+    for char in remove + ' ':
+        if char in string:
+            string = string.replace(char, '')
+    return string
+
+
+class RobotFrameworkLexer(Lexer):
+    """
+    For Robot Framework test data.
+
+    Supports both space and pipe separated plain text formats.
+    """
+    name = 'RobotFramework'
+    url = 'http://robotframework.org'
+    aliases = ['robotframework']
+    filenames = ['*.robot', '*.resource']
+    mimetypes = ['text/x-robotframework']
+    version_added = '1.6'
+
+    def __init__(self, **options):
+        options['tabsize'] = 2
+        options['encoding'] = 'UTF-8'
+        Lexer.__init__(self, **options)
+
+    def get_tokens_unprocessed(self, text):
+        row_tokenizer = RowTokenizer()
+        var_tokenizer = VariableTokenizer()
+        index = 0
+        for row in text.splitlines():
+            for value, token in row_tokenizer.tokenize(row):
+                for value, token in var_tokenizer.tokenize(value, token):
+                    if value:
+                        yield index, token, str(value)
+                        index += len(value)
+
+
+class VariableTokenizer:
+
+    def tokenize(self, string, token):
+        var = VariableSplitter(string, identifiers='$@%&')
+        if var.start < 0 or token in (COMMENT, ERROR):
+            yield string, token
+            return
+        for value, token in self._tokenize(var, string, token):
+            if value:
+                yield value, token
+
+    def _tokenize(self, var, string, orig_token):
+        before = string[:var.start]
+        yield before, orig_token
+        yield var.identifier + '{', SYNTAX
+        yield from self.tokenize(var.base, VARIABLE)
+        yield '}', SYNTAX
+        if var.index is not None:
+            yield '[', SYNTAX
+            yield from self.tokenize(var.index, VARIABLE)
+            yield ']', SYNTAX
+        yield from self.tokenize(string[var.end:], orig_token)
+
+
+class RowTokenizer:
+
+    def __init__(self):
+        self._table = UnknownTable()
+        self._splitter = RowSplitter()
+        testcases = TestCaseTable()
+        settings = SettingTable(testcases.set_default_template)
+        variables = VariableTable()
+        keywords = KeywordTable()
+        self._tables = {'settings': settings, 'setting': settings,
+                        'metadata': settings,
+                        'variables': variables, 'variable': variables,
+                        'testcases': testcases, 'testcase': testcases,
+                        'tasks': testcases, 'task': testcases,
+                        'keywords': keywords, 'keyword': keywords,
+                        'userkeywords': keywords, 'userkeyword': keywords}
+
+    def tokenize(self, row):
+        commented = False
+        heading = False
+        for index, value in enumerate(self._splitter.split(row)):
+            # First value, and every second after that, is a separator.
+            index, separator = divmod(index-1, 2)
+            if value.startswith('#'):
+                commented = True
+            elif index == 0 and value.startswith('*'):
+                self._table = self._start_table(value)
+                heading = True
+            yield from self._tokenize(value, index, commented,
+                                      separator, heading)
+        self._table.end_row()
+
+    def _start_table(self, header):
+        name = normalize(header, remove='*')
+        return self._tables.get(name, UnknownTable())
+
+    def _tokenize(self, value, index, commented, separator, heading):
+        if commented:
+            yield value, COMMENT
+        elif separator:
+            yield value, SEPARATOR
+        elif heading:
+            yield value, HEADING
+        else:
+            yield from self._table.tokenize(value, index)
+
+
+class RowSplitter:
+    _space_splitter = re.compile('( {2,})')
+    _pipe_splitter = re.compile(r'((?:^| +)\|(?: +|$))')
+
+    def split(self, row):
+        splitter = (row.startswith('| ') and self._split_from_pipes
+                    or self._split_from_spaces)
+        yield from splitter(row)
+        yield '\n'
+
+    def _split_from_spaces(self, row):
+        yield ''  # Start with (pseudo)separator similarly as with pipes
+        yield from self._space_splitter.split(row)
+
+    def _split_from_pipes(self, row):
+        _, separator, rest = self._pipe_splitter.split(row, 1)
+        yield separator
+        while self._pipe_splitter.search(rest):
+            cell, separator, rest = self._pipe_splitter.split(rest, 1)
+            yield cell
+            yield separator
+        yield rest
+
+
+class Tokenizer:
+    _tokens = None
+
+    def __init__(self):
+        self._index = 0
+
+    def tokenize(self, value):
+        values_and_tokens = self._tokenize(value, self._index)
+        self._index += 1
+        if isinstance(values_and_tokens, type(Token)):
+            values_and_tokens = [(value, values_and_tokens)]
+        return values_and_tokens
+
+    def _tokenize(self, value, index):
+        index = min(index, len(self._tokens) - 1)
+        return self._tokens[index]
+
+    def _is_assign(self, value):
+        if value.endswith('='):
+            value = value[:-1].strip()
+        var = VariableSplitter(value, identifiers='$@&')
+        return var.start == 0 and var.end == len(value)
+
+
+class Comment(Tokenizer):
+    _tokens = (COMMENT,)
+
+
+class Setting(Tokenizer):
+    _tokens = (SETTING, ARGUMENT)
+    _keyword_settings = ('suitesetup', 'suiteprecondition', 'suiteteardown',
+                         'suitepostcondition', 'testsetup', 'tasksetup', 'testprecondition',
+                         'testteardown','taskteardown', 'testpostcondition', 'testtemplate', 'tasktemplate')
+    _import_settings = ('library', 'resource', 'variables')
+    _other_settings = ('documentation', 'metadata', 'forcetags', 'defaulttags',
+                       'testtimeout','tasktimeout')
+    _custom_tokenizer = None
+
+    def __init__(self, template_setter=None):
+        Tokenizer.__init__(self)
+        self._template_setter = template_setter
+
+    def _tokenize(self, value, index):
+        if index == 1 and self._template_setter:
+            self._template_setter(value)
+        if index == 0:
+            normalized = normalize(value)
+            if normalized in self._keyword_settings:
+                self._custom_tokenizer = KeywordCall(support_assign=False)
+            elif normalized in self._import_settings:
+                self._custom_tokenizer = ImportSetting()
+            elif normalized not in self._other_settings:
+                return ERROR
+        elif self._custom_tokenizer:
+            return self._custom_tokenizer.tokenize(value)
+        return Tokenizer._tokenize(self, value, index)
+
+
+class ImportSetting(Tokenizer):
+    _tokens = (IMPORT, ARGUMENT)
+
+
+class TestCaseSetting(Setting):
+    _keyword_settings = ('setup', 'precondition', 'teardown', 'postcondition',
+                         'template')
+    _import_settings = ()
+    _other_settings = ('documentation', 'tags', 'timeout')
+
+    def _tokenize(self, value, index):
+        if index == 0:
+            type = Setting._tokenize(self, value[1:-1], index)
+            return [('[', SYNTAX), (value[1:-1], type), (']', SYNTAX)]
+        return Setting._tokenize(self, value, index)
+
+
+class KeywordSetting(TestCaseSetting):
+    _keyword_settings = ('teardown',)
+    _other_settings = ('documentation', 'arguments', 'return', 'timeout', 'tags')
+
+
+class Variable(Tokenizer):
+    _tokens = (SYNTAX, ARGUMENT)
+
+    def _tokenize(self, value, index):
+        if index == 0 and not self._is_assign(value):
+            return ERROR
+        return Tokenizer._tokenize(self, value, index)
+
+
+class KeywordCall(Tokenizer):
+    _tokens = (KEYWORD, ARGUMENT)
+
+    def __init__(self, support_assign=True):
+        Tokenizer.__init__(self)
+        self._keyword_found = not support_assign
+        self._assigns = 0
+
+    def _tokenize(self, value, index):
+        if not self._keyword_found and self._is_assign(value):
+            self._assigns += 1
+            return SYNTAX  # VariableTokenizer tokenizes this later.
+        if self._keyword_found:
+            return Tokenizer._tokenize(self, value, index - self._assigns)
+        self._keyword_found = True
+        return GherkinTokenizer().tokenize(value, KEYWORD)
+
+
+class GherkinTokenizer:
+    _gherkin_prefix = re.compile('^(Given|When|Then|And|But) ', re.IGNORECASE)
+
+    def tokenize(self, value, token):
+        match = self._gherkin_prefix.match(value)
+        if not match:
+            return [(value, token)]
+        end = match.end()
+        return [(value[:end], GHERKIN), (value[end:], token)]
+
+
+class TemplatedKeywordCall(Tokenizer):
+    _tokens = (ARGUMENT,)
+
+
+class ForLoop(Tokenizer):
+
+    def __init__(self):
+        Tokenizer.__init__(self)
+        self._in_arguments = False
+
+    def _tokenize(self, value, index):
+        token = self._in_arguments and ARGUMENT or SYNTAX
+        if value.upper() in ('IN', 'IN RANGE'):
+            self._in_arguments = True
+        return token
+
+
+class _Table:
+    _tokenizer_class = None
+
+    def __init__(self, prev_tokenizer=None):
+        self._tokenizer = self._tokenizer_class()
+        self._prev_tokenizer = prev_tokenizer
+        self._prev_values_on_row = []
+
+    def tokenize(self, value, index):
+        if self._continues(value, index):
+            self._tokenizer = self._prev_tokenizer
+            yield value, SYNTAX
+        else:
+            yield from self._tokenize(value, index)
+        self._prev_values_on_row.append(value)
+
+    def _continues(self, value, index):
+        return value == '...' and all(self._is_empty(t)
+                                      for t in self._prev_values_on_row)
+
+    def _is_empty(self, value):
+        return value in ('', '\\')
+
+    def _tokenize(self, value, index):
+        return self._tokenizer.tokenize(value)
+
+    def end_row(self):
+        self.__init__(prev_tokenizer=self._tokenizer)
+
+
+class UnknownTable(_Table):
+    _tokenizer_class = Comment
+
+    def _continues(self, value, index):
+        return False
+
+
+class VariableTable(_Table):
+    _tokenizer_class = Variable
+
+
+class SettingTable(_Table):
+    _tokenizer_class = Setting
+
+    def __init__(self, template_setter, prev_tokenizer=None):
+        _Table.__init__(self, prev_tokenizer)
+        self._template_setter = template_setter
+
+    def _tokenize(self, value, index):
+        if index == 0 and normalize(value) == 'testtemplate':
+            self._tokenizer = Setting(self._template_setter)
+        return _Table._tokenize(self, value, index)
+
+    def end_row(self):
+        self.__init__(self._template_setter, prev_tokenizer=self._tokenizer)
+
+
+class TestCaseTable(_Table):
+    _setting_class = TestCaseSetting
+    _test_template = None
+    _default_template = None
+
+    @property
+    def _tokenizer_class(self):
+        if self._test_template or (self._default_template and
+                                   self._test_template is not False):
+            return TemplatedKeywordCall
+        return KeywordCall
+
+    def _continues(self, value, index):
+        return index > 0 and _Table._continues(self, value, index)
+
+    def _tokenize(self, value, index):
+        if index == 0:
+            if value:
+                self._test_template = None
+            return GherkinTokenizer().tokenize(value, TC_KW_NAME)
+        if index == 1 and self._is_setting(value):
+            if self._is_template(value):
+                self._test_template = False
+                self._tokenizer = self._setting_class(self.set_test_template)
+            else:
+                self._tokenizer = self._setting_class()
+        if index == 1 and self._is_for_loop(value):
+            self._tokenizer = ForLoop()
+        if index == 1 and self._is_empty(value):
+            return [(value, SYNTAX)]
+        return _Table._tokenize(self, value, index)
+
+    def _is_setting(self, value):
+        return value.startswith('[') and value.endswith(']')
+
+    def _is_template(self, value):
+        return normalize(value) == '[template]'
+
+    def _is_for_loop(self, value):
+        return value.startswith(':') and normalize(value, remove=':') == 'for'
+
+    def set_test_template(self, template):
+        self._test_template = self._is_template_set(template)
+
+    def set_default_template(self, template):
+        self._default_template = self._is_template_set(template)
+
+    def _is_template_set(self, template):
+        return normalize(template) not in ('', '\\', 'none', '${empty}')
+
+
+class KeywordTable(TestCaseTable):
+    _tokenizer_class = KeywordCall
+    _setting_class = KeywordSetting
+
+    def _is_template(self, value):
+        return False
+
+
+# Following code copied directly from Robot Framework 2.7.5.
+
+class VariableSplitter:
+
+    def __init__(self, string, identifiers):
+        self.identifier = None
+        self.base = None
+        self.index = None
+        self.start = -1
+        self.end = -1
+        self._identifiers = identifiers
+        self._may_have_internal_variables = False
+        try:
+            self._split(string)
+        except ValueError:
+            pass
+        else:
+            self._finalize()
+
+    def get_replaced_base(self, variables):
+        if self._may_have_internal_variables:
+            return variables.replace_string(self.base)
+        return self.base
+
+    def _finalize(self):
+        self.identifier = self._variable_chars[0]
+        self.base = ''.join(self._variable_chars[2:-1])
+        self.end = self.start + len(self._variable_chars)
+        if self._has_list_or_dict_variable_index():
+            self.index = ''.join(self._list_and_dict_variable_index_chars[1:-1])
+            self.end += len(self._list_and_dict_variable_index_chars)
+
+    def _has_list_or_dict_variable_index(self):
+        return self._list_and_dict_variable_index_chars\
+        and self._list_and_dict_variable_index_chars[-1] == ']'
+
+    def _split(self, string):
+        start_index, max_index = self._find_variable(string)
+        self.start = start_index
+        self._open_curly = 1
+        self._state = self._variable_state
+        self._variable_chars = [string[start_index], '{']
+        self._list_and_dict_variable_index_chars = []
+        self._string = string
+        start_index += 2
+        for index, char in enumerate(string[start_index:]):
+            index += start_index  # Giving start to enumerate only in Py 2.6+
+            try:
+                self._state(char, index)
+            except StopIteration:
+                return
+            if index  == max_index and not self._scanning_list_variable_index():
+                return
+
+    def _scanning_list_variable_index(self):
+        return self._state in [self._waiting_list_variable_index_state,
+                               self._list_variable_index_state]
+
+    def _find_variable(self, string):
+        max_end_index = string.rfind('}')
+        if max_end_index == -1:
+            raise ValueError('No variable end found')
+        if self._is_escaped(string, max_end_index):
+            return self._find_variable(string[:max_end_index])
+        start_index = self._find_start_index(string, 1, max_end_index)
+        if start_index == -1:
+            raise ValueError('No variable start found')
+        return start_index, max_end_index
+
+    def _find_start_index(self, string, start, end):
+        index = string.find('{', start, end) - 1
+        if index < 0:
+            return -1
+        if self._start_index_is_ok(string, index):
+            return index
+        return self._find_start_index(string, index+2, end)
+
+    def _start_index_is_ok(self, string, index):
+        return string[index] in self._identifiers\
+        and not self._is_escaped(string, index)
+
+    def _is_escaped(self, string, index):
+        escaped = False
+        while index > 0 and string[index-1] == '\\':
+            index -= 1
+            escaped = not escaped
+        return escaped
+
+    def _variable_state(self, char, index):
+        self._variable_chars.append(char)
+        if char == '}' and not self._is_escaped(self._string, index):
+            self._open_curly -= 1
+            if self._open_curly == 0:
+                if not self._is_list_or_dict_variable():
+                    raise StopIteration
+                self._state = self._waiting_list_variable_index_state
+        elif char in self._identifiers:
+            self._state = self._internal_variable_start_state
+
+    def _is_list_or_dict_variable(self):
+        return self._variable_chars[0] in ('@','&')
+
+    def _internal_variable_start_state(self, char, index):
+        self._state = self._variable_state
+        if char == '{':
+            self._variable_chars.append(char)
+            self._open_curly += 1
+            self._may_have_internal_variables = True
+        else:
+            self._variable_state(char, index)
+
+    def _waiting_list_variable_index_state(self, char, index):
+        if char != '[':
+            raise StopIteration
+        self._list_and_dict_variable_index_chars.append(char)
+        self._state = self._list_variable_index_state
+
+    def _list_variable_index_state(self, char, index):
+        self._list_and_dict_variable_index_chars.append(char)
+        if char == ']':
+            raise StopIteration
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/ruby.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/ruby.py
new file mode 100644
index 0000000000000000000000000000000000000000..6832652a6cf52d22520a14a9adb78c8366b1f724
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/ruby.py
@@ -0,0 +1,518 @@
+"""
+    pygments.lexers.ruby
+    ~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for Ruby and related languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import Lexer, RegexLexer, ExtendedRegexLexer, include, \
+    bygroups, default, LexerContext, do_insertions, words, line_re
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation, Error, Generic, Whitespace
+from pygments.util import shebang_matches
+
+__all__ = ['RubyLexer', 'RubyConsoleLexer', 'FancyLexer']
+
+
+RUBY_OPERATORS = (
+    '*', '**', '-', '+', '-@', '+@', '/', '%', '&', '|', '^', '`', '~',
+    '[]', '[]=', '<<', '>>', '<', '<>', '<=>', '>', '>=', '==', '==='
+)
+
+
+class RubyLexer(ExtendedRegexLexer):
+    """
+    For Ruby source code.
+    """
+
+    name = 'Ruby'
+    url = 'http://www.ruby-lang.org'
+    aliases = ['ruby', 'rb', 'duby']
+    filenames = ['*.rb', '*.rbw', 'Rakefile', '*.rake', '*.gemspec',
+                 '*.rbx', '*.duby', 'Gemfile', 'Vagrantfile']
+    mimetypes = ['text/x-ruby', 'application/x-ruby']
+    version_added = ''
+
+    flags = re.DOTALL | re.MULTILINE
+
+    def heredoc_callback(self, match, ctx):
+        # okay, this is the hardest part of parsing Ruby...
+        # match: 1 = <<[-~]?, 2 = quote? 3 = name 4 = quote? 5 = rest of line
+
+        start = match.start(1)
+        yield start, Operator, match.group(1)        # <<[-~]?
+        yield match.start(2), String.Heredoc, match.group(2)   # quote ", ', `
+        yield match.start(3), String.Delimiter, match.group(3) # heredoc name
+        yield match.start(4), String.Heredoc, match.group(4)   # quote again
+
+        heredocstack = ctx.__dict__.setdefault('heredocstack', [])
+        outermost = not bool(heredocstack)
+        heredocstack.append((match.group(1) in ('<<-', '<<~'), match.group(3)))
+
+        ctx.pos = match.start(5)
+        ctx.end = match.end(5)
+        # this may find other heredocs, so limit the recursion depth
+        if len(heredocstack) < 100:
+            yield from self.get_tokens_unprocessed(context=ctx)
+        else:
+            yield ctx.pos, String.Heredoc, match.group(5)
+        ctx.pos = match.end()
+
+        if outermost:
+            # this is the outer heredoc again, now we can process them all
+            for tolerant, hdname in heredocstack:
+                lines = []
+                for match in line_re.finditer(ctx.text, ctx.pos):
+                    if tolerant:
+                        check = match.group().strip()
+                    else:
+                        check = match.group().rstrip()
+                    if check == hdname:
+                        for amatch in lines:
+                            yield amatch.start(), String.Heredoc, amatch.group()
+                        yield match.start(), String.Delimiter, match.group()
+                        ctx.pos = match.end()
+                        break
+                    else:
+                        lines.append(match)
+                else:
+                    # end of heredoc not found -- error!
+                    for amatch in lines:
+                        yield amatch.start(), Error, amatch.group()
+            ctx.end = len(ctx.text)
+            del heredocstack[:]
+
+    def gen_rubystrings_rules():
+        def intp_regex_callback(self, match, ctx):
+            yield match.start(1), String.Regex, match.group(1)  # begin
+            nctx = LexerContext(match.group(3), 0, ['interpolated-regex'])
+            for i, t, v in self.get_tokens_unprocessed(context=nctx):
+                yield match.start(3)+i, t, v
+            yield match.start(4), String.Regex, match.group(4)  # end[mixounse]*
+            ctx.pos = match.end()
+
+        def intp_string_callback(self, match, ctx):
+            yield match.start(1), String.Other, match.group(1)
+            nctx = LexerContext(match.group(3), 0, ['interpolated-string'])
+            for i, t, v in self.get_tokens_unprocessed(context=nctx):
+                yield match.start(3)+i, t, v
+            yield match.start(4), String.Other, match.group(4)  # end
+            ctx.pos = match.end()
+
+        states = {}
+        states['strings'] = [
+            # easy ones
+            (r'\:@{0,2}[a-zA-Z_]\w*[!?]?', String.Symbol),
+            (words(RUBY_OPERATORS, prefix=r'\:@{0,2}'), String.Symbol),
+            (r":'(\\\\|\\[^\\]|[^'\\])*'", String.Symbol),
+            (r':"', String.Symbol, 'simple-sym'),
+            (r'([a-zA-Z_]\w*)(:)(?!:)',
+             bygroups(String.Symbol, Punctuation)),  # Since Ruby 1.9
+            (r'"', String.Double, 'simple-string-double'),
+            (r"'", String.Single, 'simple-string-single'),
+            (r'(?', '<>', 'ab'):
+            states[name+'-intp-string'] = [
+                (r'\\[\\' + bracecc + ']', String.Other),
+                (lbrace, String.Other, '#push'),
+                (rbrace, String.Other, '#pop'),
+                include('string-intp-escaped'),
+                (r'[\\#' + bracecc + ']', String.Other),
+                (r'[^\\#' + bracecc + ']+', String.Other),
+            ]
+            states['strings'].append((r'%[QWx]?' + lbrace, String.Other,
+                                      name+'-intp-string'))
+            states[name+'-string'] = [
+                (r'\\[\\' + bracecc + ']', String.Other),
+                (lbrace, String.Other, '#push'),
+                (rbrace, String.Other, '#pop'),
+                (r'[\\#' + bracecc + ']', String.Other),
+                (r'[^\\#' + bracecc + ']+', String.Other),
+            ]
+            states['strings'].append((r'%[qsw]' + lbrace, String.Other,
+                                      name+'-string'))
+            states[name+'-regex'] = [
+                (r'\\[\\' + bracecc + ']', String.Regex),
+                (lbrace, String.Regex, '#push'),
+                (rbrace + '[mixounse]*', String.Regex, '#pop'),
+                include('string-intp'),
+                (r'[\\#' + bracecc + ']', String.Regex),
+                (r'[^\\#' + bracecc + ']+', String.Regex),
+            ]
+            states['strings'].append((r'%r' + lbrace, String.Regex,
+                                      name+'-regex'))
+
+        # these must come after %!
+        states['strings'] += [
+            # %r regex
+            (r'(%r([\W_]))((?:\\\2|(?!\2).)*)(\2[mixounse]*)',
+             intp_regex_callback),
+            # regular fancy strings with qsw
+            (r'%[qsw]([\W_])((?:\\\1|(?!\1).)*)\1', String.Other),
+            (r'(%[QWx]([\W_]))((?:\\\2|(?!\2).)*)(\2)',
+             intp_string_callback),
+            # special forms of fancy strings after operators or
+            # in method calls with braces
+            (r'(?<=[-+/*%=<>&!^|~,(])(\s*)(%([\t ])(?:(?:\\\3|(?!\3).)*)\3)',
+             bygroups(Whitespace, String.Other, None)),
+            # and because of fixed width lookbehinds the whole thing a
+            # second time for line startings...
+            (r'^(\s*)(%([\t ])(?:(?:\\\3|(?!\3).)*)\3)',
+             bygroups(Whitespace, String.Other, None)),
+            # all regular fancy strings without qsw
+            (r'(%([^a-zA-Z0-9\s]))((?:\\\2|(?!\2).)*)(\2)',
+             intp_string_callback),
+        ]
+
+        return states
+
+    tokens = {
+        'root': [
+            (r'\A#!.+?$', Comment.Hashbang),
+            (r'#.*?$', Comment.Single),
+            (r'=begin\s.*?\n=end.*?$', Comment.Multiline),
+            # keywords
+            (words((
+                'BEGIN', 'END', 'alias', 'begin', 'break', 'case', 'defined?',
+                'do', 'else', 'elsif', 'end', 'ensure', 'for', 'if', 'in', 'next', 'redo',
+                'rescue', 'raise', 'retry', 'return', 'super', 'then', 'undef',
+                'unless', 'until', 'when', 'while', 'yield'), suffix=r'\b'),
+             Keyword),
+            # start of function, class and module names
+            (r'(module)(\s+)([a-zA-Z_]\w*'
+             r'(?:::[a-zA-Z_]\w*)*)',
+             bygroups(Keyword, Whitespace, Name.Namespace)),
+            (r'(def)(\s+)', bygroups(Keyword, Whitespace), 'funcname'),
+            (r'def(?=[*%&^`~+-/\[<>=])', Keyword, 'funcname'),
+            (r'(class)(\s+)', bygroups(Keyword, Whitespace), 'classname'),
+            # special methods
+            (words((
+                'initialize', 'new', 'loop', 'include', 'extend', 'raise', 'attr_reader',
+                'attr_writer', 'attr_accessor', 'attr', 'catch', 'throw', 'private',
+                'module_function', 'public', 'protected', 'true', 'false', 'nil'),
+                suffix=r'\b'),
+             Keyword.Pseudo),
+            (r'(not|and|or)\b', Operator.Word),
+            (words((
+                'autoload', 'block_given', 'const_defined', 'eql', 'equal', 'frozen', 'include',
+                'instance_of', 'is_a', 'iterator', 'kind_of', 'method_defined', 'nil',
+                'private_method_defined', 'protected_method_defined',
+                'public_method_defined', 'respond_to', 'tainted'), suffix=r'\?'),
+             Name.Builtin),
+            (r'(chomp|chop|exit|gsub|sub)!', Name.Builtin),
+            (words((
+                'Array', 'Float', 'Integer', 'String', '__id__', '__send__', 'abort',
+                'ancestors', 'at_exit', 'autoload', 'binding', 'callcc', 'caller',
+                'catch', 'chomp', 'chop', 'class_eval', 'class_variables',
+                'clone', 'const_defined?', 'const_get', 'const_missing', 'const_set',
+                'constants', 'display', 'dup', 'eval', 'exec', 'exit', 'extend', 'fail', 'fork',
+                'format', 'freeze', 'getc', 'gets', 'global_variables', 'gsub',
+                'hash', 'id', 'included_modules', 'inspect', 'instance_eval',
+                'instance_method', 'instance_methods',
+                'instance_variable_get', 'instance_variable_set', 'instance_variables',
+                'lambda', 'load', 'local_variables', 'loop',
+                'method', 'method_missing', 'methods', 'module_eval', 'name',
+                'object_id', 'open', 'p', 'print', 'printf', 'private_class_method',
+                'private_instance_methods',
+                'private_methods', 'proc', 'protected_instance_methods',
+                'protected_methods', 'public_class_method',
+                'public_instance_methods', 'public_methods',
+                'putc', 'puts', 'raise', 'rand', 'readline', 'readlines', 'require',
+                'scan', 'select', 'self', 'send', 'set_trace_func', 'singleton_methods', 'sleep',
+                'split', 'sprintf', 'srand', 'sub', 'syscall', 'system', 'taint',
+                'test', 'throw', 'to_a', 'to_s', 'trace_var', 'trap', 'untaint',
+                'untrace_var', 'warn'), prefix=r'(?~!:])|'
+             r'(?<=(?:\s|;)when\s)|'
+             r'(?<=(?:\s|;)or\s)|'
+             r'(?<=(?:\s|;)and\s)|'
+             r'(?<=\.index\s)|'
+             r'(?<=\.scan\s)|'
+             r'(?<=\.sub\s)|'
+             r'(?<=\.sub!\s)|'
+             r'(?<=\.gsub\s)|'
+             r'(?<=\.gsub!\s)|'
+             r'(?<=\.match\s)|'
+             r'(?<=(?:\s|;)if\s)|'
+             r'(?<=(?:\s|;)elsif\s)|'
+             r'(?<=^when\s)|'
+             r'(?<=^index\s)|'
+             r'(?<=^scan\s)|'
+             r'(?<=^sub\s)|'
+             r'(?<=^gsub\s)|'
+             r'(?<=^sub!\s)|'
+             r'(?<=^gsub!\s)|'
+             r'(?<=^match\s)|'
+             r'(?<=^if\s)|'
+             r'(?<=^elsif\s)'
+             r')(\s*)(/)', bygroups(Text, String.Regex), 'multiline-regex'),
+            # multiline regex (in method calls or subscripts)
+            (r'(?<=\(|,|\[)/', String.Regex, 'multiline-regex'),
+            # multiline regex (this time the funny no whitespace rule)
+            (r'(\s+)(/)(?![\s=])', bygroups(Whitespace, String.Regex),
+             'multiline-regex'),
+            # lex numbers and ignore following regular expressions which
+            # are division operators in fact (grrrr. i hate that. any
+            # better ideas?)
+            # since pygments 0.7 we also eat a "?" operator after numbers
+            # so that the char operator does not work. Chars are not allowed
+            # there so that you can use the ternary operator.
+            # stupid example:
+            #   x>=0?n[x]:""
+            (r'(0_?[0-7]+(?:_[0-7]+)*)(\s*)([/?])?',
+             bygroups(Number.Oct, Whitespace, Operator)),
+            (r'(0x[0-9A-Fa-f]+(?:_[0-9A-Fa-f]+)*)(\s*)([/?])?',
+             bygroups(Number.Hex, Whitespace, Operator)),
+            (r'(0b[01]+(?:_[01]+)*)(\s*)([/?])?',
+             bygroups(Number.Bin, Whitespace, Operator)),
+            (r'([\d]+(?:_\d+)*)(\s*)([/?])?',
+             bygroups(Number.Integer, Whitespace, Operator)),
+            # Names
+            (r'@@[a-zA-Z_]\w*', Name.Variable.Class),
+            (r'@[a-zA-Z_]\w*', Name.Variable.Instance),
+            (r'\$\w+', Name.Variable.Global),
+            (r'\$[!@&`\'+~=/\\,;.<>_*$?:"^-]', Name.Variable.Global),
+            (r'\$-[0adFiIlpvw]', Name.Variable.Global),
+            (r'::', Operator),
+            include('strings'),
+            # chars
+            (r'\?(\\[MC]-)*'  # modifiers
+             r'(\\([\\abefnrstv#"\']|x[a-fA-F0-9]{1,2}|[0-7]{1,3})|\S)'
+             r'(?!\w)',
+             String.Char),
+            (r'[A-Z]\w+', Name.Constant),
+            # this is needed because ruby attributes can look
+            # like keywords (class) or like this: ` ?!?
+            (words(RUBY_OPERATORS, prefix=r'(\.|::)'),
+             bygroups(Operator, Name.Operator)),
+            (r'(\.|::)([a-zA-Z_]\w*[!?]?|[*%&^`~+\-/\[<>=])',
+             bygroups(Operator, Name)),
+            (r'[a-zA-Z_]\w*[!?]?', Name),
+            (r'(\[|\]|\*\*|<>?|>=|<=|<=>|=~|={3}|'
+             r'!~|&&?|\|\||\.{1,3})', Operator),
+            (r'[-+/*%=<>&!^|~]=?', Operator),
+            (r'[(){};,/?:\\]', Punctuation),
+            (r'\s+', Whitespace)
+        ],
+        'funcname': [
+            (r'\(', Punctuation, 'defexpr'),
+            (r'(?:([a-zA-Z_]\w*)(\.))?'  # optional scope name, like "self."
+             r'('
+                r'[a-zA-Z\u0080-\uffff][a-zA-Z0-9_\u0080-\uffff]*[!?=]?'  # method name
+                r'|!=|!~|=~|\*\*?|[-+!~]@?|[/%&|^]|<=>|<[<=]?|>[>=]?|===?'  # or operator override
+                r'|\[\]=?'  # or element reference/assignment override
+                r'|`'  # or the undocumented backtick override
+             r')',
+             bygroups(Name.Class, Operator, Name.Function), '#pop'),
+            default('#pop')
+        ],
+        'classname': [
+            (r'\(', Punctuation, 'defexpr'),
+            (r'<<', Operator, '#pop'),
+            (r'[A-Z_]\w*', Name.Class, '#pop'),
+            default('#pop')
+        ],
+        'defexpr': [
+            (r'(\))(\.|::)?', bygroups(Punctuation, Operator), '#pop'),
+            (r'\(', Operator, '#push'),
+            include('root')
+        ],
+        'in-intp': [
+            (r'\{', String.Interpol, '#push'),
+            (r'\}', String.Interpol, '#pop'),
+            include('root'),
+        ],
+        'string-intp': [
+            (r'#\{', String.Interpol, 'in-intp'),
+            (r'#@@?[a-zA-Z_]\w*', String.Interpol),
+            (r'#\$[a-zA-Z_]\w*', String.Interpol)
+        ],
+        'string-intp-escaped': [
+            include('string-intp'),
+            (r'\\([\\abefnrstv#"\']|x[a-fA-F0-9]{1,2}|[0-7]{1,3})',
+             String.Escape)
+        ],
+        'interpolated-regex': [
+            include('string-intp'),
+            (r'[\\#]', String.Regex),
+            (r'[^\\#]+', String.Regex),
+        ],
+        'interpolated-string': [
+            include('string-intp'),
+            (r'[\\#]', String.Other),
+            (r'[^\\#]+', String.Other),
+        ],
+        'multiline-regex': [
+            include('string-intp'),
+            (r'\\\\', String.Regex),
+            (r'\\/', String.Regex),
+            (r'[\\#]', String.Regex),
+            (r'[^\\/#]+', String.Regex),
+            (r'/[mixounse]*', String.Regex, '#pop'),
+        ],
+        'end-part': [
+            (r'.+', Comment.Preproc, '#pop')
+        ]
+    }
+    tokens.update(gen_rubystrings_rules())
+
+    def analyse_text(text):
+        return shebang_matches(text, r'ruby(1\.\d)?')
+
+
+class RubyConsoleLexer(Lexer):
+    """
+    For Ruby interactive console (**irb**) output.
+    """
+    name = 'Ruby irb session'
+    aliases = ['rbcon', 'irb']
+    mimetypes = ['text/x-ruby-shellsession']
+    url = 'https://www.ruby-lang.org'
+    version_added = ''
+    _example = 'rbcon/console'
+
+    _prompt_re = re.compile(r'irb\([a-zA-Z_]\w*\):\d{3}:\d+[>*"\'] '
+                            r'|>> |\?> ')
+
+    def get_tokens_unprocessed(self, text):
+        rblexer = RubyLexer(**self.options)
+
+        curcode = ''
+        insertions = []
+        for match in line_re.finditer(text):
+            line = match.group()
+            m = self._prompt_re.match(line)
+            if m is not None:
+                end = m.end()
+                insertions.append((len(curcode),
+                                   [(0, Generic.Prompt, line[:end])]))
+                curcode += line[end:]
+            else:
+                if curcode:
+                    yield from do_insertions(
+                        insertions, rblexer.get_tokens_unprocessed(curcode))
+                    curcode = ''
+                    insertions = []
+                yield match.start(), Generic.Output, line
+        if curcode:
+            yield from do_insertions(
+                insertions, rblexer.get_tokens_unprocessed(curcode))
+
+
+class FancyLexer(RegexLexer):
+    """
+    Pygments Lexer For Fancy.
+
+    Fancy is a self-hosted, pure object-oriented, dynamic,
+    class-based, concurrent general-purpose programming language
+    running on Rubinius, the Ruby VM.
+    """
+    name = 'Fancy'
+    url = 'https://github.com/bakkdoor/fancy'
+    filenames = ['*.fy', '*.fancypack']
+    aliases = ['fancy', 'fy']
+    mimetypes = ['text/x-fancysrc']
+    version_added = '1.5'
+
+    tokens = {
+        # copied from PerlLexer:
+        'balanced-regex': [
+            (r'/(\\\\|\\[^\\]|[^/\\])*/[egimosx]*', String.Regex, '#pop'),
+            (r'!(\\\\|\\[^\\]|[^!\\])*![egimosx]*', String.Regex, '#pop'),
+            (r'\\(\\\\|[^\\])*\\[egimosx]*', String.Regex, '#pop'),
+            (r'\{(\\\\|\\[^\\]|[^}\\])*\}[egimosx]*', String.Regex, '#pop'),
+            (r'<(\\\\|\\[^\\]|[^>\\])*>[egimosx]*', String.Regex, '#pop'),
+            (r'\[(\\\\|\\[^\\]|[^\]\\])*\][egimosx]*', String.Regex, '#pop'),
+            (r'\((\\\\|\\[^\\]|[^)\\])*\)[egimosx]*', String.Regex, '#pop'),
+            (r'@(\\\\|\\[^\\]|[^@\\])*@[egimosx]*', String.Regex, '#pop'),
+            (r'%(\\\\|\\[^\\]|[^%\\])*%[egimosx]*', String.Regex, '#pop'),
+            (r'\$(\\\\|\\[^\\]|[^$\\])*\$[egimosx]*', String.Regex, '#pop'),
+        ],
+        'root': [
+            (r'\s+', Whitespace),
+
+            # balanced delimiters (copied from PerlLexer):
+            (r's\{(\\\\|\\[^\\]|[^}\\])*\}\s*', String.Regex, 'balanced-regex'),
+            (r's<(\\\\|\\[^\\]|[^>\\])*>\s*', String.Regex, 'balanced-regex'),
+            (r's\[(\\\\|\\[^\\]|[^\]\\])*\]\s*', String.Regex, 'balanced-regex'),
+            (r's\((\\\\|\\[^\\]|[^)\\])*\)\s*', String.Regex, 'balanced-regex'),
+            (r'm?/(\\\\|\\[^\\]|[^///\n])*/[gcimosx]*', String.Regex),
+            (r'm(?=[/!\\{<\[(@%$])', String.Regex, 'balanced-regex'),
+
+            # Comments
+            (r'#(.*?)\n', Comment.Single),
+            # Symbols
+            (r'\'([^\'\s\[\](){}]+|\[\])', String.Symbol),
+            # Multi-line DoubleQuotedString
+            (r'"""(\\\\|\\[^\\]|[^\\])*?"""', String),
+            # DoubleQuotedString
+            (r'"(\\\\|\\[^\\]|[^"\\])*"', String),
+            # keywords
+            (r'(def|class|try|catch|finally|retry|return|return_local|match|'
+             r'case|->|=>)\b', Keyword),
+            # constants
+            (r'(self|super|nil|false|true)\b', Name.Constant),
+            (r'[(){};,/?|:\\]', Punctuation),
+            # names
+            (words((
+                'Object', 'Array', 'Hash', 'Directory', 'File', 'Class', 'String',
+                'Number', 'Enumerable', 'FancyEnumerable', 'Block', 'TrueClass',
+                'NilClass', 'FalseClass', 'Tuple', 'Symbol', 'Stack', 'Set',
+                'FancySpec', 'Method', 'Package', 'Range'), suffix=r'\b'),
+             Name.Builtin),
+            # functions
+            (r'[a-zA-Z](\w|[-+?!=*/^><%])*:', Name.Function),
+            # operators, must be below functions
+            (r'[-+*/~,<>=&!?%^\[\].$]+', Operator),
+            (r'[A-Z]\w*', Name.Constant),
+            (r'@[a-zA-Z_]\w*', Name.Variable.Instance),
+            (r'@@[a-zA-Z_]\w*', Name.Variable.Class),
+            ('@@?', Operator),
+            (r'[a-zA-Z_]\w*', Name),
+            # numbers - / checks are necessary to avoid mismarking regexes,
+            # see comment in RubyLexer
+            (r'(0[oO]?[0-7]+(?:_[0-7]+)*)(\s*)([/?])?',
+             bygroups(Number.Oct, Whitespace, Operator)),
+            (r'(0[xX][0-9A-Fa-f]+(?:_[0-9A-Fa-f]+)*)(\s*)([/?])?',
+             bygroups(Number.Hex, Whitespace, Operator)),
+            (r'(0[bB][01]+(?:_[01]+)*)(\s*)([/?])?',
+             bygroups(Number.Bin, Whitespace, Operator)),
+            (r'([\d]+(?:_\d+)*)(\s*)([/?])?',
+             bygroups(Number.Integer, Whitespace, Operator)),
+            (r'\d+([eE][+-]?[0-9]+)|\d+\.\d+([eE][+-]?[0-9]+)?', Number.Float),
+            (r'\d+', Number.Integer)
+        ]
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rust.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rust.py
new file mode 100644
index 0000000000000000000000000000000000000000..6c9e6217a4e88ca15012c5ea57181a8eaa37e0cf
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/rust.py
@@ -0,0 +1,222 @@
+"""
+    pygments.lexers.rust
+    ~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for the Rust language.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, include, bygroups, words, default
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation, Whitespace
+
+__all__ = ['RustLexer']
+
+
+class RustLexer(RegexLexer):
+    """
+    Lexer for the Rust programming language (version 1.47).
+    """
+    name = 'Rust'
+    url = 'https://www.rust-lang.org/'
+    filenames = ['*.rs', '*.rs.in']
+    aliases = ['rust', 'rs']
+    mimetypes = ['text/rust', 'text/x-rust']
+    version_added = '1.6'
+
+    keyword_types = (words((
+        'u8', 'u16', 'u32', 'u64', 'u128', 'i8', 'i16', 'i32', 'i64', 'i128',
+        'usize', 'isize', 'f32', 'f64', 'char', 'str', 'bool',
+    ), suffix=r'\b'), Keyword.Type)
+
+    builtin_funcs_types = (words((
+        'Copy', 'Send', 'Sized', 'Sync', 'Unpin',
+        'Drop', 'Fn', 'FnMut', 'FnOnce', 'drop',
+        'Box', 'ToOwned', 'Clone',
+        'PartialEq', 'PartialOrd', 'Eq', 'Ord',
+        'AsRef', 'AsMut', 'Into', 'From', 'Default',
+        'Iterator', 'Extend', 'IntoIterator', 'DoubleEndedIterator',
+        'ExactSizeIterator',
+        'Option', 'Some', 'None',
+        'Result', 'Ok', 'Err',
+        'String', 'ToString', 'Vec',
+    ), suffix=r'\b'), Name.Builtin)
+
+    builtin_macros = (words((
+        'asm', 'assert', 'assert_eq', 'assert_ne', 'cfg', 'column',
+        'compile_error', 'concat', 'concat_idents', 'dbg', 'debug_assert',
+        'debug_assert_eq', 'debug_assert_ne', 'env', 'eprint', 'eprintln',
+        'file', 'format', 'format_args', 'format_args_nl', 'global_asm',
+        'include', 'include_bytes', 'include_str',
+        'is_aarch64_feature_detected',
+        'is_arm_feature_detected',
+        'is_mips64_feature_detected',
+        'is_mips_feature_detected',
+        'is_powerpc64_feature_detected',
+        'is_powerpc_feature_detected',
+        'is_x86_feature_detected',
+        'line', 'llvm_asm', 'log_syntax', 'macro_rules', 'matches',
+        'module_path', 'option_env', 'panic', 'print', 'println', 'stringify',
+        'thread_local', 'todo', 'trace_macros', 'unimplemented', 'unreachable',
+        'vec', 'write', 'writeln',
+    ), suffix=r'!'), Name.Function.Magic)
+
+    tokens = {
+        'root': [
+            # rust allows a file to start with a shebang, but if the first line
+            # starts with #![ then it's not a shebang but a crate attribute.
+            (r'#![^[\r\n].*$', Comment.Preproc),
+            default('base'),
+        ],
+        'base': [
+            # Whitespace and Comments
+            (r'\n', Whitespace),
+            (r'\s+', Whitespace),
+            (r'//!.*?\n', String.Doc),
+            (r'///(\n|[^/].*?\n)', String.Doc),
+            (r'//(.*?)\n', Comment.Single),
+            (r'/\*\*(\n|[^/*])', String.Doc, 'doccomment'),
+            (r'/\*!', String.Doc, 'doccomment'),
+            (r'/\*', Comment.Multiline, 'comment'),
+
+            # Macro parameters
+            (r"""\$([a-zA-Z_]\w*|\(,?|\),?|,?)""", Comment.Preproc),
+            # Keywords
+            (words(('as', 'async', 'await', 'box', 'const', 'crate', 'dyn',
+                    'else', 'extern', 'for', 'if', 'impl', 'in', 'loop',
+                    'match', 'move', 'mut', 'pub', 'ref', 'return', 'static',
+                    'super', 'trait', 'unsafe', 'use', 'where', 'while'),
+                   suffix=r'\b'), Keyword),
+            (words(('abstract', 'become', 'do', 'final', 'macro', 'override',
+                    'priv', 'typeof', 'try', 'unsized', 'virtual', 'yield'),
+                   suffix=r'\b'), Keyword.Reserved),
+            (r'(true|false)\b', Keyword.Constant),
+            (r'self\b', Name.Builtin.Pseudo),
+            (r'mod\b', Keyword, 'modname'),
+            (r'let\b', Keyword.Declaration),
+            (r'fn\b', Keyword, 'funcname'),
+            (r'(struct|enum|type|union)\b', Keyword, 'typename'),
+            (r'(default)(\s+)(type|fn)\b', bygroups(Keyword, Whitespace, Keyword)),
+            keyword_types,
+            (r'[sS]elf\b', Name.Builtin.Pseudo),
+            # Prelude (taken from Rust's src/libstd/prelude.rs)
+            builtin_funcs_types,
+            builtin_macros,
+            # Path separators, so types don't catch them.
+            (r'::\b', Punctuation),
+            # Types in positions.
+            (r'(?::|->)', Punctuation, 'typename'),
+            # Labels
+            (r'(break|continue)(\b\s*)(\'[A-Za-z_]\w*)?',
+             bygroups(Keyword, Text.Whitespace, Name.Label)),
+
+            # Character literals
+            (r"""'(\\['"\\nrt]|\\x[0-7][0-9a-fA-F]|\\0"""
+             r"""|\\u\{[0-9a-fA-F]{1,6}\}|.)'""",
+             String.Char),
+            (r"""b'(\\['"\\nrt]|\\x[0-9a-fA-F]{2}|\\0"""
+             r"""|\\u\{[0-9a-fA-F]{1,6}\}|.)'""",
+             String.Char),
+
+            # Binary literals
+            (r'0b[01_]+', Number.Bin, 'number_lit'),
+            # Octal literals
+            (r'0o[0-7_]+', Number.Oct, 'number_lit'),
+            # Hexadecimal literals
+            (r'0[xX][0-9a-fA-F_]+', Number.Hex, 'number_lit'),
+            # Decimal literals
+            (r'[0-9][0-9_]*(\.[0-9_]+[eE][+\-]?[0-9_]+|'
+             r'\.[0-9_]*(?!\.)|[eE][+\-]?[0-9_]+)', Number.Float,
+             'number_lit'),
+            (r'[0-9][0-9_]*', Number.Integer, 'number_lit'),
+
+            # String literals
+            (r'b"', String, 'bytestring'),
+            (r'"', String, 'string'),
+            (r'(?s)b?r(#*)".*?"\1', String),
+
+            # Lifetime names
+            (r"'", Operator, 'lifetime'),
+
+            # Operators and Punctuation
+            (r'\.\.=?', Operator),
+            (r'[{}()\[\],.;]', Punctuation),
+            (r'[+\-*/%&|<>^!~@=:?]', Operator),
+
+            # Identifiers
+            (r'[a-zA-Z_]\w*', Name),
+            # Raw identifiers
+            (r'r#[a-zA-Z_]\w*', Name),
+
+            # Attributes
+            (r'#!?\[', Comment.Preproc, 'attribute['),
+
+            # Misc
+            # Lone hashes: not used in Rust syntax, but allowed in macro
+            # arguments, most famously for quote::quote!()
+            (r'#', Punctuation),
+        ],
+        'comment': [
+            (r'[^*/]+', Comment.Multiline),
+            (r'/\*', Comment.Multiline, '#push'),
+            (r'\*/', Comment.Multiline, '#pop'),
+            (r'[*/]', Comment.Multiline),
+        ],
+        'doccomment': [
+            (r'[^*/]+', String.Doc),
+            (r'/\*', String.Doc, '#push'),
+            (r'\*/', String.Doc, '#pop'),
+            (r'[*/]', String.Doc),
+        ],
+        'modname': [
+            (r'\s+', Whitespace),
+            (r'[a-zA-Z_]\w*', Name.Namespace, '#pop'),
+            default('#pop'),
+        ],
+        'funcname': [
+            (r'\s+', Whitespace),
+            (r'[a-zA-Z_]\w*', Name.Function, '#pop'),
+            default('#pop'),
+        ],
+        'typename': [
+            (r'\s+', Whitespace),
+            (r'&', Keyword.Pseudo),
+            (r"'", Operator, 'lifetime'),
+            builtin_funcs_types,
+            keyword_types,
+            (r'[a-zA-Z_]\w*', Name.Class, '#pop'),
+            default('#pop'),
+        ],
+        'lifetime': [
+            (r"(static|_)", Name.Builtin),
+            (r"[a-zA-Z_]+\w*", Name.Attribute),
+            default('#pop'),
+        ],
+        'number_lit': [
+            (r'[ui](8|16|32|64|size)', Keyword, '#pop'),
+            (r'f(32|64)', Keyword, '#pop'),
+            default('#pop'),
+        ],
+        'string': [
+            (r'"', String, '#pop'),
+            (r"""\\['"\\nrt]|\\x[0-7][0-9a-fA-F]|\\0"""
+             r"""|\\u\{[0-9a-fA-F]{1,6}\}""", String.Escape),
+            (r'[^\\"]+', String),
+            (r'\\', String),
+        ],
+        'bytestring': [
+            (r"""\\x[89a-fA-F][0-9a-fA-F]""", String.Escape),
+            include('string'),
+        ],
+        'attribute_common': [
+            (r'"', String, 'string'),
+            (r'\[', Comment.Preproc, 'attribute['),
+        ],
+        'attribute[': [
+            include('attribute_common'),
+            (r'\]', Comment.Preproc, '#pop'),
+            (r'[^"\]\[]+', Comment.Preproc),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/sas.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/sas.py
new file mode 100644
index 0000000000000000000000000000000000000000..35ee8541a9c8817f4050957bc62238a94f938e38
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/sas.py
@@ -0,0 +1,227 @@
+"""
+    pygments.lexers.sas
+    ~~~~~~~~~~~~~~~~~~~
+
+    Lexer for SAS.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+from pygments.lexer import RegexLexer, include, words
+from pygments.token import Comment, Keyword, Name, Number, String, Text, \
+    Other, Generic
+
+__all__ = ['SASLexer']
+
+
+class SASLexer(RegexLexer):
+    """
+    For SAS files.
+    """
+    # Syntax from syntax/sas.vim by James Kidd 
+
+    name      = 'SAS'
+    aliases   = ['sas']
+    filenames = ['*.SAS', '*.sas']
+    mimetypes = ['text/x-sas', 'text/sas', 'application/x-sas']
+    url = 'https://en.wikipedia.org/wiki/SAS_(software)'
+    version_added = '2.2'
+    flags     = re.IGNORECASE | re.MULTILINE
+
+    builtins_macros = (
+        "bquote", "nrbquote", "cmpres", "qcmpres", "compstor", "datatyp",
+        "display", "do", "else", "end", "eval", "global", "goto", "if",
+        "index", "input", "keydef", "label", "left", "length", "let",
+        "local", "lowcase", "macro", "mend", "nrquote",
+        "nrstr", "put", "qleft", "qlowcase", "qscan",
+        "qsubstr", "qsysfunc", "qtrim", "quote", "qupcase", "scan",
+        "str", "substr", "superq", "syscall", "sysevalf", "sysexec",
+        "sysfunc", "sysget", "syslput", "sysprod", "sysrc", "sysrput",
+        "then", "to", "trim", "unquote", "until", "upcase", "verify",
+        "while", "window"
+    )
+
+    builtins_conditionals = (
+        "do", "if", "then", "else", "end", "until", "while"
+    )
+
+    builtins_statements = (
+        "abort", "array", "attrib", "by", "call", "cards", "cards4",
+        "catname", "continue", "datalines", "datalines4", "delete", "delim",
+        "delimiter", "display", "dm", "drop", "endsas", "error", "file",
+        "filename", "footnote", "format", "goto", "in", "infile", "informat",
+        "input", "keep", "label", "leave", "length", "libname", "link",
+        "list", "lostcard", "merge", "missing", "modify", "options", "output",
+        "out", "page", "put", "redirect", "remove", "rename", "replace",
+        "retain", "return", "select", "set", "skip", "startsas", "stop",
+        "title", "update", "waitsas", "where", "window", "x", "systask"
+    )
+
+    builtins_sql = (
+        "add", "and", "alter", "as", "cascade", "check", "create",
+        "delete", "describe", "distinct", "drop", "foreign", "from",
+        "group", "having", "index", "insert", "into", "in", "key", "like",
+        "message", "modify", "msgtype", "not", "null", "on", "or",
+        "order", "primary", "references", "reset", "restrict", "select",
+        "set", "table", "unique", "update", "validate", "view", "where"
+    )
+
+    builtins_functions = (
+        "abs", "addr", "airy", "arcos", "arsin", "atan", "attrc",
+        "attrn", "band", "betainv", "blshift", "bnot", "bor",
+        "brshift", "bxor", "byte", "cdf", "ceil", "cexist", "cinv",
+        "close", "cnonct", "collate", "compbl", "compound",
+        "compress", "cos", "cosh", "css", "curobs", "cv", "daccdb",
+        "daccdbsl", "daccsl", "daccsyd", "dacctab", "dairy", "date",
+        "datejul", "datepart", "datetime", "day", "dclose", "depdb",
+        "depdbsl", "depsl", "depsyd",
+        "deptab", "dequote", "dhms", "dif", "digamma",
+        "dim", "dinfo", "dnum", "dopen", "doptname", "doptnum",
+        "dread", "dropnote", "dsname", "erf", "erfc", "exist", "exp",
+        "fappend", "fclose", "fcol", "fdelete", "fetch", "fetchobs",
+        "fexist", "fget", "fileexist", "filename", "fileref",
+        "finfo", "finv", "fipname", "fipnamel", "fipstate", "floor",
+        "fnonct", "fnote", "fopen", "foptname", "foptnum", "fpoint",
+        "fpos", "fput", "fread", "frewind", "frlen", "fsep", "fuzz",
+        "fwrite", "gaminv", "gamma", "getoption", "getvarc", "getvarn",
+        "hbound", "hms", "hosthelp", "hour", "ibessel", "index",
+        "indexc", "indexw", "input", "inputc", "inputn", "int",
+        "intck", "intnx", "intrr", "irr", "jbessel", "juldate",
+        "kurtosis", "lag", "lbound", "left", "length", "lgamma",
+        "libname", "libref", "log", "log10", "log2", "logpdf", "logpmf",
+        "logsdf", "lowcase", "max", "mdy", "mean", "min", "minute",
+        "mod", "month", "mopen", "mort", "n", "netpv", "nmiss",
+        "normal", "note", "npv", "open", "ordinal", "pathname",
+        "pdf", "peek", "peekc", "pmf", "point", "poisson", "poke",
+        "probbeta", "probbnml", "probchi", "probf", "probgam",
+        "probhypr", "probit", "probnegb", "probnorm", "probt",
+        "put", "putc", "putn", "qtr", "quote", "ranbin", "rancau",
+        "ranexp", "rangam", "range", "rank", "rannor", "ranpoi",
+        "rantbl", "rantri", "ranuni", "repeat", "resolve", "reverse",
+        "rewind", "right", "round", "saving", "scan", "sdf", "second",
+        "sign", "sin", "sinh", "skewness", "soundex", "spedis",
+        "sqrt", "std", "stderr", "stfips", "stname", "stnamel",
+        "substr", "sum", "symget", "sysget", "sysmsg", "sysprod",
+        "sysrc", "system", "tan", "tanh", "time", "timepart", "tinv",
+        "tnonct", "today", "translate", "tranwrd", "trigamma",
+        "trim", "trimn", "trunc", "uniform", "upcase", "uss", "var",
+        "varfmt", "varinfmt", "varlabel", "varlen", "varname",
+        "varnum", "varray", "varrayx", "vartype", "verify", "vformat",
+        "vformatd", "vformatdx", "vformatn", "vformatnx", "vformatw",
+        "vformatwx", "vformatx", "vinarray", "vinarrayx", "vinformat",
+        "vinformatd", "vinformatdx", "vinformatn", "vinformatnx",
+        "vinformatw", "vinformatwx", "vinformatx", "vlabel",
+        "vlabelx", "vlength", "vlengthx", "vname", "vnamex", "vtype",
+        "vtypex", "weekday", "year", "yyq", "zipfips", "zipname",
+        "zipnamel", "zipstate"
+    )
+
+    tokens = {
+        'root': [
+            include('comments'),
+            include('proc-data'),
+            include('cards-datalines'),
+            include('logs'),
+            include('general'),
+            (r'.', Text),
+        ],
+        # SAS is multi-line regardless, but * is ended by ;
+        'comments': [
+            (r'^\s*\*.*?;', Comment),
+            (r'/\*.*?\*/', Comment),
+            (r'^\s*\*(.|\n)*?;', Comment.Multiline),
+            (r'/[*](.|\n)*?[*]/', Comment.Multiline),
+        ],
+        # Special highlight for proc, data, quit, run
+        'proc-data': [
+            (r'(^|;)\s*(proc \w+|data|run|quit)[\s;]',
+             Keyword.Reserved),
+        ],
+        # Special highlight cards and datalines
+        'cards-datalines': [
+            (r'^\s*(datalines|cards)\s*;\s*$', Keyword, 'data'),
+        ],
+        'data': [
+            (r'(.|\n)*^\s*;\s*$', Other, '#pop'),
+        ],
+        # Special highlight for put NOTE|ERROR|WARNING (order matters)
+        'logs': [
+            (r'\n?^\s*%?put ', Keyword, 'log-messages'),
+        ],
+        'log-messages': [
+            (r'NOTE(:|-).*', Generic, '#pop'),
+            (r'WARNING(:|-).*', Generic.Emph, '#pop'),
+            (r'ERROR(:|-).*', Generic.Error, '#pop'),
+            include('general'),
+        ],
+        'general': [
+            include('keywords'),
+            include('vars-strings'),
+            include('special'),
+            include('numbers'),
+        ],
+        # Keywords, statements, functions, macros
+        'keywords': [
+            (words(builtins_statements,
+                   prefix = r'\b',
+                   suffix = r'\b'),
+             Keyword),
+            (words(builtins_sql,
+                   prefix = r'\b',
+                   suffix = r'\b'),
+             Keyword),
+            (words(builtins_conditionals,
+                   prefix = r'\b',
+                   suffix = r'\b'),
+             Keyword),
+            (words(builtins_macros,
+                   prefix = r'%',
+                   suffix = r'\b'),
+             Name.Builtin),
+            (words(builtins_functions,
+                   prefix = r'\b',
+                   suffix = r'\('),
+             Name.Builtin),
+        ],
+        # Strings and user-defined variables and macros (order matters)
+        'vars-strings': [
+            (r'&[a-z_]\w{0,31}\.?', Name.Variable),
+            (r'%[a-z_]\w{0,31}', Name.Function),
+            (r'\'', String, 'string_squote'),
+            (r'"', String, 'string_dquote'),
+        ],
+        'string_squote': [
+            ('\'', String, '#pop'),
+            (r'\\\\|\\"|\\\n', String.Escape),
+            # AFAIK, macro variables are not evaluated in single quotes
+            # (r'&', Name.Variable, 'validvar'),
+            (r'[^$\'\\]+', String),
+            (r'[$\'\\]', String),
+        ],
+        'string_dquote': [
+            (r'"', String, '#pop'),
+            (r'\\\\|\\"|\\\n', String.Escape),
+            (r'&', Name.Variable, 'validvar'),
+            (r'[^$&"\\]+', String),
+            (r'[$"\\]', String),
+        ],
+        'validvar': [
+            (r'[a-z_]\w{0,31}\.?', Name.Variable, '#pop'),
+        ],
+        # SAS numbers and special variables
+        'numbers': [
+            (r'\b[+-]?([0-9]+(\.[0-9]+)?|\.[0-9]+|\.)(E[+-]?[0-9]+)?i?\b',
+             Number),
+        ],
+        'special': [
+            (r'(null|missing|_all_|_automatic_|_character_|_n_|'
+             r'_infile_|_name_|_null_|_numeric_|_user_|_webout_)',
+             Keyword.Constant),
+        ],
+        # 'operators': [
+        #     (r'(-|=|<=|>=|<|>|<>|&|!=|'
+        #      r'\||\*|\+|\^|/|!|~|~=)', Operator)
+        # ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/savi.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/savi.py
new file mode 100644
index 0000000000000000000000000000000000000000..548a05665fb166f2e3bbd400a3a09630b709eb4e
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/savi.py
@@ -0,0 +1,171 @@
+"""
+    pygments.lexers.savi
+    ~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for Savi.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, bygroups, include
+from pygments.token import Whitespace, Keyword, Name, String, Number, \
+  Operator, Punctuation, Comment, Generic, Error
+
+__all__ = ['SaviLexer']
+
+
+# The canonical version of this file can be found in the following repository,
+# where it is kept in sync with any language changes, as well as the other
+# pygments-like lexers that are maintained for use with other tools:
+# - https://github.com/savi-lang/savi/blob/main/tooling/pygments/lexers/savi.py
+#
+# If you're changing this file in the pygments repository, please ensure that
+# any changes you make are also propagated to the official Savi repository,
+# in order to avoid accidental clobbering of your changes later when an update
+# from the Savi repository flows forward into the pygments repository.
+#
+# If you're changing this file in the Savi repository, please ensure that
+# any changes you make are also reflected in the other pygments-like lexers
+# (rouge, vscode, etc) so that all of the lexers can be kept cleanly in sync.
+
+class SaviLexer(RegexLexer):
+    """
+    For Savi source code.
+
+    .. versionadded: 2.10
+    """
+
+    name = 'Savi'
+    url = 'https://github.com/savi-lang/savi'
+    aliases = ['savi']
+    filenames = ['*.savi']
+    version_added = ''
+
+    tokens = {
+      "root": [
+        # Line Comment
+        (r'//.*?$', Comment.Single),
+
+        # Doc Comment
+        (r'::.*?$', Comment.Single),
+
+        # Capability Operator
+        (r'(\')(\w+)(?=[^\'])', bygroups(Operator, Name)),
+
+        # Double-Quote String
+        (r'\w?"', String.Double, "string.double"),
+
+        # Single-Char String
+        (r"'", String.Char, "string.char"),
+
+        # Type Name
+        (r'(_?[A-Z]\w*)', Name.Class),
+
+        # Nested Type Name
+        (r'(\.)(\s*)(_?[A-Z]\w*)', bygroups(Punctuation, Whitespace, Name.Class)),
+
+        # Declare
+        (r'^([ \t]*)(:\w+)',
+          bygroups(Whitespace, Name.Tag),
+          "decl"),
+
+        # Error-Raising Calls/Names
+        (r'((\w+|\+|\-|\*)\!)', Generic.Deleted),
+
+        # Numeric Values
+        (r'\b\d([\d_]*(\.[\d_]+)?)\b', Number),
+
+        # Hex Numeric Values
+        (r'\b0x([0-9a-fA-F_]+)\b', Number.Hex),
+
+        # Binary Numeric Values
+        (r'\b0b([01_]+)\b', Number.Bin),
+
+        # Function Call (with braces)
+        (r'\w+(?=\()', Name.Function),
+
+        # Function Call (with receiver)
+        (r'(\.)(\s*)(\w+)', bygroups(Punctuation, Whitespace, Name.Function)),
+
+        # Function Call (with self receiver)
+        (r'(@)(\w+)', bygroups(Punctuation, Name.Function)),
+
+        # Parenthesis
+        (r'\(', Punctuation, "root"),
+        (r'\)', Punctuation, "#pop"),
+
+        # Brace
+        (r'\{', Punctuation, "root"),
+        (r'\}', Punctuation, "#pop"),
+
+        # Bracket
+        (r'\[', Punctuation, "root"),
+        (r'(\])(\!)', bygroups(Punctuation, Generic.Deleted), "#pop"),
+        (r'\]', Punctuation, "#pop"),
+
+        # Punctuation
+        (r'[,;:\.@]', Punctuation),
+
+        # Piping Operators
+        (r'(\|\>)', Operator),
+
+        # Branching Operators
+        (r'(\&\&|\|\||\?\?|\&\?|\|\?|\.\?)', Operator),
+
+        # Comparison Operators
+        (r'(\<\=\>|\=\~|\=\=|\<\=|\>\=|\<|\>)', Operator),
+
+        # Arithmetic Operators
+        (r'(\+|\-|\/|\*|\%)', Operator),
+
+        # Assignment Operators
+        (r'(\=)', Operator),
+
+        # Other Operators
+        (r'(\!|\<\<|\<|\&|\|)', Operator),
+
+        # Identifiers
+        (r'\b\w+\b', Name),
+
+        # Whitespace
+        (r'[ \t\r]+\n*|\n+', Whitespace),
+      ],
+
+      # Declare (nested rules)
+      "decl": [
+        (r'\b[a-z_]\w*\b(?!\!)', Keyword.Declaration),
+        (r':', Punctuation, "#pop"),
+        (r'\n', Whitespace, "#pop"),
+        include("root"),
+      ],
+
+      # Double-Quote String (nested rules)
+      "string.double": [
+        (r'\\\(', String.Interpol, "string.interpolation"),
+        (r'\\u[0-9a-fA-F]{4}', String.Escape),
+        (r'\\x[0-9a-fA-F]{2}', String.Escape),
+        (r'\\[bfnrt\\\']', String.Escape),
+        (r'\\"', String.Escape),
+        (r'"', String.Double, "#pop"),
+        (r'[^\\"]+', String.Double),
+        (r'.', Error),
+      ],
+
+      # Single-Char String (nested rules)
+      "string.char": [
+        (r'\\u[0-9a-fA-F]{4}', String.Escape),
+        (r'\\x[0-9a-fA-F]{2}', String.Escape),
+        (r'\\[bfnrt\\\']', String.Escape),
+        (r"\\'", String.Escape),
+        (r"'", String.Char, "#pop"),
+        (r"[^\\']+", String.Char),
+        (r'.', Error),
+      ],
+
+      # Interpolation inside String (nested rules)
+      "string.interpolation": [
+        (r"\)", String.Interpol, "#pop"),
+        include("root"),
+      ]
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/scdoc.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/scdoc.py
new file mode 100644
index 0000000000000000000000000000000000000000..9b2e01da1f8443a0f7ddf8952531fb94f1e35e2e
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/scdoc.py
@@ -0,0 +1,85 @@
+"""
+    pygments.lexers.scdoc
+    ~~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for scdoc, a simple man page generator.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, include, bygroups, using, this
+from pygments.token import Text, Comment, Keyword, String, Generic
+
+__all__ = ['ScdocLexer']
+
+
+class ScdocLexer(RegexLexer):
+    """
+    `scdoc` is a simple man page generator for POSIX systems written in C99.
+    """
+    name = 'scdoc'
+    url = 'https://git.sr.ht/~sircmpwn/scdoc'
+    aliases = ['scdoc', 'scd']
+    filenames = ['*.scd', '*.scdoc']
+    version_added = '2.5'
+    flags = re.MULTILINE
+
+    tokens = {
+        'root': [
+            # comment
+            (r'^(;.+\n)', bygroups(Comment)),
+
+            # heading with pound prefix
+            (r'^(#)([^#].+\n)', bygroups(Generic.Heading, Text)),
+            (r'^(#{2})(.+\n)', bygroups(Generic.Subheading, Text)),
+            # bulleted lists
+            (r'^(\s*)([*-])(\s)(.+\n)',
+            bygroups(Text, Keyword, Text, using(this, state='inline'))),
+            # numbered lists
+            (r'^(\s*)(\.+\.)( .+\n)',
+            bygroups(Text, Keyword, using(this, state='inline'))),
+            # quote
+            (r'^(\s*>\s)(.+\n)', bygroups(Keyword, Generic.Emph)),
+            # text block
+            (r'^(```\n)([\w\W]*?)(^```$)', bygroups(String, Text, String)),
+
+            include('inline'),
+        ],
+        'inline': [
+            # escape
+            (r'\\.', Text),
+            # underlines
+            (r'(\s)(_[^_]+_)(\W|\n)', bygroups(Text, Generic.Emph, Text)),
+            # bold
+            (r'(\s)(\*[^*]+\*)(\W|\n)', bygroups(Text, Generic.Strong, Text)),
+            # inline code
+            (r'`[^`]+`', String.Backtick),
+
+            # general text, must come last!
+            (r'[^\\\s]+', Text),
+            (r'.', Text),
+        ],
+    }
+
+    def analyse_text(text):
+        """We checks for bold and underline text with * and _. Also
+        every scdoc file must start with a strictly defined first line."""
+        result = 0
+
+        if '*' in text:
+            result += 0.01
+
+        if '_' in text:
+            result += 0.01
+
+        # name(section) ["left_footer" ["center_header"]]
+        first_line = text.partition('\n')[0]
+        scdoc_preamble_pattern = r'^.*\([1-7]\)( "[^"]+"){0,2}$'
+
+        if re.search(scdoc_preamble_pattern, first_line):
+            result += 0.5
+
+        return result
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/scripting.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/scripting.py
new file mode 100644
index 0000000000000000000000000000000000000000..2adb7bbd0194cd2482a6c2d99d573a8486084bf8
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/scripting.py
@@ -0,0 +1,1638 @@
+"""
+    pygments.lexers.scripting
+    ~~~~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for scripting and embedded languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import RegexLexer, include, bygroups, default, combined, \
+    words
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation, Error, Whitespace, Other
+from pygments.util import get_bool_opt, get_list_opt
+
+__all__ = ['LuaLexer', 'LuauLexer', 'MoonScriptLexer', 'ChaiscriptLexer', 'LSLLexer',
+           'AppleScriptLexer', 'RexxLexer', 'MOOCodeLexer', 'HybrisLexer',
+           'EasytrieveLexer', 'JclLexer', 'MiniScriptLexer']
+
+
+def all_lua_builtins():
+    from pygments.lexers._lua_builtins import MODULES
+    return [w for values in MODULES.values() for w in values]
+
+class LuaLexer(RegexLexer):
+    """
+    For Lua source code.
+
+    Additional options accepted:
+
+    `func_name_highlighting`
+        If given and ``True``, highlight builtin function names
+        (default: ``True``).
+    `disabled_modules`
+        If given, must be a list of module names whose function names
+        should not be highlighted. By default all modules are highlighted.
+
+        To get a list of allowed modules have a look into the
+        `_lua_builtins` module:
+
+        .. sourcecode:: pycon
+
+            >>> from pygments.lexers._lua_builtins import MODULES
+            >>> MODULES.keys()
+            ['string', 'coroutine', 'modules', 'io', 'basic', ...]
+    """
+
+    name = 'Lua'
+    url = 'https://www.lua.org/'
+    aliases = ['lua']
+    filenames = ['*.lua', '*.wlua']
+    mimetypes = ['text/x-lua', 'application/x-lua']
+    version_added = ''
+
+    _comment_multiline = r'(?:--\[(?P=*)\[[\w\W]*?\](?P=level)\])'
+    _comment_single = r'(?:--.*$)'
+    _space = r'(?:\s+(?!\s))'
+    _s = rf'(?:{_comment_multiline}|{_comment_single}|{_space})'
+    # A lookahead-safe version of _s that avoids catastrophic backtracking.
+    # The _comment_multiline pattern contains [\w\W]*? which, when used
+    # inside a lookahead with a * quantifier, causes exponential blowup.
+    # This version skips only whitespace; comments between an identifier
+    # and a following [.:] or ( are rare enough to sacrifice.
+    _s_la = r'\s'
+    _name = r'(?:[^\W\d]\w*)'
+
+    tokens = {
+        'root': [
+            # Lua allows a file to start with a shebang.
+            (r'#!.*', Comment.Preproc),
+            default('base'),
+        ],
+        'ws': [
+            (_comment_multiline, Comment.Multiline),
+            (_comment_single, Comment.Single),
+            (_space, Whitespace),
+        ],
+        'base': [
+            include('ws'),
+
+            (r'(?i)0x[\da-f]*(\.[\da-f]*)?(p[+-]?\d+)?', Number.Hex),
+            (r'(?i)(\d*\.\d+|\d+\.\d*)(e[+-]?\d+)?', Number.Float),
+            (r'(?i)\d+e[+-]?\d+', Number.Float),
+            (r'\d+', Number.Integer),
+
+            # multiline strings
+            (r'(?s)\[(=*)\[.*?\]\1\]', String),
+
+            (r'::', Punctuation, 'label'),
+            (r'\.{3}', Punctuation),
+            (r'[=<>|~&+\-*/%#^]+|\.\.', Operator),
+            (r'[\[\]{}().,:;]+', Punctuation),
+            (r'(and|or|not)\b', Operator.Word),
+
+            (words([
+                'break', 'do', 'else', 'elseif', 'end', 'for', 'if', 'in',
+                'repeat', 'return', 'then', 'until', 'while'
+            ], suffix=r'\b'), Keyword.Reserved),
+            (r'goto\b', Keyword.Reserved, 'goto'),
+            (r'(local)\b', Keyword.Declaration),
+            (r'(true|false|nil)\b', Keyword.Constant),
+
+            (r'(function)\b', Keyword.Reserved, 'funcname'),
+
+            (words(all_lua_builtins(), suffix=r"\b"), Name.Builtin),
+            (fr'[A-Za-z_]\w*(?={_s_la}*[.:])', Name.Variable, 'varname'),
+            (fr'[A-Za-z_]\w*(?={_s_la}*\()', Name.Function),
+            (r'[A-Za-z_]\w*', Name.Variable),
+
+            ("'", String.Single, combined('stringescape', 'sqs')),
+            ('"', String.Double, combined('stringescape', 'dqs'))
+        ],
+
+        'varname': [
+            include('ws'),
+            (r'\.\.', Operator, '#pop'),
+            (r'[.:]', Punctuation),
+            (rf'{_name}(?={_s_la}*[.:])', Name.Property),
+            (rf'{_name}(?={_s_la}*\()', Name.Function, '#pop'),
+            (_name, Name.Property, '#pop'),
+        ],
+
+        'funcname': [
+            include('ws'),
+            (r'[.:]', Punctuation),
+            (rf'{_name}(?={_s_la}*[.:])', Name.Class),
+            (_name, Name.Function, '#pop'),
+            # inline function
+            (r'\(', Punctuation, '#pop'),
+        ],
+
+        'goto': [
+            include('ws'),
+            (_name, Name.Label, '#pop'),
+        ],
+
+        'label': [
+            include('ws'),
+            (r'::', Punctuation, '#pop'),
+            (_name, Name.Label),
+        ],
+
+        'stringescape': [
+            (r'\\([abfnrtv\\"\']|[\r\n]{1,2}|z\s*|x[0-9a-fA-F]{2}|\d{1,3}|'
+             r'u\{[0-9a-fA-F]+\})', String.Escape),
+        ],
+
+        'sqs': [
+            (r"'", String.Single, '#pop'),
+            (r"[^\\']+", String.Single),
+        ],
+
+        'dqs': [
+            (r'"', String.Double, '#pop'),
+            (r'[^\\"]+', String.Double),
+        ]
+    }
+
+    def __init__(self, **options):
+        self.func_name_highlighting = get_bool_opt(
+            options, 'func_name_highlighting', True)
+        self.disabled_modules = get_list_opt(options, 'disabled_modules', [])
+
+        self._functions = set()
+        if self.func_name_highlighting:
+            from pygments.lexers._lua_builtins import MODULES
+            for mod, func in MODULES.items():
+                if mod not in self.disabled_modules:
+                    self._functions.update(func)
+        RegexLexer.__init__(self, **options)
+
+    def get_tokens_unprocessed(self, text):
+        for index, token, value in \
+                RegexLexer.get_tokens_unprocessed(self, text):
+            if token is Name.Builtin and value not in self._functions:
+                if '.' in value:
+                    a, b = value.split('.')
+                    yield index, Name, a
+                    yield index + len(a), Punctuation, '.'
+                    yield index + len(a) + 1, Name, b
+                else:
+                    yield index, Name, value
+                continue
+            yield index, token, value
+
+def _luau_make_expression(should_pop, _s, _s_la):
+    temp_list = [
+        (r'0[xX][\da-fA-F_]*', Number.Hex, '#pop'),
+        (r'0[bB][\d_]*', Number.Bin, '#pop'),
+        (r'\.?\d[\d_]*(?:\.[\d_]*)?(?:[eE][+-]?[\d_]+)?', Number.Float, '#pop'),
+
+        (words((
+            'true', 'false', 'nil'
+        ), suffix=r'\b'), Keyword.Constant, '#pop'),
+
+        (r'\[(=*)\[[.\n]*?\]\1\]', String, '#pop'),
+
+        (r'(\.)([a-zA-Z_]\w*)(?=%s*[({"\'])', bygroups(Punctuation, Name.Function), '#pop'),
+        (r'(\.)([a-zA-Z_]\w*)', bygroups(Punctuation, Name.Variable), '#pop'),
+
+        (rf'[a-zA-Z_]\w*(?:\.[a-zA-Z_]\w*)*(?={_s_la}*[({{"\'])', Name.Other, '#pop'),
+        (r'[a-zA-Z_]\w*(?:\.[a-zA-Z_]\w*)*', Name, '#pop'),
+    ]
+    if should_pop:
+        return temp_list
+    return [entry[:2] for entry in temp_list]
+
+def _luau_make_expression_special(should_pop):
+    temp_list = [
+        (r'\{', Punctuation, ('#pop', 'closing_brace_base', 'expression')),
+        (r'\(', Punctuation, ('#pop', 'closing_parenthesis_base', 'expression')),
+
+        (r'::?', Punctuation, ('#pop', 'type_end', 'type_start')),
+
+        (r"'", String.Single, ('#pop', 'string_single')),
+        (r'"', String.Double, ('#pop', 'string_double')),
+        (r'`', String.Backtick, ('#pop', 'string_interpolated')),
+    ]
+    if should_pop:
+        return temp_list
+    return [(entry[0], entry[1], entry[2][1:]) for entry in temp_list]
+
+class LuauLexer(RegexLexer):
+    """
+    For Luau source code.
+
+    Additional options accepted:
+
+    `include_luau_builtins`
+        If given and ``True``, automatically highlight Luau builtins
+        (default: ``True``).
+    `include_roblox_builtins`
+        If given and ``True``, automatically highlight Roblox-specific builtins
+        (default: ``False``).
+    `additional_builtins`
+        If given, must be a list of additional builtins to highlight.
+    `disabled_builtins`
+        If given, must be a list of builtins that will not be highlighted.
+    """
+
+    name = 'Luau'
+    url = 'https://luau-lang.org/'
+    aliases = ['luau']
+    filenames = ['*.luau']
+    version_added = '2.18'
+
+    _comment_multiline = r'(?:--\[(?P=*)\[[\w\W]*?\](?P=level)\])'
+    _comment_single = r'(?:--.*$)'
+    _s = r'(?:{}|{}|{})'.format(_comment_multiline, _comment_single, r'\s+')
+    # Lookahead-safe version — avoids catastrophic backtracking from
+    # [\w\W]*? inside _comment_multiline when combined with * quantifier.
+    _s_la = r'\s'
+
+    tokens = {
+        'root': [
+            (r'#!.*', Comment.Hashbang, 'base'),
+            default('base'),
+        ],
+
+        'ws': [
+            (_comment_multiline, Comment.Multiline),
+            (_comment_single, Comment.Single),
+            (r'\s+', Whitespace),
+        ],
+
+        'base': [
+            include('ws'),
+
+            *_luau_make_expression_special(False),
+            (r'\.\.\.', Punctuation),
+
+            (rf'type\b(?={_s}+[a-zA-Z_])', Keyword.Reserved, 'type_declaration'),
+            (rf'export\b(?={_s}+[a-zA-Z_])', Keyword.Reserved),
+
+            (r'(?:\.\.|//|[+\-*\/%^<>=])=?', Operator, 'expression'),
+            (r'~=', Operator, 'expression'),
+
+            (words((
+                'and', 'or', 'not'
+            ), suffix=r'\b'), Operator.Word, 'expression'),
+
+            (words((
+                'elseif', 'for', 'if', 'in', 'repeat', 'return', 'until',
+                'while'), suffix=r'\b'), Keyword.Reserved, 'expression'),
+            (r'local\b', Keyword.Declaration, 'expression'),
+
+            (r'function\b', Keyword.Reserved, ('expression', 'func_name')),
+
+            (r'[\])};]+', Punctuation),
+
+            include('expression_static'),
+            *_luau_make_expression(False, _s, _s_la),
+
+            (r'[\[.,]', Punctuation, 'expression'),
+        ],
+        'expression_static': [
+            (words((
+                'break', 'continue', 'do', 'else', 'elseif', 'end', 'for',
+                'if', 'in', 'repeat', 'return', 'then', 'until', 'while'),
+                suffix=r'\b'), Keyword.Reserved),
+        ],
+        'expression': [
+            include('ws'),
+
+            (r'if\b', Keyword.Reserved, ('ternary', 'expression')),
+
+            (r'local\b', Keyword.Declaration),
+            *_luau_make_expression_special(True),
+            (r'\.\.\.', Punctuation, '#pop'),
+
+            (r'function\b', Keyword.Reserved, 'func_name'),
+
+            include('expression_static'),
+            *_luau_make_expression(True, _s, _s_la),
+
+            default('#pop'),
+        ],
+        'ternary': [
+            include('ws'),
+
+            (r'else\b', Keyword.Reserved, '#pop'),
+            (words((
+                'then', 'elseif',
+            ), suffix=r'\b'), Operator.Reserved, 'expression'),
+
+            default('#pop'),
+        ],
+
+        'closing_brace_pop': [
+            (r'\}', Punctuation, '#pop'),
+        ],
+        'closing_parenthesis_pop': [
+            (r'\)', Punctuation, '#pop'),
+        ],
+        'closing_gt_pop': [
+            (r'>', Punctuation, '#pop'),
+        ],
+
+        'closing_parenthesis_base': [
+            include('closing_parenthesis_pop'),
+            include('base'),
+        ],
+        'closing_parenthesis_type': [
+            include('closing_parenthesis_pop'),
+            include('type'),
+        ],
+        'closing_brace_base': [
+            include('closing_brace_pop'),
+            include('base'),
+        ],
+        'closing_brace_type': [
+            include('closing_brace_pop'),
+            include('type'),
+        ],
+        'closing_gt_type': [
+            include('closing_gt_pop'),
+            include('type'),
+        ],
+
+        'string_escape': [
+            (r'\\z\s*', String.Escape),
+            (r'\\(?:[abfnrtvz\\"\'`\{\n])|[\r\n]{1,2}|x[\da-fA-F]{2}|\d{1,3}|'
+             r'u\{\}[\da-fA-F]*\}', String.Escape),
+        ],
+        'string_single': [
+            include('string_escape'),
+
+            (r"'", String.Single, "#pop"),
+            (r"[^\\']+", String.Single),
+        ],
+        'string_double': [
+            include('string_escape'),
+
+            (r'"', String.Double, "#pop"),
+            (r'[^\\"]+', String.Double),
+        ],
+        'string_interpolated': [
+            include('string_escape'),
+
+            (r'\{', Punctuation, ('closing_brace_base', 'expression')),
+
+            (r'`', String.Backtick, "#pop"),
+            (r'[^\\`\{]+', String.Backtick),
+        ],
+
+        'func_name': [
+            include('ws'),
+
+            (r'[.:]', Punctuation),
+            (rf'[a-zA-Z_]\w*(?={_s_la}*[.:])', Name.Class),
+            (r'[a-zA-Z_]\w*', Name.Function),
+
+            (r'<', Punctuation, 'closing_gt_type'),
+
+            (r'\(', Punctuation, '#pop'),
+        ],
+
+        'type': [
+            include('ws'),
+
+            (r'\(', Punctuation, 'closing_parenthesis_type'),
+            (r'\{', Punctuation, 'closing_brace_type'),
+            (r'<', Punctuation, 'closing_gt_type'),
+
+            (r"'", String.Single, 'string_single'),
+            (r'"', String.Double, 'string_double'),
+
+            (r'[|&\.,\[\]:=]+', Punctuation),
+            (r'->', Punctuation),
+
+            (r'typeof\(', Name.Builtin, ('closing_parenthesis_base',
+                                         'expression')),
+            (r'[a-zA-Z_]\w*', Name.Class),
+        ],
+        'type_start': [
+            include('ws'),
+
+            (r'\(', Punctuation, ('#pop', 'closing_parenthesis_type')),
+            (r'\{', Punctuation, ('#pop', 'closing_brace_type')),
+            (r'<', Punctuation, ('#pop', 'closing_gt_type')),
+
+            (r"'", String.Single, ('#pop', 'string_single')),
+            (r'"', String.Double, ('#pop', 'string_double')),
+
+            (r'typeof\(', Name.Builtin, ('#pop', 'closing_parenthesis_base',
+                                         'expression')),
+            (r'[a-zA-Z_]\w*', Name.Class, '#pop'),
+        ],
+        'type_end': [
+            include('ws'),
+
+            (r'[|&\.]', Punctuation, 'type_start'),
+            (r'->', Punctuation, 'type_start'),
+
+            (r'<', Punctuation, 'closing_gt_type'),
+
+            default('#pop'),
+        ],
+        'type_declaration': [
+            include('ws'),
+
+            (r'[a-zA-Z_]\w*', Name.Class),
+            (r'<', Punctuation, 'closing_gt_type'),
+
+            (r'=', Punctuation, ('#pop', 'type_end', 'type_start')),
+        ],
+    }
+
+    def __init__(self, **options):
+        self.include_luau_builtins = get_bool_opt(
+            options, 'include_luau_builtins', True)
+        self.include_roblox_builtins = get_bool_opt(
+            options, 'include_roblox_builtins', False)
+        self.additional_builtins = get_list_opt(options, 'additional_builtins', [])
+        self.disabled_builtins = get_list_opt(options, 'disabled_builtins', [])
+
+        self._builtins = set(self.additional_builtins)
+        if self.include_luau_builtins:
+            from pygments.lexers._luau_builtins import LUAU_BUILTINS
+            self._builtins.update(LUAU_BUILTINS)
+        if self.include_roblox_builtins:
+            from pygments.lexers._luau_builtins import ROBLOX_BUILTINS
+            self._builtins.update(ROBLOX_BUILTINS)
+        if self.additional_builtins:
+            self._builtins.update(self.additional_builtins)
+        self._builtins.difference_update(self.disabled_builtins)
+
+        RegexLexer.__init__(self, **options)
+
+    def get_tokens_unprocessed(self, text):
+        for index, token, value in \
+                RegexLexer.get_tokens_unprocessed(self, text):
+            if token is Name or token is Name.Other:
+                split_value = value.split('.')
+                complete_value = []
+                new_index = index
+                for position in range(len(split_value), 0, -1):
+                    potential_string = '.'.join(split_value[:position])
+                    if potential_string in self._builtins:
+                        yield index, Name.Builtin, potential_string
+                        new_index += len(potential_string)
+
+                        if complete_value:
+                            yield new_index, Punctuation, '.'
+                            new_index += 1
+                        break
+                    complete_value.insert(0, split_value[position - 1])
+
+                for position, substring in enumerate(complete_value):
+                    if position + 1 == len(complete_value):
+                        if token is Name:
+                            yield new_index, Name.Variable, substring
+                            continue
+                        yield new_index, Name.Function, substring
+                        continue
+                    yield new_index, Name.Variable, substring
+                    new_index += len(substring)
+                    yield new_index, Punctuation, '.'
+                    new_index += 1
+
+                continue
+            yield index, token, value
+
+class MoonScriptLexer(LuaLexer):
+    """
+    For MoonScript source code.
+    """
+
+    name = 'MoonScript'
+    url = 'http://moonscript.org'
+    aliases = ['moonscript', 'moon']
+    filenames = ['*.moon']
+    mimetypes = ['text/x-moonscript', 'application/x-moonscript']
+    version_added = '1.5'
+
+    tokens = {
+        'root': [
+            (r'#!(.*?)$', Comment.Preproc),
+            default('base'),
+        ],
+        'base': [
+            ('--.*$', Comment.Single),
+            (r'(?i)(\d*\.\d+|\d+\.\d*)(e[+-]?\d+)?', Number.Float),
+            (r'(?i)\d+e[+-]?\d+', Number.Float),
+            (r'(?i)0x[0-9a-f]*', Number.Hex),
+            (r'\d+', Number.Integer),
+            (r'\n', Whitespace),
+            (r'[^\S\n]+', Text),
+            (r'(?s)\[(=*)\[.*?\]\1\]', String),
+            (r'(->|=>)', Name.Function),
+            (r':[a-zA-Z_]\w*', Name.Variable),
+            (r'(==|!=|~=|<=|>=|\.\.\.|\.\.|[=+\-*/%^<>#!.\\:])', Operator),
+            (r'[;,]', Punctuation),
+            (r'[\[\]{}()]', Keyword.Type),
+            (r'[a-zA-Z_]\w*:', Name.Variable),
+            (words((
+                'class', 'extends', 'if', 'then', 'super', 'do', 'with',
+                'import', 'export', 'while', 'elseif', 'return', 'for', 'in',
+                'from', 'when', 'using', 'else', 'and', 'or', 'not', 'switch',
+                'break'), suffix=r'\b'),
+             Keyword),
+            (r'(true|false|nil)\b', Keyword.Constant),
+            (r'(and|or|not)\b', Operator.Word),
+            (r'(self)\b', Name.Builtin.Pseudo),
+            (r'@@?([a-zA-Z_]\w*)?', Name.Variable.Class),
+            (r'[A-Z]\w*', Name.Class),  # proper name
+            (words(all_lua_builtins(), suffix=r"\b"), Name.Builtin),
+            (r'[A-Za-z_]\w*', Name),
+            ("'", String.Single, combined('stringescape', 'sqs')),
+            ('"', String.Double, combined('stringescape', 'dqs'))
+        ],
+        'stringescape': [
+            (r'''\\([abfnrtv\\"']|\d{1,3})''', String.Escape)
+        ],
+        'strings': [
+            (r'[^#\\\'"]+', String),
+            # note that strings are multi-line.
+            # hashmarks, quotes and backslashes must be parsed one at a time
+        ],
+        'interpoling_string': [
+            (r'\}', String.Interpol, "#pop"),
+            include('base')
+        ],
+        'dqs': [
+            (r'"', String.Double, '#pop'),
+            (r'\\.|\'', String),  # double-quoted string don't need ' escapes
+            (r'#\{', String.Interpol, "interpoling_string"),
+            (r'#', String),
+            include('strings')
+        ],
+        'sqs': [
+            (r"'", String.Single, '#pop'),
+            (r'#|\\.|"', String),  # single quoted strings don't need " escapses
+            include('strings')
+        ]
+    }
+
+    def get_tokens_unprocessed(self, text):
+        # set . as Operator instead of Punctuation
+        for index, token, value in LuaLexer.get_tokens_unprocessed(self, text):
+            if token == Punctuation and value == ".":
+                token = Operator
+            yield index, token, value
+
+
+class ChaiscriptLexer(RegexLexer):
+    """
+    For ChaiScript source code.
+    """
+
+    name = 'ChaiScript'
+    url = 'http://chaiscript.com/'
+    aliases = ['chaiscript', 'chai']
+    filenames = ['*.chai']
+    mimetypes = ['text/x-chaiscript', 'application/x-chaiscript']
+    version_added = '2.0'
+
+    flags = re.DOTALL | re.MULTILINE
+
+    tokens = {
+        'commentsandwhitespace': [
+            (r'\s+', Text),
+            (r'//.*?\n', Comment.Single),
+            (r'/\*.*?\*/', Comment.Multiline),
+            (r'^\#.*?\n', Comment.Single)
+        ],
+        'slashstartsregex': [
+            include('commentsandwhitespace'),
+            (r'/(\\.|[^[/\\\n]|\[(\\.|[^\]\\\n])*])+/'
+             r'([gim]+\b|\B)', String.Regex, '#pop'),
+            (r'(?=/)', Text, ('#pop', 'badregex')),
+            default('#pop')
+        ],
+        'badregex': [
+            (r'\n', Text, '#pop')
+        ],
+        'root': [
+            include('commentsandwhitespace'),
+            (r'\n', Text),
+            (r'[^\S\n]+', Text),
+            (r'\+\+|--|~|&&|\?|:|\|\||\\(?=\n)|\.\.'
+             r'(<<|>>>?|==?|!=?|[-<>+*%&|^/])=?', Operator, 'slashstartsregex'),
+            (r'[{(\[;,]', Punctuation, 'slashstartsregex'),
+            (r'[})\].]', Punctuation),
+            (r'[=+\-*/]', Operator),
+            (r'(for|in|while|do|break|return|continue|if|else|'
+             r'throw|try|catch'
+             r')\b', Keyword, 'slashstartsregex'),
+            (r'(var)\b', Keyword.Declaration, 'slashstartsregex'),
+            (r'(attr|def|fun)\b', Keyword.Reserved),
+            (r'(true|false)\b', Keyword.Constant),
+            (r'(eval|throw)\b', Name.Builtin),
+            (r'`\S+`', Name.Builtin),
+            (r'[$a-zA-Z_]\w*', Name.Other),
+            (r'[0-9][0-9]*\.[0-9]+([eE][0-9]+)?[fd]?', Number.Float),
+            (r'0x[0-9a-fA-F]+', Number.Hex),
+            (r'[0-9]+', Number.Integer),
+            (r'"', String.Double, 'dqstring'),
+            (r"'(\\\\|\\[^\\]|[^'\\])*'", String.Single),
+        ],
+        'dqstring': [
+            (r'\$\{[^"}]+?\}', String.Interpol),
+            (r'\$', String.Double),
+            (r'\\\\', String.Double),
+            (r'\\"', String.Double),
+            (r'[^\\"$]+', String.Double),
+            (r'"', String.Double, '#pop'),
+        ],
+    }
+
+
+class LSLLexer(RegexLexer):
+    """
+    For Second Life's Linden Scripting Language source code.
+    """
+
+    name = 'LSL'
+    aliases = ['lsl']
+    filenames = ['*.lsl']
+    mimetypes = ['text/x-lsl']
+    url = 'https://wiki.secondlife.com/wiki/Linden_Scripting_Language'
+    version_added = '2.0'
+
+    flags = re.MULTILINE
+
+    lsl_keywords = r'\b(?:do|else|for|if|jump|return|while)\b'
+    lsl_types = r'\b(?:float|integer|key|list|quaternion|rotation|string|vector)\b'
+    lsl_states = r'\b(?:(?:state)\s+\w+|default)\b'
+    lsl_events = r'\b(?:state_(?:entry|exit)|touch(?:_(?:start|end))?|(?:land_)?collision(?:_(?:start|end))?|timer|listen|(?:no_)?sensor|control|(?:not_)?at_(?:rot_)?target|money|email|run_time_permissions|changed|attach|dataserver|moving_(?:start|end)|link_message|(?:on|object)_rez|remote_data|http_re(?:sponse|quest)|path_update|transaction_result)\b'
+    lsl_functions_builtin = r'\b(?:ll(?:ReturnObjectsBy(?:ID|Owner)|Json(?:2List|[GS]etValue|ValueType)|Sin|Cos|Tan|Atan2|Sqrt|Pow|Abs|Fabs|Frand|Floor|Ceil|Round|Vec(?:Mag|Norm|Dist)|Rot(?:Between|2(?:Euler|Fwd|Left|Up))|(?:Euler|Axes)2Rot|Whisper|(?:Region|Owner)?Say|Shout|Listen(?:Control|Remove)?|Sensor(?:Repeat|Remove)?|Detected(?:Name|Key|Owner|Type|Pos|Vel|Grab|Rot|Group|LinkNumber)|Die|Ground|Wind|(?:[GS]et)(?:AnimationOverride|MemoryLimit|PrimMediaParams|ParcelMusicURL|Object(?:Desc|Name)|PhysicsMaterial|Status|Scale|Color|Alpha|Texture|Pos|Rot|Force|Torque)|ResetAnimationOverride|(?:Scale|Offset|Rotate)Texture|(?:Rot)?Target(?:Remove)?|(?:Stop)?MoveToTarget|Apply(?:Rotational)?Impulse|Set(?:KeyframedMotion|ContentType|RegionPos|(?:Angular)?Velocity|Buoyancy|HoverHeight|ForceAndTorque|TimerEvent|ScriptState|Damage|TextureAnim|Sound(?:Queueing|Radius)|Vehicle(?:Type|(?:Float|Vector|Rotation)Param)|(?:Touch|Sit)?Text|Camera(?:Eye|At)Offset|PrimitiveParams|ClickAction|Link(?:Alpha|Color|PrimitiveParams(?:Fast)?|Texture(?:Anim)?|Camera|Media)|RemoteScriptAccessPin|PayPrice|LocalRot)|ScaleByFactor|Get(?:(?:Max|Min)ScaleFactor|ClosestNavPoint|StaticPath|SimStats|Env|PrimitiveParams|Link(?:PrimitiveParams|Number(?:OfSides)?|Key|Name|Media)|HTTPHeader|FreeURLs|Object(?:Details|PermMask|PrimCount)|Parcel(?:MaxPrims|Details|Prim(?:Count|Owners))|Attached|(?:SPMax|Free|Used)Memory|Region(?:Name|TimeDilation|FPS|Corner|AgentCount)|Root(?:Position|Rotation)|UnixTime|(?:Parcel|Region)Flags|(?:Wall|GMT)clock|SimulatorHostname|BoundingBox|GeometricCenter|Creator|NumberOf(?:Prims|NotecardLines|Sides)|Animation(?:List)?|(?:Camera|Local)(?:Pos|Rot)|Vel|Accel|Omega|Time(?:stamp|OfDay)|(?:Object|CenterOf)?Mass|MassMKS|Energy|Owner|(?:Owner)?Key|SunDirection|Texture(?:Offset|Scale|Rot)|Inventory(?:Number|Name|Key|Type|Creator|PermMask)|Permissions(?:Key)?|StartParameter|List(?:Length|EntryType)|Date|Agent(?:Size|Info|Language|List)|LandOwnerAt|NotecardLine|Script(?:Name|State))|(?:Get|Reset|GetAndReset)Time|PlaySound(?:Slave)?|LoopSound(?:Master|Slave)?|(?:Trigger|Stop|Preload)Sound|(?:(?:Get|Delete)Sub|Insert)String|To(?:Upper|Lower)|Give(?:InventoryList|Money)|RezObject|(?:Stop)?LookAt|Sleep|CollisionFilter|(?:Take|Release)Controls|DetachFromAvatar|AttachToAvatar(?:Temp)?|InstantMessage|(?:GetNext)?Email|StopHover|MinEventDelay|RotLookAt|String(?:Length|Trim)|(?:Start|Stop)Animation|TargetOmega|RequestPermissions|(?:Create|Break)Link|BreakAllLinks|(?:Give|Remove)Inventory|Water|PassTouches|Request(?:Agent|Inventory)Data|TeleportAgent(?:Home|GlobalCoords)?|ModifyLand|CollisionSound|ResetScript|MessageLinked|PushObject|PassCollisions|AxisAngle2Rot|Rot2(?:Axis|Angle)|A(?:cos|sin)|AngleBetween|AllowInventoryDrop|SubStringIndex|List2(?:CSV|Integer|Json|Float|String|Key|Vector|Rot|List(?:Strided)?)|DeleteSubList|List(?:Statistics|Sort|Randomize|(?:Insert|Find|Replace)List)|EdgeOfWorld|AdjustSoundVolume|Key2Name|TriggerSoundLimited|EjectFromLand|(?:CSV|ParseString)2List|OverMyLand|SameGroup|UnSit|Ground(?:Slope|Normal|Contour)|GroundRepel|(?:Set|Remove)VehicleFlags|(?:AvatarOn)?(?:Link)?SitTarget|Script(?:Danger|Profiler)|Dialog|VolumeDetect|ResetOtherScript|RemoteLoadScriptPin|(?:Open|Close)RemoteDataChannel|SendRemoteData|RemoteDataReply|(?:Integer|String)ToBase64|XorBase64|Log(?:10)?|Base64To(?:String|Integer)|ParseStringKeepNulls|RezAtRoot|RequestSimulatorData|ForceMouselook|(?:Load|Release|(?:E|Une)scape)URL|ParcelMedia(?:CommandList|Query)|ModPow|MapDestination|(?:RemoveFrom|AddTo|Reset)Land(?:Pass|Ban)List|(?:Set|Clear)CameraParams|HTTP(?:Request|Response)|TextBox|DetectedTouch(?:UV|Face|Pos|(?:N|Bin)ormal|ST)|(?:MD5|SHA1|DumpList2)String|Request(?:Secure)?URL|Clear(?:Prim|Link)Media|(?:Link)?ParticleSystem|(?:Get|Request)(?:Username|DisplayName)|RegionSayTo|CastRay|GenerateKey|TransferLindenDollars|ManageEstateAccess|(?:Create|Delete)Character|ExecCharacterCmd|Evade|FleeFrom|NavigateTo|PatrolPoints|Pursue|UpdateCharacter|WanderWithin))\b'
+    lsl_constants_float = r'\b(?:DEG_TO_RAD|PI(?:_BY_TWO)?|RAD_TO_DEG|SQRT2|TWO_PI)\b'
+    lsl_constants_integer = r'\b(?:JSON_APPEND|STATUS_(?:PHYSICS|ROTATE_[XYZ]|PHANTOM|SANDBOX|BLOCK_GRAB(?:_OBJECT)?|(?:DIE|RETURN)_AT_EDGE|CAST_SHADOWS|OK|MALFORMED_PARAMS|TYPE_MISMATCH|BOUNDS_ERROR|NOT_(?:FOUND|SUPPORTED)|INTERNAL_ERROR|WHITELIST_FAILED)|AGENT(?:_(?:BY_(?:LEGACY_|USER)NAME|FLYING|ATTACHMENTS|SCRIPTED|MOUSELOOK|SITTING|ON_OBJECT|AWAY|WALKING|IN_AIR|TYPING|CROUCHING|BUSY|ALWAYS_RUN|AUTOPILOT|LIST_(?:PARCEL(?:_OWNER)?|REGION)))?|CAMERA_(?:PITCH|DISTANCE|BEHINDNESS_(?:ANGLE|LAG)|(?:FOCUS|POSITION)(?:_(?:THRESHOLD|LOCKED|LAG))?|FOCUS_OFFSET|ACTIVE)|ANIM_ON|LOOP|REVERSE|PING_PONG|SMOOTH|ROTATE|SCALE|ALL_SIDES|LINK_(?:ROOT|SET|ALL_(?:OTHERS|CHILDREN)|THIS)|ACTIVE|PASSIVE|SCRIPTED|CONTROL_(?:FWD|BACK|(?:ROT_)?(?:LEFT|RIGHT)|UP|DOWN|(?:ML_)?LBUTTON)|PERMISSION_(?:RETURN_OBJECTS|DEBIT|OVERRIDE_ANIMATIONS|SILENT_ESTATE_MANAGEMENT|TAKE_CONTROLS|TRIGGER_ANIMATION|ATTACH|CHANGE_LINKS|(?:CONTROL|TRACK)_CAMERA|TELEPORT)|INVENTORY_(?:TEXTURE|SOUND|OBJECT|SCRIPT|LANDMARK|CLOTHING|NOTECARD|BODYPART|ANIMATION|GESTURE|ALL|NONE)|CHANGED_(?:INVENTORY|COLOR|SHAPE|SCALE|TEXTURE|LINK|ALLOWED_DROP|OWNER|REGION(?:_START)?|TELEPORT|MEDIA)|OBJECT_(?:(?:PHYSICS|SERVER|STREAMING)_COST|UNKNOWN_DETAIL|CHARACTER_TIME|PHANTOM|PHYSICS|TEMP_ON_REZ|NAME|DESC|POS|PRIM_EQUIVALENCE|RETURN_(?:PARCEL(?:_OWNER)?|REGION)|ROO?T|VELOCITY|OWNER|GROUP|CREATOR|ATTACHED_POINT|RENDER_WEIGHT|PATHFINDING_TYPE|(?:RUNNING|TOTAL)_SCRIPT_COUNT|SCRIPT_(?:MEMORY|TIME))|TYPE_(?:INTEGER|FLOAT|STRING|KEY|VECTOR|ROTATION|INVALID)|(?:DEBUG|PUBLIC)_CHANNEL|ATTACH_(?:AVATAR_CENTER|CHEST|HEAD|BACK|PELVIS|MOUTH|CHIN|NECK|NOSE|BELLY|[LR](?:SHOULDER|HAND|FOOT|EAR|EYE|[UL](?:ARM|LEG)|HIP)|(?:LEFT|RIGHT)_PEC|HUD_(?:CENTER_[12]|TOP_(?:RIGHT|CENTER|LEFT)|BOTTOM(?:_(?:RIGHT|LEFT))?))|LAND_(?:LEVEL|RAISE|LOWER|SMOOTH|NOISE|REVERT)|DATA_(?:ONLINE|NAME|BORN|SIM_(?:POS|STATUS|RATING)|PAYINFO)|PAYMENT_INFO_(?:ON_FILE|USED)|REMOTE_DATA_(?:CHANNEL|REQUEST|REPLY)|PSYS_(?:PART_(?:BF_(?:ZERO|ONE(?:_MINUS_(?:DEST_COLOR|SOURCE_(ALPHA|COLOR)))?|DEST_COLOR|SOURCE_(ALPHA|COLOR))|BLEND_FUNC_(DEST|SOURCE)|FLAGS|(?:START|END)_(?:COLOR|ALPHA|SCALE|GLOW)|MAX_AGE|(?:RIBBON|WIND|INTERP_(?:COLOR|SCALE)|BOUNCE|FOLLOW_(?:SRC|VELOCITY)|TARGET_(?:POS|LINEAR)|EMISSIVE)_MASK)|SRC_(?:MAX_AGE|PATTERN|ANGLE_(?:BEGIN|END)|BURST_(?:RATE|PART_COUNT|RADIUS|SPEED_(?:MIN|MAX))|ACCEL|TEXTURE|TARGET_KEY|OMEGA|PATTERN_(?:DROP|EXPLODE|ANGLE(?:_CONE(?:_EMPTY)?)?)))|VEHICLE_(?:REFERENCE_FRAME|TYPE_(?:NONE|SLED|CAR|BOAT|AIRPLANE|BALLOON)|(?:LINEAR|ANGULAR)_(?:FRICTION_TIMESCALE|MOTOR_DIRECTION)|LINEAR_MOTOR_OFFSET|HOVER_(?:HEIGHT|EFFICIENCY|TIMESCALE)|BUOYANCY|(?:LINEAR|ANGULAR)_(?:DEFLECTION_(?:EFFICIENCY|TIMESCALE)|MOTOR_(?:DECAY_)?TIMESCALE)|VERTICAL_ATTRACTION_(?:EFFICIENCY|TIMESCALE)|BANKING_(?:EFFICIENCY|MIX|TIMESCALE)|FLAG_(?:NO_DEFLECTION_UP|LIMIT_(?:ROLL_ONLY|MOTOR_UP)|HOVER_(?:(?:WATER|TERRAIN|UP)_ONLY|GLOBAL_HEIGHT)|MOUSELOOK_(?:STEER|BANK)|CAMERA_DECOUPLED))|PRIM_(?:TYPE(?:_(?:BOX|CYLINDER|PRISM|SPHERE|TORUS|TUBE|RING|SCULPT))?|HOLE_(?:DEFAULT|CIRCLE|SQUARE|TRIANGLE)|MATERIAL(?:_(?:STONE|METAL|GLASS|WOOD|FLESH|PLASTIC|RUBBER))?|SHINY_(?:NONE|LOW|MEDIUM|HIGH)|BUMP_(?:NONE|BRIGHT|DARK|WOOD|BARK|BRICKS|CHECKER|CONCRETE|TILE|STONE|DISKS|GRAVEL|BLOBS|SIDING|LARGETILE|STUCCO|SUCTION|WEAVE)|TEXGEN_(?:DEFAULT|PLANAR)|SCULPT_(?:TYPE_(?:SPHERE|TORUS|PLANE|CYLINDER|MASK)|FLAG_(?:MIRROR|INVERT))|PHYSICS(?:_(?:SHAPE_(?:CONVEX|NONE|PRIM|TYPE)))?|(?:POS|ROT)_LOCAL|SLICE|TEXT|FLEXIBLE|POINT_LIGHT|TEMP_ON_REZ|PHANTOM|POSITION|SIZE|ROTATION|TEXTURE|NAME|OMEGA|DESC|LINK_TARGET|COLOR|BUMP_SHINY|FULLBRIGHT|TEXGEN|GLOW|MEDIA_(?:ALT_IMAGE_ENABLE|CONTROLS|(?:CURRENT|HOME)_URL|AUTO_(?:LOOP|PLAY|SCALE|ZOOM)|FIRST_CLICK_INTERACT|(?:WIDTH|HEIGHT)_PIXELS|WHITELIST(?:_ENABLE)?|PERMS_(?:INTERACT|CONTROL)|PARAM_MAX|CONTROLS_(?:STANDARD|MINI)|PERM_(?:NONE|OWNER|GROUP|ANYONE)|MAX_(?:URL_LENGTH|WHITELIST_(?:SIZE|COUNT)|(?:WIDTH|HEIGHT)_PIXELS)))|MASK_(?:BASE|OWNER|GROUP|EVERYONE|NEXT)|PERM_(?:TRANSFER|MODIFY|COPY|MOVE|ALL)|PARCEL_(?:MEDIA_COMMAND_(?:STOP|PAUSE|PLAY|LOOP|TEXTURE|URL|TIME|AGENT|UNLOAD|AUTO_ALIGN|TYPE|SIZE|DESC|LOOP_SET)|FLAG_(?:ALLOW_(?:FLY|(?:GROUP_)?SCRIPTS|LANDMARK|TERRAFORM|DAMAGE|CREATE_(?:GROUP_)?OBJECTS)|USE_(?:ACCESS_(?:GROUP|LIST)|BAN_LIST|LAND_PASS_LIST)|LOCAL_SOUND_ONLY|RESTRICT_PUSHOBJECT|ALLOW_(?:GROUP|ALL)_OBJECT_ENTRY)|COUNT_(?:TOTAL|OWNER|GROUP|OTHER|SELECTED|TEMP)|DETAILS_(?:NAME|DESC|OWNER|GROUP|AREA|ID|SEE_AVATARS))|LIST_STAT_(?:MAX|MIN|MEAN|MEDIAN|STD_DEV|SUM(?:_SQUARES)?|NUM_COUNT|GEOMETRIC_MEAN|RANGE)|PAY_(?:HIDE|DEFAULT)|REGION_FLAG_(?:ALLOW_DAMAGE|FIXED_SUN|BLOCK_TERRAFORM|SANDBOX|DISABLE_(?:COLLISIONS|PHYSICS)|BLOCK_FLY|ALLOW_DIRECT_TELEPORT|RESTRICT_PUSHOBJECT)|HTTP_(?:METHOD|MIMETYPE|BODY_(?:MAXLENGTH|TRUNCATED)|CUSTOM_HEADER|PRAGMA_NO_CACHE|VERBOSE_THROTTLE|VERIFY_CERT)|STRING_(?:TRIM(?:_(?:HEAD|TAIL))?)|CLICK_ACTION_(?:NONE|TOUCH|SIT|BUY|PAY|OPEN(?:_MEDIA)?|PLAY|ZOOM)|TOUCH_INVALID_FACE|PROFILE_(?:NONE|SCRIPT_MEMORY)|RC_(?:DATA_FLAGS|DETECT_PHANTOM|GET_(?:LINK_NUM|NORMAL|ROOT_KEY)|MAX_HITS|REJECT_(?:TYPES|AGENTS|(?:NON)?PHYSICAL|LAND))|RCERR_(?:CAST_TIME_EXCEEDED|SIM_PERF_LOW|UNKNOWN)|ESTATE_ACCESS_(?:ALLOWED_(?:AGENT|GROUP)_(?:ADD|REMOVE)|BANNED_AGENT_(?:ADD|REMOVE))|DENSITY|FRICTION|RESTITUTION|GRAVITY_MULTIPLIER|KFM_(?:COMMAND|CMD_(?:PLAY|STOP|PAUSE|SET_MODE)|MODE|FORWARD|LOOP|PING_PONG|REVERSE|DATA|ROTATION|TRANSLATION)|ERR_(?:GENERIC|PARCEL_PERMISSIONS|MALFORMED_PARAMS|RUNTIME_PERMISSIONS|THROTTLED)|CHARACTER_(?:CMD_(?:(?:SMOOTH_)?STOP|JUMP)|DESIRED_(?:TURN_)?SPEED|RADIUS|STAY_WITHIN_PARCEL|LENGTH|ORIENTATION|ACCOUNT_FOR_SKIPPED_FRAMES|AVOIDANCE_MODE|TYPE(?:_(?:[A-D]|NONE))?|MAX_(?:DECEL|TURN_RADIUS|(?:ACCEL|SPEED)))|PURSUIT_(?:OFFSET|FUZZ_FACTOR|GOAL_TOLERANCE|INTERCEPT)|REQUIRE_LINE_OF_SIGHT|FORCE_DIRECT_PATH|VERTICAL|HORIZONTAL|AVOID_(?:CHARACTERS|DYNAMIC_OBSTACLES|NONE)|PU_(?:EVADE_(?:HIDDEN|SPOTTED)|FAILURE_(?:DYNAMIC_PATHFINDING_DISABLED|INVALID_(?:GOAL|START)|NO_(?:NAVMESH|VALID_DESTINATION)|OTHER|TARGET_GONE|(?:PARCEL_)?UNREACHABLE)|(?:GOAL|SLOWDOWN_DISTANCE)_REACHED)|TRAVERSAL_TYPE(?:_(?:FAST|NONE|SLOW))?|CONTENT_TYPE_(?:ATOM|FORM|HTML|JSON|LLSD|RSS|TEXT|XHTML|XML)|GCNP_(?:RADIUS|STATIC)|(?:PATROL|WANDER)_PAUSE_AT_WAYPOINTS|OPT_(?:AVATAR|CHARACTER|EXCLUSION_VOLUME|LEGACY_LINKSET|MATERIAL_VOLUME|OTHER|STATIC_OBSTACLE|WALKABLE)|SIM_STAT_PCT_CHARS_STEPPED)\b'
+    lsl_constants_integer_boolean = r'\b(?:FALSE|TRUE)\b'
+    lsl_constants_rotation = r'\b(?:ZERO_ROTATION)\b'
+    lsl_constants_string = r'\b(?:EOF|JSON_(?:ARRAY|DELETE|FALSE|INVALID|NULL|NUMBER|OBJECT|STRING|TRUE)|NULL_KEY|TEXTURE_(?:BLANK|DEFAULT|MEDIA|PLYWOOD|TRANSPARENT)|URL_REQUEST_(?:GRANTED|DENIED))\b'
+    lsl_constants_vector = r'\b(?:TOUCH_INVALID_(?:TEXCOORD|VECTOR)|ZERO_VECTOR)\b'
+    lsl_invalid_broken = r'\b(?:LAND_(?:LARGE|MEDIUM|SMALL)_BRUSH)\b'
+    lsl_invalid_deprecated = r'\b(?:ATTACH_[LR]PEC|DATA_RATING|OBJECT_ATTACHMENT_(?:GEOMETRY_BYTES|SURFACE_AREA)|PRIM_(?:CAST_SHADOWS|MATERIAL_LIGHT|TYPE_LEGACY)|PSYS_SRC_(?:INNER|OUTER)ANGLE|VEHICLE_FLAG_NO_FLY_UP|ll(?:Cloud|Make(?:Explosion|Fountain|Smoke|Fire)|RemoteDataSetRegion|Sound(?:Preload)?|XorBase64Strings(?:Correct)?))\b'
+    lsl_invalid_illegal = r'\b(?:event)\b'
+    lsl_invalid_unimplemented = r'\b(?:CHARACTER_(?:MAX_ANGULAR_(?:ACCEL|SPEED)|TURN_SPEED_MULTIPLIER)|PERMISSION_(?:CHANGE_(?:JOINTS|PERMISSIONS)|RELEASE_OWNERSHIP|REMAP_CONTROLS)|PRIM_PHYSICS_MATERIAL|PSYS_SRC_OBJ_REL_MASK|ll(?:CollisionSprite|(?:Stop)?PointAt|(?:(?:Refresh|Set)Prim)URL|(?:Take|Release)Camera|RemoteLoadScript))\b'
+    lsl_reserved_godmode = r'\b(?:ll(?:GodLikeRezObject|Set(?:Inventory|Object)PermMask))\b'
+    lsl_reserved_log = r'\b(?:print)\b'
+    lsl_operators = r'\+\+|\-\-|<<|>>|&&?|\|\|?|\^|~|[!%<>=*+\-/]=?'
+
+    tokens = {
+        'root':
+        [
+            (r'//.*?\n',                          Comment.Single),
+            (r'/\*',                              Comment.Multiline, 'comment'),
+            (r'"',                                String.Double, 'string'),
+            (lsl_keywords,                        Keyword),
+            (lsl_types,                           Keyword.Type),
+            (lsl_states,                          Name.Class),
+            (lsl_events,                          Name.Builtin),
+            (lsl_functions_builtin,               Name.Function),
+            (lsl_constants_float,                 Keyword.Constant),
+            (lsl_constants_integer,               Keyword.Constant),
+            (lsl_constants_integer_boolean,       Keyword.Constant),
+            (lsl_constants_rotation,              Keyword.Constant),
+            (lsl_constants_string,                Keyword.Constant),
+            (lsl_constants_vector,                Keyword.Constant),
+            (lsl_invalid_broken,                  Error),
+            (lsl_invalid_deprecated,              Error),
+            (lsl_invalid_illegal,                 Error),
+            (lsl_invalid_unimplemented,           Error),
+            (lsl_reserved_godmode,                Keyword.Reserved),
+            (lsl_reserved_log,                    Keyword.Reserved),
+            (r'\b([a-zA-Z_]\w*)\b',     Name.Variable),
+            (r'(\d+\.\d*|\.\d+|\d+)[eE][+-]?\d*', Number.Float),
+            (r'(\d+\.\d*|\.\d+)',                 Number.Float),
+            (r'0[xX][0-9a-fA-F]+',                Number.Hex),
+            (r'\d+',                              Number.Integer),
+            (lsl_operators,                       Operator),
+            (r':=?',                              Error),
+            (r'[,;{}()\[\]]',                     Punctuation),
+            (r'\n+',                              Whitespace),
+            (r'\s+',                              Whitespace)
+        ],
+        'comment':
+        [
+            (r'[^*/]+',                           Comment.Multiline),
+            (r'/\*',                              Comment.Multiline, '#push'),
+            (r'\*/',                              Comment.Multiline, '#pop'),
+            (r'[*/]',                             Comment.Multiline)
+        ],
+        'string':
+        [
+            (r'\\([nt"\\])',                      String.Escape),
+            (r'"',                                String.Double, '#pop'),
+            (r'\\.',                              Error),
+            (r'[^"\\]+',                          String.Double),
+        ]
+    }
+
+
+class AppleScriptLexer(RegexLexer):
+    """
+    For AppleScript source code,
+    including `AppleScript Studio
+    `_.
+    Contributed by Andreas Amann .
+    """
+
+    name = 'AppleScript'
+    url = 'https://developer.apple.com/library/archive/documentation/AppleScript/Conceptual/AppleScriptLangGuide/introduction/ASLR_intro.html'
+    aliases = ['applescript']
+    filenames = ['*.applescript']
+    version_added = '1.0'
+
+    flags = re.MULTILINE | re.DOTALL
+
+    Identifiers = r'[a-zA-Z]\w*'
+
+    # XXX: use words() for all of these
+    Literals = ('AppleScript', 'current application', 'false', 'linefeed',
+                'missing value', 'pi', 'quote', 'result', 'return', 'space',
+                'tab', 'text item delimiters', 'true', 'version')
+    Classes = ('alias ', 'application ', 'boolean ', 'class ', 'constant ',
+               'date ', 'file ', 'integer ', 'list ', 'number ', 'POSIX file ',
+               'real ', 'record ', 'reference ', 'RGB color ', 'script ',
+               'text ', 'unit types', '(?:Unicode )?text', 'string')
+    BuiltIn = ('attachment', 'attribute run', 'character', 'day', 'month',
+               'paragraph', 'word', 'year')
+    HandlerParams = ('about', 'above', 'against', 'apart from', 'around',
+                     'aside from', 'at', 'below', 'beneath', 'beside',
+                     'between', 'for', 'given', 'instead of', 'on', 'onto',
+                     'out of', 'over', 'since')
+    Commands = ('ASCII (character|number)', 'activate', 'beep', 'choose URL',
+                'choose application', 'choose color', 'choose file( name)?',
+                'choose folder', 'choose from list',
+                'choose remote application', 'clipboard info',
+                'close( access)?', 'copy', 'count', 'current date', 'delay',
+                'delete', 'display (alert|dialog)', 'do shell script',
+                'duplicate', 'exists', 'get eof', 'get volume settings',
+                'info for', 'launch', 'list (disks|folder)', 'load script',
+                'log', 'make', 'mount volume', 'new', 'offset',
+                'open( (for access|location))?', 'path to', 'print', 'quit',
+                'random number', 'read', 'round', 'run( script)?',
+                'say', 'scripting components',
+                'set (eof|the clipboard to|volume)', 'store script',
+                'summarize', 'system attribute', 'system info',
+                'the clipboard', 'time to GMT', 'write', 'quoted form')
+    References = ('(in )?back of', '(in )?front of', '[0-9]+(st|nd|rd|th)',
+                  'first', 'second', 'third', 'fourth', 'fifth', 'sixth',
+                  'seventh', 'eighth', 'ninth', 'tenth', 'after', 'back',
+                  'before', 'behind', 'every', 'front', 'index', 'last',
+                  'middle', 'some', 'that', 'through', 'thru', 'where', 'whose')
+    Operators = ("and", "or", "is equal", "equals", "(is )?equal to", "is not",
+                 "isn't", "isn't equal( to)?", "is not equal( to)?",
+                 "doesn't equal", "does not equal", "(is )?greater than",
+                 "comes after", "is not less than or equal( to)?",
+                 "isn't less than or equal( to)?", "(is )?less than",
+                 "comes before", "is not greater than or equal( to)?",
+                 "isn't greater than or equal( to)?",
+                 "(is  )?greater than or equal( to)?", "is not less than",
+                 "isn't less than", "does not come before",
+                 "doesn't come before", "(is )?less than or equal( to)?",
+                 "is not greater than", "isn't greater than",
+                 "does not come after", "doesn't come after", "starts? with",
+                 "begins? with", "ends? with", "contains?", "does not contain",
+                 "doesn't contain", "is in", "is contained by", "is not in",
+                 "is not contained by", "isn't contained by", "div", "mod",
+                 "not", "(a  )?(ref( to)?|reference to)", "is", "does")
+    Control = ('considering', 'else', 'error', 'exit', 'from', 'if',
+               'ignoring', 'in', 'repeat', 'tell', 'then', 'times', 'to',
+               'try', 'until', 'using terms from', 'while', 'whith',
+               'with timeout( of)?', 'with transaction', 'by', 'continue',
+               'end', 'its?', 'me', 'my', 'return', 'of', 'as')
+    Declarations = ('global', 'local', 'prop(erty)?', 'set', 'get')
+    Reserved = ('but', 'put', 'returning', 'the')
+    StudioClasses = ('action cell', 'alert reply', 'application', 'box',
+                     'browser( cell)?', 'bundle', 'button( cell)?', 'cell',
+                     'clip view', 'color well', 'color-panel',
+                     'combo box( item)?', 'control',
+                     'data( (cell|column|item|row|source))?', 'default entry',
+                     'dialog reply', 'document', 'drag info', 'drawer',
+                     'event', 'font(-panel)?', 'formatter',
+                     'image( (cell|view))?', 'matrix', 'menu( item)?', 'item',
+                     'movie( view)?', 'open-panel', 'outline view', 'panel',
+                     'pasteboard', 'plugin', 'popup button',
+                     'progress indicator', 'responder', 'save-panel',
+                     'scroll view', 'secure text field( cell)?', 'slider',
+                     'sound', 'split view', 'stepper', 'tab view( item)?',
+                     'table( (column|header cell|header view|view))',
+                     'text( (field( cell)?|view))?', 'toolbar( item)?',
+                     'user-defaults', 'view', 'window')
+    StudioEvents = ('accept outline drop', 'accept table drop', 'action',
+                    'activated', 'alert ended', 'awake from nib', 'became key',
+                    'became main', 'begin editing', 'bounds changed',
+                    'cell value', 'cell value changed', 'change cell value',
+                    'change item value', 'changed', 'child of item',
+                    'choose menu item', 'clicked', 'clicked toolbar item',
+                    'closed', 'column clicked', 'column moved',
+                    'column resized', 'conclude drop', 'data representation',
+                    'deminiaturized', 'dialog ended', 'document nib name',
+                    'double clicked', 'drag( (entered|exited|updated))?',
+                    'drop', 'end editing', 'exposed', 'idle', 'item expandable',
+                    'item value', 'item value changed', 'items changed',
+                    'keyboard down', 'keyboard up', 'launched',
+                    'load data representation', 'miniaturized', 'mouse down',
+                    'mouse dragged', 'mouse entered', 'mouse exited',
+                    'mouse moved', 'mouse up', 'moved',
+                    'number of browser rows', 'number of items',
+                    'number of rows', 'open untitled', 'opened', 'panel ended',
+                    'parameters updated', 'plugin loaded', 'prepare drop',
+                    'prepare outline drag', 'prepare outline drop',
+                    'prepare table drag', 'prepare table drop',
+                    'read from file', 'resigned active', 'resigned key',
+                    'resigned main', 'resized( sub views)?',
+                    'right mouse down', 'right mouse dragged',
+                    'right mouse up', 'rows changed', 'scroll wheel',
+                    'selected tab view item', 'selection changed',
+                    'selection changing', 'should begin editing',
+                    'should close', 'should collapse item',
+                    'should end editing', 'should expand item',
+                    'should open( untitled)?',
+                    'should quit( after last window closed)?',
+                    'should select column', 'should select item',
+                    'should select row', 'should select tab view item',
+                    'should selection change', 'should zoom', 'shown',
+                    'update menu item', 'update parameters',
+                    'update toolbar item', 'was hidden', 'was miniaturized',
+                    'will become active', 'will close', 'will dismiss',
+                    'will display browser cell', 'will display cell',
+                    'will display item cell', 'will display outline cell',
+                    'will finish launching', 'will hide', 'will miniaturize',
+                    'will move', 'will open', 'will pop up', 'will quit',
+                    'will resign active', 'will resize( sub views)?',
+                    'will select tab view item', 'will show', 'will zoom',
+                    'write to file', 'zoomed')
+    StudioCommands = ('animate', 'append', 'call method', 'center',
+                      'close drawer', 'close panel', 'display',
+                      'display alert', 'display dialog', 'display panel', 'go',
+                      'hide', 'highlight', 'increment', 'item for',
+                      'load image', 'load movie', 'load nib', 'load panel',
+                      'load sound', 'localized string', 'lock focus', 'log',
+                      'open drawer', 'path for', 'pause', 'perform action',
+                      'play', 'register', 'resume', 'scroll', 'select( all)?',
+                      'show', 'size to fit', 'start', 'step back',
+                      'step forward', 'stop', 'synchronize', 'unlock focus',
+                      'update')
+    StudioProperties = ('accepts arrow key', 'action method', 'active',
+                        'alignment', 'allowed identifiers',
+                        'allows branch selection', 'allows column reordering',
+                        'allows column resizing', 'allows column selection',
+                        'allows customization',
+                        'allows editing text attributes',
+                        'allows empty selection', 'allows mixed state',
+                        'allows multiple selection', 'allows reordering',
+                        'allows undo', 'alpha( value)?', 'alternate image',
+                        'alternate increment value', 'alternate title',
+                        'animation delay', 'associated file name',
+                        'associated object', 'auto completes', 'auto display',
+                        'auto enables items', 'auto repeat',
+                        'auto resizes( outline column)?',
+                        'auto save expanded items', 'auto save name',
+                        'auto save table columns', 'auto saves configuration',
+                        'auto scroll', 'auto sizes all columns to fit',
+                        'auto sizes cells', 'background color', 'bezel state',
+                        'bezel style', 'bezeled', 'border rect', 'border type',
+                        'bordered', 'bounds( rotation)?', 'box type',
+                        'button returned', 'button type',
+                        'can choose directories', 'can choose files',
+                        'can draw', 'can hide',
+                        'cell( (background color|size|type))?', 'characters',
+                        'class', 'click count', 'clicked( data)? column',
+                        'clicked data item', 'clicked( data)? row',
+                        'closeable', 'collating', 'color( (mode|panel))',
+                        'command key down', 'configuration',
+                        'content(s| (size|view( margins)?))?', 'context',
+                        'continuous', 'control key down', 'control size',
+                        'control tint', 'control view',
+                        'controller visible', 'coordinate system',
+                        'copies( on scroll)?', 'corner view', 'current cell',
+                        'current column', 'current( field)?  editor',
+                        'current( menu)? item', 'current row',
+                        'current tab view item', 'data source',
+                        'default identifiers', 'delta (x|y|z)',
+                        'destination window', 'directory', 'display mode',
+                        'displayed cell', 'document( (edited|rect|view))?',
+                        'double value', 'dragged column', 'dragged distance',
+                        'dragged items', 'draws( cell)? background',
+                        'draws grid', 'dynamically scrolls', 'echos bullets',
+                        'edge', 'editable', 'edited( data)? column',
+                        'edited data item', 'edited( data)? row', 'enabled',
+                        'enclosing scroll view', 'ending page',
+                        'error handling', 'event number', 'event type',
+                        'excluded from windows menu', 'executable path',
+                        'expanded', 'fax number', 'field editor', 'file kind',
+                        'file name', 'file type', 'first responder',
+                        'first visible column', 'flipped', 'floating',
+                        'font( panel)?', 'formatter', 'frameworks path',
+                        'frontmost', 'gave up', 'grid color', 'has data items',
+                        'has horizontal ruler', 'has horizontal scroller',
+                        'has parent data item', 'has resize indicator',
+                        'has shadow', 'has sub menu', 'has vertical ruler',
+                        'has vertical scroller', 'header cell', 'header view',
+                        'hidden', 'hides when deactivated', 'highlights by',
+                        'horizontal line scroll', 'horizontal page scroll',
+                        'horizontal ruler view', 'horizontally resizable',
+                        'icon image', 'id', 'identifier',
+                        'ignores multiple clicks',
+                        'image( (alignment|dims when disabled|frame style|scaling))?',
+                        'imports graphics', 'increment value',
+                        'indentation per level', 'indeterminate', 'index',
+                        'integer value', 'intercell spacing', 'item height',
+                        'key( (code|equivalent( modifier)?|window))?',
+                        'knob thickness', 'label', 'last( visible)? column',
+                        'leading offset', 'leaf', 'level', 'line scroll',
+                        'loaded', 'localized sort', 'location', 'loop mode',
+                        'main( (bunde|menu|window))?', 'marker follows cell',
+                        'matrix mode', 'maximum( content)? size',
+                        'maximum visible columns',
+                        'menu( form representation)?', 'miniaturizable',
+                        'miniaturized', 'minimized image', 'minimized title',
+                        'minimum column width', 'minimum( content)? size',
+                        'modal', 'modified', 'mouse down state',
+                        'movie( (controller|file|rect))?', 'muted', 'name',
+                        'needs display', 'next state', 'next text',
+                        'number of tick marks', 'only tick mark values',
+                        'opaque', 'open panel', 'option key down',
+                        'outline table column', 'page scroll', 'pages across',
+                        'pages down', 'palette label', 'pane splitter',
+                        'parent data item', 'parent window', 'pasteboard',
+                        'path( (names|separator))?', 'playing',
+                        'plays every frame', 'plays selection only', 'position',
+                        'preferred edge', 'preferred type', 'pressure',
+                        'previous text', 'prompt', 'properties',
+                        'prototype cell', 'pulls down', 'rate',
+                        'released when closed', 'repeated',
+                        'requested print time', 'required file type',
+                        'resizable', 'resized column', 'resource path',
+                        'returns records', 'reuses columns', 'rich text',
+                        'roll over', 'row height', 'rulers visible',
+                        'save panel', 'scripts path', 'scrollable',
+                        'selectable( identifiers)?', 'selected cell',
+                        'selected( data)? columns?', 'selected data items?',
+                        'selected( data)? rows?', 'selected item identifier',
+                        'selection by rect', 'send action on arrow key',
+                        'sends action when done editing', 'separates columns',
+                        'separator item', 'sequence number', 'services menu',
+                        'shared frameworks path', 'shared support path',
+                        'sheet', 'shift key down', 'shows alpha',
+                        'shows state by', 'size( mode)?',
+                        'smart insert delete enabled', 'sort case sensitivity',
+                        'sort column', 'sort order', 'sort type',
+                        'sorted( data rows)?', 'sound', 'source( mask)?',
+                        'spell checking enabled', 'starting page', 'state',
+                        'string value', 'sub menu', 'super menu', 'super view',
+                        'tab key traverses cells', 'tab state', 'tab type',
+                        'tab view', 'table view', 'tag', 'target( printer)?',
+                        'text color', 'text container insert',
+                        'text container origin', 'text returned',
+                        'tick mark position', 'time stamp',
+                        'title(d| (cell|font|height|position|rect))?',
+                        'tool tip', 'toolbar', 'trailing offset', 'transparent',
+                        'treat packages as directories', 'truncated labels',
+                        'types', 'unmodified characters', 'update views',
+                        'use sort indicator', 'user defaults',
+                        'uses data source', 'uses ruler',
+                        'uses threaded animation',
+                        'uses title from previous column', 'value wraps',
+                        'version',
+                        'vertical( (line scroll|page scroll|ruler view))?',
+                        'vertically resizable', 'view',
+                        'visible( document rect)?', 'volume', 'width', 'window',
+                        'windows menu', 'wraps', 'zoomable', 'zoomed')
+
+    tokens = {
+        'root': [
+            (r'\s+', Text),
+            (r'¬\n', String.Escape),
+            (r"'s\s+", Text),  # This is a possessive, consider moving
+            (r'(--|#).*?$', Comment),
+            (r'\(\*', Comment.Multiline, 'comment'),
+            (r'[(){}!,.:]', Punctuation),
+            (r'(«)([^»]+)(»)',
+             bygroups(Text, Name.Builtin, Text)),
+            (r'\b((?:considering|ignoring)\s*)'
+             r'(application responses|case|diacriticals|hyphens|'
+             r'numeric strings|punctuation|white space)',
+             bygroups(Keyword, Name.Builtin)),
+            (r'(-|\*|\+|&|≠|>=?|<=?|=|≥|≤|/|÷|\^)', Operator),
+            (r"\b({})\b".format('|'.join(Operators)), Operator.Word),
+            (r'^(\s*(?:on|end)\s+)'
+             r'({})'.format('|'.join(StudioEvents[::-1])),
+             bygroups(Keyword, Name.Function)),
+            (r'^(\s*)(in|on|script|to)(\s+)', bygroups(Text, Keyword, Text)),
+            (r'\b(as )({})\b'.format('|'.join(Classes)),
+             bygroups(Keyword, Name.Class)),
+            (r'\b({})\b'.format('|'.join(Literals)), Name.Constant),
+            (r'\b({})\b'.format('|'.join(Commands)), Name.Builtin),
+            (r'\b({})\b'.format('|'.join(Control)), Keyword),
+            (r'\b({})\b'.format('|'.join(Declarations)), Keyword),
+            (r'\b({})\b'.format('|'.join(Reserved)), Name.Builtin),
+            (r'\b({})s?\b'.format('|'.join(BuiltIn)), Name.Builtin),
+            (r'\b({})\b'.format('|'.join(HandlerParams)), Name.Builtin),
+            (r'\b({})\b'.format('|'.join(StudioProperties)), Name.Attribute),
+            (r'\b({})s?\b'.format('|'.join(StudioClasses)), Name.Builtin),
+            (r'\b({})\b'.format('|'.join(StudioCommands)), Name.Builtin),
+            (r'\b({})\b'.format('|'.join(References)), Name.Builtin),
+            (r'"(\\\\|\\[^\\]|[^"\\])*"', String.Double),
+            (rf'\b({Identifiers})\b', Name.Variable),
+            (r'[-+]?(\d+\.\d*|\d*\.\d+)(E[-+][0-9]+)?', Number.Float),
+            (r'[-+]?\d+', Number.Integer),
+        ],
+        'comment': [
+            (r'\(\*', Comment.Multiline, '#push'),
+            (r'\*\)', Comment.Multiline, '#pop'),
+            ('[^*(]+', Comment.Multiline),
+            ('[*(]', Comment.Multiline),
+        ],
+    }
+
+
+class RexxLexer(RegexLexer):
+    """
+    Rexx is a scripting language available for
+    a wide range of different platforms with its roots found on mainframe
+    systems. It is popular for I/O- and data based tasks and can act as glue
+    language to bind different applications together.
+    """
+    name = 'Rexx'
+    url = 'http://www.rexxinfo.org/'
+    aliases = ['rexx', 'arexx']
+    filenames = ['*.rexx', '*.rex', '*.rx', '*.arexx']
+    mimetypes = ['text/x-rexx']
+    version_added = '2.0'
+    flags = re.IGNORECASE
+
+    tokens = {
+        'root': [
+            (r'\s+', Whitespace),
+            (r'/\*', Comment.Multiline, 'comment'),
+            (r'"', String, 'string_double'),
+            (r"'", String, 'string_single'),
+            (r'[0-9]+(\.[0-9]+)?(e[+-]?[0-9])?', Number),
+            (r'([a-z_]\w*)(\s*)(:)(\s*)(procedure)\b',
+             bygroups(Name.Function, Whitespace, Operator, Whitespace,
+                      Keyword.Declaration)),
+            (r'([a-z_]\w*)(\s*)(:)',
+             bygroups(Name.Label, Whitespace, Operator)),
+            include('function'),
+            include('keyword'),
+            include('operator'),
+            (r'[a-z_]\w*', Text),
+        ],
+        'function': [
+            (words((
+                'abbrev', 'abs', 'address', 'arg', 'b2x', 'bitand', 'bitor', 'bitxor',
+                'c2d', 'c2x', 'center', 'charin', 'charout', 'chars', 'compare',
+                'condition', 'copies', 'd2c', 'd2x', 'datatype', 'date', 'delstr',
+                'delword', 'digits', 'errortext', 'form', 'format', 'fuzz', 'insert',
+                'lastpos', 'left', 'length', 'linein', 'lineout', 'lines', 'max',
+                'min', 'overlay', 'pos', 'queued', 'random', 'reverse', 'right', 'sign',
+                'sourceline', 'space', 'stream', 'strip', 'substr', 'subword', 'symbol',
+                'time', 'trace', 'translate', 'trunc', 'value', 'verify', 'word',
+                'wordindex', 'wordlength', 'wordpos', 'words', 'x2b', 'x2c', 'x2d',
+                'xrange'), suffix=r'(\s*)(\()'),
+             bygroups(Name.Builtin, Whitespace, Operator)),
+        ],
+        'keyword': [
+            (r'(address|arg|by|call|do|drop|else|end|exit|for|forever|if|'
+             r'interpret|iterate|leave|nop|numeric|off|on|options|parse|'
+             r'pull|push|queue|return|say|select|signal|to|then|trace|until|'
+             r'while)\b', Keyword.Reserved),
+        ],
+        'operator': [
+            (r'(-|//|/|\(|\)|\*\*|\*|\\<<|\\<|\\==|\\=|\\>>|\\>|\\|\|\||\||'
+             r'&&|&|%|\+|<<=|<<|<=|<>|<|==|=|><|>=|>>=|>>|>|¬<<|¬<|¬==|¬=|'
+             r'¬>>|¬>|¬|\.|,)', Operator),
+        ],
+        'string_double': [
+            (r'[^"\n]+', String),
+            (r'""', String),
+            (r'"', String, '#pop'),
+            (r'\n', Text, '#pop'),  # Stray linefeed also terminates strings.
+        ],
+        'string_single': [
+            (r'[^\'\n]+', String),
+            (r'\'\'', String),
+            (r'\'', String, '#pop'),
+            (r'\n', Text, '#pop'),  # Stray linefeed also terminates strings.
+        ],
+        'comment': [
+            (r'[^*]+', Comment.Multiline),
+            (r'\*/', Comment.Multiline, '#pop'),
+            (r'\*', Comment.Multiline),
+        ]
+    }
+
+    def _c(s):
+        return re.compile(s, re.MULTILINE)
+    _ADDRESS_COMMAND_PATTERN = _c(r'^\s*address\s+command\b')
+    _ADDRESS_PATTERN = _c(r'^\s*address\s+')
+    _DO_WHILE_PATTERN = _c(r'^\s*do\s+while\b')
+    _IF_THEN_DO_PATTERN = _c(r'^\s*if\b.+\bthen\s+do\s*$')
+    _PROCEDURE_PATTERN = _c(r'^\s*([a-z_]\w*)(\s*)(:)(\s*)(procedure)\b')
+    _ELSE_DO_PATTERN = _c(r'\belse\s+do\s*$')
+    _PARSE_ARG_PATTERN = _c(r'^\s*parse\s+(upper\s+)?(arg|value)\b')
+    PATTERNS_AND_WEIGHTS = (
+        (_ADDRESS_COMMAND_PATTERN, 0.2),
+        (_ADDRESS_PATTERN, 0.05),
+        (_DO_WHILE_PATTERN, 0.1),
+        (_ELSE_DO_PATTERN, 0.1),
+        (_IF_THEN_DO_PATTERN, 0.1),
+        (_PROCEDURE_PATTERN, 0.5),
+        (_PARSE_ARG_PATTERN, 0.2),
+    )
+
+    def analyse_text(text):
+        """
+        Check for initial comment and patterns that distinguish Rexx from other
+        C-like languages.
+        """
+        if re.search(r'/\*\**\s*rexx', text, re.IGNORECASE):
+            # Header matches MVS Rexx requirements, this is certainly a Rexx
+            # script.
+            return 1.0
+        elif text.startswith('/*'):
+            # Header matches general Rexx requirements; the source code might
+            # still be any language using C comments such as C++, C# or Java.
+            lowerText = text.lower()
+            result = sum(weight
+                         for (pattern, weight) in RexxLexer.PATTERNS_AND_WEIGHTS
+                         if pattern.search(lowerText)) + 0.01
+            return min(result, 1.0)
+
+
+class MOOCodeLexer(RegexLexer):
+    """
+    For MOOCode (the MOO scripting language).
+    """
+    name = 'MOOCode'
+    url = 'http://www.moo.mud.org/'
+    filenames = ['*.moo']
+    aliases = ['moocode', 'moo']
+    mimetypes = ['text/x-moocode']
+    version_added = '0.9'
+
+    tokens = {
+        'root': [
+            # Numbers
+            (r'(0|[1-9][0-9_]*)', Number.Integer),
+            # Strings
+            (r'"(\\\\|\\[^\\]|[^"\\])*"', String),
+            # exceptions
+            (r'(E_PERM|E_DIV)', Name.Exception),
+            # db-refs
+            (r'((#[-0-9]+)|(\$\w+))', Name.Entity),
+            # Keywords
+            (r'\b(if|else|elseif|endif|for|endfor|fork|endfork|while'
+             r'|endwhile|break|continue|return|try'
+             r'|except|endtry|finally|in)\b', Keyword),
+            # builtins
+            (r'(random|length)', Name.Builtin),
+            # special variables
+            (r'(player|caller|this|args)', Name.Variable.Instance),
+            # skip whitespace
+            (r'\s+', Text),
+            (r'\n', Text),
+            # other operators
+            (r'([!;=,{}&|:.\[\]@()<>?]+)', Operator),
+            # function call
+            (r'(\w+)(\()', bygroups(Name.Function, Operator)),
+            # variables
+            (r'(\w+)', Text),
+        ]
+    }
+
+
+class HybrisLexer(RegexLexer):
+    """
+    For Hybris source code.
+    """
+
+    name = 'Hybris'
+    aliases = ['hybris']
+    filenames = ['*.hyb']
+    mimetypes = ['text/x-hybris', 'application/x-hybris']
+    url = 'https://github.com/evilsocket/hybris'
+    version_added = '1.4'
+
+    flags = re.MULTILINE | re.DOTALL
+
+    tokens = {
+        'root': [
+            # method names
+            (r'^(\s*(?:function|method|operator\s+)+?)'
+             r'([a-zA-Z_]\w*)'
+             r'(\s*)(\()', bygroups(Keyword, Name.Function, Text, Operator)),
+            (r'[^\S\n]+', Text),
+            (r'//.*?\n', Comment.Single),
+            (r'/\*.*?\*/', Comment.Multiline),
+            (r'@[a-zA-Z_][\w.]*', Name.Decorator),
+            (r'(break|case|catch|next|default|do|else|finally|for|foreach|of|'
+             r'unless|if|new|return|switch|me|throw|try|while)\b', Keyword),
+            (r'(extends|private|protected|public|static|throws|function|method|'
+             r'operator)\b', Keyword.Declaration),
+            (r'(true|false|null|__FILE__|__LINE__|__VERSION__|__LIB_PATH__|'
+             r'__INC_PATH__)\b', Keyword.Constant),
+            (r'(class|struct)(\s+)',
+             bygroups(Keyword.Declaration, Text), 'class'),
+            (r'(import|include)(\s+)',
+             bygroups(Keyword.Namespace, Text), 'import'),
+            (words((
+                'gc_collect', 'gc_mm_items', 'gc_mm_usage', 'gc_collect_threshold',
+                'urlencode', 'urldecode', 'base64encode', 'base64decode', 'sha1', 'crc32',
+                'sha2', 'md5', 'md5_file', 'acos', 'asin', 'atan', 'atan2', 'ceil', 'cos',
+                'cosh', 'exp', 'fabs', 'floor', 'fmod', 'log', 'log10', 'pow', 'sin',
+                'sinh', 'sqrt', 'tan', 'tanh', 'isint', 'isfloat', 'ischar', 'isstring',
+                'isarray', 'ismap', 'isalias', 'typeof', 'sizeof', 'toint', 'tostring',
+                'fromxml', 'toxml', 'binary', 'pack', 'load', 'eval', 'var_names',
+                'var_values', 'user_functions', 'dyn_functions', 'methods', 'call',
+                'call_method', 'mknod', 'mkfifo', 'mount', 'umount2', 'umount', 'ticks',
+                'usleep', 'sleep', 'time', 'strtime', 'strdate', 'dllopen', 'dlllink',
+                'dllcall', 'dllcall_argv', 'dllclose', 'env', 'exec', 'fork', 'getpid',
+                'wait', 'popen', 'pclose', 'exit', 'kill', 'pthread_create',
+                'pthread_create_argv', 'pthread_exit', 'pthread_join', 'pthread_kill',
+                'smtp_send', 'http_get', 'http_post', 'http_download', 'socket', 'bind',
+                'listen', 'accept', 'getsockname', 'getpeername', 'settimeout', 'connect',
+                'server', 'recv', 'send', 'close', 'print', 'println', 'printf', 'input',
+                'readline', 'serial_open', 'serial_fcntl', 'serial_get_attr',
+                'serial_get_ispeed', 'serial_get_ospeed', 'serial_set_attr',
+                'serial_set_ispeed', 'serial_set_ospeed', 'serial_write', 'serial_read',
+                'serial_close', 'xml_load', 'xml_parse', 'fopen', 'fseek', 'ftell',
+                'fsize', 'fread', 'fwrite', 'fgets', 'fclose', 'file', 'readdir',
+                'pcre_replace', 'size', 'pop', 'unmap', 'has', 'keys', 'values',
+                'length', 'find', 'substr', 'replace', 'split', 'trim', 'remove',
+                'contains', 'join'), suffix=r'\b'),
+             Name.Builtin),
+            (words((
+                'MethodReference', 'Runner', 'Dll', 'Thread', 'Pipe', 'Process',
+                'Runnable', 'CGI', 'ClientSocket', 'Socket', 'ServerSocket',
+                'File', 'Console', 'Directory', 'Exception'), suffix=r'\b'),
+             Keyword.Type),
+            (r'"(\\\\|\\[^\\]|[^"\\])*"', String),
+            (r"'\\.'|'[^\\]'|'\\u[0-9a-f]{4}'", String.Char),
+            (r'(\.)([a-zA-Z_]\w*)',
+             bygroups(Operator, Name.Attribute)),
+            (r'[a-zA-Z_]\w*:', Name.Label),
+            (r'[a-zA-Z_$]\w*', Name),
+            (r'[~^*!%&\[\](){}<>|+=:;,./?\-@]+', Operator),
+            (r'[0-9][0-9]*\.[0-9]+([eE][0-9]+)?[fd]?', Number.Float),
+            (r'0x[0-9a-f]+', Number.Hex),
+            (r'[0-9]+L?', Number.Integer),
+            (r'\n', Text),
+        ],
+        'class': [
+            (r'[a-zA-Z_]\w*', Name.Class, '#pop')
+        ],
+        'import': [
+            (r'[\w.]+\*?', Name.Namespace, '#pop')
+        ],
+    }
+
+    def analyse_text(text):
+        """public method and private method don't seem to be quite common
+        elsewhere."""
+        result = 0
+        if re.search(r'\b(?:public|private)\s+method\b', text):
+            result += 0.01
+        return result
+
+
+
+class EasytrieveLexer(RegexLexer):
+    """
+    Easytrieve Plus is a programming language for extracting, filtering and
+    converting sequential data. Furthermore it can layout data for reports.
+    It is mainly used on mainframe platforms and can access several of the
+    mainframe's native file formats. It is somewhat comparable to awk.
+    """
+    name = 'Easytrieve'
+    aliases = ['easytrieve']
+    filenames = ['*.ezt', '*.mac']
+    mimetypes = ['text/x-easytrieve']
+    url = 'https://www.broadcom.com/products/mainframe/application-development/easytrieve-report-generator'
+    version_added = '2.1'
+    flags = 0
+
+    # Note: We cannot use r'\b' at the start and end of keywords because
+    # Easytrieve Plus delimiter characters are:
+    #
+    #   * space ( )
+    #   * apostrophe (')
+    #   * period (.)
+    #   * comma (,)
+    #   * parenthesis ( and )
+    #   * colon (:)
+    #
+    # Additionally words end once a '*' appears, indicatins a comment.
+    _DELIMITERS = r' \'.,():\n'
+    _DELIMITERS_OR_COMENT = _DELIMITERS + '*'
+    _DELIMITER_PATTERN = '[' + _DELIMITERS + ']'
+    _DELIMITER_PATTERN_CAPTURE = '(' + _DELIMITER_PATTERN + ')'
+    _NON_DELIMITER_OR_COMMENT_PATTERN = '[^' + _DELIMITERS_OR_COMENT + ']'
+    _OPERATORS_PATTERN = '[.+\\-/=\\[\\](){}<>;,&%¬]'
+    _KEYWORDS = [
+        'AFTER-BREAK', 'AFTER-LINE', 'AFTER-SCREEN', 'AIM', 'AND', 'ATTR',
+        'BEFORE', 'BEFORE-BREAK', 'BEFORE-LINE', 'BEFORE-SCREEN', 'BUSHU',
+        'BY', 'CALL', 'CASE', 'CHECKPOINT', 'CHKP', 'CHKP-STATUS', 'CLEAR',
+        'CLOSE', 'COL', 'COLOR', 'COMMIT', 'CONTROL', 'COPY', 'CURSOR', 'D',
+        'DECLARE', 'DEFAULT', 'DEFINE', 'DELETE', 'DENWA', 'DISPLAY', 'DLI',
+        'DO', 'DUPLICATE', 'E', 'ELSE', 'ELSE-IF', 'END', 'END-CASE',
+        'END-DO', 'END-IF', 'END-PROC', 'ENDPAGE', 'ENDTABLE', 'ENTER', 'EOF',
+        'EQ', 'ERROR', 'EXIT', 'EXTERNAL', 'EZLIB', 'F1', 'F10', 'F11', 'F12',
+        'F13', 'F14', 'F15', 'F16', 'F17', 'F18', 'F19', 'F2', 'F20', 'F21',
+        'F22', 'F23', 'F24', 'F25', 'F26', 'F27', 'F28', 'F29', 'F3', 'F30',
+        'F31', 'F32', 'F33', 'F34', 'F35', 'F36', 'F4', 'F5', 'F6', 'F7',
+        'F8', 'F9', 'FETCH', 'FILE-STATUS', 'FILL', 'FINAL', 'FIRST',
+        'FIRST-DUP', 'FOR', 'GE', 'GET', 'GO', 'GOTO', 'GQ', 'GR', 'GT',
+        'HEADING', 'HEX', 'HIGH-VALUES', 'IDD', 'IDMS', 'IF', 'IN', 'INSERT',
+        'JUSTIFY', 'KANJI-DATE', 'KANJI-DATE-LONG', 'KANJI-TIME', 'KEY',
+        'KEY-PRESSED', 'KOKUGO', 'KUN', 'LAST-DUP', 'LE', 'LEVEL', 'LIKE',
+        'LINE', 'LINE-COUNT', 'LINE-NUMBER', 'LINK', 'LIST', 'LOW-VALUES',
+        'LQ', 'LS', 'LT', 'MACRO', 'MASK', 'MATCHED', 'MEND', 'MESSAGE',
+        'MOVE', 'MSTART', 'NE', 'NEWPAGE', 'NOMASK', 'NOPRINT', 'NOT',
+        'NOTE', 'NOVERIFY', 'NQ', 'NULL', 'OF', 'OR', 'OTHERWISE', 'PA1',
+        'PA2', 'PA3', 'PAGE-COUNT', 'PAGE-NUMBER', 'PARM-REGISTER',
+        'PATH-ID', 'PATTERN', 'PERFORM', 'POINT', 'POS', 'PRIMARY', 'PRINT',
+        'PROCEDURE', 'PROGRAM', 'PUT', 'READ', 'RECORD', 'RECORD-COUNT',
+        'RECORD-LENGTH', 'REFRESH', 'RELEASE', 'RENUM', 'REPEAT', 'REPORT',
+        'REPORT-INPUT', 'RESHOW', 'RESTART', 'RETRIEVE', 'RETURN-CODE',
+        'ROLLBACK', 'ROW', 'S', 'SCREEN', 'SEARCH', 'SECONDARY', 'SELECT',
+        'SEQUENCE', 'SIZE', 'SKIP', 'SOKAKU', 'SORT', 'SQL', 'STOP', 'SUM',
+        'SYSDATE', 'SYSDATE-LONG', 'SYSIN', 'SYSIPT', 'SYSLST', 'SYSPRINT',
+        'SYSSNAP', 'SYSTIME', 'TALLY', 'TERM-COLUMNS', 'TERM-NAME',
+        'TERM-ROWS', 'TERMINATION', 'TITLE', 'TO', 'TRANSFER', 'TRC',
+        'UNIQUE', 'UNTIL', 'UPDATE', 'UPPERCASE', 'USER', 'USERID', 'VALUE',
+        'VERIFY', 'W', 'WHEN', 'WHILE', 'WORK', 'WRITE', 'X', 'XDM', 'XRST'
+    ]
+
+    tokens = {
+        'root': [
+            (r'\*.*\n', Comment.Single),
+            (r'\n+', Whitespace),
+            # Macro argument
+            (r'&' + _NON_DELIMITER_OR_COMMENT_PATTERN + r'+\.', Name.Variable,
+             'after_macro_argument'),
+            # Macro call
+            (r'%' + _NON_DELIMITER_OR_COMMENT_PATTERN + r'+', Name.Variable),
+            (r'(FILE|MACRO|REPORT)(\s+)',
+             bygroups(Keyword.Declaration, Whitespace), 'after_declaration'),
+            (r'(JOB|PARM)' + r'(' + _DELIMITER_PATTERN + r')',
+             bygroups(Keyword.Declaration, Operator)),
+            (words(_KEYWORDS, suffix=_DELIMITER_PATTERN_CAPTURE),
+             bygroups(Keyword.Reserved, Operator)),
+            (_OPERATORS_PATTERN, Operator),
+            # Procedure declaration
+            (r'(' + _NON_DELIMITER_OR_COMMENT_PATTERN + r'+)(\s*)(\.?)(\s*)(PROC)(\s*\n)',
+             bygroups(Name.Function, Whitespace, Operator, Whitespace,
+                      Keyword.Declaration, Whitespace)),
+            (r'[0-9]+\.[0-9]*', Number.Float),
+            (r'[0-9]+', Number.Integer),
+            (r"'(''|[^'])*'", String),
+            (r'\s+', Whitespace),
+            # Everything else just belongs to a name
+            (_NON_DELIMITER_OR_COMMENT_PATTERN + r'+', Name),
+         ],
+        'after_declaration': [
+            (_NON_DELIMITER_OR_COMMENT_PATTERN + r'+', Name.Function),
+            default('#pop'),
+        ],
+        'after_macro_argument': [
+            (r'\*.*\n', Comment.Single, '#pop'),
+            (r'\s+', Whitespace, '#pop'),
+            (_OPERATORS_PATTERN, Operator, '#pop'),
+            (r"'(''|[^'])*'", String, '#pop'),
+            # Everything else just belongs to a name
+            (_NON_DELIMITER_OR_COMMENT_PATTERN + r'+', Name),
+        ],
+    }
+    _COMMENT_LINE_REGEX = re.compile(r'^\s*\*')
+    _MACRO_HEADER_REGEX = re.compile(r'^\s*MACRO')
+
+    def analyse_text(text):
+        """
+        Perform a structural analysis for basic Easytrieve constructs.
+        """
+        result = 0.0
+        lines = text.split('\n')
+        hasEndProc = False
+        hasHeaderComment = False
+        hasFile = False
+        hasJob = False
+        hasProc = False
+        hasParm = False
+        hasReport = False
+
+        def isCommentLine(line):
+            return EasytrieveLexer._COMMENT_LINE_REGEX.match(lines[0]) is not None
+
+        def isEmptyLine(line):
+            return not bool(line.strip())
+
+        # Remove possible empty lines and header comments.
+        while lines and (isEmptyLine(lines[0]) or isCommentLine(lines[0])):
+            if not isEmptyLine(lines[0]):
+                hasHeaderComment = True
+            del lines[0]
+
+        if EasytrieveLexer._MACRO_HEADER_REGEX.match(lines[0]):
+            # Looks like an Easytrieve macro.
+            result = 0.4
+            if hasHeaderComment:
+                result += 0.4
+        else:
+            # Scan the source for lines starting with indicators.
+            for line in lines:
+                words = line.split()
+                if (len(words) >= 2):
+                    firstWord = words[0]
+                    if not hasReport:
+                        if not hasJob:
+                            if not hasFile:
+                                if not hasParm:
+                                    if firstWord == 'PARM':
+                                        hasParm = True
+                                if firstWord == 'FILE':
+                                    hasFile = True
+                            if firstWord == 'JOB':
+                                hasJob = True
+                        elif firstWord == 'PROC':
+                            hasProc = True
+                        elif firstWord == 'END-PROC':
+                            hasEndProc = True
+                        elif firstWord == 'REPORT':
+                            hasReport = True
+
+            # Weight the findings.
+            if hasJob and (hasProc == hasEndProc):
+                if hasHeaderComment:
+                    result += 0.1
+                if hasParm:
+                    if hasProc:
+                        # Found PARM, JOB and PROC/END-PROC:
+                        # pretty sure this is Easytrieve.
+                        result += 0.8
+                    else:
+                        # Found PARAM and  JOB: probably this is Easytrieve
+                        result += 0.5
+                else:
+                    # Found JOB and possibly other keywords: might be Easytrieve
+                    result += 0.11
+                    if hasParm:
+                        # Note: PARAM is not a proper English word, so this is
+                        # regarded a much better indicator for Easytrieve than
+                        # the other words.
+                        result += 0.2
+                    if hasFile:
+                        result += 0.01
+                    if hasReport:
+                        result += 0.01
+        assert 0.0 <= result <= 1.0
+        return result
+
+
+class JclLexer(RegexLexer):
+    """
+    Job Control Language (JCL)
+    is a scripting language used on mainframe platforms to instruct the system
+    on how to run a batch job or start a subsystem. It is somewhat
+    comparable to MS DOS batch and Unix shell scripts.
+    """
+    name = 'JCL'
+    aliases = ['jcl']
+    filenames = ['*.jcl']
+    mimetypes = ['text/x-jcl']
+    url = 'https://en.wikipedia.org/wiki/Job_Control_Language'
+    version_added = '2.1'
+
+    flags = re.IGNORECASE
+
+    tokens = {
+        'root': [
+            (r'//\*.*\n', Comment.Single),
+            (r'//', Keyword.Pseudo, 'statement'),
+            (r'/\*', Keyword.Pseudo, 'jes2_statement'),
+            # TODO: JES3 statement
+            (r'.*\n', Other)  # Input text or inline code in any language.
+        ],
+        'statement': [
+            (r'\s*\n', Whitespace, '#pop'),
+            (r'([a-z]\w*)(\s+)(exec|job)(\s*)',
+             bygroups(Name.Label, Whitespace, Keyword.Reserved, Whitespace),
+             'option'),
+            (r'[a-z]\w*', Name.Variable, 'statement_command'),
+            (r'\s+', Whitespace, 'statement_command'),
+        ],
+        'statement_command': [
+            (r'\s+(command|cntl|dd|endctl|endif|else|include|jcllib|'
+             r'output|pend|proc|set|then|xmit)\s+', Keyword.Reserved, 'option'),
+            include('option')
+        ],
+        'jes2_statement': [
+            (r'\s*\n', Whitespace, '#pop'),
+            (r'\$', Keyword, 'option'),
+            (r'\b(jobparam|message|netacct|notify|output|priority|route|'
+             r'setup|signoff|xeq|xmit)\b', Keyword, 'option'),
+        ],
+        'option': [
+            # (r'\n', Text, 'root'),
+            (r'\*', Name.Builtin),
+            (r'[\[\](){}<>;,]', Punctuation),
+            (r'[-+*/=&%]', Operator),
+            (r'[a-z_]\w*', Name),
+            (r'\d+\.\d*', Number.Float),
+            (r'\.\d+', Number.Float),
+            (r'\d+', Number.Integer),
+            (r"'", String, 'option_string'),
+            (r'[ \t]+', Whitespace, 'option_comment'),
+            (r'\.', Punctuation),
+        ],
+        'option_string': [
+            (r"(\n)(//)", bygroups(Text, Keyword.Pseudo)),
+            (r"''", String),
+            (r"[^']", String),
+            (r"'", String, '#pop'),
+        ],
+        'option_comment': [
+            # (r'\n', Text, 'root'),
+            (r'.+', Comment.Single),
+        ]
+    }
+
+    _JOB_HEADER_PATTERN = re.compile(r'^//[a-z#$@][a-z0-9#$@]{0,7}\s+job(\s+.*)?$',
+                                     re.IGNORECASE)
+
+    def analyse_text(text):
+        """
+        Recognize JCL job by header.
+        """
+        result = 0.0
+        lines = text.split('\n')
+        if len(lines) > 0:
+            if JclLexer._JOB_HEADER_PATTERN.match(lines[0]):
+                result = 1.0
+        assert 0.0 <= result <= 1.0
+        return result
+
+
+class MiniScriptLexer(RegexLexer):
+    """
+    For MiniScript source code.
+    """
+
+    name = 'MiniScript'
+    url = 'https://miniscript.org'
+    aliases = ['miniscript', 'ms']
+    filenames = ['*.ms']
+    mimetypes = ['text/x-minicript', 'application/x-miniscript']
+    version_added = '2.6'
+
+    tokens = {
+        'root': [
+            (r'#!(.*?)$', Comment.Preproc),
+            default('base'),
+        ],
+        'base': [
+            ('//.*$', Comment.Single),
+            (r'(?i)(\d*\.\d+|\d+\.\d*)(e[+-]?\d+)?', Number),
+            (r'(?i)\d+e[+-]?\d+', Number),
+            (r'\d+', Number),
+            (r'\n', Text),
+            (r'[^\S\n]+', Text),
+            (r'"', String, 'string_double'),
+            (r'(==|!=|<=|>=|[=+\-*/%^<>.:])', Operator),
+            (r'[;,\[\]{}()]', Punctuation),
+            (words((
+                'break', 'continue', 'else', 'end', 'for', 'function', 'if',
+                'in', 'isa', 'then', 'repeat', 'return', 'while'), suffix=r'\b'),
+             Keyword),
+            (words((
+                'abs', 'acos', 'asin', 'atan', 'ceil', 'char', 'cos', 'floor',
+                'log', 'round', 'rnd', 'pi', 'sign', 'sin', 'sqrt', 'str', 'tan',
+                'hasIndex', 'indexOf', 'len', 'val', 'code', 'remove', 'lower',
+                'upper', 'replace', 'split', 'indexes', 'values', 'join', 'sum',
+                'sort', 'shuffle', 'push', 'pop', 'pull', 'range',
+                'print', 'input', 'time', 'wait', 'locals', 'globals', 'outer',
+                'yield'), suffix=r'\b'),
+             Name.Builtin),
+            (r'(true|false|null)\b', Keyword.Constant),
+            (r'(and|or|not|new)\b', Operator.Word),
+            (r'(self|super|__isa)\b', Name.Builtin.Pseudo),
+            (r'[a-zA-Z_]\w*', Name.Variable)
+        ],
+        'string_double': [
+            (r'[^"\n]+', String),
+            (r'""', String),
+            (r'"', String, '#pop'),
+            (r'\n', Text, '#pop'),  # Stray linefeed also terminates strings.
+        ]
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/sgf.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/sgf.py
new file mode 100644
index 0000000000000000000000000000000000000000..6d7c30432cc39e99f3cacebde19db1550c814ac8
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/sgf.py
@@ -0,0 +1,59 @@
+"""
+    pygments.lexers.sgf
+    ~~~~~~~~~~~~~~~~~~~
+
+    Lexer for Smart Game Format (sgf) file format.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, bygroups
+from pygments.token import Name, Literal, String, Punctuation, Whitespace
+
+__all__ = ["SmartGameFormatLexer"]
+
+
+class SmartGameFormatLexer(RegexLexer):
+    """
+    Lexer for Smart Game Format (sgf) file format.
+
+    The format is used to store game records of board games for two players
+    (mainly Go game).
+    """
+    name = 'SmartGameFormat'
+    url = 'https://www.red-bean.com/sgf/'
+    aliases = ['sgf']
+    filenames = ['*.sgf']
+    version_added = '2.4'
+
+    tokens = {
+        'root': [
+            (r'[():;]+', Punctuation),
+            # tokens:
+            (r'(A[BW]|AE|AN|AP|AR|AS|[BW]L|BM|[BW]R|[BW]S|[BW]T|CA|CH|CP|CR|'
+             r'DD|DM|DO|DT|EL|EV|EX|FF|FG|G[BW]|GC|GM|GN|HA|HO|ID|IP|IT|IY|KM|'
+             r'KO|LB|LN|LT|L|MA|MN|M|N|OB|OM|ON|OP|OT|OV|P[BW]|PC|PL|PM|RE|RG|'
+             r'RO|RU|SO|SC|SE|SI|SL|SO|SQ|ST|SU|SZ|T[BW]|TC|TE|TM|TR|UC|US|VW|'
+             r'V|[BW]|C)',
+             Name.Builtin),
+            # number:
+            (r'(\[)([0-9.]+)(\])',
+             bygroups(Punctuation, Literal.Number, Punctuation)),
+            # date:
+            (r'(\[)([0-9]{4}-[0-9]{2}-[0-9]{2})(\])',
+             bygroups(Punctuation, Literal.Date, Punctuation)),
+            # point:
+            (r'(\[)([a-z]{2})(\])',
+             bygroups(Punctuation, String, Punctuation)),
+            # double points:
+            (r'(\[)([a-z]{2})(:)([a-z]{2})(\])',
+             bygroups(Punctuation, String, Punctuation, String, Punctuation)),
+
+            (r'(\[)([\w\s#()+,\-.:?]+)(\])',
+             bygroups(Punctuation, String, Punctuation)),
+            (r'(\[)(\s.*)(\])',
+             bygroups(Punctuation, Whitespace, Punctuation)),
+            (r'\s+', Whitespace)
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/shell.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/shell.py
new file mode 100644
index 0000000000000000000000000000000000000000..c1ce07fcc8aa5ac7aab453df30af21f94d859f3e
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/shell.py
@@ -0,0 +1,902 @@
+"""
+    pygments.lexers.shell
+    ~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for various shells.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import re
+
+from pygments.lexer import Lexer, RegexLexer, do_insertions, bygroups, \
+    include, default, this, using, words, line_re
+from pygments.token import Punctuation, Whitespace, \
+    Text, Comment, Operator, Keyword, Name, String, Number, Generic
+from pygments.util import shebang_matches
+
+__all__ = ['BashLexer', 'BashSessionLexer', 'TcshLexer', 'BatchLexer',
+           'SlurmBashLexer', 'MSDOSSessionLexer', 'PowerShellLexer',
+           'PowerShellSessionLexer', 'TcshSessionLexer', 'FishShellLexer',
+           'ExeclineLexer']
+
+
+class BashLexer(RegexLexer):
+    """
+    Lexer for (ba|k|z|)sh shell scripts.
+    """
+
+    name = 'Bash'
+    aliases = ['bash', 'sh', 'ksh', 'zsh', 'shell', 'openrc']
+    filenames = ['*.sh', '*.ksh', '*.bash', '*.ebuild', '*.eclass',
+                 '*.exheres-0', '*.exlib', '*.zsh',
+                 '.bashrc', 'bashrc', '.bash_*', 'bash_*', 'zshrc', '.zshrc',
+                 '.kshrc', 'kshrc',
+                 'PKGBUILD']
+    mimetypes = ['application/x-sh', 'application/x-shellscript', 'text/x-shellscript']
+    url = 'https://en.wikipedia.org/wiki/Unix_shell'
+    version_added = '0.6'
+
+    tokens = {
+        'root': [
+            include('basic'),
+            (r'`', String.Backtick, 'backticks'),
+            include('data'),
+            include('interp'),
+        ],
+        'interp': [
+            (r'\$\(\(', Keyword, 'math'),
+            (r'\$\(', Keyword, 'paren'),
+            (r'\$\{#?', String.Interpol, 'curly'),
+            (r'\$[a-zA-Z_]\w*', Name.Variable),  # user variable
+            (r'\$(?:\d+|[#$?!_*@-])', Name.Variable),      # builtin
+            (r'\$', Text),
+        ],
+        'basic': [
+            (r'\b(if|fi|else|while|in|do|done|for|then|return|function|case|'
+             r'select|break|continue|until|esac|elif)(\s*)\b',
+             bygroups(Keyword, Whitespace)),
+            (r'\b(alias|bg|bind|builtin|caller|cd|command|compgen|'
+             r'complete|declare|dirs|disown|echo|enable|eval|exec|exit|'
+             r'export|false|fc|fg|getopts|hash|help|history|jobs|kill|let|'
+             r'local|logout|popd|printf|pushd|pwd|read|readonly|set|shift|'
+             r'shopt|source|suspend|test|time|times|trap|true|type|typeset|'
+             r'ulimit|umask|unalias|unset|wait)(?=[\s)`])',
+             Name.Builtin),
+            (r'\A#!.+\n', Comment.Hashbang),
+            (r'#.*\n', Comment.Single),
+            (r'\\[\w\W]', String.Escape),
+            (r'(\b\w+)(\s*)(\+?=)', bygroups(Name.Variable, Whitespace, Operator)),
+            (r'[\[\]{}()=]', Operator),
+            (r'<<<', Operator),  # here-string
+            (r'<<-?\s*(\'?)\\?(\w+)[\w\W]+?\2', String),
+            (r'&&|\|\|', Operator),
+        ],
+        'data': [
+            (r'(?s)\$?"(\\.|[^"\\$])*"', String.Double),
+            (r'"', String.Double, 'string'),
+            (r"(?s)\$'(\\\\|\\[0-7]+|\\.|[^'\\])*'", String.Single),
+            (r"(?s)'.*?'", String.Single),
+            (r';', Punctuation),
+            (r'&', Punctuation),
+            (r'\|', Punctuation),
+            (r'\s+', Whitespace),
+            (r'\d+\b', Number),
+            (r'[^=\s\[\]{}()$"\'`\\<&|;]+', Text),
+            (r'<', Text),
+        ],
+        'string': [
+            (r'"', String.Double, '#pop'),
+            (r'(?s)(\\\\|\\[0-7]+|\\.|[^"\\$])+', String.Double),
+            include('interp'),
+        ],
+        'curly': [
+            (r'\}', String.Interpol, '#pop'),
+            (r':-', Keyword),
+            (r'\w+', Name.Variable),
+            (r'[^}:"\'`$\\]+', Punctuation),
+            (r':', Punctuation),
+            include('root'),
+        ],
+        'paren': [
+            (r'\)', Keyword, '#pop'),
+            include('root'),
+        ],
+        'math': [
+            (r'\)\)', Keyword, '#pop'),
+            (r'\*\*|\|\||<<|>>|[-+*/%^|&<>]', Operator),
+            (r'\d+#[\da-zA-Z]+', Number),
+            (r'\d+#(?! )', Number),
+            (r'0[xX][\da-fA-F]+', Number),
+            (r'\d+', Number),
+            (r'[a-zA-Z_]\w*', Name.Variable),  # user variable
+            include('root'),
+        ],
+        'backticks': [
+            (r'`', String.Backtick, '#pop'),
+            include('root'),
+        ],
+    }
+
+    def analyse_text(text):
+        if shebang_matches(text, r'(ba|z|)sh'):
+            return 1
+        if text.startswith('$ '):
+            return 0.2
+
+
+class SlurmBashLexer(BashLexer):
+    """
+    Lexer for (ba|k|z|)sh Slurm scripts.
+    """
+
+    name = 'Slurm'
+    aliases = ['slurm', 'sbatch']
+    filenames = ['*.sl']
+    mimetypes = []
+    version_added = '2.4'
+    EXTRA_KEYWORDS = {'srun'}
+
+    def get_tokens_unprocessed(self, text):
+        for index, token, value in BashLexer.get_tokens_unprocessed(self, text):
+            if token is Text and value in self.EXTRA_KEYWORDS:
+                yield index, Name.Builtin, value
+            elif token is Comment.Single and 'SBATCH' in value:
+                yield index, Keyword.Pseudo, value
+            else:
+                yield index, token, value
+
+
+class ShellSessionBaseLexer(Lexer):
+    """
+    Base lexer for shell sessions.
+
+    .. versionadded:: 2.1
+    """
+
+    _bare_continuation = False
+    _venv = re.compile(r'^(\([^)]*\))(\s*)')
+
+    def get_tokens_unprocessed(self, text):
+        innerlexer = self._innerLexerCls(**self.options)
+
+        pos = 0
+        curcode = ''
+        insertions = []
+        backslash_continuation = False
+
+        for match in line_re.finditer(text):
+            line = match.group()
+
+            venv_match = self._venv.match(line)
+            if venv_match:
+                venv = venv_match.group(1)
+                venv_whitespace = venv_match.group(2)
+                insertions.append((len(curcode),
+                                   [(0, Generic.Prompt.VirtualEnv, venv)]))
+                if venv_whitespace:
+                    insertions.append((len(curcode),
+                                       [(0, Text, venv_whitespace)]))
+                line = line[venv_match.end():]
+
+            m = self._ps1rgx.match(line)
+            if m:
+                # To support output lexers (say diff output), the output
+                # needs to be broken by prompts whenever the output lexer
+                # changes.
+                if not insertions:
+                    pos = match.start()
+
+                insertions.append((len(curcode),
+                                   [(0, Generic.Prompt, m.group(1))]))
+                curcode += m.group(2)
+                backslash_continuation = curcode.endswith('\\\n')
+            elif backslash_continuation:
+                if line.startswith(self._ps2):
+                    insertions.append((len(curcode),
+                                       [(0, Generic.Prompt,
+                                         line[:len(self._ps2)])]))
+                    curcode += line[len(self._ps2):]
+                else:
+                    curcode += line
+                backslash_continuation = curcode.endswith('\\\n')
+            elif self._bare_continuation and line.startswith(self._ps2):
+                insertions.append((len(curcode),
+                                   [(0, Generic.Prompt,
+                                     line[:len(self._ps2)])]))
+                curcode += line[len(self._ps2):]
+            else:
+                if insertions:
+                    toks = innerlexer.get_tokens_unprocessed(curcode)
+                    for i, t, v in do_insertions(insertions, toks):
+                        yield pos+i, t, v
+                yield match.start(), Generic.Output, line
+                insertions = []
+                curcode = ''
+        if insertions:
+            for i, t, v in do_insertions(insertions,
+                                         innerlexer.get_tokens_unprocessed(curcode)):
+                yield pos+i, t, v
+
+
+class BashSessionLexer(ShellSessionBaseLexer):
+    """
+    Lexer for Bash shell sessions, i.e. command lines, including a
+    prompt, interspersed with output.
+    """
+
+    name = 'Bash Session'
+    aliases = ['console', 'shell-session']
+    filenames = ['*.sh-session', '*.shell-session']
+    mimetypes = ['application/x-shell-session', 'application/x-sh-session']
+    url = 'https://en.wikipedia.org/wiki/Unix_shell'
+    version_added = '1.1'
+    _example = "console/example.sh-session"
+
+    _innerLexerCls = BashLexer
+    _ps1rgx = re.compile(
+        r'^((?:(?:\[.*?\])|(?:\(\S+\))?(?:| |sh\S*?|\w+\S+[@:]\S+(?:\s+\S+)' \
+        r'?|\[\S+[@:][^\n]+\].+))\s*[$#%]\s*)(.*\n?)')
+    _ps2 = '> '
+
+
+class BatchLexer(RegexLexer):
+    """
+    Lexer for the DOS/Windows Batch file format.
+    """
+    name = 'Batchfile'
+    aliases = ['batch', 'bat', 'dosbatch', 'winbatch']
+    filenames = ['*.bat', '*.cmd']
+    mimetypes = ['application/x-dos-batch']
+    url = 'https://en.wikipedia.org/wiki/Batch_file'
+    version_added = '0.7'
+
+    flags = re.MULTILINE | re.IGNORECASE
+
+    _nl = r'\n\x1a'
+    _punct = r'&<>|'
+    _ws = r'\t\v\f\r ,;=\xa0'
+    _nlws = r'\s\x1a\xa0,;='
+    _space = rf'(?:(?:(?:\^[{_nl}])?[{_ws}])+)'
+    _keyword_terminator = (rf'(?=(?:\^[{_nl}]?)?[{_ws}+./:[\\\]]|[{_nl}{_punct}(])')
+    _token_terminator = rf'(?=\^?[{_ws}]|[{_punct}{_nl}])'
+    _start_label = rf'((?:(?<=^[^:])|^[^:]?)[{_ws}]*)(:)'
+    _label = rf'(?:(?:[^{_nlws}{_punct}+:^]|\^[{_nl}]?[\w\W])*)'
+    _label_compound = rf'(?:(?:[^{_nlws}{_punct}+:^)]|\^[{_nl}]?[^)])*)'
+    _number = rf'(?:-?(?:0[0-7]+|0x[\da-f]+|\d+){_token_terminator})'
+    _opword = r'(?:equ|geq|gtr|leq|lss|neq)'
+    _string = rf'(?:"[^{_nl}"]*(?:"|(?=[{_nl}])))'
+    _variable = (r'(?:(?:%(?:\*|(?:~[a-z]*(?:\$[^:]+:)?)?\d|'
+                 rf'[^%:{_nl}]+(?::(?:~(?:-?\d+)?(?:,(?:-?\d+)?)?|(?:[^%{_nl}^]|'
+                 rf'\^[^%{_nl}])[^={_nl}]*=(?:[^%{_nl}^]|\^[^%{_nl}])*)?)?%))|'
+                 rf'(?:\^?![^!:{_nl}]+(?::(?:~(?:-?\d+)?(?:,(?:-?\d+)?)?|(?:'
+                 rf'[^!{_nl}^]|\^[^!{_nl}])[^={_nl}]*=(?:[^!{_nl}^]|\^[^!{_nl}])*)?)?\^?!))')
+    _core_token = rf'(?:(?:(?:\^[{_nl}]?)?[^"{_nlws}{_punct}])+)'
+    _core_token_compound = rf'(?:(?:(?:\^[{_nl}]?)?[^"{_nlws}{_punct})])+)'
+    _token = rf'(?:[{_punct}]+|{_core_token})'
+    _token_compound = rf'(?:[{_punct}]+|{_core_token_compound})'
+    _stoken = (rf'(?:[{_punct}]+|(?:{_string}|{_variable}|{_core_token})+)')
+
+    def _make_begin_state(compound, _core_token=_core_token,
+                          _core_token_compound=_core_token_compound,
+                          _keyword_terminator=_keyword_terminator,
+                          _nl=_nl, _punct=_punct, _string=_string,
+                          _space=_space, _start_label=_start_label,
+                          _stoken=_stoken, _token_terminator=_token_terminator,
+                          _variable=_variable, _ws=_ws):
+        rest = '(?:{}|{}|[^"%{}{}{}])*'.format(_string, _variable, _nl, _punct,
+                                            ')' if compound else '')
+        rest_of_line = rf'(?:(?:[^{_nl}^]|\^[{_nl}]?[\w\W])*)'
+        rest_of_line_compound = rf'(?:(?:[^{_nl}^)]|\^[{_nl}]?[^)])*)'
+        set_space = rf'((?:(?:\^[{_nl}]?)?[^\S\n])*)'
+        suffix = ''
+        if compound:
+            _keyword_terminator = rf'(?:(?=\))|{_keyword_terminator})'
+            _token_terminator = rf'(?:(?=\))|{_token_terminator})'
+            suffix = '/compound'
+        return [
+            ((r'\)', Punctuation, '#pop') if compound else
+             (rf'\)((?=\()|{_token_terminator}){rest_of_line}',
+              Comment.Single)),
+            (rf'(?={_start_label})', Text, f'follow{suffix}'),
+            (_space, using(this, state='text')),
+            include(f'redirect{suffix}'),
+            (rf'[{_nl}]+', Text),
+            (r'\(', Punctuation, 'root/compound'),
+            (r'@+', Punctuation),
+            (rf'((?:for|if|rem)(?:(?=(?:\^[{_nl}]?)?/)|(?:(?!\^)|'
+             rf'(?<=m))(?:(?=\()|{_token_terminator})))({_space}?{_core_token_compound if compound else _core_token}?(?:\^[{_nl}]?)?/(?:\^[{_nl}]?)?\?)',
+             bygroups(Keyword, using(this, state='text')),
+             f'follow{suffix}'),
+            (rf'(goto{_keyword_terminator})({rest}(?:\^[{_nl}]?)?/(?:\^[{_nl}]?)?\?{rest})',
+             bygroups(Keyword, using(this, state='text')),
+             f'follow{suffix}'),
+            (words(('assoc', 'break', 'cd', 'chdir', 'cls', 'color', 'copy',
+                    'date', 'del', 'dir', 'dpath', 'echo', 'endlocal', 'erase',
+                    'exit', 'ftype', 'keys', 'md', 'mkdir', 'mklink', 'move',
+                    'path', 'pause', 'popd', 'prompt', 'pushd', 'rd', 'ren',
+                    'rename', 'rmdir', 'setlocal', 'shift', 'start', 'time',
+                    'title', 'type', 'ver', 'verify', 'vol'),
+                   suffix=_keyword_terminator), Keyword, f'follow{suffix}'),
+            (rf'(call)({_space}?)(:)',
+             bygroups(Keyword, using(this, state='text'), Punctuation),
+             f'call{suffix}'),
+            (rf'call{_keyword_terminator}', Keyword),
+            (rf'(for{_token_terminator}(?!\^))({_space})(/f{_token_terminator})',
+             bygroups(Keyword, using(this, state='text'), Keyword),
+             ('for/f', 'for')),
+            (rf'(for{_token_terminator}(?!\^))({_space})(/l{_token_terminator})',
+             bygroups(Keyword, using(this, state='text'), Keyword),
+             ('for/l', 'for')),
+            (rf'for{_token_terminator}(?!\^)', Keyword, ('for2', 'for')),
+            (rf'(goto{_keyword_terminator})({_space}?)(:?)',
+             bygroups(Keyword, using(this, state='text'), Punctuation),
+             f'label{suffix}'),
+            (rf'(if(?:(?=\()|{_token_terminator})(?!\^))({_space}?)((?:/i{_token_terminator})?)({_space}?)((?:not{_token_terminator})?)({_space}?)',
+             bygroups(Keyword, using(this, state='text'), Keyword,
+                      using(this, state='text'), Keyword,
+                      using(this, state='text')), ('(?', 'if')),
+            (rf'rem(((?=\()|{_token_terminator}){_space}?{_stoken}?.*|{_keyword_terminator}{rest_of_line_compound if compound else rest_of_line})',
+             Comment.Single, f'follow{suffix}'),
+            (rf'(set{_keyword_terminator}){set_space}(/a)',
+             bygroups(Keyword, using(this, state='text'), Keyword),
+             f'arithmetic{suffix}'),
+            (r'(set{}){}((?:/p)?){}((?:(?:(?:\^[{}]?)?[^"{}{}^={}]|'
+             r'\^[{}]?[^"=])+)?)((?:(?:\^[{}]?)?=)?)'.format(_keyword_terminator, set_space, set_space, _nl, _nl, _punct,
+              ')' if compound else '', _nl, _nl),
+             bygroups(Keyword, using(this, state='text'), Keyword,
+                      using(this, state='text'), using(this, state='variable'),
+                      Punctuation),
+             f'follow{suffix}'),
+            default(f'follow{suffix}')
+        ]
+
+    def _make_follow_state(compound, _label=_label,
+                           _label_compound=_label_compound, _nl=_nl,
+                           _space=_space, _start_label=_start_label,
+                           _token=_token, _token_compound=_token_compound,
+                           _ws=_ws):
+        suffix = '/compound' if compound else ''
+        state = []
+        if compound:
+            state.append((r'(?=\))', Text, '#pop'))
+        state += [
+            (rf'{_start_label}([{_ws}]*)({_label_compound if compound else _label})(.*)',
+             bygroups(Text, Punctuation, Text, Name.Label, Comment.Single)),
+            include(f'redirect{suffix}'),
+            (rf'(?=[{_nl}])', Text, '#pop'),
+            (r'\|\|?|&&?', Punctuation, '#pop'),
+            include('text')
+        ]
+        return state
+
+    def _make_arithmetic_state(compound, _nl=_nl, _punct=_punct,
+                               _string=_string, _variable=_variable,
+                               _ws=_ws, _nlws=_nlws):
+        op = r'=+\-*/!~'
+        state = []
+        if compound:
+            state.append((r'(?=\))', Text, '#pop'))
+        state += [
+            (r'0[0-7]+', Number.Oct),
+            (r'0x[\da-f]+', Number.Hex),
+            (r'\d+', Number.Integer),
+            (r'[(),]+', Punctuation),
+            (rf'([{op}]|%|\^\^)+', Operator),
+            (r'({}|{}|(\^[{}]?)?[^(){}%\^"{}{}]|\^[{}]?{})+'.format(_string, _variable, _nl, op, _nlws, _punct, _nlws,
+              r'[^)]' if compound else r'[\w\W]'),
+             using(this, state='variable')),
+            (r'(?=[\x00|&])', Text, '#pop'),
+            include('follow')
+        ]
+        return state
+
+    def _make_call_state(compound, _label=_label,
+                         _label_compound=_label_compound):
+        state = []
+        if compound:
+            state.append((r'(?=\))', Text, '#pop'))
+        state.append((r'(:?)(%s)' % (_label_compound if compound else _label),
+                      bygroups(Punctuation, Name.Label), '#pop'))
+        return state
+
+    def _make_label_state(compound, _label=_label,
+                          _label_compound=_label_compound, _nl=_nl,
+                          _punct=_punct, _string=_string, _variable=_variable):
+        state = []
+        if compound:
+            state.append((r'(?=\))', Text, '#pop'))
+        state.append((r'({}?)((?:{}|{}|\^[{}]?{}|[^"%^{}{}{}])*)'.format(_label_compound if compound else _label, _string,
+                       _variable, _nl, r'[^)]' if compound else r'[\w\W]', _nl,
+                       _punct, r')' if compound else ''),
+                      bygroups(Name.Label, Comment.Single), '#pop'))
+        return state
+
+    def _make_redirect_state(compound,
+                             _core_token_compound=_core_token_compound,
+                             _nl=_nl, _punct=_punct, _stoken=_stoken,
+                             _string=_string, _space=_space,
+                             _variable=_variable, _nlws=_nlws):
+        stoken_compound = (rf'(?:[{_punct}]+|(?:{_string}|{_variable}|{_core_token_compound})+)')
+        return [
+            (rf'((?:(?<=[{_nlws}])\d)?)(>>?&|<&)([{_nlws}]*)(\d)',
+             bygroups(Number.Integer, Punctuation, Text, Number.Integer)),
+            (rf'((?:(?<=[{_nlws}])(?>?|<)({_space}?{stoken_compound if compound else _stoken})',
+             bygroups(Number.Integer, Punctuation, using(this, state='text')))
+        ]
+
+    tokens = {
+        'root': _make_begin_state(False),
+        'follow': _make_follow_state(False),
+        'arithmetic': _make_arithmetic_state(False),
+        'call': _make_call_state(False),
+        'label': _make_label_state(False),
+        'redirect': _make_redirect_state(False),
+        'root/compound': _make_begin_state(True),
+        'follow/compound': _make_follow_state(True),
+        'arithmetic/compound': _make_arithmetic_state(True),
+        'call/compound': _make_call_state(True),
+        'label/compound': _make_label_state(True),
+        'redirect/compound': _make_redirect_state(True),
+        'variable-or-escape': [
+            (_variable, Name.Variable),
+            (rf'%%|\^[{_nl}]?(\^!|[\w\W])', String.Escape)
+        ],
+        'string': [
+            (r'"', String.Double, '#pop'),
+            (_variable, Name.Variable),
+            (r'\^!|%%', String.Escape),
+            (rf'[^"%^{_nl}]+|[%^]', String.Double),
+            default('#pop')
+        ],
+        'sqstring': [
+            include('variable-or-escape'),
+            (r'[^%]+|%', String.Single)
+        ],
+        'bqstring': [
+            include('variable-or-escape'),
+            (r'[^%]+|%', String.Backtick)
+        ],
+        'text': [
+            (r'"', String.Double, 'string'),
+            include('variable-or-escape'),
+            (rf'[^"%^{_nlws}{_punct}\d)]+|.', Text)
+        ],
+        'variable': [
+            (r'"', String.Double, 'string'),
+            include('variable-or-escape'),
+            (rf'[^"%^{_nl}]+|.', Name.Variable)
+        ],
+        'for': [
+            (rf'({_space})(in)({_space})(\()',
+             bygroups(using(this, state='text'), Keyword,
+                      using(this, state='text'), Punctuation), '#pop'),
+            include('follow')
+        ],
+        'for2': [
+            (r'\)', Punctuation),
+            (rf'({_space})(do{_token_terminator})',
+             bygroups(using(this, state='text'), Keyword), '#pop'),
+            (rf'[{_nl}]+', Text),
+            include('follow')
+        ],
+        'for/f': [
+            (rf'(")((?:{_variable}|[^"])*?")([{_nlws}]*)(\))',
+             bygroups(String.Double, using(this, state='string'), Text,
+                      Punctuation)),
+            (r'"', String.Double, ('#pop', 'for2', 'string')),
+            (rf"('(?:%%|{_variable}|[\w\W])*?')([{_nlws}]*)(\))",
+             bygroups(using(this, state='sqstring'), Text, Punctuation)),
+            (rf'(`(?:%%|{_variable}|[\w\W])*?`)([{_nlws}]*)(\))',
+             bygroups(using(this, state='bqstring'), Text, Punctuation)),
+            include('for2')
+        ],
+        'for/l': [
+            (r'-?\d+', Number.Integer),
+            include('for2')
+        ],
+        'if': [
+            (rf'((?:cmdextversion|errorlevel){_token_terminator})({_space})(\d+)',
+             bygroups(Keyword, using(this, state='text'),
+                      Number.Integer), '#pop'),
+            (rf'(defined{_token_terminator})({_space})({_stoken})',
+             bygroups(Keyword, using(this, state='text'),
+                      using(this, state='variable')), '#pop'),
+            (rf'(exist{_token_terminator})({_space}{_stoken})',
+             bygroups(Keyword, using(this, state='text')), '#pop'),
+            (rf'({_number}{_space})({_opword})({_space}{_number})',
+             bygroups(using(this, state='arithmetic'), Operator.Word,
+                      using(this, state='arithmetic')), '#pop'),
+            (_stoken, using(this, state='text'), ('#pop', 'if2')),
+        ],
+        'if2': [
+            (rf'({_space}?)(==)({_space}?{_stoken})',
+             bygroups(using(this, state='text'), Operator,
+                      using(this, state='text')), '#pop'),
+            (rf'({_space})({_opword})({_space}{_stoken})',
+             bygroups(using(this, state='text'), Operator.Word,
+                      using(this, state='text')), '#pop')
+        ],
+        '(?': [
+            (_space, using(this, state='text')),
+            (r'\(', Punctuation, ('#pop', 'else?', 'root/compound')),
+            default('#pop')
+        ],
+        'else?': [
+            (_space, using(this, state='text')),
+            (rf'else{_token_terminator}', Keyword, '#pop'),
+            default('#pop')
+        ]
+    }
+
+
+class MSDOSSessionLexer(ShellSessionBaseLexer):
+    """
+    Lexer for MS DOS shell sessions, i.e. command lines, including a
+    prompt, interspersed with output.
+    """
+
+    name = 'MSDOS Session'
+    aliases = ['doscon']
+    filenames = []
+    mimetypes = []
+    url = 'https://en.wikipedia.org/wiki/MS-DOS'
+    version_added = '2.1'
+    _example = "doscon/session"
+
+    _innerLexerCls = BatchLexer
+    _ps1rgx = re.compile(r'^([^>]*>)(.*\n?)')
+    _ps2 = 'More? '
+
+
+class TcshLexer(RegexLexer):
+    """
+    Lexer for tcsh scripts.
+    """
+
+    name = 'Tcsh'
+    aliases = ['tcsh', 'csh']
+    filenames = ['*.tcsh', '*.csh']
+    mimetypes = ['application/x-csh']
+    url = 'https://www.tcsh.org'
+    version_added = '0.10'
+
+    tokens = {
+        'root': [
+            include('basic'),
+            (r'\$\(', Keyword, 'paren'),
+            (r'\$\{#?', Keyword, 'curly'),
+            (r'`', String.Backtick, 'backticks'),
+            include('data'),
+        ],
+        'basic': [
+            (r'\b(if|endif|else|while|then|foreach|case|default|'
+             r'break|continue|goto|breaksw|end|switch|endsw)\s*\b',
+             Keyword),
+            (r'\b(alias|alloc|bg|bindkey|builtins|bye|caller|cd|chdir|'
+             r'complete|dirs|echo|echotc|eval|exec|exit|fg|filetest|getxvers|'
+             r'glob|getspath|hashstat|history|hup|inlib|jobs|kill|'
+             r'limit|log|login|logout|ls-F|migrate|newgrp|nice|nohup|notify|'
+             r'onintr|popd|printenv|pushd|rehash|repeat|rootnode|popd|pushd|'
+             r'set|shift|sched|setenv|setpath|settc|setty|setxvers|shift|'
+             r'source|stop|suspend|source|suspend|telltc|time|'
+             r'umask|unalias|uncomplete|unhash|universe|unlimit|unset|unsetenv|'
+             r'ver|wait|warp|watchlog|where|which)\s*\b',
+             Name.Builtin),
+            (r'#.*', Comment),
+            (r'\\[\w\W]', String.Escape),
+            (r'(\b\w+)(\s*)(=)', bygroups(Name.Variable, Text, Operator)),
+            (r'[\[\]{}()=]+', Operator),
+            (r'<<\s*(\'?)\\?(\w+)[\w\W]+?\2', String),
+            (r';', Punctuation),
+        ],
+        'data': [
+            (r'(?s)"(\\\\|\\[0-7]+|\\.|[^"\\])*"', String.Double),
+            (r"(?s)'(\\\\|\\[0-7]+|\\.|[^'\\])*'", String.Single),
+            (r'\s+', Text),
+            (r'[^=\s\[\]{}()$"\'`\\;#]+', Text),
+            (r'\d+(?= |\Z)', Number),
+            (r'\$#?(\w+|.)', Name.Variable),
+        ],
+        'curly': [
+            (r'\}', Keyword, '#pop'),
+            (r':-', Keyword),
+            (r'\w+', Name.Variable),
+            (r'[^}:"\'`$]+', Punctuation),
+            (r':', Punctuation),
+            include('root'),
+        ],
+        'paren': [
+            (r'\)', Keyword, '#pop'),
+            include('root'),
+        ],
+        'backticks': [
+            (r'`', String.Backtick, '#pop'),
+            include('root'),
+        ],
+    }
+
+
+class TcshSessionLexer(ShellSessionBaseLexer):
+    """
+    Lexer for Tcsh sessions, i.e. command lines, including a
+    prompt, interspersed with output.
+    """
+
+    name = 'Tcsh Session'
+    aliases = ['tcshcon']
+    filenames = []
+    mimetypes = []
+    url = 'https://www.tcsh.org'
+    version_added = '2.1'
+    _example = "tcshcon/session"
+
+    _innerLexerCls = TcshLexer
+    _ps1rgx = re.compile(r'^([^>]+>)(.*\n?)')
+    _ps2 = '? '
+
+
+class PowerShellLexer(RegexLexer):
+    """
+    For Windows PowerShell code.
+    """
+    name = 'PowerShell'
+    aliases = ['powershell', 'pwsh', 'posh', 'ps1', 'psm1']
+    filenames = ['*.ps1', '*.psm1']
+    mimetypes = ['text/x-powershell']
+    url = 'https://learn.microsoft.com/en-us/powershell'
+    version_added = '1.5'
+
+    flags = re.DOTALL | re.IGNORECASE | re.MULTILINE
+
+    keywords = (
+        'while validateset validaterange validatepattern validatelength '
+        'validatecount until trap switch return ref process param parameter in '
+        'if global: local: function foreach for finally filter end elseif else '
+        'dynamicparam do default continue cmdletbinding break begin alias \\? '
+        '% #script #private #local #global mandatory parametersetname position '
+        'valuefrompipeline valuefrompipelinebypropertyname '
+        'valuefromremainingarguments helpmessage try catch throw').split()
+
+    operators = (
+        'and as band bnot bor bxor casesensitive ccontains ceq cge cgt cle '
+        'clike clt cmatch cne cnotcontains cnotlike cnotmatch contains '
+        'creplace eq exact f file ge gt icontains ieq ige igt ile ilike ilt '
+        'imatch ine inotcontains inotlike inotmatch ireplace is isnot le like '
+        'lt match ne not notcontains notlike notmatch or regex replace '
+        'wildcard').split()
+
+    verbs = (
+        'write where watch wait use update unregister unpublish unprotect '
+        'unlock uninstall undo unblock trace test tee take sync switch '
+        'suspend submit stop step start split sort skip show set send select '
+        'search scroll save revoke resume restore restart resolve resize '
+        'reset request repair rename remove register redo receive read push '
+        'publish protect pop ping out optimize open new move mount merge '
+        'measure lock limit join invoke install initialize import hide group '
+        'grant get format foreach find export expand exit enter enable edit '
+        'dismount disconnect disable deny debug cxnew copy convertto '
+        'convertfrom convert connect confirm compress complete compare close '
+        'clear checkpoint block backup assert approve aggregate add').split()
+
+    aliases_ = (
+        'ac asnp cat cd cfs chdir clc clear clhy cli clp cls clv cnsn '
+        'compare copy cp cpi cpp curl cvpa dbp del diff dir dnsn ebp echo epal '
+        'epcsv epsn erase etsn exsn fc fhx fl foreach ft fw gal gbp gc gci gcm '
+        'gcs gdr ghy gi gjb gl gm gmo gp gps gpv group gsn gsnp gsv gu gv gwmi '
+        'h history icm iex ihy ii ipal ipcsv ipmo ipsn irm ise iwmi iwr kill lp '
+        'ls man md measure mi mount move mp mv nal ndr ni nmo npssc nsn nv ogv '
+        'oh popd ps pushd pwd r rbp rcjb rcsn rd rdr ren ri rjb rm rmdir rmo '
+        'rni rnp rp rsn rsnp rujb rv rvpa rwmi sajb sal saps sasv sbp sc select '
+        'set shcm si sl sleep sls sort sp spjb spps spsv start sujb sv swmi tee '
+        'trcm type wget where wjb write').split()
+
+    commenthelp = (
+        'component description example externalhelp forwardhelpcategory '
+        'forwardhelptargetname functionality inputs link '
+        'notes outputs parameter remotehelprunspace role synopsis').split()
+
+    tokens = {
+        'root': [
+            # we need to count pairs of parentheses for correct highlight
+            # of '$(...)' blocks in strings
+            (r'\(', Punctuation, 'child'),
+            (r'\s+', Text),
+            (r'^(\s*#[#\s]*)(\.(?:{}))([^\n]*$)'.format('|'.join(commenthelp)),
+             bygroups(Comment, String.Doc, Comment)),
+            (r'#[^\n]*?$', Comment),
+            (r'(<|<)#', Comment.Multiline, 'multline'),
+            (r'@"\n', String.Heredoc, 'heredoc-double'),
+            (r"@'\n.*?\n'@", String.Heredoc),
+            # escaped syntax
+            (r'`[\'"$@-]', Punctuation),
+            (r'"', String.Double, 'string'),
+            (r"'([^']|'')*'", String.Single),
+            (r'(\$|@@|@)((global|script|private|env):)?\w+',
+             Name.Variable),
+            (r'({})\b'.format('|'.join(keywords)), Keyword),
+            (r'-({})\b'.format('|'.join(operators)), Operator),
+            (r'({})-[a-z_]\w*\b'.format('|'.join(verbs)), Name.Builtin),
+            (r'({})\s'.format('|'.join(aliases_)), Name.Builtin),
+            (r'\[[a-z_\[][\w. `,\[\]]*\]', Name.Constant),  # .net [type]s
+            (r'-[a-z_]\w*', Name),
+            (r'\w+', Name),
+            (r'[.,;:@{}\[\]$()=+*/\\&%!~?^`|<>-]', Punctuation),
+        ],
+        'child': [
+            (r'\)', Punctuation, '#pop'),
+            include('root'),
+        ],
+        'multline': [
+            (r'[^#&.]+', Comment.Multiline),
+            (r'#(>|>)', Comment.Multiline, '#pop'),
+            (r'\.({})'.format('|'.join(commenthelp)), String.Doc),
+            (r'[#&.]', Comment.Multiline),
+        ],
+        'string': [
+            (r"`[0abfnrtv'\"$`]", String.Escape),
+            (r'[^$`"]+', String.Double),
+            (r'\$\(', Punctuation, 'child'),
+            (r'""', String.Double),
+            (r'[`$]', String.Double),
+            (r'"', String.Double, '#pop'),
+        ],
+        'heredoc-double': [
+            (r'\n"@', String.Heredoc, '#pop'),
+            (r'\$\(', Punctuation, 'child'),
+            (r'[^@\n]+"]', String.Heredoc),
+            (r".", String.Heredoc),
+        ]
+    }
+
+
+class PowerShellSessionLexer(ShellSessionBaseLexer):
+    """
+    Lexer for PowerShell sessions, i.e. command lines, including a
+    prompt, interspersed with output.
+    """
+
+    name = 'PowerShell Session'
+    aliases = ['pwsh-session', 'ps1con']
+    filenames = []
+    mimetypes = []
+    url = 'https://learn.microsoft.com/en-us/powershell'
+    version_added = '2.1'
+    _example = "pwsh-session/session"
+
+    _innerLexerCls = PowerShellLexer
+    _bare_continuation = True
+    _ps1rgx = re.compile(r'^((?:\[[^]]+\]: )?PS[^>]*> ?)(.*\n?)')
+    _ps2 = '> '
+
+
+class FishShellLexer(RegexLexer):
+    """
+    Lexer for Fish shell scripts.
+    """
+
+    name = 'Fish'
+    aliases = ['fish', 'fishshell']
+    filenames = ['*.fish', '*.load']
+    mimetypes = ['application/x-fish']
+    url = 'https://fishshell.com'
+    version_added = '2.1'
+
+    tokens = {
+        'root': [
+            include('basic'),
+            include('data'),
+            include('interp'),
+        ],
+        'interp': [
+            (r'\$\(\(', Keyword, 'math'),
+            (r'\(', Keyword, 'paren'),
+            (r'\$#?(\w+|.)', Name.Variable),
+        ],
+        'basic': [
+            (r'\b(begin|end|if|else|while|break|for|in|return|function|block|'
+             r'case|continue|switch|not|and|or|set|echo|exit|pwd|true|false|'
+             r'cd|count|test)(\s*)\b',
+             bygroups(Keyword, Text)),
+            (r'\b(alias|bg|bind|breakpoint|builtin|command|commandline|'
+             r'complete|contains|dirh|dirs|emit|eval|exec|fg|fish|fish_config|'
+             r'fish_indent|fish_pager|fish_prompt|fish_right_prompt|'
+             r'fish_update_completions|fishd|funced|funcsave|functions|help|'
+             r'history|isatty|jobs|math|mimedb|nextd|open|popd|prevd|psub|'
+             r'pushd|random|read|set_color|source|status|trap|type|ulimit|'
+             r'umask|vared|fc|getopts|hash|kill|printf|time|wait)\s*\b(?!\.)',
+             Name.Builtin),
+            (r'#.*\n', Comment),
+            (r'\\[\w\W]', String.Escape),
+            (r'(\b\w+)(\s*)(=)', bygroups(Name.Variable, Whitespace, Operator)),
+            (r'[\[\]()=]', Operator),
+            (r'<<-?\s*(\'?)\\?(\w+)[\w\W]+?\2', String),
+        ],
+        'data': [
+            (r'(?s)\$?"(\\\\|\\[0-7]+|\\.|[^"\\$])*"', String.Double),
+            (r'"', String.Double, 'string'),
+            (r"(?s)\$'(\\\\|\\[0-7]+|\\.|[^'\\])*'", String.Single),
+            (r"(?s)'.*?'", String.Single),
+            (r';', Punctuation),
+            (r'&|\||\^|<|>', Operator),
+            (r'\s+', Text),
+            (r'\d+(?= |\Z)', Number),
+            (r'[^=\s\[\]{}()$"\'`\\<&|;]+', Text),
+        ],
+        'string': [
+            (r'"', String.Double, '#pop'),
+            (r'(?s)(\\\\|\\[0-7]+|\\.|[^"\\$])+', String.Double),
+            include('interp'),
+        ],
+        'paren': [
+            (r'\)', Keyword, '#pop'),
+            include('root'),
+        ],
+        'math': [
+            (r'\)\)', Keyword, '#pop'),
+            (r'[-+*/%^|&]|\*\*|\|\|', Operator),
+            (r'\d+#\d+', Number),
+            (r'\d+#(?! )', Number),
+            (r'\d+', Number),
+            include('root'),
+        ],
+    }
+
+class ExeclineLexer(RegexLexer):
+    """
+    Lexer for Laurent Bercot's execline language.
+    """
+
+    name = 'execline'
+    aliases = ['execline']
+    filenames = ['*.exec']
+    url = 'https://skarnet.org/software/execline'
+    version_added = '2.7'
+
+    tokens = {
+        'root': [
+            include('basic'),
+            include('data'),
+            include('interp')
+        ],
+        'interp': [
+            (r'\$\{', String.Interpol, 'curly'),
+            (r'\$[\w@#]+', Name.Variable),  # user variable
+            (r'\$', Text),
+        ],
+        'basic': [
+            (r'\b(background|backtick|cd|define|dollarat|elgetopt|'
+             r'elgetpositionals|elglob|emptyenv|envfile|exec|execlineb|'
+             r'exit|export|fdblock|fdclose|fdmove|fdreserve|fdswap|'
+             r'forbacktickx|foreground|forstdin|forx|getcwd|getpid|heredoc|'
+             r'homeof|if|ifelse|ifte|ifthenelse|importas|loopwhilex|'
+             r'multidefine|multisubstitute|pipeline|piperw|posix-cd|'
+             r'redirfd|runblock|shift|trap|tryexec|umask|unexport|wait|'
+             r'withstdinas)\b', Name.Builtin),
+            (r'\A#!.+\n', Comment.Hashbang),
+            (r'#.*\n', Comment.Single),
+            (r'[{}]', Operator)
+        ],
+        'data': [
+            (r'(?s)"(\\.|[^"\\$])*"', String.Double),
+            (r'"', String.Double, 'string'),
+            (r'\s+', Text),
+            (r'[^\s{}$"\\]+', Text)
+        ],
+        'string': [
+            (r'"', String.Double, '#pop'),
+            (r'(?s)(\\\\|\\.|[^"\\$])+', String.Double),
+            include('interp'),
+        ],
+        'curly': [
+            (r'\}', String.Interpol, '#pop'),
+            (r'[\w#@]+', Name.Variable),
+            include('root')
+        ]
+
+    }
+
+    def analyse_text(text):
+        if shebang_matches(text, r'execlineb'):
+            return 1
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/sieve.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/sieve.py
new file mode 100644
index 0000000000000000000000000000000000000000..4bda3517e83e2ba20c57b165b237f845796d6727
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/sieve.py
@@ -0,0 +1,78 @@
+"""
+    pygments.lexers.sieve
+    ~~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for Sieve file format.
+
+    https://tools.ietf.org/html/rfc5228
+    https://tools.ietf.org/html/rfc5173
+    https://tools.ietf.org/html/rfc5229
+    https://tools.ietf.org/html/rfc5230
+    https://tools.ietf.org/html/rfc5232
+    https://tools.ietf.org/html/rfc5235
+    https://tools.ietf.org/html/rfc5429
+    https://tools.ietf.org/html/rfc8580
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, bygroups
+from pygments.token import Comment, Name, Literal, String, Text, Punctuation, \
+    Keyword
+
+__all__ = ["SieveLexer"]
+
+
+class SieveLexer(RegexLexer):
+    """
+    Lexer for sieve format.
+    """
+    name = 'Sieve'
+    filenames = ['*.siv', '*.sieve']
+    aliases = ['sieve']
+    url = 'https://en.wikipedia.org/wiki/Sieve_(mail_filtering_language)'
+    version_added = '2.6'
+
+    tokens = {
+        'root': [
+            (r'\s+', Text),
+            (r'[();,{}\[\]]', Punctuation),
+            # import:
+            (r'(?i)require',
+             Keyword.Namespace),
+            # tags:
+            (r'(?i)(:)(addresses|all|contains|content|create|copy|comparator|'
+             r'count|days|detail|domain|fcc|flags|from|handle|importance|is|'
+             r'localpart|length|lowerfirst|lower|matches|message|mime|options|'
+             r'over|percent|quotewildcard|raw|regex|specialuse|subject|text|'
+             r'under|upperfirst|upper|value)',
+             bygroups(Name.Tag, Name.Tag)),
+            # tokens:
+            (r'(?i)(address|addflag|allof|anyof|body|discard|elsif|else|envelope|'
+             r'ereject|exists|false|fileinto|if|hasflag|header|keep|'
+             r'notify_method_capability|notify|not|redirect|reject|removeflag|'
+             r'setflag|size|spamtest|stop|string|true|vacation|virustest)',
+             Name.Builtin),
+            (r'(?i)set',
+             Keyword.Declaration),
+            # number:
+            (r'([0-9.]+)([kmgKMG])?',
+             bygroups(Literal.Number, Literal.Number)),
+            # comment:
+            (r'#.*$',
+             Comment.Single),
+            (r'/\*.*\*/',
+             Comment.Multiline),
+            # string:
+            (r'"[^"]*?"',
+             String),
+            # text block:
+            (r'text:',
+             Name.Tag, 'text'),
+        ],
+        'text': [
+            (r'[^.].*?\n', String),
+            (r'^\.', Punctuation, "#pop"),
+        ]
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/slash.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/slash.py
new file mode 100644
index 0000000000000000000000000000000000000000..2bcbdf877548eb9d670ee2384aed01d2d631dc16
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/slash.py
@@ -0,0 +1,183 @@
+"""
+    pygments.lexers.slash
+    ~~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for the Slash programming language.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import ExtendedRegexLexer, bygroups, DelegatingLexer
+from pygments.token import Name, Number, String, Comment, Punctuation, \
+    Other, Keyword, Operator, Whitespace
+
+__all__ = ['SlashLexer']
+
+
+class SlashLanguageLexer(ExtendedRegexLexer):
+    _nkw = r'(?=[^a-zA-Z_0-9])'
+
+    def move_state(new_state):
+        return ("#pop", new_state)
+
+    def right_angle_bracket(lexer, match, ctx):
+        if len(ctx.stack) > 1 and ctx.stack[-2] == "string":
+            ctx.stack.pop()
+        yield match.start(), String.Interpol, '}'
+        ctx.pos = match.end()
+        pass
+
+    tokens = {
+        "root": [
+            (r"<%=",        Comment.Preproc,    move_state("slash")),
+            (r"<%!!",       Comment.Preproc,    move_state("slash")),
+            (r"<%#.*?%>",   Comment.Multiline),
+            (r"<%",         Comment.Preproc,    move_state("slash")),
+            (r".|\n",       Other),
+        ],
+        "string": [
+            (r"\\",         String.Escape,      move_state("string_e")),
+            (r"\"",         String,             move_state("slash")),
+            (r"#\{",        String.Interpol,    "slash"),
+            (r'.|\n',       String),
+        ],
+        "string_e": [
+            (r'n',                  String.Escape,      move_state("string")),
+            (r't',                  String.Escape,      move_state("string")),
+            (r'r',                  String.Escape,      move_state("string")),
+            (r'e',                  String.Escape,      move_state("string")),
+            (r'x[a-fA-F0-9]{2}',    String.Escape,      move_state("string")),
+            (r'.',                  String.Escape,      move_state("string")),
+        ],
+        "regexp": [
+            (r'}[a-z]*',            String.Regex,       move_state("slash")),
+            (r'\\(.|\n)',           String.Regex),
+            (r'{',                  String.Regex,       "regexp_r"),
+            (r'.|\n',               String.Regex),
+        ],
+        "regexp_r": [
+            (r'}[a-z]*',            String.Regex,       "#pop"),
+            (r'\\(.|\n)',           String.Regex),
+            (r'{',                  String.Regex,       "regexp_r"),
+        ],
+        "slash": [
+            (r"%>",                     Comment.Preproc,    move_state("root")),
+            (r"\"",                     String,             move_state("string")),
+            (r"'[a-zA-Z0-9_]+",         String),
+            (r'%r{',                    String.Regex,       move_state("regexp")),
+            (r'/\*.*?\*/',              Comment.Multiline),
+            (r"(#|//).*?\n",            Comment.Single),
+            (r'-?[0-9]+e[+-]?[0-9]+',   Number.Float),
+            (r'-?[0-9]+\.[0-9]+(e[+-]?[0-9]+)?', Number.Float),
+            (r'-?[0-9]+',               Number.Integer),
+            (r'nil'+_nkw,               Name.Builtin),
+            (r'true'+_nkw,              Name.Builtin),
+            (r'false'+_nkw,             Name.Builtin),
+            (r'self'+_nkw,              Name.Builtin),
+            (r'(class)(\s+)([A-Z][a-zA-Z0-9_\']*)',
+                bygroups(Keyword, Whitespace, Name.Class)),
+            (r'class'+_nkw,             Keyword),
+            (r'extends'+_nkw,           Keyword),
+            (r'(def)(\s+)(self)(\s*)(\.)(\s*)([a-z_][a-zA-Z0-9_\']*=?|<<|>>|==|<=>|<=|<|>=|>|\+|-(self)?|~(self)?|\*|/|%|^|&&|&|\||\[\]=?)',
+                bygroups(Keyword, Whitespace, Name.Builtin, Whitespace, Punctuation, Whitespace, Name.Function)),
+            (r'(def)(\s+)([a-z_][a-zA-Z0-9_\']*=?|<<|>>|==|<=>|<=|<|>=|>|\+|-(self)?|~(self)?|\*|/|%|^|&&|&|\||\[\]=?)',
+                bygroups(Keyword, Whitespace, Name.Function)),
+            (r'def'+_nkw,               Keyword),
+            (r'if'+_nkw,                Keyword),
+            (r'elsif'+_nkw,             Keyword),
+            (r'else'+_nkw,              Keyword),
+            (r'unless'+_nkw,            Keyword),
+            (r'for'+_nkw,               Keyword),
+            (r'in'+_nkw,                Keyword),
+            (r'while'+_nkw,             Keyword),
+            (r'until'+_nkw,             Keyword),
+            (r'and'+_nkw,               Keyword),
+            (r'or'+_nkw,                Keyword),
+            (r'not'+_nkw,               Keyword),
+            (r'lambda'+_nkw,            Keyword),
+            (r'try'+_nkw,               Keyword),
+            (r'catch'+_nkw,             Keyword),
+            (r'return'+_nkw,            Keyword),
+            (r'next'+_nkw,              Keyword),
+            (r'last'+_nkw,              Keyword),
+            (r'throw'+_nkw,             Keyword),
+            (r'use'+_nkw,               Keyword),
+            (r'switch'+_nkw,            Keyword),
+            (r'\\',                     Keyword),
+            (r'λ',                      Keyword),
+            (r'__FILE__'+_nkw,          Name.Builtin.Pseudo),
+            (r'__LINE__'+_nkw,          Name.Builtin.Pseudo),
+            (r'[A-Z][a-zA-Z0-9_\']*'+_nkw, Name.Constant),
+            (r'[a-z_][a-zA-Z0-9_\']*'+_nkw, Name),
+            (r'@[a-z_][a-zA-Z0-9_\']*'+_nkw, Name.Variable.Instance),
+            (r'@@[a-z_][a-zA-Z0-9_\']*'+_nkw, Name.Variable.Class),
+            (r'\(',                     Punctuation),
+            (r'\)',                     Punctuation),
+            (r'\[',                     Punctuation),
+            (r'\]',                     Punctuation),
+            (r'\{',                     Punctuation),
+            (r'\}',                     right_angle_bracket),
+            (r';',                      Punctuation),
+            (r',',                      Punctuation),
+            (r'<<=',                    Operator),
+            (r'>>=',                    Operator),
+            (r'<<',                     Operator),
+            (r'>>',                     Operator),
+            (r'==',                     Operator),
+            (r'!=',                     Operator),
+            (r'=>',                     Operator),
+            (r'=',                      Operator),
+            (r'<=>',                    Operator),
+            (r'<=',                     Operator),
+            (r'>=',                     Operator),
+            (r'<',                      Operator),
+            (r'>',                      Operator),
+            (r'\+\+',                   Operator),
+            (r'\+=',                    Operator),
+            (r'-=',                     Operator),
+            (r'\*\*=',                  Operator),
+            (r'\*=',                    Operator),
+            (r'\*\*',                   Operator),
+            (r'\*',                     Operator),
+            (r'/=',                     Operator),
+            (r'\+',                     Operator),
+            (r'-',                      Operator),
+            (r'/',                      Operator),
+            (r'%=',                     Operator),
+            (r'%',                      Operator),
+            (r'^=',                     Operator),
+            (r'&&=',                    Operator),
+            (r'&=',                     Operator),
+            (r'&&',                     Operator),
+            (r'&',                      Operator),
+            (r'\|\|=',                  Operator),
+            (r'\|=',                    Operator),
+            (r'\|\|',                   Operator),
+            (r'\|',                     Operator),
+            (r'!',                      Operator),
+            (r'\.\.\.',                 Operator),
+            (r'\.\.',                   Operator),
+            (r'\.',                     Operator),
+            (r'::',                     Operator),
+            (r':',                      Operator),
+            (r'(\s|\n)+',               Whitespace),
+            (r'[a-z_][a-zA-Z0-9_\']*',  Name.Variable),
+        ],
+    }
+
+
+class SlashLexer(DelegatingLexer):
+    """
+    Lexer for the Slash programming language.
+    """
+
+    name = 'Slash'
+    aliases = ['slash']
+    filenames = ['*.sla']
+    url = 'https://github.com/arturadib/Slash-A'
+    version_added = '2.4'
+
+    def __init__(self, **options):
+        from pygments.lexers.web import HtmlLexer
+        super().__init__(HtmlLexer, SlashLanguageLexer, **options)
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/smalltalk.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/smalltalk.py
new file mode 100644
index 0000000000000000000000000000000000000000..69e0519b77f612145f5ac56f3260bfe4ad863d97
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/smalltalk.py
@@ -0,0 +1,194 @@
+"""
+    pygments.lexers.smalltalk
+    ~~~~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for Smalltalk and related languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, include, bygroups, default
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation
+
+__all__ = ['SmalltalkLexer', 'NewspeakLexer']
+
+
+class SmalltalkLexer(RegexLexer):
+    """
+    For Smalltalk syntax.
+    Contributed by Stefan Matthias Aust.
+    Rewritten by Nils Winter.
+    """
+    name = 'Smalltalk'
+    url = 'http://www.smalltalk.org/'
+    filenames = ['*.st']
+    aliases = ['smalltalk', 'squeak', 'st']
+    mimetypes = ['text/x-smalltalk']
+    version_added = '0.10'
+
+    tokens = {
+        'root': [
+            (r'(<)(\w+:)(.*?)(>)', bygroups(Text, Keyword, Text, Text)),
+            include('squeak fileout'),
+            include('whitespaces'),
+            include('method definition'),
+            (r'(\|)([\w\s]*)(\|)', bygroups(Operator, Name.Variable, Operator)),
+            include('objects'),
+            (r'\^|\:=|\_', Operator),
+            # temporaries
+            (r'[\]({}.;!]', Text),
+        ],
+        'method definition': [
+            # Not perfect can't allow whitespaces at the beginning and the
+            # without breaking everything
+            (r'([a-zA-Z]+\w*:)(\s*)(\w+)',
+             bygroups(Name.Function, Text, Name.Variable)),
+            (r'^(\b[a-zA-Z]+\w*\b)(\s*)$', bygroups(Name.Function, Text)),
+            (r'^([-+*/\\~<>=|&!?,@%]+)(\s*)(\w+)(\s*)$',
+             bygroups(Name.Function, Text, Name.Variable, Text)),
+        ],
+        'blockvariables': [
+            include('whitespaces'),
+            (r'(:)(\s*)(\w+)',
+             bygroups(Operator, Text, Name.Variable)),
+            (r'\|', Operator, '#pop'),
+            default('#pop'),  # else pop
+        ],
+        'literals': [
+            (r"'(''|[^'])*'", String, 'afterobject'),
+            (r'\$.', String.Char, 'afterobject'),
+            (r'#\(', String.Symbol, 'parenth'),
+            (r'\)', Text, 'afterobject'),
+            (r'(\d+r)?-?\d+(\.\d+)?(e-?\d+)?', Number, 'afterobject'),
+        ],
+        '_parenth_helper': [
+            include('whitespaces'),
+            (r'(\d+r)?-?\d+(\.\d+)?(e-?\d+)?', Number),
+            (r'[-+*/\\~<>=|&#!?,@%\w:]+', String.Symbol),
+            # literals
+            (r"'(''|[^'])*'", String),
+            (r'\$.', String.Char),
+            (r'#*\(', String.Symbol, 'inner_parenth'),
+        ],
+        'parenth': [
+            # This state is a bit tricky since
+            # we can't just pop this state
+            (r'\)', String.Symbol, ('root', 'afterobject')),
+            include('_parenth_helper'),
+        ],
+        'inner_parenth': [
+            (r'\)', String.Symbol, '#pop'),
+            include('_parenth_helper'),
+        ],
+        'whitespaces': [
+            # skip whitespace and comments
+            (r'\s+', Text),
+            (r'"(""|[^"])*"', Comment),
+        ],
+        'objects': [
+            (r'\[', Text, 'blockvariables'),
+            (r'\]', Text, 'afterobject'),
+            (r'\b(self|super|true|false|nil|thisContext)\b',
+             Name.Builtin.Pseudo, 'afterobject'),
+            (r'\b[A-Z]\w*(?!:)\b', Name.Class, 'afterobject'),
+            (r'\b[a-z]\w*(?!:)\b', Name.Variable, 'afterobject'),
+            (r'#("(""|[^"])*"|[-+*/\\~<>=|&!?,@%]+|[\w:]+)',
+             String.Symbol, 'afterobject'),
+            include('literals'),
+        ],
+        'afterobject': [
+            (r'! !$', Keyword, '#pop'),  # squeak chunk delimiter
+            include('whitespaces'),
+            (r'\b(ifTrue:|ifFalse:|whileTrue:|whileFalse:|timesRepeat:)',
+             Name.Builtin, '#pop'),
+            (r'\b(new\b(?!:))', Name.Builtin),
+            (r'\:=|\_', Operator, '#pop'),
+            (r'\b[a-zA-Z]+\w*:', Name.Function, '#pop'),
+            (r'\b[a-zA-Z]+\w*', Name.Function),
+            (r'\w+:?|[-+*/\\~<>=|&!?,@%]+', Name.Function, '#pop'),
+            (r'\.', Punctuation, '#pop'),
+            (r';', Punctuation),
+            (r'[\])}]', Text),
+            (r'[\[({]', Text, '#pop'),
+        ],
+        'squeak fileout': [
+            # Squeak fileout format (optional)
+            (r'^"(""|[^"])*"!', Keyword),
+            (r"^'(''|[^'])*'!", Keyword),
+            (r'^(!)(\w+)( commentStamp: )(.*?)( prior: .*?!\n)(.*?)(!)',
+                bygroups(Keyword, Name.Class, Keyword, String, Keyword, Text, Keyword)),
+            (r"^(!)(\w+(?: class)?)( methodsFor: )('(?:''|[^'])*')(.*?!)",
+                bygroups(Keyword, Name.Class, Keyword, String, Keyword)),
+            (r'^(\w+)( subclass: )(#\w+)'
+             r'(\s+instanceVariableNames: )(.*?)'
+             r'(\s+classVariableNames: )(.*?)'
+             r'(\s+poolDictionaries: )(.*?)'
+             r'(\s+category: )(.*?)(!)',
+                bygroups(Name.Class, Keyword, String.Symbol, Keyword, String, Keyword,
+                         String, Keyword, String, Keyword, String, Keyword)),
+            (r'^(\w+(?: class)?)(\s+instanceVariableNames: )(.*?)(!)',
+                bygroups(Name.Class, Keyword, String, Keyword)),
+            (r'(!\n)(\].*)(! !)$', bygroups(Keyword, Text, Keyword)),
+            (r'! !$', Keyword),
+        ],
+    }
+
+
+class NewspeakLexer(RegexLexer):
+    """
+    For Newspeak syntax.
+    """
+    name = 'Newspeak'
+    url = 'http://newspeaklanguage.org/'
+    filenames = ['*.ns2']
+    aliases = ['newspeak', ]
+    mimetypes = ['text/x-newspeak']
+    version_added = '1.1'
+
+    tokens = {
+        'root': [
+            (r'\b(Newsqueak2)\b', Keyword.Declaration),
+            (r"'[^']*'", String),
+            (r'\b(class)(\s+)(\w+)(\s*)',
+             bygroups(Keyword.Declaration, Text, Name.Class, Text)),
+            (r'\b(mixin|self|super|private|public|protected|nil|true|false)\b',
+             Keyword),
+            (r'(\w+\:)(\s*)([a-zA-Z_]\w+)',
+             bygroups(Name.Function, Text, Name.Variable)),
+            (r'(\w+)(\s*)(=)',
+             bygroups(Name.Attribute, Text, Operator)),
+            (r'<\w+>', Comment.Special),
+            include('expressionstat'),
+            include('whitespace')
+        ],
+
+        'expressionstat': [
+            (r'(\d+\.\d*|\.\d+|\d+[fF])[fF]?', Number.Float),
+            (r'\d+', Number.Integer),
+            (r':\w+', Name.Variable),
+            (r'(\w+)(::)', bygroups(Name.Variable, Operator)),
+            (r'\w+:', Name.Function),
+            (r'\w+', Name.Variable),
+            (r'\(|\)', Punctuation),
+            (r'\[|\]', Punctuation),
+            (r'\{|\}', Punctuation),
+
+            (r'(\^|\+|\/|~|\*|<|>|=|@|%|\||&|\?|!|,|-|:)', Operator),
+            (r'\.|;', Punctuation),
+            include('whitespace'),
+            include('literals'),
+        ],
+        'literals': [
+            (r'\$.', String),
+            (r"'[^']*'", String),
+            (r"#'[^']*'", String.Symbol),
+            (r"#\w+:?", String.Symbol),
+            (r"#(\+|\/|~|\*|<|>|=|@|%|\||&|\?|!|,|-)+", String.Symbol)
+        ],
+        'whitespace': [
+            (r'\s+', Text),
+            (r'"[^"]*"', Comment)
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/smithy.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/smithy.py
new file mode 100644
index 0000000000000000000000000000000000000000..2642bb879901595f88e605364703db92de9707bd
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/smithy.py
@@ -0,0 +1,77 @@
+"""
+    pygments.lexers.smithy
+    ~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for the Smithy IDL.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, bygroups, words
+from pygments.token import Text, Comment, Keyword, Name, String, \
+    Number, Whitespace, Punctuation
+
+__all__ = ['SmithyLexer']
+
+
+class SmithyLexer(RegexLexer):
+    """
+    For Smithy IDL
+    """
+    name = 'Smithy'
+    url = 'https://awslabs.github.io/smithy/'
+    filenames = ['*.smithy']
+    aliases = ['smithy']
+    version_added = '2.10'
+
+    unquoted = r'[A-Za-z0-9_\.#$-]+'
+    identifier = r"[A-Za-z0-9_\.#$-]+"
+
+    simple_shapes = (
+        'use', 'byte', 'short', 'integer', 'long', 'float', 'document',
+        'double', 'bigInteger', 'bigDecimal', 'boolean', 'blob', 'string',
+        'timestamp',
+    )
+
+    aggregate_shapes = (
+       'apply', 'list', 'map', 'set', 'structure', 'union', 'resource',
+       'operation', 'service', 'trait'
+    )
+
+    tokens = {
+        'root': [
+            (r'///.*$', Comment.Multiline),
+            (r'//.*$', Comment),
+            (r'@[0-9a-zA-Z\.#-]*', Name.Decorator),
+            (r'(=)', Name.Decorator),
+            (r'^(\$version)(:)(.+)',
+                bygroups(Keyword.Declaration, Name.Decorator, Name.Class)),
+            (r'^(namespace)(\s+' + identifier + r')\b',
+                bygroups(Keyword.Declaration, Name.Class)),
+            (words(simple_shapes,
+                   prefix=r'^', suffix=r'(\s+' + identifier + r')\b'),
+                bygroups(Keyword.Declaration, Name.Class)),
+            (words(aggregate_shapes,
+                   prefix=r'^', suffix=r'(\s+' + identifier + r')'),
+                bygroups(Keyword.Declaration, Name.Class)),
+            (r'^(metadata)(\s+)((?:\S+)|(?:\"[^"]+\"))(\s*)(=)',
+                bygroups(Keyword.Declaration, Whitespace, Name.Class,
+                         Whitespace, Name.Decorator)),
+            (r"(true|false|null)", Keyword.Constant),
+            (r"(-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?)", Number),
+            (identifier + ":", Name.Label),
+            (identifier, Name.Variable.Class),
+            (r'\[', Text, "#push"),
+            (r'\]', Text, "#pop"),
+            (r'\(', Text, "#push"),
+            (r'\)', Text, "#pop"),
+            (r'\{', Text, "#push"),
+            (r'\}', Text, "#pop"),
+            (r'"{3}(\\\\|\n|\\")*"{3}', String.Doc),
+            (r'"(\\\\|\n|\\"|[^"])*"', String.Double),
+            (r"'(\\\\|\n|\\'|[^'])*'", String.Single),
+            (r'[:,]+', Punctuation),
+            (r'\s+', Whitespace),
+        ]
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/smv.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/smv.py
new file mode 100644
index 0000000000000000000000000000000000000000..3d06f99f60b3af912d889faba24993a9b69ea5ca
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/smv.py
@@ -0,0 +1,78 @@
+"""
+    pygments.lexers.smv
+    ~~~~~~~~~~~~~~~~~~~
+
+    Lexers for the SMV languages.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, words
+from pygments.token import Comment, Keyword, Name, Number, Operator, \
+    Punctuation, Text
+
+__all__ = ['NuSMVLexer']
+
+
+class NuSMVLexer(RegexLexer):
+    """
+    Lexer for the NuSMV language.
+    """
+
+    name = 'NuSMV'
+    aliases = ['nusmv']
+    filenames = ['*.smv']
+    mimetypes = []
+    url = 'https://nusmv.fbk.eu'
+    version_added = '2.2'
+
+    tokens = {
+        'root': [
+            # Comments
+            (r'(?s)\/\-\-.*?\-\-/', Comment),
+            (r'--.*\n', Comment),
+
+            # Reserved
+            (words(('MODULE', 'DEFINE', 'MDEFINE', 'CONSTANTS', 'VAR', 'IVAR',
+                    'FROZENVAR', 'INIT', 'TRANS', 'INVAR', 'SPEC', 'CTLSPEC',
+                    'LTLSPEC', 'PSLSPEC', 'COMPUTE', 'NAME', 'INVARSPEC',
+                    'FAIRNESS', 'JUSTICE', 'COMPASSION', 'ISA', 'ASSIGN',
+                    'CONSTRAINT', 'SIMPWFF', 'CTLWFF', 'LTLWFF', 'PSLWFF',
+                    'COMPWFF', 'IN', 'MIN', 'MAX', 'MIRROR', 'PRED',
+                    'PREDICATES'), suffix=r'(?![\w$#-])'),
+             Keyword.Declaration),
+            (r'process(?![\w$#-])', Keyword),
+            (words(('array', 'of', 'boolean', 'integer', 'real', 'word'),
+                   suffix=r'(?![\w$#-])'), Keyword.Type),
+            (words(('case', 'esac'), suffix=r'(?![\w$#-])'), Keyword),
+            (words(('word1', 'bool', 'signed', 'unsigned', 'extend', 'resize',
+                    'sizeof', 'uwconst', 'swconst', 'init', 'self', 'count',
+                    'abs', 'max', 'min'), suffix=r'(?![\w$#-])'),
+             Name.Builtin),
+            (words(('EX', 'AX', 'EF', 'AF', 'EG', 'AG', 'E', 'F', 'O', 'G',
+                    'H', 'X', 'Y', 'Z', 'A', 'U', 'S', 'V', 'T', 'BU', 'EBF',
+                    'ABF', 'EBG', 'ABG', 'next', 'mod', 'union', 'in', 'xor',
+                    'xnor'), suffix=r'(?![\w$#-])'),
+                Operator.Word),
+            (words(('TRUE', 'FALSE'), suffix=r'(?![\w$#-])'), Keyword.Constant),
+
+            # Names
+            (r'[a-zA-Z_][\w$#-]*', Name.Variable),
+
+            # Operators
+            (r':=', Operator),
+            (r'[-&|+*/<>!=]', Operator),
+
+            # Literals
+            (r'\-?\d+\b', Number.Integer),
+            (r'0[su][bB]\d*_[01_]+', Number.Bin),
+            (r'0[su][oO]\d*_[0-7_]+', Number.Oct),
+            (r'0[su][dD]\d*_[\d_]+', Number.Decimal),
+            (r'0[su][hH]\d*_[\da-fA-F_]+', Number.Hex),
+
+            # Whitespace, punctuation and the rest
+            (r'\s+', Text.Whitespace),
+            (r'[()\[\]{};?:.,]', Punctuation),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/snobol.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/snobol.py
new file mode 100644
index 0000000000000000000000000000000000000000..7016c96a5fdbaa7ed5e531a78584faf903d99841
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/snobol.py
@@ -0,0 +1,82 @@
+"""
+    pygments.lexers.snobol
+    ~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for the SNOBOL language.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, bygroups
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation
+
+__all__ = ['SnobolLexer']
+
+
+class SnobolLexer(RegexLexer):
+    """
+    Lexer for the SNOBOL4 programming language.
+
+    Recognizes the common ASCII equivalents of the original SNOBOL4 operators.
+    Does not require spaces around binary operators.
+    """
+
+    name = "Snobol"
+    aliases = ["snobol"]
+    filenames = ['*.snobol']
+    mimetypes = ['text/x-snobol']
+    url = 'https://www.regressive.org/snobol4'
+    version_added = '1.5'
+
+    tokens = {
+        # root state, start of line
+        # comments, continuation lines, and directives start in column 1
+        # as do labels
+        'root': [
+            (r'\*.*\n', Comment),
+            (r'[+.] ', Punctuation, 'statement'),
+            (r'-.*\n', Comment),
+            (r'END\s*\n', Name.Label, 'heredoc'),
+            (r'[A-Za-z$][\w$]*', Name.Label, 'statement'),
+            (r'\s+', Text, 'statement'),
+        ],
+        # statement state, line after continuation or label
+        'statement': [
+            (r'\s*\n', Text, '#pop'),
+            (r'\s+', Text),
+            (r'(?<=[^\w.])(LT|LE|EQ|NE|GE|GT|INTEGER|IDENT|DIFFER|LGT|SIZE|'
+             r'REPLACE|TRIM|DUPL|REMDR|DATE|TIME|EVAL|APPLY|OPSYN|LOAD|UNLOAD|'
+             r'LEN|SPAN|BREAK|ANY|NOTANY|TAB|RTAB|REM|POS|RPOS|FAIL|FENCE|'
+             r'ABORT|ARB|ARBNO|BAL|SUCCEED|INPUT|OUTPUT|TERMINAL)(?=[^\w.])',
+             Name.Builtin),
+            (r'[A-Za-z][\w.]*', Name),
+            # ASCII equivalents of original operators
+            # | for the EBCDIC equivalent, ! likewise
+            # \ for EBCDIC negation
+            (r'\*\*|[?$.!%*/#+\-@|&\\=]', Operator),
+            (r'"[^"]*"', String),
+            (r"'[^']*'", String),
+            # Accept SPITBOL syntax for real numbers
+            # as well as Macro SNOBOL4
+            (r'[0-9]+(?=[^.EeDd])', Number.Integer),
+            (r'[0-9]+(\.[0-9]*)?([EDed][-+]?[0-9]+)?', Number.Float),
+            # Goto
+            (r':', Punctuation, 'goto'),
+            (r'[()<>,;]', Punctuation),
+        ],
+        # Goto block
+        'goto': [
+            (r'\s*\n', Text, "#pop:2"),
+            (r'\s+', Text),
+            (r'F|S', Keyword),
+            (r'(\()([A-Za-z][\w.]*)(\))',
+             bygroups(Punctuation, Name.Label, Punctuation))
+        ],
+        # everything after the END statement is basically one
+        # big heredoc.
+        'heredoc': [
+            (r'.*\n', String.Heredoc)
+        ]
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/solidity.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/solidity.py
new file mode 100644
index 0000000000000000000000000000000000000000..3f2d1dd0ac19bd5d9eb90939da249d4505286803
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/solidity.py
@@ -0,0 +1,87 @@
+"""
+    pygments.lexers.solidity
+    ~~~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for Solidity.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, bygroups, include, words
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation, Whitespace
+
+__all__ = ['SolidityLexer']
+
+
+class SolidityLexer(RegexLexer):
+    """
+    For Solidity source code.
+    """
+
+    name = 'Solidity'
+    aliases = ['solidity']
+    filenames = ['*.sol']
+    mimetypes = []
+    url = 'https://soliditylang.org'
+    version_added = '2.5'
+
+    datatype = (
+        r'\b(address|bool|(?:(?:bytes|hash|int|string|uint)(?:8|16|24|32|40|48|56|64'
+        r'|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208'
+        r'|216|224|232|240|248|256)?))\b'
+    )
+
+    tokens = {
+        'root': [
+            include('whitespace'),
+            include('comments'),
+            (r'\bpragma\s+solidity\b', Keyword, 'pragma'),
+            (r'\b(contract)(\s+)([a-zA-Z_]\w*)',
+             bygroups(Keyword, Whitespace, Name.Entity)),
+            (datatype + r'(\s+)((?:external|public|internal|private)\s+)?' +
+             r'([a-zA-Z_]\w*)',
+             bygroups(Keyword.Type, Whitespace, Keyword, Name.Variable)),
+            (r'\b(enum|event|function|struct)(\s+)([a-zA-Z_]\w*)',
+             bygroups(Keyword.Type, Whitespace, Name.Variable)),
+            (r'\b(msg|block|tx)\.([A-Za-z_][a-zA-Z0-9_]*)\b', Keyword),
+            (words((
+                'block', 'break', 'constant', 'constructor', 'continue',
+                'contract', 'do', 'else', 'external', 'false', 'for',
+                'function', 'if', 'import', 'inherited', 'internal', 'is',
+                'library', 'mapping', 'memory', 'modifier', 'msg', 'new',
+                'payable', 'private', 'public', 'require', 'return',
+                'returns', 'struct', 'suicide', 'throw', 'this', 'true',
+                'tx', 'var', 'while'), prefix=r'\b', suffix=r'\b'),
+             Keyword.Type),
+            (words(('keccak256',), prefix=r'\b', suffix=r'\b'), Name.Builtin),
+            (datatype, Keyword.Type),
+            include('constants'),
+            (r'[a-zA-Z_]\w*', Text),
+            (r'[~!%^&*+=|?:<>/-]', Operator),
+            (r'[.;{}(),\[\]]', Punctuation)
+        ],
+        'comments': [
+            (r'//(\n|[\w\W]*?[^\\]\n)', Comment.Single),
+            (r'/(\\\n)?[*][\w\W]*?[*](\\\n)?/', Comment.Multiline),
+            (r'/(\\\n)?[*][\w\W]*', Comment.Multiline)
+        ],
+        'constants': [
+            (r'("(\\"|.)*?")', String.Double),
+            (r"('(\\'|.)*?')", String.Single),
+            (r'\b0[xX][0-9a-fA-F]+\b', Number.Hex),
+            (r'\b\d+\b', Number.Decimal),
+        ],
+        'pragma': [
+            include('whitespace'),
+            include('comments'),
+            (r'(\^|>=|<)(\s*)(\d+\.\d+\.\d+)',
+             bygroups(Operator, Whitespace, Keyword)),
+            (r';', Punctuation, '#pop')
+        ],
+        'whitespace': [
+            (r'\s+', Whitespace),
+            (r'\n', Whitespace)
+        ]
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/soong.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/soong.py
new file mode 100644
index 0000000000000000000000000000000000000000..0d7f12ccd592e71b6a866089a35fd2582c82f3d6
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/soong.py
@@ -0,0 +1,78 @@
+"""
+    pygments.lexers.soong
+    ~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for Soong (Android.bp Blueprint) files.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, bygroups, include
+from pygments.token import Comment, Name, Number, Operator, Punctuation, \
+        String, Whitespace
+
+__all__ = ['SoongLexer']
+
+class SoongLexer(RegexLexer):
+    name = 'Soong'
+    version_added = '2.18'
+    url = 'https://source.android.com/docs/setup/reference/androidbp'
+    aliases = ['androidbp', 'bp', 'soong']
+    filenames = ['Android.bp']
+
+    tokens = {
+        'root': [
+            # A variable assignment
+            (r'(\w*)(\s*)(\+?=)(\s*)',
+             bygroups(Name.Variable, Whitespace, Operator, Whitespace),
+             'assign-rhs'),
+
+            # A top-level module
+            (r'(\w*)(\s*)(\{)',
+             bygroups(Name.Function, Whitespace, Punctuation),
+             'in-rule'),
+
+            # Everything else
+            include('comments'),
+            (r'\s+', Whitespace),  # newlines okay
+        ],
+        'assign-rhs': [
+            include('expr'),
+            (r'\n', Whitespace, '#pop'),
+        ],
+        'in-list': [
+            include('expr'),
+            include('comments'),
+            (r'\s+', Whitespace),  # newlines okay in a list
+            (r',', Punctuation),
+            (r'\]', Punctuation, '#pop'),
+        ],
+        'in-map': [
+            # A map key
+            (r'(\w+)(:)(\s*)', bygroups(Name, Punctuation, Whitespace)),
+
+            include('expr'),
+            include('comments'),
+            (r'\s+', Whitespace),  # newlines okay in a map
+            (r',', Punctuation),
+            (r'\}', Punctuation, '#pop'),
+        ],
+        'in-rule': [
+            # Just re-use map syntax
+            include('in-map'),
+        ],
+        'comments': [
+            (r'//.*', Comment.Single),
+            (r'/(\\\n)?[*](.|\n)*?[*](\\\n)?/', Comment.Multiline),
+        ],
+        'expr': [
+            (r'(true|false)\b', Name.Builtin),
+            (r'0x[0-9a-fA-F]+', Number.Hex),
+            (r'\d+', Number.Integer),
+            (r'".*?"', String),
+            (r'\{', Punctuation, 'in-map'),
+            (r'\[', Punctuation, 'in-list'),
+            (r'\w+', Name),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/sophia.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/sophia.py
new file mode 100644
index 0000000000000000000000000000000000000000..86435f3fe7e482cd069f2cdae33fe32a69f08434
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/sophia.py
@@ -0,0 +1,102 @@
+"""
+    pygments.lexers.sophia
+    ~~~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for Sophia.
+
+    Derived from pygments/lexers/reason.py.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, include, default, words
+from pygments.token import Comment, Keyword, Name, Number, Operator, \
+    Punctuation, String, Text
+
+__all__ = ['SophiaLexer']
+
+class SophiaLexer(RegexLexer):
+    """
+    A Sophia lexer.
+    """
+
+    name = 'Sophia'
+    aliases = ['sophia']
+    filenames = ['*.aes']
+    mimetypes = []
+    url = 'https://docs.aeternity.com/aesophia'
+    version_added = '2.11'
+
+    keywords = (
+        'contract', 'include', 'let', 'switch', 'type', 'record', 'datatype',
+        'if', 'elif', 'else', 'function', 'stateful', 'payable', 'public',
+        'entrypoint', 'private', 'indexed', 'namespace', 'interface', 'main',
+        'using', 'as', 'for', 'hiding',
+    )
+
+    builtins = ('state', 'put', 'abort', 'require')
+
+    word_operators = ('mod', 'band', 'bor', 'bxor', 'bnot')
+
+    primitive_types = ('int', 'address', 'bool', 'bits', 'bytes', 'string',
+                       'list', 'option', 'char', 'unit', 'map', 'event',
+                       'hash', 'signature', 'oracle', 'oracle_query')
+
+    tokens = {
+        'escape-sequence': [
+            (r'\\[\\"\'ntbr]', String.Escape),
+            (r'\\[0-9]{3}', String.Escape),
+            (r'\\x[0-9a-fA-F]{2}', String.Escape),
+        ],
+        'root': [
+            (r'\s+', Text.Whitespace),
+            (r'(true|false)\b', Keyword.Constant),
+            (r'\b([A-Z][\w\']*)(?=\s*\.)', Name.Class, 'dotted'),
+            (r'\b([A-Z][\w\']*)', Name.Function),
+            (r'//.*?\n', Comment.Single),
+            (r'\/\*(?!/)', Comment.Multiline, 'comment'),
+
+            (r'0[xX][\da-fA-F][\da-fA-F_]*', Number.Hex),
+            (r'#[\da-fA-F][\da-fA-F_]*', Name.Label),
+            (r'\d[\d_]*', Number.Integer),
+
+            (words(keywords, suffix=r'\b'), Keyword),
+            (words(builtins, suffix=r'\b'), Name.Builtin),
+            (words(word_operators, prefix=r'\b', suffix=r'\b'), Operator.Word),
+            (words(primitive_types, prefix=r'\b', suffix=r'\b'), Keyword.Type),
+
+            (r'[=!<>+\\*/:&|?~@^-]', Operator.Word),
+            (r'[.;:{}(),\[\]]', Punctuation),
+
+            (r"(ak_|ok_|oq_|ct_)[\w']*", Name.Label),
+            (r"[^\W\d][\w']*", Name),
+
+            (r"'(?:(\\[\\\"'ntbr ])|(\\[0-9]{3})|(\\x[0-9a-fA-F]{2}))'",
+             String.Char),
+            (r"'.'", String.Char),
+            (r"'[a-z][\w]*", Name.Variable),
+
+            (r'"', String.Double, 'string')
+        ],
+        'comment': [
+            (r'[^/*]+', Comment.Multiline),
+            (r'\/\*', Comment.Multiline, '#push'),
+            (r'\*\/', Comment.Multiline, '#pop'),
+            (r'\*', Comment.Multiline),
+        ],
+        'string': [
+            (r'[^\\"]+', String.Double),
+            include('escape-sequence'),
+            (r'\\\n', String.Double),
+            (r'"', String.Double, '#pop'),
+        ],
+        'dotted': [
+            (r'\s+', Text),
+            (r'\.', Punctuation),
+            (r'[A-Z][\w\']*(?=\s*\.)', Name.Function),
+            (r'[A-Z][\w\']*', Name.Function, '#pop'),
+            (r'[a-z_][\w\']*', Name, '#pop'),
+            default('#pop'),
+        ],
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/special.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/special.py
new file mode 100644
index 0000000000000000000000000000000000000000..ea345226fc7beca9290514d90dfef58bc8512a3a
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/special.py
@@ -0,0 +1,122 @@
+"""
+    pygments.lexers.special
+    ~~~~~~~~~~~~~~~~~~~~~~~
+
+    Special lexers.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+import ast
+
+from pygments.lexer import Lexer, line_re
+from pygments.token import Token, Error, Text, Generic
+from pygments.util import get_choice_opt
+
+
+__all__ = ['TextLexer', 'OutputLexer', 'RawTokenLexer']
+
+
+class TextLexer(Lexer):
+    """
+    "Null" lexer, doesn't highlight anything.
+    """
+    name = 'Text only'
+    aliases = ['text']
+    filenames = ['*.txt']
+    mimetypes = ['text/plain']
+    url = ""
+    version_added = ''
+
+    priority = 0.01
+
+    def get_tokens_unprocessed(self, text):
+        yield 0, Text, text
+
+    def analyse_text(text):
+        return TextLexer.priority
+
+
+class OutputLexer(Lexer):
+    """
+    Simple lexer that highlights everything as ``Token.Generic.Output``.
+    """
+    name = 'Text output'
+    aliases = ['output']
+    url = ""
+    version_added = '2.10'
+    _example = "output/output"
+
+    def get_tokens_unprocessed(self, text):
+        yield 0, Generic.Output, text
+
+
+_ttype_cache = {}
+
+
+class RawTokenLexer(Lexer):
+    """
+    Recreate a token stream formatted with the `RawTokenFormatter`.
+
+    Additional options accepted:
+
+    `compress`
+        If set to ``"gz"`` or ``"bz2"``, decompress the token stream with
+        the given compression algorithm before lexing (default: ``""``).
+    """
+    name = 'Raw token data'
+    aliases = []
+    filenames = []
+    mimetypes = ['application/x-pygments-tokens']
+    url = 'https://pygments.org/docs/formatters/#RawTokenFormatter'
+    version_added = ''
+
+    def __init__(self, **options):
+        self.compress = get_choice_opt(options, 'compress',
+                                       ['', 'none', 'gz', 'bz2'], '')
+        Lexer.__init__(self, **options)
+
+    def get_tokens(self, text):
+        if self.compress:
+            if isinstance(text, str):
+                text = text.encode('latin1')
+            try:
+                if self.compress == 'gz':
+                    import gzip
+                    text = gzip.decompress(text)
+                elif self.compress == 'bz2':
+                    import bz2
+                    text = bz2.decompress(text)
+            except OSError:
+                yield Error, text.decode('latin1')
+        if isinstance(text, bytes):
+            text = text.decode('latin1')
+
+        # do not call Lexer.get_tokens() because stripping is not optional.
+        text = text.strip('\n') + '\n'
+        for i, t, v in self.get_tokens_unprocessed(text):
+            yield t, v
+
+    def get_tokens_unprocessed(self, text):
+        length = 0
+        for match in line_re.finditer(text):
+            try:
+                ttypestr, val = match.group().rstrip().split('\t', 1)
+                ttype = _ttype_cache.get(ttypestr)
+                if not ttype:
+                    ttype = Token
+                    ttypes = ttypestr.split('.')[1:]
+                    for ttype_ in ttypes:
+                        if not ttype_ or not ttype_[0].isupper():
+                            raise ValueError('malformed token name')
+                        ttype = getattr(ttype, ttype_)
+                    _ttype_cache[ttypestr] = ttype
+                val = ast.literal_eval(val)
+                if not isinstance(val, str):
+                    raise ValueError('expected str')
+            except (SyntaxError, ValueError):
+                val = match.group()
+                ttype = Error
+            yield length, ttype, val
+            length += len(val)
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/spice.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/spice.py
new file mode 100644
index 0000000000000000000000000000000000000000..978f0a71fd2957c88060b51bb3bef863cff5769d
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/spice.py
@@ -0,0 +1,70 @@
+"""
+    pygments.lexers.spice
+    ~~~~~~~~~~~~~~~~~~~~~
+
+    Lexers for the Spice programming language.
+
+    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, bygroups, words
+from pygments.token import Text, Comment, Operator, Keyword, Name, String, \
+    Number, Punctuation, Whitespace
+
+__all__ = ['SpiceLexer']
+
+
+class SpiceLexer(RegexLexer):
+    """
+    For Spice source.
+    """
+    name = 'Spice'
+    url = 'https://www.spicelang.com'
+    filenames = ['*.spice']
+    aliases = ['spice', 'spicelang']
+    mimetypes = ['text/x-spice']
+    version_added = '2.11'
+
+    tokens = {
+        'root': [
+            (r'\n', Whitespace),
+            (r'\s+', Whitespace),
+            (r'\\\n', Text),
+            # comments
+            (r'//(.*?)\n', Comment.Single),
+            (r'/(\\\n)?[*]{2}(.|\n)*?[*](\\\n)?/', String.Doc),
+            (r'/(\\\n)?[*](.|\n)*?[*](\\\n)?/', Comment.Multiline),
+            # keywords
+            (r'(import|as)\b', Keyword.Namespace),
+            (r'(f|p|type|struct|interface|enum|alias|operator)\b', Keyword.Declaration),
+            (words(('if', 'else', 'switch', 'case', 'default', 'for', 'foreach', 'do',
+                    'while', 'break', 'continue', 'fallthrough', 'return', 'assert',
+                    'unsafe', 'ext', 'cast'), suffix=r'\b'), Keyword),
+            (words(('const', 'signed', 'unsigned', 'inline', 'public', 'heap', 'compose'),
+                   suffix=r'\b'), Keyword.Pseudo),
+            (words(('new', 'yield', 'stash', 'pick', 'sync', 'class'), suffix=r'\b'),
+                   Keyword.Reserved),
+            (r'(true|false|nil)\b', Keyword.Constant),
+            (words(('double', 'int', 'short', 'long', 'byte', 'char', 'string',
+                    'bool', 'dyn'), suffix=r'\b'), Keyword.Type),
+            (words(('printf', 'sizeof', 'alignof', 'len', 'panic'), suffix=r'\b(\()'),
+             bygroups(Name.Builtin, Punctuation)),
+            # numeric literals
+            (r'[-]?[0-9]*[.][0-9]+([eE][+-]?[0-9]+)?', Number.Double),
+            (r'0[bB][01]+[slu]?', Number.Bin),
+            (r'0[oO][0-7]+[slu]?', Number.Oct),
+            (r'0[xXhH][0-9a-fA-F]+[slu]?', Number.Hex),
+            (r'(0[dD])?[0-9]+[slu]?', Number.Integer),
+            # string literal
+            (r'"(\\\\|\\[^\\]|[^"\\])*"', String),
+            # char literal
+            (r'\'(\\\\|\\[^\\]|[^\'\\])\'', String.Char),
+            # tokens
+            (r'<<=|>>=|<<|>>|<=|>=|\+=|-=|\*=|/=|\%=|\|=|&=|\^=|&&|\|\||&|\||'
+             r'\+\+|--|\%|\^|\~|==|!=|->|::|[.]{3}|#!|#|[+\-*/&]', Operator),
+            (r'[|<>=!()\[\]{}.,;:\?]', Punctuation),
+            # identifiers
+            (r'[^\W\d]\w*', Name.Other),
+        ]
+    }
diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/sql.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/sql.py
new file mode 100644
index 0000000000000000000000000000000000000000..1d3458e9aefd10bb0ef89ea81f6c006e3f690ec3
--- /dev/null
+++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pygments-2.20.0-pyhd8ed1ab_0/site-packages/pygments/lexers/sql.py
@@ -0,0 +1,1111 @@
+"""
+    pygments.lexers.sql
+    ~~~~~~~~~~~~~~~~~~~
+
+    Lexers for various SQL dialects and related interactive sessions.
+
+    Postgres specific lexers:
+
+    `PostgresLexer`
+        A SQL lexer for the PostgreSQL dialect. Differences w.r.t. the SQL
+        lexer are:
+
+        - keywords and data types list parsed from the PG docs (run the
+          `_postgres_builtins` module to update them);
+        - Content of $-strings parsed using a specific lexer, e.g. the content
+          of a PL/Python function is parsed using the Python lexer;
+        - parse PG specific constructs: E-strings, $-strings, U&-strings,
+          different operators and punctuation.
+
+    `PlPgsqlLexer`
+        A lexer for the PL/pgSQL language. Adds a few specific construct on
+        top of the PG SQL lexer (such as <

(critic del close)(critic ins close)

` etc.""" + content = None + key = m.group('key') + if key is not None: + content = self.critic_stash.get(key) + return content + + def block_edit(self, m): + """Handle block edits.""" + + if 'break' in m.group(4).split(' '): + return m.group(0) + else: + return m.group(1) + m.group(2) + m.group(4) + ' block' + m.group(5) + + def restore(self, m): + """Replace placeholders with actual critic tags.""" + + content = None + if m.group('block_keys') is not None: + content = RE_CRITIC_SUB_PLACEHOLDER.sub( + self.subrestore, m.group('block_keys') + ) + if content is not None: + content = RE_CRITIC_BLOCK.sub(self.block_edit, content) + else: + text = self.critic_stash.get(m.group('key')) + if text is not None: + content = text + return content if content is not None else m.group(0) + + def run(self, text): + """Replace critic placeholders.""" + + text = RE_CRITIC_PLACEHOLDER.sub(self.restore, text) + + return text + + +class CriticViewPreprocessor(Preprocessor): + """Handle viewing critic marks in Markdown content.""" + + def __init__(self, critic_stash): + """Initialize.""" + + super().__init__() + self.critic_stash = critic_stash + + def _ins(self, text): + """Handle critic inserts.""" + + if RE_BLOCK_SEP.match(text): + return '\n\n%s\n\n' % self.critic_stash.store(' ') + return ( + self.critic_stash.store('') + + text + + self.critic_stash.store('') + ) + + def _del(self, text): + """Handle critic deletes.""" + + if RE_BLOCK_SEP.match(text): + return self.critic_stash.store(' ') + return ( + self.critic_stash.store('') + + text + + self.critic_stash.store('') + ) + + def _mark(self, text): + """Handle critic marks.""" + + return ( + self.critic_stash.store('') + + text + + self.critic_stash.store('') + ) + + def _comment(self, text): + """Handle critic comments.""" + + return ( + self.critic_stash.store( + '' + + self.html_escape(text, strip_nl=True) + + '' + ) + ) + + def critic_view(self, m): + """Insert appropriate HTML to tags to visualize Critic marks.""" + + if m.group('ins_open'): + return self._ins(m.group('ins_text')) + elif m.group('del_open'): + return self._del(m.group('del_text')) + elif m.group('sub_open'): + return ( + self._del(m.group('sub_del_text')) + + self._ins(m.group('sub_ins_text')) + ) + elif m.group('mark_open'): + return self._mark(m.group('mark_text')) + elif m.group('com_open'): + return self._comment(m.group('com_text')) + + def critic_parse(self, m): + """ + Normal critic parser. + + Either removes accepted or rejected critic marks and replaces with the opposite. + Comments are removed and marks are replaced with their content. + """ + accept = self.config["mode"] == 'accept' + if m.group('ins_open'): + return m.group('ins_text') if accept else '' + elif m.group('del_open'): + return '' if accept else m.group('del_text') + elif m.group('mark_open'): + return m.group('mark_text') + elif m.group('com_open'): + return '' + elif m.group('sub_open'): + return m.group('sub_ins_text') if accept else m.group('sub_del_text') + + def html_escape(self, txt, strip_nl=False): + """Basic html escaping.""" + + txt = txt.replace('&', '&') + txt = txt.replace('<', '<') + txt = txt.replace('>', '>') + txt = txt.replace('"', '"') + txt = txt.replace("\n", "
" if not strip_nl else ' ') + return txt + + def run(self, lines): + """Process critic marks.""" + + # Determine processor type to use + if self.config['mode'] == "view": + processor = self.critic_view + else: + processor = self.critic_parse + + # Find and process critic marks + text = RE_CRITIC.sub(processor, '\n'.join(lines)) + + return text.split('\n') + + +class CriticExtension(Extension): + """Critic extension.""" + + def __init__(self, *args, **kwargs): + """Initialize.""" + + self.config = { + 'mode': [ + 'view', + "Critic mode to run in: 'view', 'accept', or 'reject' - Default: view " + ], + 'raw_view': [False, "Raw view keeps the output as the raw markup for view mode - Default False"] + } + + super().__init__(*args, **kwargs) + + def extendMarkdown(self, md): + """Register the extension.""" + + md.registerExtension(self) + self.critic_stash = CriticStash(CRITIC_KEY) + post = CriticsPostprocessor(self.critic_stash) + critic = CriticViewPreprocessor(self.critic_stash) + critic.config = self.getConfigs() + md.preprocessors.register(critic, "critic", 31.1) + md.postprocessors.register(post, "critic-post", 25) + md.registerExtensions(["pymdownx._bypassnorm"], {}) + + def reset(self): + """Clear stash.""" + + self.critic_stash.clear() + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return CriticExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/details.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/details.py new file mode 100644 index 0000000000000000000000000000000000000000..9694211aa623d7c53dfff61f2cdaace8d5ac3e6d --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/details.py @@ -0,0 +1,189 @@ +""" +Details. + +pymdownx.details + +MIT license. + +Copyright (c) 2017 Isaac Muse + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, +and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +""" +from markdown import Extension +from markdown.blockprocessors import BlockProcessor +import xml.etree.ElementTree as etree +import re + + +class DetailsProcessor(BlockProcessor): + """Details block processor.""" + + START = re.compile( + r'(?:^|\n)\?{3}(\+)? ?(?:([\w\-]+(?: +[\w\-]+)*?)?(?: +"(.*?)")|([\w\-]+(?: +[\w\-]+)*?)) *(?:\n|$)' + ) + COMPRESS_SPACES = re.compile(r' {2,}') + + def __init__(self, parser): + """Initialization.""" + + super().__init__(parser) + + self.current_sibling = None + self.content_indention = 0 + + def detab_by_length(self, text, length): + """Remove a tab from the front of each line of the given text.""" + + newtext = [] + lines = text.split('\n') + for line in lines: + if line.startswith(' ' * length): + newtext.append(line[length:]) + elif not line.strip(): + newtext.append('') # pragma: no cover + else: + break + return '\n'.join(newtext), '\n'.join(lines[len(newtext):]) + + def parse_content(self, parent, block): + """ + Get sibling details. + + Retrieve the appropriate sibling element. This can get tricky when + dealing with lists. + + """ + + old_block = block + non_details = '' + + # We already acquired the block via test + if self.current_sibling is not None: + sibling = self.current_sibling + block, non_details = self.detab_by_length(block, self.content_indent) + self.current_sibling = None + self.content_indent = 0 + return sibling, block, non_details + + sibling = self.lastChild(parent) + + if sibling is None or sibling.tag.lower() != 'details': + sibling = None + else: + # If the last child is a list and the content is indented sufficient + # to be under it, then the content's is sibling is in the list. + last_child = self.lastChild(sibling) + indent = 0 + while last_child is not None: + if ( + sibling is not None and block.startswith(' ' * self.tab_length * 2) and + last_child is not None and last_child.tag in ('ul', 'ol', 'dl') + ): + + # The expectation is that we'll find an `
  • `. + # We should get it's last child as well. + sibling = self.lastChild(last_child) + last_child = self.lastChild(sibling) if sibling is not None else None + + # Context has been lost at this point, so we must adjust the + # text's indentation level so it will be evaluated correctly + # under the list. + block = block[self.tab_length:] + indent += self.tab_length + else: + last_child = None + + if not block.startswith(' ' * self.tab_length): + sibling = None + + if sibling is not None: + indent += self.tab_length + block, non_details = self.detab_by_length(old_block, indent) + self.current_sibling = sibling + self.content_indent = indent + + return sibling, block, non_details + + def test(self, parent, block): + """Test block.""" + + if self.START.search(block): + return True + else: + return self.parse_content(parent, block)[0] is not None + + def run(self, parent, blocks): + """Convert to details/summary block.""" + + block = blocks.pop(0) + m = self.START.search(block) + + if m: + # remove the first line + if m.start() > 0: + self.parser.parseBlocks(parent, [block[:m.start()]]) + block = block[m.end():] + block, non_details = self.detab(block) + else: + sibling, block, non_details = self.parse_content(parent, block) + + if m: + state = m.group(1) + is_open = state is not None + + if m.group(4): + class_name = self.COMPRESS_SPACES.sub(' ', m.group(4).lower()) + title = class_name.split(' ')[0].capitalize() + else: + classes = m.group(2) + class_name = '' if classes is None else self.COMPRESS_SPACES.sub(' ', classes.lower()) + title = m.group(3) + + div = etree.SubElement(parent, 'details', ({'open': 'open'} if is_open else {})) + if class_name: + div.set('class', class_name) + summary = etree.SubElement(div, 'summary') + summary.text = title + else: + # Sibling is a list item, but we need to wrap it's content should be wrapped in

    + if sibling.tag in ('li', 'dd') and sibling.text: + text = sibling.text + sibling.text = '' + p = etree.SubElement(sibling, 'p') + p.text = text + + div = sibling + + self.parser.parseChunk(div, block) + + if non_details: + # Insert the non-details content back into blocks + blocks.insert(0, non_details) + + +class DetailsExtension(Extension): + """Add Details extension.""" + + def extendMarkdown(self, md): + """Add Details to Markdown instance.""" + md.registerExtension(self) + + md.parser.blockprocessors.register(DetailsProcessor(md.parser), "details", 105) + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return DetailsExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/emoji.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/emoji.py new file mode 100644 index 0000000000000000000000000000000000000000..d6180ee5c775b296745733fae2aab7d9d994e386 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/emoji.py @@ -0,0 +1,441 @@ +""" +Emoji. + +pymdownx.emoji +Emoji extension for EmojiOne's, GitHub's, or Twemoji's gemoji. + +MIT license. + +Copyright (c) 2016 - 2017 Isaac Muse + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, +and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +""" +from markdown import Extension +from markdown.inlinepatterns import InlineProcessor +from markdown.postprocessors import Postprocessor +from markdown import util as md_util +import xml.etree.ElementTree as etree +import inspect +import copy +from . import util + +RE_EMOJI = r'(:[+\-\w]+:)' +SUPPORTED_INDEXES = ('emojione', 'gemoji', 'twemoji') +UNICODE_VARIATION_SELECTOR_16 = 'fe0f' +EMOJIONE_SVG_CDN = 'https://cdnjs.cloudflare.com/ajax/libs/emojione/2.2.7/assets/svg/' +EMOJIONE_PNG_CDN = 'https://cdnjs.cloudflare.com/ajax/libs/emojione/2.2.7/assets/png/' +TWEMOJI_SVG_CDN = 'https://cdn.jsdelivr.net/gh/jdecked/twemoji@16.0.1/assets/svg/' +TWEMOJI_PNG_CDN = 'https://cdn.jsdelivr.net/gh/jdecked/twemoji@16.0.1/assets/72x72/' +GITHUB_UNICODE_CDN = 'https://github.githubassets.com/images/icons/emoji/unicode/' +GITHUB_CDN = 'https://github.githubassets.com/images/icons/emoji/' +NO_TITLE = 'none' +LONG_TITLE = 'long' +SHORT_TITLE = 'short' +VALID_TITLE = (LONG_TITLE, SHORT_TITLE, NO_TITLE) +UNICODE_ENTITY = 'html_entity' +UNICODE_ALT = ('unicode', UNICODE_ENTITY) +LEGACY_ARG_COUNT = 8 + +MSG_INDEX_WARN = """Using emoji indexes with no arguments is now deprecated. +Emoji indexes now take 2 arguments: 'options' and 'md'. +Please update your custom index accordingly. +""" + +MSG_BAD_EMOJI = """ +Emoji Extension (strict mode): The following emoji were detected and either had +their name change, were removed, or have never existed. + +{} +""" + + +def add_attributes(options, attributes): + """Add additional attributes from options.""" + + attr = options.get('attributes', {}) + if attr: + for k, v in attr.items(): + attributes[k] = v + + +# Exists for backwards compatibility as this function +# was initially spelled incorrectly. +add_attriubtes = add_attributes + + +def emojione(options, md): + """The EmojiOne index.""" + + from . import emoji1_db as emoji_map + return { + "name": emoji_map.name, + "emoji": copy.deepcopy(emoji_map.emoji), + "aliases": copy.deepcopy(emoji_map.aliases) + } + + +def gemoji(options, md): + """The Gemoji index.""" + + from . import gemoji_db as emoji_map + return { + "name": emoji_map.name, + "emoji": copy.deepcopy(emoji_map.emoji), + "aliases": copy.deepcopy(emoji_map.aliases) + } + + +def twemoji(options, md): + """The Twemoji index.""" + + from . import twemoji_db as emoji_map + return { + "name": emoji_map.name, + "emoji": copy.deepcopy(emoji_map.emoji), + "aliases": copy.deepcopy(emoji_map.aliases) + } + + +################### +# Converters +################### +def to_png(index, shortname, alias, uc, alt, title, category, options, md): + """Return PNG element.""" + + if index == 'gemoji': + def_image_path = GITHUB_UNICODE_CDN + def_non_std_image_path = GITHUB_CDN + elif index == 'twemoji': + def_image_path = TWEMOJI_PNG_CDN + def_non_std_image_path = TWEMOJI_PNG_CDN + else: + def_image_path = EMOJIONE_PNG_CDN + def_non_std_image_path = EMOJIONE_PNG_CDN + + is_unicode = uc is not None + classes = options.get('classes', index) + + # In general we can use the alias, but github specific images don't have one for each alias. + # We can tell we have a github specific if there is no Unicode value. + if is_unicode: + image_path = options.get('image_path', def_image_path) + else: # pragma: no cover + image_path = options.get('non_standard_image_path', def_non_std_image_path) + + src = "{}{}.png".format( + image_path, + uc if is_unicode else shortname[1:-1] + ) + + attributes = { + "class": classes, + "alt": alt, + "src": src + } + + if title: + attributes['title'] = title + + add_attributes(options, attributes) + + return etree.Element("img", attributes) + + +def to_svg(index, shortname, alias, uc, alt, title, category, options, md): + """Return SVG element.""" + + if index == 'twemoji': + svg_path = TWEMOJI_SVG_CDN + else: + svg_path = EMOJIONE_SVG_CDN + + attributes = { + "class": options.get('classes', index), + "alt": alt, + "src": "{}{}.svg".format( + options.get('image_path', svg_path), + uc + ) + } + + if title: + attributes['title'] = title + + add_attributes(options, attributes) + + return etree.Element("img", attributes) + + +def to_png_sprite(index, shortname, alias, uc, alt, title, category, options, md): + """Return PNG sprite element.""" + + attributes = { + "class": '%(class)s-%(size)s-%(category)s _%(unicode)s' % { + "class": options.get('classes', index), + "size": options.get('size', '64'), + "category": (category if category else ''), + "unicode": uc + } + } + + if title: + attributes['title'] = title + + add_attributes(options, attributes) + + el = etree.Element("span", attributes) + el.text = md_util.AtomicString(alt) + + return el + + +def to_svg_sprite(index, shortname, alias, uc, alt, title, category, options, md): + """ + Return SVG sprite element. + + ``` + %(alt)s + + ``` + """ + + xlink_href = '{}#emoji-{}'.format( + options.get('image_path', './../assets/sprites/emojione.sprites.svg'), uc + ) + svg = etree.Element("svg", {"class": options.get('classes', index)}) + desc = etree.SubElement(svg, 'description') + desc.text = md_util.AtomicString(alt) + etree.SubElement(svg, 'use', {'xlink:href': xlink_href}) + + return svg + + +def to_alt(index, shortname, alias, uc, alt, title, category, options, md): + """Return html entities.""" + + return md.htmlStash.store(alt) + + +################### +# Classes +################### +class EmojiPattern(InlineProcessor): + """Return element of type `tag` with a text attribute of group(2) of an `InlineProcessor`.""" + + def __init__(self, pattern, config, strict_mode, md): + """Initialize.""" + + InlineProcessor.__init__(self, pattern, md) + + title = config['title'] + alt = config['alt'] + self.options = config['options'] + self._set_index(config["emoji_index"]) + self.unicode_alt = alt in UNICODE_ALT + self.encoded_alt = alt == UNICODE_ENTITY + self.remove_var_sel = config['remove_variation_selector'] + self.title = title if title in VALID_TITLE else NO_TITLE + self.generator = config['emoji_generator'] + self.strict = config['strict'] + self.strict_cache = strict_mode + + def _set_index(self, index): + """Set the index.""" + + if len(inspect.getfullargspec(index).args): + self.emoji_index = index(self.options, self.md) + else: + util.warn_deprecated(MSG_INDEX_WARN) + self.emoji_index = index() + + def _remove_variation_selector(self, value): + """Remove variation selectors.""" + + return value.replace('-' + UNICODE_VARIATION_SELECTOR_16, '') + + def _get_unicode_char(self, value): + """Get the Unicode char.""" + + return ''.join([util.get_char(int(c, 16)) for c in value.split('-')]) + + def _get_unicode(self, emoji): + """ + Get Unicode and Unicode alt. + + Unicode: This is the stripped down form of the Unicode, no joining chars and no variation chars. + Unicode code points are not always valid. If this is present and there is no 'unicode_alt', + Unicode code points can be counted on as valid. For the most part, the returned `uc` should + be used to reference image files, or create classes, but for inserting actual Unicode, 'uc_alt' + should be used. + + Unicode Alt: When present, this will always be valid Unicode points. This contains not just the + needed characters to identify the Unicode emoji, but the formatting as well. Joining characters + and variation characters will be present. If you don't want variation chars, enable the global + 'remove_variation_selector' option. + """ + + uc = emoji.get('unicode') + uc_alt = emoji.get('unicode_alt', uc) + if uc_alt and self.remove_var_sel: + uc_alt = self._remove_variation_selector(uc_alt) + + return uc, uc_alt + + def _get_title(self, shortname, emoji): + """Get the title.""" + + if self.title == LONG_TITLE: + title = emoji['name'] + elif self.title == SHORT_TITLE: + title = shortname + else: + title = None + return title + + def _get_alt(self, shortname, uc_alt): + """Get alt form.""" + + if uc_alt is None or not self.unicode_alt: + alt = shortname + else: + alt = self._get_unicode_char(uc_alt) + if self.encoded_alt: + alt = ''.join( + [md_util.AMP_SUBSTITUTE + ('#x%04x;' % util.get_ord(point)) for point in util.get_code_points(alt)] + ) + return alt + + def _get_category(self, emoji): + """Get the category.""" + + return emoji.get('category') + + def handleMatch(self, m, data): + """Handle emoji pattern matches.""" + + el = m.group(1) + + shortname = self.emoji_index['aliases'].get(el, el) + alias = None if shortname == el else el + emoji = self.emoji_index['emoji'].get(shortname, None) + if emoji: + uc, uc_alt = self._get_unicode(emoji) + title = self._get_title(el, emoji) + alt = self._get_alt(el, uc_alt) + category = self._get_category(emoji) + el = self.generator( + self.emoji_index['name'], + shortname, + alias, + uc, + alt, + title, + category, + self.options, + self.md + ) + elif self.strict: + self.strict_cache.add(shortname) + + return el, m.start(0), m.end(0) + + +class EmojiAlertPostprocessor(Postprocessor): + """Post processor to strip out unwanted content.""" + + def __init__(self, strict_cache, md): + """Initialize.""" + + self.strict_cache = strict_cache + + def run(self, text): + """Strip out ids and classes for a simplified HTML output.""" + + if len(self.strict_cache): + raise RuntimeError( + MSG_BAD_EMOJI.format('\n'.join([f'- {x}' for x in sorted(self.strict_cache)])) + ) + return text + + +class EmojiExtension(Extension): + """Add emoji extension to Markdown class.""" + + def __init__(self, *args, **kwargs): + """Initialize.""" + + self.config = { + 'emoji_index': [ + emojione, + "Function that returns the desired emoji index. - Default: 'pymdownx.emoji.emojione'" + ], + 'emoji_generator': [ + to_png, + "Emoji generator method. - Default: pymdownx.emoji.to_png" + ], + 'title': [ + 'short', + "What title to use on images. You can use 'long' which shows the long name, " + "'short' which shows the shortname (:short:), or 'none' which shows no title. " + "- Default: 'short'" + ], + 'alt': [ + 'unicode', + "Control alt form. 'short' sets alt to the shortname (:short:), 'uniocde' sets " + "alt to the raw Unicode value, and 'html_entity' sets alt to the HTML entity. " + "- Default: 'unicode'" + ], + 'remove_variation_selector': [ + False, + "Remove variation selector 16 from unicode. - Default: False" + ], + 'strict': [ + False, + "When enabled, if an emoji with a missing name is detected, an exception will be raised." + ], + 'options': [ + {}, + "Emoji options see documentation for options for github and emojione." + ] + } + super().__init__(*args, **kwargs) + + def reset(self): + """Reset.""" + + self.strict_cache.clear() + + def extendMarkdown(self, md): + """Add support for emoji.""" + + md.registerExtension(self) + + config = self.getConfigs() + + util.escape_chars(md, [':']) + + self.strict_cache = set() + md.inlinePatterns.register(EmojiPattern(RE_EMOJI, config, self.strict_cache, md), "emoji", 75) + if config['strict']: + md.postprocessors.register(EmojiAlertPostprocessor(self.strict_cache, md), "emoji-alert", 50) + + +################### +# Make Available +################### +def makeExtension(*args, **kwargs): + """Return extension.""" + + return EmojiExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/emoji1_db.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/emoji1_db.py new file mode 100644 index 0000000000000000000000000000000000000000..a57fc5e19ce9288591dfd8c34872916b75b07b09 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/emoji1_db.py @@ -0,0 +1,9938 @@ +"""Emojione autogen. + +Generated from emojione source. Do not edit by hand. + +MIT license. + +Copyright (c) http://www.emojione.com +""" +version = "v2.2.7" +name = "emojione" +emoji = { + ":100:": { + "category": "symbols", + "name": "hundred points symbol", + "unicode": "1f4af" + }, + ":1234:": { + "category": "symbols", + "name": "input symbol for numbers", + "unicode": "1f522" + }, + ":8ball:": { + "category": "activity", + "name": "billiards", + "unicode": "1f3b1" + }, + ":a:": { + "category": "symbols", + "name": "negative squared latin capital letter a", + "unicode": "1f170" + }, + ":ab:": { + "category": "symbols", + "name": "negative squared ab", + "unicode": "1f18e" + }, + ":abc:": { + "category": "symbols", + "name": "input symbol for latin letters", + "unicode": "1f524" + }, + ":abcd:": { + "category": "symbols", + "name": "input symbol for latin small letters", + "unicode": "1f521" + }, + ":accept:": { + "category": "symbols", + "name": "circled ideograph accept", + "unicode": "1f251" + }, + ":aerial_tramway:": { + "category": "travel", + "name": "aerial tramway", + "unicode": "1f6a1" + }, + ":airplane:": { + "category": "travel", + "name": "airplane", + "unicode": "2708", + "unicode_alt": "2708-fe0f" + }, + ":airplane_arriving:": { + "category": "travel", + "name": "airplane arriving", + "unicode": "1f6ec" + }, + ":airplane_departure:": { + "category": "travel", + "name": "airplane departure", + "unicode": "1f6eb" + }, + ":airplane_small:": { + "category": "travel", + "name": "small airplane", + "unicode": "1f6e9", + "unicode_alt": "1f6e9-fe0f" + }, + ":alarm_clock:": { + "category": "objects", + "name": "alarm clock", + "unicode": "23f0" + }, + ":alembic:": { + "category": "objects", + "name": "alembic", + "unicode": "2697", + "unicode_alt": "2697-fe0f" + }, + ":alien:": { + "category": "people", + "name": "extraterrestrial alien", + "unicode": "1f47d" + }, + ":ambulance:": { + "category": "travel", + "name": "ambulance", + "unicode": "1f691" + }, + ":amphora:": { + "category": "objects", + "name": "amphora", + "unicode": "1f3fa" + }, + ":anchor:": { + "category": "travel", + "name": "anchor", + "unicode": "2693", + "unicode_alt": "2693-fe0f" + }, + ":angel:": { + "category": "people", + "name": "baby angel", + "unicode": "1f47c" + }, + ":angel_tone1:": { + "category": "people", + "name": "baby angel tone 1", + "unicode": "1f47c-1f3fb" + }, + ":angel_tone2:": { + "category": "people", + "name": "baby angel tone 2", + "unicode": "1f47c-1f3fc" + }, + ":angel_tone3:": { + "category": "people", + "name": "baby angel tone 3", + "unicode": "1f47c-1f3fd" + }, + ":angel_tone4:": { + "category": "people", + "name": "baby angel tone 4", + "unicode": "1f47c-1f3fe" + }, + ":angel_tone5:": { + "category": "people", + "name": "baby angel tone 5", + "unicode": "1f47c-1f3ff" + }, + ":anger:": { + "category": "symbols", + "name": "anger symbol", + "unicode": "1f4a2" + }, + ":anger_right:": { + "category": "symbols", + "name": "right anger bubble", + "unicode": "1f5ef", + "unicode_alt": "1f5ef-fe0f" + }, + ":angry:": { + "category": "people", + "name": "angry face", + "unicode": "1f620" + }, + ":anguished:": { + "category": "people", + "name": "anguished face", + "unicode": "1f627" + }, + ":ant:": { + "category": "nature", + "name": "ant", + "unicode": "1f41c" + }, + ":apple:": { + "category": "food", + "name": "red apple", + "unicode": "1f34e" + }, + ":aquarius:": { + "category": "symbols", + "name": "aquarius", + "unicode": "2652", + "unicode_alt": "2652-fe0f" + }, + ":aries:": { + "category": "symbols", + "name": "aries", + "unicode": "2648", + "unicode_alt": "2648-fe0f" + }, + ":arrow_backward:": { + "category": "symbols", + "name": "black left-pointing triangle", + "unicode": "25c0", + "unicode_alt": "25c0-fe0f" + }, + ":arrow_double_down:": { + "category": "symbols", + "name": "black down-pointing double triangle", + "unicode": "23ec" + }, + ":arrow_double_up:": { + "category": "symbols", + "name": "black up-pointing double triangle", + "unicode": "23eb" + }, + ":arrow_down:": { + "category": "symbols", + "name": "downwards black arrow", + "unicode": "2b07", + "unicode_alt": "2b07-fe0f" + }, + ":arrow_down_small:": { + "category": "symbols", + "name": "down-pointing small red triangle", + "unicode": "1f53d" + }, + ":arrow_forward:": { + "category": "symbols", + "name": "black right-pointing triangle", + "unicode": "25b6", + "unicode_alt": "25b6-fe0f" + }, + ":arrow_heading_down:": { + "category": "symbols", + "name": "arrow pointing rightwards then curving downwards", + "unicode": "2935", + "unicode_alt": "2935-fe0f" + }, + ":arrow_heading_up:": { + "category": "symbols", + "name": "arrow pointing rightwards then curving upwards", + "unicode": "2934", + "unicode_alt": "2934-fe0f" + }, + ":arrow_left:": { + "category": "symbols", + "name": "leftwards black arrow", + "unicode": "2b05", + "unicode_alt": "2b05-fe0f" + }, + ":arrow_lower_left:": { + "category": "symbols", + "name": "south west arrow", + "unicode": "2199", + "unicode_alt": "2199-fe0f" + }, + ":arrow_lower_right:": { + "category": "symbols", + "name": "south east arrow", + "unicode": "2198", + "unicode_alt": "2198-fe0f" + }, + ":arrow_right:": { + "category": "symbols", + "name": "black rightwards arrow", + "unicode": "27a1", + "unicode_alt": "27a1-fe0f" + }, + ":arrow_right_hook:": { + "category": "symbols", + "name": "rightwards arrow with hook", + "unicode": "21aa", + "unicode_alt": "21aa-fe0f" + }, + ":arrow_up:": { + "category": "symbols", + "name": "upwards black arrow", + "unicode": "2b06", + "unicode_alt": "2b06-fe0f" + }, + ":arrow_up_down:": { + "category": "symbols", + "name": "up down arrow", + "unicode": "2195", + "unicode_alt": "2195-fe0f" + }, + ":arrow_up_small:": { + "category": "symbols", + "name": "up-pointing small red triangle", + "unicode": "1f53c" + }, + ":arrow_upper_left:": { + "category": "symbols", + "name": "north west arrow", + "unicode": "2196", + "unicode_alt": "2196-fe0f" + }, + ":arrow_upper_right:": { + "category": "symbols", + "name": "north east arrow", + "unicode": "2197", + "unicode_alt": "2197-fe0f" + }, + ":arrows_clockwise:": { + "category": "symbols", + "name": "clockwise downwards and upwards open circle arrows", + "unicode": "1f503" + }, + ":arrows_counterclockwise:": { + "category": "symbols", + "name": "anticlockwise downwards and upwards open circle arrows", + "unicode": "1f504" + }, + ":art:": { + "category": "activity", + "name": "artist palette", + "unicode": "1f3a8" + }, + ":articulated_lorry:": { + "category": "travel", + "name": "articulated lorry", + "unicode": "1f69b" + }, + ":asterisk:": { + "category": "symbols", + "name": "keycap asterisk", + "unicode": "002a-20e3", + "unicode_alt": "002a-fe0f-20e3" + }, + ":astonished:": { + "category": "people", + "name": "astonished face", + "unicode": "1f632" + }, + ":athletic_shoe:": { + "category": "people", + "name": "athletic shoe", + "unicode": "1f45f" + }, + ":atm:": { + "category": "symbols", + "name": "automated teller machine", + "unicode": "1f3e7" + }, + ":atom:": { + "category": "symbols", + "name": "atom symbol", + "unicode": "269b", + "unicode_alt": "269b-fe0f" + }, + ":avocado:": { + "category": "food", + "name": "avocado", + "unicode": "1f951" + }, + ":b:": { + "category": "symbols", + "name": "negative squared latin capital letter b", + "unicode": "1f171" + }, + ":baby:": { + "category": "people", + "name": "baby", + "unicode": "1f476" + }, + ":baby_bottle:": { + "category": "food", + "name": "baby bottle", + "unicode": "1f37c" + }, + ":baby_chick:": { + "category": "nature", + "name": "baby chick", + "unicode": "1f424" + }, + ":baby_symbol:": { + "category": "symbols", + "name": "baby symbol", + "unicode": "1f6bc" + }, + ":baby_tone1:": { + "category": "people", + "name": "baby tone 1", + "unicode": "1f476-1f3fb" + }, + ":baby_tone2:": { + "category": "people", + "name": "baby tone 2", + "unicode": "1f476-1f3fc" + }, + ":baby_tone3:": { + "category": "people", + "name": "baby tone 3", + "unicode": "1f476-1f3fd" + }, + ":baby_tone4:": { + "category": "people", + "name": "baby tone 4", + "unicode": "1f476-1f3fe" + }, + ":baby_tone5:": { + "category": "people", + "name": "baby tone 5", + "unicode": "1f476-1f3ff" + }, + ":back:": { + "category": "symbols", + "name": "back with leftwards arrow above", + "unicode": "1f519" + }, + ":bacon:": { + "category": "food", + "name": "bacon", + "unicode": "1f953" + }, + ":badminton:": { + "category": "activity", + "name": "badminton racquet", + "unicode": "1f3f8" + }, + ":baggage_claim:": { + "category": "symbols", + "name": "baggage claim", + "unicode": "1f6c4" + }, + ":balloon:": { + "category": "objects", + "name": "balloon", + "unicode": "1f388" + }, + ":ballot_box:": { + "category": "objects", + "name": "ballot box with ballot", + "unicode": "1f5f3", + "unicode_alt": "1f5f3-fe0f" + }, + ":ballot_box_with_check:": { + "category": "symbols", + "name": "ballot box with check", + "unicode": "2611", + "unicode_alt": "2611-fe0f" + }, + ":bamboo:": { + "category": "nature", + "name": "pine decoration", + "unicode": "1f38d" + }, + ":banana:": { + "category": "food", + "name": "banana", + "unicode": "1f34c" + }, + ":bangbang:": { + "category": "symbols", + "name": "double exclamation mark", + "unicode": "203c", + "unicode_alt": "203c-fe0f" + }, + ":bank:": { + "category": "travel", + "name": "bank", + "unicode": "1f3e6" + }, + ":bar_chart:": { + "category": "objects", + "name": "bar chart", + "unicode": "1f4ca" + }, + ":barber:": { + "category": "objects", + "name": "barber pole", + "unicode": "1f488" + }, + ":baseball:": { + "category": "activity", + "name": "baseball", + "unicode": "26be", + "unicode_alt": "26be-fe0f" + }, + ":basketball:": { + "category": "activity", + "name": "basketball and hoop", + "unicode": "1f3c0" + }, + ":basketball_player:": { + "category": "activity", + "name": "person with ball", + "unicode": "26f9", + "unicode_alt": "26f9-fe0f" + }, + ":basketball_player_tone1:": { + "category": "activity", + "name": "person with ball tone 1", + "unicode": "26f9-1f3fb" + }, + ":basketball_player_tone2:": { + "category": "activity", + "name": "person with ball tone 2", + "unicode": "26f9-1f3fc" + }, + ":basketball_player_tone3:": { + "category": "activity", + "name": "person with ball tone 3", + "unicode": "26f9-1f3fd" + }, + ":basketball_player_tone4:": { + "category": "activity", + "name": "person with ball tone 4", + "unicode": "26f9-1f3fe" + }, + ":basketball_player_tone5:": { + "category": "activity", + "name": "person with ball tone 5", + "unicode": "26f9-1f3ff" + }, + ":bat:": { + "category": "nature", + "name": "bat", + "unicode": "1f987" + }, + ":bath:": { + "category": "activity", + "name": "bath", + "unicode": "1f6c0" + }, + ":bath_tone1:": { + "category": "activity", + "name": "bath tone 1", + "unicode": "1f6c0-1f3fb" + }, + ":bath_tone2:": { + "category": "activity", + "name": "bath tone 2", + "unicode": "1f6c0-1f3fc" + }, + ":bath_tone3:": { + "category": "activity", + "name": "bath tone 3", + "unicode": "1f6c0-1f3fd" + }, + ":bath_tone4:": { + "category": "activity", + "name": "bath tone 4", + "unicode": "1f6c0-1f3fe" + }, + ":bath_tone5:": { + "category": "activity", + "name": "bath tone 5", + "unicode": "1f6c0-1f3ff" + }, + ":bathtub:": { + "category": "objects", + "name": "bathtub", + "unicode": "1f6c1" + }, + ":battery:": { + "category": "objects", + "name": "battery", + "unicode": "1f50b" + }, + ":beach:": { + "category": "travel", + "name": "beach with umbrella", + "unicode": "1f3d6", + "unicode_alt": "1f3d6-fe0f" + }, + ":beach_umbrella:": { + "category": "objects", + "name": "umbrella on ground", + "unicode": "26f1", + "unicode_alt": "26f1-fe0f" + }, + ":bear:": { + "category": "nature", + "name": "bear face", + "unicode": "1f43b" + }, + ":bed:": { + "category": "objects", + "name": "bed", + "unicode": "1f6cf", + "unicode_alt": "1f6cf-fe0f" + }, + ":bee:": { + "category": "nature", + "name": "honeybee", + "unicode": "1f41d" + }, + ":beer:": { + "category": "food", + "name": "beer mug", + "unicode": "1f37a" + }, + ":beers:": { + "category": "food", + "name": "clinking beer mugs", + "unicode": "1f37b" + }, + ":beetle:": { + "category": "nature", + "name": "lady beetle", + "unicode": "1f41e" + }, + ":beginner:": { + "category": "symbols", + "name": "japanese symbol for beginner", + "unicode": "1f530" + }, + ":bell:": { + "category": "symbols", + "name": "bell", + "unicode": "1f514" + }, + ":bellhop:": { + "category": "objects", + "name": "bellhop bell", + "unicode": "1f6ce", + "unicode_alt": "1f6ce-fe0f" + }, + ":bento:": { + "category": "food", + "name": "bento box", + "unicode": "1f371" + }, + ":bicyclist:": { + "category": "activity", + "name": "bicyclist", + "unicode": "1f6b4" + }, + ":bicyclist_tone1:": { + "category": "activity", + "name": "bicyclist tone 1", + "unicode": "1f6b4-1f3fb" + }, + ":bicyclist_tone2:": { + "category": "activity", + "name": "bicyclist tone 2", + "unicode": "1f6b4-1f3fc" + }, + ":bicyclist_tone3:": { + "category": "activity", + "name": "bicyclist tone 3", + "unicode": "1f6b4-1f3fd" + }, + ":bicyclist_tone4:": { + "category": "activity", + "name": "bicyclist tone 4", + "unicode": "1f6b4-1f3fe" + }, + ":bicyclist_tone5:": { + "category": "activity", + "name": "bicyclist tone 5", + "unicode": "1f6b4-1f3ff" + }, + ":bike:": { + "category": "travel", + "name": "bicycle", + "unicode": "1f6b2" + }, + ":bikini:": { + "category": "people", + "name": "bikini", + "unicode": "1f459" + }, + ":biohazard:": { + "category": "symbols", + "name": "biohazard sign", + "unicode": "2623", + "unicode_alt": "2623-fe0f" + }, + ":bird:": { + "category": "nature", + "name": "bird", + "unicode": "1f426" + }, + ":birthday:": { + "category": "food", + "name": "birthday cake", + "unicode": "1f382" + }, + ":black_circle:": { + "category": "symbols", + "name": "black circle", + "unicode": "26ab", + "unicode_alt": "26ab-fe0f" + }, + ":black_heart:": { + "category": "symbols", + "name": "black heart", + "unicode": "1f5a4" + }, + ":black_joker:": { + "category": "symbols", + "name": "playing card black joker", + "unicode": "1f0cf" + }, + ":black_large_square:": { + "category": "symbols", + "name": "black large square", + "unicode": "2b1b", + "unicode_alt": "2b1b-fe0f" + }, + ":black_medium_small_square:": { + "category": "symbols", + "name": "black medium small square", + "unicode": "25fe", + "unicode_alt": "25fe-fe0f" + }, + ":black_medium_square:": { + "category": "symbols", + "name": "black medium square", + "unicode": "25fc", + "unicode_alt": "25fc-fe0f" + }, + ":black_nib:": { + "category": "objects", + "name": "black nib", + "unicode": "2712", + "unicode_alt": "2712-fe0f" + }, + ":black_small_square:": { + "category": "symbols", + "name": "black small square", + "unicode": "25aa", + "unicode_alt": "25aa-fe0f" + }, + ":black_square_button:": { + "category": "symbols", + "name": "black square button", + "unicode": "1f532" + }, + ":blossom:": { + "category": "nature", + "name": "blossom", + "unicode": "1f33c" + }, + ":blowfish:": { + "category": "nature", + "name": "blowfish", + "unicode": "1f421" + }, + ":blue_book:": { + "category": "objects", + "name": "blue book", + "unicode": "1f4d8" + }, + ":blue_car:": { + "category": "travel", + "name": "recreational vehicle", + "unicode": "1f699" + }, + ":blue_circle:": { + "category": "symbols", + "name": "blue circle", + "unicode": "1f535" + }, + ":blue_heart:": { + "category": "symbols", + "name": "blue heart", + "unicode": "1f499" + }, + ":blush:": { + "category": "people", + "name": "smiling face with smiling eyes", + "unicode": "1f60a" + }, + ":boar:": { + "category": "nature", + "name": "boar", + "unicode": "1f417" + }, + ":bomb:": { + "category": "objects", + "name": "bomb", + "unicode": "1f4a3" + }, + ":book:": { + "category": "objects", + "name": "open book", + "unicode": "1f4d6" + }, + ":bookmark:": { + "category": "objects", + "name": "bookmark", + "unicode": "1f516" + }, + ":bookmark_tabs:": { + "category": "objects", + "name": "bookmark tabs", + "unicode": "1f4d1" + }, + ":books:": { + "category": "objects", + "name": "books", + "unicode": "1f4da" + }, + ":boom:": { + "category": "symbols", + "name": "collision symbol", + "unicode": "1f4a5" + }, + ":boot:": { + "category": "people", + "name": "womans boots", + "unicode": "1f462" + }, + ":bouquet:": { + "category": "nature", + "name": "bouquet", + "unicode": "1f490" + }, + ":bow:": { + "category": "people", + "name": "person bowing deeply", + "unicode": "1f647" + }, + ":bow_and_arrow:": { + "category": "activity", + "name": "bow and arrow", + "unicode": "1f3f9" + }, + ":bow_tone1:": { + "category": "people", + "name": "person bowing deeply tone 1", + "unicode": "1f647-1f3fb" + }, + ":bow_tone2:": { + "category": "people", + "name": "person bowing deeply tone 2", + "unicode": "1f647-1f3fc" + }, + ":bow_tone3:": { + "category": "people", + "name": "person bowing deeply tone 3", + "unicode": "1f647-1f3fd" + }, + ":bow_tone4:": { + "category": "people", + "name": "person bowing deeply tone 4", + "unicode": "1f647-1f3fe" + }, + ":bow_tone5:": { + "category": "people", + "name": "person bowing deeply tone 5", + "unicode": "1f647-1f3ff" + }, + ":bowling:": { + "category": "activity", + "name": "bowling", + "unicode": "1f3b3" + }, + ":boxing_glove:": { + "category": "activity", + "name": "boxing glove", + "unicode": "1f94a" + }, + ":boy:": { + "category": "people", + "name": "boy", + "unicode": "1f466" + }, + ":boy_tone1:": { + "category": "people", + "name": "boy tone 1", + "unicode": "1f466-1f3fb" + }, + ":boy_tone2:": { + "category": "people", + "name": "boy tone 2", + "unicode": "1f466-1f3fc" + }, + ":boy_tone3:": { + "category": "people", + "name": "boy tone 3", + "unicode": "1f466-1f3fd" + }, + ":boy_tone4:": { + "category": "people", + "name": "boy tone 4", + "unicode": "1f466-1f3fe" + }, + ":boy_tone5:": { + "category": "people", + "name": "boy tone 5", + "unicode": "1f466-1f3ff" + }, + ":bread:": { + "category": "food", + "name": "bread", + "unicode": "1f35e" + }, + ":bride_with_veil:": { + "category": "people", + "name": "bride with veil", + "unicode": "1f470" + }, + ":bride_with_veil_tone1:": { + "category": "people", + "name": "bride with veil tone 1", + "unicode": "1f470-1f3fb" + }, + ":bride_with_veil_tone2:": { + "category": "people", + "name": "bride with veil tone 2", + "unicode": "1f470-1f3fc" + }, + ":bride_with_veil_tone3:": { + "category": "people", + "name": "bride with veil tone 3", + "unicode": "1f470-1f3fd" + }, + ":bride_with_veil_tone4:": { + "category": "people", + "name": "bride with veil tone 4", + "unicode": "1f470-1f3fe" + }, + ":bride_with_veil_tone5:": { + "category": "people", + "name": "bride with veil tone 5", + "unicode": "1f470-1f3ff" + }, + ":bridge_at_night:": { + "category": "travel", + "name": "bridge at night", + "unicode": "1f309" + }, + ":briefcase:": { + "category": "people", + "name": "briefcase", + "unicode": "1f4bc" + }, + ":broken_heart:": { + "category": "symbols", + "name": "broken heart", + "unicode": "1f494" + }, + ":bug:": { + "category": "nature", + "name": "bug", + "unicode": "1f41b" + }, + ":bulb:": { + "category": "objects", + "name": "electric light bulb", + "unicode": "1f4a1" + }, + ":bullettrain_front:": { + "category": "travel", + "name": "high-speed train with bullet nose", + "unicode": "1f685" + }, + ":bullettrain_side:": { + "category": "travel", + "name": "high-speed train", + "unicode": "1f684" + }, + ":burrito:": { + "category": "food", + "name": "burrito", + "unicode": "1f32f" + }, + ":bus:": { + "category": "travel", + "name": "bus", + "unicode": "1f68c" + }, + ":busstop:": { + "category": "travel", + "name": "bus stop", + "unicode": "1f68f" + }, + ":bust_in_silhouette:": { + "category": "people", + "name": "bust in silhouette", + "unicode": "1f464" + }, + ":busts_in_silhouette:": { + "category": "people", + "name": "busts in silhouette", + "unicode": "1f465" + }, + ":butterfly:": { + "category": "nature", + "name": "butterfly", + "unicode": "1f98b" + }, + ":cactus:": { + "category": "nature", + "name": "cactus", + "unicode": "1f335" + }, + ":cake:": { + "category": "food", + "name": "shortcake", + "unicode": "1f370" + }, + ":calendar:": { + "category": "objects", + "name": "tear-off calendar", + "unicode": "1f4c6" + }, + ":calendar_spiral:": { + "category": "objects", + "name": "spiral calendar pad", + "unicode": "1f5d3", + "unicode_alt": "1f5d3-fe0f" + }, + ":call_me:": { + "category": "people", + "name": "call me hand", + "unicode": "1f919" + }, + ":call_me_tone1:": { + "category": "people", + "name": "call me hand tone 1", + "unicode": "1f919-1f3fb" + }, + ":call_me_tone2:": { + "category": "people", + "name": "call me hand tone 2", + "unicode": "1f919-1f3fc" + }, + ":call_me_tone3:": { + "category": "people", + "name": "call me hand tone 3", + "unicode": "1f919-1f3fd" + }, + ":call_me_tone4:": { + "category": "people", + "name": "call me hand tone 4", + "unicode": "1f919-1f3fe" + }, + ":call_me_tone5:": { + "category": "people", + "name": "call me hand tone 5", + "unicode": "1f919-1f3ff" + }, + ":calling:": { + "category": "objects", + "name": "mobile phone with rightwards arrow at left", + "unicode": "1f4f2" + }, + ":camel:": { + "category": "nature", + "name": "bactrian camel", + "unicode": "1f42b" + }, + ":camera:": { + "category": "objects", + "name": "camera", + "unicode": "1f4f7" + }, + ":camera_with_flash:": { + "category": "objects", + "name": "camera with flash", + "unicode": "1f4f8" + }, + ":camping:": { + "category": "travel", + "name": "camping", + "unicode": "1f3d5", + "unicode_alt": "1f3d5-fe0f" + }, + ":cancer:": { + "category": "symbols", + "name": "cancer", + "unicode": "264b", + "unicode_alt": "264b-fe0f" + }, + ":candle:": { + "category": "objects", + "name": "candle", + "unicode": "1f56f", + "unicode_alt": "1f56f-fe0f" + }, + ":candy:": { + "category": "food", + "name": "candy", + "unicode": "1f36c" + }, + ":canoe:": { + "category": "travel", + "name": "canoe", + "unicode": "1f6f6" + }, + ":capital_abcd:": { + "category": "symbols", + "name": "input symbol for latin capital letters", + "unicode": "1f520" + }, + ":capricorn:": { + "category": "symbols", + "name": "capricorn", + "unicode": "2651", + "unicode_alt": "2651-fe0f" + }, + ":card_box:": { + "category": "objects", + "name": "card file box", + "unicode": "1f5c3", + "unicode_alt": "1f5c3-fe0f" + }, + ":card_index:": { + "category": "objects", + "name": "card index", + "unicode": "1f4c7" + }, + ":carousel_horse:": { + "category": "travel", + "name": "carousel horse", + "unicode": "1f3a0" + }, + ":carrot:": { + "category": "food", + "name": "carrot", + "unicode": "1f955" + }, + ":cartwheel:": { + "category": "activity", + "name": "person doing cartwheel", + "unicode": "1f938" + }, + ":cartwheel_tone1:": { + "category": "activity", + "name": "person doing cartwheel tone 1", + "unicode": "1f938-1f3fb" + }, + ":cartwheel_tone2:": { + "category": "activity", + "name": "person doing cartwheel tone 2", + "unicode": "1f938-1f3fc" + }, + ":cartwheel_tone3:": { + "category": "activity", + "name": "person doing cartwheel tone 3", + "unicode": "1f938-1f3fd" + }, + ":cartwheel_tone4:": { + "category": "activity", + "name": "person doing cartwheel tone 4", + "unicode": "1f938-1f3fe" + }, + ":cartwheel_tone5:": { + "category": "activity", + "name": "person doing cartwheel tone 5", + "unicode": "1f938-1f3ff" + }, + ":cat2:": { + "category": "nature", + "name": "cat", + "unicode": "1f408" + }, + ":cat:": { + "category": "nature", + "name": "cat face", + "unicode": "1f431" + }, + ":cd:": { + "category": "objects", + "name": "optical disc", + "unicode": "1f4bf" + }, + ":chains:": { + "category": "objects", + "name": "chains", + "unicode": "26d3", + "unicode_alt": "26d3-fe0f" + }, + ":champagne:": { + "category": "food", + "name": "bottle with popping cork", + "unicode": "1f37e" + }, + ":champagne_glass:": { + "category": "food", + "name": "clinking glasses", + "unicode": "1f942" + }, + ":chart:": { + "category": "symbols", + "name": "chart with upwards trend and yen sign", + "unicode": "1f4b9" + }, + ":chart_with_downwards_trend:": { + "category": "objects", + "name": "chart with downwards trend", + "unicode": "1f4c9" + }, + ":chart_with_upwards_trend:": { + "category": "objects", + "name": "chart with upwards trend", + "unicode": "1f4c8" + }, + ":checkered_flag:": { + "category": "travel", + "name": "chequered flag", + "unicode": "1f3c1" + }, + ":cheese:": { + "category": "food", + "name": "cheese wedge", + "unicode": "1f9c0" + }, + ":cherries:": { + "category": "food", + "name": "cherries", + "unicode": "1f352" + }, + ":cherry_blossom:": { + "category": "nature", + "name": "cherry blossom", + "unicode": "1f338" + }, + ":chestnut:": { + "category": "nature", + "name": "chestnut", + "unicode": "1f330" + }, + ":chicken:": { + "category": "nature", + "name": "chicken", + "unicode": "1f414" + }, + ":children_crossing:": { + "category": "symbols", + "name": "children crossing", + "unicode": "1f6b8" + }, + ":chipmunk:": { + "category": "nature", + "name": "chipmunk", + "unicode": "1f43f", + "unicode_alt": "1f43f-fe0f" + }, + ":chocolate_bar:": { + "category": "food", + "name": "chocolate bar", + "unicode": "1f36b" + }, + ":christmas_tree:": { + "category": "nature", + "name": "christmas tree", + "unicode": "1f384" + }, + ":church:": { + "category": "travel", + "name": "church", + "unicode": "26ea", + "unicode_alt": "26ea-fe0f" + }, + ":cinema:": { + "category": "symbols", + "name": "cinema", + "unicode": "1f3a6" + }, + ":circus_tent:": { + "category": "activity", + "name": "circus tent", + "unicode": "1f3aa" + }, + ":city_dusk:": { + "category": "travel", + "name": "cityscape at dusk", + "unicode": "1f306" + }, + ":city_sunset:": { + "category": "travel", + "name": "sunset over buildings", + "unicode": "1f307" + }, + ":cityscape:": { + "category": "travel", + "name": "cityscape", + "unicode": "1f3d9", + "unicode_alt": "1f3d9-fe0f" + }, + ":cl:": { + "category": "symbols", + "name": "squared cl", + "unicode": "1f191" + }, + ":clap:": { + "category": "people", + "name": "clapping hands sign", + "unicode": "1f44f" + }, + ":clap_tone1:": { + "category": "people", + "name": "clapping hands sign tone 1", + "unicode": "1f44f-1f3fb" + }, + ":clap_tone2:": { + "category": "people", + "name": "clapping hands sign tone 2", + "unicode": "1f44f-1f3fc" + }, + ":clap_tone3:": { + "category": "people", + "name": "clapping hands sign tone 3", + "unicode": "1f44f-1f3fd" + }, + ":clap_tone4:": { + "category": "people", + "name": "clapping hands sign tone 4", + "unicode": "1f44f-1f3fe" + }, + ":clap_tone5:": { + "category": "people", + "name": "clapping hands sign tone 5", + "unicode": "1f44f-1f3ff" + }, + ":clapper:": { + "category": "activity", + "name": "clapper board", + "unicode": "1f3ac" + }, + ":classical_building:": { + "category": "travel", + "name": "classical building", + "unicode": "1f3db", + "unicode_alt": "1f3db-fe0f" + }, + ":clipboard:": { + "category": "objects", + "name": "clipboard", + "unicode": "1f4cb" + }, + ":clock1030:": { + "category": "symbols", + "name": "clock face ten-thirty", + "unicode": "1f565" + }, + ":clock10:": { + "category": "symbols", + "name": "clock face ten oclock", + "unicode": "1f559" + }, + ":clock1130:": { + "category": "symbols", + "name": "clock face eleven-thirty", + "unicode": "1f566" + }, + ":clock11:": { + "category": "symbols", + "name": "clock face eleven oclock", + "unicode": "1f55a" + }, + ":clock1230:": { + "category": "symbols", + "name": "clock face twelve-thirty", + "unicode": "1f567" + }, + ":clock12:": { + "category": "symbols", + "name": "clock face twelve oclock", + "unicode": "1f55b" + }, + ":clock130:": { + "category": "symbols", + "name": "clock face one-thirty", + "unicode": "1f55c" + }, + ":clock1:": { + "category": "symbols", + "name": "clock face one oclock", + "unicode": "1f550" + }, + ":clock230:": { + "category": "symbols", + "name": "clock face two-thirty", + "unicode": "1f55d" + }, + ":clock2:": { + "category": "symbols", + "name": "clock face two oclock", + "unicode": "1f551" + }, + ":clock330:": { + "category": "symbols", + "name": "clock face three-thirty", + "unicode": "1f55e" + }, + ":clock3:": { + "category": "symbols", + "name": "clock face three oclock", + "unicode": "1f552" + }, + ":clock430:": { + "category": "symbols", + "name": "clock face four-thirty", + "unicode": "1f55f" + }, + ":clock4:": { + "category": "symbols", + "name": "clock face four oclock", + "unicode": "1f553" + }, + ":clock530:": { + "category": "symbols", + "name": "clock face five-thirty", + "unicode": "1f560" + }, + ":clock5:": { + "category": "symbols", + "name": "clock face five oclock", + "unicode": "1f554" + }, + ":clock630:": { + "category": "symbols", + "name": "clock face six-thirty", + "unicode": "1f561" + }, + ":clock6:": { + "category": "symbols", + "name": "clock face six oclock", + "unicode": "1f555" + }, + ":clock730:": { + "category": "symbols", + "name": "clock face seven-thirty", + "unicode": "1f562" + }, + ":clock7:": { + "category": "symbols", + "name": "clock face seven oclock", + "unicode": "1f556" + }, + ":clock830:": { + "category": "symbols", + "name": "clock face eight-thirty", + "unicode": "1f563" + }, + ":clock8:": { + "category": "symbols", + "name": "clock face eight oclock", + "unicode": "1f557" + }, + ":clock930:": { + "category": "symbols", + "name": "clock face nine-thirty", + "unicode": "1f564" + }, + ":clock9:": { + "category": "symbols", + "name": "clock face nine oclock", + "unicode": "1f558" + }, + ":clock:": { + "category": "objects", + "name": "mantlepiece clock", + "unicode": "1f570", + "unicode_alt": "1f570-fe0f" + }, + ":closed_book:": { + "category": "objects", + "name": "closed book", + "unicode": "1f4d5" + }, + ":closed_lock_with_key:": { + "category": "objects", + "name": "closed lock with key", + "unicode": "1f510" + }, + ":closed_umbrella:": { + "category": "people", + "name": "closed umbrella", + "unicode": "1f302" + }, + ":cloud:": { + "category": "nature", + "name": "cloud", + "unicode": "2601", + "unicode_alt": "2601-fe0f" + }, + ":cloud_lightning:": { + "category": "nature", + "name": "cloud with lightning", + "unicode": "1f329", + "unicode_alt": "1f329-fe0f" + }, + ":cloud_rain:": { + "category": "nature", + "name": "cloud with rain", + "unicode": "1f327", + "unicode_alt": "1f327-fe0f" + }, + ":cloud_snow:": { + "category": "nature", + "name": "cloud with snow", + "unicode": "1f328", + "unicode_alt": "1f328-fe0f" + }, + ":cloud_tornado:": { + "category": "nature", + "name": "cloud with tornado", + "unicode": "1f32a", + "unicode_alt": "1f32a-fe0f" + }, + ":clown:": { + "category": "people", + "name": "clown face", + "unicode": "1f921" + }, + ":clubs:": { + "category": "symbols", + "name": "black club suit", + "unicode": "2663", + "unicode_alt": "2663-fe0f" + }, + ":cocktail:": { + "category": "food", + "name": "cocktail glass", + "unicode": "1f378" + }, + ":coffee:": { + "category": "food", + "name": "hot beverage", + "unicode": "2615", + "unicode_alt": "2615-fe0f" + }, + ":coffin:": { + "category": "objects", + "name": "coffin", + "unicode": "26b0", + "unicode_alt": "26b0-fe0f" + }, + ":cold_sweat:": { + "category": "people", + "name": "face with open mouth and cold sweat", + "unicode": "1f630" + }, + ":comet:": { + "category": "nature", + "name": "comet", + "unicode": "2604", + "unicode_alt": "2604-fe0f" + }, + ":compression:": { + "category": "objects", + "name": "compression", + "unicode": "1f5dc", + "unicode_alt": "1f5dc-fe0f" + }, + ":computer:": { + "category": "objects", + "name": "personal computer", + "unicode": "1f4bb" + }, + ":confetti_ball:": { + "category": "objects", + "name": "confetti ball", + "unicode": "1f38a" + }, + ":confounded:": { + "category": "people", + "name": "confounded face", + "unicode": "1f616" + }, + ":confused:": { + "category": "people", + "name": "confused face", + "unicode": "1f615" + }, + ":congratulations:": { + "category": "symbols", + "name": "circled ideograph congratulation", + "unicode": "3297", + "unicode_alt": "3297-fe0f" + }, + ":construction:": { + "category": "travel", + "name": "construction sign", + "unicode": "1f6a7" + }, + ":construction_site:": { + "category": "travel", + "name": "building construction", + "unicode": "1f3d7", + "unicode_alt": "1f3d7-fe0f" + }, + ":construction_worker:": { + "category": "people", + "name": "construction worker", + "unicode": "1f477" + }, + ":construction_worker_tone1:": { + "category": "people", + "name": "construction worker tone 1", + "unicode": "1f477-1f3fb" + }, + ":construction_worker_tone2:": { + "category": "people", + "name": "construction worker tone 2", + "unicode": "1f477-1f3fc" + }, + ":construction_worker_tone3:": { + "category": "people", + "name": "construction worker tone 3", + "unicode": "1f477-1f3fd" + }, + ":construction_worker_tone4:": { + "category": "people", + "name": "construction worker tone 4", + "unicode": "1f477-1f3fe" + }, + ":construction_worker_tone5:": { + "category": "people", + "name": "construction worker tone 5", + "unicode": "1f477-1f3ff" + }, + ":control_knobs:": { + "category": "objects", + "name": "control knobs", + "unicode": "1f39b", + "unicode_alt": "1f39b-fe0f" + }, + ":convenience_store:": { + "category": "travel", + "name": "convenience store", + "unicode": "1f3ea" + }, + ":cookie:": { + "category": "food", + "name": "cookie", + "unicode": "1f36a" + }, + ":cooking:": { + "category": "food", + "name": "cooking", + "unicode": "1f373" + }, + ":cool:": { + "category": "symbols", + "name": "squared cool", + "unicode": "1f192" + }, + ":cop:": { + "category": "people", + "name": "police officer", + "unicode": "1f46e" + }, + ":cop_tone1:": { + "category": "people", + "name": "police officer tone 1", + "unicode": "1f46e-1f3fb" + }, + ":cop_tone2:": { + "category": "people", + "name": "police officer tone 2", + "unicode": "1f46e-1f3fc" + }, + ":cop_tone3:": { + "category": "people", + "name": "police officer tone 3", + "unicode": "1f46e-1f3fd" + }, + ":cop_tone4:": { + "category": "people", + "name": "police officer tone 4", + "unicode": "1f46e-1f3fe" + }, + ":cop_tone5:": { + "category": "people", + "name": "police officer tone 5", + "unicode": "1f46e-1f3ff" + }, + ":copyright:": { + "category": "symbols", + "name": "copyright sign", + "unicode": "00a9", + "unicode_alt": "00a9-fe0f" + }, + ":corn:": { + "category": "food", + "name": "ear of maize", + "unicode": "1f33d" + }, + ":couch:": { + "category": "objects", + "name": "couch and lamp", + "unicode": "1f6cb", + "unicode_alt": "1f6cb-fe0f" + }, + ":couple:": { + "category": "people", + "name": "man and woman holding hands", + "unicode": "1f46b" + }, + ":couple_mm:": { + "category": "people", + "name": "couple (man,man)", + "unicode": "1f468-2764-1f468", + "unicode_alt": "1f468-200d-2764-fe0f-200d-1f468" + }, + ":couple_with_heart:": { + "category": "people", + "name": "couple with heart", + "unicode": "1f491" + }, + ":couple_ww:": { + "category": "people", + "name": "couple (woman,woman)", + "unicode": "1f469-2764-1f469", + "unicode_alt": "1f469-200d-2764-fe0f-200d-1f469" + }, + ":couplekiss:": { + "category": "people", + "name": "kiss", + "unicode": "1f48f" + }, + ":cow2:": { + "category": "nature", + "name": "cow", + "unicode": "1f404" + }, + ":cow:": { + "category": "nature", + "name": "cow face", + "unicode": "1f42e" + }, + ":cowboy:": { + "category": "people", + "name": "face with cowboy hat", + "unicode": "1f920" + }, + ":crab:": { + "category": "nature", + "name": "crab", + "unicode": "1f980" + }, + ":crayon:": { + "category": "objects", + "name": "lower left crayon", + "unicode": "1f58d", + "unicode_alt": "1f58d-fe0f" + }, + ":credit_card:": { + "category": "objects", + "name": "credit card", + "unicode": "1f4b3" + }, + ":crescent_moon:": { + "category": "nature", + "name": "crescent moon", + "unicode": "1f319" + }, + ":cricket:": { + "category": "activity", + "name": "cricket bat and ball", + "unicode": "1f3cf" + }, + ":crocodile:": { + "category": "nature", + "name": "crocodile", + "unicode": "1f40a" + }, + ":croissant:": { + "category": "food", + "name": "croissant", + "unicode": "1f950" + }, + ":cross:": { + "category": "symbols", + "name": "latin cross", + "unicode": "271d", + "unicode_alt": "271d-fe0f" + }, + ":crossed_flags:": { + "category": "objects", + "name": "crossed flags", + "unicode": "1f38c" + }, + ":crossed_swords:": { + "category": "objects", + "name": "crossed swords", + "unicode": "2694", + "unicode_alt": "2694-fe0f" + }, + ":crown:": { + "category": "people", + "name": "crown", + "unicode": "1f451" + }, + ":cruise_ship:": { + "category": "travel", + "name": "passenger ship", + "unicode": "1f6f3", + "unicode_alt": "1f6f3-fe0f" + }, + ":cry:": { + "category": "people", + "name": "crying face", + "unicode": "1f622" + }, + ":crying_cat_face:": { + "category": "people", + "name": "crying cat face", + "unicode": "1f63f" + }, + ":crystal_ball:": { + "category": "objects", + "name": "crystal ball", + "unicode": "1f52e" + }, + ":cucumber:": { + "category": "food", + "name": "cucumber", + "unicode": "1f952" + }, + ":cupid:": { + "category": "symbols", + "name": "heart with arrow", + "unicode": "1f498" + }, + ":curly_loop:": { + "category": "symbols", + "name": "curly loop", + "unicode": "27b0" + }, + ":currency_exchange:": { + "category": "symbols", + "name": "currency exchange", + "unicode": "1f4b1" + }, + ":curry:": { + "category": "food", + "name": "curry and rice", + "unicode": "1f35b" + }, + ":custard:": { + "category": "food", + "name": "custard", + "unicode": "1f36e" + }, + ":customs:": { + "category": "symbols", + "name": "customs", + "unicode": "1f6c3" + }, + ":cyclone:": { + "category": "symbols", + "name": "cyclone", + "unicode": "1f300" + }, + ":dagger:": { + "category": "objects", + "name": "dagger knife", + "unicode": "1f5e1", + "unicode_alt": "1f5e1-fe0f" + }, + ":dancer:": { + "category": "people", + "name": "dancer", + "unicode": "1f483" + }, + ":dancer_tone1:": { + "category": "people", + "name": "dancer tone 1", + "unicode": "1f483-1f3fb" + }, + ":dancer_tone2:": { + "category": "people", + "name": "dancer tone 2", + "unicode": "1f483-1f3fc" + }, + ":dancer_tone3:": { + "category": "people", + "name": "dancer tone 3", + "unicode": "1f483-1f3fd" + }, + ":dancer_tone4:": { + "category": "people", + "name": "dancer tone 4", + "unicode": "1f483-1f3fe" + }, + ":dancer_tone5:": { + "category": "people", + "name": "dancer tone 5", + "unicode": "1f483-1f3ff" + }, + ":dancers:": { + "category": "people", + "name": "woman with bunny ears", + "unicode": "1f46f" + }, + ":dango:": { + "category": "food", + "name": "dango", + "unicode": "1f361" + }, + ":dark_sunglasses:": { + "category": "people", + "name": "dark sunglasses", + "unicode": "1f576", + "unicode_alt": "1f576-fe0f" + }, + ":dart:": { + "category": "activity", + "name": "direct hit", + "unicode": "1f3af" + }, + ":dash:": { + "category": "nature", + "name": "dash symbol", + "unicode": "1f4a8" + }, + ":date:": { + "category": "objects", + "name": "calendar", + "unicode": "1f4c5" + }, + ":deciduous_tree:": { + "category": "nature", + "name": "deciduous tree", + "unicode": "1f333" + }, + ":deer:": { + "category": "nature", + "name": "deer", + "unicode": "1f98c" + }, + ":department_store:": { + "category": "travel", + "name": "department store", + "unicode": "1f3ec" + }, + ":desert:": { + "category": "travel", + "name": "desert", + "unicode": "1f3dc", + "unicode_alt": "1f3dc-fe0f" + }, + ":desktop:": { + "category": "objects", + "name": "desktop computer", + "unicode": "1f5a5", + "unicode_alt": "1f5a5-fe0f" + }, + ":diamond_shape_with_a_dot_inside:": { + "category": "symbols", + "name": "diamond shape with a dot inside", + "unicode": "1f4a0" + }, + ":diamonds:": { + "category": "symbols", + "name": "black diamond suit", + "unicode": "2666", + "unicode_alt": "2666-fe0f" + }, + ":disappointed:": { + "category": "people", + "name": "disappointed face", + "unicode": "1f61e" + }, + ":disappointed_relieved:": { + "category": "people", + "name": "disappointed but relieved face", + "unicode": "1f625" + }, + ":dividers:": { + "category": "objects", + "name": "card index dividers", + "unicode": "1f5c2", + "unicode_alt": "1f5c2-fe0f" + }, + ":dizzy:": { + "category": "symbols", + "name": "dizzy symbol", + "unicode": "1f4ab" + }, + ":dizzy_face:": { + "category": "people", + "name": "dizzy face", + "unicode": "1f635" + }, + ":do_not_litter:": { + "category": "symbols", + "name": "do not litter symbol", + "unicode": "1f6af" + }, + ":dog2:": { + "category": "nature", + "name": "dog", + "unicode": "1f415" + }, + ":dog:": { + "category": "nature", + "name": "dog face", + "unicode": "1f436" + }, + ":dollar:": { + "category": "objects", + "name": "banknote with dollar sign", + "unicode": "1f4b5" + }, + ":dolls:": { + "category": "objects", + "name": "japanese dolls", + "unicode": "1f38e" + }, + ":dolphin:": { + "category": "nature", + "name": "dolphin", + "unicode": "1f42c" + }, + ":door:": { + "category": "objects", + "name": "door", + "unicode": "1f6aa" + }, + ":doughnut:": { + "category": "food", + "name": "doughnut", + "unicode": "1f369" + }, + ":dove:": { + "category": "nature", + "name": "dove of peace", + "unicode": "1f54a", + "unicode_alt": "1f54a-fe0f" + }, + ":dragon:": { + "category": "nature", + "name": "dragon", + "unicode": "1f409" + }, + ":dragon_face:": { + "category": "nature", + "name": "dragon face", + "unicode": "1f432" + }, + ":dress:": { + "category": "people", + "name": "dress", + "unicode": "1f457" + }, + ":dromedary_camel:": { + "category": "nature", + "name": "dromedary camel", + "unicode": "1f42a" + }, + ":drooling_face:": { + "category": "people", + "name": "drooling face", + "unicode": "1f924" + }, + ":droplet:": { + "category": "nature", + "name": "droplet", + "unicode": "1f4a7" + }, + ":drum:": { + "category": "activity", + "name": "drum with drumsticks", + "unicode": "1f941" + }, + ":duck:": { + "category": "nature", + "name": "duck", + "unicode": "1f986" + }, + ":dvd:": { + "category": "objects", + "name": "dvd", + "unicode": "1f4c0" + }, + ":e-mail:": { + "category": "objects", + "name": "e-mail symbol", + "unicode": "1f4e7" + }, + ":eagle:": { + "category": "nature", + "name": "eagle", + "unicode": "1f985" + }, + ":ear:": { + "category": "people", + "name": "ear", + "unicode": "1f442" + }, + ":ear_of_rice:": { + "category": "nature", + "name": "ear of rice", + "unicode": "1f33e" + }, + ":ear_tone1:": { + "category": "people", + "name": "ear tone 1", + "unicode": "1f442-1f3fb" + }, + ":ear_tone2:": { + "category": "people", + "name": "ear tone 2", + "unicode": "1f442-1f3fc" + }, + ":ear_tone3:": { + "category": "people", + "name": "ear tone 3", + "unicode": "1f442-1f3fd" + }, + ":ear_tone4:": { + "category": "people", + "name": "ear tone 4", + "unicode": "1f442-1f3fe" + }, + ":ear_tone5:": { + "category": "people", + "name": "ear tone 5", + "unicode": "1f442-1f3ff" + }, + ":earth_africa:": { + "category": "nature", + "name": "earth globe europe-africa", + "unicode": "1f30d" + }, + ":earth_americas:": { + "category": "nature", + "name": "earth globe americas", + "unicode": "1f30e" + }, + ":earth_asia:": { + "category": "nature", + "name": "earth globe asia-australia", + "unicode": "1f30f" + }, + ":egg:": { + "category": "food", + "name": "egg", + "unicode": "1f95a" + }, + ":eggplant:": { + "category": "food", + "name": "aubergine", + "unicode": "1f346" + }, + ":eight:": { + "category": "symbols", + "name": "keycap digit eight", + "unicode": "0038-20e3", + "unicode_alt": "0038-fe0f-20e3" + }, + ":eight_pointed_black_star:": { + "category": "symbols", + "name": "eight pointed black star", + "unicode": "2734", + "unicode_alt": "2734-fe0f" + }, + ":eight_spoked_asterisk:": { + "category": "symbols", + "name": "eight spoked asterisk", + "unicode": "2733", + "unicode_alt": "2733-fe0f" + }, + ":eject:": { + "category": "symbols", + "name": "eject symbol", + "unicode": "23cf", + "unicode_alt": "23cf-fe0f" + }, + ":electric_plug:": { + "category": "objects", + "name": "electric plug", + "unicode": "1f50c" + }, + ":elephant:": { + "category": "nature", + "name": "elephant", + "unicode": "1f418" + }, + ":end:": { + "category": "symbols", + "name": "end with leftwards arrow above", + "unicode": "1f51a" + }, + ":envelope:": { + "category": "objects", + "name": "envelope", + "unicode": "2709", + "unicode_alt": "2709-fe0f" + }, + ":envelope_with_arrow:": { + "category": "objects", + "name": "envelope with downwards arrow above", + "unicode": "1f4e9" + }, + ":euro:": { + "category": "objects", + "name": "banknote with euro sign", + "unicode": "1f4b6" + }, + ":european_castle:": { + "category": "travel", + "name": "european castle", + "unicode": "1f3f0" + }, + ":european_post_office:": { + "category": "travel", + "name": "european post office", + "unicode": "1f3e4" + }, + ":evergreen_tree:": { + "category": "nature", + "name": "evergreen tree", + "unicode": "1f332" + }, + ":exclamation:": { + "category": "symbols", + "name": "heavy exclamation mark symbol", + "unicode": "2757", + "unicode_alt": "2757-fe0f" + }, + ":expressionless:": { + "category": "people", + "name": "expressionless face", + "unicode": "1f611" + }, + ":eye:": { + "category": "people", + "name": "eye", + "unicode": "1f441", + "unicode_alt": "1f441-fe0f" + }, + ":eye_in_speech_bubble:": { + "category": "symbols", + "name": "eye in speech bubble", + "unicode": "1f441-1f5e8", + "unicode_alt": "1f441-200d-1f5e8" + }, + ":eyeglasses:": { + "category": "people", + "name": "eyeglasses", + "unicode": "1f453" + }, + ":eyes:": { + "category": "people", + "name": "eyes", + "unicode": "1f440" + }, + ":face_palm:": { + "category": "people", + "name": "face palm", + "unicode": "1f926" + }, + ":face_palm_tone1:": { + "category": "people", + "name": "face palm tone 1", + "unicode": "1f926-1f3fb" + }, + ":face_palm_tone2:": { + "category": "people", + "name": "face palm tone 2", + "unicode": "1f926-1f3fc" + }, + ":face_palm_tone3:": { + "category": "people", + "name": "face palm tone 3", + "unicode": "1f926-1f3fd" + }, + ":face_palm_tone4:": { + "category": "people", + "name": "face palm tone 4", + "unicode": "1f926-1f3fe" + }, + ":face_palm_tone5:": { + "category": "people", + "name": "face palm tone 5", + "unicode": "1f926-1f3ff" + }, + ":factory:": { + "category": "travel", + "name": "factory", + "unicode": "1f3ed" + }, + ":fallen_leaf:": { + "category": "nature", + "name": "fallen leaf", + "unicode": "1f342" + }, + ":family:": { + "category": "people", + "name": "family", + "unicode": "1f46a" + }, + ":family_mmb:": { + "category": "people", + "name": "family (man,man,boy)", + "unicode": "1f468-1f468-1f466", + "unicode_alt": "1f468-200d-1f468-200d-1f466" + }, + ":family_mmbb:": { + "category": "people", + "name": "family (man,man,boy,boy)", + "unicode": "1f468-1f468-1f466-1f466", + "unicode_alt": "1f468-200d-1f468-200d-1f466-200d-1f466" + }, + ":family_mmg:": { + "category": "people", + "name": "family (man,man,girl)", + "unicode": "1f468-1f468-1f467", + "unicode_alt": "1f468-200d-1f468-200d-1f467" + }, + ":family_mmgb:": { + "category": "people", + "name": "family (man,man,girl,boy)", + "unicode": "1f468-1f468-1f467-1f466", + "unicode_alt": "1f468-200d-1f468-200d-1f467-200d-1f466" + }, + ":family_mmgg:": { + "category": "people", + "name": "family (man,man,girl,girl)", + "unicode": "1f468-1f468-1f467-1f467", + "unicode_alt": "1f468-200d-1f468-200d-1f467-200d-1f467" + }, + ":family_mwbb:": { + "category": "people", + "name": "family (man,woman,boy,boy)", + "unicode": "1f468-1f469-1f466-1f466", + "unicode_alt": "1f468-200d-1f469-200d-1f466-200d-1f466" + }, + ":family_mwg:": { + "category": "people", + "name": "family (man,woman,girl)", + "unicode": "1f468-1f469-1f467", + "unicode_alt": "1f468-200d-1f469-200d-1f467" + }, + ":family_mwgb:": { + "category": "people", + "name": "family (man,woman,girl,boy)", + "unicode": "1f468-1f469-1f467-1f466", + "unicode_alt": "1f468-200d-1f469-200d-1f467-200d-1f466" + }, + ":family_mwgg:": { + "category": "people", + "name": "family (man,woman,girl,girl)", + "unicode": "1f468-1f469-1f467-1f467", + "unicode_alt": "1f468-200d-1f469-200d-1f467-200d-1f467" + }, + ":family_wwb:": { + "category": "people", + "name": "family (woman,woman,boy)", + "unicode": "1f469-1f469-1f466", + "unicode_alt": "1f469-200d-1f469-200d-1f466" + }, + ":family_wwbb:": { + "category": "people", + "name": "family (woman,woman,boy,boy)", + "unicode": "1f469-1f469-1f466-1f466", + "unicode_alt": "1f469-200d-1f469-200d-1f466-200d-1f466" + }, + ":family_wwg:": { + "category": "people", + "name": "family (woman,woman,girl)", + "unicode": "1f469-1f469-1f467", + "unicode_alt": "1f469-200d-1f469-200d-1f467" + }, + ":family_wwgb:": { + "category": "people", + "name": "family (woman,woman,girl,boy)", + "unicode": "1f469-1f469-1f467-1f466", + "unicode_alt": "1f469-200d-1f469-200d-1f467-200d-1f466" + }, + ":family_wwgg:": { + "category": "people", + "name": "family (woman,woman,girl,girl)", + "unicode": "1f469-1f469-1f467-1f467", + "unicode_alt": "1f469-200d-1f469-200d-1f467-200d-1f467" + }, + ":fast_forward:": { + "category": "symbols", + "name": "black right-pointing double triangle", + "unicode": "23e9" + }, + ":fax:": { + "category": "objects", + "name": "fax machine", + "unicode": "1f4e0" + }, + ":fearful:": { + "category": "people", + "name": "fearful face", + "unicode": "1f628" + }, + ":feet:": { + "category": "nature", + "name": "paw prints", + "unicode": "1f43e" + }, + ":fencer:": { + "category": "activity", + "name": "fencer", + "unicode": "1f93a" + }, + ":ferris_wheel:": { + "category": "travel", + "name": "ferris wheel", + "unicode": "1f3a1" + }, + ":ferry:": { + "category": "travel", + "name": "ferry", + "unicode": "26f4", + "unicode_alt": "26f4-fe0f" + }, + ":field_hockey:": { + "category": "activity", + "name": "field hockey stick and ball", + "unicode": "1f3d1" + }, + ":file_cabinet:": { + "category": "objects", + "name": "file cabinet", + "unicode": "1f5c4", + "unicode_alt": "1f5c4-fe0f" + }, + ":file_folder:": { + "category": "objects", + "name": "file folder", + "unicode": "1f4c1" + }, + ":film_frames:": { + "category": "objects", + "name": "film frames", + "unicode": "1f39e", + "unicode_alt": "1f39e-fe0f" + }, + ":fingers_crossed:": { + "category": "people", + "name": "hand with first and index finger crossed", + "unicode": "1f91e" + }, + ":fingers_crossed_tone1:": { + "category": "people", + "name": "hand with index and middle fingers crossed tone 1", + "unicode": "1f91e-1f3fb" + }, + ":fingers_crossed_tone2:": { + "category": "people", + "name": "hand with index and middle fingers crossed tone 2", + "unicode": "1f91e-1f3fc" + }, + ":fingers_crossed_tone3:": { + "category": "people", + "name": "hand with index and middle fingers crossed tone 3", + "unicode": "1f91e-1f3fd" + }, + ":fingers_crossed_tone4:": { + "category": "people", + "name": "hand with index and middle fingers crossed tone 4", + "unicode": "1f91e-1f3fe" + }, + ":fingers_crossed_tone5:": { + "category": "people", + "name": "hand with index and middle fingers crossed tone 5", + "unicode": "1f91e-1f3ff" + }, + ":fire:": { + "category": "nature", + "name": "fire", + "unicode": "1f525" + }, + ":fire_engine:": { + "category": "travel", + "name": "fire engine", + "unicode": "1f692" + }, + ":fireworks:": { + "category": "travel", + "name": "fireworks", + "unicode": "1f386" + }, + ":first_place:": { + "category": "activity", + "name": "first place medal", + "unicode": "1f947" + }, + ":first_quarter_moon:": { + "category": "nature", + "name": "first quarter moon symbol", + "unicode": "1f313" + }, + ":first_quarter_moon_with_face:": { + "category": "nature", + "name": "first quarter moon with face", + "unicode": "1f31b" + }, + ":fish:": { + "category": "nature", + "name": "fish", + "unicode": "1f41f" + }, + ":fish_cake:": { + "category": "food", + "name": "fish cake with swirl design", + "unicode": "1f365" + }, + ":fishing_pole_and_fish:": { + "category": "activity", + "name": "fishing pole and fish", + "unicode": "1f3a3" + }, + ":fist:": { + "category": "people", + "name": "raised fist", + "unicode": "270a" + }, + ":fist_tone1:": { + "category": "people", + "name": "raised fist tone 1", + "unicode": "270a-1f3fb" + }, + ":fist_tone2:": { + "category": "people", + "name": "raised fist tone 2", + "unicode": "270a-1f3fc" + }, + ":fist_tone3:": { + "category": "people", + "name": "raised fist tone 3", + "unicode": "270a-1f3fd" + }, + ":fist_tone4:": { + "category": "people", + "name": "raised fist tone 4", + "unicode": "270a-1f3fe" + }, + ":fist_tone5:": { + "category": "people", + "name": "raised fist tone 5", + "unicode": "270a-1f3ff" + }, + ":five:": { + "category": "symbols", + "name": "keycap digit five", + "unicode": "0035-20e3", + "unicode_alt": "0035-fe0f-20e3" + }, + ":flag_ac:": { + "category": "flags", + "name": "ascension", + "unicode": "1f1e6-1f1e8" + }, + ":flag_ad:": { + "category": "flags", + "name": "andorra", + "unicode": "1f1e6-1f1e9" + }, + ":flag_ae:": { + "category": "flags", + "name": "the united arab emirates", + "unicode": "1f1e6-1f1ea" + }, + ":flag_af:": { + "category": "flags", + "name": "afghanistan", + "unicode": "1f1e6-1f1eb" + }, + ":flag_ag:": { + "category": "flags", + "name": "antigua and barbuda", + "unicode": "1f1e6-1f1ec" + }, + ":flag_ai:": { + "category": "flags", + "name": "anguilla", + "unicode": "1f1e6-1f1ee" + }, + ":flag_al:": { + "category": "flags", + "name": "albania", + "unicode": "1f1e6-1f1f1" + }, + ":flag_am:": { + "category": "flags", + "name": "armenia", + "unicode": "1f1e6-1f1f2" + }, + ":flag_ao:": { + "category": "flags", + "name": "angola", + "unicode": "1f1e6-1f1f4" + }, + ":flag_aq:": { + "category": "flags", + "name": "antarctica", + "unicode": "1f1e6-1f1f6" + }, + ":flag_ar:": { + "category": "flags", + "name": "argentina", + "unicode": "1f1e6-1f1f7" + }, + ":flag_as:": { + "category": "flags", + "name": "american samoa", + "unicode": "1f1e6-1f1f8" + }, + ":flag_at:": { + "category": "flags", + "name": "austria", + "unicode": "1f1e6-1f1f9" + }, + ":flag_au:": { + "category": "flags", + "name": "australia", + "unicode": "1f1e6-1f1fa" + }, + ":flag_aw:": { + "category": "flags", + "name": "aruba", + "unicode": "1f1e6-1f1fc" + }, + ":flag_ax:": { + "category": "flags", + "name": "\u00e5land islands", + "unicode": "1f1e6-1f1fd" + }, + ":flag_az:": { + "category": "flags", + "name": "azerbaijan", + "unicode": "1f1e6-1f1ff" + }, + ":flag_ba:": { + "category": "flags", + "name": "bosnia and herzegovina", + "unicode": "1f1e7-1f1e6" + }, + ":flag_bb:": { + "category": "flags", + "name": "barbados", + "unicode": "1f1e7-1f1e7" + }, + ":flag_bd:": { + "category": "flags", + "name": "bangladesh", + "unicode": "1f1e7-1f1e9" + }, + ":flag_be:": { + "category": "flags", + "name": "belgium", + "unicode": "1f1e7-1f1ea" + }, + ":flag_bf:": { + "category": "flags", + "name": "burkina faso", + "unicode": "1f1e7-1f1eb" + }, + ":flag_bg:": { + "category": "flags", + "name": "bulgaria", + "unicode": "1f1e7-1f1ec" + }, + ":flag_bh:": { + "category": "flags", + "name": "bahrain", + "unicode": "1f1e7-1f1ed" + }, + ":flag_bi:": { + "category": "flags", + "name": "burundi", + "unicode": "1f1e7-1f1ee" + }, + ":flag_bj:": { + "category": "flags", + "name": "benin", + "unicode": "1f1e7-1f1ef" + }, + ":flag_bl:": { + "category": "flags", + "name": "saint barth\u00e9lemy", + "unicode": "1f1e7-1f1f1" + }, + ":flag_black:": { + "category": "objects", + "name": "waving black flag", + "unicode": "1f3f4" + }, + ":flag_bm:": { + "category": "flags", + "name": "bermuda", + "unicode": "1f1e7-1f1f2" + }, + ":flag_bn:": { + "category": "flags", + "name": "brunei", + "unicode": "1f1e7-1f1f3" + }, + ":flag_bo:": { + "category": "flags", + "name": "bolivia", + "unicode": "1f1e7-1f1f4" + }, + ":flag_bq:": { + "category": "flags", + "name": "caribbean netherlands", + "unicode": "1f1e7-1f1f6" + }, + ":flag_br:": { + "category": "flags", + "name": "brazil", + "unicode": "1f1e7-1f1f7" + }, + ":flag_bs:": { + "category": "flags", + "name": "the bahamas", + "unicode": "1f1e7-1f1f8" + }, + ":flag_bt:": { + "category": "flags", + "name": "bhutan", + "unicode": "1f1e7-1f1f9" + }, + ":flag_bv:": { + "category": "flags", + "name": "bouvet island", + "unicode": "1f1e7-1f1fb" + }, + ":flag_bw:": { + "category": "flags", + "name": "botswana", + "unicode": "1f1e7-1f1fc" + }, + ":flag_by:": { + "category": "flags", + "name": "belarus", + "unicode": "1f1e7-1f1fe" + }, + ":flag_bz:": { + "category": "flags", + "name": "belize", + "unicode": "1f1e7-1f1ff" + }, + ":flag_ca:": { + "category": "flags", + "name": "canada", + "unicode": "1f1e8-1f1e6" + }, + ":flag_cc:": { + "category": "flags", + "name": "cocos (keeling) islands", + "unicode": "1f1e8-1f1e8" + }, + ":flag_cd:": { + "category": "flags", + "name": "the democratic republic of the congo", + "unicode": "1f1e8-1f1e9" + }, + ":flag_cf:": { + "category": "flags", + "name": "central african republic", + "unicode": "1f1e8-1f1eb" + }, + ":flag_cg:": { + "category": "flags", + "name": "the republic of the congo", + "unicode": "1f1e8-1f1ec" + }, + ":flag_ch:": { + "category": "flags", + "name": "switzerland", + "unicode": "1f1e8-1f1ed" + }, + ":flag_ci:": { + "category": "flags", + "name": "c\u00f4te d\u2019ivoire", + "unicode": "1f1e8-1f1ee" + }, + ":flag_ck:": { + "category": "flags", + "name": "cook islands", + "unicode": "1f1e8-1f1f0" + }, + ":flag_cl:": { + "category": "flags", + "name": "chile", + "unicode": "1f1e8-1f1f1" + }, + ":flag_cm:": { + "category": "flags", + "name": "cameroon", + "unicode": "1f1e8-1f1f2" + }, + ":flag_cn:": { + "category": "flags", + "name": "china", + "unicode": "1f1e8-1f1f3" + }, + ":flag_co:": { + "category": "flags", + "name": "colombia", + "unicode": "1f1e8-1f1f4" + }, + ":flag_cp:": { + "category": "flags", + "name": "clipperton island", + "unicode": "1f1e8-1f1f5" + }, + ":flag_cr:": { + "category": "flags", + "name": "costa rica", + "unicode": "1f1e8-1f1f7" + }, + ":flag_cu:": { + "category": "flags", + "name": "cuba", + "unicode": "1f1e8-1f1fa" + }, + ":flag_cv:": { + "category": "flags", + "name": "cape verde", + "unicode": "1f1e8-1f1fb" + }, + ":flag_cw:": { + "category": "flags", + "name": "cura\u00e7ao", + "unicode": "1f1e8-1f1fc" + }, + ":flag_cx:": { + "category": "flags", + "name": "christmas island", + "unicode": "1f1e8-1f1fd" + }, + ":flag_cy:": { + "category": "flags", + "name": "cyprus", + "unicode": "1f1e8-1f1fe" + }, + ":flag_cz:": { + "category": "flags", + "name": "the czech republic", + "unicode": "1f1e8-1f1ff" + }, + ":flag_de:": { + "category": "flags", + "name": "germany", + "unicode": "1f1e9-1f1ea" + }, + ":flag_dg:": { + "category": "flags", + "name": "diego garcia", + "unicode": "1f1e9-1f1ec" + }, + ":flag_dj:": { + "category": "flags", + "name": "djibouti", + "unicode": "1f1e9-1f1ef" + }, + ":flag_dk:": { + "category": "flags", + "name": "denmark", + "unicode": "1f1e9-1f1f0" + }, + ":flag_dm:": { + "category": "flags", + "name": "dominica", + "unicode": "1f1e9-1f1f2" + }, + ":flag_do:": { + "category": "flags", + "name": "the dominican republic", + "unicode": "1f1e9-1f1f4" + }, + ":flag_dz:": { + "category": "flags", + "name": "algeria", + "unicode": "1f1e9-1f1ff" + }, + ":flag_ea:": { + "category": "flags", + "name": "ceuta, melilla", + "unicode": "1f1ea-1f1e6" + }, + ":flag_ec:": { + "category": "flags", + "name": "ecuador", + "unicode": "1f1ea-1f1e8" + }, + ":flag_ee:": { + "category": "flags", + "name": "estonia", + "unicode": "1f1ea-1f1ea" + }, + ":flag_eg:": { + "category": "flags", + "name": "egypt", + "unicode": "1f1ea-1f1ec" + }, + ":flag_eh:": { + "category": "flags", + "name": "western sahara", + "unicode": "1f1ea-1f1ed" + }, + ":flag_er:": { + "category": "flags", + "name": "eritrea", + "unicode": "1f1ea-1f1f7" + }, + ":flag_es:": { + "category": "flags", + "name": "spain", + "unicode": "1f1ea-1f1f8" + }, + ":flag_et:": { + "category": "flags", + "name": "ethiopia", + "unicode": "1f1ea-1f1f9" + }, + ":flag_eu:": { + "category": "flags", + "name": "european union", + "unicode": "1f1ea-1f1fa" + }, + ":flag_fi:": { + "category": "flags", + "name": "finland", + "unicode": "1f1eb-1f1ee" + }, + ":flag_fj:": { + "category": "flags", + "name": "fiji", + "unicode": "1f1eb-1f1ef" + }, + ":flag_fk:": { + "category": "flags", + "name": "falkland islands", + "unicode": "1f1eb-1f1f0" + }, + ":flag_fm:": { + "category": "flags", + "name": "micronesia", + "unicode": "1f1eb-1f1f2" + }, + ":flag_fo:": { + "category": "flags", + "name": "faroe islands", + "unicode": "1f1eb-1f1f4" + }, + ":flag_fr:": { + "category": "flags", + "name": "france", + "unicode": "1f1eb-1f1f7" + }, + ":flag_ga:": { + "category": "flags", + "name": "gabon", + "unicode": "1f1ec-1f1e6" + }, + ":flag_gb:": { + "category": "flags", + "name": "great britain", + "unicode": "1f1ec-1f1e7" + }, + ":flag_gd:": { + "category": "flags", + "name": "grenada", + "unicode": "1f1ec-1f1e9" + }, + ":flag_ge:": { + "category": "flags", + "name": "georgia", + "unicode": "1f1ec-1f1ea" + }, + ":flag_gf:": { + "category": "flags", + "name": "french guiana", + "unicode": "1f1ec-1f1eb" + }, + ":flag_gg:": { + "category": "flags", + "name": "guernsey", + "unicode": "1f1ec-1f1ec" + }, + ":flag_gh:": { + "category": "flags", + "name": "ghana", + "unicode": "1f1ec-1f1ed" + }, + ":flag_gi:": { + "category": "flags", + "name": "gibraltar", + "unicode": "1f1ec-1f1ee" + }, + ":flag_gl:": { + "category": "flags", + "name": "greenland", + "unicode": "1f1ec-1f1f1" + }, + ":flag_gm:": { + "category": "flags", + "name": "the gambia", + "unicode": "1f1ec-1f1f2" + }, + ":flag_gn:": { + "category": "flags", + "name": "guinea", + "unicode": "1f1ec-1f1f3" + }, + ":flag_gp:": { + "category": "flags", + "name": "guadeloupe", + "unicode": "1f1ec-1f1f5" + }, + ":flag_gq:": { + "category": "flags", + "name": "equatorial guinea", + "unicode": "1f1ec-1f1f6" + }, + ":flag_gr:": { + "category": "flags", + "name": "greece", + "unicode": "1f1ec-1f1f7" + }, + ":flag_gs:": { + "category": "flags", + "name": "south georgia", + "unicode": "1f1ec-1f1f8" + }, + ":flag_gt:": { + "category": "flags", + "name": "guatemala", + "unicode": "1f1ec-1f1f9" + }, + ":flag_gu:": { + "category": "flags", + "name": "guam", + "unicode": "1f1ec-1f1fa" + }, + ":flag_gw:": { + "category": "flags", + "name": "guinea-bissau", + "unicode": "1f1ec-1f1fc" + }, + ":flag_gy:": { + "category": "flags", + "name": "guyana", + "unicode": "1f1ec-1f1fe" + }, + ":flag_hk:": { + "category": "flags", + "name": "hong kong", + "unicode": "1f1ed-1f1f0" + }, + ":flag_hm:": { + "category": "flags", + "name": "heard island and mcdonald islands", + "unicode": "1f1ed-1f1f2" + }, + ":flag_hn:": { + "category": "flags", + "name": "honduras", + "unicode": "1f1ed-1f1f3" + }, + ":flag_hr:": { + "category": "flags", + "name": "croatia", + "unicode": "1f1ed-1f1f7" + }, + ":flag_ht:": { + "category": "flags", + "name": "haiti", + "unicode": "1f1ed-1f1f9" + }, + ":flag_hu:": { + "category": "flags", + "name": "hungary", + "unicode": "1f1ed-1f1fa" + }, + ":flag_ic:": { + "category": "flags", + "name": "canary islands", + "unicode": "1f1ee-1f1e8" + }, + ":flag_id:": { + "category": "flags", + "name": "indonesia", + "unicode": "1f1ee-1f1e9" + }, + ":flag_ie:": { + "category": "flags", + "name": "ireland", + "unicode": "1f1ee-1f1ea" + }, + ":flag_il:": { + "category": "flags", + "name": "israel", + "unicode": "1f1ee-1f1f1" + }, + ":flag_im:": { + "category": "flags", + "name": "isle of man", + "unicode": "1f1ee-1f1f2" + }, + ":flag_in:": { + "category": "flags", + "name": "india", + "unicode": "1f1ee-1f1f3" + }, + ":flag_io:": { + "category": "flags", + "name": "british indian ocean territory", + "unicode": "1f1ee-1f1f4" + }, + ":flag_iq:": { + "category": "flags", + "name": "iraq", + "unicode": "1f1ee-1f1f6" + }, + ":flag_ir:": { + "category": "flags", + "name": "iran", + "unicode": "1f1ee-1f1f7" + }, + ":flag_is:": { + "category": "flags", + "name": "iceland", + "unicode": "1f1ee-1f1f8" + }, + ":flag_it:": { + "category": "flags", + "name": "italy", + "unicode": "1f1ee-1f1f9" + }, + ":flag_je:": { + "category": "flags", + "name": "jersey", + "unicode": "1f1ef-1f1ea" + }, + ":flag_jm:": { + "category": "flags", + "name": "jamaica", + "unicode": "1f1ef-1f1f2" + }, + ":flag_jo:": { + "category": "flags", + "name": "jordan", + "unicode": "1f1ef-1f1f4" + }, + ":flag_jp:": { + "category": "flags", + "name": "japan", + "unicode": "1f1ef-1f1f5" + }, + ":flag_ke:": { + "category": "flags", + "name": "kenya", + "unicode": "1f1f0-1f1ea" + }, + ":flag_kg:": { + "category": "flags", + "name": "kyrgyzstan", + "unicode": "1f1f0-1f1ec" + }, + ":flag_kh:": { + "category": "flags", + "name": "cambodia", + "unicode": "1f1f0-1f1ed" + }, + ":flag_ki:": { + "category": "flags", + "name": "kiribati", + "unicode": "1f1f0-1f1ee" + }, + ":flag_km:": { + "category": "flags", + "name": "the comoros", + "unicode": "1f1f0-1f1f2" + }, + ":flag_kn:": { + "category": "flags", + "name": "saint kitts and nevis", + "unicode": "1f1f0-1f1f3" + }, + ":flag_kp:": { + "category": "flags", + "name": "north korea", + "unicode": "1f1f0-1f1f5" + }, + ":flag_kr:": { + "category": "flags", + "name": "korea", + "unicode": "1f1f0-1f1f7" + }, + ":flag_kw:": { + "category": "flags", + "name": "kuwait", + "unicode": "1f1f0-1f1fc" + }, + ":flag_ky:": { + "category": "flags", + "name": "cayman islands", + "unicode": "1f1f0-1f1fe" + }, + ":flag_kz:": { + "category": "flags", + "name": "kazakhstan", + "unicode": "1f1f0-1f1ff" + }, + ":flag_la:": { + "category": "flags", + "name": "laos", + "unicode": "1f1f1-1f1e6" + }, + ":flag_lb:": { + "category": "flags", + "name": "lebanon", + "unicode": "1f1f1-1f1e7" + }, + ":flag_lc:": { + "category": "flags", + "name": "saint lucia", + "unicode": "1f1f1-1f1e8" + }, + ":flag_li:": { + "category": "flags", + "name": "liechtenstein", + "unicode": "1f1f1-1f1ee" + }, + ":flag_lk:": { + "category": "flags", + "name": "sri lanka", + "unicode": "1f1f1-1f1f0" + }, + ":flag_lr:": { + "category": "flags", + "name": "liberia", + "unicode": "1f1f1-1f1f7" + }, + ":flag_ls:": { + "category": "flags", + "name": "lesotho", + "unicode": "1f1f1-1f1f8" + }, + ":flag_lt:": { + "category": "flags", + "name": "lithuania", + "unicode": "1f1f1-1f1f9" + }, + ":flag_lu:": { + "category": "flags", + "name": "luxembourg", + "unicode": "1f1f1-1f1fa" + }, + ":flag_lv:": { + "category": "flags", + "name": "latvia", + "unicode": "1f1f1-1f1fb" + }, + ":flag_ly:": { + "category": "flags", + "name": "libya", + "unicode": "1f1f1-1f1fe" + }, + ":flag_ma:": { + "category": "flags", + "name": "morocco", + "unicode": "1f1f2-1f1e6" + }, + ":flag_mc:": { + "category": "flags", + "name": "monaco", + "unicode": "1f1f2-1f1e8" + }, + ":flag_md:": { + "category": "flags", + "name": "moldova", + "unicode": "1f1f2-1f1e9" + }, + ":flag_me:": { + "category": "flags", + "name": "montenegro", + "unicode": "1f1f2-1f1ea" + }, + ":flag_mf:": { + "category": "flags", + "name": "saint martin", + "unicode": "1f1f2-1f1eb" + }, + ":flag_mg:": { + "category": "flags", + "name": "madagascar", + "unicode": "1f1f2-1f1ec" + }, + ":flag_mh:": { + "category": "flags", + "name": "the marshall islands", + "unicode": "1f1f2-1f1ed" + }, + ":flag_mk:": { + "category": "flags", + "name": "macedonia", + "unicode": "1f1f2-1f1f0" + }, + ":flag_ml:": { + "category": "flags", + "name": "mali", + "unicode": "1f1f2-1f1f1" + }, + ":flag_mm:": { + "category": "flags", + "name": "myanmar", + "unicode": "1f1f2-1f1f2" + }, + ":flag_mn:": { + "category": "flags", + "name": "mongolia", + "unicode": "1f1f2-1f1f3" + }, + ":flag_mo:": { + "category": "flags", + "name": "macau", + "unicode": "1f1f2-1f1f4" + }, + ":flag_mp:": { + "category": "flags", + "name": "northern mariana islands", + "unicode": "1f1f2-1f1f5" + }, + ":flag_mq:": { + "category": "flags", + "name": "martinique", + "unicode": "1f1f2-1f1f6" + }, + ":flag_mr:": { + "category": "flags", + "name": "mauritania", + "unicode": "1f1f2-1f1f7" + }, + ":flag_ms:": { + "category": "flags", + "name": "montserrat", + "unicode": "1f1f2-1f1f8" + }, + ":flag_mt:": { + "category": "flags", + "name": "malta", + "unicode": "1f1f2-1f1f9" + }, + ":flag_mu:": { + "category": "flags", + "name": "mauritius", + "unicode": "1f1f2-1f1fa" + }, + ":flag_mv:": { + "category": "flags", + "name": "maldives", + "unicode": "1f1f2-1f1fb" + }, + ":flag_mw:": { + "category": "flags", + "name": "malawi", + "unicode": "1f1f2-1f1fc" + }, + ":flag_mx:": { + "category": "flags", + "name": "mexico", + "unicode": "1f1f2-1f1fd" + }, + ":flag_my:": { + "category": "flags", + "name": "malaysia", + "unicode": "1f1f2-1f1fe" + }, + ":flag_mz:": { + "category": "flags", + "name": "mozambique", + "unicode": "1f1f2-1f1ff" + }, + ":flag_na:": { + "category": "flags", + "name": "namibia", + "unicode": "1f1f3-1f1e6" + }, + ":flag_nc:": { + "category": "flags", + "name": "new caledonia", + "unicode": "1f1f3-1f1e8" + }, + ":flag_ne:": { + "category": "flags", + "name": "niger", + "unicode": "1f1f3-1f1ea" + }, + ":flag_nf:": { + "category": "flags", + "name": "norfolk island", + "unicode": "1f1f3-1f1eb" + }, + ":flag_ng:": { + "category": "flags", + "name": "nigeria", + "unicode": "1f1f3-1f1ec" + }, + ":flag_ni:": { + "category": "flags", + "name": "nicaragua", + "unicode": "1f1f3-1f1ee" + }, + ":flag_nl:": { + "category": "flags", + "name": "the netherlands", + "unicode": "1f1f3-1f1f1" + }, + ":flag_no:": { + "category": "flags", + "name": "norway", + "unicode": "1f1f3-1f1f4" + }, + ":flag_np:": { + "category": "flags", + "name": "nepal", + "unicode": "1f1f3-1f1f5" + }, + ":flag_nr:": { + "category": "flags", + "name": "nauru", + "unicode": "1f1f3-1f1f7" + }, + ":flag_nu:": { + "category": "flags", + "name": "niue", + "unicode": "1f1f3-1f1fa" + }, + ":flag_nz:": { + "category": "flags", + "name": "new zealand", + "unicode": "1f1f3-1f1ff" + }, + ":flag_om:": { + "category": "flags", + "name": "oman", + "unicode": "1f1f4-1f1f2" + }, + ":flag_pa:": { + "category": "flags", + "name": "panama", + "unicode": "1f1f5-1f1e6" + }, + ":flag_pe:": { + "category": "flags", + "name": "peru", + "unicode": "1f1f5-1f1ea" + }, + ":flag_pf:": { + "category": "flags", + "name": "french polynesia", + "unicode": "1f1f5-1f1eb" + }, + ":flag_pg:": { + "category": "flags", + "name": "papua new guinea", + "unicode": "1f1f5-1f1ec" + }, + ":flag_ph:": { + "category": "flags", + "name": "the philippines", + "unicode": "1f1f5-1f1ed" + }, + ":flag_pk:": { + "category": "flags", + "name": "pakistan", + "unicode": "1f1f5-1f1f0" + }, + ":flag_pl:": { + "category": "flags", + "name": "poland", + "unicode": "1f1f5-1f1f1" + }, + ":flag_pm:": { + "category": "flags", + "name": "saint pierre and miquelon", + "unicode": "1f1f5-1f1f2" + }, + ":flag_pn:": { + "category": "flags", + "name": "pitcairn", + "unicode": "1f1f5-1f1f3" + }, + ":flag_pr:": { + "category": "flags", + "name": "puerto rico", + "unicode": "1f1f5-1f1f7" + }, + ":flag_ps:": { + "category": "flags", + "name": "palestinian authority", + "unicode": "1f1f5-1f1f8" + }, + ":flag_pt:": { + "category": "flags", + "name": "portugal", + "unicode": "1f1f5-1f1f9" + }, + ":flag_pw:": { + "category": "flags", + "name": "palau", + "unicode": "1f1f5-1f1fc" + }, + ":flag_py:": { + "category": "flags", + "name": "paraguay", + "unicode": "1f1f5-1f1fe" + }, + ":flag_qa:": { + "category": "flags", + "name": "qatar", + "unicode": "1f1f6-1f1e6" + }, + ":flag_re:": { + "category": "flags", + "name": "r\u00e9union", + "unicode": "1f1f7-1f1ea" + }, + ":flag_ro:": { + "category": "flags", + "name": "romania", + "unicode": "1f1f7-1f1f4" + }, + ":flag_rs:": { + "category": "flags", + "name": "serbia", + "unicode": "1f1f7-1f1f8" + }, + ":flag_ru:": { + "category": "flags", + "name": "russia", + "unicode": "1f1f7-1f1fa" + }, + ":flag_rw:": { + "category": "flags", + "name": "rwanda", + "unicode": "1f1f7-1f1fc" + }, + ":flag_sa:": { + "category": "flags", + "name": "saudi arabia", + "unicode": "1f1f8-1f1e6" + }, + ":flag_sb:": { + "category": "flags", + "name": "the solomon islands", + "unicode": "1f1f8-1f1e7" + }, + ":flag_sc:": { + "category": "flags", + "name": "the seychelles", + "unicode": "1f1f8-1f1e8" + }, + ":flag_sd:": { + "category": "flags", + "name": "sudan", + "unicode": "1f1f8-1f1e9" + }, + ":flag_se:": { + "category": "flags", + "name": "sweden", + "unicode": "1f1f8-1f1ea" + }, + ":flag_sg:": { + "category": "flags", + "name": "singapore", + "unicode": "1f1f8-1f1ec" + }, + ":flag_sh:": { + "category": "flags", + "name": "saint helena", + "unicode": "1f1f8-1f1ed" + }, + ":flag_si:": { + "category": "flags", + "name": "slovenia", + "unicode": "1f1f8-1f1ee" + }, + ":flag_sj:": { + "category": "flags", + "name": "svalbard and jan mayen", + "unicode": "1f1f8-1f1ef" + }, + ":flag_sk:": { + "category": "flags", + "name": "slovakia", + "unicode": "1f1f8-1f1f0" + }, + ":flag_sl:": { + "category": "flags", + "name": "sierra leone", + "unicode": "1f1f8-1f1f1" + }, + ":flag_sm:": { + "category": "flags", + "name": "san marino", + "unicode": "1f1f8-1f1f2" + }, + ":flag_sn:": { + "category": "flags", + "name": "senegal", + "unicode": "1f1f8-1f1f3" + }, + ":flag_so:": { + "category": "flags", + "name": "somalia", + "unicode": "1f1f8-1f1f4" + }, + ":flag_sr:": { + "category": "flags", + "name": "suriname", + "unicode": "1f1f8-1f1f7" + }, + ":flag_ss:": { + "category": "flags", + "name": "south sudan", + "unicode": "1f1f8-1f1f8" + }, + ":flag_st:": { + "category": "flags", + "name": "s\u00e3o tom\u00e9 and pr\u00edncipe", + "unicode": "1f1f8-1f1f9" + }, + ":flag_sv:": { + "category": "flags", + "name": "el salvador", + "unicode": "1f1f8-1f1fb" + }, + ":flag_sx:": { + "category": "flags", + "name": "sint maarten", + "unicode": "1f1f8-1f1fd" + }, + ":flag_sy:": { + "category": "flags", + "name": "syria", + "unicode": "1f1f8-1f1fe" + }, + ":flag_sz:": { + "category": "flags", + "name": "swaziland", + "unicode": "1f1f8-1f1ff" + }, + ":flag_ta:": { + "category": "flags", + "name": "tristan da cunha", + "unicode": "1f1f9-1f1e6" + }, + ":flag_tc:": { + "category": "flags", + "name": "turks and caicos islands", + "unicode": "1f1f9-1f1e8" + }, + ":flag_td:": { + "category": "flags", + "name": "chad", + "unicode": "1f1f9-1f1e9" + }, + ":flag_tf:": { + "category": "flags", + "name": "french southern territories", + "unicode": "1f1f9-1f1eb" + }, + ":flag_tg:": { + "category": "flags", + "name": "togo", + "unicode": "1f1f9-1f1ec" + }, + ":flag_th:": { + "category": "flags", + "name": "thailand", + "unicode": "1f1f9-1f1ed" + }, + ":flag_tj:": { + "category": "flags", + "name": "tajikistan", + "unicode": "1f1f9-1f1ef" + }, + ":flag_tk:": { + "category": "flags", + "name": "tokelau", + "unicode": "1f1f9-1f1f0" + }, + ":flag_tl:": { + "category": "flags", + "name": "timor-leste", + "unicode": "1f1f9-1f1f1" + }, + ":flag_tm:": { + "category": "flags", + "name": "turkmenistan", + "unicode": "1f1f9-1f1f2" + }, + ":flag_tn:": { + "category": "flags", + "name": "tunisia", + "unicode": "1f1f9-1f1f3" + }, + ":flag_to:": { + "category": "flags", + "name": "tonga", + "unicode": "1f1f9-1f1f4" + }, + ":flag_tr:": { + "category": "flags", + "name": "turkey", + "unicode": "1f1f9-1f1f7" + }, + ":flag_tt:": { + "category": "flags", + "name": "trinidad and tobago", + "unicode": "1f1f9-1f1f9" + }, + ":flag_tv:": { + "category": "flags", + "name": "tuvalu", + "unicode": "1f1f9-1f1fb" + }, + ":flag_tw:": { + "category": "flags", + "name": "the republic of china", + "unicode": "1f1f9-1f1fc" + }, + ":flag_tz:": { + "category": "flags", + "name": "tanzania", + "unicode": "1f1f9-1f1ff" + }, + ":flag_ua:": { + "category": "flags", + "name": "ukraine", + "unicode": "1f1fa-1f1e6" + }, + ":flag_ug:": { + "category": "flags", + "name": "uganda", + "unicode": "1f1fa-1f1ec" + }, + ":flag_um:": { + "category": "flags", + "name": "united states minor outlying islands", + "unicode": "1f1fa-1f1f2" + }, + ":flag_us:": { + "category": "flags", + "name": "united states", + "unicode": "1f1fa-1f1f8" + }, + ":flag_uy:": { + "category": "flags", + "name": "uruguay", + "unicode": "1f1fa-1f1fe" + }, + ":flag_uz:": { + "category": "flags", + "name": "uzbekistan", + "unicode": "1f1fa-1f1ff" + }, + ":flag_va:": { + "category": "flags", + "name": "the vatican city", + "unicode": "1f1fb-1f1e6" + }, + ":flag_vc:": { + "category": "flags", + "name": "saint vincent and the grenadines", + "unicode": "1f1fb-1f1e8" + }, + ":flag_ve:": { + "category": "flags", + "name": "venezuela", + "unicode": "1f1fb-1f1ea" + }, + ":flag_vg:": { + "category": "flags", + "name": "british virgin islands", + "unicode": "1f1fb-1f1ec" + }, + ":flag_vi:": { + "category": "flags", + "name": "u.s. virgin islands", + "unicode": "1f1fb-1f1ee" + }, + ":flag_vn:": { + "category": "flags", + "name": "vietnam", + "unicode": "1f1fb-1f1f3" + }, + ":flag_vu:": { + "category": "flags", + "name": "vanuatu", + "unicode": "1f1fb-1f1fa" + }, + ":flag_wf:": { + "category": "flags", + "name": "wallis and futuna", + "unicode": "1f1fc-1f1eb" + }, + ":flag_white:": { + "category": "objects", + "name": "waving white flag", + "unicode": "1f3f3", + "unicode_alt": "1f3f3-fe0f" + }, + ":flag_ws:": { + "category": "flags", + "name": "samoa", + "unicode": "1f1fc-1f1f8" + }, + ":flag_xk:": { + "category": "flags", + "name": "kosovo", + "unicode": "1f1fd-1f1f0" + }, + ":flag_ye:": { + "category": "flags", + "name": "yemen", + "unicode": "1f1fe-1f1ea" + }, + ":flag_yt:": { + "category": "flags", + "name": "mayotte", + "unicode": "1f1fe-1f1f9" + }, + ":flag_za:": { + "category": "flags", + "name": "south africa", + "unicode": "1f1ff-1f1e6" + }, + ":flag_zm:": { + "category": "flags", + "name": "zambia", + "unicode": "1f1ff-1f1f2" + }, + ":flag_zw:": { + "category": "flags", + "name": "zimbabwe", + "unicode": "1f1ff-1f1fc" + }, + ":flags:": { + "category": "objects", + "name": "carp streamer", + "unicode": "1f38f" + }, + ":flashlight:": { + "category": "objects", + "name": "electric torch", + "unicode": "1f526" + }, + ":fleur-de-lis:": { + "category": "symbols", + "name": "fleur-de-lis", + "unicode": "269c", + "unicode_alt": "269c-fe0f" + }, + ":floppy_disk:": { + "category": "objects", + "name": "floppy disk", + "unicode": "1f4be" + }, + ":flower_playing_cards:": { + "category": "symbols", + "name": "flower playing cards", + "unicode": "1f3b4" + }, + ":flushed:": { + "category": "people", + "name": "flushed face", + "unicode": "1f633" + }, + ":fog:": { + "category": "nature", + "name": "fog", + "unicode": "1f32b", + "unicode_alt": "1f32b-fe0f" + }, + ":foggy:": { + "category": "travel", + "name": "foggy", + "unicode": "1f301" + }, + ":football:": { + "category": "activity", + "name": "american football", + "unicode": "1f3c8" + }, + ":footprints:": { + "category": "people", + "name": "footprints", + "unicode": "1f463" + }, + ":fork_and_knife:": { + "category": "food", + "name": "fork and knife", + "unicode": "1f374" + }, + ":fork_knife_plate:": { + "category": "food", + "name": "fork and knife with plate", + "unicode": "1f37d", + "unicode_alt": "1f37d-fe0f" + }, + ":fountain:": { + "category": "travel", + "name": "fountain", + "unicode": "26f2", + "unicode_alt": "26f2-fe0f" + }, + ":four:": { + "category": "symbols", + "name": "keycap digit four", + "unicode": "0034-20e3", + "unicode_alt": "0034-fe0f-20e3" + }, + ":four_leaf_clover:": { + "category": "nature", + "name": "four leaf clover", + "unicode": "1f340" + }, + ":fox:": { + "category": "nature", + "name": "fox face", + "unicode": "1f98a" + }, + ":frame_photo:": { + "category": "objects", + "name": "frame with picture", + "unicode": "1f5bc", + "unicode_alt": "1f5bc-fe0f" + }, + ":free:": { + "category": "symbols", + "name": "squared free", + "unicode": "1f193" + }, + ":french_bread:": { + "category": "food", + "name": "baguette bread", + "unicode": "1f956" + }, + ":fried_shrimp:": { + "category": "food", + "name": "fried shrimp", + "unicode": "1f364" + }, + ":fries:": { + "category": "food", + "name": "french fries", + "unicode": "1f35f" + }, + ":frog:": { + "category": "nature", + "name": "frog face", + "unicode": "1f438" + }, + ":frowning2:": { + "category": "people", + "name": "white frowning face", + "unicode": "2639", + "unicode_alt": "2639-fe0f" + }, + ":frowning:": { + "category": "people", + "name": "frowning face with open mouth", + "unicode": "1f626" + }, + ":fuelpump:": { + "category": "travel", + "name": "fuel pump", + "unicode": "26fd", + "unicode_alt": "26fd-fe0f" + }, + ":full_moon:": { + "category": "nature", + "name": "full moon symbol", + "unicode": "1f315" + }, + ":full_moon_with_face:": { + "category": "nature", + "name": "full moon with face", + "unicode": "1f31d" + }, + ":game_die:": { + "category": "activity", + "name": "game die", + "unicode": "1f3b2" + }, + ":gear:": { + "category": "objects", + "name": "gear", + "unicode": "2699", + "unicode_alt": "2699-fe0f" + }, + ":gem:": { + "category": "objects", + "name": "gem stone", + "unicode": "1f48e" + }, + ":gemini:": { + "category": "symbols", + "name": "gemini", + "unicode": "264a", + "unicode_alt": "264a-fe0f" + }, + ":ghost:": { + "category": "people", + "name": "ghost", + "unicode": "1f47b" + }, + ":gift:": { + "category": "objects", + "name": "wrapped present", + "unicode": "1f381" + }, + ":gift_heart:": { + "category": "symbols", + "name": "heart with ribbon", + "unicode": "1f49d" + }, + ":girl:": { + "category": "people", + "name": "girl", + "unicode": "1f467" + }, + ":girl_tone1:": { + "category": "people", + "name": "girl tone 1", + "unicode": "1f467-1f3fb" + }, + ":girl_tone2:": { + "category": "people", + "name": "girl tone 2", + "unicode": "1f467-1f3fc" + }, + ":girl_tone3:": { + "category": "people", + "name": "girl tone 3", + "unicode": "1f467-1f3fd" + }, + ":girl_tone4:": { + "category": "people", + "name": "girl tone 4", + "unicode": "1f467-1f3fe" + }, + ":girl_tone5:": { + "category": "people", + "name": "girl tone 5", + "unicode": "1f467-1f3ff" + }, + ":globe_with_meridians:": { + "category": "symbols", + "name": "globe with meridians", + "unicode": "1f310" + }, + ":goal:": { + "category": "activity", + "name": "goal net", + "unicode": "1f945" + }, + ":goat:": { + "category": "nature", + "name": "goat", + "unicode": "1f410" + }, + ":golf:": { + "category": "activity", + "name": "flag in hole", + "unicode": "26f3", + "unicode_alt": "26f3-fe0f" + }, + ":golfer:": { + "category": "activity", + "name": "golfer", + "unicode": "1f3cc", + "unicode_alt": "1f3cc-fe0f" + }, + ":gorilla:": { + "category": "nature", + "name": "gorilla", + "unicode": "1f98d" + }, + ":grapes:": { + "category": "food", + "name": "grapes", + "unicode": "1f347" + }, + ":green_apple:": { + "category": "food", + "name": "green apple", + "unicode": "1f34f" + }, + ":green_book:": { + "category": "objects", + "name": "green book", + "unicode": "1f4d7" + }, + ":green_heart:": { + "category": "symbols", + "name": "green heart", + "unicode": "1f49a" + }, + ":grey_exclamation:": { + "category": "symbols", + "name": "white exclamation mark ornament", + "unicode": "2755" + }, + ":grey_question:": { + "category": "symbols", + "name": "white question mark ornament", + "unicode": "2754" + }, + ":grimacing:": { + "category": "people", + "name": "grimacing face", + "unicode": "1f62c" + }, + ":grin:": { + "category": "people", + "name": "grinning face with smiling eyes", + "unicode": "1f601" + }, + ":grinning:": { + "category": "people", + "name": "grinning face", + "unicode": "1f600" + }, + ":guardsman:": { + "category": "people", + "name": "guardsman", + "unicode": "1f482" + }, + ":guardsman_tone1:": { + "category": "people", + "name": "guardsman tone 1", + "unicode": "1f482-1f3fb" + }, + ":guardsman_tone2:": { + "category": "people", + "name": "guardsman tone 2", + "unicode": "1f482-1f3fc" + }, + ":guardsman_tone3:": { + "category": "people", + "name": "guardsman tone 3", + "unicode": "1f482-1f3fd" + }, + ":guardsman_tone4:": { + "category": "people", + "name": "guardsman tone 4", + "unicode": "1f482-1f3fe" + }, + ":guardsman_tone5:": { + "category": "people", + "name": "guardsman tone 5", + "unicode": "1f482-1f3ff" + }, + ":guitar:": { + "category": "activity", + "name": "guitar", + "unicode": "1f3b8" + }, + ":gun:": { + "category": "objects", + "name": "pistol", + "unicode": "1f52b" + }, + ":haircut:": { + "category": "people", + "name": "haircut", + "unicode": "1f487" + }, + ":haircut_tone1:": { + "category": "people", + "name": "haircut tone 1", + "unicode": "1f487-1f3fb" + }, + ":haircut_tone2:": { + "category": "people", + "name": "haircut tone 2", + "unicode": "1f487-1f3fc" + }, + ":haircut_tone3:": { + "category": "people", + "name": "haircut tone 3", + "unicode": "1f487-1f3fd" + }, + ":haircut_tone4:": { + "category": "people", + "name": "haircut tone 4", + "unicode": "1f487-1f3fe" + }, + ":haircut_tone5:": { + "category": "people", + "name": "haircut tone 5", + "unicode": "1f487-1f3ff" + }, + ":hamburger:": { + "category": "food", + "name": "hamburger", + "unicode": "1f354" + }, + ":hammer:": { + "category": "objects", + "name": "hammer", + "unicode": "1f528" + }, + ":hammer_pick:": { + "category": "objects", + "name": "hammer and pick", + "unicode": "2692", + "unicode_alt": "2692-fe0f" + }, + ":hamster:": { + "category": "nature", + "name": "hamster face", + "unicode": "1f439" + }, + ":hand_splayed:": { + "category": "people", + "name": "raised hand with fingers splayed", + "unicode": "1f590", + "unicode_alt": "1f590-fe0f" + }, + ":hand_splayed_tone1:": { + "category": "people", + "name": "raised hand with fingers splayed tone 1", + "unicode": "1f590-1f3fb" + }, + ":hand_splayed_tone2:": { + "category": "people", + "name": "raised hand with fingers splayed tone 2", + "unicode": "1f590-1f3fc" + }, + ":hand_splayed_tone3:": { + "category": "people", + "name": "raised hand with fingers splayed tone 3", + "unicode": "1f590-1f3fd" + }, + ":hand_splayed_tone4:": { + "category": "people", + "name": "raised hand with fingers splayed tone 4", + "unicode": "1f590-1f3fe" + }, + ":hand_splayed_tone5:": { + "category": "people", + "name": "raised hand with fingers splayed tone 5", + "unicode": "1f590-1f3ff" + }, + ":handbag:": { + "category": "people", + "name": "handbag", + "unicode": "1f45c" + }, + ":handball:": { + "category": "activity", + "name": "handball", + "unicode": "1f93e" + }, + ":handball_tone1:": { + "category": "activity", + "name": "handball tone 1", + "unicode": "1f93e-1f3fb" + }, + ":handball_tone2:": { + "category": "activity", + "name": "handball tone 2", + "unicode": "1f93e-1f3fc" + }, + ":handball_tone3:": { + "category": "activity", + "name": "handball tone 3", + "unicode": "1f93e-1f3fd" + }, + ":handball_tone4:": { + "category": "activity", + "name": "handball tone 4", + "unicode": "1f93e-1f3fe" + }, + ":handball_tone5:": { + "category": "activity", + "name": "handball tone 5", + "unicode": "1f93e-1f3ff" + }, + ":handshake:": { + "category": "people", + "name": "handshake", + "unicode": "1f91d" + }, + ":handshake_tone1:": { + "category": "people", + "name": "handshake tone 1", + "unicode": "1f91d-1f3fb" + }, + ":handshake_tone2:": { + "category": "people", + "name": "handshake tone 2", + "unicode": "1f91d-1f3fc" + }, + ":handshake_tone3:": { + "category": "people", + "name": "handshake tone 3", + "unicode": "1f91d-1f3fd" + }, + ":handshake_tone4:": { + "category": "people", + "name": "handshake tone 4", + "unicode": "1f91d-1f3fe" + }, + ":handshake_tone5:": { + "category": "people", + "name": "handshake tone 5", + "unicode": "1f91d-1f3ff" + }, + ":hash:": { + "category": "symbols", + "name": "keycap number sign", + "unicode": "0023-20e3", + "unicode_alt": "0023-fe0f-20e3" + }, + ":hatched_chick:": { + "category": "nature", + "name": "front-facing baby chick", + "unicode": "1f425" + }, + ":hatching_chick:": { + "category": "nature", + "name": "hatching chick", + "unicode": "1f423" + }, + ":head_bandage:": { + "category": "people", + "name": "face with head-bandage", + "unicode": "1f915" + }, + ":headphones:": { + "category": "activity", + "name": "headphone", + "unicode": "1f3a7" + }, + ":hear_no_evil:": { + "category": "nature", + "name": "hear-no-evil monkey", + "unicode": "1f649" + }, + ":heart:": { + "category": "symbols", + "name": "heavy black heart", + "unicode": "2764", + "unicode_alt": "2764-fe0f" + }, + ":heart_decoration:": { + "category": "symbols", + "name": "heart decoration", + "unicode": "1f49f" + }, + ":heart_exclamation:": { + "category": "symbols", + "name": "heavy heart exclamation mark ornament", + "unicode": "2763", + "unicode_alt": "2763-fe0f" + }, + ":heart_eyes:": { + "category": "people", + "name": "smiling face with heart-shaped eyes", + "unicode": "1f60d" + }, + ":heart_eyes_cat:": { + "category": "people", + "name": "smiling cat face with heart-shaped eyes", + "unicode": "1f63b" + }, + ":heartbeat:": { + "category": "symbols", + "name": "beating heart", + "unicode": "1f493" + }, + ":heartpulse:": { + "category": "symbols", + "name": "growing heart", + "unicode": "1f497" + }, + ":hearts:": { + "category": "symbols", + "name": "black heart suit", + "unicode": "2665", + "unicode_alt": "2665-fe0f" + }, + ":heavy_check_mark:": { + "category": "symbols", + "name": "heavy check mark", + "unicode": "2714", + "unicode_alt": "2714-fe0f" + }, + ":heavy_division_sign:": { + "category": "symbols", + "name": "heavy division sign", + "unicode": "2797" + }, + ":heavy_dollar_sign:": { + "category": "symbols", + "name": "heavy dollar sign", + "unicode": "1f4b2" + }, + ":heavy_minus_sign:": { + "category": "symbols", + "name": "heavy minus sign", + "unicode": "2796" + }, + ":heavy_multiplication_x:": { + "category": "symbols", + "name": "heavy multiplication x", + "unicode": "2716", + "unicode_alt": "2716-fe0f" + }, + ":heavy_plus_sign:": { + "category": "symbols", + "name": "heavy plus sign", + "unicode": "2795" + }, + ":helicopter:": { + "category": "travel", + "name": "helicopter", + "unicode": "1f681" + }, + ":helmet_with_cross:": { + "category": "people", + "name": "helmet with white cross", + "unicode": "26d1", + "unicode_alt": "26d1-fe0f" + }, + ":herb:": { + "category": "nature", + "name": "herb", + "unicode": "1f33f" + }, + ":hibiscus:": { + "category": "nature", + "name": "hibiscus", + "unicode": "1f33a" + }, + ":high_brightness:": { + "category": "symbols", + "name": "high brightness symbol", + "unicode": "1f506" + }, + ":high_heel:": { + "category": "people", + "name": "high-heeled shoe", + "unicode": "1f460" + }, + ":hockey:": { + "category": "activity", + "name": "ice hockey stick and puck", + "unicode": "1f3d2" + }, + ":hole:": { + "category": "objects", + "name": "hole", + "unicode": "1f573", + "unicode_alt": "1f573-fe0f" + }, + ":homes:": { + "category": "travel", + "name": "house buildings", + "unicode": "1f3d8", + "unicode_alt": "1f3d8-fe0f" + }, + ":honey_pot:": { + "category": "food", + "name": "honey pot", + "unicode": "1f36f" + }, + ":horse:": { + "category": "nature", + "name": "horse face", + "unicode": "1f434" + }, + ":horse_racing:": { + "category": "activity", + "name": "horse racing", + "unicode": "1f3c7" + }, + ":horse_racing_tone1:": { + "category": "activity", + "name": "horse racing tone 1", + "unicode": "1f3c7-1f3fb" + }, + ":horse_racing_tone2:": { + "category": "activity", + "name": "horse racing tone 2", + "unicode": "1f3c7-1f3fc" + }, + ":horse_racing_tone3:": { + "category": "activity", + "name": "horse racing tone 3", + "unicode": "1f3c7-1f3fd" + }, + ":horse_racing_tone4:": { + "category": "activity", + "name": "horse racing tone 4", + "unicode": "1f3c7-1f3fe" + }, + ":horse_racing_tone5:": { + "category": "activity", + "name": "horse racing tone 5", + "unicode": "1f3c7-1f3ff" + }, + ":hospital:": { + "category": "travel", + "name": "hospital", + "unicode": "1f3e5" + }, + ":hot_pepper:": { + "category": "food", + "name": "hot pepper", + "unicode": "1f336", + "unicode_alt": "1f336-fe0f" + }, + ":hotdog:": { + "category": "food", + "name": "hot dog", + "unicode": "1f32d" + }, + ":hotel:": { + "category": "travel", + "name": "hotel", + "unicode": "1f3e8" + }, + ":hotsprings:": { + "category": "symbols", + "name": "hot springs", + "unicode": "2668", + "unicode_alt": "2668-fe0f" + }, + ":hourglass:": { + "category": "objects", + "name": "hourglass", + "unicode": "231b", + "unicode_alt": "231b-fe0f" + }, + ":hourglass_flowing_sand:": { + "category": "objects", + "name": "hourglass with flowing sand", + "unicode": "23f3" + }, + ":house:": { + "category": "travel", + "name": "house building", + "unicode": "1f3e0" + }, + ":house_abandoned:": { + "category": "travel", + "name": "derelict house building", + "unicode": "1f3da", + "unicode_alt": "1f3da-fe0f" + }, + ":house_with_garden:": { + "category": "travel", + "name": "house with garden", + "unicode": "1f3e1" + }, + ":hugging:": { + "category": "people", + "name": "hugging face", + "unicode": "1f917" + }, + ":hushed:": { + "category": "people", + "name": "hushed face", + "unicode": "1f62f" + }, + ":ice_cream:": { + "category": "food", + "name": "ice cream", + "unicode": "1f368" + }, + ":ice_skate:": { + "category": "activity", + "name": "ice skate", + "unicode": "26f8", + "unicode_alt": "26f8-fe0f" + }, + ":icecream:": { + "category": "food", + "name": "soft ice cream", + "unicode": "1f366" + }, + ":id:": { + "category": "symbols", + "name": "squared id", + "unicode": "1f194" + }, + ":ideograph_advantage:": { + "category": "symbols", + "name": "circled ideograph advantage", + "unicode": "1f250" + }, + ":imp:": { + "category": "people", + "name": "imp", + "unicode": "1f47f" + }, + ":inbox_tray:": { + "category": "objects", + "name": "inbox tray", + "unicode": "1f4e5" + }, + ":incoming_envelope:": { + "category": "objects", + "name": "incoming envelope", + "unicode": "1f4e8" + }, + ":information_desk_person:": { + "category": "people", + "name": "information desk person", + "unicode": "1f481" + }, + ":information_desk_person_tone1:": { + "category": "people", + "name": "information desk person tone 1", + "unicode": "1f481-1f3fb" + }, + ":information_desk_person_tone2:": { + "category": "people", + "name": "information desk person tone 2", + "unicode": "1f481-1f3fc" + }, + ":information_desk_person_tone3:": { + "category": "people", + "name": "information desk person tone 3", + "unicode": "1f481-1f3fd" + }, + ":information_desk_person_tone4:": { + "category": "people", + "name": "information desk person tone 4", + "unicode": "1f481-1f3fe" + }, + ":information_desk_person_tone5:": { + "category": "people", + "name": "information desk person tone 5", + "unicode": "1f481-1f3ff" + }, + ":information_source:": { + "category": "symbols", + "name": "information source", + "unicode": "2139", + "unicode_alt": "2139-fe0f" + }, + ":innocent:": { + "category": "people", + "name": "smiling face with halo", + "unicode": "1f607" + }, + ":interrobang:": { + "category": "symbols", + "name": "exclamation question mark", + "unicode": "2049", + "unicode_alt": "2049-fe0f" + }, + ":iphone:": { + "category": "objects", + "name": "mobile phone", + "unicode": "1f4f1" + }, + ":island:": { + "category": "travel", + "name": "desert island", + "unicode": "1f3dd", + "unicode_alt": "1f3dd-fe0f" + }, + ":izakaya_lantern:": { + "category": "objects", + "name": "izakaya lantern", + "unicode": "1f3ee" + }, + ":jack_o_lantern:": { + "category": "nature", + "name": "jack-o-lantern", + "unicode": "1f383" + }, + ":japan:": { + "category": "travel", + "name": "silhouette of japan", + "unicode": "1f5fe" + }, + ":japanese_castle:": { + "category": "travel", + "name": "japanese castle", + "unicode": "1f3ef" + }, + ":japanese_goblin:": { + "category": "people", + "name": "japanese goblin", + "unicode": "1f47a" + }, + ":japanese_ogre:": { + "category": "people", + "name": "japanese ogre", + "unicode": "1f479" + }, + ":jeans:": { + "category": "people", + "name": "jeans", + "unicode": "1f456" + }, + ":joy:": { + "category": "people", + "name": "face with tears of joy", + "unicode": "1f602" + }, + ":joy_cat:": { + "category": "people", + "name": "cat face with tears of joy", + "unicode": "1f639" + }, + ":joystick:": { + "category": "objects", + "name": "joystick", + "unicode": "1f579", + "unicode_alt": "1f579-fe0f" + }, + ":juggling:": { + "category": "activity", + "name": "juggling", + "unicode": "1f939" + }, + ":juggling_tone1:": { + "category": "activity", + "name": "juggling tone 1", + "unicode": "1f939-1f3fb" + }, + ":juggling_tone2:": { + "category": "activity", + "name": "juggling tone 2", + "unicode": "1f939-1f3fc" + }, + ":juggling_tone3:": { + "category": "activity", + "name": "juggling tone 3", + "unicode": "1f939-1f3fd" + }, + ":juggling_tone4:": { + "category": "activity", + "name": "juggling tone 4", + "unicode": "1f939-1f3fe" + }, + ":juggling_tone5:": { + "category": "activity", + "name": "juggling tone 5", + "unicode": "1f939-1f3ff" + }, + ":kaaba:": { + "category": "travel", + "name": "kaaba", + "unicode": "1f54b" + }, + ":key2:": { + "category": "objects", + "name": "old key", + "unicode": "1f5dd", + "unicode_alt": "1f5dd-fe0f" + }, + ":key:": { + "category": "objects", + "name": "key", + "unicode": "1f511" + }, + ":keyboard:": { + "category": "objects", + "name": "keyboard", + "unicode": "2328", + "unicode_alt": "2328-fe0f" + }, + ":keycap_ten:": { + "category": "symbols", + "name": "keycap ten", + "unicode": "1f51f" + }, + ":kimono:": { + "category": "people", + "name": "kimono", + "unicode": "1f458" + }, + ":kiss:": { + "category": "people", + "name": "kiss mark", + "unicode": "1f48b" + }, + ":kiss_mm:": { + "category": "people", + "name": "kiss (man,man)", + "unicode": "1f468-2764-1f48b-1f468", + "unicode_alt": "1f468-200d-2764-fe0f-200d-1f48b-200d-1f468" + }, + ":kiss_ww:": { + "category": "people", + "name": "kiss (woman,woman)", + "unicode": "1f469-2764-1f48b-1f469", + "unicode_alt": "1f469-200d-2764-fe0f-200d-1f48b-200d-1f469" + }, + ":kissing:": { + "category": "people", + "name": "kissing face", + "unicode": "1f617" + }, + ":kissing_cat:": { + "category": "people", + "name": "kissing cat face with closed eyes", + "unicode": "1f63d" + }, + ":kissing_closed_eyes:": { + "category": "people", + "name": "kissing face with closed eyes", + "unicode": "1f61a" + }, + ":kissing_heart:": { + "category": "people", + "name": "face throwing a kiss", + "unicode": "1f618" + }, + ":kissing_smiling_eyes:": { + "category": "people", + "name": "kissing face with smiling eyes", + "unicode": "1f619" + }, + ":kiwi:": { + "category": "food", + "name": "kiwifruit", + "unicode": "1f95d" + }, + ":knife:": { + "category": "objects", + "name": "hocho", + "unicode": "1f52a" + }, + ":koala:": { + "category": "nature", + "name": "koala", + "unicode": "1f428" + }, + ":koko:": { + "category": "symbols", + "name": "squared katakana koko", + "unicode": "1f201" + }, + ":label:": { + "category": "objects", + "name": "label", + "unicode": "1f3f7", + "unicode_alt": "1f3f7-fe0f" + }, + ":large_blue_diamond:": { + "category": "symbols", + "name": "large blue diamond", + "unicode": "1f537" + }, + ":large_orange_diamond:": { + "category": "symbols", + "name": "large orange diamond", + "unicode": "1f536" + }, + ":last_quarter_moon:": { + "category": "nature", + "name": "last quarter moon symbol", + "unicode": "1f317" + }, + ":last_quarter_moon_with_face:": { + "category": "nature", + "name": "last quarter moon with face", + "unicode": "1f31c" + }, + ":laughing:": { + "category": "people", + "name": "smiling face with open mouth and tightly-closed eyes", + "unicode": "1f606" + }, + ":leaves:": { + "category": "nature", + "name": "leaf fluttering in wind", + "unicode": "1f343" + }, + ":ledger:": { + "category": "objects", + "name": "ledger", + "unicode": "1f4d2" + }, + ":left_facing_fist:": { + "category": "people", + "name": "left-facing fist", + "unicode": "1f91b" + }, + ":left_facing_fist_tone1:": { + "category": "people", + "name": "left facing fist tone 1", + "unicode": "1f91b-1f3fb" + }, + ":left_facing_fist_tone2:": { + "category": "people", + "name": "left facing fist tone 2", + "unicode": "1f91b-1f3fc" + }, + ":left_facing_fist_tone3:": { + "category": "people", + "name": "left facing fist tone 3", + "unicode": "1f91b-1f3fd" + }, + ":left_facing_fist_tone4:": { + "category": "people", + "name": "left facing fist tone 4", + "unicode": "1f91b-1f3fe" + }, + ":left_facing_fist_tone5:": { + "category": "people", + "name": "left facing fist tone 5", + "unicode": "1f91b-1f3ff" + }, + ":left_luggage:": { + "category": "symbols", + "name": "left luggage", + "unicode": "1f6c5" + }, + ":left_right_arrow:": { + "category": "symbols", + "name": "left right arrow", + "unicode": "2194", + "unicode_alt": "2194-fe0f" + }, + ":leftwards_arrow_with_hook:": { + "category": "symbols", + "name": "leftwards arrow with hook", + "unicode": "21a9", + "unicode_alt": "21a9-fe0f" + }, + ":lemon:": { + "category": "food", + "name": "lemon", + "unicode": "1f34b" + }, + ":leo:": { + "category": "symbols", + "name": "leo", + "unicode": "264c", + "unicode_alt": "264c-fe0f" + }, + ":leopard:": { + "category": "nature", + "name": "leopard", + "unicode": "1f406" + }, + ":level_slider:": { + "category": "objects", + "name": "level slider", + "unicode": "1f39a", + "unicode_alt": "1f39a-fe0f" + }, + ":levitate:": { + "category": "activity", + "name": "man in business suit levitating", + "unicode": "1f574", + "unicode_alt": "1f574-fe0f" + }, + ":libra:": { + "category": "symbols", + "name": "libra", + "unicode": "264e", + "unicode_alt": "264e-fe0f" + }, + ":lifter:": { + "category": "activity", + "name": "weight lifter", + "unicode": "1f3cb", + "unicode_alt": "1f3cb-fe0f" + }, + ":lifter_tone1:": { + "category": "activity", + "name": "weight lifter tone 1", + "unicode": "1f3cb-1f3fb" + }, + ":lifter_tone2:": { + "category": "activity", + "name": "weight lifter tone 2", + "unicode": "1f3cb-1f3fc" + }, + ":lifter_tone3:": { + "category": "activity", + "name": "weight lifter tone 3", + "unicode": "1f3cb-1f3fd" + }, + ":lifter_tone4:": { + "category": "activity", + "name": "weight lifter tone 4", + "unicode": "1f3cb-1f3fe" + }, + ":lifter_tone5:": { + "category": "activity", + "name": "weight lifter tone 5", + "unicode": "1f3cb-1f3ff" + }, + ":light_rail:": { + "category": "travel", + "name": "light rail", + "unicode": "1f688" + }, + ":link:": { + "category": "objects", + "name": "link symbol", + "unicode": "1f517" + }, + ":lion_face:": { + "category": "nature", + "name": "lion face", + "unicode": "1f981" + }, + ":lips:": { + "category": "people", + "name": "mouth", + "unicode": "1f444" + }, + ":lipstick:": { + "category": "people", + "name": "lipstick", + "unicode": "1f484" + }, + ":lizard:": { + "category": "nature", + "name": "lizard", + "unicode": "1f98e" + }, + ":lock:": { + "category": "objects", + "name": "lock", + "unicode": "1f512" + }, + ":lock_with_ink_pen:": { + "category": "objects", + "name": "lock with ink pen", + "unicode": "1f50f" + }, + ":lollipop:": { + "category": "food", + "name": "lollipop", + "unicode": "1f36d" + }, + ":loop:": { + "category": "symbols", + "name": "double curly loop", + "unicode": "27bf" + }, + ":loud_sound:": { + "category": "symbols", + "name": "speaker with three sound waves", + "unicode": "1f50a" + }, + ":loudspeaker:": { + "category": "symbols", + "name": "public address loudspeaker", + "unicode": "1f4e2" + }, + ":love_hotel:": { + "category": "travel", + "name": "love hotel", + "unicode": "1f3e9" + }, + ":love_letter:": { + "category": "objects", + "name": "love letter", + "unicode": "1f48c" + }, + ":low_brightness:": { + "category": "symbols", + "name": "low brightness symbol", + "unicode": "1f505" + }, + ":lying_face:": { + "category": "people", + "name": "lying face", + "unicode": "1f925" + }, + ":m:": { + "category": "symbols", + "name": "circled latin capital letter m", + "unicode": "24c2", + "unicode_alt": "24c2-fe0f" + }, + ":mag:": { + "category": "objects", + "name": "left-pointing magnifying glass", + "unicode": "1f50d" + }, + ":mag_right:": { + "category": "objects", + "name": "right-pointing magnifying glass", + "unicode": "1f50e" + }, + ":mahjong:": { + "category": "symbols", + "name": "mahjong tile red dragon", + "unicode": "1f004", + "unicode_alt": "1f004-fe0f" + }, + ":mailbox:": { + "category": "objects", + "name": "closed mailbox with raised flag", + "unicode": "1f4eb" + }, + ":mailbox_closed:": { + "category": "objects", + "name": "closed mailbox with lowered flag", + "unicode": "1f4ea" + }, + ":mailbox_with_mail:": { + "category": "objects", + "name": "open mailbox with raised flag", + "unicode": "1f4ec" + }, + ":mailbox_with_no_mail:": { + "category": "objects", + "name": "open mailbox with lowered flag", + "unicode": "1f4ed" + }, + ":man:": { + "category": "people", + "name": "man", + "unicode": "1f468" + }, + ":man_dancing:": { + "category": "people", + "name": "man dancing", + "unicode": "1f57a" + }, + ":man_dancing_tone1:": { + "category": "people", + "name": "man dancing tone 1", + "unicode": "1f57a-1f3fb" + }, + ":man_dancing_tone2:": { + "category": "people", + "name": "man dancing tone 2", + "unicode": "1f57a-1f3fc" + }, + ":man_dancing_tone3:": { + "category": "people", + "name": "man dancing tone 3", + "unicode": "1f57a-1f3fd" + }, + ":man_dancing_tone4:": { + "category": "people", + "name": "man dancing tone 4", + "unicode": "1f57a-1f3fe" + }, + ":man_dancing_tone5:": { + "category": "people", + "name": "man dancing tone 5", + "unicode": "1f57a-1f3ff" + }, + ":man_in_tuxedo:": { + "category": "people", + "name": "man in tuxedo", + "unicode": "1f935" + }, + ":man_in_tuxedo_tone1:": { + "category": "people", + "name": "man in tuxedo tone 1", + "unicode": "1f935-1f3fb" + }, + ":man_in_tuxedo_tone2:": { + "category": "people", + "name": "man in tuxedo tone 2", + "unicode": "1f935-1f3fc" + }, + ":man_in_tuxedo_tone3:": { + "category": "people", + "name": "man in tuxedo tone 3", + "unicode": "1f935-1f3fd" + }, + ":man_in_tuxedo_tone4:": { + "category": "people", + "name": "man in tuxedo tone 4", + "unicode": "1f935-1f3fe" + }, + ":man_in_tuxedo_tone5:": { + "category": "people", + "name": "man in tuxedo tone 5", + "unicode": "1f935-1f3ff" + }, + ":man_tone1:": { + "category": "people", + "name": "man tone 1", + "unicode": "1f468-1f3fb" + }, + ":man_tone2:": { + "category": "people", + "name": "man tone 2", + "unicode": "1f468-1f3fc" + }, + ":man_tone3:": { + "category": "people", + "name": "man tone 3", + "unicode": "1f468-1f3fd" + }, + ":man_tone4:": { + "category": "people", + "name": "man tone 4", + "unicode": "1f468-1f3fe" + }, + ":man_tone5:": { + "category": "people", + "name": "man tone 5", + "unicode": "1f468-1f3ff" + }, + ":man_with_gua_pi_mao:": { + "category": "people", + "name": "man with gua pi mao", + "unicode": "1f472" + }, + ":man_with_gua_pi_mao_tone1:": { + "category": "people", + "name": "man with gua pi mao tone 1", + "unicode": "1f472-1f3fb" + }, + ":man_with_gua_pi_mao_tone2:": { + "category": "people", + "name": "man with gua pi mao tone 2", + "unicode": "1f472-1f3fc" + }, + ":man_with_gua_pi_mao_tone3:": { + "category": "people", + "name": "man with gua pi mao tone 3", + "unicode": "1f472-1f3fd" + }, + ":man_with_gua_pi_mao_tone4:": { + "category": "people", + "name": "man with gua pi mao tone 4", + "unicode": "1f472-1f3fe" + }, + ":man_with_gua_pi_mao_tone5:": { + "category": "people", + "name": "man with gua pi mao tone 5", + "unicode": "1f472-1f3ff" + }, + ":man_with_turban:": { + "category": "people", + "name": "man with turban", + "unicode": "1f473" + }, + ":man_with_turban_tone1:": { + "category": "people", + "name": "man with turban tone 1", + "unicode": "1f473-1f3fb" + }, + ":man_with_turban_tone2:": { + "category": "people", + "name": "man with turban tone 2", + "unicode": "1f473-1f3fc" + }, + ":man_with_turban_tone3:": { + "category": "people", + "name": "man with turban tone 3", + "unicode": "1f473-1f3fd" + }, + ":man_with_turban_tone4:": { + "category": "people", + "name": "man with turban tone 4", + "unicode": "1f473-1f3fe" + }, + ":man_with_turban_tone5:": { + "category": "people", + "name": "man with turban tone 5", + "unicode": "1f473-1f3ff" + }, + ":mans_shoe:": { + "category": "people", + "name": "mans shoe", + "unicode": "1f45e" + }, + ":map:": { + "category": "objects", + "name": "world map", + "unicode": "1f5fa", + "unicode_alt": "1f5fa-fe0f" + }, + ":maple_leaf:": { + "category": "nature", + "name": "maple leaf", + "unicode": "1f341" + }, + ":martial_arts_uniform:": { + "category": "activity", + "name": "martial arts uniform", + "unicode": "1f94b" + }, + ":mask:": { + "category": "people", + "name": "face with medical mask", + "unicode": "1f637" + }, + ":massage:": { + "category": "people", + "name": "face massage", + "unicode": "1f486" + }, + ":massage_tone1:": { + "category": "people", + "name": "face massage tone 1", + "unicode": "1f486-1f3fb" + }, + ":massage_tone2:": { + "category": "people", + "name": "face massage tone 2", + "unicode": "1f486-1f3fc" + }, + ":massage_tone3:": { + "category": "people", + "name": "face massage tone 3", + "unicode": "1f486-1f3fd" + }, + ":massage_tone4:": { + "category": "people", + "name": "face massage tone 4", + "unicode": "1f486-1f3fe" + }, + ":massage_tone5:": { + "category": "people", + "name": "face massage tone 5", + "unicode": "1f486-1f3ff" + }, + ":meat_on_bone:": { + "category": "food", + "name": "meat on bone", + "unicode": "1f356" + }, + ":medal:": { + "category": "activity", + "name": "sports medal", + "unicode": "1f3c5" + }, + ":mega:": { + "category": "symbols", + "name": "cheering megaphone", + "unicode": "1f4e3" + }, + ":melon:": { + "category": "food", + "name": "melon", + "unicode": "1f348" + }, + ":menorah:": { + "category": "symbols", + "name": "menorah with nine branches", + "unicode": "1f54e" + }, + ":mens:": { + "category": "symbols", + "name": "mens symbol", + "unicode": "1f6b9" + }, + ":metal:": { + "category": "people", + "name": "sign of the horns", + "unicode": "1f918" + }, + ":metal_tone1:": { + "category": "people", + "name": "sign of the horns tone 1", + "unicode": "1f918-1f3fb" + }, + ":metal_tone2:": { + "category": "people", + "name": "sign of the horns tone 2", + "unicode": "1f918-1f3fc" + }, + ":metal_tone3:": { + "category": "people", + "name": "sign of the horns tone 3", + "unicode": "1f918-1f3fd" + }, + ":metal_tone4:": { + "category": "people", + "name": "sign of the horns tone 4", + "unicode": "1f918-1f3fe" + }, + ":metal_tone5:": { + "category": "people", + "name": "sign of the horns tone 5", + "unicode": "1f918-1f3ff" + }, + ":metro:": { + "category": "travel", + "name": "metro", + "unicode": "1f687" + }, + ":microphone2:": { + "category": "objects", + "name": "studio microphone", + "unicode": "1f399", + "unicode_alt": "1f399-fe0f" + }, + ":microphone:": { + "category": "activity", + "name": "microphone", + "unicode": "1f3a4" + }, + ":microscope:": { + "category": "objects", + "name": "microscope", + "unicode": "1f52c" + }, + ":middle_finger:": { + "category": "people", + "name": "reversed hand with middle finger extended", + "unicode": "1f595" + }, + ":middle_finger_tone1:": { + "category": "people", + "name": "reversed hand with middle finger extended tone 1", + "unicode": "1f595-1f3fb" + }, + ":middle_finger_tone2:": { + "category": "people", + "name": "reversed hand with middle finger extended tone 2", + "unicode": "1f595-1f3fc" + }, + ":middle_finger_tone3:": { + "category": "people", + "name": "reversed hand with middle finger extended tone 3", + "unicode": "1f595-1f3fd" + }, + ":middle_finger_tone4:": { + "category": "people", + "name": "reversed hand with middle finger extended tone 4", + "unicode": "1f595-1f3fe" + }, + ":middle_finger_tone5:": { + "category": "people", + "name": "reversed hand with middle finger extended tone 5", + "unicode": "1f595-1f3ff" + }, + ":military_medal:": { + "category": "activity", + "name": "military medal", + "unicode": "1f396", + "unicode_alt": "1f396-fe0f" + }, + ":milk:": { + "category": "food", + "name": "glass of milk", + "unicode": "1f95b" + }, + ":milky_way:": { + "category": "travel", + "name": "milky way", + "unicode": "1f30c" + }, + ":minibus:": { + "category": "travel", + "name": "minibus", + "unicode": "1f690" + }, + ":minidisc:": { + "category": "objects", + "name": "minidisc", + "unicode": "1f4bd" + }, + ":mobile_phone_off:": { + "category": "symbols", + "name": "mobile phone off", + "unicode": "1f4f4" + }, + ":money_mouth:": { + "category": "people", + "name": "money-mouth face", + "unicode": "1f911" + }, + ":money_with_wings:": { + "category": "objects", + "name": "money with wings", + "unicode": "1f4b8" + }, + ":moneybag:": { + "category": "objects", + "name": "money bag", + "unicode": "1f4b0" + }, + ":monkey:": { + "category": "nature", + "name": "monkey", + "unicode": "1f412" + }, + ":monkey_face:": { + "category": "nature", + "name": "monkey face", + "unicode": "1f435" + }, + ":monorail:": { + "category": "travel", + "name": "monorail", + "unicode": "1f69d" + }, + ":mortar_board:": { + "category": "people", + "name": "graduation cap", + "unicode": "1f393" + }, + ":mosque:": { + "category": "travel", + "name": "mosque", + "unicode": "1f54c" + }, + ":motor_scooter:": { + "category": "travel", + "name": "motor scooter", + "unicode": "1f6f5" + }, + ":motorboat:": { + "category": "travel", + "name": "motorboat", + "unicode": "1f6e5", + "unicode_alt": "1f6e5-fe0f" + }, + ":motorcycle:": { + "category": "travel", + "name": "racing motorcycle", + "unicode": "1f3cd", + "unicode_alt": "1f3cd-fe0f" + }, + ":motorway:": { + "category": "travel", + "name": "motorway", + "unicode": "1f6e3", + "unicode_alt": "1f6e3-fe0f" + }, + ":mount_fuji:": { + "category": "travel", + "name": "mount fuji", + "unicode": "1f5fb" + }, + ":mountain:": { + "category": "travel", + "name": "mountain", + "unicode": "26f0", + "unicode_alt": "26f0-fe0f" + }, + ":mountain_bicyclist:": { + "category": "activity", + "name": "mountain bicyclist", + "unicode": "1f6b5" + }, + ":mountain_bicyclist_tone1:": { + "category": "activity", + "name": "mountain bicyclist tone 1", + "unicode": "1f6b5-1f3fb" + }, + ":mountain_bicyclist_tone2:": { + "category": "activity", + "name": "mountain bicyclist tone 2", + "unicode": "1f6b5-1f3fc" + }, + ":mountain_bicyclist_tone3:": { + "category": "activity", + "name": "mountain bicyclist tone 3", + "unicode": "1f6b5-1f3fd" + }, + ":mountain_bicyclist_tone4:": { + "category": "activity", + "name": "mountain bicyclist tone 4", + "unicode": "1f6b5-1f3fe" + }, + ":mountain_bicyclist_tone5:": { + "category": "activity", + "name": "mountain bicyclist tone 5", + "unicode": "1f6b5-1f3ff" + }, + ":mountain_cableway:": { + "category": "travel", + "name": "mountain cableway", + "unicode": "1f6a0" + }, + ":mountain_railway:": { + "category": "travel", + "name": "mountain railway", + "unicode": "1f69e" + }, + ":mountain_snow:": { + "category": "travel", + "name": "snow capped mountain", + "unicode": "1f3d4", + "unicode_alt": "1f3d4-fe0f" + }, + ":mouse2:": { + "category": "nature", + "name": "mouse", + "unicode": "1f401" + }, + ":mouse:": { + "category": "nature", + "name": "mouse face", + "unicode": "1f42d" + }, + ":mouse_three_button:": { + "category": "objects", + "name": "three button mouse", + "unicode": "1f5b1", + "unicode_alt": "1f5b1-fe0f" + }, + ":movie_camera:": { + "category": "objects", + "name": "movie camera", + "unicode": "1f3a5" + }, + ":moyai:": { + "category": "objects", + "name": "moyai", + "unicode": "1f5ff" + }, + ":mrs_claus:": { + "category": "people", + "name": "mother christmas", + "unicode": "1f936" + }, + ":mrs_claus_tone1:": { + "category": "people", + "name": "mother christmas tone 1", + "unicode": "1f936-1f3fb" + }, + ":mrs_claus_tone2:": { + "category": "people", + "name": "mother christmas tone 2", + "unicode": "1f936-1f3fc" + }, + ":mrs_claus_tone3:": { + "category": "people", + "name": "mother christmas tone 3", + "unicode": "1f936-1f3fd" + }, + ":mrs_claus_tone4:": { + "category": "people", + "name": "mother christmas tone 4", + "unicode": "1f936-1f3fe" + }, + ":mrs_claus_tone5:": { + "category": "people", + "name": "mother christmas tone 5", + "unicode": "1f936-1f3ff" + }, + ":muscle:": { + "category": "people", + "name": "flexed biceps", + "unicode": "1f4aa" + }, + ":muscle_tone1:": { + "category": "people", + "name": "flexed biceps tone 1", + "unicode": "1f4aa-1f3fb" + }, + ":muscle_tone2:": { + "category": "people", + "name": "flexed biceps tone 2", + "unicode": "1f4aa-1f3fc" + }, + ":muscle_tone3:": { + "category": "people", + "name": "flexed biceps tone 3", + "unicode": "1f4aa-1f3fd" + }, + ":muscle_tone4:": { + "category": "people", + "name": "flexed biceps tone 4", + "unicode": "1f4aa-1f3fe" + }, + ":muscle_tone5:": { + "category": "people", + "name": "flexed biceps tone 5", + "unicode": "1f4aa-1f3ff" + }, + ":mushroom:": { + "category": "nature", + "name": "mushroom", + "unicode": "1f344" + }, + ":musical_keyboard:": { + "category": "activity", + "name": "musical keyboard", + "unicode": "1f3b9" + }, + ":musical_note:": { + "category": "symbols", + "name": "musical note", + "unicode": "1f3b5" + }, + ":musical_score:": { + "category": "activity", + "name": "musical score", + "unicode": "1f3bc" + }, + ":mute:": { + "category": "symbols", + "name": "speaker with cancellation stroke", + "unicode": "1f507" + }, + ":nail_care:": { + "category": "people", + "name": "nail polish", + "unicode": "1f485" + }, + ":nail_care_tone1:": { + "category": "people", + "name": "nail polish tone 1", + "unicode": "1f485-1f3fb" + }, + ":nail_care_tone2:": { + "category": "people", + "name": "nail polish tone 2", + "unicode": "1f485-1f3fc" + }, + ":nail_care_tone3:": { + "category": "people", + "name": "nail polish tone 3", + "unicode": "1f485-1f3fd" + }, + ":nail_care_tone4:": { + "category": "people", + "name": "nail polish tone 4", + "unicode": "1f485-1f3fe" + }, + ":nail_care_tone5:": { + "category": "people", + "name": "nail polish tone 5", + "unicode": "1f485-1f3ff" + }, + ":name_badge:": { + "category": "symbols", + "name": "name badge", + "unicode": "1f4db" + }, + ":nauseated_face:": { + "category": "people", + "name": "nauseated face", + "unicode": "1f922" + }, + ":necktie:": { + "category": "people", + "name": "necktie", + "unicode": "1f454" + }, + ":negative_squared_cross_mark:": { + "category": "symbols", + "name": "negative squared cross mark", + "unicode": "274e" + }, + ":nerd:": { + "category": "people", + "name": "nerd face", + "unicode": "1f913" + }, + ":neutral_face:": { + "category": "people", + "name": "neutral face", + "unicode": "1f610" + }, + ":new:": { + "category": "symbols", + "name": "squared new", + "unicode": "1f195" + }, + ":new_moon:": { + "category": "nature", + "name": "new moon symbol", + "unicode": "1f311" + }, + ":new_moon_with_face:": { + "category": "nature", + "name": "new moon with face", + "unicode": "1f31a" + }, + ":newspaper2:": { + "category": "objects", + "name": "rolled-up newspaper", + "unicode": "1f5de", + "unicode_alt": "1f5de-fe0f" + }, + ":newspaper:": { + "category": "objects", + "name": "newspaper", + "unicode": "1f4f0" + }, + ":ng:": { + "category": "symbols", + "name": "squared ng", + "unicode": "1f196" + }, + ":night_with_stars:": { + "category": "travel", + "name": "night with stars", + "unicode": "1f303" + }, + ":nine:": { + "category": "symbols", + "name": "keycap digit nine", + "unicode": "0039-20e3", + "unicode_alt": "0039-fe0f-20e3" + }, + ":no_bell:": { + "category": "symbols", + "name": "bell with cancellation stroke", + "unicode": "1f515" + }, + ":no_bicycles:": { + "category": "symbols", + "name": "no bicycles", + "unicode": "1f6b3" + }, + ":no_entry:": { + "category": "symbols", + "name": "no entry", + "unicode": "26d4", + "unicode_alt": "26d4-fe0f" + }, + ":no_entry_sign:": { + "category": "symbols", + "name": "no entry sign", + "unicode": "1f6ab" + }, + ":no_good:": { + "category": "people", + "name": "face with no good gesture", + "unicode": "1f645" + }, + ":no_good_tone1:": { + "category": "people", + "name": "face with no good gesture tone 1", + "unicode": "1f645-1f3fb" + }, + ":no_good_tone2:": { + "category": "people", + "name": "face with no good gesture tone 2", + "unicode": "1f645-1f3fc" + }, + ":no_good_tone3:": { + "category": "people", + "name": "face with no good gesture tone 3", + "unicode": "1f645-1f3fd" + }, + ":no_good_tone4:": { + "category": "people", + "name": "face with no good gesture tone 4", + "unicode": "1f645-1f3fe" + }, + ":no_good_tone5:": { + "category": "people", + "name": "face with no good gesture tone 5", + "unicode": "1f645-1f3ff" + }, + ":no_mobile_phones:": { + "category": "symbols", + "name": "no mobile phones", + "unicode": "1f4f5" + }, + ":no_mouth:": { + "category": "people", + "name": "face without mouth", + "unicode": "1f636" + }, + ":no_pedestrians:": { + "category": "symbols", + "name": "no pedestrians", + "unicode": "1f6b7" + }, + ":no_smoking:": { + "category": "symbols", + "name": "no smoking symbol", + "unicode": "1f6ad" + }, + ":non-potable_water:": { + "category": "symbols", + "name": "non-potable water symbol", + "unicode": "1f6b1" + }, + ":nose:": { + "category": "people", + "name": "nose", + "unicode": "1f443" + }, + ":nose_tone1:": { + "category": "people", + "name": "nose tone 1", + "unicode": "1f443-1f3fb" + }, + ":nose_tone2:": { + "category": "people", + "name": "nose tone 2", + "unicode": "1f443-1f3fc" + }, + ":nose_tone3:": { + "category": "people", + "name": "nose tone 3", + "unicode": "1f443-1f3fd" + }, + ":nose_tone4:": { + "category": "people", + "name": "nose tone 4", + "unicode": "1f443-1f3fe" + }, + ":nose_tone5:": { + "category": "people", + "name": "nose tone 5", + "unicode": "1f443-1f3ff" + }, + ":notebook:": { + "category": "objects", + "name": "notebook", + "unicode": "1f4d3" + }, + ":notebook_with_decorative_cover:": { + "category": "objects", + "name": "notebook with decorative cover", + "unicode": "1f4d4" + }, + ":notepad_spiral:": { + "category": "objects", + "name": "spiral note pad", + "unicode": "1f5d2", + "unicode_alt": "1f5d2-fe0f" + }, + ":notes:": { + "category": "symbols", + "name": "multiple musical notes", + "unicode": "1f3b6" + }, + ":nut_and_bolt:": { + "category": "objects", + "name": "nut and bolt", + "unicode": "1f529" + }, + ":o2:": { + "category": "symbols", + "name": "negative squared latin capital letter o", + "unicode": "1f17e" + }, + ":o:": { + "category": "symbols", + "name": "heavy large circle", + "unicode": "2b55", + "unicode_alt": "2b55-fe0f" + }, + ":ocean:": { + "category": "nature", + "name": "water wave", + "unicode": "1f30a" + }, + ":octagonal_sign:": { + "category": "symbols", + "name": "octagonal sign", + "unicode": "1f6d1" + }, + ":octopus:": { + "category": "nature", + "name": "octopus", + "unicode": "1f419" + }, + ":oden:": { + "category": "food", + "name": "oden", + "unicode": "1f362" + }, + ":office:": { + "category": "travel", + "name": "office building", + "unicode": "1f3e2" + }, + ":oil:": { + "category": "objects", + "name": "oil drum", + "unicode": "1f6e2", + "unicode_alt": "1f6e2-fe0f" + }, + ":ok:": { + "category": "symbols", + "name": "squared ok", + "unicode": "1f197" + }, + ":ok_hand:": { + "category": "people", + "name": "ok hand sign", + "unicode": "1f44c" + }, + ":ok_hand_tone1:": { + "category": "people", + "name": "ok hand sign tone 1", + "unicode": "1f44c-1f3fb" + }, + ":ok_hand_tone2:": { + "category": "people", + "name": "ok hand sign tone 2", + "unicode": "1f44c-1f3fc" + }, + ":ok_hand_tone3:": { + "category": "people", + "name": "ok hand sign tone 3", + "unicode": "1f44c-1f3fd" + }, + ":ok_hand_tone4:": { + "category": "people", + "name": "ok hand sign tone 4", + "unicode": "1f44c-1f3fe" + }, + ":ok_hand_tone5:": { + "category": "people", + "name": "ok hand sign tone 5", + "unicode": "1f44c-1f3ff" + }, + ":ok_woman:": { + "category": "people", + "name": "face with ok gesture", + "unicode": "1f646" + }, + ":ok_woman_tone1:": { + "category": "people", + "name": "face with ok gesture tone1", + "unicode": "1f646-1f3fb" + }, + ":ok_woman_tone2:": { + "category": "people", + "name": "face with ok gesture tone2", + "unicode": "1f646-1f3fc" + }, + ":ok_woman_tone3:": { + "category": "people", + "name": "face with ok gesture tone3", + "unicode": "1f646-1f3fd" + }, + ":ok_woman_tone4:": { + "category": "people", + "name": "face with ok gesture tone4", + "unicode": "1f646-1f3fe" + }, + ":ok_woman_tone5:": { + "category": "people", + "name": "face with ok gesture tone5", + "unicode": "1f646-1f3ff" + }, + ":older_man:": { + "category": "people", + "name": "older man", + "unicode": "1f474" + }, + ":older_man_tone1:": { + "category": "people", + "name": "older man tone 1", + "unicode": "1f474-1f3fb" + }, + ":older_man_tone2:": { + "category": "people", + "name": "older man tone 2", + "unicode": "1f474-1f3fc" + }, + ":older_man_tone3:": { + "category": "people", + "name": "older man tone 3", + "unicode": "1f474-1f3fd" + }, + ":older_man_tone4:": { + "category": "people", + "name": "older man tone 4", + "unicode": "1f474-1f3fe" + }, + ":older_man_tone5:": { + "category": "people", + "name": "older man tone 5", + "unicode": "1f474-1f3ff" + }, + ":older_woman:": { + "category": "people", + "name": "older woman", + "unicode": "1f475" + }, + ":older_woman_tone1:": { + "category": "people", + "name": "older woman tone 1", + "unicode": "1f475-1f3fb" + }, + ":older_woman_tone2:": { + "category": "people", + "name": "older woman tone 2", + "unicode": "1f475-1f3fc" + }, + ":older_woman_tone3:": { + "category": "people", + "name": "older woman tone 3", + "unicode": "1f475-1f3fd" + }, + ":older_woman_tone4:": { + "category": "people", + "name": "older woman tone 4", + "unicode": "1f475-1f3fe" + }, + ":older_woman_tone5:": { + "category": "people", + "name": "older woman tone 5", + "unicode": "1f475-1f3ff" + }, + ":om_symbol:": { + "category": "symbols", + "name": "om symbol", + "unicode": "1f549", + "unicode_alt": "1f549-fe0f" + }, + ":on:": { + "category": "symbols", + "name": "on with exclamation mark with left right arrow abo", + "unicode": "1f51b" + }, + ":oncoming_automobile:": { + "category": "travel", + "name": "oncoming automobile", + "unicode": "1f698" + }, + ":oncoming_bus:": { + "category": "travel", + "name": "oncoming bus", + "unicode": "1f68d" + }, + ":oncoming_police_car:": { + "category": "travel", + "name": "oncoming police car", + "unicode": "1f694" + }, + ":oncoming_taxi:": { + "category": "travel", + "name": "oncoming taxi", + "unicode": "1f696" + }, + ":one:": { + "category": "symbols", + "name": "keycap digit one", + "unicode": "0031-20e3", + "unicode_alt": "0031-fe0f-20e3" + }, + ":open_file_folder:": { + "category": "objects", + "name": "open file folder", + "unicode": "1f4c2" + }, + ":open_hands:": { + "category": "people", + "name": "open hands sign", + "unicode": "1f450" + }, + ":open_hands_tone1:": { + "category": "people", + "name": "open hands sign tone 1", + "unicode": "1f450-1f3fb" + }, + ":open_hands_tone2:": { + "category": "people", + "name": "open hands sign tone 2", + "unicode": "1f450-1f3fc" + }, + ":open_hands_tone3:": { + "category": "people", + "name": "open hands sign tone 3", + "unicode": "1f450-1f3fd" + }, + ":open_hands_tone4:": { + "category": "people", + "name": "open hands sign tone 4", + "unicode": "1f450-1f3fe" + }, + ":open_hands_tone5:": { + "category": "people", + "name": "open hands sign tone 5", + "unicode": "1f450-1f3ff" + }, + ":open_mouth:": { + "category": "people", + "name": "face with open mouth", + "unicode": "1f62e" + }, + ":ophiuchus:": { + "category": "symbols", + "name": "ophiuchus", + "unicode": "26ce" + }, + ":orange_book:": { + "category": "objects", + "name": "orange book", + "unicode": "1f4d9" + }, + ":orthodox_cross:": { + "category": "symbols", + "name": "orthodox cross", + "unicode": "2626", + "unicode_alt": "2626-fe0f" + }, + ":outbox_tray:": { + "category": "objects", + "name": "outbox tray", + "unicode": "1f4e4" + }, + ":owl:": { + "category": "nature", + "name": "owl", + "unicode": "1f989" + }, + ":ox:": { + "category": "nature", + "name": "ox", + "unicode": "1f402" + }, + ":package:": { + "category": "objects", + "name": "package", + "unicode": "1f4e6" + }, + ":page_facing_up:": { + "category": "objects", + "name": "page facing up", + "unicode": "1f4c4" + }, + ":page_with_curl:": { + "category": "objects", + "name": "page with curl", + "unicode": "1f4c3" + }, + ":pager:": { + "category": "objects", + "name": "pager", + "unicode": "1f4df" + }, + ":paintbrush:": { + "category": "objects", + "name": "lower left paintbrush", + "unicode": "1f58c", + "unicode_alt": "1f58c-fe0f" + }, + ":palm_tree:": { + "category": "nature", + "name": "palm tree", + "unicode": "1f334" + }, + ":pancakes:": { + "category": "food", + "name": "pancakes", + "unicode": "1f95e" + }, + ":panda_face:": { + "category": "nature", + "name": "panda face", + "unicode": "1f43c" + }, + ":paperclip:": { + "category": "objects", + "name": "paperclip", + "unicode": "1f4ce" + }, + ":paperclips:": { + "category": "objects", + "name": "linked paperclips", + "unicode": "1f587", + "unicode_alt": "1f587-fe0f" + }, + ":park:": { + "category": "travel", + "name": "national park", + "unicode": "1f3de", + "unicode_alt": "1f3de-fe0f" + }, + ":parking:": { + "category": "symbols", + "name": "negative squared latin capital letter p", + "unicode": "1f17f", + "unicode_alt": "1f17f-fe0f" + }, + ":part_alternation_mark:": { + "category": "symbols", + "name": "part alternation mark", + "unicode": "303d", + "unicode_alt": "303d-fe0f" + }, + ":partly_sunny:": { + "category": "nature", + "name": "sun behind cloud", + "unicode": "26c5", + "unicode_alt": "26c5-fe0f" + }, + ":passport_control:": { + "category": "symbols", + "name": "passport control", + "unicode": "1f6c2" + }, + ":pause_button:": { + "category": "symbols", + "name": "double vertical bar", + "unicode": "23f8", + "unicode_alt": "23f8-fe0f" + }, + ":peace:": { + "category": "symbols", + "name": "peace symbol", + "unicode": "262e", + "unicode_alt": "262e-fe0f" + }, + ":peach:": { + "category": "food", + "name": "peach", + "unicode": "1f351" + }, + ":peanuts:": { + "category": "food", + "name": "peanuts", + "unicode": "1f95c" + }, + ":pear:": { + "category": "food", + "name": "pear", + "unicode": "1f350" + }, + ":pen_ballpoint:": { + "category": "objects", + "name": "lower left ballpoint pen", + "unicode": "1f58a", + "unicode_alt": "1f58a-fe0f" + }, + ":pen_fountain:": { + "category": "objects", + "name": "lower left fountain pen", + "unicode": "1f58b", + "unicode_alt": "1f58b-fe0f" + }, + ":pencil2:": { + "category": "objects", + "name": "pencil", + "unicode": "270f", + "unicode_alt": "270f-fe0f" + }, + ":pencil:": { + "category": "objects", + "name": "memo", + "unicode": "1f4dd" + }, + ":penguin:": { + "category": "nature", + "name": "penguin", + "unicode": "1f427" + }, + ":pensive:": { + "category": "people", + "name": "pensive face", + "unicode": "1f614" + }, + ":performing_arts:": { + "category": "activity", + "name": "performing arts", + "unicode": "1f3ad" + }, + ":persevere:": { + "category": "people", + "name": "persevering face", + "unicode": "1f623" + }, + ":person_frowning:": { + "category": "people", + "name": "person frowning", + "unicode": "1f64d" + }, + ":person_frowning_tone1:": { + "category": "people", + "name": "person frowning tone 1", + "unicode": "1f64d-1f3fb" + }, + ":person_frowning_tone2:": { + "category": "people", + "name": "person frowning tone 2", + "unicode": "1f64d-1f3fc" + }, + ":person_frowning_tone3:": { + "category": "people", + "name": "person frowning tone 3", + "unicode": "1f64d-1f3fd" + }, + ":person_frowning_tone4:": { + "category": "people", + "name": "person frowning tone 4", + "unicode": "1f64d-1f3fe" + }, + ":person_frowning_tone5:": { + "category": "people", + "name": "person frowning tone 5", + "unicode": "1f64d-1f3ff" + }, + ":person_with_blond_hair:": { + "category": "people", + "name": "person with blond hair", + "unicode": "1f471" + }, + ":person_with_blond_hair_tone1:": { + "category": "people", + "name": "person with blond hair tone 1", + "unicode": "1f471-1f3fb" + }, + ":person_with_blond_hair_tone2:": { + "category": "people", + "name": "person with blond hair tone 2", + "unicode": "1f471-1f3fc" + }, + ":person_with_blond_hair_tone3:": { + "category": "people", + "name": "person with blond hair tone 3", + "unicode": "1f471-1f3fd" + }, + ":person_with_blond_hair_tone4:": { + "category": "people", + "name": "person with blond hair tone 4", + "unicode": "1f471-1f3fe" + }, + ":person_with_blond_hair_tone5:": { + "category": "people", + "name": "person with blond hair tone 5", + "unicode": "1f471-1f3ff" + }, + ":person_with_pouting_face:": { + "category": "people", + "name": "person with pouting face", + "unicode": "1f64e" + }, + ":person_with_pouting_face_tone1:": { + "category": "people", + "name": "person with pouting face tone1", + "unicode": "1f64e-1f3fb" + }, + ":person_with_pouting_face_tone2:": { + "category": "people", + "name": "person with pouting face tone2", + "unicode": "1f64e-1f3fc" + }, + ":person_with_pouting_face_tone3:": { + "category": "people", + "name": "person with pouting face tone3", + "unicode": "1f64e-1f3fd" + }, + ":person_with_pouting_face_tone4:": { + "category": "people", + "name": "person with pouting face tone4", + "unicode": "1f64e-1f3fe" + }, + ":person_with_pouting_face_tone5:": { + "category": "people", + "name": "person with pouting face tone5", + "unicode": "1f64e-1f3ff" + }, + ":pick:": { + "category": "objects", + "name": "pick", + "unicode": "26cf", + "unicode_alt": "26cf-fe0f" + }, + ":pig2:": { + "category": "nature", + "name": "pig", + "unicode": "1f416" + }, + ":pig:": { + "category": "nature", + "name": "pig face", + "unicode": "1f437" + }, + ":pig_nose:": { + "category": "nature", + "name": "pig nose", + "unicode": "1f43d" + }, + ":pill:": { + "category": "objects", + "name": "pill", + "unicode": "1f48a" + }, + ":pineapple:": { + "category": "food", + "name": "pineapple", + "unicode": "1f34d" + }, + ":ping_pong:": { + "category": "activity", + "name": "table tennis paddle and ball", + "unicode": "1f3d3" + }, + ":pisces:": { + "category": "symbols", + "name": "pisces", + "unicode": "2653", + "unicode_alt": "2653-fe0f" + }, + ":pizza:": { + "category": "food", + "name": "slice of pizza", + "unicode": "1f355" + }, + ":place_of_worship:": { + "category": "symbols", + "name": "place of worship", + "unicode": "1f6d0" + }, + ":play_pause:": { + "category": "symbols", + "name": "black right-pointing double triangle with double vertical bar", + "unicode": "23ef", + "unicode_alt": "23ef-fe0f" + }, + ":point_down:": { + "category": "people", + "name": "white down pointing backhand index", + "unicode": "1f447" + }, + ":point_down_tone1:": { + "category": "people", + "name": "white down pointing backhand index tone 1", + "unicode": "1f447-1f3fb" + }, + ":point_down_tone2:": { + "category": "people", + "name": "white down pointing backhand index tone 2", + "unicode": "1f447-1f3fc" + }, + ":point_down_tone3:": { + "category": "people", + "name": "white down pointing backhand index tone 3", + "unicode": "1f447-1f3fd" + }, + ":point_down_tone4:": { + "category": "people", + "name": "white down pointing backhand index tone 4", + "unicode": "1f447-1f3fe" + }, + ":point_down_tone5:": { + "category": "people", + "name": "white down pointing backhand index tone 5", + "unicode": "1f447-1f3ff" + }, + ":point_left:": { + "category": "people", + "name": "white left pointing backhand index", + "unicode": "1f448" + }, + ":point_left_tone1:": { + "category": "people", + "name": "white left pointing backhand index tone 1", + "unicode": "1f448-1f3fb" + }, + ":point_left_tone2:": { + "category": "people", + "name": "white left pointing backhand index tone 2", + "unicode": "1f448-1f3fc" + }, + ":point_left_tone3:": { + "category": "people", + "name": "white left pointing backhand index tone 3", + "unicode": "1f448-1f3fd" + }, + ":point_left_tone4:": { + "category": "people", + "name": "white left pointing backhand index tone 4", + "unicode": "1f448-1f3fe" + }, + ":point_left_tone5:": { + "category": "people", + "name": "white left pointing backhand index tone 5", + "unicode": "1f448-1f3ff" + }, + ":point_right:": { + "category": "people", + "name": "white right pointing backhand index", + "unicode": "1f449" + }, + ":point_right_tone1:": { + "category": "people", + "name": "white right pointing backhand index tone 1", + "unicode": "1f449-1f3fb" + }, + ":point_right_tone2:": { + "category": "people", + "name": "white right pointing backhand index tone 2", + "unicode": "1f449-1f3fc" + }, + ":point_right_tone3:": { + "category": "people", + "name": "white right pointing backhand index tone 3", + "unicode": "1f449-1f3fd" + }, + ":point_right_tone4:": { + "category": "people", + "name": "white right pointing backhand index tone 4", + "unicode": "1f449-1f3fe" + }, + ":point_right_tone5:": { + "category": "people", + "name": "white right pointing backhand index tone 5", + "unicode": "1f449-1f3ff" + }, + ":point_up:": { + "category": "people", + "name": "white up pointing index", + "unicode": "261d", + "unicode_alt": "261d-fe0f" + }, + ":point_up_2:": { + "category": "people", + "name": "white up pointing backhand index", + "unicode": "1f446" + }, + ":point_up_2_tone1:": { + "category": "people", + "name": "white up pointing backhand index tone 1", + "unicode": "1f446-1f3fb" + }, + ":point_up_2_tone2:": { + "category": "people", + "name": "white up pointing backhand index tone 2", + "unicode": "1f446-1f3fc" + }, + ":point_up_2_tone3:": { + "category": "people", + "name": "white up pointing backhand index tone 3", + "unicode": "1f446-1f3fd" + }, + ":point_up_2_tone4:": { + "category": "people", + "name": "white up pointing backhand index tone 4", + "unicode": "1f446-1f3fe" + }, + ":point_up_2_tone5:": { + "category": "people", + "name": "white up pointing backhand index tone 5", + "unicode": "1f446-1f3ff" + }, + ":point_up_tone1:": { + "category": "people", + "name": "white up pointing index tone 1", + "unicode": "261d-1f3fb" + }, + ":point_up_tone2:": { + "category": "people", + "name": "white up pointing index tone 2", + "unicode": "261d-1f3fc" + }, + ":point_up_tone3:": { + "category": "people", + "name": "white up pointing index tone 3", + "unicode": "261d-1f3fd" + }, + ":point_up_tone4:": { + "category": "people", + "name": "white up pointing index tone 4", + "unicode": "261d-1f3fe" + }, + ":point_up_tone5:": { + "category": "people", + "name": "white up pointing index tone 5", + "unicode": "261d-1f3ff" + }, + ":police_car:": { + "category": "travel", + "name": "police car", + "unicode": "1f693" + }, + ":poodle:": { + "category": "nature", + "name": "poodle", + "unicode": "1f429" + }, + ":poop:": { + "category": "people", + "name": "pile of poo", + "unicode": "1f4a9" + }, + ":popcorn:": { + "category": "food", + "name": "popcorn", + "unicode": "1f37f" + }, + ":post_office:": { + "category": "travel", + "name": "japanese post office", + "unicode": "1f3e3" + }, + ":postal_horn:": { + "category": "objects", + "name": "postal horn", + "unicode": "1f4ef" + }, + ":postbox:": { + "category": "objects", + "name": "postbox", + "unicode": "1f4ee" + }, + ":potable_water:": { + "category": "symbols", + "name": "potable water symbol", + "unicode": "1f6b0" + }, + ":potato:": { + "category": "food", + "name": "potato", + "unicode": "1f954" + }, + ":pouch:": { + "category": "people", + "name": "pouch", + "unicode": "1f45d" + }, + ":poultry_leg:": { + "category": "food", + "name": "poultry leg", + "unicode": "1f357" + }, + ":pound:": { + "category": "objects", + "name": "banknote with pound sign", + "unicode": "1f4b7" + }, + ":pouting_cat:": { + "category": "people", + "name": "pouting cat face", + "unicode": "1f63e" + }, + ":pray:": { + "category": "people", + "name": "person with folded hands", + "unicode": "1f64f" + }, + ":pray_tone1:": { + "category": "people", + "name": "person with folded hands tone 1", + "unicode": "1f64f-1f3fb" + }, + ":pray_tone2:": { + "category": "people", + "name": "person with folded hands tone 2", + "unicode": "1f64f-1f3fc" + }, + ":pray_tone3:": { + "category": "people", + "name": "person with folded hands tone 3", + "unicode": "1f64f-1f3fd" + }, + ":pray_tone4:": { + "category": "people", + "name": "person with folded hands tone 4", + "unicode": "1f64f-1f3fe" + }, + ":pray_tone5:": { + "category": "people", + "name": "person with folded hands tone 5", + "unicode": "1f64f-1f3ff" + }, + ":prayer_beads:": { + "category": "objects", + "name": "prayer beads", + "unicode": "1f4ff" + }, + ":pregnant_woman:": { + "category": "people", + "name": "pregnant woman", + "unicode": "1f930" + }, + ":pregnant_woman_tone1:": { + "category": "people", + "name": "pregnant woman tone 1", + "unicode": "1f930-1f3fb" + }, + ":pregnant_woman_tone2:": { + "category": "people", + "name": "pregnant woman tone 2", + "unicode": "1f930-1f3fc" + }, + ":pregnant_woman_tone3:": { + "category": "people", + "name": "pregnant woman tone 3", + "unicode": "1f930-1f3fd" + }, + ":pregnant_woman_tone4:": { + "category": "people", + "name": "pregnant woman tone 4", + "unicode": "1f930-1f3fe" + }, + ":pregnant_woman_tone5:": { + "category": "people", + "name": "pregnant woman tone 5", + "unicode": "1f930-1f3ff" + }, + ":prince:": { + "category": "people", + "name": "prince", + "unicode": "1f934" + }, + ":prince_tone1:": { + "category": "people", + "name": "prince tone 1", + "unicode": "1f934-1f3fb" + }, + ":prince_tone2:": { + "category": "people", + "name": "prince tone 2", + "unicode": "1f934-1f3fc" + }, + ":prince_tone3:": { + "category": "people", + "name": "prince tone 3", + "unicode": "1f934-1f3fd" + }, + ":prince_tone4:": { + "category": "people", + "name": "prince tone 4", + "unicode": "1f934-1f3fe" + }, + ":prince_tone5:": { + "category": "people", + "name": "prince tone 5", + "unicode": "1f934-1f3ff" + }, + ":princess:": { + "category": "people", + "name": "princess", + "unicode": "1f478" + }, + ":princess_tone1:": { + "category": "people", + "name": "princess tone 1", + "unicode": "1f478-1f3fb" + }, + ":princess_tone2:": { + "category": "people", + "name": "princess tone 2", + "unicode": "1f478-1f3fc" + }, + ":princess_tone3:": { + "category": "people", + "name": "princess tone 3", + "unicode": "1f478-1f3fd" + }, + ":princess_tone4:": { + "category": "people", + "name": "princess tone 4", + "unicode": "1f478-1f3fe" + }, + ":princess_tone5:": { + "category": "people", + "name": "princess tone 5", + "unicode": "1f478-1f3ff" + }, + ":printer:": { + "category": "objects", + "name": "printer", + "unicode": "1f5a8", + "unicode_alt": "1f5a8-fe0f" + }, + ":projector:": { + "category": "objects", + "name": "film projector", + "unicode": "1f4fd", + "unicode_alt": "1f4fd-fe0f" + }, + ":punch:": { + "category": "people", + "name": "fisted hand sign", + "unicode": "1f44a" + }, + ":punch_tone1:": { + "category": "people", + "name": "fisted hand sign tone 1", + "unicode": "1f44a-1f3fb" + }, + ":punch_tone2:": { + "category": "people", + "name": "fisted hand sign tone 2", + "unicode": "1f44a-1f3fc" + }, + ":punch_tone3:": { + "category": "people", + "name": "fisted hand sign tone 3", + "unicode": "1f44a-1f3fd" + }, + ":punch_tone4:": { + "category": "people", + "name": "fisted hand sign tone 4", + "unicode": "1f44a-1f3fe" + }, + ":punch_tone5:": { + "category": "people", + "name": "fisted hand sign tone 5", + "unicode": "1f44a-1f3ff" + }, + ":purple_heart:": { + "category": "symbols", + "name": "purple heart", + "unicode": "1f49c" + }, + ":purse:": { + "category": "people", + "name": "purse", + "unicode": "1f45b" + }, + ":pushpin:": { + "category": "objects", + "name": "pushpin", + "unicode": "1f4cc" + }, + ":put_litter_in_its_place:": { + "category": "symbols", + "name": "put litter in its place symbol", + "unicode": "1f6ae" + }, + ":question:": { + "category": "symbols", + "name": "black question mark ornament", + "unicode": "2753" + }, + ":rabbit2:": { + "category": "nature", + "name": "rabbit", + "unicode": "1f407" + }, + ":rabbit:": { + "category": "nature", + "name": "rabbit face", + "unicode": "1f430" + }, + ":race_car:": { + "category": "travel", + "name": "racing car", + "unicode": "1f3ce", + "unicode_alt": "1f3ce-fe0f" + }, + ":racehorse:": { + "category": "nature", + "name": "horse", + "unicode": "1f40e" + }, + ":radio:": { + "category": "objects", + "name": "radio", + "unicode": "1f4fb" + }, + ":radio_button:": { + "category": "symbols", + "name": "radio button", + "unicode": "1f518" + }, + ":radioactive:": { + "category": "symbols", + "name": "radioactive sign", + "unicode": "2622", + "unicode_alt": "2622-fe0f" + }, + ":rage:": { + "category": "people", + "name": "pouting face", + "unicode": "1f621" + }, + ":railway_car:": { + "category": "travel", + "name": "railway car", + "unicode": "1f683" + }, + ":railway_track:": { + "category": "travel", + "name": "railway track", + "unicode": "1f6e4", + "unicode_alt": "1f6e4-fe0f" + }, + ":rainbow:": { + "category": "travel", + "name": "rainbow", + "unicode": "1f308" + }, + ":rainbow_flag:": { + "category": "objects", + "name": "rainbow_flag", + "unicode": "1f3f3-1f308" + }, + ":raised_back_of_hand:": { + "category": "people", + "name": "raised back of hand", + "unicode": "1f91a" + }, + ":raised_back_of_hand_tone1:": { + "category": "people", + "name": "raised back of hand tone 1", + "unicode": "1f91a-1f3fb" + }, + ":raised_back_of_hand_tone2:": { + "category": "people", + "name": "raised back of hand tone 2", + "unicode": "1f91a-1f3fc" + }, + ":raised_back_of_hand_tone3:": { + "category": "people", + "name": "raised back of hand tone 3", + "unicode": "1f91a-1f3fd" + }, + ":raised_back_of_hand_tone4:": { + "category": "people", + "name": "raised back of hand tone 4", + "unicode": "1f91a-1f3fe" + }, + ":raised_back_of_hand_tone5:": { + "category": "people", + "name": "raised back of hand tone 5", + "unicode": "1f91a-1f3ff" + }, + ":raised_hand:": { + "category": "people", + "name": "raised hand", + "unicode": "270b" + }, + ":raised_hand_tone1:": { + "category": "people", + "name": "raised hand tone 1", + "unicode": "270b-1f3fb" + }, + ":raised_hand_tone2:": { + "category": "people", + "name": "raised hand tone 2", + "unicode": "270b-1f3fc" + }, + ":raised_hand_tone3:": { + "category": "people", + "name": "raised hand tone 3", + "unicode": "270b-1f3fd" + }, + ":raised_hand_tone4:": { + "category": "people", + "name": "raised hand tone 4", + "unicode": "270b-1f3fe" + }, + ":raised_hand_tone5:": { + "category": "people", + "name": "raised hand tone 5", + "unicode": "270b-1f3ff" + }, + ":raised_hands:": { + "category": "people", + "name": "person raising both hands in celebration", + "unicode": "1f64c" + }, + ":raised_hands_tone1:": { + "category": "people", + "name": "person raising both hands in celebration tone 1", + "unicode": "1f64c-1f3fb" + }, + ":raised_hands_tone2:": { + "category": "people", + "name": "person raising both hands in celebration tone 2", + "unicode": "1f64c-1f3fc" + }, + ":raised_hands_tone3:": { + "category": "people", + "name": "person raising both hands in celebration tone 3", + "unicode": "1f64c-1f3fd" + }, + ":raised_hands_tone4:": { + "category": "people", + "name": "person raising both hands in celebration tone 4", + "unicode": "1f64c-1f3fe" + }, + ":raised_hands_tone5:": { + "category": "people", + "name": "person raising both hands in celebration tone 5", + "unicode": "1f64c-1f3ff" + }, + ":raising_hand:": { + "category": "people", + "name": "happy person raising one hand", + "unicode": "1f64b" + }, + ":raising_hand_tone1:": { + "category": "people", + "name": "happy person raising one hand tone1", + "unicode": "1f64b-1f3fb" + }, + ":raising_hand_tone2:": { + "category": "people", + "name": "happy person raising one hand tone2", + "unicode": "1f64b-1f3fc" + }, + ":raising_hand_tone3:": { + "category": "people", + "name": "happy person raising one hand tone3", + "unicode": "1f64b-1f3fd" + }, + ":raising_hand_tone4:": { + "category": "people", + "name": "happy person raising one hand tone4", + "unicode": "1f64b-1f3fe" + }, + ":raising_hand_tone5:": { + "category": "people", + "name": "happy person raising one hand tone5", + "unicode": "1f64b-1f3ff" + }, + ":ram:": { + "category": "nature", + "name": "ram", + "unicode": "1f40f" + }, + ":ramen:": { + "category": "food", + "name": "steaming bowl", + "unicode": "1f35c" + }, + ":rat:": { + "category": "nature", + "name": "rat", + "unicode": "1f400" + }, + ":record_button:": { + "category": "symbols", + "name": "black circle for record", + "unicode": "23fa", + "unicode_alt": "23fa-fe0f" + }, + ":recycle:": { + "category": "symbols", + "name": "black universal recycling symbol", + "unicode": "267b", + "unicode_alt": "267b-fe0f" + }, + ":red_car:": { + "category": "travel", + "name": "automobile", + "unicode": "1f697" + }, + ":red_circle:": { + "category": "symbols", + "name": "red circle", + "unicode": "1f534" + }, + ":regional_indicator_a:": { + "category": "regional", + "name": "regional indicator symbol letter a", + "unicode": "1f1e6" + }, + ":regional_indicator_b:": { + "category": "regional", + "name": "regional indicator symbol letter b", + "unicode": "1f1e7" + }, + ":regional_indicator_c:": { + "category": "regional", + "name": "regional indicator symbol letter c", + "unicode": "1f1e8" + }, + ":regional_indicator_d:": { + "category": "regional", + "name": "regional indicator symbol letter d", + "unicode": "1f1e9" + }, + ":regional_indicator_e:": { + "category": "regional", + "name": "regional indicator symbol letter e", + "unicode": "1f1ea" + }, + ":regional_indicator_f:": { + "category": "regional", + "name": "regional indicator symbol letter f", + "unicode": "1f1eb" + }, + ":regional_indicator_g:": { + "category": "regional", + "name": "regional indicator symbol letter g", + "unicode": "1f1ec" + }, + ":regional_indicator_h:": { + "category": "regional", + "name": "regional indicator symbol letter h", + "unicode": "1f1ed" + }, + ":regional_indicator_i:": { + "category": "regional", + "name": "regional indicator symbol letter i", + "unicode": "1f1ee" + }, + ":regional_indicator_j:": { + "category": "regional", + "name": "regional indicator symbol letter j", + "unicode": "1f1ef" + }, + ":regional_indicator_k:": { + "category": "regional", + "name": "regional indicator symbol letter k", + "unicode": "1f1f0" + }, + ":regional_indicator_l:": { + "category": "regional", + "name": "regional indicator symbol letter l", + "unicode": "1f1f1" + }, + ":regional_indicator_m:": { + "category": "regional", + "name": "regional indicator symbol letter m", + "unicode": "1f1f2" + }, + ":regional_indicator_n:": { + "category": "regional", + "name": "regional indicator symbol letter n", + "unicode": "1f1f3" + }, + ":regional_indicator_o:": { + "category": "regional", + "name": "regional indicator symbol letter o", + "unicode": "1f1f4" + }, + ":regional_indicator_p:": { + "category": "regional", + "name": "regional indicator symbol letter p", + "unicode": "1f1f5" + }, + ":regional_indicator_q:": { + "category": "regional", + "name": "regional indicator symbol letter q", + "unicode": "1f1f6" + }, + ":regional_indicator_r:": { + "category": "regional", + "name": "regional indicator symbol letter r", + "unicode": "1f1f7" + }, + ":regional_indicator_s:": { + "category": "regional", + "name": "regional indicator symbol letter s", + "unicode": "1f1f8" + }, + ":regional_indicator_t:": { + "category": "regional", + "name": "regional indicator symbol letter t", + "unicode": "1f1f9" + }, + ":regional_indicator_u:": { + "category": "regional", + "name": "regional indicator symbol letter u", + "unicode": "1f1fa" + }, + ":regional_indicator_v:": { + "category": "regional", + "name": "regional indicator symbol letter v", + "unicode": "1f1fb" + }, + ":regional_indicator_w:": { + "category": "regional", + "name": "regional indicator symbol letter w", + "unicode": "1f1fc" + }, + ":regional_indicator_x:": { + "category": "regional", + "name": "regional indicator symbol letter x", + "unicode": "1f1fd" + }, + ":regional_indicator_y:": { + "category": "regional", + "name": "regional indicator symbol letter y", + "unicode": "1f1fe" + }, + ":regional_indicator_z:": { + "category": "regional", + "name": "regional indicator symbol letter z", + "unicode": "1f1ff" + }, + ":registered:": { + "category": "symbols", + "name": "registered sign", + "unicode": "00ae", + "unicode_alt": "00ae-fe0f" + }, + ":relaxed:": { + "category": "people", + "name": "white smiling face", + "unicode": "263a", + "unicode_alt": "263a-fe0f" + }, + ":relieved:": { + "category": "people", + "name": "relieved face", + "unicode": "1f60c" + }, + ":reminder_ribbon:": { + "category": "activity", + "name": "reminder ribbon", + "unicode": "1f397", + "unicode_alt": "1f397-fe0f" + }, + ":repeat:": { + "category": "symbols", + "name": "clockwise rightwards and leftwards open circle arrows", + "unicode": "1f501" + }, + ":repeat_one:": { + "category": "symbols", + "name": "clockwise rightwards and leftwards open circle arrows with circled one overlay", + "unicode": "1f502" + }, + ":restroom:": { + "category": "symbols", + "name": "restroom", + "unicode": "1f6bb" + }, + ":revolving_hearts:": { + "category": "symbols", + "name": "revolving hearts", + "unicode": "1f49e" + }, + ":rewind:": { + "category": "symbols", + "name": "black left-pointing double triangle", + "unicode": "23ea" + }, + ":rhino:": { + "category": "nature", + "name": "rhinoceros", + "unicode": "1f98f" + }, + ":ribbon:": { + "category": "objects", + "name": "ribbon", + "unicode": "1f380" + }, + ":rice:": { + "category": "food", + "name": "cooked rice", + "unicode": "1f35a" + }, + ":rice_ball:": { + "category": "food", + "name": "rice ball", + "unicode": "1f359" + }, + ":rice_cracker:": { + "category": "food", + "name": "rice cracker", + "unicode": "1f358" + }, + ":rice_scene:": { + "category": "travel", + "name": "moon viewing ceremony", + "unicode": "1f391" + }, + ":right_facing_fist:": { + "category": "people", + "name": "right-facing fist", + "unicode": "1f91c" + }, + ":right_facing_fist_tone1:": { + "category": "people", + "name": "right facing fist tone 1", + "unicode": "1f91c-1f3fb" + }, + ":right_facing_fist_tone2:": { + "category": "people", + "name": "right facing fist tone 2", + "unicode": "1f91c-1f3fc" + }, + ":right_facing_fist_tone3:": { + "category": "people", + "name": "right facing fist tone 3", + "unicode": "1f91c-1f3fd" + }, + ":right_facing_fist_tone4:": { + "category": "people", + "name": "right facing fist tone 4", + "unicode": "1f91c-1f3fe" + }, + ":right_facing_fist_tone5:": { + "category": "people", + "name": "right facing fist tone 5", + "unicode": "1f91c-1f3ff" + }, + ":ring:": { + "category": "people", + "name": "ring", + "unicode": "1f48d" + }, + ":robot:": { + "category": "people", + "name": "robot face", + "unicode": "1f916" + }, + ":rocket:": { + "category": "travel", + "name": "rocket", + "unicode": "1f680" + }, + ":rofl:": { + "category": "people", + "name": "rolling on the floor laughing", + "unicode": "1f923" + }, + ":roller_coaster:": { + "category": "travel", + "name": "roller coaster", + "unicode": "1f3a2" + }, + ":rolling_eyes:": { + "category": "people", + "name": "face with rolling eyes", + "unicode": "1f644" + }, + ":rooster:": { + "category": "nature", + "name": "rooster", + "unicode": "1f413" + }, + ":rose:": { + "category": "nature", + "name": "rose", + "unicode": "1f339" + }, + ":rosette:": { + "category": "nature", + "name": "rosette", + "unicode": "1f3f5", + "unicode_alt": "1f3f5-fe0f" + }, + ":rotating_light:": { + "category": "travel", + "name": "police cars revolving light", + "unicode": "1f6a8" + }, + ":round_pushpin:": { + "category": "objects", + "name": "round pushpin", + "unicode": "1f4cd" + }, + ":rowboat:": { + "category": "activity", + "name": "rowboat", + "unicode": "1f6a3" + }, + ":rowboat_tone1:": { + "category": "activity", + "name": "rowboat tone 1", + "unicode": "1f6a3-1f3fb" + }, + ":rowboat_tone2:": { + "category": "activity", + "name": "rowboat tone 2", + "unicode": "1f6a3-1f3fc" + }, + ":rowboat_tone3:": { + "category": "activity", + "name": "rowboat tone 3", + "unicode": "1f6a3-1f3fd" + }, + ":rowboat_tone4:": { + "category": "activity", + "name": "rowboat tone 4", + "unicode": "1f6a3-1f3fe" + }, + ":rowboat_tone5:": { + "category": "activity", + "name": "rowboat tone 5", + "unicode": "1f6a3-1f3ff" + }, + ":rugby_football:": { + "category": "activity", + "name": "rugby football", + "unicode": "1f3c9" + }, + ":runner:": { + "category": "people", + "name": "runner", + "unicode": "1f3c3" + }, + ":runner_tone1:": { + "category": "people", + "name": "runner tone 1", + "unicode": "1f3c3-1f3fb" + }, + ":runner_tone2:": { + "category": "people", + "name": "runner tone 2", + "unicode": "1f3c3-1f3fc" + }, + ":runner_tone3:": { + "category": "people", + "name": "runner tone 3", + "unicode": "1f3c3-1f3fd" + }, + ":runner_tone4:": { + "category": "people", + "name": "runner tone 4", + "unicode": "1f3c3-1f3fe" + }, + ":runner_tone5:": { + "category": "people", + "name": "runner tone 5", + "unicode": "1f3c3-1f3ff" + }, + ":running_shirt_with_sash:": { + "category": "activity", + "name": "running shirt with sash", + "unicode": "1f3bd" + }, + ":sa:": { + "category": "symbols", + "name": "squared katakana sa", + "unicode": "1f202", + "unicode_alt": "1f202-fe0f" + }, + ":sagittarius:": { + "category": "symbols", + "name": "sagittarius", + "unicode": "2650", + "unicode_alt": "2650-fe0f" + }, + ":sailboat:": { + "category": "travel", + "name": "sailboat", + "unicode": "26f5", + "unicode_alt": "26f5-fe0f" + }, + ":sake:": { + "category": "food", + "name": "sake bottle and cup", + "unicode": "1f376" + }, + ":salad:": { + "category": "food", + "name": "green salad", + "unicode": "1f957" + }, + ":sandal:": { + "category": "people", + "name": "womans sandal", + "unicode": "1f461" + }, + ":santa:": { + "category": "people", + "name": "father christmas", + "unicode": "1f385" + }, + ":santa_tone1:": { + "category": "people", + "name": "father christmas tone 1", + "unicode": "1f385-1f3fb" + }, + ":santa_tone2:": { + "category": "people", + "name": "father christmas tone 2", + "unicode": "1f385-1f3fc" + }, + ":santa_tone3:": { + "category": "people", + "name": "father christmas tone 3", + "unicode": "1f385-1f3fd" + }, + ":santa_tone4:": { + "category": "people", + "name": "father christmas tone 4", + "unicode": "1f385-1f3fe" + }, + ":santa_tone5:": { + "category": "people", + "name": "father christmas tone 5", + "unicode": "1f385-1f3ff" + }, + ":satellite:": { + "category": "objects", + "name": "satellite antenna", + "unicode": "1f4e1" + }, + ":satellite_orbital:": { + "category": "travel", + "name": "satellite", + "unicode": "1f6f0", + "unicode_alt": "1f6f0-fe0f" + }, + ":saxophone:": { + "category": "activity", + "name": "saxophone", + "unicode": "1f3b7" + }, + ":scales:": { + "category": "objects", + "name": "scales", + "unicode": "2696", + "unicode_alt": "2696-fe0f" + }, + ":school:": { + "category": "travel", + "name": "school", + "unicode": "1f3eb" + }, + ":school_satchel:": { + "category": "people", + "name": "school satchel", + "unicode": "1f392" + }, + ":scissors:": { + "category": "objects", + "name": "black scissors", + "unicode": "2702", + "unicode_alt": "2702-fe0f" + }, + ":scooter:": { + "category": "travel", + "name": "scooter", + "unicode": "1f6f4" + }, + ":scorpion:": { + "category": "nature", + "name": "scorpion", + "unicode": "1f982" + }, + ":scorpius:": { + "category": "symbols", + "name": "scorpius", + "unicode": "264f", + "unicode_alt": "264f-fe0f" + }, + ":scream:": { + "category": "people", + "name": "face screaming in fear", + "unicode": "1f631" + }, + ":scream_cat:": { + "category": "people", + "name": "weary cat face", + "unicode": "1f640" + }, + ":scroll:": { + "category": "objects", + "name": "scroll", + "unicode": "1f4dc" + }, + ":seat:": { + "category": "travel", + "name": "seat", + "unicode": "1f4ba" + }, + ":second_place:": { + "category": "activity", + "name": "second place medal", + "unicode": "1f948" + }, + ":secret:": { + "category": "symbols", + "name": "circled ideograph secret", + "unicode": "3299", + "unicode_alt": "3299-fe0f" + }, + ":see_no_evil:": { + "category": "nature", + "name": "see-no-evil monkey", + "unicode": "1f648" + }, + ":seedling:": { + "category": "nature", + "name": "seedling", + "unicode": "1f331" + }, + ":selfie:": { + "category": "people", + "name": "selfie", + "unicode": "1f933" + }, + ":selfie_tone1:": { + "category": "people", + "name": "selfie tone 1", + "unicode": "1f933-1f3fb" + }, + ":selfie_tone2:": { + "category": "people", + "name": "selfie tone 2", + "unicode": "1f933-1f3fc" + }, + ":selfie_tone3:": { + "category": "people", + "name": "selfie tone 3", + "unicode": "1f933-1f3fd" + }, + ":selfie_tone4:": { + "category": "people", + "name": "selfie tone 4", + "unicode": "1f933-1f3fe" + }, + ":selfie_tone5:": { + "category": "people", + "name": "selfie tone 5", + "unicode": "1f933-1f3ff" + }, + ":seven:": { + "category": "symbols", + "name": "keycap digit seven", + "unicode": "0037-20e3", + "unicode_alt": "0037-fe0f-20e3" + }, + ":shallow_pan_of_food:": { + "category": "food", + "name": "shallow pan of food", + "unicode": "1f958" + }, + ":shamrock:": { + "category": "nature", + "name": "shamrock", + "unicode": "2618", + "unicode_alt": "2618-fe0f" + }, + ":shark:": { + "category": "nature", + "name": "shark", + "unicode": "1f988" + }, + ":shaved_ice:": { + "category": "food", + "name": "shaved ice", + "unicode": "1f367" + }, + ":sheep:": { + "category": "nature", + "name": "sheep", + "unicode": "1f411" + }, + ":shell:": { + "category": "nature", + "name": "spiral shell", + "unicode": "1f41a" + }, + ":shield:": { + "category": "objects", + "name": "shield", + "unicode": "1f6e1", + "unicode_alt": "1f6e1-fe0f" + }, + ":shinto_shrine:": { + "category": "travel", + "name": "shinto shrine", + "unicode": "26e9", + "unicode_alt": "26e9-fe0f" + }, + ":ship:": { + "category": "travel", + "name": "ship", + "unicode": "1f6a2" + }, + ":shirt:": { + "category": "people", + "name": "t-shirt", + "unicode": "1f455" + }, + ":shopping_bags:": { + "category": "objects", + "name": "shopping bags", + "unicode": "1f6cd", + "unicode_alt": "1f6cd-fe0f" + }, + ":shopping_cart:": { + "category": "objects", + "name": "shopping trolley", + "unicode": "1f6d2" + }, + ":shower:": { + "category": "objects", + "name": "shower", + "unicode": "1f6bf" + }, + ":shrimp:": { + "category": "nature", + "name": "shrimp", + "unicode": "1f990" + }, + ":shrug:": { + "category": "people", + "name": "shrug", + "unicode": "1f937" + }, + ":shrug_tone1:": { + "category": "people", + "name": "shrug tone 1", + "unicode": "1f937-1f3fb" + }, + ":shrug_tone2:": { + "category": "people", + "name": "shrug tone 2", + "unicode": "1f937-1f3fc" + }, + ":shrug_tone3:": { + "category": "people", + "name": "shrug tone 3", + "unicode": "1f937-1f3fd" + }, + ":shrug_tone4:": { + "category": "people", + "name": "shrug tone 4", + "unicode": "1f937-1f3fe" + }, + ":shrug_tone5:": { + "category": "people", + "name": "shrug tone 5", + "unicode": "1f937-1f3ff" + }, + ":signal_strength:": { + "category": "symbols", + "name": "antenna with bars", + "unicode": "1f4f6" + }, + ":six:": { + "category": "symbols", + "name": "keycap digit six", + "unicode": "0036-20e3", + "unicode_alt": "0036-fe0f-20e3" + }, + ":six_pointed_star:": { + "category": "symbols", + "name": "six pointed star with middle dot", + "unicode": "1f52f" + }, + ":ski:": { + "category": "activity", + "name": "ski and ski boot", + "unicode": "1f3bf" + }, + ":skier:": { + "category": "activity", + "name": "skier", + "unicode": "26f7", + "unicode_alt": "26f7-fe0f" + }, + ":skull:": { + "category": "people", + "name": "skull", + "unicode": "1f480" + }, + ":skull_crossbones:": { + "category": "objects", + "name": "skull and crossbones", + "unicode": "2620", + "unicode_alt": "2620-fe0f" + }, + ":sleeping:": { + "category": "people", + "name": "sleeping face", + "unicode": "1f634" + }, + ":sleeping_accommodation:": { + "category": "objects", + "name": "sleeping accommodation", + "unicode": "1f6cc" + }, + ":sleepy:": { + "category": "people", + "name": "sleepy face", + "unicode": "1f62a" + }, + ":slight_frown:": { + "category": "people", + "name": "slightly frowning face", + "unicode": "1f641" + }, + ":slight_smile:": { + "category": "people", + "name": "slightly smiling face", + "unicode": "1f642" + }, + ":slot_machine:": { + "category": "activity", + "name": "slot machine", + "unicode": "1f3b0" + }, + ":small_blue_diamond:": { + "category": "symbols", + "name": "small blue diamond", + "unicode": "1f539" + }, + ":small_orange_diamond:": { + "category": "symbols", + "name": "small orange diamond", + "unicode": "1f538" + }, + ":small_red_triangle:": { + "category": "symbols", + "name": "up-pointing red triangle", + "unicode": "1f53a" + }, + ":small_red_triangle_down:": { + "category": "symbols", + "name": "down-pointing red triangle", + "unicode": "1f53b" + }, + ":smile:": { + "category": "people", + "name": "smiling face with open mouth and smiling eyes", + "unicode": "1f604" + }, + ":smile_cat:": { + "category": "people", + "name": "grinning cat face with smiling eyes", + "unicode": "1f638" + }, + ":smiley:": { + "category": "people", + "name": "smiling face with open mouth", + "unicode": "1f603" + }, + ":smiley_cat:": { + "category": "people", + "name": "smiling cat face with open mouth", + "unicode": "1f63a" + }, + ":smiling_imp:": { + "category": "people", + "name": "smiling face with horns", + "unicode": "1f608" + }, + ":smirk:": { + "category": "people", + "name": "smirking face", + "unicode": "1f60f" + }, + ":smirk_cat:": { + "category": "people", + "name": "cat face with wry smile", + "unicode": "1f63c" + }, + ":smoking:": { + "category": "objects", + "name": "smoking symbol", + "unicode": "1f6ac" + }, + ":snail:": { + "category": "nature", + "name": "snail", + "unicode": "1f40c" + }, + ":snake:": { + "category": "nature", + "name": "snake", + "unicode": "1f40d" + }, + ":sneezing_face:": { + "category": "people", + "name": "sneezing face", + "unicode": "1f927" + }, + ":snowboarder:": { + "category": "activity", + "name": "snowboarder", + "unicode": "1f3c2" + }, + ":snowflake:": { + "category": "nature", + "name": "snowflake", + "unicode": "2744", + "unicode_alt": "2744-fe0f" + }, + ":snowman2:": { + "category": "nature", + "name": "snowman", + "unicode": "2603", + "unicode_alt": "2603-fe0f" + }, + ":snowman:": { + "category": "nature", + "name": "snowman without snow", + "unicode": "26c4", + "unicode_alt": "26c4-fe0f" + }, + ":sob:": { + "category": "people", + "name": "loudly crying face", + "unicode": "1f62d" + }, + ":soccer:": { + "category": "activity", + "name": "soccer ball", + "unicode": "26bd", + "unicode_alt": "26bd-fe0f" + }, + ":soon:": { + "category": "symbols", + "name": "soon with rightwards arrow above", + "unicode": "1f51c" + }, + ":sos:": { + "category": "symbols", + "name": "squared sos", + "unicode": "1f198" + }, + ":sound:": { + "category": "symbols", + "name": "speaker with one sound wave", + "unicode": "1f509" + }, + ":space_invader:": { + "category": "activity", + "name": "alien monster", + "unicode": "1f47e" + }, + ":spades:": { + "category": "symbols", + "name": "black spade suit", + "unicode": "2660", + "unicode_alt": "2660-fe0f" + }, + ":spaghetti:": { + "category": "food", + "name": "spaghetti", + "unicode": "1f35d" + }, + ":sparkle:": { + "category": "symbols", + "name": "sparkle", + "unicode": "2747", + "unicode_alt": "2747-fe0f" + }, + ":sparkler:": { + "category": "travel", + "name": "firework sparkler", + "unicode": "1f387" + }, + ":sparkles:": { + "category": "nature", + "name": "sparkles", + "unicode": "2728" + }, + ":sparkling_heart:": { + "category": "symbols", + "name": "sparkling heart", + "unicode": "1f496" + }, + ":speak_no_evil:": { + "category": "nature", + "name": "speak-no-evil monkey", + "unicode": "1f64a" + }, + ":speaker:": { + "category": "symbols", + "name": "speaker", + "unicode": "1f508" + }, + ":speaking_head:": { + "category": "people", + "name": "speaking head in silhouette", + "unicode": "1f5e3", + "unicode_alt": "1f5e3-fe0f" + }, + ":speech_balloon:": { + "category": "symbols", + "name": "speech balloon", + "unicode": "1f4ac" + }, + ":speech_left:": { + "category": "symbols", + "name": "left speech bubble", + "unicode": "1f5e8", + "unicode_alt": "1f5e8-fe0f" + }, + ":speedboat:": { + "category": "travel", + "name": "speedboat", + "unicode": "1f6a4" + }, + ":spider:": { + "category": "nature", + "name": "spider", + "unicode": "1f577", + "unicode_alt": "1f577-fe0f" + }, + ":spider_web:": { + "category": "nature", + "name": "spider web", + "unicode": "1f578", + "unicode_alt": "1f578-fe0f" + }, + ":spoon:": { + "category": "food", + "name": "spoon", + "unicode": "1f944" + }, + ":spy:": { + "category": "people", + "name": "sleuth or spy", + "unicode": "1f575", + "unicode_alt": "1f575-fe0f" + }, + ":spy_tone1:": { + "category": "people", + "name": "sleuth or spy tone 1", + "unicode": "1f575-1f3fb" + }, + ":spy_tone2:": { + "category": "people", + "name": "sleuth or spy tone 2", + "unicode": "1f575-1f3fc" + }, + ":spy_tone3:": { + "category": "people", + "name": "sleuth or spy tone 3", + "unicode": "1f575-1f3fd" + }, + ":spy_tone4:": { + "category": "people", + "name": "sleuth or spy tone 4", + "unicode": "1f575-1f3fe" + }, + ":spy_tone5:": { + "category": "people", + "name": "sleuth or spy tone 5", + "unicode": "1f575-1f3ff" + }, + ":squid:": { + "category": "nature", + "name": "squid", + "unicode": "1f991" + }, + ":stadium:": { + "category": "travel", + "name": "stadium", + "unicode": "1f3df", + "unicode_alt": "1f3df-fe0f" + }, + ":star2:": { + "category": "nature", + "name": "glowing star", + "unicode": "1f31f" + }, + ":star:": { + "category": "nature", + "name": "white medium star", + "unicode": "2b50", + "unicode_alt": "2b50-fe0f" + }, + ":star_and_crescent:": { + "category": "symbols", + "name": "star and crescent", + "unicode": "262a", + "unicode_alt": "262a-fe0f" + }, + ":star_of_david:": { + "category": "symbols", + "name": "star of david", + "unicode": "2721", + "unicode_alt": "2721-fe0f" + }, + ":stars:": { + "category": "travel", + "name": "shooting star", + "unicode": "1f320" + }, + ":station:": { + "category": "travel", + "name": "station", + "unicode": "1f689" + }, + ":statue_of_liberty:": { + "category": "travel", + "name": "statue of liberty", + "unicode": "1f5fd" + }, + ":steam_locomotive:": { + "category": "travel", + "name": "steam locomotive", + "unicode": "1f682" + }, + ":stew:": { + "category": "food", + "name": "pot of food", + "unicode": "1f372" + }, + ":stop_button:": { + "category": "symbols", + "name": "black square for stop", + "unicode": "23f9", + "unicode_alt": "23f9-fe0f" + }, + ":stopwatch:": { + "category": "objects", + "name": "stopwatch", + "unicode": "23f1", + "unicode_alt": "23f1-fe0f" + }, + ":straight_ruler:": { + "category": "objects", + "name": "straight ruler", + "unicode": "1f4cf" + }, + ":strawberry:": { + "category": "food", + "name": "strawberry", + "unicode": "1f353" + }, + ":stuck_out_tongue:": { + "category": "people", + "name": "face with stuck-out tongue", + "unicode": "1f61b" + }, + ":stuck_out_tongue_closed_eyes:": { + "category": "people", + "name": "face with stuck-out tongue and tightly-closed eyes", + "unicode": "1f61d" + }, + ":stuck_out_tongue_winking_eye:": { + "category": "people", + "name": "face with stuck-out tongue and winking eye", + "unicode": "1f61c" + }, + ":stuffed_flatbread:": { + "category": "food", + "name": "stuffed flatbread", + "unicode": "1f959" + }, + ":sun_with_face:": { + "category": "nature", + "name": "sun with face", + "unicode": "1f31e" + }, + ":sunflower:": { + "category": "nature", + "name": "sunflower", + "unicode": "1f33b" + }, + ":sunglasses:": { + "category": "people", + "name": "smiling face with sunglasses", + "unicode": "1f60e" + }, + ":sunny:": { + "category": "nature", + "name": "black sun with rays", + "unicode": "2600", + "unicode_alt": "2600-fe0f" + }, + ":sunrise:": { + "category": "travel", + "name": "sunrise", + "unicode": "1f305" + }, + ":sunrise_over_mountains:": { + "category": "travel", + "name": "sunrise over mountains", + "unicode": "1f304" + }, + ":surfer:": { + "category": "activity", + "name": "surfer", + "unicode": "1f3c4" + }, + ":surfer_tone1:": { + "category": "activity", + "name": "surfer tone 1", + "unicode": "1f3c4-1f3fb" + }, + ":surfer_tone2:": { + "category": "activity", + "name": "surfer tone 2", + "unicode": "1f3c4-1f3fc" + }, + ":surfer_tone3:": { + "category": "activity", + "name": "surfer tone 3", + "unicode": "1f3c4-1f3fd" + }, + ":surfer_tone4:": { + "category": "activity", + "name": "surfer tone 4", + "unicode": "1f3c4-1f3fe" + }, + ":surfer_tone5:": { + "category": "activity", + "name": "surfer tone 5", + "unicode": "1f3c4-1f3ff" + }, + ":sushi:": { + "category": "food", + "name": "sushi", + "unicode": "1f363" + }, + ":suspension_railway:": { + "category": "travel", + "name": "suspension railway", + "unicode": "1f69f" + }, + ":sweat:": { + "category": "people", + "name": "face with cold sweat", + "unicode": "1f613" + }, + ":sweat_drops:": { + "category": "nature", + "name": "splashing sweat symbol", + "unicode": "1f4a6" + }, + ":sweat_smile:": { + "category": "people", + "name": "smiling face with open mouth and cold sweat", + "unicode": "1f605" + }, + ":sweet_potato:": { + "category": "food", + "name": "roasted sweet potato", + "unicode": "1f360" + }, + ":swimmer:": { + "category": "activity", + "name": "swimmer", + "unicode": "1f3ca" + }, + ":swimmer_tone1:": { + "category": "activity", + "name": "swimmer tone 1", + "unicode": "1f3ca-1f3fb" + }, + ":swimmer_tone2:": { + "category": "activity", + "name": "swimmer tone 2", + "unicode": "1f3ca-1f3fc" + }, + ":swimmer_tone3:": { + "category": "activity", + "name": "swimmer tone 3", + "unicode": "1f3ca-1f3fd" + }, + ":swimmer_tone4:": { + "category": "activity", + "name": "swimmer tone 4", + "unicode": "1f3ca-1f3fe" + }, + ":swimmer_tone5:": { + "category": "activity", + "name": "swimmer tone 5", + "unicode": "1f3ca-1f3ff" + }, + ":symbols:": { + "category": "symbols", + "name": "input symbol for symbols", + "unicode": "1f523" + }, + ":synagogue:": { + "category": "travel", + "name": "synagogue", + "unicode": "1f54d" + }, + ":syringe:": { + "category": "objects", + "name": "syringe", + "unicode": "1f489" + }, + ":taco:": { + "category": "food", + "name": "taco", + "unicode": "1f32e" + }, + ":tada:": { + "category": "objects", + "name": "party popper", + "unicode": "1f389" + }, + ":tanabata_tree:": { + "category": "nature", + "name": "tanabata tree", + "unicode": "1f38b" + }, + ":tangerine:": { + "category": "food", + "name": "tangerine", + "unicode": "1f34a" + }, + ":taurus:": { + "category": "symbols", + "name": "taurus", + "unicode": "2649", + "unicode_alt": "2649-fe0f" + }, + ":taxi:": { + "category": "travel", + "name": "taxi", + "unicode": "1f695" + }, + ":tea:": { + "category": "food", + "name": "teacup without handle", + "unicode": "1f375" + }, + ":telephone:": { + "category": "objects", + "name": "black telephone", + "unicode": "260e", + "unicode_alt": "260e-fe0f" + }, + ":telephone_receiver:": { + "category": "objects", + "name": "telephone receiver", + "unicode": "1f4de" + }, + ":telescope:": { + "category": "objects", + "name": "telescope", + "unicode": "1f52d" + }, + ":tennis:": { + "category": "activity", + "name": "tennis racquet and ball", + "unicode": "1f3be" + }, + ":tent:": { + "category": "travel", + "name": "tent", + "unicode": "26fa", + "unicode_alt": "26fa-fe0f" + }, + ":thermometer:": { + "category": "objects", + "name": "thermometer", + "unicode": "1f321", + "unicode_alt": "1f321-fe0f" + }, + ":thermometer_face:": { + "category": "people", + "name": "face with thermometer", + "unicode": "1f912" + }, + ":thinking:": { + "category": "people", + "name": "thinking face", + "unicode": "1f914" + }, + ":third_place:": { + "category": "activity", + "name": "third place medal", + "unicode": "1f949" + }, + ":thought_balloon:": { + "category": "symbols", + "name": "thought balloon", + "unicode": "1f4ad" + }, + ":three:": { + "category": "symbols", + "name": "keycap digit three", + "unicode": "0033-20e3", + "unicode_alt": "0033-fe0f-20e3" + }, + ":thumbsdown:": { + "category": "people", + "name": "thumbs down sign", + "unicode": "1f44e" + }, + ":thumbsdown_tone1:": { + "category": "people", + "name": "thumbs down sign tone 1", + "unicode": "1f44e-1f3fb" + }, + ":thumbsdown_tone2:": { + "category": "people", + "name": "thumbs down sign tone 2", + "unicode": "1f44e-1f3fc" + }, + ":thumbsdown_tone3:": { + "category": "people", + "name": "thumbs down sign tone 3", + "unicode": "1f44e-1f3fd" + }, + ":thumbsdown_tone4:": { + "category": "people", + "name": "thumbs down sign tone 4", + "unicode": "1f44e-1f3fe" + }, + ":thumbsdown_tone5:": { + "category": "people", + "name": "thumbs down sign tone 5", + "unicode": "1f44e-1f3ff" + }, + ":thumbsup:": { + "category": "people", + "name": "thumbs up sign", + "unicode": "1f44d" + }, + ":thumbsup_tone1:": { + "category": "people", + "name": "thumbs up sign tone 1", + "unicode": "1f44d-1f3fb" + }, + ":thumbsup_tone2:": { + "category": "people", + "name": "thumbs up sign tone 2", + "unicode": "1f44d-1f3fc" + }, + ":thumbsup_tone3:": { + "category": "people", + "name": "thumbs up sign tone 3", + "unicode": "1f44d-1f3fd" + }, + ":thumbsup_tone4:": { + "category": "people", + "name": "thumbs up sign tone 4", + "unicode": "1f44d-1f3fe" + }, + ":thumbsup_tone5:": { + "category": "people", + "name": "thumbs up sign tone 5", + "unicode": "1f44d-1f3ff" + }, + ":thunder_cloud_rain:": { + "category": "nature", + "name": "thunder cloud and rain", + "unicode": "26c8", + "unicode_alt": "26c8-fe0f" + }, + ":ticket:": { + "category": "activity", + "name": "ticket", + "unicode": "1f3ab" + }, + ":tickets:": { + "category": "activity", + "name": "admission tickets", + "unicode": "1f39f", + "unicode_alt": "1f39f-fe0f" + }, + ":tiger2:": { + "category": "nature", + "name": "tiger", + "unicode": "1f405" + }, + ":tiger:": { + "category": "nature", + "name": "tiger face", + "unicode": "1f42f" + }, + ":timer:": { + "category": "objects", + "name": "timer clock", + "unicode": "23f2", + "unicode_alt": "23f2-fe0f" + }, + ":tired_face:": { + "category": "people", + "name": "tired face", + "unicode": "1f62b" + }, + ":tm:": { + "category": "symbols", + "name": "trade mark sign", + "unicode": "2122", + "unicode_alt": "2122-fe0f" + }, + ":toilet:": { + "category": "objects", + "name": "toilet", + "unicode": "1f6bd" + }, + ":tokyo_tower:": { + "category": "travel", + "name": "tokyo tower", + "unicode": "1f5fc" + }, + ":tomato:": { + "category": "food", + "name": "tomato", + "unicode": "1f345" + }, + ":tone1:": { + "category": "modifier", + "name": "emoji modifier Fitzpatrick type-1-2", + "unicode": "1f3fb" + }, + ":tone2:": { + "category": "modifier", + "name": "emoji modifier Fitzpatrick type-3", + "unicode": "1f3fc" + }, + ":tone3:": { + "category": "modifier", + "name": "emoji modifier Fitzpatrick type-4", + "unicode": "1f3fd" + }, + ":tone4:": { + "category": "modifier", + "name": "emoji modifier Fitzpatrick type-5", + "unicode": "1f3fe" + }, + ":tone5:": { + "category": "modifier", + "name": "emoji modifier Fitzpatrick type-6", + "unicode": "1f3ff" + }, + ":tongue:": { + "category": "people", + "name": "tongue", + "unicode": "1f445" + }, + ":tools:": { + "category": "objects", + "name": "hammer and wrench", + "unicode": "1f6e0", + "unicode_alt": "1f6e0-fe0f" + }, + ":top:": { + "category": "symbols", + "name": "top with upwards arrow above", + "unicode": "1f51d" + }, + ":tophat:": { + "category": "people", + "name": "top hat", + "unicode": "1f3a9" + }, + ":track_next:": { + "category": "symbols", + "name": "black right-pointing double triangle with vertical bar", + "unicode": "23ed", + "unicode_alt": "23ed-fe0f" + }, + ":track_previous:": { + "category": "symbols", + "name": "black left-pointing double triangle with vertical bar", + "unicode": "23ee", + "unicode_alt": "23ee-fe0f" + }, + ":trackball:": { + "category": "objects", + "name": "trackball", + "unicode": "1f5b2", + "unicode_alt": "1f5b2-fe0f" + }, + ":tractor:": { + "category": "travel", + "name": "tractor", + "unicode": "1f69c" + }, + ":traffic_light:": { + "category": "travel", + "name": "horizontal traffic light", + "unicode": "1f6a5" + }, + ":train2:": { + "category": "travel", + "name": "train", + "unicode": "1f686" + }, + ":train:": { + "category": "travel", + "name": "tram car", + "unicode": "1f68b" + }, + ":tram:": { + "category": "travel", + "name": "tram", + "unicode": "1f68a" + }, + ":triangular_flag_on_post:": { + "category": "objects", + "name": "triangular flag on post", + "unicode": "1f6a9" + }, + ":triangular_ruler:": { + "category": "objects", + "name": "triangular ruler", + "unicode": "1f4d0" + }, + ":trident:": { + "category": "symbols", + "name": "trident emblem", + "unicode": "1f531" + }, + ":triumph:": { + "category": "people", + "name": "face with look of triumph", + "unicode": "1f624" + }, + ":trolleybus:": { + "category": "travel", + "name": "trolleybus", + "unicode": "1f68e" + }, + ":trophy:": { + "category": "activity", + "name": "trophy", + "unicode": "1f3c6" + }, + ":tropical_drink:": { + "category": "food", + "name": "tropical drink", + "unicode": "1f379" + }, + ":tropical_fish:": { + "category": "nature", + "name": "tropical fish", + "unicode": "1f420" + }, + ":truck:": { + "category": "travel", + "name": "delivery truck", + "unicode": "1f69a" + }, + ":trumpet:": { + "category": "activity", + "name": "trumpet", + "unicode": "1f3ba" + }, + ":tulip:": { + "category": "nature", + "name": "tulip", + "unicode": "1f337" + }, + ":tumbler_glass:": { + "category": "food", + "name": "tumbler glass", + "unicode": "1f943" + }, + ":turkey:": { + "category": "nature", + "name": "turkey", + "unicode": "1f983" + }, + ":turtle:": { + "category": "nature", + "name": "turtle", + "unicode": "1f422" + }, + ":tv:": { + "category": "objects", + "name": "television", + "unicode": "1f4fa" + }, + ":twisted_rightwards_arrows:": { + "category": "symbols", + "name": "twisted rightwards arrows", + "unicode": "1f500" + }, + ":two:": { + "category": "symbols", + "name": "keycap digit two", + "unicode": "0032-20e3", + "unicode_alt": "0032-fe0f-20e3" + }, + ":two_hearts:": { + "category": "symbols", + "name": "two hearts", + "unicode": "1f495" + }, + ":two_men_holding_hands:": { + "category": "people", + "name": "two men holding hands", + "unicode": "1f46c" + }, + ":two_women_holding_hands:": { + "category": "people", + "name": "two women holding hands", + "unicode": "1f46d" + }, + ":u5272:": { + "category": "symbols", + "name": "squared cjk unified ideograph-5272", + "unicode": "1f239" + }, + ":u5408:": { + "category": "symbols", + "name": "squared cjk unified ideograph-5408", + "unicode": "1f234" + }, + ":u55b6:": { + "category": "symbols", + "name": "squared cjk unified ideograph-55b6", + "unicode": "1f23a" + }, + ":u6307:": { + "category": "symbols", + "name": "squared cjk unified ideograph-6307", + "unicode": "1f22f", + "unicode_alt": "1f22f-fe0f" + }, + ":u6708:": { + "category": "symbols", + "name": "squared cjk unified ideograph-6708", + "unicode": "1f237", + "unicode_alt": "1f237-fe0f" + }, + ":u6709:": { + "category": "symbols", + "name": "squared cjk unified ideograph-6709", + "unicode": "1f236" + }, + ":u6e80:": { + "category": "symbols", + "name": "squared cjk unified ideograph-6e80", + "unicode": "1f235" + }, + ":u7121:": { + "category": "symbols", + "name": "squared cjk unified ideograph-7121", + "unicode": "1f21a", + "unicode_alt": "1f21a-fe0f" + }, + ":u7533:": { + "category": "symbols", + "name": "squared cjk unified ideograph-7533", + "unicode": "1f238" + }, + ":u7981:": { + "category": "symbols", + "name": "squared cjk unified ideograph-7981", + "unicode": "1f232" + }, + ":u7a7a:": { + "category": "symbols", + "name": "squared cjk unified ideograph-7a7a", + "unicode": "1f233" + }, + ":umbrella2:": { + "category": "nature", + "name": "umbrella", + "unicode": "2602", + "unicode_alt": "2602-fe0f" + }, + ":umbrella:": { + "category": "nature", + "name": "umbrella with rain drops", + "unicode": "2614", + "unicode_alt": "2614-fe0f" + }, + ":unamused:": { + "category": "people", + "name": "unamused face", + "unicode": "1f612" + }, + ":underage:": { + "category": "symbols", + "name": "no one under eighteen symbol", + "unicode": "1f51e" + }, + ":unicorn:": { + "category": "nature", + "name": "unicorn face", + "unicode": "1f984" + }, + ":unlock:": { + "category": "objects", + "name": "open lock", + "unicode": "1f513" + }, + ":up:": { + "category": "symbols", + "name": "squared up with exclamation mark", + "unicode": "1f199" + }, + ":upside_down:": { + "category": "people", + "name": "upside-down face", + "unicode": "1f643" + }, + ":urn:": { + "category": "objects", + "name": "funeral urn", + "unicode": "26b1", + "unicode_alt": "26b1-fe0f" + }, + ":v:": { + "category": "people", + "name": "victory hand", + "unicode": "270c", + "unicode_alt": "270c-fe0f" + }, + ":v_tone1:": { + "category": "people", + "name": "victory hand tone 1", + "unicode": "270c-1f3fb" + }, + ":v_tone2:": { + "category": "people", + "name": "victory hand tone 2", + "unicode": "270c-1f3fc" + }, + ":v_tone3:": { + "category": "people", + "name": "victory hand tone 3", + "unicode": "270c-1f3fd" + }, + ":v_tone4:": { + "category": "people", + "name": "victory hand tone 4", + "unicode": "270c-1f3fe" + }, + ":v_tone5:": { + "category": "people", + "name": "victory hand tone 5", + "unicode": "270c-1f3ff" + }, + ":vertical_traffic_light:": { + "category": "travel", + "name": "vertical traffic light", + "unicode": "1f6a6" + }, + ":vhs:": { + "category": "objects", + "name": "videocassette", + "unicode": "1f4fc" + }, + ":vibration_mode:": { + "category": "symbols", + "name": "vibration mode", + "unicode": "1f4f3" + }, + ":video_camera:": { + "category": "objects", + "name": "video camera", + "unicode": "1f4f9" + }, + ":video_game:": { + "category": "activity", + "name": "video game", + "unicode": "1f3ae" + }, + ":violin:": { + "category": "activity", + "name": "violin", + "unicode": "1f3bb" + }, + ":virgo:": { + "category": "symbols", + "name": "virgo", + "unicode": "264d", + "unicode_alt": "264d-fe0f" + }, + ":volcano:": { + "category": "travel", + "name": "volcano", + "unicode": "1f30b" + }, + ":volleyball:": { + "category": "activity", + "name": "volleyball", + "unicode": "1f3d0" + }, + ":vs:": { + "category": "symbols", + "name": "squared vs", + "unicode": "1f19a" + }, + ":vulcan:": { + "category": "people", + "name": "raised hand with part between middle and ring fingers", + "unicode": "1f596" + }, + ":vulcan_tone1:": { + "category": "people", + "name": "raised hand with part between middle and ring fingers tone 1", + "unicode": "1f596-1f3fb" + }, + ":vulcan_tone2:": { + "category": "people", + "name": "raised hand with part between middle and ring fingers tone 2", + "unicode": "1f596-1f3fc" + }, + ":vulcan_tone3:": { + "category": "people", + "name": "raised hand with part between middle and ring fingers tone 3", + "unicode": "1f596-1f3fd" + }, + ":vulcan_tone4:": { + "category": "people", + "name": "raised hand with part between middle and ring fingers tone 4", + "unicode": "1f596-1f3fe" + }, + ":vulcan_tone5:": { + "category": "people", + "name": "raised hand with part between middle and ring fingers tone 5", + "unicode": "1f596-1f3ff" + }, + ":walking:": { + "category": "people", + "name": "pedestrian", + "unicode": "1f6b6" + }, + ":walking_tone1:": { + "category": "people", + "name": "pedestrian tone 1", + "unicode": "1f6b6-1f3fb" + }, + ":walking_tone2:": { + "category": "people", + "name": "pedestrian tone 2", + "unicode": "1f6b6-1f3fc" + }, + ":walking_tone3:": { + "category": "people", + "name": "pedestrian tone 3", + "unicode": "1f6b6-1f3fd" + }, + ":walking_tone4:": { + "category": "people", + "name": "pedestrian tone 4", + "unicode": "1f6b6-1f3fe" + }, + ":walking_tone5:": { + "category": "people", + "name": "pedestrian tone 5", + "unicode": "1f6b6-1f3ff" + }, + ":waning_crescent_moon:": { + "category": "nature", + "name": "waning crescent moon symbol", + "unicode": "1f318" + }, + ":waning_gibbous_moon:": { + "category": "nature", + "name": "waning gibbous moon symbol", + "unicode": "1f316" + }, + ":warning:": { + "category": "symbols", + "name": "warning sign", + "unicode": "26a0", + "unicode_alt": "26a0-fe0f" + }, + ":wastebasket:": { + "category": "objects", + "name": "wastebasket", + "unicode": "1f5d1", + "unicode_alt": "1f5d1-fe0f" + }, + ":watch:": { + "category": "objects", + "name": "watch", + "unicode": "231a", + "unicode_alt": "231a-fe0f" + }, + ":water_buffalo:": { + "category": "nature", + "name": "water buffalo", + "unicode": "1f403" + }, + ":water_polo:": { + "category": "activity", + "name": "water polo", + "unicode": "1f93d" + }, + ":water_polo_tone1:": { + "category": "activity", + "name": "water polo tone 1", + "unicode": "1f93d-1f3fb" + }, + ":water_polo_tone2:": { + "category": "activity", + "name": "water polo tone 2", + "unicode": "1f93d-1f3fc" + }, + ":water_polo_tone3:": { + "category": "activity", + "name": "water polo tone 3", + "unicode": "1f93d-1f3fd" + }, + ":water_polo_tone4:": { + "category": "activity", + "name": "water polo tone 4", + "unicode": "1f93d-1f3fe" + }, + ":water_polo_tone5:": { + "category": "activity", + "name": "water polo tone 5", + "unicode": "1f93d-1f3ff" + }, + ":watermelon:": { + "category": "food", + "name": "watermelon", + "unicode": "1f349" + }, + ":wave:": { + "category": "people", + "name": "waving hand sign", + "unicode": "1f44b" + }, + ":wave_tone1:": { + "category": "people", + "name": "waving hand sign tone 1", + "unicode": "1f44b-1f3fb" + }, + ":wave_tone2:": { + "category": "people", + "name": "waving hand sign tone 2", + "unicode": "1f44b-1f3fc" + }, + ":wave_tone3:": { + "category": "people", + "name": "waving hand sign tone 3", + "unicode": "1f44b-1f3fd" + }, + ":wave_tone4:": { + "category": "people", + "name": "waving hand sign tone 4", + "unicode": "1f44b-1f3fe" + }, + ":wave_tone5:": { + "category": "people", + "name": "waving hand sign tone 5", + "unicode": "1f44b-1f3ff" + }, + ":wavy_dash:": { + "category": "symbols", + "name": "wavy dash", + "unicode": "3030", + "unicode_alt": "3030-fe0f" + }, + ":waxing_crescent_moon:": { + "category": "nature", + "name": "waxing crescent moon symbol", + "unicode": "1f312" + }, + ":waxing_gibbous_moon:": { + "category": "nature", + "name": "waxing gibbous moon symbol", + "unicode": "1f314" + }, + ":wc:": { + "category": "symbols", + "name": "water closet", + "unicode": "1f6be" + }, + ":weary:": { + "category": "people", + "name": "weary face", + "unicode": "1f629" + }, + ":wedding:": { + "category": "travel", + "name": "wedding", + "unicode": "1f492" + }, + ":whale2:": { + "category": "nature", + "name": "whale", + "unicode": "1f40b" + }, + ":whale:": { + "category": "nature", + "name": "spouting whale", + "unicode": "1f433" + }, + ":wheel_of_dharma:": { + "category": "symbols", + "name": "wheel of dharma", + "unicode": "2638", + "unicode_alt": "2638-fe0f" + }, + ":wheelchair:": { + "category": "symbols", + "name": "wheelchair symbol", + "unicode": "267f", + "unicode_alt": "267f-fe0f" + }, + ":white_check_mark:": { + "category": "symbols", + "name": "white heavy check mark", + "unicode": "2705" + }, + ":white_circle:": { + "category": "symbols", + "name": "white circle", + "unicode": "26aa", + "unicode_alt": "26aa-fe0f" + }, + ":white_flower:": { + "category": "symbols", + "name": "white flower", + "unicode": "1f4ae" + }, + ":white_large_square:": { + "category": "symbols", + "name": "white large square", + "unicode": "2b1c", + "unicode_alt": "2b1c-fe0f" + }, + ":white_medium_small_square:": { + "category": "symbols", + "name": "white medium small square", + "unicode": "25fd", + "unicode_alt": "25fd-fe0f" + }, + ":white_medium_square:": { + "category": "symbols", + "name": "white medium square", + "unicode": "25fb", + "unicode_alt": "25fb-fe0f" + }, + ":white_small_square:": { + "category": "symbols", + "name": "white small square", + "unicode": "25ab", + "unicode_alt": "25ab-fe0f" + }, + ":white_square_button:": { + "category": "symbols", + "name": "white square button", + "unicode": "1f533" + }, + ":white_sun_cloud:": { + "category": "nature", + "name": "white sun behind cloud", + "unicode": "1f325", + "unicode_alt": "1f325-fe0f" + }, + ":white_sun_rain_cloud:": { + "category": "nature", + "name": "white sun behind cloud with rain", + "unicode": "1f326", + "unicode_alt": "1f326-fe0f" + }, + ":white_sun_small_cloud:": { + "category": "nature", + "name": "white sun with small cloud", + "unicode": "1f324", + "unicode_alt": "1f324-fe0f" + }, + ":wilted_rose:": { + "category": "nature", + "name": "wilted flower", + "unicode": "1f940" + }, + ":wind_blowing_face:": { + "category": "nature", + "name": "wind blowing face", + "unicode": "1f32c", + "unicode_alt": "1f32c-fe0f" + }, + ":wind_chime:": { + "category": "objects", + "name": "wind chime", + "unicode": "1f390" + }, + ":wine_glass:": { + "category": "food", + "name": "wine glass", + "unicode": "1f377" + }, + ":wink:": { + "category": "people", + "name": "winking face", + "unicode": "1f609" + }, + ":wolf:": { + "category": "nature", + "name": "wolf face", + "unicode": "1f43a" + }, + ":woman:": { + "category": "people", + "name": "woman", + "unicode": "1f469" + }, + ":woman_tone1:": { + "category": "people", + "name": "woman tone 1", + "unicode": "1f469-1f3fb" + }, + ":woman_tone2:": { + "category": "people", + "name": "woman tone 2", + "unicode": "1f469-1f3fc" + }, + ":woman_tone3:": { + "category": "people", + "name": "woman tone 3", + "unicode": "1f469-1f3fd" + }, + ":woman_tone4:": { + "category": "people", + "name": "woman tone 4", + "unicode": "1f469-1f3fe" + }, + ":woman_tone5:": { + "category": "people", + "name": "woman tone 5", + "unicode": "1f469-1f3ff" + }, + ":womans_clothes:": { + "category": "people", + "name": "womans clothes", + "unicode": "1f45a" + }, + ":womans_hat:": { + "category": "people", + "name": "womans hat", + "unicode": "1f452" + }, + ":womens:": { + "category": "symbols", + "name": "womens symbol", + "unicode": "1f6ba" + }, + ":worried:": { + "category": "people", + "name": "worried face", + "unicode": "1f61f" + }, + ":wrench:": { + "category": "objects", + "name": "wrench", + "unicode": "1f527" + }, + ":wrestlers:": { + "category": "activity", + "name": "wrestlers", + "unicode": "1f93c" + }, + ":wrestlers_tone1:": { + "category": "activity", + "name": "wrestlers tone 1", + "unicode": "1f93c-1f3fb" + }, + ":wrestlers_tone2:": { + "category": "activity", + "name": "wrestlers tone 2", + "unicode": "1f93c-1f3fc" + }, + ":wrestlers_tone3:": { + "category": "activity", + "name": "wrestlers tone 3", + "unicode": "1f93c-1f3fd" + }, + ":wrestlers_tone4:": { + "category": "activity", + "name": "wrestlers tone 4", + "unicode": "1f93c-1f3fe" + }, + ":wrestlers_tone5:": { + "category": "activity", + "name": "wrestlers tone 5", + "unicode": "1f93c-1f3ff" + }, + ":writing_hand:": { + "category": "people", + "name": "writing hand", + "unicode": "270d", + "unicode_alt": "270d-fe0f" + }, + ":writing_hand_tone1:": { + "category": "people", + "name": "writing hand tone 1", + "unicode": "270d-1f3fb" + }, + ":writing_hand_tone2:": { + "category": "people", + "name": "writing hand tone 2", + "unicode": "270d-1f3fc" + }, + ":writing_hand_tone3:": { + "category": "people", + "name": "writing hand tone 3", + "unicode": "270d-1f3fd" + }, + ":writing_hand_tone4:": { + "category": "people", + "name": "writing hand tone 4", + "unicode": "270d-1f3fe" + }, + ":writing_hand_tone5:": { + "category": "people", + "name": "writing hand tone 5", + "unicode": "270d-1f3ff" + }, + ":x:": { + "category": "symbols", + "name": "cross mark", + "unicode": "274c" + }, + ":yellow_heart:": { + "category": "symbols", + "name": "yellow heart", + "unicode": "1f49b" + }, + ":yen:": { + "category": "objects", + "name": "banknote with yen sign", + "unicode": "1f4b4" + }, + ":yin_yang:": { + "category": "symbols", + "name": "yin yang", + "unicode": "262f", + "unicode_alt": "262f-fe0f" + }, + ":yum:": { + "category": "people", + "name": "face savouring delicious food", + "unicode": "1f60b" + }, + ":zap:": { + "category": "nature", + "name": "high voltage sign", + "unicode": "26a1", + "unicode_alt": "26a1-fe0f" + }, + ":zero:": { + "category": "symbols", + "name": "keycap digit zero", + "unicode": "0030-20e3", + "unicode_alt": "0030-fe0f-20e3" + }, + ":zipper_mouth:": { + "category": "people", + "name": "zipper-mouth face", + "unicode": "1f910" + }, + ":zzz:": { + "category": "people", + "name": "sleeping symbol", + "unicode": "1f4a4" + } +} +aliases = { + ":+1:": ":thumbsup:", + ":+1_tone1:": ":thumbsup_tone1:", + ":+1_tone2:": ":thumbsup_tone2:", + ":+1_tone3:": ":thumbsup_tone3:", + ":+1_tone4:": ":thumbsup_tone4:", + ":+1_tone5:": ":thumbsup_tone5:", + ":-1:": ":thumbsdown:", + ":-1_tone1:": ":thumbsdown_tone1:", + ":-1_tone2:": ":thumbsdown_tone2:", + ":-1_tone3:": ":thumbsdown_tone3:", + ":-1_tone4:": ":thumbsdown_tone4:", + ":-1_tone5:": ":thumbsdown_tone5:", + ":ac:": ":flag_ac:", + ":ad:": ":flag_ad:", + ":admission_tickets:": ":tickets:", + ":ae:": ":flag_ae:", + ":af:": ":flag_af:", + ":ag:": ":flag_ag:", + ":ai:": ":flag_ai:", + ":al:": ":flag_al:", + ":am:": ":flag_am:", + ":ao:": ":flag_ao:", + ":aq:": ":flag_aq:", + ":ar:": ":flag_ar:", + ":archery:": ":bow_and_arrow:", + ":as:": ":flag_as:", + ":at:": ":flag_at:", + ":atom_symbol:": ":atom:", + ":au:": ":flag_au:", + ":aw:": ":flag_aw:", + ":ax:": ":flag_ax:", + ":az:": ":flag_az:", + ":ba:": ":flag_ba:", + ":back_of_hand:": ":raised_back_of_hand:", + ":back_of_hand_tone1:": ":raised_back_of_hand_tone1:", + ":back_of_hand_tone2:": ":raised_back_of_hand_tone2:", + ":back_of_hand_tone3:": ":raised_back_of_hand_tone3:", + ":back_of_hand_tone4:": ":raised_back_of_hand_tone4:", + ":back_of_hand_tone5:": ":raised_back_of_hand_tone5:", + ":baguette_bread:": ":french_bread:", + ":ballot_box_with_ballot:": ":ballot_box:", + ":bb:": ":flag_bb:", + ":bd:": ":flag_bd:", + ":be:": ":flag_be:", + ":beach_with_umbrella:": ":beach:", + ":bellhop_bell:": ":bellhop:", + ":bf:": ":flag_bf:", + ":bg:": ":flag_bg:", + ":bh:": ":flag_bh:", + ":bi:": ":flag_bi:", + ":biohazard_sign:": ":biohazard:", + ":bj:": ":flag_bj:", + ":bl:": ":flag_bl:", + ":bm:": ":flag_bm:", + ":bn:": ":flag_bn:", + ":bo:": ":flag_bo:", + ":bottle_with_popping_cork:": ":champagne:", + ":boxing_gloves:": ":boxing_glove:", + ":bq:": ":flag_bq:", + ":br:": ":flag_br:", + ":bs:": ":flag_bs:", + ":bt:": ":flag_bt:", + ":building_construction:": ":construction_site:", + ":bv:": ":flag_bv:", + ":bw:": ":flag_bw:", + ":by:": ":flag_by:", + ":bz:": ":flag_bz:", + ":ca:": ":flag_ca:", + ":call_me_hand:": ":call_me:", + ":call_me_hand_tone1:": ":call_me_tone1:", + ":call_me_hand_tone2:": ":call_me_tone2:", + ":call_me_hand_tone3:": ":call_me_tone3:", + ":call_me_hand_tone4:": ":call_me_tone4:", + ":call_me_hand_tone5:": ":call_me_tone5:", + ":card_file_box:": ":card_box:", + ":card_index_dividers:": ":dividers:", + ":cc:": ":flag_cc:", + ":cf:": ":flag_cf:", + ":cg:": ":flag_cg:", + ":ch:": ":flag_ch:", + ":cheese_wedge:": ":cheese:", + ":chile:": ":flag_cl:", + ":ci:": ":flag_ci:", + ":city_sunrise:": ":city_sunset:", + ":ck:": ":flag_ck:", + ":clinking_glass:": ":champagne_glass:", + ":cloud_with_lightning:": ":cloud_lightning:", + ":cloud_with_rain:": ":cloud_rain:", + ":cloud_with_snow:": ":cloud_snow:", + ":cloud_with_tornado:": ":cloud_tornado:", + ":clown_face:": ":clown:", + ":cm:": ":flag_cm:", + ":cn:": ":flag_cn:", + ":co:": ":flag_co:", + ":congo:": ":flag_cd:", + ":couch_and_lamp:": ":couch:", + ":couple_with_heart_mm:": ":couple_mm:", + ":couple_with_heart_ww:": ":couple_ww:", + ":couplekiss_mm:": ":kiss_mm:", + ":couplekiss_ww:": ":kiss_ww:", + ":cp:": ":flag_cp:", + ":cr:": ":flag_cr:", + ":cricket_bat_ball:": ":cricket:", + ":cu:": ":flag_cu:", + ":cv:": ":flag_cv:", + ":cw:": ":flag_cw:", + ":cx:": ":flag_cx:", + ":cy:": ":flag_cy:", + ":cz:": ":flag_cz:", + ":dagger_knife:": ":dagger:", + ":de:": ":flag_de:", + ":derelict_house_building:": ":house_abandoned:", + ":desert_island:": ":island:", + ":desktop_computer:": ":desktop:", + ":dg:": ":flag_dg:", + ":dj:": ":flag_dj:", + ":dk:": ":flag_dk:", + ":dm:": ":flag_dm:", + ":do:": ":flag_do:", + ":double_vertical_bar:": ":pause_button:", + ":dove_of_peace:": ":dove:", + ":drool:": ":drooling_face:", + ":drum_with_drumsticks:": ":drum:", + ":dz:": ":flag_dz:", + ":ea:": ":flag_ea:", + ":ec:": ":flag_ec:", + ":ee:": ":flag_ee:", + ":eg:": ":flag_eg:", + ":eh:": ":flag_eh:", + ":eject_symbol:": ":eject:", + ":email:": ":e-mail:", + ":er:": ":flag_er:", + ":es:": ":flag_es:", + ":et:": ":flag_et:", + ":eu:": ":flag_eu:", + ":expecting_woman:": ":pregnant_woman:", + ":expecting_woman_tone1:": ":pregnant_woman_tone1:", + ":expecting_woman_tone2:": ":pregnant_woman_tone2:", + ":expecting_woman_tone3:": ":pregnant_woman_tone3:", + ":expecting_woman_tone4:": ":pregnant_woman_tone4:", + ":expecting_woman_tone5:": ":pregnant_woman_tone5:", + ":face_with_cowboy_hat:": ":cowboy:", + ":face_with_head_bandage:": ":head_bandage:", + ":face_with_rolling_eyes:": ":rolling_eyes:", + ":face_with_thermometer:": ":thermometer_face:", + ":facepalm:": ":face_palm:", + ":facepalm_tone1:": ":face_palm_tone1:", + ":facepalm_tone2:": ":face_palm_tone2:", + ":facepalm_tone3:": ":face_palm_tone3:", + ":facepalm_tone4:": ":face_palm_tone4:", + ":facepalm_tone5:": ":face_palm_tone5:", + ":fencing:": ":fencer:", + ":fi:": ":flag_fi:", + ":film_projector:": ":projector:", + ":first_place_medal:": ":first_place:", + ":fj:": ":flag_fj:", + ":fk:": ":flag_fk:", + ":flame:": ":fire:", + ":flan:": ":custard:", + ":fm:": ":flag_fm:", + ":fo:": ":flag_fo:", + ":fork_and_knife_with_plate:": ":fork_knife_plate:", + ":fox_face:": ":fox:", + ":fr:": ":flag_fr:", + ":frame_with_picture:": ":frame_photo:", + ":funeral_urn:": ":urn:", + ":ga:": ":flag_ga:", + ":gay_pride_flag:": ":rainbow_flag:", + ":gb:": ":flag_gb:", + ":gd:": ":flag_gd:", + ":ge:": ":flag_ge:", + ":gf:": ":flag_gf:", + ":gg:": ":flag_gg:", + ":gh:": ":flag_gh:", + ":gi:": ":flag_gi:", + ":gl:": ":flag_gl:", + ":glass_of_milk:": ":milk:", + ":gm:": ":flag_gm:", + ":gn:": ":flag_gn:", + ":goal_net:": ":goal:", + ":gp:": ":flag_gp:", + ":gq:": ":flag_gq:", + ":gr:": ":flag_gr:", + ":grandma:": ":older_woman:", + ":grandma_tone1:": ":older_woman_tone1:", + ":grandma_tone2:": ":older_woman_tone2:", + ":grandma_tone3:": ":older_woman_tone3:", + ":grandma_tone4:": ":older_woman_tone4:", + ":grandma_tone5:": ":older_woman_tone5:", + ":green_salad:": ":salad:", + ":gs:": ":flag_gs:", + ":gt:": ":flag_gt:", + ":gu:": ":flag_gu:", + ":gw:": ":flag_gw:", + ":gy:": ":flag_gy:", + ":hammer_and_pick:": ":hammer_pick:", + ":hammer_and_wrench:": ":tools:", + ":hand_with_index_and_middle_finger_crossed:": ":fingers_crossed:", + ":hand_with_index_and_middle_fingers_crossed_tone1:": ":fingers_crossed_tone1:", + ":hand_with_index_and_middle_fingers_crossed_tone2:": ":fingers_crossed_tone2:", + ":hand_with_index_and_middle_fingers_crossed_tone3:": ":fingers_crossed_tone3:", + ":hand_with_index_and_middle_fingers_crossed_tone4:": ":fingers_crossed_tone4:", + ":hand_with_index_and_middle_fingers_crossed_tone5:": ":fingers_crossed_tone5:", + ":hankey:": ":poop:", + ":heavy_heart_exclamation_mark_ornament:": ":heart_exclamation:", + ":helmet_with_white_cross:": ":helmet_with_cross:", + ":hk:": ":flag_hk:", + ":hm:": ":flag_hm:", + ":hn:": ":flag_hn:", + ":hot_dog:": ":hotdog:", + ":house_buildings:": ":homes:", + ":hr:": ":flag_hr:", + ":ht:": ":flag_ht:", + ":hu:": ":flag_hu:", + ":hugging_face:": ":hugging:", + ":ic:": ":flag_ic:", + ":ie:": ":flag_ie:", + ":il:": ":flag_il:", + ":im:": ":flag_im:", + ":in:": ":flag_in:", + ":indonesia:": ":flag_id:", + ":io:": ":flag_io:", + ":iq:": ":flag_iq:", + ":ir:": ":flag_ir:", + ":is:": ":flag_is:", + ":it:": ":flag_it:", + ":je:": ":flag_je:", + ":jm:": ":flag_jm:", + ":jo:": ":flag_jo:", + ":jp:": ":flag_jp:", + ":juggler:": ":juggling:", + ":juggler_tone1:": ":juggling_tone1:", + ":juggler_tone2:": ":juggling_tone2:", + ":juggler_tone3:": ":juggling_tone3:", + ":juggler_tone4:": ":juggling_tone4:", + ":juggler_tone5:": ":juggling_tone5:", + ":karate_uniform:": ":martial_arts_uniform:", + ":kayak:": ":canoe:", + ":ke:": ":flag_ke:", + ":keycap_asterisk:": ":asterisk:", + ":kg:": ":flag_kg:", + ":kh:": ":flag_kh:", + ":ki:": ":flag_ki:", + ":kiwifruit:": ":kiwi:", + ":km:": ":flag_km:", + ":kn:": ":flag_kn:", + ":kp:": ":flag_kp:", + ":kr:": ":flag_kr:", + ":kw:": ":flag_kw:", + ":ky:": ":flag_ky:", + ":kz:": ":flag_kz:", + ":la:": ":flag_la:", + ":latin_cross:": ":cross:", + ":lb:": ":flag_lb:", + ":lc:": ":flag_lc:", + ":left_fist:": ":left_facing_fist:", + ":left_fist_tone1:": ":left_facing_fist_tone1:", + ":left_fist_tone2:": ":left_facing_fist_tone2:", + ":left_fist_tone3:": ":left_facing_fist_tone3:", + ":left_fist_tone4:": ":left_facing_fist_tone4:", + ":left_fist_tone5:": ":left_facing_fist_tone5:", + ":left_speech_bubble:": ":speech_left:", + ":li:": ":flag_li:", + ":liar:": ":lying_face:", + ":linked_paperclips:": ":paperclips:", + ":lion:": ":lion_face:", + ":lk:": ":flag_lk:", + ":lower_left_ballpoint_pen:": ":pen_ballpoint:", + ":lower_left_crayon:": ":crayon:", + ":lower_left_fountain_pen:": ":pen_fountain:", + ":lower_left_paintbrush:": ":paintbrush:", + ":lr:": ":flag_lr:", + ":ls:": ":flag_ls:", + ":lt:": ":flag_lt:", + ":lu:": ":flag_lu:", + ":lv:": ":flag_lv:", + ":ly:": ":flag_ly:", + ":ma:": ":flag_ma:", + ":male_dancer:": ":man_dancing:", + ":male_dancer_tone1:": ":man_dancing_tone1:", + ":male_dancer_tone2:": ":man_dancing_tone2:", + ":male_dancer_tone3:": ":man_dancing_tone3:", + ":male_dancer_tone4:": ":man_dancing_tone4:", + ":male_dancer_tone5:": ":man_dancing_tone5:", + ":man_in_business_suit_levitating:": ":levitate:", + ":mantlepiece_clock:": ":clock:", + ":mc:": ":flag_mc:", + ":md:": ":flag_md:", + ":me:": ":flag_me:", + ":mf:": ":flag_mf:", + ":mg:": ":flag_mg:", + ":mh:": ":flag_mh:", + ":mk:": ":flag_mk:", + ":ml:": ":flag_ml:", + ":mm:": ":flag_mm:", + ":mn:": ":flag_mn:", + ":mo:": ":flag_mo:", + ":money_mouth_face:": ":money_mouth:", + ":mother_christmas:": ":mrs_claus:", + ":mother_christmas_tone1:": ":mrs_claus_tone1:", + ":mother_christmas_tone2:": ":mrs_claus_tone2:", + ":mother_christmas_tone3:": ":mrs_claus_tone3:", + ":mother_christmas_tone4:": ":mrs_claus_tone4:", + ":mother_christmas_tone5:": ":mrs_claus_tone5:", + ":motorbike:": ":motor_scooter:", + ":mp:": ":flag_mp:", + ":mq:": ":flag_mq:", + ":mr:": ":flag_mr:", + ":ms:": ":flag_ms:", + ":mt:": ":flag_mt:", + ":mu:": ":flag_mu:", + ":mv:": ":flag_mv:", + ":mw:": ":flag_mw:", + ":mx:": ":flag_mx:", + ":my:": ":flag_my:", + ":mz:": ":flag_mz:", + ":na:": ":flag_na:", + ":national_park:": ":park:", + ":nc:": ":flag_nc:", + ":ne:": ":flag_ne:", + ":nerd_face:": ":nerd:", + ":next_track:": ":track_next:", + ":nf:": ":flag_nf:", + ":ni:": ":flag_ni:", + ":nigeria:": ":flag_ng:", + ":nl:": ":flag_nl:", + ":no:": ":flag_no:", + ":np:": ":flag_np:", + ":nr:": ":flag_nr:", + ":nu:": ":flag_nu:", + ":nz:": ":flag_nz:", + ":oil_drum:": ":oil:", + ":old_key:": ":key2:", + ":om:": ":flag_om:", + ":pa:": ":flag_pa:", + ":paella:": ":shallow_pan_of_food:", + ":passenger_ship:": ":cruise_ship:", + ":paw_prints:": ":feet:", + ":pe:": ":flag_pe:", + ":peace_symbol:": ":peace:", + ":person_doing_cartwheel:": ":cartwheel:", + ":person_doing_cartwheel_tone1:": ":cartwheel_tone1:", + ":person_doing_cartwheel_tone2:": ":cartwheel_tone2:", + ":person_doing_cartwheel_tone3:": ":cartwheel_tone3:", + ":person_doing_cartwheel_tone4:": ":cartwheel_tone4:", + ":person_doing_cartwheel_tone5:": ":cartwheel_tone5:", + ":person_with_ball:": ":basketball_player:", + ":person_with_ball_tone1:": ":basketball_player_tone1:", + ":person_with_ball_tone2:": ":basketball_player_tone2:", + ":person_with_ball_tone3:": ":basketball_player_tone3:", + ":person_with_ball_tone4:": ":basketball_player_tone4:", + ":person_with_ball_tone5:": ":basketball_player_tone5:", + ":pf:": ":flag_pf:", + ":pg:": ":flag_pg:", + ":ph:": ":flag_ph:", + ":pk:": ":flag_pk:", + ":pl:": ":flag_pl:", + ":pm:": ":flag_pm:", + ":pn:": ":flag_pn:", + ":poo:": ":poop:", + ":pr:": ":flag_pr:", + ":previous_track:": ":track_previous:", + ":ps:": ":flag_ps:", + ":pt:": ":flag_pt:", + ":pudding:": ":custard:", + ":pw:": ":flag_pw:", + ":py:": ":flag_py:", + ":qa:": ":flag_qa:", + ":racing_car:": ":race_car:", + ":racing_motorcycle:": ":motorcycle:", + ":radioactive_sign:": ":radioactive:", + ":railroad_track:": ":railway_track:", + ":raised_hand_with_fingers_splayed:": ":hand_splayed:", + ":raised_hand_with_fingers_splayed_tone1:": ":hand_splayed_tone1:", + ":raised_hand_with_fingers_splayed_tone2:": ":hand_splayed_tone2:", + ":raised_hand_with_fingers_splayed_tone3:": ":hand_splayed_tone3:", + ":raised_hand_with_fingers_splayed_tone4:": ":hand_splayed_tone4:", + ":raised_hand_with_fingers_splayed_tone5:": ":hand_splayed_tone5:", + ":raised_hand_with_part_between_middle_and_ring_fingers:": ":vulcan:", + ":raised_hand_with_part_between_middle_and_ring_fingers_tone1:": ":vulcan_tone1:", + ":raised_hand_with_part_between_middle_and_ring_fingers_tone2:": ":vulcan_tone2:", + ":raised_hand_with_part_between_middle_and_ring_fingers_tone3:": ":vulcan_tone3:", + ":raised_hand_with_part_between_middle_and_ring_fingers_tone4:": ":vulcan_tone4:", + ":raised_hand_with_part_between_middle_and_ring_fingers_tone5:": ":vulcan_tone5:", + ":re:": ":flag_re:", + ":reversed_hand_with_middle_finger_extended:": ":middle_finger:", + ":reversed_hand_with_middle_finger_extended_tone1:": ":middle_finger_tone1:", + ":reversed_hand_with_middle_finger_extended_tone2:": ":middle_finger_tone2:", + ":reversed_hand_with_middle_finger_extended_tone3:": ":middle_finger_tone3:", + ":reversed_hand_with_middle_finger_extended_tone4:": ":middle_finger_tone4:", + ":reversed_hand_with_middle_finger_extended_tone5:": ":middle_finger_tone5:", + ":rhinoceros:": ":rhino:", + ":right_anger_bubble:": ":anger_right:", + ":right_fist:": ":right_facing_fist:", + ":right_fist_tone1:": ":right_facing_fist_tone1:", + ":right_fist_tone2:": ":right_facing_fist_tone2:", + ":right_fist_tone3:": ":right_facing_fist_tone3:", + ":right_fist_tone4:": ":right_facing_fist_tone4:", + ":right_fist_tone5:": ":right_facing_fist_tone5:", + ":ro:": ":flag_ro:", + ":robot_face:": ":robot:", + ":rolled_up_newspaper:": ":newspaper2:", + ":rolling_on_the_floor_laughing:": ":rofl:", + ":rs:": ":flag_rs:", + ":ru:": ":flag_ru:", + ":rw:": ":flag_rw:", + ":satisfied:": ":laughing:", + ":saudi:": ":flag_sa:", + ":saudiarabia:": ":flag_sa:", + ":sb:": ":flag_sb:", + ":sc:": ":flag_sc:", + ":sd:": ":flag_sd:", + ":se:": ":flag_se:", + ":second_place_medal:": ":second_place:", + ":sg:": ":flag_sg:", + ":sh:": ":flag_sh:", + ":shaking_hands:": ":handshake:", + ":shaking_hands_tone1:": ":handshake_tone1:", + ":shaking_hands_tone2:": ":handshake_tone2:", + ":shaking_hands_tone3:": ":handshake_tone3:", + ":shaking_hands_tone4:": ":handshake_tone4:", + ":shaking_hands_tone5:": ":handshake_tone5:", + ":shelled_peanut:": ":peanuts:", + ":shit:": ":poop:", + ":shopping_trolley:": ":shopping_cart:", + ":si:": ":flag_si:", + ":sick:": ":nauseated_face:", + ":sign_of_the_horns:": ":metal:", + ":sign_of_the_horns_tone1:": ":metal_tone1:", + ":sign_of_the_horns_tone2:": ":metal_tone2:", + ":sign_of_the_horns_tone3:": ":metal_tone3:", + ":sign_of_the_horns_tone4:": ":metal_tone4:", + ":sign_of_the_horns_tone5:": ":metal_tone5:", + ":sj:": ":flag_sj:", + ":sk:": ":flag_sk:", + ":skeleton:": ":skull:", + ":skull_and_crossbones:": ":skull_crossbones:", + ":sl:": ":flag_sl:", + ":sleuth_or_spy:": ":spy:", + ":sleuth_or_spy_tone1:": ":spy_tone1:", + ":sleuth_or_spy_tone2:": ":spy_tone2:", + ":sleuth_or_spy_tone3:": ":spy_tone3:", + ":sleuth_or_spy_tone4:": ":spy_tone4:", + ":sleuth_or_spy_tone5:": ":spy_tone5:", + ":slightly_frowning_face:": ":slight_frown:", + ":slightly_smiling_face:": ":slight_smile:", + ":sm:": ":flag_sm:", + ":small_airplane:": ":airplane_small:", + ":sn:": ":flag_sn:", + ":sneeze:": ":sneezing_face:", + ":snow_capped_mountain:": ":mountain_snow:", + ":so:": ":flag_so:", + ":speaking_head_in_silhouette:": ":speaking_head:", + ":spiral_calendar_pad:": ":calendar_spiral:", + ":spiral_note_pad:": ":notepad_spiral:", + ":sports_medal:": ":medal:", + ":sr:": ":flag_sr:", + ":ss:": ":flag_ss:", + ":st:": ":flag_st:", + ":stop_sign:": ":octagonal_sign:", + ":studio_microphone:": ":microphone2:", + ":stuffed_pita:": ":stuffed_flatbread:", + ":sv:": ":flag_sv:", + ":sx:": ":flag_sx:", + ":sy:": ":flag_sy:", + ":sz:": ":flag_sz:", + ":ta:": ":flag_ta:", + ":table_tennis:": ":ping_pong:", + ":tc:": ":flag_tc:", + ":td:": ":flag_td:", + ":tf:": ":flag_tf:", + ":tg:": ":flag_tg:", + ":th:": ":flag_th:", + ":thinking_face:": ":thinking:", + ":third_place_medal:": ":third_place:", + ":three_button_mouse:": ":mouse_three_button:", + ":thumbdown:": ":thumbsdown:", + ":thumbdown_tone1:": ":thumbsdown_tone1:", + ":thumbdown_tone2:": ":thumbsdown_tone2:", + ":thumbdown_tone3:": ":thumbsdown_tone3:", + ":thumbdown_tone4:": ":thumbsdown_tone4:", + ":thumbdown_tone5:": ":thumbsdown_tone5:", + ":thumbup:": ":thumbsup:", + ":thumbup_tone1:": ":thumbsup_tone1:", + ":thumbup_tone2:": ":thumbsup_tone2:", + ":thumbup_tone3:": ":thumbsup_tone3:", + ":thumbup_tone4:": ":thumbsup_tone4:", + ":thumbup_tone5:": ":thumbsup_tone5:", + ":thunder_cloud_and_rain:": ":thunder_cloud_rain:", + ":timer_clock:": ":timer:", + ":tj:": ":flag_tj:", + ":tk:": ":flag_tk:", + ":tl:": ":flag_tl:", + ":tn:": ":flag_tn:", + ":to:": ":flag_to:", + ":tr:": ":flag_tr:", + ":tt:": ":flag_tt:", + ":turkmenistan:": ":flag_tm:", + ":tuvalu:": ":flag_tv:", + ":tuxedo_tone1:": ":man_in_tuxedo_tone1:", + ":tuxedo_tone2:": ":man_in_tuxedo_tone2:", + ":tuxedo_tone3:": ":man_in_tuxedo_tone3:", + ":tuxedo_tone4:": ":man_in_tuxedo_tone4:", + ":tuxedo_tone5:": ":man_in_tuxedo_tone5:", + ":tw:": ":flag_tw:", + ":tz:": ":flag_tz:", + ":ua:": ":flag_ua:", + ":ug:": ":flag_ug:", + ":um:": ":flag_um:", + ":umbrella_on_ground:": ":beach_umbrella:", + ":unicorn_face:": ":unicorn:", + ":upside_down_face:": ":upside_down:", + ":us:": ":flag_us:", + ":uy:": ":flag_uy:", + ":uz:": ":flag_uz:", + ":va:": ":flag_va:", + ":vc:": ":flag_vc:", + ":ve:": ":flag_ve:", + ":vg:": ":flag_vg:", + ":vi:": ":flag_vi:", + ":vn:": ":flag_vn:", + ":vu:": ":flag_vu:", + ":waving_black_flag:": ":flag_black:", + ":waving_white_flag:": ":flag_white:", + ":weight_lifter:": ":lifter:", + ":weight_lifter_tone1:": ":lifter_tone1:", + ":weight_lifter_tone2:": ":lifter_tone2:", + ":weight_lifter_tone3:": ":lifter_tone3:", + ":weight_lifter_tone4:": ":lifter_tone4:", + ":weight_lifter_tone5:": ":lifter_tone5:", + ":wf:": ":flag_wf:", + ":whisky:": ":tumbler_glass:", + ":white_frowning_face:": ":frowning2:", + ":white_sun_behind_cloud:": ":white_sun_cloud:", + ":white_sun_behind_cloud_with_rain:": ":white_sun_rain_cloud:", + ":white_sun_with_small_cloud:": ":white_sun_small_cloud:", + ":wilted_flower:": ":wilted_rose:", + ":world_map:": ":map:", + ":worship_symbol:": ":place_of_worship:", + ":wrestling:": ":wrestlers:", + ":wrestling_tone1:": ":wrestlers_tone1:", + ":wrestling_tone2:": ":wrestlers_tone2:", + ":wrestling_tone3:": ":wrestlers_tone3:", + ":wrestling_tone4:": ":wrestlers_tone4:", + ":wrestling_tone5:": ":wrestlers_tone5:", + ":ws:": ":flag_ws:", + ":xk:": ":flag_xk:", + ":ye:": ":flag_ye:", + ":yt:": ":flag_yt:", + ":za:": ":flag_za:", + ":zipper_mouth_face:": ":zipper_mouth:", + ":zm:": ":flag_zm:", + ":zw:": ":flag_zw:" +} diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/escapeall.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/escapeall.py new file mode 100644 index 0000000000000000000000000000000000000000..19bb5a7f60cd9536db8356eede204033c397f186 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/escapeall.py @@ -0,0 +1,104 @@ +""" +EscapeAll. + +pymdownx.escapeall +Escape everything. + +MIT license. + +Copyright (c) 2017 Isaac Muse + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, +and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +""" +from markdown import Extension +from markdown.inlinepatterns import InlineProcessor, SubstituteTagInlineProcessor +from markdown import util as md_util +from . import util + +# We need to ignore these as they are used in Markdown processing +STX = '\u0002' +ETX = '\u0003' +ESCAPE_RE = r'\\(.)' +ESCAPE_NO_NL_RE = r'\\([^\n])' +HARDBREAK_RE = r'\\\n' + + +class EscapeAllPattern(InlineProcessor): + """Return an escaped character.""" + + def __init__(self, pattern, nbsp, md): + """Initialize.""" + + self.nbsp = nbsp + InlineProcessor.__init__(self, pattern, md) + + def handleMatch(self, m, data): + """Convert the char to an escaped character.""" + + char = m.group(1) + if char in ('<', '>', '&'): + if char == '<': + char = '<' + elif char == '>': + char = '>' + elif char == '&': + char = '&' + escape = self.md.htmlStash.store(char) + elif self.nbsp and char == ' ': + escape = self.md.htmlStash.store(' ') + elif char in (STX, ETX): + escape = char + else: + escape = '{}{}{}'.format(md_util.STX, util.get_ord(char), md_util.ETX) + return escape, m.start(0), m.end(0) + + +class EscapeAllExtension(Extension): + """Extension that allows you to escape everything.""" + + def __init__(self, *args, **kwargs): + """Initialize.""" + + self.config = { + 'hardbreak': [ + False, + "Turn escaped newlines to hardbreaks - Default: False" + ], + 'nbsp': [ + False, + "Turn escaped spaces to non-breaking spaces - Default: False" + ] + } + super().__init__(*args, **kwargs) + + def extendMarkdown(self, md): + """Escape all.""" + + config = self.getConfigs() + hardbreak = config['hardbreak'] + md.inlinePatterns.register( + EscapeAllPattern(ESCAPE_NO_NL_RE if hardbreak else ESCAPE_RE, config['nbsp'], md), + "escape", + 180 + ) + + if config['hardbreak']: + md.inlinePatterns.register(SubstituteTagInlineProcessor(HARDBREAK_RE, 'br'), "hardbreak", 5.1) + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return EscapeAllExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/extra.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/extra.py new file mode 100644 index 0000000000000000000000000000000000000000..2fdabe5784fb85fb5af3ac441f079c7fa57a592c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/extra.py @@ -0,0 +1,65 @@ +""" +Extra. + +pymdown.extra +A wrapper that emulate PHP Markdown Extra. +Re-packages Python Markdowns 'extra' extensions, +but substitutes a few extensions with PyMdown extensions: + +- fenced_code --> superfences +- smartstrong --> betterem + +MIT license. + +Copyright (c) 2015 - 2017 Isaac Muse + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, +and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +""" +from markdown import Extension + +extra_extensions = [ + 'pymdownx.betterem', + 'pymdownx.superfences', + 'markdown.extensions.footnotes', + 'markdown.extensions.attr_list', + 'markdown.extensions.def_list', + 'markdown.extensions.tables', + 'markdown.extensions.abbr', + 'markdown.extensions.md_in_html' +] + +extra_extension_configs = {} + + +class ExtraExtension(Extension): + """Add various extensions to Markdown class.""" + + def __init__(self, *args, **kwargs): + """Initialize.""" + + self.config = kwargs.pop('configs', {}) + self.config.update(extra_extension_configs) + self.config.update(kwargs) + + def extendMarkdown(self, md): + """Register extension instances.""" + + md.registerExtensions(extra_extensions, self.config) + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return ExtraExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/fancylists.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/fancylists.py new file mode 100644 index 0000000000000000000000000000000000000000..88cafe15086ebb88c7e704fbf46e2e105a7715bd --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/fancylists.py @@ -0,0 +1,535 @@ +""" +Fancy lists in the style of Pandoc. + +--- +# A Python implementation of John Gruber's Markdown. + +# Started by Manfred Stienstra (http://www.dwerg.net/). +# Maintained for a few years by Yuri Takhteyev (http://www.freewisdom.org). +# Currently maintained by Waylan Limberg (https://github.com/waylan), +# Dmitry Shachnev (https://github.com/mitya57) and Isaac Muse (https://github.com/facelessuser). + +# Copyright 2007-2023 The Python Markdown Project (v. 1.7 and later) +# Copyright 2004, 2005, 2006 Yuri Takhteyev (v. 0.2-1.6b) +# Copyright 2004 Manfred Stienstra (the original version) + +# License: BSD (see LICENSE.md for details). +--- + +Adapted to support "fancy" behavior by Copyright 2024 Isaac Muse. + +Work in progress, not fully tested. +""" +from markdown.blockprocessors import BlockProcessor +from markdown.treeprocessors import Treeprocessor +from .blocks.block import Block +from .blocks import BlocksExtension +import xml.etree.ElementTree as etree +import re + +ROMAN_MAP = {'I': 1, 'V': 5, 'X': 10, 'L': 50, 'C': 100, 'D': 500, 'M': 1000} + +OL_STYLE = { + '1': 'decimal', + 'a': 'lower-alpha', + 'A': 'upper-alpha', + 'i': 'lower-roman', + 'I': 'upper-roman' +} + + +def roman2int(s): + """ + Convert Roman numeral to integer. + + Values should be validated before as no validation during conversion. + """ + + s = s.upper() + + # Initialize result + total = 0 + i = 0 + while i < len(s): + # Current index is less than the next, subtract current from next and sum value + if i + 1 < len(s) and ROMAN_MAP[s[i]] < ROMAN_MAP[s[i + 1]]: + total += ROMAN_MAP[s[i + 1]] - ROMAN_MAP[s[i]] + i += 2 + # Sum the value + else: + total += ROMAN_MAP[s[i]] + i += 1 + + return total + + +class FancyOListProcessor(BlockProcessor): + """Process fancy ordered list blocks.""" + + TAG = 'ol' + SIBLING_TAGS = ['ol'] + OL_TYPES = { + 'dot-decimal': '1', + 'paren-decimal': '1', + 'dot-roman': 'i', + 'paren-roman': 'i', + 'dot-ROMAN': 'I', + 'paren-ROMAN': 'I', + 'dot-alpha': 'a', + 'paren-alpha': 'a', + 'dot-ALPHA': 'A', + 'paren-ALPHA': 'A' + } + + def __init__(self, parser, config): + """Initialize.""" + + super().__init__(parser) + + list_types = config['additional_ordered_styles'] + self.alpha_enabled = 'alpha' in list_types + self.roman_enabled = 'roman' in list_types + self.inject_style = config['inject_style'] + self.inject_class = config['inject_class'] + + formats = '' + + if 'generic' in list_types: + formats += r'| \#' + + if 'roman' in list_types: + # Rules are similar to https://projecteuler.net/about=roman_numerals + # We do not follow the "rule of 3": repeated values should not occur more than 3 times. + # The above link suggests that repeats should be restricted such that lower denominations + # do not equal or exceed X, C or M. We alter this to allow equaling to help mitigate + # conflicts with alphabetical lists. + formats += r''' + | (?=[IVXLCDM]{2}) + M* + (?:C[MD]|D(?:C{0,4}|C{5}\b)|(?:C{0,9}|C{10}\b)) + (?:X[CL]|L(?:X{0,4}|X{5}\b)|(?:X{0,9}|X{10}\b)) + (?:I[XV]|V(?:I{0,4}|I{5}\b)|(?:I{0,9}|I{10}\b)) + | (?=[ivxlcdm]) + m* + (?:c[md]|d(?:c{0,4}|c{5}\b)|(?:c{0,9}|c{10}\b)) + (?:x[cl]|l(?:x{0,4}|x{5}\b)|(?:x{0,9}|x{10}\b)) + (?:i[xv]|v(?:i{0,4}|i{5}\b)|(?:i{0,9}|i{10}\b)) + ''' + + if 'alpha' not in list_types: + formats += r''' + | [IVXLCDM](?=\)|\.[ ]{2}) + ''' + + if 'alpha' in list_types: + formats += r''' + | [a-z] + | [A-Z](?=\)|\.[ ]{2}) + ''' + + # Detect an item list item. + self.list_re = re.compile( + r'^[ ]{0,%d}(?:(?:\d+%s)[).])[ ]+(.*)' % (self.tab_length - 1, formats), + re.VERBOSE + ) + + # Detect items on secondary lines which can be of any list type. + self.child_re = re.compile( + r'^[ ]{0,%d}((?:(?:\d+%s)[).]|[-*+]))[ ]+(.*)' % (self.tab_length - 1, formats), + re.VERBOSE + ) + + # Detect indented (nested) list items of any type. + self.indent_re = re.compile( + r'^[ ]{%d,%d}(?:(?:\d+%s)[).]|[-*+])[ ]+.*' % (self.tab_length, self.tab_length * 2 - 1, formats), + re.VERBOSE + ) + + self.startswith = "1" + + def test(self, parent, block): + """Test to see if block starts with a list.""" + + return bool(self.list_re.match(block)) + + def run(self, parent, blocks): + """Process list items.""" + + sibling = self.lastChild(parent) + + # Check for multiple items in one block and get the ordered list fancy type. + items, fancy_type = self.get_items(sibling, blocks.pop(0), blocks) + + # Append list items that are under the sibling list if the list type matches + if ( + sibling is not None and sibling.tag in self.SIBLING_TAGS and + sibling.attrib.get('__fancylist', '') == fancy_type + ): + # Previous block was a list item, so set that as parent + lst = sibling + + # Make sure previous item is in a `p` - if the item has text, + # then it isn't in a `p`. + if lst[-1].text: + # Since it's possible there are other children for this + # sibling, we can't just `SubElement` the `p`, we need to + # insert it as the first item. + p = etree.Element('p') + p.text = lst[-1].text + lst[-1].text = '' + lst[-1].insert(0, p) + + # If the last item has a tail, then the tail needs to be put in a `p` + # likely only when a header is not followed by a blank line. + lch = self.lastChild(lst[-1]) + if lch is not None and lch.tail: + p = etree.SubElement(lst[-1], 'p') + p.text = lch.tail.lstrip() + lch.tail = '' + + # Parse first block differently as it gets wrapped in a `p`. + li = etree.SubElement(lst, 'li') + self.parser.state.set('looselist') + firstitem = items.pop(0) + self.parser.parseBlocks(li, [firstitem]) + self.parser.state.reset() + + # This catches the edge case of a multi-item indented list whose + # first item is in a blank parent-list item: + # ``` + # * * subitem1 + # * subitem2 + # ``` + # see also `ListIndentProcessor` + elif parent.tag in ['ol', 'ul']: + lst = parent + + # This is a new, unique list so create parent with appropriate tag. + else: + if self.TAG == 'ol': + # Correct the metadata of a forced list to now represent the actual content + if sibling is not None and sibling.attrib.get('__fancylist', '').startswith('force'): + sibling.attrib['__fancylist'] = fancy_type + lst = sibling + else: + attrib = {'type': self.OL_TYPES[fancy_type], '__fancylist': fancy_type} + if self.inject_style: + attrib['style'] = f"list-style-type: {OL_STYLE[attrib['type']]};" + if self.inject_class: + attrib['class'] = f"fancylists-{OL_STYLE[attrib['type']]}" + lst = etree.SubElement( + parent, + self.TAG, + attrib + ) + else: + lst = etree.SubElement(parent, self.TAG) + + # Check if a custom start integer is set + if self.startswith != '1' and not lst.attrib.get('start', ''): + lst.attrib['start'] = self.startswith + + # Set the parse set to list + self.parser.state.set('list') + + # Loop through items in block, recursively parsing each with the appropriate parent. + for item in items: + # Item is indented. Parse with last item as parent + if item.startswith(' '*self.tab_length): + self.parser.parseBlocks(lst[-1], [item]) + # New item. Create `li` and parse with it as parent + else: + li = etree.SubElement(lst, 'li') + self.parser.parseBlocks(li, [item]) + + # Reset the parse state + self.parser.state.reset() + + def get_start(self, fancy_type, m): + """Translate list convention into a logical start.""" + + # Generic marker + if m.group(1).startswith('#'): + return '1' + + t = fancy_type.split('-')[1].lower() + if t == 'decimal': + return m.group(1)[:-1].lstrip('(') + elif t == 'roman': + return str(roman2int(m.group(1)[:-1])) + elif t == 'alpha': + return str(ord(m.group(1)[:-1].upper()) - 64) + + def get_fancy_type(self, m, first, fancy_type): + """Get the fancy type for a given list item.""" + + value = m.group(1)[:-1] + sep = m.group(1)[-1] + list_type = '' + + # Determine list type convention: _., _), (_) + if sep == '.': + list_type += 'dot-' + elif sep == ')': + list_type += 'paren-' + else: + return list_type, fancy_type + + # The first item will be forced to assume the sibling list's type + if fancy_type.startswith('force'): + ltype = fancy_type.split('-', 1)[1] + # Make sure we aren't forcing an impossible scenario. + # If everything looks sound, return the types + if value == '#' or ( + (ltype.lower() == 'decimal' and value.isdigit()) or + ( + ltype.lower() == 'roman' and + self.roman_enabled and + value.isalpha() and + (len(value) > 2 or value.lower() in 'ivxlcdm') + ) or + (ltype.lower() == 'alpha' and self.alpha_enabled and len(value) == 1 and value.isalpha()) + ): + fancy_type = list_type + fancy_type.split('-', 1)[1] if list_type else list_type + return fancy_type, fancy_type + + # Ignore the force as it cannot be done + fancy_type = '' + + # Determine numbering: numerical, roman numerical, alphabetic, or `#` numerical placeholder. + if value == '#': + list_type += fancy_type.split('-', 1)[1] if fancy_type else 'decimal' + elif value.isdigit(): + list_type += 'decimal' + elif len(value) == 1 and value.isalpha(): + if value.islower(): + in_roman = value in 'ivxlcdm' + if ( + self.alpha_enabled and ( + not self.roman_enabled or ( + first and (not in_roman or ((list_type + 'roman') != fancy_type and value != 'i')) + ) + ) + ): + list_type += 'alpha' + elif self.alpha_enabled and not first and ((list_type + 'alpha') == fancy_type or not in_roman): + list_type += 'alpha' + else: + list_type += 'roman' + elif value.isupper(): + in_roman = value in 'IVXLCDM' + if ( + self.alpha_enabled and ( + not self.roman_enabled or ( + first and (not in_roman or ((list_type + 'ROMAN') != fancy_type and value != 'I')) + ) + ) + ): + list_type += 'ALPHA' + elif self.alpha_enabled and not first and ((list_type + 'ALPHA') == fancy_type or not in_roman): + list_type += 'ALPHA' + else: + list_type += 'ROMAN' + elif value.isupper(): + list_type += 'ROMAN' + elif value.islower(): + list_type += 'roman' + + return list_type, fancy_type + + def get_items(self, sibling, block, blocks): + """Break a block into list items.""" + + # Get ordered list fancy type + fancy_type = '' + if self.TAG == 'ol': + if sibling is not None and sibling.tag in self.SIBLING_TAGS: + fancy_type = sibling.attrib.get('__fancylist', '') + fancy = fancy_type + + items = [] + rest = [] + for line in block.split('\n'): + + # We've found a list type that differs form the our current, + # so gather the rest to be processed separately. + if rest: + rest.append(line) + continue + + # Child list items + m = self.child_re.match(line) + if m: + # This is a new list item check first item for the start index. + # Also check for list items that differ from the first. + fancy, fancy_type = self.get_fancy_type(m, not items, fancy) + + # We found a different fancy type, so handle these separately + if items and fancy != fancy_type: + rest.append(line) + continue + + # Detect the integer value of first list item. + # If we are already in a list, just grab that. + if not items and self.TAG == 'ol': + self.startswith = self.get_start(fancy, m) + fancy_type = fancy + + # Append to the list + items.append(m.group(2)) + + # Indented, possibly nested content + elif self.indent_re.match(line): + # Previous item was indented. Append to that item. + if items[-1].startswith(' ' * self.tab_length): + items[-1] = '{}\n{}'.format(items[-1], line) + # Other indented content + else: + items.append(line) + + # Append non list items to previous list item. + else: + items[-1] = '{}\n{}'.format(items[-1], line) + + # Insert non-list items back into the blocks to be parsed later + if rest: + blocks.insert(0, '\n'.join(rest)) + + return items, fancy_type + + +class FancyListBlock(Block): + """Collapse code.""" + + NAME = 'fancylists' + ARGUMENT = True + OL_TYPE = { + '1': 'decimal', + 'a': 'alpha', + 'A': 'ALPHA', + 'i': 'roman', + 'I': 'ROMAN' + } + + def on_init(self): + """Handle initialization.""" + + ordered_styles = self.config['additional_ordered_styles'] + self.inject_style = self.config['inject_style'] + self.inject_class = self.config['inject_class'] + self.roman_enabled = 'roman' in ordered_styles + self.alpha_enabled = 'alpha' in ordered_styles + + def on_validate(self, parent): + """Handle on validate event.""" + + self.type = '1' + self.start = None + self.count = 0 + + try: + for a in self.argument.split(): + name, value = [x.strip() for x in a.split('=')] + if name == 'type' and value in ['a', 'A', 'i', 'I', '1']: + if value.lower() == 'a' and not self.alpha_enabled: + raise ValueError('Alphabetical lists not enabled') + if value.lower() == 'i' and not self.roman_enabled: + raise ValueError('Alphabetical lists not enabled') + self.type = value + elif name == 'start': + self.start = max(0, int(value)) + else: + raise ValueError('Not a valid option') + except Exception: + return False + + return True + + def on_create(self, parent): + """Create the element.""" + + # Create an ordered list that will guide the first list item's type + attrib = {'type': self.type, '__fancylist': 'force-' + self.OL_TYPE[self.type]} + if self.start is not None: + attrib['start'] = str(self.start) + if self.inject_style: + attrib['style'] = f"list-style-type: {OL_STYLE[self.type]};" + if self.inject_class: + attrib['class'] = f"fancylists-{OL_STYLE[self.type]}" + + self.parent = parent + self.ol = etree.SubElement(parent, 'ol', attrib) + return parent + + def on_end(self, block): + """On end.""" + + # Remove the ordered list if empty. + if not list(self.ol): + self.parent.remove(self.ol) + + +class FancyUListProcessor(FancyOListProcessor): + """Process unordered list blocks.""" + + SIBLING_TAGS = ['ul'] + TAG = 'ul' + + def __init__(self, parser, config): + """Initialize.""" + + super().__init__(parser, config) + self.list_re = re.compile(r'^[ ]{0,%d}[-+*][ ]+(.*)' % (self.tab_length - 1)) + + +class FancyListTreeprocessor(Treeprocessor): + """Clean up fancy list metadata.""" + + def run(self, root): + """Remove intermediate fancy list type metadata.""" + + for ol in root.iter('ol'): + if '__fancylist' in ol.attrib: + del ol.attrib['__fancylist'] + return root + + +class FancyListExtension(BlocksExtension): + """HTML Blocks Extension.""" + + def __init__(self, *args, **kwargs): + """Initialize.""" + + self.config = { + 'additional_ordered_styles': [ + ['roman', 'alpha', 'generic'], + "Specify the ordered list formats to add in addition to decimal.", + ], + 'inject_style': [ + False, + "Inject style attribute with the appropriate 'list-style-type'" + ], + 'inject_class': [ + False, + "Inject a class indicating the 'list-style-type'" + ] + } + + super().__init__(*args, **kwargs) + + def extendMarkdownBlocks(self, md, blocks): + """Add Details to Markdown instance.""" + + config = self.getConfigs() + blocks.register(FancyListBlock, config) + ol = FancyOListProcessor(md.parser, config) + ul = FancyUListProcessor(md.parser, config) + md.parser.blockprocessors.register(ol, 'olist', 40) + md.parser.blockprocessors.register(ul, 'ulist', 30) + md.treeprocessors.register(FancyListTreeprocessor(md), "olist-cleanup", 10) + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return FancyListExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/gemoji_db.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/gemoji_db.py new file mode 100644 index 0000000000000000000000000000000000000000..3140bc640eb83437842a11f3faddec48dd904676 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/gemoji_db.py @@ -0,0 +1,9865 @@ +"""Gemoji autogen. + +Generated from gemoji source. Do not edit by hand. + +Copyright (c) 2019 GitHub, Inc. + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. +""" +version = "v4.1.0" +name = "gemoji" +emoji = { + ":+1:": { + "category": "People & Body", + "name": "thumbs up", + "unicode": "1f44d" + }, + ":-1:": { + "category": "People & Body", + "name": "thumbs down", + "unicode": "1f44e" + }, + ":100:": { + "category": "Smileys & Emotion", + "name": "hundred points", + "unicode": "1f4af" + }, + ":1234:": { + "category": "Symbols", + "name": "input numbers", + "unicode": "1f522" + }, + ":1st_place_medal:": { + "category": "Activities", + "name": "1st place medal", + "unicode": "1f947" + }, + ":2nd_place_medal:": { + "category": "Activities", + "name": "2nd place medal", + "unicode": "1f948" + }, + ":3rd_place_medal:": { + "category": "Activities", + "name": "3rd place medal", + "unicode": "1f949" + }, + ":8ball:": { + "category": "Activities", + "name": "pool 8 ball", + "unicode": "1f3b1" + }, + ":a:": { + "category": "Symbols", + "name": "A button (blood type)", + "unicode": "1f170", + "unicode_alt": "1f170-fe0f" + }, + ":ab:": { + "category": "Symbols", + "name": "AB button (blood type)", + "unicode": "1f18e" + }, + ":abacus:": { + "category": "Objects", + "name": "abacus", + "unicode": "1f9ee" + }, + ":abc:": { + "category": "Symbols", + "name": "input latin letters", + "unicode": "1f524" + }, + ":abcd:": { + "category": "Symbols", + "name": "input latin lowercase", + "unicode": "1f521" + }, + ":accept:": { + "category": "Symbols", + "name": "Japanese \u201cacceptable\u201d button", + "unicode": "1f251" + }, + ":accordion:": { + "category": "Objects", + "name": "accordion", + "unicode": "1fa97" + }, + ":adhesive_bandage:": { + "category": "Objects", + "name": "adhesive bandage", + "unicode": "1fa79" + }, + ":adult:": { + "category": "People & Body", + "name": "person", + "unicode": "1f9d1" + }, + ":aerial_tramway:": { + "category": "Travel & Places", + "name": "aerial tramway", + "unicode": "1f6a1" + }, + ":afghanistan:": { + "category": "Flags", + "name": "flag: Afghanistan", + "unicode": "1f1e6-1f1eb" + }, + ":airplane:": { + "category": "Travel & Places", + "name": "airplane", + "unicode": "2708", + "unicode_alt": "2708-fe0f" + }, + ":aland_islands:": { + "category": "Flags", + "name": "flag: \u00c5land Islands", + "unicode": "1f1e6-1f1fd" + }, + ":alarm_clock:": { + "category": "Travel & Places", + "name": "alarm clock", + "unicode": "23f0" + }, + ":albania:": { + "category": "Flags", + "name": "flag: Albania", + "unicode": "1f1e6-1f1f1" + }, + ":alembic:": { + "category": "Objects", + "name": "alembic", + "unicode": "2697", + "unicode_alt": "2697-fe0f" + }, + ":algeria:": { + "category": "Flags", + "name": "flag: Algeria", + "unicode": "1f1e9-1f1ff" + }, + ":alien:": { + "category": "Smileys & Emotion", + "name": "alien", + "unicode": "1f47d" + }, + ":ambulance:": { + "category": "Travel & Places", + "name": "ambulance", + "unicode": "1f691" + }, + ":american_samoa:": { + "category": "Flags", + "name": "flag: American Samoa", + "unicode": "1f1e6-1f1f8" + }, + ":amphora:": { + "category": "Food & Drink", + "name": "amphora", + "unicode": "1f3fa" + }, + ":anatomical_heart:": { + "category": "People & Body", + "name": "anatomical heart", + "unicode": "1fac0" + }, + ":anchor:": { + "category": "Travel & Places", + "name": "anchor", + "unicode": "2693" + }, + ":andorra:": { + "category": "Flags", + "name": "flag: Andorra", + "unicode": "1f1e6-1f1e9" + }, + ":angel:": { + "category": "People & Body", + "name": "baby angel", + "unicode": "1f47c" + }, + ":anger:": { + "category": "Smileys & Emotion", + "name": "anger symbol", + "unicode": "1f4a2" + }, + ":angola:": { + "category": "Flags", + "name": "flag: Angola", + "unicode": "1f1e6-1f1f4" + }, + ":angry:": { + "category": "Smileys & Emotion", + "name": "angry face", + "unicode": "1f620" + }, + ":anguilla:": { + "category": "Flags", + "name": "flag: Anguilla", + "unicode": "1f1e6-1f1ee" + }, + ":anguished:": { + "category": "Smileys & Emotion", + "name": "anguished face", + "unicode": "1f627" + }, + ":ant:": { + "category": "Animals & Nature", + "name": "ant", + "unicode": "1f41c" + }, + ":antarctica:": { + "category": "Flags", + "name": "flag: Antarctica", + "unicode": "1f1e6-1f1f6" + }, + ":antigua_barbuda:": { + "category": "Flags", + "name": "flag: Antigua & Barbuda", + "unicode": "1f1e6-1f1ec" + }, + ":apple:": { + "category": "Food & Drink", + "name": "red apple", + "unicode": "1f34e" + }, + ":aquarius:": { + "category": "Symbols", + "name": "Aquarius", + "unicode": "2652" + }, + ":argentina:": { + "category": "Flags", + "name": "flag: Argentina", + "unicode": "1f1e6-1f1f7" + }, + ":aries:": { + "category": "Symbols", + "name": "Aries", + "unicode": "2648" + }, + ":armenia:": { + "category": "Flags", + "name": "flag: Armenia", + "unicode": "1f1e6-1f1f2" + }, + ":arrow_backward:": { + "category": "Symbols", + "name": "reverse button", + "unicode": "25c0", + "unicode_alt": "25c0-fe0f" + }, + ":arrow_double_down:": { + "category": "Symbols", + "name": "fast down button", + "unicode": "23ec" + }, + ":arrow_double_up:": { + "category": "Symbols", + "name": "fast up button", + "unicode": "23eb" + }, + ":arrow_down:": { + "category": "Symbols", + "name": "down arrow", + "unicode": "2b07", + "unicode_alt": "2b07-fe0f" + }, + ":arrow_down_small:": { + "category": "Symbols", + "name": "downwards button", + "unicode": "1f53d" + }, + ":arrow_forward:": { + "category": "Symbols", + "name": "play button", + "unicode": "25b6", + "unicode_alt": "25b6-fe0f" + }, + ":arrow_heading_down:": { + "category": "Symbols", + "name": "right arrow curving down", + "unicode": "2935", + "unicode_alt": "2935-fe0f" + }, + ":arrow_heading_up:": { + "category": "Symbols", + "name": "right arrow curving up", + "unicode": "2934", + "unicode_alt": "2934-fe0f" + }, + ":arrow_left:": { + "category": "Symbols", + "name": "left arrow", + "unicode": "2b05", + "unicode_alt": "2b05-fe0f" + }, + ":arrow_lower_left:": { + "category": "Symbols", + "name": "down-left arrow", + "unicode": "2199", + "unicode_alt": "2199-fe0f" + }, + ":arrow_lower_right:": { + "category": "Symbols", + "name": "down-right arrow", + "unicode": "2198", + "unicode_alt": "2198-fe0f" + }, + ":arrow_right:": { + "category": "Symbols", + "name": "right arrow", + "unicode": "27a1", + "unicode_alt": "27a1-fe0f" + }, + ":arrow_right_hook:": { + "category": "Symbols", + "name": "left arrow curving right", + "unicode": "21aa", + "unicode_alt": "21aa-fe0f" + }, + ":arrow_up:": { + "category": "Symbols", + "name": "up arrow", + "unicode": "2b06", + "unicode_alt": "2b06-fe0f" + }, + ":arrow_up_down:": { + "category": "Symbols", + "name": "up-down arrow", + "unicode": "2195", + "unicode_alt": "2195-fe0f" + }, + ":arrow_up_small:": { + "category": "Symbols", + "name": "upwards button", + "unicode": "1f53c" + }, + ":arrow_upper_left:": { + "category": "Symbols", + "name": "up-left arrow", + "unicode": "2196", + "unicode_alt": "2196-fe0f" + }, + ":arrow_upper_right:": { + "category": "Symbols", + "name": "up-right arrow", + "unicode": "2197", + "unicode_alt": "2197-fe0f" + }, + ":arrows_clockwise:": { + "category": "Symbols", + "name": "clockwise vertical arrows", + "unicode": "1f503" + }, + ":arrows_counterclockwise:": { + "category": "Symbols", + "name": "counterclockwise arrows button", + "unicode": "1f504" + }, + ":art:": { + "category": "Activities", + "name": "artist palette", + "unicode": "1f3a8" + }, + ":articulated_lorry:": { + "category": "Travel & Places", + "name": "articulated lorry", + "unicode": "1f69b" + }, + ":artificial_satellite:": { + "category": "Travel & Places", + "name": "satellite", + "unicode": "1f6f0", + "unicode_alt": "1f6f0-fe0f" + }, + ":artist:": { + "category": "People & Body", + "name": "artist", + "unicode": "1f9d1-1f3a8", + "unicode_alt": "1f9d1-200d-1f3a8" + }, + ":aruba:": { + "category": "Flags", + "name": "flag: Aruba", + "unicode": "1f1e6-1f1fc" + }, + ":ascension_island:": { + "category": "Flags", + "name": "flag: Ascension Island", + "unicode": "1f1e6-1f1e8" + }, + ":asterisk:": { + "category": "Symbols", + "name": "keycap: *", + "unicode": "002a-20e3", + "unicode_alt": "002a-fe0f-20e3" + }, + ":astonished:": { + "category": "Smileys & Emotion", + "name": "astonished face", + "unicode": "1f632" + }, + ":astronaut:": { + "category": "People & Body", + "name": "astronaut", + "unicode": "1f9d1-1f680", + "unicode_alt": "1f9d1-200d-1f680" + }, + ":athletic_shoe:": { + "category": "Objects", + "name": "running shoe", + "unicode": "1f45f" + }, + ":atm:": { + "category": "Symbols", + "name": "ATM sign", + "unicode": "1f3e7" + }, + ":atom_symbol:": { + "category": "Symbols", + "name": "atom symbol", + "unicode": "269b", + "unicode_alt": "269b-fe0f" + }, + ":australia:": { + "category": "Flags", + "name": "flag: Australia", + "unicode": "1f1e6-1f1fa" + }, + ":austria:": { + "category": "Flags", + "name": "flag: Austria", + "unicode": "1f1e6-1f1f9" + }, + ":auto_rickshaw:": { + "category": "Travel & Places", + "name": "auto rickshaw", + "unicode": "1f6fa" + }, + ":avocado:": { + "category": "Food & Drink", + "name": "avocado", + "unicode": "1f951" + }, + ":axe:": { + "category": "Objects", + "name": "axe", + "unicode": "1fa93" + }, + ":azerbaijan:": { + "category": "Flags", + "name": "flag: Azerbaijan", + "unicode": "1f1e6-1f1ff" + }, + ":b:": { + "category": "Symbols", + "name": "B button (blood type)", + "unicode": "1f171", + "unicode_alt": "1f171-fe0f" + }, + ":baby:": { + "category": "People & Body", + "name": "baby", + "unicode": "1f476" + }, + ":baby_bottle:": { + "category": "Food & Drink", + "name": "baby bottle", + "unicode": "1f37c" + }, + ":baby_chick:": { + "category": "Animals & Nature", + "name": "baby chick", + "unicode": "1f424" + }, + ":baby_symbol:": { + "category": "Symbols", + "name": "baby symbol", + "unicode": "1f6bc" + }, + ":back:": { + "category": "Symbols", + "name": "BACK arrow", + "unicode": "1f519" + }, + ":bacon:": { + "category": "Food & Drink", + "name": "bacon", + "unicode": "1f953" + }, + ":badger:": { + "category": "Animals & Nature", + "name": "badger", + "unicode": "1f9a1" + }, + ":badminton:": { + "category": "Activities", + "name": "badminton", + "unicode": "1f3f8" + }, + ":bagel:": { + "category": "Food & Drink", + "name": "bagel", + "unicode": "1f96f" + }, + ":baggage_claim:": { + "category": "Symbols", + "name": "baggage claim", + "unicode": "1f6c4" + }, + ":baguette_bread:": { + "category": "Food & Drink", + "name": "baguette bread", + "unicode": "1f956" + }, + ":bahamas:": { + "category": "Flags", + "name": "flag: Bahamas", + "unicode": "1f1e7-1f1f8" + }, + ":bahrain:": { + "category": "Flags", + "name": "flag: Bahrain", + "unicode": "1f1e7-1f1ed" + }, + ":balance_scale:": { + "category": "Objects", + "name": "balance scale", + "unicode": "2696", + "unicode_alt": "2696-fe0f" + }, + ":bald_man:": { + "category": "People & Body", + "name": "man: bald", + "unicode": "1f468-1f9b2", + "unicode_alt": "1f468-200d-1f9b2" + }, + ":bald_woman:": { + "category": "People & Body", + "name": "woman: bald", + "unicode": "1f469-1f9b2", + "unicode_alt": "1f469-200d-1f9b2" + }, + ":ballet_shoes:": { + "category": "Objects", + "name": "ballet shoes", + "unicode": "1fa70" + }, + ":balloon:": { + "category": "Activities", + "name": "balloon", + "unicode": "1f388" + }, + ":ballot_box:": { + "category": "Objects", + "name": "ballot box with ballot", + "unicode": "1f5f3", + "unicode_alt": "1f5f3-fe0f" + }, + ":ballot_box_with_check:": { + "category": "Symbols", + "name": "check box with check", + "unicode": "2611", + "unicode_alt": "2611-fe0f" + }, + ":bamboo:": { + "category": "Activities", + "name": "pine decoration", + "unicode": "1f38d" + }, + ":banana:": { + "category": "Food & Drink", + "name": "banana", + "unicode": "1f34c" + }, + ":bangbang:": { + "category": "Symbols", + "name": "double exclamation mark", + "unicode": "203c", + "unicode_alt": "203c-fe0f" + }, + ":bangladesh:": { + "category": "Flags", + "name": "flag: Bangladesh", + "unicode": "1f1e7-1f1e9" + }, + ":banjo:": { + "category": "Objects", + "name": "banjo", + "unicode": "1fa95" + }, + ":bank:": { + "category": "Travel & Places", + "name": "bank", + "unicode": "1f3e6" + }, + ":bar_chart:": { + "category": "Objects", + "name": "bar chart", + "unicode": "1f4ca" + }, + ":barbados:": { + "category": "Flags", + "name": "flag: Barbados", + "unicode": "1f1e7-1f1e7" + }, + ":barber:": { + "category": "Travel & Places", + "name": "barber pole", + "unicode": "1f488" + }, + ":baseball:": { + "category": "Activities", + "name": "baseball", + "unicode": "26be" + }, + ":basket:": { + "category": "Objects", + "name": "basket", + "unicode": "1f9fa" + }, + ":basketball:": { + "category": "Activities", + "name": "basketball", + "unicode": "1f3c0" + }, + ":bat:": { + "category": "Animals & Nature", + "name": "bat", + "unicode": "1f987" + }, + ":bath:": { + "category": "People & Body", + "name": "person taking bath", + "unicode": "1f6c0" + }, + ":bathtub:": { + "category": "Objects", + "name": "bathtub", + "unicode": "1f6c1" + }, + ":battery:": { + "category": "Objects", + "name": "battery", + "unicode": "1f50b" + }, + ":beach_umbrella:": { + "category": "Travel & Places", + "name": "beach with umbrella", + "unicode": "1f3d6", + "unicode_alt": "1f3d6-fe0f" + }, + ":beans:": { + "category": "Food & Drink", + "name": "beans", + "unicode": "1fad8" + }, + ":bear:": { + "category": "Animals & Nature", + "name": "bear", + "unicode": "1f43b" + }, + ":bearded_person:": { + "category": "People & Body", + "name": "person: beard", + "unicode": "1f9d4" + }, + ":beaver:": { + "category": "Animals & Nature", + "name": "beaver", + "unicode": "1f9ab" + }, + ":bed:": { + "category": "Objects", + "name": "bed", + "unicode": "1f6cf", + "unicode_alt": "1f6cf-fe0f" + }, + ":bee:": { + "category": "Animals & Nature", + "name": "honeybee", + "unicode": "1f41d" + }, + ":beer:": { + "category": "Food & Drink", + "name": "beer mug", + "unicode": "1f37a" + }, + ":beers:": { + "category": "Food & Drink", + "name": "clinking beer mugs", + "unicode": "1f37b" + }, + ":beetle:": { + "category": "Animals & Nature", + "name": "beetle", + "unicode": "1fab2" + }, + ":beginner:": { + "category": "Symbols", + "name": "Japanese symbol for beginner", + "unicode": "1f530" + }, + ":belarus:": { + "category": "Flags", + "name": "flag: Belarus", + "unicode": "1f1e7-1f1fe" + }, + ":belgium:": { + "category": "Flags", + "name": "flag: Belgium", + "unicode": "1f1e7-1f1ea" + }, + ":belize:": { + "category": "Flags", + "name": "flag: Belize", + "unicode": "1f1e7-1f1ff" + }, + ":bell:": { + "category": "Objects", + "name": "bell", + "unicode": "1f514" + }, + ":bell_pepper:": { + "category": "Food & Drink", + "name": "bell pepper", + "unicode": "1fad1" + }, + ":bellhop_bell:": { + "category": "Travel & Places", + "name": "bellhop bell", + "unicode": "1f6ce", + "unicode_alt": "1f6ce-fe0f" + }, + ":benin:": { + "category": "Flags", + "name": "flag: Benin", + "unicode": "1f1e7-1f1ef" + }, + ":bento:": { + "category": "Food & Drink", + "name": "bento box", + "unicode": "1f371" + }, + ":bermuda:": { + "category": "Flags", + "name": "flag: Bermuda", + "unicode": "1f1e7-1f1f2" + }, + ":beverage_box:": { + "category": "Food & Drink", + "name": "beverage box", + "unicode": "1f9c3" + }, + ":bhutan:": { + "category": "Flags", + "name": "flag: Bhutan", + "unicode": "1f1e7-1f1f9" + }, + ":bicyclist:": { + "category": "People & Body", + "name": "person biking", + "unicode": "1f6b4" + }, + ":bike:": { + "category": "Travel & Places", + "name": "bicycle", + "unicode": "1f6b2" + }, + ":biking_man:": { + "category": "People & Body", + "name": "man biking", + "unicode": "1f6b4-2642", + "unicode_alt": "1f6b4-200d-2642-fe0f" + }, + ":biking_woman:": { + "category": "People & Body", + "name": "woman biking", + "unicode": "1f6b4-2640", + "unicode_alt": "1f6b4-200d-2640-fe0f" + }, + ":bikini:": { + "category": "Objects", + "name": "bikini", + "unicode": "1f459" + }, + ":billed_cap:": { + "category": "Objects", + "name": "billed cap", + "unicode": "1f9e2" + }, + ":biohazard:": { + "category": "Symbols", + "name": "biohazard", + "unicode": "2623", + "unicode_alt": "2623-fe0f" + }, + ":bird:": { + "category": "Animals & Nature", + "name": "bird", + "unicode": "1f426" + }, + ":birthday:": { + "category": "Food & Drink", + "name": "birthday cake", + "unicode": "1f382" + }, + ":bison:": { + "category": "Animals & Nature", + "name": "bison", + "unicode": "1f9ac" + }, + ":biting_lip:": { + "category": "People & Body", + "name": "biting lip", + "unicode": "1fae6" + }, + ":black_bird:": { + "category": "Animals & Nature", + "name": "black bird", + "unicode": "1f426-2b1b", + "unicode_alt": "1f426-200d-2b1b" + }, + ":black_cat:": { + "category": "Animals & Nature", + "name": "black cat", + "unicode": "1f408-2b1b", + "unicode_alt": "1f408-200d-2b1b" + }, + ":black_circle:": { + "category": "Symbols", + "name": "black circle", + "unicode": "26ab" + }, + ":black_flag:": { + "category": "Flags", + "name": "black flag", + "unicode": "1f3f4" + }, + ":black_heart:": { + "category": "Smileys & Emotion", + "name": "black heart", + "unicode": "1f5a4" + }, + ":black_joker:": { + "category": "Activities", + "name": "joker", + "unicode": "1f0cf" + }, + ":black_large_square:": { + "category": "Symbols", + "name": "black large square", + "unicode": "2b1b" + }, + ":black_medium_small_square:": { + "category": "Symbols", + "name": "black medium-small square", + "unicode": "25fe" + }, + ":black_medium_square:": { + "category": "Symbols", + "name": "black medium square", + "unicode": "25fc", + "unicode_alt": "25fc-fe0f" + }, + ":black_nib:": { + "category": "Objects", + "name": "black nib", + "unicode": "2712", + "unicode_alt": "2712-fe0f" + }, + ":black_small_square:": { + "category": "Symbols", + "name": "black small square", + "unicode": "25aa", + "unicode_alt": "25aa-fe0f" + }, + ":black_square_button:": { + "category": "Symbols", + "name": "black square button", + "unicode": "1f532" + }, + ":blond_haired_man:": { + "category": "People & Body", + "name": "man: blond hair", + "unicode": "1f471-2642", + "unicode_alt": "1f471-200d-2642-fe0f" + }, + ":blond_haired_person:": { + "category": "People & Body", + "name": "person: blond hair", + "unicode": "1f471" + }, + ":blond_haired_woman:": { + "category": "People & Body", + "name": "woman: blond hair", + "unicode": "1f471-2640", + "unicode_alt": "1f471-200d-2640-fe0f" + }, + ":blossom:": { + "category": "Animals & Nature", + "name": "blossom", + "unicode": "1f33c" + }, + ":blowfish:": { + "category": "Animals & Nature", + "name": "blowfish", + "unicode": "1f421" + }, + ":blue_book:": { + "category": "Objects", + "name": "blue book", + "unicode": "1f4d8" + }, + ":blue_car:": { + "category": "Travel & Places", + "name": "sport utility vehicle", + "unicode": "1f699" + }, + ":blue_heart:": { + "category": "Smileys & Emotion", + "name": "blue heart", + "unicode": "1f499" + }, + ":blue_square:": { + "category": "Symbols", + "name": "blue square", + "unicode": "1f7e6" + }, + ":blueberries:": { + "category": "Food & Drink", + "name": "blueberries", + "unicode": "1fad0" + }, + ":blush:": { + "category": "Smileys & Emotion", + "name": "smiling face with smiling eyes", + "unicode": "1f60a" + }, + ":boar:": { + "category": "Animals & Nature", + "name": "boar", + "unicode": "1f417" + }, + ":boat:": { + "category": "Travel & Places", + "name": "sailboat", + "unicode": "26f5" + }, + ":bolivia:": { + "category": "Flags", + "name": "flag: Bolivia", + "unicode": "1f1e7-1f1f4" + }, + ":bomb:": { + "category": "Objects", + "name": "bomb", + "unicode": "1f4a3" + }, + ":bone:": { + "category": "People & Body", + "name": "bone", + "unicode": "1f9b4" + }, + ":book:": { + "category": "Objects", + "name": "open book", + "unicode": "1f4d6" + }, + ":bookmark:": { + "category": "Objects", + "name": "bookmark", + "unicode": "1f516" + }, + ":bookmark_tabs:": { + "category": "Objects", + "name": "bookmark tabs", + "unicode": "1f4d1" + }, + ":books:": { + "category": "Objects", + "name": "books", + "unicode": "1f4da" + }, + ":boom:": { + "category": "Smileys & Emotion", + "name": "collision", + "unicode": "1f4a5" + }, + ":boomerang:": { + "category": "Objects", + "name": "boomerang", + "unicode": "1fa83" + }, + ":boot:": { + "category": "Objects", + "name": "woman\u2019s boot", + "unicode": "1f462" + }, + ":bosnia_herzegovina:": { + "category": "Flags", + "name": "flag: Bosnia & Herzegovina", + "unicode": "1f1e7-1f1e6" + }, + ":botswana:": { + "category": "Flags", + "name": "flag: Botswana", + "unicode": "1f1e7-1f1fc" + }, + ":bouncing_ball_man:": { + "category": "People & Body", + "name": "man bouncing ball", + "unicode": "26f9-2642", + "unicode_alt": "26f9-fe0f-200d-2642-fe0f" + }, + ":bouncing_ball_person:": { + "category": "People & Body", + "name": "person bouncing ball", + "unicode": "26f9", + "unicode_alt": "26f9-fe0f" + }, + ":bouncing_ball_woman:": { + "category": "People & Body", + "name": "woman bouncing ball", + "unicode": "26f9-2640", + "unicode_alt": "26f9-fe0f-200d-2640-fe0f" + }, + ":bouquet:": { + "category": "Animals & Nature", + "name": "bouquet", + "unicode": "1f490" + }, + ":bouvet_island:": { + "category": "Flags", + "name": "flag: Bouvet Island", + "unicode": "1f1e7-1f1fb" + }, + ":bow:": { + "category": "People & Body", + "name": "person bowing", + "unicode": "1f647" + }, + ":bow_and_arrow:": { + "category": "Objects", + "name": "bow and arrow", + "unicode": "1f3f9" + }, + ":bowing_man:": { + "category": "People & Body", + "name": "man bowing", + "unicode": "1f647-2642", + "unicode_alt": "1f647-200d-2642-fe0f" + }, + ":bowing_woman:": { + "category": "People & Body", + "name": "woman bowing", + "unicode": "1f647-2640", + "unicode_alt": "1f647-200d-2640-fe0f" + }, + ":bowl_with_spoon:": { + "category": "Food & Drink", + "name": "bowl with spoon", + "unicode": "1f963" + }, + ":bowling:": { + "category": "Activities", + "name": "bowling", + "unicode": "1f3b3" + }, + ":boxing_glove:": { + "category": "Activities", + "name": "boxing glove", + "unicode": "1f94a" + }, + ":boy:": { + "category": "People & Body", + "name": "boy", + "unicode": "1f466" + }, + ":brain:": { + "category": "People & Body", + "name": "brain", + "unicode": "1f9e0" + }, + ":brazil:": { + "category": "Flags", + "name": "flag: Brazil", + "unicode": "1f1e7-1f1f7" + }, + ":bread:": { + "category": "Food & Drink", + "name": "bread", + "unicode": "1f35e" + }, + ":breast_feeding:": { + "category": "People & Body", + "name": "breast-feeding", + "unicode": "1f931" + }, + ":bricks:": { + "category": "Travel & Places", + "name": "brick", + "unicode": "1f9f1" + }, + ":bridge_at_night:": { + "category": "Travel & Places", + "name": "bridge at night", + "unicode": "1f309" + }, + ":briefcase:": { + "category": "Objects", + "name": "briefcase", + "unicode": "1f4bc" + }, + ":british_indian_ocean_territory:": { + "category": "Flags", + "name": "flag: British Indian Ocean Territory", + "unicode": "1f1ee-1f1f4" + }, + ":british_virgin_islands:": { + "category": "Flags", + "name": "flag: British Virgin Islands", + "unicode": "1f1fb-1f1ec" + }, + ":broccoli:": { + "category": "Food & Drink", + "name": "broccoli", + "unicode": "1f966" + }, + ":broken_heart:": { + "category": "Smileys & Emotion", + "name": "broken heart", + "unicode": "1f494" + }, + ":broom:": { + "category": "Objects", + "name": "broom", + "unicode": "1f9f9" + }, + ":brown_circle:": { + "category": "Symbols", + "name": "brown circle", + "unicode": "1f7e4" + }, + ":brown_heart:": { + "category": "Smileys & Emotion", + "name": "brown heart", + "unicode": "1f90e" + }, + ":brown_square:": { + "category": "Symbols", + "name": "brown square", + "unicode": "1f7eb" + }, + ":brunei:": { + "category": "Flags", + "name": "flag: Brunei", + "unicode": "1f1e7-1f1f3" + }, + ":bubble_tea:": { + "category": "Food & Drink", + "name": "bubble tea", + "unicode": "1f9cb" + }, + ":bubbles:": { + "category": "Objects", + "name": "bubbles", + "unicode": "1fae7" + }, + ":bucket:": { + "category": "Objects", + "name": "bucket", + "unicode": "1faa3" + }, + ":bug:": { + "category": "Animals & Nature", + "name": "bug", + "unicode": "1f41b" + }, + ":building_construction:": { + "category": "Travel & Places", + "name": "building construction", + "unicode": "1f3d7", + "unicode_alt": "1f3d7-fe0f" + }, + ":bulb:": { + "category": "Objects", + "name": "light bulb", + "unicode": "1f4a1" + }, + ":bulgaria:": { + "category": "Flags", + "name": "flag: Bulgaria", + "unicode": "1f1e7-1f1ec" + }, + ":bullettrain_front:": { + "category": "Travel & Places", + "name": "bullet train", + "unicode": "1f685" + }, + ":bullettrain_side:": { + "category": "Travel & Places", + "name": "high-speed train", + "unicode": "1f684" + }, + ":burkina_faso:": { + "category": "Flags", + "name": "flag: Burkina Faso", + "unicode": "1f1e7-1f1eb" + }, + ":burrito:": { + "category": "Food & Drink", + "name": "burrito", + "unicode": "1f32f" + }, + ":burundi:": { + "category": "Flags", + "name": "flag: Burundi", + "unicode": "1f1e7-1f1ee" + }, + ":bus:": { + "category": "Travel & Places", + "name": "bus", + "unicode": "1f68c" + }, + ":business_suit_levitating:": { + "category": "People & Body", + "name": "person in suit levitating", + "unicode": "1f574", + "unicode_alt": "1f574-fe0f" + }, + ":busstop:": { + "category": "Travel & Places", + "name": "bus stop", + "unicode": "1f68f" + }, + ":bust_in_silhouette:": { + "category": "People & Body", + "name": "bust in silhouette", + "unicode": "1f464" + }, + ":busts_in_silhouette:": { + "category": "People & Body", + "name": "busts in silhouette", + "unicode": "1f465" + }, + ":butter:": { + "category": "Food & Drink", + "name": "butter", + "unicode": "1f9c8" + }, + ":butterfly:": { + "category": "Animals & Nature", + "name": "butterfly", + "unicode": "1f98b" + }, + ":cactus:": { + "category": "Animals & Nature", + "name": "cactus", + "unicode": "1f335" + }, + ":cake:": { + "category": "Food & Drink", + "name": "shortcake", + "unicode": "1f370" + }, + ":calendar:": { + "category": "Objects", + "name": "tear-off calendar", + "unicode": "1f4c6" + }, + ":call_me_hand:": { + "category": "People & Body", + "name": "call me hand", + "unicode": "1f919" + }, + ":calling:": { + "category": "Objects", + "name": "mobile phone with arrow", + "unicode": "1f4f2" + }, + ":cambodia:": { + "category": "Flags", + "name": "flag: Cambodia", + "unicode": "1f1f0-1f1ed" + }, + ":camel:": { + "category": "Animals & Nature", + "name": "two-hump camel", + "unicode": "1f42b" + }, + ":camera:": { + "category": "Objects", + "name": "camera", + "unicode": "1f4f7" + }, + ":camera_flash:": { + "category": "Objects", + "name": "camera with flash", + "unicode": "1f4f8" + }, + ":cameroon:": { + "category": "Flags", + "name": "flag: Cameroon", + "unicode": "1f1e8-1f1f2" + }, + ":camping:": { + "category": "Travel & Places", + "name": "camping", + "unicode": "1f3d5", + "unicode_alt": "1f3d5-fe0f" + }, + ":canada:": { + "category": "Flags", + "name": "flag: Canada", + "unicode": "1f1e8-1f1e6" + }, + ":canary_islands:": { + "category": "Flags", + "name": "flag: Canary Islands", + "unicode": "1f1ee-1f1e8" + }, + ":cancer:": { + "category": "Symbols", + "name": "Cancer", + "unicode": "264b" + }, + ":candle:": { + "category": "Objects", + "name": "candle", + "unicode": "1f56f", + "unicode_alt": "1f56f-fe0f" + }, + ":candy:": { + "category": "Food & Drink", + "name": "candy", + "unicode": "1f36c" + }, + ":canned_food:": { + "category": "Food & Drink", + "name": "canned food", + "unicode": "1f96b" + }, + ":canoe:": { + "category": "Travel & Places", + "name": "canoe", + "unicode": "1f6f6" + }, + ":cape_verde:": { + "category": "Flags", + "name": "flag: Cape Verde", + "unicode": "1f1e8-1f1fb" + }, + ":capital_abcd:": { + "category": "Symbols", + "name": "input latin uppercase", + "unicode": "1f520" + }, + ":capricorn:": { + "category": "Symbols", + "name": "Capricorn", + "unicode": "2651" + }, + ":car:": { + "category": "Travel & Places", + "name": "automobile", + "unicode": "1f697" + }, + ":card_file_box:": { + "category": "Objects", + "name": "card file box", + "unicode": "1f5c3", + "unicode_alt": "1f5c3-fe0f" + }, + ":card_index:": { + "category": "Objects", + "name": "card index", + "unicode": "1f4c7" + }, + ":card_index_dividers:": { + "category": "Objects", + "name": "card index dividers", + "unicode": "1f5c2", + "unicode_alt": "1f5c2-fe0f" + }, + ":caribbean_netherlands:": { + "category": "Flags", + "name": "flag: Caribbean Netherlands", + "unicode": "1f1e7-1f1f6" + }, + ":carousel_horse:": { + "category": "Travel & Places", + "name": "carousel horse", + "unicode": "1f3a0" + }, + ":carpentry_saw:": { + "category": "Objects", + "name": "carpentry saw", + "unicode": "1fa9a" + }, + ":carrot:": { + "category": "Food & Drink", + "name": "carrot", + "unicode": "1f955" + }, + ":cartwheeling:": { + "category": "People & Body", + "name": "person cartwheeling", + "unicode": "1f938" + }, + ":cat2:": { + "category": "Animals & Nature", + "name": "cat", + "unicode": "1f408" + }, + ":cat:": { + "category": "Animals & Nature", + "name": "cat face", + "unicode": "1f431" + }, + ":cayman_islands:": { + "category": "Flags", + "name": "flag: Cayman Islands", + "unicode": "1f1f0-1f1fe" + }, + ":cd:": { + "category": "Objects", + "name": "optical disk", + "unicode": "1f4bf" + }, + ":central_african_republic:": { + "category": "Flags", + "name": "flag: Central African Republic", + "unicode": "1f1e8-1f1eb" + }, + ":ceuta_melilla:": { + "category": "Flags", + "name": "flag: Ceuta & Melilla", + "unicode": "1f1ea-1f1e6" + }, + ":chad:": { + "category": "Flags", + "name": "flag: Chad", + "unicode": "1f1f9-1f1e9" + }, + ":chains:": { + "category": "Objects", + "name": "chains", + "unicode": "26d3", + "unicode_alt": "26d3-fe0f" + }, + ":chair:": { + "category": "Objects", + "name": "chair", + "unicode": "1fa91" + }, + ":champagne:": { + "category": "Food & Drink", + "name": "bottle with popping cork", + "unicode": "1f37e" + }, + ":chart:": { + "category": "Objects", + "name": "chart increasing with yen", + "unicode": "1f4b9" + }, + ":chart_with_downwards_trend:": { + "category": "Objects", + "name": "chart decreasing", + "unicode": "1f4c9" + }, + ":chart_with_upwards_trend:": { + "category": "Objects", + "name": "chart increasing", + "unicode": "1f4c8" + }, + ":checkered_flag:": { + "category": "Flags", + "name": "chequered flag", + "unicode": "1f3c1" + }, + ":cheese:": { + "category": "Food & Drink", + "name": "cheese wedge", + "unicode": "1f9c0" + }, + ":cherries:": { + "category": "Food & Drink", + "name": "cherries", + "unicode": "1f352" + }, + ":cherry_blossom:": { + "category": "Animals & Nature", + "name": "cherry blossom", + "unicode": "1f338" + }, + ":chess_pawn:": { + "category": "Activities", + "name": "chess pawn", + "unicode": "265f", + "unicode_alt": "265f-fe0f" + }, + ":chestnut:": { + "category": "Food & Drink", + "name": "chestnut", + "unicode": "1f330" + }, + ":chicken:": { + "category": "Animals & Nature", + "name": "chicken", + "unicode": "1f414" + }, + ":child:": { + "category": "People & Body", + "name": "child", + "unicode": "1f9d2" + }, + ":children_crossing:": { + "category": "Symbols", + "name": "children crossing", + "unicode": "1f6b8" + }, + ":chile:": { + "category": "Flags", + "name": "flag: Chile", + "unicode": "1f1e8-1f1f1" + }, + ":chipmunk:": { + "category": "Animals & Nature", + "name": "chipmunk", + "unicode": "1f43f", + "unicode_alt": "1f43f-fe0f" + }, + ":chocolate_bar:": { + "category": "Food & Drink", + "name": "chocolate bar", + "unicode": "1f36b" + }, + ":chopsticks:": { + "category": "Food & Drink", + "name": "chopsticks", + "unicode": "1f962" + }, + ":christmas_island:": { + "category": "Flags", + "name": "flag: Christmas Island", + "unicode": "1f1e8-1f1fd" + }, + ":christmas_tree:": { + "category": "Activities", + "name": "Christmas tree", + "unicode": "1f384" + }, + ":church:": { + "category": "Travel & Places", + "name": "church", + "unicode": "26ea" + }, + ":cinema:": { + "category": "Symbols", + "name": "cinema", + "unicode": "1f3a6" + }, + ":circus_tent:": { + "category": "Travel & Places", + "name": "circus tent", + "unicode": "1f3aa" + }, + ":city_sunrise:": { + "category": "Travel & Places", + "name": "sunset", + "unicode": "1f307" + }, + ":city_sunset:": { + "category": "Travel & Places", + "name": "cityscape at dusk", + "unicode": "1f306" + }, + ":cityscape:": { + "category": "Travel & Places", + "name": "cityscape", + "unicode": "1f3d9", + "unicode_alt": "1f3d9-fe0f" + }, + ":cl:": { + "category": "Symbols", + "name": "CL button", + "unicode": "1f191" + }, + ":clamp:": { + "category": "Objects", + "name": "clamp", + "unicode": "1f5dc", + "unicode_alt": "1f5dc-fe0f" + }, + ":clap:": { + "category": "People & Body", + "name": "clapping hands", + "unicode": "1f44f" + }, + ":clapper:": { + "category": "Objects", + "name": "clapper board", + "unicode": "1f3ac" + }, + ":classical_building:": { + "category": "Travel & Places", + "name": "classical building", + "unicode": "1f3db", + "unicode_alt": "1f3db-fe0f" + }, + ":climbing:": { + "category": "People & Body", + "name": "person climbing", + "unicode": "1f9d7" + }, + ":climbing_man:": { + "category": "People & Body", + "name": "man climbing", + "unicode": "1f9d7-2642", + "unicode_alt": "1f9d7-200d-2642-fe0f" + }, + ":climbing_woman:": { + "category": "People & Body", + "name": "woman climbing", + "unicode": "1f9d7-2640", + "unicode_alt": "1f9d7-200d-2640-fe0f" + }, + ":clinking_glasses:": { + "category": "Food & Drink", + "name": "clinking glasses", + "unicode": "1f942" + }, + ":clipboard:": { + "category": "Objects", + "name": "clipboard", + "unicode": "1f4cb" + }, + ":clipperton_island:": { + "category": "Flags", + "name": "flag: Clipperton Island", + "unicode": "1f1e8-1f1f5" + }, + ":clock1030:": { + "category": "Travel & Places", + "name": "ten-thirty", + "unicode": "1f565" + }, + ":clock10:": { + "category": "Travel & Places", + "name": "ten o\u2019clock", + "unicode": "1f559" + }, + ":clock1130:": { + "category": "Travel & Places", + "name": "eleven-thirty", + "unicode": "1f566" + }, + ":clock11:": { + "category": "Travel & Places", + "name": "eleven o\u2019clock", + "unicode": "1f55a" + }, + ":clock1230:": { + "category": "Travel & Places", + "name": "twelve-thirty", + "unicode": "1f567" + }, + ":clock12:": { + "category": "Travel & Places", + "name": "twelve o\u2019clock", + "unicode": "1f55b" + }, + ":clock130:": { + "category": "Travel & Places", + "name": "one-thirty", + "unicode": "1f55c" + }, + ":clock1:": { + "category": "Travel & Places", + "name": "one o\u2019clock", + "unicode": "1f550" + }, + ":clock230:": { + "category": "Travel & Places", + "name": "two-thirty", + "unicode": "1f55d" + }, + ":clock2:": { + "category": "Travel & Places", + "name": "two o\u2019clock", + "unicode": "1f551" + }, + ":clock330:": { + "category": "Travel & Places", + "name": "three-thirty", + "unicode": "1f55e" + }, + ":clock3:": { + "category": "Travel & Places", + "name": "three o\u2019clock", + "unicode": "1f552" + }, + ":clock430:": { + "category": "Travel & Places", + "name": "four-thirty", + "unicode": "1f55f" + }, + ":clock4:": { + "category": "Travel & Places", + "name": "four o\u2019clock", + "unicode": "1f553" + }, + ":clock530:": { + "category": "Travel & Places", + "name": "five-thirty", + "unicode": "1f560" + }, + ":clock5:": { + "category": "Travel & Places", + "name": "five o\u2019clock", + "unicode": "1f554" + }, + ":clock630:": { + "category": "Travel & Places", + "name": "six-thirty", + "unicode": "1f561" + }, + ":clock6:": { + "category": "Travel & Places", + "name": "six o\u2019clock", + "unicode": "1f555" + }, + ":clock730:": { + "category": "Travel & Places", + "name": "seven-thirty", + "unicode": "1f562" + }, + ":clock7:": { + "category": "Travel & Places", + "name": "seven o\u2019clock", + "unicode": "1f556" + }, + ":clock830:": { + "category": "Travel & Places", + "name": "eight-thirty", + "unicode": "1f563" + }, + ":clock8:": { + "category": "Travel & Places", + "name": "eight o\u2019clock", + "unicode": "1f557" + }, + ":clock930:": { + "category": "Travel & Places", + "name": "nine-thirty", + "unicode": "1f564" + }, + ":clock9:": { + "category": "Travel & Places", + "name": "nine o\u2019clock", + "unicode": "1f558" + }, + ":closed_book:": { + "category": "Objects", + "name": "closed book", + "unicode": "1f4d5" + }, + ":closed_lock_with_key:": { + "category": "Objects", + "name": "locked with key", + "unicode": "1f510" + }, + ":closed_umbrella:": { + "category": "Travel & Places", + "name": "closed umbrella", + "unicode": "1f302" + }, + ":cloud:": { + "category": "Travel & Places", + "name": "cloud", + "unicode": "2601", + "unicode_alt": "2601-fe0f" + }, + ":cloud_with_lightning:": { + "category": "Travel & Places", + "name": "cloud with lightning", + "unicode": "1f329", + "unicode_alt": "1f329-fe0f" + }, + ":cloud_with_lightning_and_rain:": { + "category": "Travel & Places", + "name": "cloud with lightning and rain", + "unicode": "26c8", + "unicode_alt": "26c8-fe0f" + }, + ":cloud_with_rain:": { + "category": "Travel & Places", + "name": "cloud with rain", + "unicode": "1f327", + "unicode_alt": "1f327-fe0f" + }, + ":cloud_with_snow:": { + "category": "Travel & Places", + "name": "cloud with snow", + "unicode": "1f328", + "unicode_alt": "1f328-fe0f" + }, + ":clown_face:": { + "category": "Smileys & Emotion", + "name": "clown face", + "unicode": "1f921" + }, + ":clubs:": { + "category": "Activities", + "name": "club suit", + "unicode": "2663", + "unicode_alt": "2663-fe0f" + }, + ":cn:": { + "category": "Flags", + "name": "flag: China", + "unicode": "1f1e8-1f1f3" + }, + ":coat:": { + "category": "Objects", + "name": "coat", + "unicode": "1f9e5" + }, + ":cockroach:": { + "category": "Animals & Nature", + "name": "cockroach", + "unicode": "1fab3" + }, + ":cocktail:": { + "category": "Food & Drink", + "name": "cocktail glass", + "unicode": "1f378" + }, + ":coconut:": { + "category": "Food & Drink", + "name": "coconut", + "unicode": "1f965" + }, + ":cocos_islands:": { + "category": "Flags", + "name": "flag: Cocos (Keeling) Islands", + "unicode": "1f1e8-1f1e8" + }, + ":coffee:": { + "category": "Food & Drink", + "name": "hot beverage", + "unicode": "2615" + }, + ":coffin:": { + "category": "Objects", + "name": "coffin", + "unicode": "26b0", + "unicode_alt": "26b0-fe0f" + }, + ":coin:": { + "category": "Objects", + "name": "coin", + "unicode": "1fa99" + }, + ":cold_face:": { + "category": "Smileys & Emotion", + "name": "cold face", + "unicode": "1f976" + }, + ":cold_sweat:": { + "category": "Smileys & Emotion", + "name": "anxious face with sweat", + "unicode": "1f630" + }, + ":colombia:": { + "category": "Flags", + "name": "flag: Colombia", + "unicode": "1f1e8-1f1f4" + }, + ":comet:": { + "category": "Travel & Places", + "name": "comet", + "unicode": "2604", + "unicode_alt": "2604-fe0f" + }, + ":comoros:": { + "category": "Flags", + "name": "flag: Comoros", + "unicode": "1f1f0-1f1f2" + }, + ":compass:": { + "category": "Travel & Places", + "name": "compass", + "unicode": "1f9ed" + }, + ":computer:": { + "category": "Objects", + "name": "laptop", + "unicode": "1f4bb" + }, + ":computer_mouse:": { + "category": "Objects", + "name": "computer mouse", + "unicode": "1f5b1", + "unicode_alt": "1f5b1-fe0f" + }, + ":confetti_ball:": { + "category": "Activities", + "name": "confetti ball", + "unicode": "1f38a" + }, + ":confounded:": { + "category": "Smileys & Emotion", + "name": "confounded face", + "unicode": "1f616" + }, + ":confused:": { + "category": "Smileys & Emotion", + "name": "confused face", + "unicode": "1f615" + }, + ":congo_brazzaville:": { + "category": "Flags", + "name": "flag: Congo - Brazzaville", + "unicode": "1f1e8-1f1ec" + }, + ":congo_kinshasa:": { + "category": "Flags", + "name": "flag: Congo - Kinshasa", + "unicode": "1f1e8-1f1e9" + }, + ":congratulations:": { + "category": "Symbols", + "name": "Japanese \u201ccongratulations\u201d button", + "unicode": "3297", + "unicode_alt": "3297-fe0f" + }, + ":construction:": { + "category": "Travel & Places", + "name": "construction", + "unicode": "1f6a7" + }, + ":construction_worker:": { + "category": "People & Body", + "name": "construction worker", + "unicode": "1f477" + }, + ":construction_worker_man:": { + "category": "People & Body", + "name": "man construction worker", + "unicode": "1f477-2642", + "unicode_alt": "1f477-200d-2642-fe0f" + }, + ":construction_worker_woman:": { + "category": "People & Body", + "name": "woman construction worker", + "unicode": "1f477-2640", + "unicode_alt": "1f477-200d-2640-fe0f" + }, + ":control_knobs:": { + "category": "Objects", + "name": "control knobs", + "unicode": "1f39b", + "unicode_alt": "1f39b-fe0f" + }, + ":convenience_store:": { + "category": "Travel & Places", + "name": "convenience store", + "unicode": "1f3ea" + }, + ":cook:": { + "category": "People & Body", + "name": "cook", + "unicode": "1f9d1-1f373", + "unicode_alt": "1f9d1-200d-1f373" + }, + ":cook_islands:": { + "category": "Flags", + "name": "flag: Cook Islands", + "unicode": "1f1e8-1f1f0" + }, + ":cookie:": { + "category": "Food & Drink", + "name": "cookie", + "unicode": "1f36a" + }, + ":cool:": { + "category": "Symbols", + "name": "COOL button", + "unicode": "1f192" + }, + ":copyright:": { + "category": "Symbols", + "name": "copyright", + "unicode": "00a9", + "unicode_alt": "00a9-fe0f" + }, + ":coral:": { + "category": "Animals & Nature", + "name": "coral", + "unicode": "1fab8" + }, + ":corn:": { + "category": "Food & Drink", + "name": "ear of corn", + "unicode": "1f33d" + }, + ":costa_rica:": { + "category": "Flags", + "name": "flag: Costa Rica", + "unicode": "1f1e8-1f1f7" + }, + ":cote_divoire:": { + "category": "Flags", + "name": "flag: C\u00f4te d\u2019Ivoire", + "unicode": "1f1e8-1f1ee" + }, + ":couch_and_lamp:": { + "category": "Objects", + "name": "couch and lamp", + "unicode": "1f6cb", + "unicode_alt": "1f6cb-fe0f" + }, + ":couple:": { + "category": "People & Body", + "name": "woman and man holding hands", + "unicode": "1f46b" + }, + ":couple_with_heart:": { + "category": "People & Body", + "name": "couple with heart", + "unicode": "1f491" + }, + ":couple_with_heart_man_man:": { + "category": "People & Body", + "name": "couple with heart: man, man", + "unicode": "1f468-2764-1f468", + "unicode_alt": "1f468-200d-2764-fe0f-200d-1f468" + }, + ":couple_with_heart_woman_man:": { + "category": "People & Body", + "name": "couple with heart: woman, man", + "unicode": "1f469-2764-1f468", + "unicode_alt": "1f469-200d-2764-fe0f-200d-1f468" + }, + ":couple_with_heart_woman_woman:": { + "category": "People & Body", + "name": "couple with heart: woman, woman", + "unicode": "1f469-2764-1f469", + "unicode_alt": "1f469-200d-2764-fe0f-200d-1f469" + }, + ":couplekiss:": { + "category": "People & Body", + "name": "kiss", + "unicode": "1f48f" + }, + ":couplekiss_man_man:": { + "category": "People & Body", + "name": "kiss: man, man", + "unicode": "1f468-2764-1f48b-1f468", + "unicode_alt": "1f468-200d-2764-fe0f-200d-1f48b-200d-1f468" + }, + ":couplekiss_man_woman:": { + "category": "People & Body", + "name": "kiss: woman, man", + "unicode": "1f469-2764-1f48b-1f468", + "unicode_alt": "1f469-200d-2764-fe0f-200d-1f48b-200d-1f468" + }, + ":couplekiss_woman_woman:": { + "category": "People & Body", + "name": "kiss: woman, woman", + "unicode": "1f469-2764-1f48b-1f469", + "unicode_alt": "1f469-200d-2764-fe0f-200d-1f48b-200d-1f469" + }, + ":cow2:": { + "category": "Animals & Nature", + "name": "cow", + "unicode": "1f404" + }, + ":cow:": { + "category": "Animals & Nature", + "name": "cow face", + "unicode": "1f42e" + }, + ":cowboy_hat_face:": { + "category": "Smileys & Emotion", + "name": "cowboy hat face", + "unicode": "1f920" + }, + ":crab:": { + "category": "Food & Drink", + "name": "crab", + "unicode": "1f980" + }, + ":crayon:": { + "category": "Objects", + "name": "crayon", + "unicode": "1f58d", + "unicode_alt": "1f58d-fe0f" + }, + ":credit_card:": { + "category": "Objects", + "name": "credit card", + "unicode": "1f4b3" + }, + ":crescent_moon:": { + "category": "Travel & Places", + "name": "crescent moon", + "unicode": "1f319" + }, + ":cricket:": { + "category": "Animals & Nature", + "name": "cricket", + "unicode": "1f997" + }, + ":cricket_game:": { + "category": "Activities", + "name": "cricket game", + "unicode": "1f3cf" + }, + ":croatia:": { + "category": "Flags", + "name": "flag: Croatia", + "unicode": "1f1ed-1f1f7" + }, + ":crocodile:": { + "category": "Animals & Nature", + "name": "crocodile", + "unicode": "1f40a" + }, + ":croissant:": { + "category": "Food & Drink", + "name": "croissant", + "unicode": "1f950" + }, + ":crossed_fingers:": { + "category": "People & Body", + "name": "crossed fingers", + "unicode": "1f91e" + }, + ":crossed_flags:": { + "category": "Flags", + "name": "crossed flags", + "unicode": "1f38c" + }, + ":crossed_swords:": { + "category": "Objects", + "name": "crossed swords", + "unicode": "2694", + "unicode_alt": "2694-fe0f" + }, + ":crown:": { + "category": "Objects", + "name": "crown", + "unicode": "1f451" + }, + ":crutch:": { + "category": "Objects", + "name": "crutch", + "unicode": "1fa7c" + }, + ":cry:": { + "category": "Smileys & Emotion", + "name": "crying face", + "unicode": "1f622" + }, + ":crying_cat_face:": { + "category": "Smileys & Emotion", + "name": "crying cat", + "unicode": "1f63f" + }, + ":crystal_ball:": { + "category": "Activities", + "name": "crystal ball", + "unicode": "1f52e" + }, + ":cuba:": { + "category": "Flags", + "name": "flag: Cuba", + "unicode": "1f1e8-1f1fa" + }, + ":cucumber:": { + "category": "Food & Drink", + "name": "cucumber", + "unicode": "1f952" + }, + ":cup_with_straw:": { + "category": "Food & Drink", + "name": "cup with straw", + "unicode": "1f964" + }, + ":cupcake:": { + "category": "Food & Drink", + "name": "cupcake", + "unicode": "1f9c1" + }, + ":cupid:": { + "category": "Smileys & Emotion", + "name": "heart with arrow", + "unicode": "1f498" + }, + ":curacao:": { + "category": "Flags", + "name": "flag: Cura\u00e7ao", + "unicode": "1f1e8-1f1fc" + }, + ":curling_stone:": { + "category": "Activities", + "name": "curling stone", + "unicode": "1f94c" + }, + ":curly_haired_man:": { + "category": "People & Body", + "name": "man: curly hair", + "unicode": "1f468-1f9b1", + "unicode_alt": "1f468-200d-1f9b1" + }, + ":curly_haired_woman:": { + "category": "People & Body", + "name": "woman: curly hair", + "unicode": "1f469-1f9b1", + "unicode_alt": "1f469-200d-1f9b1" + }, + ":curly_loop:": { + "category": "Symbols", + "name": "curly loop", + "unicode": "27b0" + }, + ":currency_exchange:": { + "category": "Symbols", + "name": "currency exchange", + "unicode": "1f4b1" + }, + ":curry:": { + "category": "Food & Drink", + "name": "curry rice", + "unicode": "1f35b" + }, + ":cursing_face:": { + "category": "Smileys & Emotion", + "name": "face with symbols on mouth", + "unicode": "1f92c" + }, + ":custard:": { + "category": "Food & Drink", + "name": "custard", + "unicode": "1f36e" + }, + ":customs:": { + "category": "Symbols", + "name": "customs", + "unicode": "1f6c3" + }, + ":cut_of_meat:": { + "category": "Food & Drink", + "name": "cut of meat", + "unicode": "1f969" + }, + ":cyclone:": { + "category": "Travel & Places", + "name": "cyclone", + "unicode": "1f300" + }, + ":cyprus:": { + "category": "Flags", + "name": "flag: Cyprus", + "unicode": "1f1e8-1f1fe" + }, + ":czech_republic:": { + "category": "Flags", + "name": "flag: Czechia", + "unicode": "1f1e8-1f1ff" + }, + ":dagger:": { + "category": "Objects", + "name": "dagger", + "unicode": "1f5e1", + "unicode_alt": "1f5e1-fe0f" + }, + ":dancers:": { + "category": "People & Body", + "name": "people with bunny ears", + "unicode": "1f46f" + }, + ":dancing_men:": { + "category": "People & Body", + "name": "men with bunny ears", + "unicode": "1f46f-2642", + "unicode_alt": "1f46f-200d-2642-fe0f" + }, + ":dancing_women:": { + "category": "People & Body", + "name": "women with bunny ears", + "unicode": "1f46f-2640", + "unicode_alt": "1f46f-200d-2640-fe0f" + }, + ":dango:": { + "category": "Food & Drink", + "name": "dango", + "unicode": "1f361" + }, + ":dark_sunglasses:": { + "category": "Objects", + "name": "sunglasses", + "unicode": "1f576", + "unicode_alt": "1f576-fe0f" + }, + ":dart:": { + "category": "Activities", + "name": "bullseye", + "unicode": "1f3af" + }, + ":dash:": { + "category": "Smileys & Emotion", + "name": "dashing away", + "unicode": "1f4a8" + }, + ":date:": { + "category": "Objects", + "name": "calendar", + "unicode": "1f4c5" + }, + ":de:": { + "category": "Flags", + "name": "flag: Germany", + "unicode": "1f1e9-1f1ea" + }, + ":deaf_man:": { + "category": "People & Body", + "name": "deaf man", + "unicode": "1f9cf-2642", + "unicode_alt": "1f9cf-200d-2642-fe0f" + }, + ":deaf_person:": { + "category": "People & Body", + "name": "deaf person", + "unicode": "1f9cf" + }, + ":deaf_woman:": { + "category": "People & Body", + "name": "deaf woman", + "unicode": "1f9cf-2640", + "unicode_alt": "1f9cf-200d-2640-fe0f" + }, + ":deciduous_tree:": { + "category": "Animals & Nature", + "name": "deciduous tree", + "unicode": "1f333" + }, + ":deer:": { + "category": "Animals & Nature", + "name": "deer", + "unicode": "1f98c" + }, + ":denmark:": { + "category": "Flags", + "name": "flag: Denmark", + "unicode": "1f1e9-1f1f0" + }, + ":department_store:": { + "category": "Travel & Places", + "name": "department store", + "unicode": "1f3ec" + }, + ":derelict_house:": { + "category": "Travel & Places", + "name": "derelict house", + "unicode": "1f3da", + "unicode_alt": "1f3da-fe0f" + }, + ":desert:": { + "category": "Travel & Places", + "name": "desert", + "unicode": "1f3dc", + "unicode_alt": "1f3dc-fe0f" + }, + ":desert_island:": { + "category": "Travel & Places", + "name": "desert island", + "unicode": "1f3dd", + "unicode_alt": "1f3dd-fe0f" + }, + ":desktop_computer:": { + "category": "Objects", + "name": "desktop computer", + "unicode": "1f5a5", + "unicode_alt": "1f5a5-fe0f" + }, + ":detective:": { + "category": "People & Body", + "name": "detective", + "unicode": "1f575", + "unicode_alt": "1f575-fe0f" + }, + ":diamond_shape_with_a_dot_inside:": { + "category": "Symbols", + "name": "diamond with a dot", + "unicode": "1f4a0" + }, + ":diamonds:": { + "category": "Activities", + "name": "diamond suit", + "unicode": "2666", + "unicode_alt": "2666-fe0f" + }, + ":diego_garcia:": { + "category": "Flags", + "name": "flag: Diego Garcia", + "unicode": "1f1e9-1f1ec" + }, + ":disappointed:": { + "category": "Smileys & Emotion", + "name": "disappointed face", + "unicode": "1f61e" + }, + ":disappointed_relieved:": { + "category": "Smileys & Emotion", + "name": "sad but relieved face", + "unicode": "1f625" + }, + ":disguised_face:": { + "category": "Smileys & Emotion", + "name": "disguised face", + "unicode": "1f978" + }, + ":diving_mask:": { + "category": "Activities", + "name": "diving mask", + "unicode": "1f93f" + }, + ":diya_lamp:": { + "category": "Objects", + "name": "diya lamp", + "unicode": "1fa94" + }, + ":dizzy:": { + "category": "Smileys & Emotion", + "name": "dizzy", + "unicode": "1f4ab" + }, + ":dizzy_face:": { + "category": "Smileys & Emotion", + "name": "face with crossed-out eyes", + "unicode": "1f635" + }, + ":djibouti:": { + "category": "Flags", + "name": "flag: Djibouti", + "unicode": "1f1e9-1f1ef" + }, + ":dna:": { + "category": "Objects", + "name": "dna", + "unicode": "1f9ec" + }, + ":do_not_litter:": { + "category": "Symbols", + "name": "no littering", + "unicode": "1f6af" + }, + ":dodo:": { + "category": "Animals & Nature", + "name": "dodo", + "unicode": "1f9a4" + }, + ":dog2:": { + "category": "Animals & Nature", + "name": "dog", + "unicode": "1f415" + }, + ":dog:": { + "category": "Animals & Nature", + "name": "dog face", + "unicode": "1f436" + }, + ":dollar:": { + "category": "Objects", + "name": "dollar banknote", + "unicode": "1f4b5" + }, + ":dolls:": { + "category": "Activities", + "name": "Japanese dolls", + "unicode": "1f38e" + }, + ":dolphin:": { + "category": "Animals & Nature", + "name": "dolphin", + "unicode": "1f42c" + }, + ":dominica:": { + "category": "Flags", + "name": "flag: Dominica", + "unicode": "1f1e9-1f1f2" + }, + ":dominican_republic:": { + "category": "Flags", + "name": "flag: Dominican Republic", + "unicode": "1f1e9-1f1f4" + }, + ":donkey:": { + "category": "Animals & Nature", + "name": "donkey", + "unicode": "1facf" + }, + ":door:": { + "category": "Objects", + "name": "door", + "unicode": "1f6aa" + }, + ":dotted_line_face:": { + "category": "Smileys & Emotion", + "name": "dotted line face", + "unicode": "1fae5" + }, + ":doughnut:": { + "category": "Food & Drink", + "name": "doughnut", + "unicode": "1f369" + }, + ":dove:": { + "category": "Animals & Nature", + "name": "dove", + "unicode": "1f54a", + "unicode_alt": "1f54a-fe0f" + }, + ":dragon:": { + "category": "Animals & Nature", + "name": "dragon", + "unicode": "1f409" + }, + ":dragon_face:": { + "category": "Animals & Nature", + "name": "dragon face", + "unicode": "1f432" + }, + ":dress:": { + "category": "Objects", + "name": "dress", + "unicode": "1f457" + }, + ":dromedary_camel:": { + "category": "Animals & Nature", + "name": "camel", + "unicode": "1f42a" + }, + ":drooling_face:": { + "category": "Smileys & Emotion", + "name": "drooling face", + "unicode": "1f924" + }, + ":drop_of_blood:": { + "category": "Objects", + "name": "drop of blood", + "unicode": "1fa78" + }, + ":droplet:": { + "category": "Travel & Places", + "name": "droplet", + "unicode": "1f4a7" + }, + ":drum:": { + "category": "Objects", + "name": "drum", + "unicode": "1f941" + }, + ":duck:": { + "category": "Animals & Nature", + "name": "duck", + "unicode": "1f986" + }, + ":dumpling:": { + "category": "Food & Drink", + "name": "dumpling", + "unicode": "1f95f" + }, + ":dvd:": { + "category": "Objects", + "name": "dvd", + "unicode": "1f4c0" + }, + ":eagle:": { + "category": "Animals & Nature", + "name": "eagle", + "unicode": "1f985" + }, + ":ear:": { + "category": "People & Body", + "name": "ear", + "unicode": "1f442" + }, + ":ear_of_rice:": { + "category": "Animals & Nature", + "name": "sheaf of rice", + "unicode": "1f33e" + }, + ":ear_with_hearing_aid:": { + "category": "People & Body", + "name": "ear with hearing aid", + "unicode": "1f9bb" + }, + ":earth_africa:": { + "category": "Travel & Places", + "name": "globe showing Europe-Africa", + "unicode": "1f30d" + }, + ":earth_americas:": { + "category": "Travel & Places", + "name": "globe showing Americas", + "unicode": "1f30e" + }, + ":earth_asia:": { + "category": "Travel & Places", + "name": "globe showing Asia-Australia", + "unicode": "1f30f" + }, + ":ecuador:": { + "category": "Flags", + "name": "flag: Ecuador", + "unicode": "1f1ea-1f1e8" + }, + ":egg:": { + "category": "Food & Drink", + "name": "egg", + "unicode": "1f95a" + }, + ":eggplant:": { + "category": "Food & Drink", + "name": "eggplant", + "unicode": "1f346" + }, + ":egypt:": { + "category": "Flags", + "name": "flag: Egypt", + "unicode": "1f1ea-1f1ec" + }, + ":eight:": { + "category": "Symbols", + "name": "keycap: 8", + "unicode": "0038-20e3", + "unicode_alt": "0038-fe0f-20e3" + }, + ":eight_pointed_black_star:": { + "category": "Symbols", + "name": "eight-pointed star", + "unicode": "2734", + "unicode_alt": "2734-fe0f" + }, + ":eight_spoked_asterisk:": { + "category": "Symbols", + "name": "eight-spoked asterisk", + "unicode": "2733", + "unicode_alt": "2733-fe0f" + }, + ":eject_button:": { + "category": "Symbols", + "name": "eject button", + "unicode": "23cf", + "unicode_alt": "23cf-fe0f" + }, + ":el_salvador:": { + "category": "Flags", + "name": "flag: El Salvador", + "unicode": "1f1f8-1f1fb" + }, + ":electric_plug:": { + "category": "Objects", + "name": "electric plug", + "unicode": "1f50c" + }, + ":elephant:": { + "category": "Animals & Nature", + "name": "elephant", + "unicode": "1f418" + }, + ":elevator:": { + "category": "Objects", + "name": "elevator", + "unicode": "1f6d7" + }, + ":elf:": { + "category": "People & Body", + "name": "elf", + "unicode": "1f9dd" + }, + ":elf_man:": { + "category": "People & Body", + "name": "man elf", + "unicode": "1f9dd-2642", + "unicode_alt": "1f9dd-200d-2642-fe0f" + }, + ":elf_woman:": { + "category": "People & Body", + "name": "woman elf", + "unicode": "1f9dd-2640", + "unicode_alt": "1f9dd-200d-2640-fe0f" + }, + ":email:": { + "category": "Objects", + "name": "e-mail", + "unicode": "1f4e7" + }, + ":empty_nest:": { + "category": "Animals & Nature", + "name": "empty nest", + "unicode": "1fab9" + }, + ":end:": { + "category": "Symbols", + "name": "END arrow", + "unicode": "1f51a" + }, + ":england:": { + "category": "Flags", + "name": "flag: England", + "unicode": "1f3f4-e0067-e0062-e0065-e006e-e0067-e007f" + }, + ":envelope:": { + "category": "Objects", + "name": "envelope", + "unicode": "2709", + "unicode_alt": "2709-fe0f" + }, + ":envelope_with_arrow:": { + "category": "Objects", + "name": "envelope with arrow", + "unicode": "1f4e9" + }, + ":equatorial_guinea:": { + "category": "Flags", + "name": "flag: Equatorial Guinea", + "unicode": "1f1ec-1f1f6" + }, + ":eritrea:": { + "category": "Flags", + "name": "flag: Eritrea", + "unicode": "1f1ea-1f1f7" + }, + ":es:": { + "category": "Flags", + "name": "flag: Spain", + "unicode": "1f1ea-1f1f8" + }, + ":estonia:": { + "category": "Flags", + "name": "flag: Estonia", + "unicode": "1f1ea-1f1ea" + }, + ":ethiopia:": { + "category": "Flags", + "name": "flag: Ethiopia", + "unicode": "1f1ea-1f1f9" + }, + ":eu:": { + "category": "Flags", + "name": "flag: European Union", + "unicode": "1f1ea-1f1fa" + }, + ":euro:": { + "category": "Objects", + "name": "euro banknote", + "unicode": "1f4b6" + }, + ":european_castle:": { + "category": "Travel & Places", + "name": "castle", + "unicode": "1f3f0" + }, + ":european_post_office:": { + "category": "Travel & Places", + "name": "post office", + "unicode": "1f3e4" + }, + ":evergreen_tree:": { + "category": "Animals & Nature", + "name": "evergreen tree", + "unicode": "1f332" + }, + ":exclamation:": { + "category": "Symbols", + "name": "red exclamation mark", + "unicode": "2757" + }, + ":exploding_head:": { + "category": "Smileys & Emotion", + "name": "exploding head", + "unicode": "1f92f" + }, + ":expressionless:": { + "category": "Smileys & Emotion", + "name": "expressionless face", + "unicode": "1f611" + }, + ":eye:": { + "category": "People & Body", + "name": "eye", + "unicode": "1f441", + "unicode_alt": "1f441-fe0f" + }, + ":eye_speech_bubble:": { + "category": "Smileys & Emotion", + "name": "eye in speech bubble", + "unicode": "1f441-1f5e8", + "unicode_alt": "1f441-fe0f-200d-1f5e8-fe0f" + }, + ":eyeglasses:": { + "category": "Objects", + "name": "glasses", + "unicode": "1f453" + }, + ":eyes:": { + "category": "People & Body", + "name": "eyes", + "unicode": "1f440" + }, + ":face_exhaling:": { + "category": "Smileys & Emotion", + "name": "face exhaling", + "unicode": "1f62e-1f4a8", + "unicode_alt": "1f62e-200d-1f4a8" + }, + ":face_holding_back_tears:": { + "category": "Smileys & Emotion", + "name": "face holding back tears", + "unicode": "1f979" + }, + ":face_in_clouds:": { + "category": "Smileys & Emotion", + "name": "face in clouds", + "unicode": "1f636-1f32b", + "unicode_alt": "1f636-200d-1f32b-fe0f" + }, + ":face_with_diagonal_mouth:": { + "category": "Smileys & Emotion", + "name": "face with diagonal mouth", + "unicode": "1fae4" + }, + ":face_with_head_bandage:": { + "category": "Smileys & Emotion", + "name": "face with head-bandage", + "unicode": "1f915" + }, + ":face_with_open_eyes_and_hand_over_mouth:": { + "category": "Smileys & Emotion", + "name": "face with open eyes and hand over mouth", + "unicode": "1fae2" + }, + ":face_with_peeking_eye:": { + "category": "Smileys & Emotion", + "name": "face with peeking eye", + "unicode": "1fae3" + }, + ":face_with_spiral_eyes:": { + "category": "Smileys & Emotion", + "name": "face with spiral eyes", + "unicode": "1f635-1f4ab", + "unicode_alt": "1f635-200d-1f4ab" + }, + ":face_with_thermometer:": { + "category": "Smileys & Emotion", + "name": "face with thermometer", + "unicode": "1f912" + }, + ":facepalm:": { + "category": "People & Body", + "name": "person facepalming", + "unicode": "1f926" + }, + ":factory:": { + "category": "Travel & Places", + "name": "factory", + "unicode": "1f3ed" + }, + ":factory_worker:": { + "category": "People & Body", + "name": "factory worker", + "unicode": "1f9d1-1f3ed", + "unicode_alt": "1f9d1-200d-1f3ed" + }, + ":fairy:": { + "category": "People & Body", + "name": "fairy", + "unicode": "1f9da" + }, + ":fairy_man:": { + "category": "People & Body", + "name": "man fairy", + "unicode": "1f9da-2642", + "unicode_alt": "1f9da-200d-2642-fe0f" + }, + ":fairy_woman:": { + "category": "People & Body", + "name": "woman fairy", + "unicode": "1f9da-2640", + "unicode_alt": "1f9da-200d-2640-fe0f" + }, + ":falafel:": { + "category": "Food & Drink", + "name": "falafel", + "unicode": "1f9c6" + }, + ":falkland_islands:": { + "category": "Flags", + "name": "flag: Falkland Islands", + "unicode": "1f1eb-1f1f0" + }, + ":fallen_leaf:": { + "category": "Animals & Nature", + "name": "fallen leaf", + "unicode": "1f342" + }, + ":family:": { + "category": "People & Body", + "name": "family", + "unicode": "1f46a" + }, + ":family_man_boy:": { + "category": "People & Body", + "name": "family: man, boy", + "unicode": "1f468-1f466", + "unicode_alt": "1f468-200d-1f466" + }, + ":family_man_boy_boy:": { + "category": "People & Body", + "name": "family: man, boy, boy", + "unicode": "1f468-1f466-1f466", + "unicode_alt": "1f468-200d-1f466-200d-1f466" + }, + ":family_man_girl:": { + "category": "People & Body", + "name": "family: man, girl", + "unicode": "1f468-1f467", + "unicode_alt": "1f468-200d-1f467" + }, + ":family_man_girl_boy:": { + "category": "People & Body", + "name": "family: man, girl, boy", + "unicode": "1f468-1f467-1f466", + "unicode_alt": "1f468-200d-1f467-200d-1f466" + }, + ":family_man_girl_girl:": { + "category": "People & Body", + "name": "family: man, girl, girl", + "unicode": "1f468-1f467-1f467", + "unicode_alt": "1f468-200d-1f467-200d-1f467" + }, + ":family_man_man_boy:": { + "category": "People & Body", + "name": "family: man, man, boy", + "unicode": "1f468-1f468-1f466", + "unicode_alt": "1f468-200d-1f468-200d-1f466" + }, + ":family_man_man_boy_boy:": { + "category": "People & Body", + "name": "family: man, man, boy, boy", + "unicode": "1f468-1f468-1f466-1f466", + "unicode_alt": "1f468-200d-1f468-200d-1f466-200d-1f466" + }, + ":family_man_man_girl:": { + "category": "People & Body", + "name": "family: man, man, girl", + "unicode": "1f468-1f468-1f467", + "unicode_alt": "1f468-200d-1f468-200d-1f467" + }, + ":family_man_man_girl_boy:": { + "category": "People & Body", + "name": "family: man, man, girl, boy", + "unicode": "1f468-1f468-1f467-1f466", + "unicode_alt": "1f468-200d-1f468-200d-1f467-200d-1f466" + }, + ":family_man_man_girl_girl:": { + "category": "People & Body", + "name": "family: man, man, girl, girl", + "unicode": "1f468-1f468-1f467-1f467", + "unicode_alt": "1f468-200d-1f468-200d-1f467-200d-1f467" + }, + ":family_man_woman_boy:": { + "category": "People & Body", + "name": "family: man, woman, boy", + "unicode": "1f468-1f469-1f466", + "unicode_alt": "1f468-200d-1f469-200d-1f466" + }, + ":family_man_woman_boy_boy:": { + "category": "People & Body", + "name": "family: man, woman, boy, boy", + "unicode": "1f468-1f469-1f466-1f466", + "unicode_alt": "1f468-200d-1f469-200d-1f466-200d-1f466" + }, + ":family_man_woman_girl:": { + "category": "People & Body", + "name": "family: man, woman, girl", + "unicode": "1f468-1f469-1f467", + "unicode_alt": "1f468-200d-1f469-200d-1f467" + }, + ":family_man_woman_girl_boy:": { + "category": "People & Body", + "name": "family: man, woman, girl, boy", + "unicode": "1f468-1f469-1f467-1f466", + "unicode_alt": "1f468-200d-1f469-200d-1f467-200d-1f466" + }, + ":family_man_woman_girl_girl:": { + "category": "People & Body", + "name": "family: man, woman, girl, girl", + "unicode": "1f468-1f469-1f467-1f467", + "unicode_alt": "1f468-200d-1f469-200d-1f467-200d-1f467" + }, + ":family_woman_boy:": { + "category": "People & Body", + "name": "family: woman, boy", + "unicode": "1f469-1f466", + "unicode_alt": "1f469-200d-1f466" + }, + ":family_woman_boy_boy:": { + "category": "People & Body", + "name": "family: woman, boy, boy", + "unicode": "1f469-1f466-1f466", + "unicode_alt": "1f469-200d-1f466-200d-1f466" + }, + ":family_woman_girl:": { + "category": "People & Body", + "name": "family: woman, girl", + "unicode": "1f469-1f467", + "unicode_alt": "1f469-200d-1f467" + }, + ":family_woman_girl_boy:": { + "category": "People & Body", + "name": "family: woman, girl, boy", + "unicode": "1f469-1f467-1f466", + "unicode_alt": "1f469-200d-1f467-200d-1f466" + }, + ":family_woman_girl_girl:": { + "category": "People & Body", + "name": "family: woman, girl, girl", + "unicode": "1f469-1f467-1f467", + "unicode_alt": "1f469-200d-1f467-200d-1f467" + }, + ":family_woman_woman_boy:": { + "category": "People & Body", + "name": "family: woman, woman, boy", + "unicode": "1f469-1f469-1f466", + "unicode_alt": "1f469-200d-1f469-200d-1f466" + }, + ":family_woman_woman_boy_boy:": { + "category": "People & Body", + "name": "family: woman, woman, boy, boy", + "unicode": "1f469-1f469-1f466-1f466", + "unicode_alt": "1f469-200d-1f469-200d-1f466-200d-1f466" + }, + ":family_woman_woman_girl:": { + "category": "People & Body", + "name": "family: woman, woman, girl", + "unicode": "1f469-1f469-1f467", + "unicode_alt": "1f469-200d-1f469-200d-1f467" + }, + ":family_woman_woman_girl_boy:": { + "category": "People & Body", + "name": "family: woman, woman, girl, boy", + "unicode": "1f469-1f469-1f467-1f466", + "unicode_alt": "1f469-200d-1f469-200d-1f467-200d-1f466" + }, + ":family_woman_woman_girl_girl:": { + "category": "People & Body", + "name": "family: woman, woman, girl, girl", + "unicode": "1f469-1f469-1f467-1f467", + "unicode_alt": "1f469-200d-1f469-200d-1f467-200d-1f467" + }, + ":farmer:": { + "category": "People & Body", + "name": "farmer", + "unicode": "1f9d1-1f33e", + "unicode_alt": "1f9d1-200d-1f33e" + }, + ":faroe_islands:": { + "category": "Flags", + "name": "flag: Faroe Islands", + "unicode": "1f1eb-1f1f4" + }, + ":fast_forward:": { + "category": "Symbols", + "name": "fast-forward button", + "unicode": "23e9" + }, + ":fax:": { + "category": "Objects", + "name": "fax machine", + "unicode": "1f4e0" + }, + ":fearful:": { + "category": "Smileys & Emotion", + "name": "fearful face", + "unicode": "1f628" + }, + ":feather:": { + "category": "Animals & Nature", + "name": "feather", + "unicode": "1fab6" + }, + ":feet:": { + "category": "Animals & Nature", + "name": "paw prints", + "unicode": "1f43e" + }, + ":female_detective:": { + "category": "People & Body", + "name": "woman detective", + "unicode": "1f575-2640", + "unicode_alt": "1f575-fe0f-200d-2640-fe0f" + }, + ":female_sign:": { + "category": "Symbols", + "name": "female sign", + "unicode": "2640", + "unicode_alt": "2640-fe0f" + }, + ":ferris_wheel:": { + "category": "Travel & Places", + "name": "ferris wheel", + "unicode": "1f3a1" + }, + ":ferry:": { + "category": "Travel & Places", + "name": "ferry", + "unicode": "26f4", + "unicode_alt": "26f4-fe0f" + }, + ":field_hockey:": { + "category": "Activities", + "name": "field hockey", + "unicode": "1f3d1" + }, + ":fiji:": { + "category": "Flags", + "name": "flag: Fiji", + "unicode": "1f1eb-1f1ef" + }, + ":file_cabinet:": { + "category": "Objects", + "name": "file cabinet", + "unicode": "1f5c4", + "unicode_alt": "1f5c4-fe0f" + }, + ":file_folder:": { + "category": "Objects", + "name": "file folder", + "unicode": "1f4c1" + }, + ":film_projector:": { + "category": "Objects", + "name": "film projector", + "unicode": "1f4fd", + "unicode_alt": "1f4fd-fe0f" + }, + ":film_strip:": { + "category": "Objects", + "name": "film frames", + "unicode": "1f39e", + "unicode_alt": "1f39e-fe0f" + }, + ":finland:": { + "category": "Flags", + "name": "flag: Finland", + "unicode": "1f1eb-1f1ee" + }, + ":fire:": { + "category": "Travel & Places", + "name": "fire", + "unicode": "1f525" + }, + ":fire_engine:": { + "category": "Travel & Places", + "name": "fire engine", + "unicode": "1f692" + }, + ":fire_extinguisher:": { + "category": "Objects", + "name": "fire extinguisher", + "unicode": "1f9ef" + }, + ":firecracker:": { + "category": "Activities", + "name": "firecracker", + "unicode": "1f9e8" + }, + ":firefighter:": { + "category": "People & Body", + "name": "firefighter", + "unicode": "1f9d1-1f692", + "unicode_alt": "1f9d1-200d-1f692" + }, + ":fireworks:": { + "category": "Activities", + "name": "fireworks", + "unicode": "1f386" + }, + ":first_quarter_moon:": { + "category": "Travel & Places", + "name": "first quarter moon", + "unicode": "1f313" + }, + ":first_quarter_moon_with_face:": { + "category": "Travel & Places", + "name": "first quarter moon face", + "unicode": "1f31b" + }, + ":fish:": { + "category": "Animals & Nature", + "name": "fish", + "unicode": "1f41f" + }, + ":fish_cake:": { + "category": "Food & Drink", + "name": "fish cake with swirl", + "unicode": "1f365" + }, + ":fishing_pole_and_fish:": { + "category": "Activities", + "name": "fishing pole", + "unicode": "1f3a3" + }, + ":fist_left:": { + "category": "People & Body", + "name": "left-facing fist", + "unicode": "1f91b" + }, + ":fist_oncoming:": { + "category": "People & Body", + "name": "oncoming fist", + "unicode": "1f44a" + }, + ":fist_raised:": { + "category": "People & Body", + "name": "raised fist", + "unicode": "270a" + }, + ":fist_right:": { + "category": "People & Body", + "name": "right-facing fist", + "unicode": "1f91c" + }, + ":five:": { + "category": "Symbols", + "name": "keycap: 5", + "unicode": "0035-20e3", + "unicode_alt": "0035-fe0f-20e3" + }, + ":flags:": { + "category": "Activities", + "name": "carp streamer", + "unicode": "1f38f" + }, + ":flamingo:": { + "category": "Animals & Nature", + "name": "flamingo", + "unicode": "1f9a9" + }, + ":flashlight:": { + "category": "Objects", + "name": "flashlight", + "unicode": "1f526" + }, + ":flat_shoe:": { + "category": "Objects", + "name": "flat shoe", + "unicode": "1f97f" + }, + ":flatbread:": { + "category": "Food & Drink", + "name": "flatbread", + "unicode": "1fad3" + }, + ":fleur_de_lis:": { + "category": "Symbols", + "name": "fleur-de-lis", + "unicode": "269c", + "unicode_alt": "269c-fe0f" + }, + ":flight_arrival:": { + "category": "Travel & Places", + "name": "airplane arrival", + "unicode": "1f6ec" + }, + ":flight_departure:": { + "category": "Travel & Places", + "name": "airplane departure", + "unicode": "1f6eb" + }, + ":floppy_disk:": { + "category": "Objects", + "name": "floppy disk", + "unicode": "1f4be" + }, + ":flower_playing_cards:": { + "category": "Activities", + "name": "flower playing cards", + "unicode": "1f3b4" + }, + ":flushed:": { + "category": "Smileys & Emotion", + "name": "flushed face", + "unicode": "1f633" + }, + ":flute:": { + "category": "Objects", + "name": "flute", + "unicode": "1fa88" + }, + ":fly:": { + "category": "Animals & Nature", + "name": "fly", + "unicode": "1fab0" + }, + ":flying_disc:": { + "category": "Activities", + "name": "flying disc", + "unicode": "1f94f" + }, + ":flying_saucer:": { + "category": "Travel & Places", + "name": "flying saucer", + "unicode": "1f6f8" + }, + ":fog:": { + "category": "Travel & Places", + "name": "fog", + "unicode": "1f32b", + "unicode_alt": "1f32b-fe0f" + }, + ":foggy:": { + "category": "Travel & Places", + "name": "foggy", + "unicode": "1f301" + }, + ":folding_hand_fan:": { + "category": "Objects", + "name": "folding hand fan", + "unicode": "1faad" + }, + ":fondue:": { + "category": "Food & Drink", + "name": "fondue", + "unicode": "1fad5" + }, + ":foot:": { + "category": "People & Body", + "name": "foot", + "unicode": "1f9b6" + }, + ":football:": { + "category": "Activities", + "name": "american football", + "unicode": "1f3c8" + }, + ":footprints:": { + "category": "People & Body", + "name": "footprints", + "unicode": "1f463" + }, + ":fork_and_knife:": { + "category": "Food & Drink", + "name": "fork and knife", + "unicode": "1f374" + }, + ":fortune_cookie:": { + "category": "Food & Drink", + "name": "fortune cookie", + "unicode": "1f960" + }, + ":fountain:": { + "category": "Travel & Places", + "name": "fountain", + "unicode": "26f2" + }, + ":fountain_pen:": { + "category": "Objects", + "name": "fountain pen", + "unicode": "1f58b", + "unicode_alt": "1f58b-fe0f" + }, + ":four:": { + "category": "Symbols", + "name": "keycap: 4", + "unicode": "0034-20e3", + "unicode_alt": "0034-fe0f-20e3" + }, + ":four_leaf_clover:": { + "category": "Animals & Nature", + "name": "four leaf clover", + "unicode": "1f340" + }, + ":fox_face:": { + "category": "Animals & Nature", + "name": "fox", + "unicode": "1f98a" + }, + ":fr:": { + "category": "Flags", + "name": "flag: France", + "unicode": "1f1eb-1f1f7" + }, + ":framed_picture:": { + "category": "Activities", + "name": "framed picture", + "unicode": "1f5bc", + "unicode_alt": "1f5bc-fe0f" + }, + ":free:": { + "category": "Symbols", + "name": "FREE button", + "unicode": "1f193" + }, + ":french_guiana:": { + "category": "Flags", + "name": "flag: French Guiana", + "unicode": "1f1ec-1f1eb" + }, + ":french_polynesia:": { + "category": "Flags", + "name": "flag: French Polynesia", + "unicode": "1f1f5-1f1eb" + }, + ":french_southern_territories:": { + "category": "Flags", + "name": "flag: French Southern Territories", + "unicode": "1f1f9-1f1eb" + }, + ":fried_egg:": { + "category": "Food & Drink", + "name": "cooking", + "unicode": "1f373" + }, + ":fried_shrimp:": { + "category": "Food & Drink", + "name": "fried shrimp", + "unicode": "1f364" + }, + ":fries:": { + "category": "Food & Drink", + "name": "french fries", + "unicode": "1f35f" + }, + ":frog:": { + "category": "Animals & Nature", + "name": "frog", + "unicode": "1f438" + }, + ":frowning:": { + "category": "Smileys & Emotion", + "name": "frowning face with open mouth", + "unicode": "1f626" + }, + ":frowning_face:": { + "category": "Smileys & Emotion", + "name": "frowning face", + "unicode": "2639", + "unicode_alt": "2639-fe0f" + }, + ":frowning_man:": { + "category": "People & Body", + "name": "man frowning", + "unicode": "1f64d-2642", + "unicode_alt": "1f64d-200d-2642-fe0f" + }, + ":frowning_person:": { + "category": "People & Body", + "name": "person frowning", + "unicode": "1f64d" + }, + ":frowning_woman:": { + "category": "People & Body", + "name": "woman frowning", + "unicode": "1f64d-2640", + "unicode_alt": "1f64d-200d-2640-fe0f" + }, + ":fuelpump:": { + "category": "Travel & Places", + "name": "fuel pump", + "unicode": "26fd" + }, + ":full_moon:": { + "category": "Travel & Places", + "name": "full moon", + "unicode": "1f315" + }, + ":full_moon_with_face:": { + "category": "Travel & Places", + "name": "full moon face", + "unicode": "1f31d" + }, + ":funeral_urn:": { + "category": "Objects", + "name": "funeral urn", + "unicode": "26b1", + "unicode_alt": "26b1-fe0f" + }, + ":gabon:": { + "category": "Flags", + "name": "flag: Gabon", + "unicode": "1f1ec-1f1e6" + }, + ":gambia:": { + "category": "Flags", + "name": "flag: Gambia", + "unicode": "1f1ec-1f1f2" + }, + ":game_die:": { + "category": "Activities", + "name": "game die", + "unicode": "1f3b2" + }, + ":garlic:": { + "category": "Food & Drink", + "name": "garlic", + "unicode": "1f9c4" + }, + ":gb:": { + "category": "Flags", + "name": "flag: United Kingdom", + "unicode": "1f1ec-1f1e7" + }, + ":gear:": { + "category": "Objects", + "name": "gear", + "unicode": "2699", + "unicode_alt": "2699-fe0f" + }, + ":gem:": { + "category": "Objects", + "name": "gem stone", + "unicode": "1f48e" + }, + ":gemini:": { + "category": "Symbols", + "name": "Gemini", + "unicode": "264a" + }, + ":genie:": { + "category": "People & Body", + "name": "genie", + "unicode": "1f9de" + }, + ":genie_man:": { + "category": "People & Body", + "name": "man genie", + "unicode": "1f9de-2642", + "unicode_alt": "1f9de-200d-2642-fe0f" + }, + ":genie_woman:": { + "category": "People & Body", + "name": "woman genie", + "unicode": "1f9de-2640", + "unicode_alt": "1f9de-200d-2640-fe0f" + }, + ":georgia:": { + "category": "Flags", + "name": "flag: Georgia", + "unicode": "1f1ec-1f1ea" + }, + ":ghana:": { + "category": "Flags", + "name": "flag: Ghana", + "unicode": "1f1ec-1f1ed" + }, + ":ghost:": { + "category": "Smileys & Emotion", + "name": "ghost", + "unicode": "1f47b" + }, + ":gibraltar:": { + "category": "Flags", + "name": "flag: Gibraltar", + "unicode": "1f1ec-1f1ee" + }, + ":gift:": { + "category": "Activities", + "name": "wrapped gift", + "unicode": "1f381" + }, + ":gift_heart:": { + "category": "Smileys & Emotion", + "name": "heart with ribbon", + "unicode": "1f49d" + }, + ":ginger_root:": { + "category": "Food & Drink", + "name": "ginger root", + "unicode": "1fada" + }, + ":giraffe:": { + "category": "Animals & Nature", + "name": "giraffe", + "unicode": "1f992" + }, + ":girl:": { + "category": "People & Body", + "name": "girl", + "unicode": "1f467" + }, + ":globe_with_meridians:": { + "category": "Travel & Places", + "name": "globe with meridians", + "unicode": "1f310" + }, + ":gloves:": { + "category": "Objects", + "name": "gloves", + "unicode": "1f9e4" + }, + ":goal_net:": { + "category": "Activities", + "name": "goal net", + "unicode": "1f945" + }, + ":goat:": { + "category": "Animals & Nature", + "name": "goat", + "unicode": "1f410" + }, + ":goggles:": { + "category": "Objects", + "name": "goggles", + "unicode": "1f97d" + }, + ":golf:": { + "category": "Activities", + "name": "flag in hole", + "unicode": "26f3" + }, + ":golfing:": { + "category": "People & Body", + "name": "person golfing", + "unicode": "1f3cc", + "unicode_alt": "1f3cc-fe0f" + }, + ":golfing_man:": { + "category": "People & Body", + "name": "man golfing", + "unicode": "1f3cc-2642", + "unicode_alt": "1f3cc-fe0f-200d-2642-fe0f" + }, + ":golfing_woman:": { + "category": "People & Body", + "name": "woman golfing", + "unicode": "1f3cc-2640", + "unicode_alt": "1f3cc-fe0f-200d-2640-fe0f" + }, + ":goose:": { + "category": "Animals & Nature", + "name": "goose", + "unicode": "1fabf" + }, + ":gorilla:": { + "category": "Animals & Nature", + "name": "gorilla", + "unicode": "1f98d" + }, + ":grapes:": { + "category": "Food & Drink", + "name": "grapes", + "unicode": "1f347" + }, + ":greece:": { + "category": "Flags", + "name": "flag: Greece", + "unicode": "1f1ec-1f1f7" + }, + ":green_apple:": { + "category": "Food & Drink", + "name": "green apple", + "unicode": "1f34f" + }, + ":green_book:": { + "category": "Objects", + "name": "green book", + "unicode": "1f4d7" + }, + ":green_circle:": { + "category": "Symbols", + "name": "green circle", + "unicode": "1f7e2" + }, + ":green_heart:": { + "category": "Smileys & Emotion", + "name": "green heart", + "unicode": "1f49a" + }, + ":green_salad:": { + "category": "Food & Drink", + "name": "green salad", + "unicode": "1f957" + }, + ":green_square:": { + "category": "Symbols", + "name": "green square", + "unicode": "1f7e9" + }, + ":greenland:": { + "category": "Flags", + "name": "flag: Greenland", + "unicode": "1f1ec-1f1f1" + }, + ":grenada:": { + "category": "Flags", + "name": "flag: Grenada", + "unicode": "1f1ec-1f1e9" + }, + ":grey_exclamation:": { + "category": "Symbols", + "name": "white exclamation mark", + "unicode": "2755" + }, + ":grey_heart:": { + "category": "Smileys & Emotion", + "name": "grey heart", + "unicode": "1fa76" + }, + ":grey_question:": { + "category": "Symbols", + "name": "white question mark", + "unicode": "2754" + }, + ":grimacing:": { + "category": "Smileys & Emotion", + "name": "grimacing face", + "unicode": "1f62c" + }, + ":grin:": { + "category": "Smileys & Emotion", + "name": "beaming face with smiling eyes", + "unicode": "1f601" + }, + ":grinning:": { + "category": "Smileys & Emotion", + "name": "grinning face", + "unicode": "1f600" + }, + ":guadeloupe:": { + "category": "Flags", + "name": "flag: Guadeloupe", + "unicode": "1f1ec-1f1f5" + }, + ":guam:": { + "category": "Flags", + "name": "flag: Guam", + "unicode": "1f1ec-1f1fa" + }, + ":guard:": { + "category": "People & Body", + "name": "guard", + "unicode": "1f482" + }, + ":guardsman:": { + "category": "People & Body", + "name": "man guard", + "unicode": "1f482-2642", + "unicode_alt": "1f482-200d-2642-fe0f" + }, + ":guardswoman:": { + "category": "People & Body", + "name": "woman guard", + "unicode": "1f482-2640", + "unicode_alt": "1f482-200d-2640-fe0f" + }, + ":guatemala:": { + "category": "Flags", + "name": "flag: Guatemala", + "unicode": "1f1ec-1f1f9" + }, + ":guernsey:": { + "category": "Flags", + "name": "flag: Guernsey", + "unicode": "1f1ec-1f1ec" + }, + ":guide_dog:": { + "category": "Animals & Nature", + "name": "guide dog", + "unicode": "1f9ae" + }, + ":guinea:": { + "category": "Flags", + "name": "flag: Guinea", + "unicode": "1f1ec-1f1f3" + }, + ":guinea_bissau:": { + "category": "Flags", + "name": "flag: Guinea-Bissau", + "unicode": "1f1ec-1f1fc" + }, + ":guitar:": { + "category": "Objects", + "name": "guitar", + "unicode": "1f3b8" + }, + ":gun:": { + "category": "Activities", + "name": "water pistol", + "unicode": "1f52b" + }, + ":guyana:": { + "category": "Flags", + "name": "flag: Guyana", + "unicode": "1f1ec-1f1fe" + }, + ":hair_pick:": { + "category": "Objects", + "name": "hair pick", + "unicode": "1faae" + }, + ":haircut:": { + "category": "People & Body", + "name": "person getting haircut", + "unicode": "1f487" + }, + ":haircut_man:": { + "category": "People & Body", + "name": "man getting haircut", + "unicode": "1f487-2642", + "unicode_alt": "1f487-200d-2642-fe0f" + }, + ":haircut_woman:": { + "category": "People & Body", + "name": "woman getting haircut", + "unicode": "1f487-2640", + "unicode_alt": "1f487-200d-2640-fe0f" + }, + ":haiti:": { + "category": "Flags", + "name": "flag: Haiti", + "unicode": "1f1ed-1f1f9" + }, + ":hamburger:": { + "category": "Food & Drink", + "name": "hamburger", + "unicode": "1f354" + }, + ":hammer:": { + "category": "Objects", + "name": "hammer", + "unicode": "1f528" + }, + ":hammer_and_pick:": { + "category": "Objects", + "name": "hammer and pick", + "unicode": "2692", + "unicode_alt": "2692-fe0f" + }, + ":hammer_and_wrench:": { + "category": "Objects", + "name": "hammer and wrench", + "unicode": "1f6e0", + "unicode_alt": "1f6e0-fe0f" + }, + ":hamsa:": { + "category": "Objects", + "name": "hamsa", + "unicode": "1faac" + }, + ":hamster:": { + "category": "Animals & Nature", + "name": "hamster", + "unicode": "1f439" + }, + ":hand:": { + "category": "People & Body", + "name": "raised hand", + "unicode": "270b" + }, + ":hand_over_mouth:": { + "category": "Smileys & Emotion", + "name": "face with hand over mouth", + "unicode": "1f92d" + }, + ":hand_with_index_finger_and_thumb_crossed:": { + "category": "People & Body", + "name": "hand with index finger and thumb crossed", + "unicode": "1faf0" + }, + ":handbag:": { + "category": "Objects", + "name": "handbag", + "unicode": "1f45c" + }, + ":handball_person:": { + "category": "People & Body", + "name": "person playing handball", + "unicode": "1f93e" + }, + ":handshake:": { + "category": "People & Body", + "name": "handshake", + "unicode": "1f91d" + }, + ":hankey:": { + "category": "Smileys & Emotion", + "name": "pile of poo", + "unicode": "1f4a9" + }, + ":hash:": { + "category": "Symbols", + "name": "keycap: #", + "unicode": "0023-20e3", + "unicode_alt": "0023-fe0f-20e3" + }, + ":hatched_chick:": { + "category": "Animals & Nature", + "name": "front-facing baby chick", + "unicode": "1f425" + }, + ":hatching_chick:": { + "category": "Animals & Nature", + "name": "hatching chick", + "unicode": "1f423" + }, + ":headphones:": { + "category": "Objects", + "name": "headphone", + "unicode": "1f3a7" + }, + ":headstone:": { + "category": "Objects", + "name": "headstone", + "unicode": "1faa6" + }, + ":health_worker:": { + "category": "People & Body", + "name": "health worker", + "unicode": "1f9d1-2695", + "unicode_alt": "1f9d1-200d-2695-fe0f" + }, + ":hear_no_evil:": { + "category": "Smileys & Emotion", + "name": "hear-no-evil monkey", + "unicode": "1f649" + }, + ":heard_mcdonald_islands:": { + "category": "Flags", + "name": "flag: Heard & McDonald Islands", + "unicode": "1f1ed-1f1f2" + }, + ":heart:": { + "category": "Smileys & Emotion", + "name": "red heart", + "unicode": "2764", + "unicode_alt": "2764-fe0f" + }, + ":heart_decoration:": { + "category": "Smileys & Emotion", + "name": "heart decoration", + "unicode": "1f49f" + }, + ":heart_eyes:": { + "category": "Smileys & Emotion", + "name": "smiling face with heart-eyes", + "unicode": "1f60d" + }, + ":heart_eyes_cat:": { + "category": "Smileys & Emotion", + "name": "smiling cat with heart-eyes", + "unicode": "1f63b" + }, + ":heart_hands:": { + "category": "People & Body", + "name": "heart hands", + "unicode": "1faf6" + }, + ":heart_on_fire:": { + "category": "Smileys & Emotion", + "name": "heart on fire", + "unicode": "2764-1f525", + "unicode_alt": "2764-fe0f-200d-1f525" + }, + ":heartbeat:": { + "category": "Smileys & Emotion", + "name": "beating heart", + "unicode": "1f493" + }, + ":heartpulse:": { + "category": "Smileys & Emotion", + "name": "growing heart", + "unicode": "1f497" + }, + ":hearts:": { + "category": "Activities", + "name": "heart suit", + "unicode": "2665", + "unicode_alt": "2665-fe0f" + }, + ":heavy_check_mark:": { + "category": "Symbols", + "name": "check mark", + "unicode": "2714", + "unicode_alt": "2714-fe0f" + }, + ":heavy_division_sign:": { + "category": "Symbols", + "name": "divide", + "unicode": "2797" + }, + ":heavy_dollar_sign:": { + "category": "Symbols", + "name": "heavy dollar sign", + "unicode": "1f4b2" + }, + ":heavy_equals_sign:": { + "category": "Symbols", + "name": "heavy equals sign", + "unicode": "1f7f0" + }, + ":heavy_heart_exclamation:": { + "category": "Smileys & Emotion", + "name": "heart exclamation", + "unicode": "2763", + "unicode_alt": "2763-fe0f" + }, + ":heavy_minus_sign:": { + "category": "Symbols", + "name": "minus", + "unicode": "2796" + }, + ":heavy_multiplication_x:": { + "category": "Symbols", + "name": "multiply", + "unicode": "2716", + "unicode_alt": "2716-fe0f" + }, + ":heavy_plus_sign:": { + "category": "Symbols", + "name": "plus", + "unicode": "2795" + }, + ":hedgehog:": { + "category": "Animals & Nature", + "name": "hedgehog", + "unicode": "1f994" + }, + ":helicopter:": { + "category": "Travel & Places", + "name": "helicopter", + "unicode": "1f681" + }, + ":herb:": { + "category": "Animals & Nature", + "name": "herb", + "unicode": "1f33f" + }, + ":hibiscus:": { + "category": "Animals & Nature", + "name": "hibiscus", + "unicode": "1f33a" + }, + ":high_brightness:": { + "category": "Symbols", + "name": "bright button", + "unicode": "1f506" + }, + ":high_heel:": { + "category": "Objects", + "name": "high-heeled shoe", + "unicode": "1f460" + }, + ":hiking_boot:": { + "category": "Objects", + "name": "hiking boot", + "unicode": "1f97e" + }, + ":hindu_temple:": { + "category": "Travel & Places", + "name": "hindu temple", + "unicode": "1f6d5" + }, + ":hippopotamus:": { + "category": "Animals & Nature", + "name": "hippopotamus", + "unicode": "1f99b" + }, + ":hocho:": { + "category": "Food & Drink", + "name": "kitchen knife", + "unicode": "1f52a" + }, + ":hole:": { + "category": "Smileys & Emotion", + "name": "hole", + "unicode": "1f573", + "unicode_alt": "1f573-fe0f" + }, + ":honduras:": { + "category": "Flags", + "name": "flag: Honduras", + "unicode": "1f1ed-1f1f3" + }, + ":honey_pot:": { + "category": "Food & Drink", + "name": "honey pot", + "unicode": "1f36f" + }, + ":hong_kong:": { + "category": "Flags", + "name": "flag: Hong Kong SAR China", + "unicode": "1f1ed-1f1f0" + }, + ":hook:": { + "category": "Objects", + "name": "hook", + "unicode": "1fa9d" + }, + ":horse:": { + "category": "Animals & Nature", + "name": "horse face", + "unicode": "1f434" + }, + ":horse_racing:": { + "category": "People & Body", + "name": "horse racing", + "unicode": "1f3c7" + }, + ":hospital:": { + "category": "Travel & Places", + "name": "hospital", + "unicode": "1f3e5" + }, + ":hot_face:": { + "category": "Smileys & Emotion", + "name": "hot face", + "unicode": "1f975" + }, + ":hot_pepper:": { + "category": "Food & Drink", + "name": "hot pepper", + "unicode": "1f336", + "unicode_alt": "1f336-fe0f" + }, + ":hotdog:": { + "category": "Food & Drink", + "name": "hot dog", + "unicode": "1f32d" + }, + ":hotel:": { + "category": "Travel & Places", + "name": "hotel", + "unicode": "1f3e8" + }, + ":hotsprings:": { + "category": "Travel & Places", + "name": "hot springs", + "unicode": "2668", + "unicode_alt": "2668-fe0f" + }, + ":hourglass:": { + "category": "Travel & Places", + "name": "hourglass done", + "unicode": "231b" + }, + ":hourglass_flowing_sand:": { + "category": "Travel & Places", + "name": "hourglass not done", + "unicode": "23f3" + }, + ":house:": { + "category": "Travel & Places", + "name": "house", + "unicode": "1f3e0" + }, + ":house_with_garden:": { + "category": "Travel & Places", + "name": "house with garden", + "unicode": "1f3e1" + }, + ":houses:": { + "category": "Travel & Places", + "name": "houses", + "unicode": "1f3d8", + "unicode_alt": "1f3d8-fe0f" + }, + ":hugs:": { + "category": "Smileys & Emotion", + "name": "smiling face with open hands", + "unicode": "1f917" + }, + ":hungary:": { + "category": "Flags", + "name": "flag: Hungary", + "unicode": "1f1ed-1f1fa" + }, + ":hushed:": { + "category": "Smileys & Emotion", + "name": "hushed face", + "unicode": "1f62f" + }, + ":hut:": { + "category": "Travel & Places", + "name": "hut", + "unicode": "1f6d6" + }, + ":hyacinth:": { + "category": "Animals & Nature", + "name": "hyacinth", + "unicode": "1fabb" + }, + ":ice_cream:": { + "category": "Food & Drink", + "name": "ice cream", + "unicode": "1f368" + }, + ":ice_cube:": { + "category": "Food & Drink", + "name": "ice", + "unicode": "1f9ca" + }, + ":ice_hockey:": { + "category": "Activities", + "name": "ice hockey", + "unicode": "1f3d2" + }, + ":ice_skate:": { + "category": "Activities", + "name": "ice skate", + "unicode": "26f8", + "unicode_alt": "26f8-fe0f" + }, + ":icecream:": { + "category": "Food & Drink", + "name": "soft ice cream", + "unicode": "1f366" + }, + ":iceland:": { + "category": "Flags", + "name": "flag: Iceland", + "unicode": "1f1ee-1f1f8" + }, + ":id:": { + "category": "Symbols", + "name": "ID button", + "unicode": "1f194" + }, + ":identification_card:": { + "category": "Objects", + "name": "identification card", + "unicode": "1faaa" + }, + ":ideograph_advantage:": { + "category": "Symbols", + "name": "Japanese \u201cbargain\u201d button", + "unicode": "1f250" + }, + ":imp:": { + "category": "Smileys & Emotion", + "name": "angry face with horns", + "unicode": "1f47f" + }, + ":inbox_tray:": { + "category": "Objects", + "name": "inbox tray", + "unicode": "1f4e5" + }, + ":incoming_envelope:": { + "category": "Objects", + "name": "incoming envelope", + "unicode": "1f4e8" + }, + ":index_pointing_at_the_viewer:": { + "category": "People & Body", + "name": "index pointing at the viewer", + "unicode": "1faf5" + }, + ":india:": { + "category": "Flags", + "name": "flag: India", + "unicode": "1f1ee-1f1f3" + }, + ":indonesia:": { + "category": "Flags", + "name": "flag: Indonesia", + "unicode": "1f1ee-1f1e9" + }, + ":infinity:": { + "category": "Symbols", + "name": "infinity", + "unicode": "267e", + "unicode_alt": "267e-fe0f" + }, + ":information_source:": { + "category": "Symbols", + "name": "information", + "unicode": "2139", + "unicode_alt": "2139-fe0f" + }, + ":innocent:": { + "category": "Smileys & Emotion", + "name": "smiling face with halo", + "unicode": "1f607" + }, + ":interrobang:": { + "category": "Symbols", + "name": "exclamation question mark", + "unicode": "2049", + "unicode_alt": "2049-fe0f" + }, + ":iphone:": { + "category": "Objects", + "name": "mobile phone", + "unicode": "1f4f1" + }, + ":iran:": { + "category": "Flags", + "name": "flag: Iran", + "unicode": "1f1ee-1f1f7" + }, + ":iraq:": { + "category": "Flags", + "name": "flag: Iraq", + "unicode": "1f1ee-1f1f6" + }, + ":ireland:": { + "category": "Flags", + "name": "flag: Ireland", + "unicode": "1f1ee-1f1ea" + }, + ":isle_of_man:": { + "category": "Flags", + "name": "flag: Isle of Man", + "unicode": "1f1ee-1f1f2" + }, + ":israel:": { + "category": "Flags", + "name": "flag: Israel", + "unicode": "1f1ee-1f1f1" + }, + ":it:": { + "category": "Flags", + "name": "flag: Italy", + "unicode": "1f1ee-1f1f9" + }, + ":izakaya_lantern:": { + "category": "Objects", + "name": "red paper lantern", + "unicode": "1f3ee" + }, + ":jack_o_lantern:": { + "category": "Activities", + "name": "jack-o-lantern", + "unicode": "1f383" + }, + ":jamaica:": { + "category": "Flags", + "name": "flag: Jamaica", + "unicode": "1f1ef-1f1f2" + }, + ":japan:": { + "category": "Travel & Places", + "name": "map of Japan", + "unicode": "1f5fe" + }, + ":japanese_castle:": { + "category": "Travel & Places", + "name": "Japanese castle", + "unicode": "1f3ef" + }, + ":japanese_goblin:": { + "category": "Smileys & Emotion", + "name": "goblin", + "unicode": "1f47a" + }, + ":japanese_ogre:": { + "category": "Smileys & Emotion", + "name": "ogre", + "unicode": "1f479" + }, + ":jar:": { + "category": "Food & Drink", + "name": "jar", + "unicode": "1fad9" + }, + ":jeans:": { + "category": "Objects", + "name": "jeans", + "unicode": "1f456" + }, + ":jellyfish:": { + "category": "Animals & Nature", + "name": "jellyfish", + "unicode": "1fabc" + }, + ":jersey:": { + "category": "Flags", + "name": "flag: Jersey", + "unicode": "1f1ef-1f1ea" + }, + ":jigsaw:": { + "category": "Activities", + "name": "puzzle piece", + "unicode": "1f9e9" + }, + ":jordan:": { + "category": "Flags", + "name": "flag: Jordan", + "unicode": "1f1ef-1f1f4" + }, + ":joy:": { + "category": "Smileys & Emotion", + "name": "face with tears of joy", + "unicode": "1f602" + }, + ":joy_cat:": { + "category": "Smileys & Emotion", + "name": "cat with tears of joy", + "unicode": "1f639" + }, + ":joystick:": { + "category": "Activities", + "name": "joystick", + "unicode": "1f579", + "unicode_alt": "1f579-fe0f" + }, + ":jp:": { + "category": "Flags", + "name": "flag: Japan", + "unicode": "1f1ef-1f1f5" + }, + ":judge:": { + "category": "People & Body", + "name": "judge", + "unicode": "1f9d1-2696", + "unicode_alt": "1f9d1-200d-2696-fe0f" + }, + ":juggling_person:": { + "category": "People & Body", + "name": "person juggling", + "unicode": "1f939" + }, + ":kaaba:": { + "category": "Travel & Places", + "name": "kaaba", + "unicode": "1f54b" + }, + ":kangaroo:": { + "category": "Animals & Nature", + "name": "kangaroo", + "unicode": "1f998" + }, + ":kazakhstan:": { + "category": "Flags", + "name": "flag: Kazakhstan", + "unicode": "1f1f0-1f1ff" + }, + ":kenya:": { + "category": "Flags", + "name": "flag: Kenya", + "unicode": "1f1f0-1f1ea" + }, + ":key:": { + "category": "Objects", + "name": "key", + "unicode": "1f511" + }, + ":keyboard:": { + "category": "Objects", + "name": "keyboard", + "unicode": "2328", + "unicode_alt": "2328-fe0f" + }, + ":keycap_ten:": { + "category": "Symbols", + "name": "keycap: 10", + "unicode": "1f51f" + }, + ":khanda:": { + "category": "Symbols", + "name": "khanda", + "unicode": "1faaf" + }, + ":kick_scooter:": { + "category": "Travel & Places", + "name": "kick scooter", + "unicode": "1f6f4" + }, + ":kimono:": { + "category": "Objects", + "name": "kimono", + "unicode": "1f458" + }, + ":kiribati:": { + "category": "Flags", + "name": "flag: Kiribati", + "unicode": "1f1f0-1f1ee" + }, + ":kiss:": { + "category": "Smileys & Emotion", + "name": "kiss mark", + "unicode": "1f48b" + }, + ":kissing:": { + "category": "Smileys & Emotion", + "name": "kissing face", + "unicode": "1f617" + }, + ":kissing_cat:": { + "category": "Smileys & Emotion", + "name": "kissing cat", + "unicode": "1f63d" + }, + ":kissing_closed_eyes:": { + "category": "Smileys & Emotion", + "name": "kissing face with closed eyes", + "unicode": "1f61a" + }, + ":kissing_heart:": { + "category": "Smileys & Emotion", + "name": "face blowing a kiss", + "unicode": "1f618" + }, + ":kissing_smiling_eyes:": { + "category": "Smileys & Emotion", + "name": "kissing face with smiling eyes", + "unicode": "1f619" + }, + ":kite:": { + "category": "Activities", + "name": "kite", + "unicode": "1fa81" + }, + ":kiwi_fruit:": { + "category": "Food & Drink", + "name": "kiwi fruit", + "unicode": "1f95d" + }, + ":kneeling_man:": { + "category": "People & Body", + "name": "man kneeling", + "unicode": "1f9ce-2642", + "unicode_alt": "1f9ce-200d-2642-fe0f" + }, + ":kneeling_person:": { + "category": "People & Body", + "name": "person kneeling", + "unicode": "1f9ce" + }, + ":kneeling_woman:": { + "category": "People & Body", + "name": "woman kneeling", + "unicode": "1f9ce-2640", + "unicode_alt": "1f9ce-200d-2640-fe0f" + }, + ":knot:": { + "category": "Activities", + "name": "knot", + "unicode": "1faa2" + }, + ":koala:": { + "category": "Animals & Nature", + "name": "koala", + "unicode": "1f428" + }, + ":koko:": { + "category": "Symbols", + "name": "Japanese \u201chere\u201d button", + "unicode": "1f201" + }, + ":kosovo:": { + "category": "Flags", + "name": "flag: Kosovo", + "unicode": "1f1fd-1f1f0" + }, + ":kr:": { + "category": "Flags", + "name": "flag: South Korea", + "unicode": "1f1f0-1f1f7" + }, + ":kuwait:": { + "category": "Flags", + "name": "flag: Kuwait", + "unicode": "1f1f0-1f1fc" + }, + ":kyrgyzstan:": { + "category": "Flags", + "name": "flag: Kyrgyzstan", + "unicode": "1f1f0-1f1ec" + }, + ":lab_coat:": { + "category": "Objects", + "name": "lab coat", + "unicode": "1f97c" + }, + ":label:": { + "category": "Objects", + "name": "label", + "unicode": "1f3f7", + "unicode_alt": "1f3f7-fe0f" + }, + ":lacrosse:": { + "category": "Activities", + "name": "lacrosse", + "unicode": "1f94d" + }, + ":ladder:": { + "category": "Objects", + "name": "ladder", + "unicode": "1fa9c" + }, + ":lady_beetle:": { + "category": "Animals & Nature", + "name": "lady beetle", + "unicode": "1f41e" + }, + ":laos:": { + "category": "Flags", + "name": "flag: Laos", + "unicode": "1f1f1-1f1e6" + }, + ":large_blue_circle:": { + "category": "Symbols", + "name": "blue circle", + "unicode": "1f535" + }, + ":large_blue_diamond:": { + "category": "Symbols", + "name": "large blue diamond", + "unicode": "1f537" + }, + ":large_orange_diamond:": { + "category": "Symbols", + "name": "large orange diamond", + "unicode": "1f536" + }, + ":last_quarter_moon:": { + "category": "Travel & Places", + "name": "last quarter moon", + "unicode": "1f317" + }, + ":last_quarter_moon_with_face:": { + "category": "Travel & Places", + "name": "last quarter moon face", + "unicode": "1f31c" + }, + ":latin_cross:": { + "category": "Symbols", + "name": "latin cross", + "unicode": "271d", + "unicode_alt": "271d-fe0f" + }, + ":latvia:": { + "category": "Flags", + "name": "flag: Latvia", + "unicode": "1f1f1-1f1fb" + }, + ":laughing:": { + "category": "Smileys & Emotion", + "name": "grinning squinting face", + "unicode": "1f606" + }, + ":leafy_green:": { + "category": "Food & Drink", + "name": "leafy green", + "unicode": "1f96c" + }, + ":leaves:": { + "category": "Animals & Nature", + "name": "leaf fluttering in wind", + "unicode": "1f343" + }, + ":lebanon:": { + "category": "Flags", + "name": "flag: Lebanon", + "unicode": "1f1f1-1f1e7" + }, + ":ledger:": { + "category": "Objects", + "name": "ledger", + "unicode": "1f4d2" + }, + ":left_luggage:": { + "category": "Symbols", + "name": "left luggage", + "unicode": "1f6c5" + }, + ":left_right_arrow:": { + "category": "Symbols", + "name": "left-right arrow", + "unicode": "2194", + "unicode_alt": "2194-fe0f" + }, + ":left_speech_bubble:": { + "category": "Smileys & Emotion", + "name": "left speech bubble", + "unicode": "1f5e8", + "unicode_alt": "1f5e8-fe0f" + }, + ":leftwards_arrow_with_hook:": { + "category": "Symbols", + "name": "right arrow curving left", + "unicode": "21a9", + "unicode_alt": "21a9-fe0f" + }, + ":leftwards_hand:": { + "category": "People & Body", + "name": "leftwards hand", + "unicode": "1faf2" + }, + ":leftwards_pushing_hand:": { + "category": "People & Body", + "name": "leftwards pushing hand", + "unicode": "1faf7" + }, + ":leg:": { + "category": "People & Body", + "name": "leg", + "unicode": "1f9b5" + }, + ":lemon:": { + "category": "Food & Drink", + "name": "lemon", + "unicode": "1f34b" + }, + ":leo:": { + "category": "Symbols", + "name": "Leo", + "unicode": "264c" + }, + ":leopard:": { + "category": "Animals & Nature", + "name": "leopard", + "unicode": "1f406" + }, + ":lesotho:": { + "category": "Flags", + "name": "flag: Lesotho", + "unicode": "1f1f1-1f1f8" + }, + ":level_slider:": { + "category": "Objects", + "name": "level slider", + "unicode": "1f39a", + "unicode_alt": "1f39a-fe0f" + }, + ":liberia:": { + "category": "Flags", + "name": "flag: Liberia", + "unicode": "1f1f1-1f1f7" + }, + ":libra:": { + "category": "Symbols", + "name": "Libra", + "unicode": "264e" + }, + ":libya:": { + "category": "Flags", + "name": "flag: Libya", + "unicode": "1f1f1-1f1fe" + }, + ":liechtenstein:": { + "category": "Flags", + "name": "flag: Liechtenstein", + "unicode": "1f1f1-1f1ee" + }, + ":light_blue_heart:": { + "category": "Smileys & Emotion", + "name": "light blue heart", + "unicode": "1fa75" + }, + ":light_rail:": { + "category": "Travel & Places", + "name": "light rail", + "unicode": "1f688" + }, + ":link:": { + "category": "Objects", + "name": "link", + "unicode": "1f517" + }, + ":lion:": { + "category": "Animals & Nature", + "name": "lion", + "unicode": "1f981" + }, + ":lips:": { + "category": "People & Body", + "name": "mouth", + "unicode": "1f444" + }, + ":lipstick:": { + "category": "Objects", + "name": "lipstick", + "unicode": "1f484" + }, + ":lithuania:": { + "category": "Flags", + "name": "flag: Lithuania", + "unicode": "1f1f1-1f1f9" + }, + ":lizard:": { + "category": "Animals & Nature", + "name": "lizard", + "unicode": "1f98e" + }, + ":llama:": { + "category": "Animals & Nature", + "name": "llama", + "unicode": "1f999" + }, + ":lobster:": { + "category": "Food & Drink", + "name": "lobster", + "unicode": "1f99e" + }, + ":lock:": { + "category": "Objects", + "name": "locked", + "unicode": "1f512" + }, + ":lock_with_ink_pen:": { + "category": "Objects", + "name": "locked with pen", + "unicode": "1f50f" + }, + ":lollipop:": { + "category": "Food & Drink", + "name": "lollipop", + "unicode": "1f36d" + }, + ":long_drum:": { + "category": "Objects", + "name": "long drum", + "unicode": "1fa98" + }, + ":loop:": { + "category": "Symbols", + "name": "double curly loop", + "unicode": "27bf" + }, + ":lotion_bottle:": { + "category": "Objects", + "name": "lotion bottle", + "unicode": "1f9f4" + }, + ":lotus:": { + "category": "Animals & Nature", + "name": "lotus", + "unicode": "1fab7" + }, + ":lotus_position:": { + "category": "People & Body", + "name": "person in lotus position", + "unicode": "1f9d8" + }, + ":lotus_position_man:": { + "category": "People & Body", + "name": "man in lotus position", + "unicode": "1f9d8-2642", + "unicode_alt": "1f9d8-200d-2642-fe0f" + }, + ":lotus_position_woman:": { + "category": "People & Body", + "name": "woman in lotus position", + "unicode": "1f9d8-2640", + "unicode_alt": "1f9d8-200d-2640-fe0f" + }, + ":loud_sound:": { + "category": "Objects", + "name": "speaker high volume", + "unicode": "1f50a" + }, + ":loudspeaker:": { + "category": "Objects", + "name": "loudspeaker", + "unicode": "1f4e2" + }, + ":love_hotel:": { + "category": "Travel & Places", + "name": "love hotel", + "unicode": "1f3e9" + }, + ":love_letter:": { + "category": "Smileys & Emotion", + "name": "love letter", + "unicode": "1f48c" + }, + ":love_you_gesture:": { + "category": "People & Body", + "name": "love-you gesture", + "unicode": "1f91f" + }, + ":low_battery:": { + "category": "Objects", + "name": "low battery", + "unicode": "1faab" + }, + ":low_brightness:": { + "category": "Symbols", + "name": "dim button", + "unicode": "1f505" + }, + ":luggage:": { + "category": "Travel & Places", + "name": "luggage", + "unicode": "1f9f3" + }, + ":lungs:": { + "category": "People & Body", + "name": "lungs", + "unicode": "1fac1" + }, + ":luxembourg:": { + "category": "Flags", + "name": "flag: Luxembourg", + "unicode": "1f1f1-1f1fa" + }, + ":lying_face:": { + "category": "Smileys & Emotion", + "name": "lying face", + "unicode": "1f925" + }, + ":m:": { + "category": "Symbols", + "name": "circled M", + "unicode": "24c2", + "unicode_alt": "24c2-fe0f" + }, + ":macau:": { + "category": "Flags", + "name": "flag: Macao SAR China", + "unicode": "1f1f2-1f1f4" + }, + ":macedonia:": { + "category": "Flags", + "name": "flag: North Macedonia", + "unicode": "1f1f2-1f1f0" + }, + ":madagascar:": { + "category": "Flags", + "name": "flag: Madagascar", + "unicode": "1f1f2-1f1ec" + }, + ":mag:": { + "category": "Objects", + "name": "magnifying glass tilted left", + "unicode": "1f50d" + }, + ":mag_right:": { + "category": "Objects", + "name": "magnifying glass tilted right", + "unicode": "1f50e" + }, + ":mage:": { + "category": "People & Body", + "name": "mage", + "unicode": "1f9d9" + }, + ":mage_man:": { + "category": "People & Body", + "name": "man mage", + "unicode": "1f9d9-2642", + "unicode_alt": "1f9d9-200d-2642-fe0f" + }, + ":mage_woman:": { + "category": "People & Body", + "name": "woman mage", + "unicode": "1f9d9-2640", + "unicode_alt": "1f9d9-200d-2640-fe0f" + }, + ":magic_wand:": { + "category": "Activities", + "name": "magic wand", + "unicode": "1fa84" + }, + ":magnet:": { + "category": "Objects", + "name": "magnet", + "unicode": "1f9f2" + }, + ":mahjong:": { + "category": "Activities", + "name": "mahjong red dragon", + "unicode": "1f004" + }, + ":mailbox:": { + "category": "Objects", + "name": "closed mailbox with raised flag", + "unicode": "1f4eb" + }, + ":mailbox_closed:": { + "category": "Objects", + "name": "closed mailbox with lowered flag", + "unicode": "1f4ea" + }, + ":mailbox_with_mail:": { + "category": "Objects", + "name": "open mailbox with raised flag", + "unicode": "1f4ec" + }, + ":mailbox_with_no_mail:": { + "category": "Objects", + "name": "open mailbox with lowered flag", + "unicode": "1f4ed" + }, + ":malawi:": { + "category": "Flags", + "name": "flag: Malawi", + "unicode": "1f1f2-1f1fc" + }, + ":malaysia:": { + "category": "Flags", + "name": "flag: Malaysia", + "unicode": "1f1f2-1f1fe" + }, + ":maldives:": { + "category": "Flags", + "name": "flag: Maldives", + "unicode": "1f1f2-1f1fb" + }, + ":male_detective:": { + "category": "People & Body", + "name": "man detective", + "unicode": "1f575-2642", + "unicode_alt": "1f575-fe0f-200d-2642-fe0f" + }, + ":male_sign:": { + "category": "Symbols", + "name": "male sign", + "unicode": "2642", + "unicode_alt": "2642-fe0f" + }, + ":mali:": { + "category": "Flags", + "name": "flag: Mali", + "unicode": "1f1f2-1f1f1" + }, + ":malta:": { + "category": "Flags", + "name": "flag: Malta", + "unicode": "1f1f2-1f1f9" + }, + ":mammoth:": { + "category": "Animals & Nature", + "name": "mammoth", + "unicode": "1f9a3" + }, + ":man:": { + "category": "People & Body", + "name": "man", + "unicode": "1f468" + }, + ":man_artist:": { + "category": "People & Body", + "name": "man artist", + "unicode": "1f468-1f3a8", + "unicode_alt": "1f468-200d-1f3a8" + }, + ":man_astronaut:": { + "category": "People & Body", + "name": "man astronaut", + "unicode": "1f468-1f680", + "unicode_alt": "1f468-200d-1f680" + }, + ":man_beard:": { + "category": "People & Body", + "name": "man: beard", + "unicode": "1f9d4-2642", + "unicode_alt": "1f9d4-200d-2642-fe0f" + }, + ":man_cartwheeling:": { + "category": "People & Body", + "name": "man cartwheeling", + "unicode": "1f938-2642", + "unicode_alt": "1f938-200d-2642-fe0f" + }, + ":man_cook:": { + "category": "People & Body", + "name": "man cook", + "unicode": "1f468-1f373", + "unicode_alt": "1f468-200d-1f373" + }, + ":man_dancing:": { + "category": "People & Body", + "name": "man dancing", + "unicode": "1f57a" + }, + ":man_facepalming:": { + "category": "People & Body", + "name": "man facepalming", + "unicode": "1f926-2642", + "unicode_alt": "1f926-200d-2642-fe0f" + }, + ":man_factory_worker:": { + "category": "People & Body", + "name": "man factory worker", + "unicode": "1f468-1f3ed", + "unicode_alt": "1f468-200d-1f3ed" + }, + ":man_farmer:": { + "category": "People & Body", + "name": "man farmer", + "unicode": "1f468-1f33e", + "unicode_alt": "1f468-200d-1f33e" + }, + ":man_feeding_baby:": { + "category": "People & Body", + "name": "man feeding baby", + "unicode": "1f468-1f37c", + "unicode_alt": "1f468-200d-1f37c" + }, + ":man_firefighter:": { + "category": "People & Body", + "name": "man firefighter", + "unicode": "1f468-1f692", + "unicode_alt": "1f468-200d-1f692" + }, + ":man_health_worker:": { + "category": "People & Body", + "name": "man health worker", + "unicode": "1f468-2695", + "unicode_alt": "1f468-200d-2695-fe0f" + }, + ":man_in_manual_wheelchair:": { + "category": "People & Body", + "name": "man in manual wheelchair", + "unicode": "1f468-1f9bd", + "unicode_alt": "1f468-200d-1f9bd" + }, + ":man_in_motorized_wheelchair:": { + "category": "People & Body", + "name": "man in motorized wheelchair", + "unicode": "1f468-1f9bc", + "unicode_alt": "1f468-200d-1f9bc" + }, + ":man_in_tuxedo:": { + "category": "People & Body", + "name": "man in tuxedo", + "unicode": "1f935-2642", + "unicode_alt": "1f935-200d-2642-fe0f" + }, + ":man_judge:": { + "category": "People & Body", + "name": "man judge", + "unicode": "1f468-2696", + "unicode_alt": "1f468-200d-2696-fe0f" + }, + ":man_juggling:": { + "category": "People & Body", + "name": "man juggling", + "unicode": "1f939-2642", + "unicode_alt": "1f939-200d-2642-fe0f" + }, + ":man_mechanic:": { + "category": "People & Body", + "name": "man mechanic", + "unicode": "1f468-1f527", + "unicode_alt": "1f468-200d-1f527" + }, + ":man_office_worker:": { + "category": "People & Body", + "name": "man office worker", + "unicode": "1f468-1f4bc", + "unicode_alt": "1f468-200d-1f4bc" + }, + ":man_pilot:": { + "category": "People & Body", + "name": "man pilot", + "unicode": "1f468-2708", + "unicode_alt": "1f468-200d-2708-fe0f" + }, + ":man_playing_handball:": { + "category": "People & Body", + "name": "man playing handball", + "unicode": "1f93e-2642", + "unicode_alt": "1f93e-200d-2642-fe0f" + }, + ":man_playing_water_polo:": { + "category": "People & Body", + "name": "man playing water polo", + "unicode": "1f93d-2642", + "unicode_alt": "1f93d-200d-2642-fe0f" + }, + ":man_scientist:": { + "category": "People & Body", + "name": "man scientist", + "unicode": "1f468-1f52c", + "unicode_alt": "1f468-200d-1f52c" + }, + ":man_shrugging:": { + "category": "People & Body", + "name": "man shrugging", + "unicode": "1f937-2642", + "unicode_alt": "1f937-200d-2642-fe0f" + }, + ":man_singer:": { + "category": "People & Body", + "name": "man singer", + "unicode": "1f468-1f3a4", + "unicode_alt": "1f468-200d-1f3a4" + }, + ":man_student:": { + "category": "People & Body", + "name": "man student", + "unicode": "1f468-1f393", + "unicode_alt": "1f468-200d-1f393" + }, + ":man_teacher:": { + "category": "People & Body", + "name": "man teacher", + "unicode": "1f468-1f3eb", + "unicode_alt": "1f468-200d-1f3eb" + }, + ":man_technologist:": { + "category": "People & Body", + "name": "man technologist", + "unicode": "1f468-1f4bb", + "unicode_alt": "1f468-200d-1f4bb" + }, + ":man_with_gua_pi_mao:": { + "category": "People & Body", + "name": "person with skullcap", + "unicode": "1f472" + }, + ":man_with_probing_cane:": { + "category": "People & Body", + "name": "man with white cane", + "unicode": "1f468-1f9af", + "unicode_alt": "1f468-200d-1f9af" + }, + ":man_with_turban:": { + "category": "People & Body", + "name": "man wearing turban", + "unicode": "1f473-2642", + "unicode_alt": "1f473-200d-2642-fe0f" + }, + ":man_with_veil:": { + "category": "People & Body", + "name": "man with veil", + "unicode": "1f470-2642", + "unicode_alt": "1f470-200d-2642-fe0f" + }, + ":mango:": { + "category": "Food & Drink", + "name": "mango", + "unicode": "1f96d" + }, + ":mans_shoe:": { + "category": "Objects", + "name": "man\u2019s shoe", + "unicode": "1f45e" + }, + ":mantelpiece_clock:": { + "category": "Travel & Places", + "name": "mantelpiece clock", + "unicode": "1f570", + "unicode_alt": "1f570-fe0f" + }, + ":manual_wheelchair:": { + "category": "Travel & Places", + "name": "manual wheelchair", + "unicode": "1f9bd" + }, + ":maple_leaf:": { + "category": "Animals & Nature", + "name": "maple leaf", + "unicode": "1f341" + }, + ":maracas:": { + "category": "Objects", + "name": "maracas", + "unicode": "1fa87" + }, + ":marshall_islands:": { + "category": "Flags", + "name": "flag: Marshall Islands", + "unicode": "1f1f2-1f1ed" + }, + ":martial_arts_uniform:": { + "category": "Activities", + "name": "martial arts uniform", + "unicode": "1f94b" + }, + ":martinique:": { + "category": "Flags", + "name": "flag: Martinique", + "unicode": "1f1f2-1f1f6" + }, + ":mask:": { + "category": "Smileys & Emotion", + "name": "face with medical mask", + "unicode": "1f637" + }, + ":massage:": { + "category": "People & Body", + "name": "person getting massage", + "unicode": "1f486" + }, + ":massage_man:": { + "category": "People & Body", + "name": "man getting massage", + "unicode": "1f486-2642", + "unicode_alt": "1f486-200d-2642-fe0f" + }, + ":massage_woman:": { + "category": "People & Body", + "name": "woman getting massage", + "unicode": "1f486-2640", + "unicode_alt": "1f486-200d-2640-fe0f" + }, + ":mate:": { + "category": "Food & Drink", + "name": "mate", + "unicode": "1f9c9" + }, + ":mauritania:": { + "category": "Flags", + "name": "flag: Mauritania", + "unicode": "1f1f2-1f1f7" + }, + ":mauritius:": { + "category": "Flags", + "name": "flag: Mauritius", + "unicode": "1f1f2-1f1fa" + }, + ":mayotte:": { + "category": "Flags", + "name": "flag: Mayotte", + "unicode": "1f1fe-1f1f9" + }, + ":meat_on_bone:": { + "category": "Food & Drink", + "name": "meat on bone", + "unicode": "1f356" + }, + ":mechanic:": { + "category": "People & Body", + "name": "mechanic", + "unicode": "1f9d1-1f527", + "unicode_alt": "1f9d1-200d-1f527" + }, + ":mechanical_arm:": { + "category": "People & Body", + "name": "mechanical arm", + "unicode": "1f9be" + }, + ":mechanical_leg:": { + "category": "People & Body", + "name": "mechanical leg", + "unicode": "1f9bf" + }, + ":medal_military:": { + "category": "Activities", + "name": "military medal", + "unicode": "1f396", + "unicode_alt": "1f396-fe0f" + }, + ":medal_sports:": { + "category": "Activities", + "name": "sports medal", + "unicode": "1f3c5" + }, + ":medical_symbol:": { + "category": "Symbols", + "name": "medical symbol", + "unicode": "2695", + "unicode_alt": "2695-fe0f" + }, + ":mega:": { + "category": "Objects", + "name": "megaphone", + "unicode": "1f4e3" + }, + ":melon:": { + "category": "Food & Drink", + "name": "melon", + "unicode": "1f348" + }, + ":melting_face:": { + "category": "Smileys & Emotion", + "name": "melting face", + "unicode": "1fae0" + }, + ":memo:": { + "category": "Objects", + "name": "memo", + "unicode": "1f4dd" + }, + ":men_wrestling:": { + "category": "People & Body", + "name": "men wrestling", + "unicode": "1f93c-2642", + "unicode_alt": "1f93c-200d-2642-fe0f" + }, + ":mending_heart:": { + "category": "Smileys & Emotion", + "name": "mending heart", + "unicode": "2764-1fa79", + "unicode_alt": "2764-fe0f-200d-1fa79" + }, + ":menorah:": { + "category": "Symbols", + "name": "menorah", + "unicode": "1f54e" + }, + ":mens:": { + "category": "Symbols", + "name": "men\u2019s room", + "unicode": "1f6b9" + }, + ":mermaid:": { + "category": "People & Body", + "name": "mermaid", + "unicode": "1f9dc-2640", + "unicode_alt": "1f9dc-200d-2640-fe0f" + }, + ":merman:": { + "category": "People & Body", + "name": "merman", + "unicode": "1f9dc-2642", + "unicode_alt": "1f9dc-200d-2642-fe0f" + }, + ":merperson:": { + "category": "People & Body", + "name": "merperson", + "unicode": "1f9dc" + }, + ":metal:": { + "category": "People & Body", + "name": "sign of the horns", + "unicode": "1f918" + }, + ":metro:": { + "category": "Travel & Places", + "name": "metro", + "unicode": "1f687" + }, + ":mexico:": { + "category": "Flags", + "name": "flag: Mexico", + "unicode": "1f1f2-1f1fd" + }, + ":microbe:": { + "category": "Animals & Nature", + "name": "microbe", + "unicode": "1f9a0" + }, + ":micronesia:": { + "category": "Flags", + "name": "flag: Micronesia", + "unicode": "1f1eb-1f1f2" + }, + ":microphone:": { + "category": "Objects", + "name": "microphone", + "unicode": "1f3a4" + }, + ":microscope:": { + "category": "Objects", + "name": "microscope", + "unicode": "1f52c" + }, + ":middle_finger:": { + "category": "People & Body", + "name": "middle finger", + "unicode": "1f595" + }, + ":military_helmet:": { + "category": "Objects", + "name": "military helmet", + "unicode": "1fa96" + }, + ":milk_glass:": { + "category": "Food & Drink", + "name": "glass of milk", + "unicode": "1f95b" + }, + ":milky_way:": { + "category": "Travel & Places", + "name": "milky way", + "unicode": "1f30c" + }, + ":minibus:": { + "category": "Travel & Places", + "name": "minibus", + "unicode": "1f690" + }, + ":minidisc:": { + "category": "Objects", + "name": "computer disk", + "unicode": "1f4bd" + }, + ":mirror:": { + "category": "Objects", + "name": "mirror", + "unicode": "1fa9e" + }, + ":mirror_ball:": { + "category": "Activities", + "name": "mirror ball", + "unicode": "1faa9" + }, + ":mobile_phone_off:": { + "category": "Symbols", + "name": "mobile phone off", + "unicode": "1f4f4" + }, + ":moldova:": { + "category": "Flags", + "name": "flag: Moldova", + "unicode": "1f1f2-1f1e9" + }, + ":monaco:": { + "category": "Flags", + "name": "flag: Monaco", + "unicode": "1f1f2-1f1e8" + }, + ":money_mouth_face:": { + "category": "Smileys & Emotion", + "name": "money-mouth face", + "unicode": "1f911" + }, + ":money_with_wings:": { + "category": "Objects", + "name": "money with wings", + "unicode": "1f4b8" + }, + ":moneybag:": { + "category": "Objects", + "name": "money bag", + "unicode": "1f4b0" + }, + ":mongolia:": { + "category": "Flags", + "name": "flag: Mongolia", + "unicode": "1f1f2-1f1f3" + }, + ":monkey:": { + "category": "Animals & Nature", + "name": "monkey", + "unicode": "1f412" + }, + ":monkey_face:": { + "category": "Animals & Nature", + "name": "monkey face", + "unicode": "1f435" + }, + ":monocle_face:": { + "category": "Smileys & Emotion", + "name": "face with monocle", + "unicode": "1f9d0" + }, + ":monorail:": { + "category": "Travel & Places", + "name": "monorail", + "unicode": "1f69d" + }, + ":montenegro:": { + "category": "Flags", + "name": "flag: Montenegro", + "unicode": "1f1f2-1f1ea" + }, + ":montserrat:": { + "category": "Flags", + "name": "flag: Montserrat", + "unicode": "1f1f2-1f1f8" + }, + ":moon:": { + "category": "Travel & Places", + "name": "waxing gibbous moon", + "unicode": "1f314" + }, + ":moon_cake:": { + "category": "Food & Drink", + "name": "moon cake", + "unicode": "1f96e" + }, + ":moose:": { + "category": "Animals & Nature", + "name": "moose", + "unicode": "1face" + }, + ":morocco:": { + "category": "Flags", + "name": "flag: Morocco", + "unicode": "1f1f2-1f1e6" + }, + ":mortar_board:": { + "category": "Objects", + "name": "graduation cap", + "unicode": "1f393" + }, + ":mosque:": { + "category": "Travel & Places", + "name": "mosque", + "unicode": "1f54c" + }, + ":mosquito:": { + "category": "Animals & Nature", + "name": "mosquito", + "unicode": "1f99f" + }, + ":motor_boat:": { + "category": "Travel & Places", + "name": "motor boat", + "unicode": "1f6e5", + "unicode_alt": "1f6e5-fe0f" + }, + ":motor_scooter:": { + "category": "Travel & Places", + "name": "motor scooter", + "unicode": "1f6f5" + }, + ":motorcycle:": { + "category": "Travel & Places", + "name": "motorcycle", + "unicode": "1f3cd", + "unicode_alt": "1f3cd-fe0f" + }, + ":motorized_wheelchair:": { + "category": "Travel & Places", + "name": "motorized wheelchair", + "unicode": "1f9bc" + }, + ":motorway:": { + "category": "Travel & Places", + "name": "motorway", + "unicode": "1f6e3", + "unicode_alt": "1f6e3-fe0f" + }, + ":mount_fuji:": { + "category": "Travel & Places", + "name": "mount fuji", + "unicode": "1f5fb" + }, + ":mountain:": { + "category": "Travel & Places", + "name": "mountain", + "unicode": "26f0", + "unicode_alt": "26f0-fe0f" + }, + ":mountain_bicyclist:": { + "category": "People & Body", + "name": "person mountain biking", + "unicode": "1f6b5" + }, + ":mountain_biking_man:": { + "category": "People & Body", + "name": "man mountain biking", + "unicode": "1f6b5-2642", + "unicode_alt": "1f6b5-200d-2642-fe0f" + }, + ":mountain_biking_woman:": { + "category": "People & Body", + "name": "woman mountain biking", + "unicode": "1f6b5-2640", + "unicode_alt": "1f6b5-200d-2640-fe0f" + }, + ":mountain_cableway:": { + "category": "Travel & Places", + "name": "mountain cableway", + "unicode": "1f6a0" + }, + ":mountain_railway:": { + "category": "Travel & Places", + "name": "mountain railway", + "unicode": "1f69e" + }, + ":mountain_snow:": { + "category": "Travel & Places", + "name": "snow-capped mountain", + "unicode": "1f3d4", + "unicode_alt": "1f3d4-fe0f" + }, + ":mouse2:": { + "category": "Animals & Nature", + "name": "mouse", + "unicode": "1f401" + }, + ":mouse:": { + "category": "Animals & Nature", + "name": "mouse face", + "unicode": "1f42d" + }, + ":mouse_trap:": { + "category": "Objects", + "name": "mouse trap", + "unicode": "1faa4" + }, + ":movie_camera:": { + "category": "Objects", + "name": "movie camera", + "unicode": "1f3a5" + }, + ":moyai:": { + "category": "Objects", + "name": "moai", + "unicode": "1f5ff" + }, + ":mozambique:": { + "category": "Flags", + "name": "flag: Mozambique", + "unicode": "1f1f2-1f1ff" + }, + ":mrs_claus:": { + "category": "People & Body", + "name": "Mrs. Claus", + "unicode": "1f936" + }, + ":muscle:": { + "category": "People & Body", + "name": "flexed biceps", + "unicode": "1f4aa" + }, + ":mushroom:": { + "category": "Animals & Nature", + "name": "mushroom", + "unicode": "1f344" + }, + ":musical_keyboard:": { + "category": "Objects", + "name": "musical keyboard", + "unicode": "1f3b9" + }, + ":musical_note:": { + "category": "Objects", + "name": "musical note", + "unicode": "1f3b5" + }, + ":musical_score:": { + "category": "Objects", + "name": "musical score", + "unicode": "1f3bc" + }, + ":mute:": { + "category": "Objects", + "name": "muted speaker", + "unicode": "1f507" + }, + ":mx_claus:": { + "category": "People & Body", + "name": "mx claus", + "unicode": "1f9d1-1f384", + "unicode_alt": "1f9d1-200d-1f384" + }, + ":myanmar:": { + "category": "Flags", + "name": "flag: Myanmar (Burma)", + "unicode": "1f1f2-1f1f2" + }, + ":nail_care:": { + "category": "People & Body", + "name": "nail polish", + "unicode": "1f485" + }, + ":name_badge:": { + "category": "Symbols", + "name": "name badge", + "unicode": "1f4db" + }, + ":namibia:": { + "category": "Flags", + "name": "flag: Namibia", + "unicode": "1f1f3-1f1e6" + }, + ":national_park:": { + "category": "Travel & Places", + "name": "national park", + "unicode": "1f3de", + "unicode_alt": "1f3de-fe0f" + }, + ":nauru:": { + "category": "Flags", + "name": "flag: Nauru", + "unicode": "1f1f3-1f1f7" + }, + ":nauseated_face:": { + "category": "Smileys & Emotion", + "name": "nauseated face", + "unicode": "1f922" + }, + ":nazar_amulet:": { + "category": "Objects", + "name": "nazar amulet", + "unicode": "1f9ff" + }, + ":necktie:": { + "category": "Objects", + "name": "necktie", + "unicode": "1f454" + }, + ":negative_squared_cross_mark:": { + "category": "Symbols", + "name": "cross mark button", + "unicode": "274e" + }, + ":nepal:": { + "category": "Flags", + "name": "flag: Nepal", + "unicode": "1f1f3-1f1f5" + }, + ":nerd_face:": { + "category": "Smileys & Emotion", + "name": "nerd face", + "unicode": "1f913" + }, + ":nest_with_eggs:": { + "category": "Animals & Nature", + "name": "nest with eggs", + "unicode": "1faba" + }, + ":nesting_dolls:": { + "category": "Activities", + "name": "nesting dolls", + "unicode": "1fa86" + }, + ":netherlands:": { + "category": "Flags", + "name": "flag: Netherlands", + "unicode": "1f1f3-1f1f1" + }, + ":neutral_face:": { + "category": "Smileys & Emotion", + "name": "neutral face", + "unicode": "1f610" + }, + ":new:": { + "category": "Symbols", + "name": "NEW button", + "unicode": "1f195" + }, + ":new_caledonia:": { + "category": "Flags", + "name": "flag: New Caledonia", + "unicode": "1f1f3-1f1e8" + }, + ":new_moon:": { + "category": "Travel & Places", + "name": "new moon", + "unicode": "1f311" + }, + ":new_moon_with_face:": { + "category": "Travel & Places", + "name": "new moon face", + "unicode": "1f31a" + }, + ":new_zealand:": { + "category": "Flags", + "name": "flag: New Zealand", + "unicode": "1f1f3-1f1ff" + }, + ":newspaper:": { + "category": "Objects", + "name": "newspaper", + "unicode": "1f4f0" + }, + ":newspaper_roll:": { + "category": "Objects", + "name": "rolled-up newspaper", + "unicode": "1f5de", + "unicode_alt": "1f5de-fe0f" + }, + ":next_track_button:": { + "category": "Symbols", + "name": "next track button", + "unicode": "23ed", + "unicode_alt": "23ed-fe0f" + }, + ":ng:": { + "category": "Symbols", + "name": "NG button", + "unicode": "1f196" + }, + ":nicaragua:": { + "category": "Flags", + "name": "flag: Nicaragua", + "unicode": "1f1f3-1f1ee" + }, + ":niger:": { + "category": "Flags", + "name": "flag: Niger", + "unicode": "1f1f3-1f1ea" + }, + ":nigeria:": { + "category": "Flags", + "name": "flag: Nigeria", + "unicode": "1f1f3-1f1ec" + }, + ":night_with_stars:": { + "category": "Travel & Places", + "name": "night with stars", + "unicode": "1f303" + }, + ":nine:": { + "category": "Symbols", + "name": "keycap: 9", + "unicode": "0039-20e3", + "unicode_alt": "0039-fe0f-20e3" + }, + ":ninja:": { + "category": "People & Body", + "name": "ninja", + "unicode": "1f977" + }, + ":niue:": { + "category": "Flags", + "name": "flag: Niue", + "unicode": "1f1f3-1f1fa" + }, + ":no_bell:": { + "category": "Objects", + "name": "bell with slash", + "unicode": "1f515" + }, + ":no_bicycles:": { + "category": "Symbols", + "name": "no bicycles", + "unicode": "1f6b3" + }, + ":no_entry:": { + "category": "Symbols", + "name": "no entry", + "unicode": "26d4" + }, + ":no_entry_sign:": { + "category": "Symbols", + "name": "prohibited", + "unicode": "1f6ab" + }, + ":no_good:": { + "category": "People & Body", + "name": "person gesturing NO", + "unicode": "1f645" + }, + ":no_good_man:": { + "category": "People & Body", + "name": "man gesturing NO", + "unicode": "1f645-2642", + "unicode_alt": "1f645-200d-2642-fe0f" + }, + ":no_good_woman:": { + "category": "People & Body", + "name": "woman gesturing NO", + "unicode": "1f645-2640", + "unicode_alt": "1f645-200d-2640-fe0f" + }, + ":no_mobile_phones:": { + "category": "Symbols", + "name": "no mobile phones", + "unicode": "1f4f5" + }, + ":no_mouth:": { + "category": "Smileys & Emotion", + "name": "face without mouth", + "unicode": "1f636" + }, + ":no_pedestrians:": { + "category": "Symbols", + "name": "no pedestrians", + "unicode": "1f6b7" + }, + ":no_smoking:": { + "category": "Symbols", + "name": "no smoking", + "unicode": "1f6ad" + }, + ":non-potable_water:": { + "category": "Symbols", + "name": "non-potable water", + "unicode": "1f6b1" + }, + ":norfolk_island:": { + "category": "Flags", + "name": "flag: Norfolk Island", + "unicode": "1f1f3-1f1eb" + }, + ":north_korea:": { + "category": "Flags", + "name": "flag: North Korea", + "unicode": "1f1f0-1f1f5" + }, + ":northern_mariana_islands:": { + "category": "Flags", + "name": "flag: Northern Mariana Islands", + "unicode": "1f1f2-1f1f5" + }, + ":norway:": { + "category": "Flags", + "name": "flag: Norway", + "unicode": "1f1f3-1f1f4" + }, + ":nose:": { + "category": "People & Body", + "name": "nose", + "unicode": "1f443" + }, + ":notebook:": { + "category": "Objects", + "name": "notebook", + "unicode": "1f4d3" + }, + ":notebook_with_decorative_cover:": { + "category": "Objects", + "name": "notebook with decorative cover", + "unicode": "1f4d4" + }, + ":notes:": { + "category": "Objects", + "name": "musical notes", + "unicode": "1f3b6" + }, + ":nut_and_bolt:": { + "category": "Objects", + "name": "nut and bolt", + "unicode": "1f529" + }, + ":o2:": { + "category": "Symbols", + "name": "O button (blood type)", + "unicode": "1f17e", + "unicode_alt": "1f17e-fe0f" + }, + ":o:": { + "category": "Symbols", + "name": "hollow red circle", + "unicode": "2b55" + }, + ":ocean:": { + "category": "Travel & Places", + "name": "water wave", + "unicode": "1f30a" + }, + ":octopus:": { + "category": "Animals & Nature", + "name": "octopus", + "unicode": "1f419" + }, + ":oden:": { + "category": "Food & Drink", + "name": "oden", + "unicode": "1f362" + }, + ":office:": { + "category": "Travel & Places", + "name": "office building", + "unicode": "1f3e2" + }, + ":office_worker:": { + "category": "People & Body", + "name": "office worker", + "unicode": "1f9d1-1f4bc", + "unicode_alt": "1f9d1-200d-1f4bc" + }, + ":oil_drum:": { + "category": "Travel & Places", + "name": "oil drum", + "unicode": "1f6e2", + "unicode_alt": "1f6e2-fe0f" + }, + ":ok:": { + "category": "Symbols", + "name": "OK button", + "unicode": "1f197" + }, + ":ok_hand:": { + "category": "People & Body", + "name": "OK hand", + "unicode": "1f44c" + }, + ":ok_man:": { + "category": "People & Body", + "name": "man gesturing OK", + "unicode": "1f646-2642", + "unicode_alt": "1f646-200d-2642-fe0f" + }, + ":ok_person:": { + "category": "People & Body", + "name": "person gesturing OK", + "unicode": "1f646" + }, + ":ok_woman:": { + "category": "People & Body", + "name": "woman gesturing OK", + "unicode": "1f646-2640", + "unicode_alt": "1f646-200d-2640-fe0f" + }, + ":old_key:": { + "category": "Objects", + "name": "old key", + "unicode": "1f5dd", + "unicode_alt": "1f5dd-fe0f" + }, + ":older_adult:": { + "category": "People & Body", + "name": "older person", + "unicode": "1f9d3" + }, + ":older_man:": { + "category": "People & Body", + "name": "old man", + "unicode": "1f474" + }, + ":older_woman:": { + "category": "People & Body", + "name": "old woman", + "unicode": "1f475" + }, + ":olive:": { + "category": "Food & Drink", + "name": "olive", + "unicode": "1fad2" + }, + ":om:": { + "category": "Symbols", + "name": "om", + "unicode": "1f549", + "unicode_alt": "1f549-fe0f" + }, + ":oman:": { + "category": "Flags", + "name": "flag: Oman", + "unicode": "1f1f4-1f1f2" + }, + ":on:": { + "category": "Symbols", + "name": "ON! arrow", + "unicode": "1f51b" + }, + ":oncoming_automobile:": { + "category": "Travel & Places", + "name": "oncoming automobile", + "unicode": "1f698" + }, + ":oncoming_bus:": { + "category": "Travel & Places", + "name": "oncoming bus", + "unicode": "1f68d" + }, + ":oncoming_police_car:": { + "category": "Travel & Places", + "name": "oncoming police car", + "unicode": "1f694" + }, + ":oncoming_taxi:": { + "category": "Travel & Places", + "name": "oncoming taxi", + "unicode": "1f696" + }, + ":one:": { + "category": "Symbols", + "name": "keycap: 1", + "unicode": "0031-20e3", + "unicode_alt": "0031-fe0f-20e3" + }, + ":one_piece_swimsuit:": { + "category": "Objects", + "name": "one-piece swimsuit", + "unicode": "1fa71" + }, + ":onion:": { + "category": "Food & Drink", + "name": "onion", + "unicode": "1f9c5" + }, + ":open_file_folder:": { + "category": "Objects", + "name": "open file folder", + "unicode": "1f4c2" + }, + ":open_hands:": { + "category": "People & Body", + "name": "open hands", + "unicode": "1f450" + }, + ":open_mouth:": { + "category": "Smileys & Emotion", + "name": "face with open mouth", + "unicode": "1f62e" + }, + ":open_umbrella:": { + "category": "Travel & Places", + "name": "umbrella", + "unicode": "2602", + "unicode_alt": "2602-fe0f" + }, + ":ophiuchus:": { + "category": "Symbols", + "name": "Ophiuchus", + "unicode": "26ce" + }, + ":orange_book:": { + "category": "Objects", + "name": "orange book", + "unicode": "1f4d9" + }, + ":orange_circle:": { + "category": "Symbols", + "name": "orange circle", + "unicode": "1f7e0" + }, + ":orange_heart:": { + "category": "Smileys & Emotion", + "name": "orange heart", + "unicode": "1f9e1" + }, + ":orange_square:": { + "category": "Symbols", + "name": "orange square", + "unicode": "1f7e7" + }, + ":orangutan:": { + "category": "Animals & Nature", + "name": "orangutan", + "unicode": "1f9a7" + }, + ":orthodox_cross:": { + "category": "Symbols", + "name": "orthodox cross", + "unicode": "2626", + "unicode_alt": "2626-fe0f" + }, + ":otter:": { + "category": "Animals & Nature", + "name": "otter", + "unicode": "1f9a6" + }, + ":outbox_tray:": { + "category": "Objects", + "name": "outbox tray", + "unicode": "1f4e4" + }, + ":owl:": { + "category": "Animals & Nature", + "name": "owl", + "unicode": "1f989" + }, + ":ox:": { + "category": "Animals & Nature", + "name": "ox", + "unicode": "1f402" + }, + ":oyster:": { + "category": "Food & Drink", + "name": "oyster", + "unicode": "1f9aa" + }, + ":package:": { + "category": "Objects", + "name": "package", + "unicode": "1f4e6" + }, + ":page_facing_up:": { + "category": "Objects", + "name": "page facing up", + "unicode": "1f4c4" + }, + ":page_with_curl:": { + "category": "Objects", + "name": "page with curl", + "unicode": "1f4c3" + }, + ":pager:": { + "category": "Objects", + "name": "pager", + "unicode": "1f4df" + }, + ":paintbrush:": { + "category": "Objects", + "name": "paintbrush", + "unicode": "1f58c", + "unicode_alt": "1f58c-fe0f" + }, + ":pakistan:": { + "category": "Flags", + "name": "flag: Pakistan", + "unicode": "1f1f5-1f1f0" + }, + ":palau:": { + "category": "Flags", + "name": "flag: Palau", + "unicode": "1f1f5-1f1fc" + }, + ":palestinian_territories:": { + "category": "Flags", + "name": "flag: Palestinian Territories", + "unicode": "1f1f5-1f1f8" + }, + ":palm_down_hand:": { + "category": "People & Body", + "name": "palm down hand", + "unicode": "1faf3" + }, + ":palm_tree:": { + "category": "Animals & Nature", + "name": "palm tree", + "unicode": "1f334" + }, + ":palm_up_hand:": { + "category": "People & Body", + "name": "palm up hand", + "unicode": "1faf4" + }, + ":palms_up_together:": { + "category": "People & Body", + "name": "palms up together", + "unicode": "1f932" + }, + ":panama:": { + "category": "Flags", + "name": "flag: Panama", + "unicode": "1f1f5-1f1e6" + }, + ":pancakes:": { + "category": "Food & Drink", + "name": "pancakes", + "unicode": "1f95e" + }, + ":panda_face:": { + "category": "Animals & Nature", + "name": "panda", + "unicode": "1f43c" + }, + ":paperclip:": { + "category": "Objects", + "name": "paperclip", + "unicode": "1f4ce" + }, + ":paperclips:": { + "category": "Objects", + "name": "linked paperclips", + "unicode": "1f587", + "unicode_alt": "1f587-fe0f" + }, + ":papua_new_guinea:": { + "category": "Flags", + "name": "flag: Papua New Guinea", + "unicode": "1f1f5-1f1ec" + }, + ":parachute:": { + "category": "Travel & Places", + "name": "parachute", + "unicode": "1fa82" + }, + ":paraguay:": { + "category": "Flags", + "name": "flag: Paraguay", + "unicode": "1f1f5-1f1fe" + }, + ":parasol_on_ground:": { + "category": "Travel & Places", + "name": "umbrella on ground", + "unicode": "26f1", + "unicode_alt": "26f1-fe0f" + }, + ":parking:": { + "category": "Symbols", + "name": "P button", + "unicode": "1f17f", + "unicode_alt": "1f17f-fe0f" + }, + ":parrot:": { + "category": "Animals & Nature", + "name": "parrot", + "unicode": "1f99c" + }, + ":part_alternation_mark:": { + "category": "Symbols", + "name": "part alternation mark", + "unicode": "303d", + "unicode_alt": "303d-fe0f" + }, + ":partly_sunny:": { + "category": "Travel & Places", + "name": "sun behind cloud", + "unicode": "26c5" + }, + ":partying_face:": { + "category": "Smileys & Emotion", + "name": "partying face", + "unicode": "1f973" + }, + ":passenger_ship:": { + "category": "Travel & Places", + "name": "passenger ship", + "unicode": "1f6f3", + "unicode_alt": "1f6f3-fe0f" + }, + ":passport_control:": { + "category": "Symbols", + "name": "passport control", + "unicode": "1f6c2" + }, + ":pause_button:": { + "category": "Symbols", + "name": "pause button", + "unicode": "23f8", + "unicode_alt": "23f8-fe0f" + }, + ":pea_pod:": { + "category": "Food & Drink", + "name": "pea pod", + "unicode": "1fadb" + }, + ":peace_symbol:": { + "category": "Symbols", + "name": "peace symbol", + "unicode": "262e", + "unicode_alt": "262e-fe0f" + }, + ":peach:": { + "category": "Food & Drink", + "name": "peach", + "unicode": "1f351" + }, + ":peacock:": { + "category": "Animals & Nature", + "name": "peacock", + "unicode": "1f99a" + }, + ":peanuts:": { + "category": "Food & Drink", + "name": "peanuts", + "unicode": "1f95c" + }, + ":pear:": { + "category": "Food & Drink", + "name": "pear", + "unicode": "1f350" + }, + ":pen:": { + "category": "Objects", + "name": "pen", + "unicode": "1f58a", + "unicode_alt": "1f58a-fe0f" + }, + ":pencil2:": { + "category": "Objects", + "name": "pencil", + "unicode": "270f", + "unicode_alt": "270f-fe0f" + }, + ":penguin:": { + "category": "Animals & Nature", + "name": "penguin", + "unicode": "1f427" + }, + ":pensive:": { + "category": "Smileys & Emotion", + "name": "pensive face", + "unicode": "1f614" + }, + ":people_holding_hands:": { + "category": "People & Body", + "name": "people holding hands", + "unicode": "1f9d1-1f91d-1f9d1", + "unicode_alt": "1f9d1-200d-1f91d-200d-1f9d1" + }, + ":people_hugging:": { + "category": "People & Body", + "name": "people hugging", + "unicode": "1fac2" + }, + ":performing_arts:": { + "category": "Activities", + "name": "performing arts", + "unicode": "1f3ad" + }, + ":persevere:": { + "category": "Smileys & Emotion", + "name": "persevering face", + "unicode": "1f623" + }, + ":person_bald:": { + "category": "People & Body", + "name": "person: bald", + "unicode": "1f9d1-1f9b2", + "unicode_alt": "1f9d1-200d-1f9b2" + }, + ":person_curly_hair:": { + "category": "People & Body", + "name": "person: curly hair", + "unicode": "1f9d1-1f9b1", + "unicode_alt": "1f9d1-200d-1f9b1" + }, + ":person_feeding_baby:": { + "category": "People & Body", + "name": "person feeding baby", + "unicode": "1f9d1-1f37c", + "unicode_alt": "1f9d1-200d-1f37c" + }, + ":person_fencing:": { + "category": "People & Body", + "name": "person fencing", + "unicode": "1f93a" + }, + ":person_in_manual_wheelchair:": { + "category": "People & Body", + "name": "person in manual wheelchair", + "unicode": "1f9d1-1f9bd", + "unicode_alt": "1f9d1-200d-1f9bd" + }, + ":person_in_motorized_wheelchair:": { + "category": "People & Body", + "name": "person in motorized wheelchair", + "unicode": "1f9d1-1f9bc", + "unicode_alt": "1f9d1-200d-1f9bc" + }, + ":person_in_tuxedo:": { + "category": "People & Body", + "name": "person in tuxedo", + "unicode": "1f935" + }, + ":person_red_hair:": { + "category": "People & Body", + "name": "person: red hair", + "unicode": "1f9d1-1f9b0", + "unicode_alt": "1f9d1-200d-1f9b0" + }, + ":person_white_hair:": { + "category": "People & Body", + "name": "person: white hair", + "unicode": "1f9d1-1f9b3", + "unicode_alt": "1f9d1-200d-1f9b3" + }, + ":person_with_crown:": { + "category": "People & Body", + "name": "person with crown", + "unicode": "1fac5" + }, + ":person_with_probing_cane:": { + "category": "People & Body", + "name": "person with white cane", + "unicode": "1f9d1-1f9af", + "unicode_alt": "1f9d1-200d-1f9af" + }, + ":person_with_turban:": { + "category": "People & Body", + "name": "person wearing turban", + "unicode": "1f473" + }, + ":person_with_veil:": { + "category": "People & Body", + "name": "person with veil", + "unicode": "1f470" + }, + ":peru:": { + "category": "Flags", + "name": "flag: Peru", + "unicode": "1f1f5-1f1ea" + }, + ":petri_dish:": { + "category": "Objects", + "name": "petri dish", + "unicode": "1f9eb" + }, + ":philippines:": { + "category": "Flags", + "name": "flag: Philippines", + "unicode": "1f1f5-1f1ed" + }, + ":phone:": { + "category": "Objects", + "name": "telephone", + "unicode": "260e", + "unicode_alt": "260e-fe0f" + }, + ":pick:": { + "category": "Objects", + "name": "pick", + "unicode": "26cf", + "unicode_alt": "26cf-fe0f" + }, + ":pickup_truck:": { + "category": "Travel & Places", + "name": "pickup truck", + "unicode": "1f6fb" + }, + ":pie:": { + "category": "Food & Drink", + "name": "pie", + "unicode": "1f967" + }, + ":pig2:": { + "category": "Animals & Nature", + "name": "pig", + "unicode": "1f416" + }, + ":pig:": { + "category": "Animals & Nature", + "name": "pig face", + "unicode": "1f437" + }, + ":pig_nose:": { + "category": "Animals & Nature", + "name": "pig nose", + "unicode": "1f43d" + }, + ":pill:": { + "category": "Objects", + "name": "pill", + "unicode": "1f48a" + }, + ":pilot:": { + "category": "People & Body", + "name": "pilot", + "unicode": "1f9d1-2708", + "unicode_alt": "1f9d1-200d-2708-fe0f" + }, + ":pinata:": { + "category": "Activities", + "name": "pi\u00f1ata", + "unicode": "1fa85" + }, + ":pinched_fingers:": { + "category": "People & Body", + "name": "pinched fingers", + "unicode": "1f90c" + }, + ":pinching_hand:": { + "category": "People & Body", + "name": "pinching hand", + "unicode": "1f90f" + }, + ":pineapple:": { + "category": "Food & Drink", + "name": "pineapple", + "unicode": "1f34d" + }, + ":ping_pong:": { + "category": "Activities", + "name": "ping pong", + "unicode": "1f3d3" + }, + ":pink_heart:": { + "category": "Smileys & Emotion", + "name": "pink heart", + "unicode": "1fa77" + }, + ":pirate_flag:": { + "category": "Flags", + "name": "pirate flag", + "unicode": "1f3f4-2620", + "unicode_alt": "1f3f4-200d-2620-fe0f" + }, + ":pisces:": { + "category": "Symbols", + "name": "Pisces", + "unicode": "2653" + }, + ":pitcairn_islands:": { + "category": "Flags", + "name": "flag: Pitcairn Islands", + "unicode": "1f1f5-1f1f3" + }, + ":pizza:": { + "category": "Food & Drink", + "name": "pizza", + "unicode": "1f355" + }, + ":placard:": { + "category": "Objects", + "name": "placard", + "unicode": "1faa7" + }, + ":place_of_worship:": { + "category": "Symbols", + "name": "place of worship", + "unicode": "1f6d0" + }, + ":plate_with_cutlery:": { + "category": "Food & Drink", + "name": "fork and knife with plate", + "unicode": "1f37d", + "unicode_alt": "1f37d-fe0f" + }, + ":play_or_pause_button:": { + "category": "Symbols", + "name": "play or pause button", + "unicode": "23ef", + "unicode_alt": "23ef-fe0f" + }, + ":playground_slide:": { + "category": "Travel & Places", + "name": "playground slide", + "unicode": "1f6dd" + }, + ":pleading_face:": { + "category": "Smileys & Emotion", + "name": "pleading face", + "unicode": "1f97a" + }, + ":plunger:": { + "category": "Objects", + "name": "plunger", + "unicode": "1faa0" + }, + ":point_down:": { + "category": "People & Body", + "name": "backhand index pointing down", + "unicode": "1f447" + }, + ":point_left:": { + "category": "People & Body", + "name": "backhand index pointing left", + "unicode": "1f448" + }, + ":point_right:": { + "category": "People & Body", + "name": "backhand index pointing right", + "unicode": "1f449" + }, + ":point_up:": { + "category": "People & Body", + "name": "index pointing up", + "unicode": "261d", + "unicode_alt": "261d-fe0f" + }, + ":point_up_2:": { + "category": "People & Body", + "name": "backhand index pointing up", + "unicode": "1f446" + }, + ":poland:": { + "category": "Flags", + "name": "flag: Poland", + "unicode": "1f1f5-1f1f1" + }, + ":polar_bear:": { + "category": "Animals & Nature", + "name": "polar bear", + "unicode": "1f43b-2744", + "unicode_alt": "1f43b-200d-2744-fe0f" + }, + ":police_car:": { + "category": "Travel & Places", + "name": "police car", + "unicode": "1f693" + }, + ":police_officer:": { + "category": "People & Body", + "name": "police officer", + "unicode": "1f46e" + }, + ":policeman:": { + "category": "People & Body", + "name": "man police officer", + "unicode": "1f46e-2642", + "unicode_alt": "1f46e-200d-2642-fe0f" + }, + ":policewoman:": { + "category": "People & Body", + "name": "woman police officer", + "unicode": "1f46e-2640", + "unicode_alt": "1f46e-200d-2640-fe0f" + }, + ":poodle:": { + "category": "Animals & Nature", + "name": "poodle", + "unicode": "1f429" + }, + ":popcorn:": { + "category": "Food & Drink", + "name": "popcorn", + "unicode": "1f37f" + }, + ":portugal:": { + "category": "Flags", + "name": "flag: Portugal", + "unicode": "1f1f5-1f1f9" + }, + ":post_office:": { + "category": "Travel & Places", + "name": "Japanese post office", + "unicode": "1f3e3" + }, + ":postal_horn:": { + "category": "Objects", + "name": "postal horn", + "unicode": "1f4ef" + }, + ":postbox:": { + "category": "Objects", + "name": "postbox", + "unicode": "1f4ee" + }, + ":potable_water:": { + "category": "Symbols", + "name": "potable water", + "unicode": "1f6b0" + }, + ":potato:": { + "category": "Food & Drink", + "name": "potato", + "unicode": "1f954" + }, + ":potted_plant:": { + "category": "Animals & Nature", + "name": "potted plant", + "unicode": "1fab4" + }, + ":pouch:": { + "category": "Objects", + "name": "clutch bag", + "unicode": "1f45d" + }, + ":poultry_leg:": { + "category": "Food & Drink", + "name": "poultry leg", + "unicode": "1f357" + }, + ":pound:": { + "category": "Objects", + "name": "pound banknote", + "unicode": "1f4b7" + }, + ":pouring_liquid:": { + "category": "Food & Drink", + "name": "pouring liquid", + "unicode": "1fad7" + }, + ":pouting_cat:": { + "category": "Smileys & Emotion", + "name": "pouting cat", + "unicode": "1f63e" + }, + ":pouting_face:": { + "category": "People & Body", + "name": "person pouting", + "unicode": "1f64e" + }, + ":pouting_man:": { + "category": "People & Body", + "name": "man pouting", + "unicode": "1f64e-2642", + "unicode_alt": "1f64e-200d-2642-fe0f" + }, + ":pouting_woman:": { + "category": "People & Body", + "name": "woman pouting", + "unicode": "1f64e-2640", + "unicode_alt": "1f64e-200d-2640-fe0f" + }, + ":pray:": { + "category": "People & Body", + "name": "folded hands", + "unicode": "1f64f" + }, + ":prayer_beads:": { + "category": "Objects", + "name": "prayer beads", + "unicode": "1f4ff" + }, + ":pregnant_man:": { + "category": "People & Body", + "name": "pregnant man", + "unicode": "1fac3" + }, + ":pregnant_person:": { + "category": "People & Body", + "name": "pregnant person", + "unicode": "1fac4" + }, + ":pregnant_woman:": { + "category": "People & Body", + "name": "pregnant woman", + "unicode": "1f930" + }, + ":pretzel:": { + "category": "Food & Drink", + "name": "pretzel", + "unicode": "1f968" + }, + ":previous_track_button:": { + "category": "Symbols", + "name": "last track button", + "unicode": "23ee", + "unicode_alt": "23ee-fe0f" + }, + ":prince:": { + "category": "People & Body", + "name": "prince", + "unicode": "1f934" + }, + ":princess:": { + "category": "People & Body", + "name": "princess", + "unicode": "1f478" + }, + ":printer:": { + "category": "Objects", + "name": "printer", + "unicode": "1f5a8", + "unicode_alt": "1f5a8-fe0f" + }, + ":probing_cane:": { + "category": "Objects", + "name": "white cane", + "unicode": "1f9af" + }, + ":puerto_rico:": { + "category": "Flags", + "name": "flag: Puerto Rico", + "unicode": "1f1f5-1f1f7" + }, + ":purple_circle:": { + "category": "Symbols", + "name": "purple circle", + "unicode": "1f7e3" + }, + ":purple_heart:": { + "category": "Smileys & Emotion", + "name": "purple heart", + "unicode": "1f49c" + }, + ":purple_square:": { + "category": "Symbols", + "name": "purple square", + "unicode": "1f7ea" + }, + ":purse:": { + "category": "Objects", + "name": "purse", + "unicode": "1f45b" + }, + ":pushpin:": { + "category": "Objects", + "name": "pushpin", + "unicode": "1f4cc" + }, + ":put_litter_in_its_place:": { + "category": "Symbols", + "name": "litter in bin sign", + "unicode": "1f6ae" + }, + ":qatar:": { + "category": "Flags", + "name": "flag: Qatar", + "unicode": "1f1f6-1f1e6" + }, + ":question:": { + "category": "Symbols", + "name": "red question mark", + "unicode": "2753" + }, + ":rabbit2:": { + "category": "Animals & Nature", + "name": "rabbit", + "unicode": "1f407" + }, + ":rabbit:": { + "category": "Animals & Nature", + "name": "rabbit face", + "unicode": "1f430" + }, + ":raccoon:": { + "category": "Animals & Nature", + "name": "raccoon", + "unicode": "1f99d" + }, + ":racehorse:": { + "category": "Animals & Nature", + "name": "horse", + "unicode": "1f40e" + }, + ":racing_car:": { + "category": "Travel & Places", + "name": "racing car", + "unicode": "1f3ce", + "unicode_alt": "1f3ce-fe0f" + }, + ":radio:": { + "category": "Objects", + "name": "radio", + "unicode": "1f4fb" + }, + ":radio_button:": { + "category": "Symbols", + "name": "radio button", + "unicode": "1f518" + }, + ":radioactive:": { + "category": "Symbols", + "name": "radioactive", + "unicode": "2622", + "unicode_alt": "2622-fe0f" + }, + ":rage:": { + "category": "Smileys & Emotion", + "name": "enraged face", + "unicode": "1f621" + }, + ":railway_car:": { + "category": "Travel & Places", + "name": "railway car", + "unicode": "1f683" + }, + ":railway_track:": { + "category": "Travel & Places", + "name": "railway track", + "unicode": "1f6e4", + "unicode_alt": "1f6e4-fe0f" + }, + ":rainbow:": { + "category": "Travel & Places", + "name": "rainbow", + "unicode": "1f308" + }, + ":rainbow_flag:": { + "category": "Flags", + "name": "rainbow flag", + "unicode": "1f3f3-1f308", + "unicode_alt": "1f3f3-fe0f-200d-1f308" + }, + ":raised_back_of_hand:": { + "category": "People & Body", + "name": "raised back of hand", + "unicode": "1f91a" + }, + ":raised_eyebrow:": { + "category": "Smileys & Emotion", + "name": "face with raised eyebrow", + "unicode": "1f928" + }, + ":raised_hand_with_fingers_splayed:": { + "category": "People & Body", + "name": "hand with fingers splayed", + "unicode": "1f590", + "unicode_alt": "1f590-fe0f" + }, + ":raised_hands:": { + "category": "People & Body", + "name": "raising hands", + "unicode": "1f64c" + }, + ":raising_hand:": { + "category": "People & Body", + "name": "person raising hand", + "unicode": "1f64b" + }, + ":raising_hand_man:": { + "category": "People & Body", + "name": "man raising hand", + "unicode": "1f64b-2642", + "unicode_alt": "1f64b-200d-2642-fe0f" + }, + ":raising_hand_woman:": { + "category": "People & Body", + "name": "woman raising hand", + "unicode": "1f64b-2640", + "unicode_alt": "1f64b-200d-2640-fe0f" + }, + ":ram:": { + "category": "Animals & Nature", + "name": "ram", + "unicode": "1f40f" + }, + ":ramen:": { + "category": "Food & Drink", + "name": "steaming bowl", + "unicode": "1f35c" + }, + ":rat:": { + "category": "Animals & Nature", + "name": "rat", + "unicode": "1f400" + }, + ":razor:": { + "category": "Objects", + "name": "razor", + "unicode": "1fa92" + }, + ":receipt:": { + "category": "Objects", + "name": "receipt", + "unicode": "1f9fe" + }, + ":record_button:": { + "category": "Symbols", + "name": "record button", + "unicode": "23fa", + "unicode_alt": "23fa-fe0f" + }, + ":recycle:": { + "category": "Symbols", + "name": "recycling symbol", + "unicode": "267b", + "unicode_alt": "267b-fe0f" + }, + ":red_circle:": { + "category": "Symbols", + "name": "red circle", + "unicode": "1f534" + }, + ":red_envelope:": { + "category": "Activities", + "name": "red envelope", + "unicode": "1f9e7" + }, + ":red_haired_man:": { + "category": "People & Body", + "name": "man: red hair", + "unicode": "1f468-1f9b0", + "unicode_alt": "1f468-200d-1f9b0" + }, + ":red_haired_woman:": { + "category": "People & Body", + "name": "woman: red hair", + "unicode": "1f469-1f9b0", + "unicode_alt": "1f469-200d-1f9b0" + }, + ":red_square:": { + "category": "Symbols", + "name": "red square", + "unicode": "1f7e5" + }, + ":registered:": { + "category": "Symbols", + "name": "registered", + "unicode": "00ae", + "unicode_alt": "00ae-fe0f" + }, + ":relaxed:": { + "category": "Smileys & Emotion", + "name": "smiling face", + "unicode": "263a", + "unicode_alt": "263a-fe0f" + }, + ":relieved:": { + "category": "Smileys & Emotion", + "name": "relieved face", + "unicode": "1f60c" + }, + ":reminder_ribbon:": { + "category": "Activities", + "name": "reminder ribbon", + "unicode": "1f397", + "unicode_alt": "1f397-fe0f" + }, + ":repeat:": { + "category": "Symbols", + "name": "repeat button", + "unicode": "1f501" + }, + ":repeat_one:": { + "category": "Symbols", + "name": "repeat single button", + "unicode": "1f502" + }, + ":rescue_worker_helmet:": { + "category": "Objects", + "name": "rescue worker\u2019s helmet", + "unicode": "26d1", + "unicode_alt": "26d1-fe0f" + }, + ":restroom:": { + "category": "Symbols", + "name": "restroom", + "unicode": "1f6bb" + }, + ":reunion:": { + "category": "Flags", + "name": "flag: R\u00e9union", + "unicode": "1f1f7-1f1ea" + }, + ":revolving_hearts:": { + "category": "Smileys & Emotion", + "name": "revolving hearts", + "unicode": "1f49e" + }, + ":rewind:": { + "category": "Symbols", + "name": "fast reverse button", + "unicode": "23ea" + }, + ":rhinoceros:": { + "category": "Animals & Nature", + "name": "rhinoceros", + "unicode": "1f98f" + }, + ":ribbon:": { + "category": "Activities", + "name": "ribbon", + "unicode": "1f380" + }, + ":rice:": { + "category": "Food & Drink", + "name": "cooked rice", + "unicode": "1f35a" + }, + ":rice_ball:": { + "category": "Food & Drink", + "name": "rice ball", + "unicode": "1f359" + }, + ":rice_cracker:": { + "category": "Food & Drink", + "name": "rice cracker", + "unicode": "1f358" + }, + ":rice_scene:": { + "category": "Activities", + "name": "moon viewing ceremony", + "unicode": "1f391" + }, + ":right_anger_bubble:": { + "category": "Smileys & Emotion", + "name": "right anger bubble", + "unicode": "1f5ef", + "unicode_alt": "1f5ef-fe0f" + }, + ":rightwards_hand:": { + "category": "People & Body", + "name": "rightwards hand", + "unicode": "1faf1" + }, + ":rightwards_pushing_hand:": { + "category": "People & Body", + "name": "rightwards pushing hand", + "unicode": "1faf8" + }, + ":ring:": { + "category": "Objects", + "name": "ring", + "unicode": "1f48d" + }, + ":ring_buoy:": { + "category": "Travel & Places", + "name": "ring buoy", + "unicode": "1f6df" + }, + ":ringed_planet:": { + "category": "Travel & Places", + "name": "ringed planet", + "unicode": "1fa90" + }, + ":robot:": { + "category": "Smileys & Emotion", + "name": "robot", + "unicode": "1f916" + }, + ":rock:": { + "category": "Travel & Places", + "name": "rock", + "unicode": "1faa8" + }, + ":rocket:": { + "category": "Travel & Places", + "name": "rocket", + "unicode": "1f680" + }, + ":rofl:": { + "category": "Smileys & Emotion", + "name": "rolling on the floor laughing", + "unicode": "1f923" + }, + ":roll_eyes:": { + "category": "Smileys & Emotion", + "name": "face with rolling eyes", + "unicode": "1f644" + }, + ":roll_of_paper:": { + "category": "Objects", + "name": "roll of paper", + "unicode": "1f9fb" + }, + ":roller_coaster:": { + "category": "Travel & Places", + "name": "roller coaster", + "unicode": "1f3a2" + }, + ":roller_skate:": { + "category": "Travel & Places", + "name": "roller skate", + "unicode": "1f6fc" + }, + ":romania:": { + "category": "Flags", + "name": "flag: Romania", + "unicode": "1f1f7-1f1f4" + }, + ":rooster:": { + "category": "Animals & Nature", + "name": "rooster", + "unicode": "1f413" + }, + ":rose:": { + "category": "Animals & Nature", + "name": "rose", + "unicode": "1f339" + }, + ":rosette:": { + "category": "Animals & Nature", + "name": "rosette", + "unicode": "1f3f5", + "unicode_alt": "1f3f5-fe0f" + }, + ":rotating_light:": { + "category": "Travel & Places", + "name": "police car light", + "unicode": "1f6a8" + }, + ":round_pushpin:": { + "category": "Objects", + "name": "round pushpin", + "unicode": "1f4cd" + }, + ":rowboat:": { + "category": "People & Body", + "name": "person rowing boat", + "unicode": "1f6a3" + }, + ":rowing_man:": { + "category": "People & Body", + "name": "man rowing boat", + "unicode": "1f6a3-2642", + "unicode_alt": "1f6a3-200d-2642-fe0f" + }, + ":rowing_woman:": { + "category": "People & Body", + "name": "woman rowing boat", + "unicode": "1f6a3-2640", + "unicode_alt": "1f6a3-200d-2640-fe0f" + }, + ":ru:": { + "category": "Flags", + "name": "flag: Russia", + "unicode": "1f1f7-1f1fa" + }, + ":rugby_football:": { + "category": "Activities", + "name": "rugby football", + "unicode": "1f3c9" + }, + ":runner:": { + "category": "People & Body", + "name": "person running", + "unicode": "1f3c3" + }, + ":running_man:": { + "category": "People & Body", + "name": "man running", + "unicode": "1f3c3-2642", + "unicode_alt": "1f3c3-200d-2642-fe0f" + }, + ":running_shirt_with_sash:": { + "category": "Activities", + "name": "running shirt", + "unicode": "1f3bd" + }, + ":running_woman:": { + "category": "People & Body", + "name": "woman running", + "unicode": "1f3c3-2640", + "unicode_alt": "1f3c3-200d-2640-fe0f" + }, + ":rwanda:": { + "category": "Flags", + "name": "flag: Rwanda", + "unicode": "1f1f7-1f1fc" + }, + ":sa:": { + "category": "Symbols", + "name": "Japanese \u201cservice charge\u201d button", + "unicode": "1f202", + "unicode_alt": "1f202-fe0f" + }, + ":safety_pin:": { + "category": "Objects", + "name": "safety pin", + "unicode": "1f9f7" + }, + ":safety_vest:": { + "category": "Objects", + "name": "safety vest", + "unicode": "1f9ba" + }, + ":sagittarius:": { + "category": "Symbols", + "name": "Sagittarius", + "unicode": "2650" + }, + ":sake:": { + "category": "Food & Drink", + "name": "sake", + "unicode": "1f376" + }, + ":salt:": { + "category": "Food & Drink", + "name": "salt", + "unicode": "1f9c2" + }, + ":saluting_face:": { + "category": "Smileys & Emotion", + "name": "saluting face", + "unicode": "1fae1" + }, + ":samoa:": { + "category": "Flags", + "name": "flag: Samoa", + "unicode": "1f1fc-1f1f8" + }, + ":san_marino:": { + "category": "Flags", + "name": "flag: San Marino", + "unicode": "1f1f8-1f1f2" + }, + ":sandal:": { + "category": "Objects", + "name": "woman\u2019s sandal", + "unicode": "1f461" + }, + ":sandwich:": { + "category": "Food & Drink", + "name": "sandwich", + "unicode": "1f96a" + }, + ":santa:": { + "category": "People & Body", + "name": "Santa Claus", + "unicode": "1f385" + }, + ":sao_tome_principe:": { + "category": "Flags", + "name": "flag: S\u00e3o Tom\u00e9 & Pr\u00edncipe", + "unicode": "1f1f8-1f1f9" + }, + ":sari:": { + "category": "Objects", + "name": "sari", + "unicode": "1f97b" + }, + ":satellite:": { + "category": "Objects", + "name": "satellite antenna", + "unicode": "1f4e1" + }, + ":saudi_arabia:": { + "category": "Flags", + "name": "flag: Saudi Arabia", + "unicode": "1f1f8-1f1e6" + }, + ":sauna_man:": { + "category": "People & Body", + "name": "man in steamy room", + "unicode": "1f9d6-2642", + "unicode_alt": "1f9d6-200d-2642-fe0f" + }, + ":sauna_person:": { + "category": "People & Body", + "name": "person in steamy room", + "unicode": "1f9d6" + }, + ":sauna_woman:": { + "category": "People & Body", + "name": "woman in steamy room", + "unicode": "1f9d6-2640", + "unicode_alt": "1f9d6-200d-2640-fe0f" + }, + ":sauropod:": { + "category": "Animals & Nature", + "name": "sauropod", + "unicode": "1f995" + }, + ":saxophone:": { + "category": "Objects", + "name": "saxophone", + "unicode": "1f3b7" + }, + ":scarf:": { + "category": "Objects", + "name": "scarf", + "unicode": "1f9e3" + }, + ":school:": { + "category": "Travel & Places", + "name": "school", + "unicode": "1f3eb" + }, + ":school_satchel:": { + "category": "Objects", + "name": "backpack", + "unicode": "1f392" + }, + ":scientist:": { + "category": "People & Body", + "name": "scientist", + "unicode": "1f9d1-1f52c", + "unicode_alt": "1f9d1-200d-1f52c" + }, + ":scissors:": { + "category": "Objects", + "name": "scissors", + "unicode": "2702", + "unicode_alt": "2702-fe0f" + }, + ":scorpion:": { + "category": "Animals & Nature", + "name": "scorpion", + "unicode": "1f982" + }, + ":scorpius:": { + "category": "Symbols", + "name": "Scorpio", + "unicode": "264f" + }, + ":scotland:": { + "category": "Flags", + "name": "flag: Scotland", + "unicode": "1f3f4-e0067-e0062-e0073-e0063-e0074-e007f" + }, + ":scream:": { + "category": "Smileys & Emotion", + "name": "face screaming in fear", + "unicode": "1f631" + }, + ":scream_cat:": { + "category": "Smileys & Emotion", + "name": "weary cat", + "unicode": "1f640" + }, + ":screwdriver:": { + "category": "Objects", + "name": "screwdriver", + "unicode": "1fa9b" + }, + ":scroll:": { + "category": "Objects", + "name": "scroll", + "unicode": "1f4dc" + }, + ":seal:": { + "category": "Animals & Nature", + "name": "seal", + "unicode": "1f9ad" + }, + ":seat:": { + "category": "Travel & Places", + "name": "seat", + "unicode": "1f4ba" + }, + ":secret:": { + "category": "Symbols", + "name": "Japanese \u201csecret\u201d button", + "unicode": "3299", + "unicode_alt": "3299-fe0f" + }, + ":see_no_evil:": { + "category": "Smileys & Emotion", + "name": "see-no-evil monkey", + "unicode": "1f648" + }, + ":seedling:": { + "category": "Animals & Nature", + "name": "seedling", + "unicode": "1f331" + }, + ":selfie:": { + "category": "People & Body", + "name": "selfie", + "unicode": "1f933" + }, + ":senegal:": { + "category": "Flags", + "name": "flag: Senegal", + "unicode": "1f1f8-1f1f3" + }, + ":serbia:": { + "category": "Flags", + "name": "flag: Serbia", + "unicode": "1f1f7-1f1f8" + }, + ":service_dog:": { + "category": "Animals & Nature", + "name": "service dog", + "unicode": "1f415-1f9ba", + "unicode_alt": "1f415-200d-1f9ba" + }, + ":seven:": { + "category": "Symbols", + "name": "keycap: 7", + "unicode": "0037-20e3", + "unicode_alt": "0037-fe0f-20e3" + }, + ":sewing_needle:": { + "category": "Activities", + "name": "sewing needle", + "unicode": "1faa1" + }, + ":seychelles:": { + "category": "Flags", + "name": "flag: Seychelles", + "unicode": "1f1f8-1f1e8" + }, + ":shaking_face:": { + "category": "Smileys & Emotion", + "name": "shaking face", + "unicode": "1fae8" + }, + ":shallow_pan_of_food:": { + "category": "Food & Drink", + "name": "shallow pan of food", + "unicode": "1f958" + }, + ":shamrock:": { + "category": "Animals & Nature", + "name": "shamrock", + "unicode": "2618", + "unicode_alt": "2618-fe0f" + }, + ":shark:": { + "category": "Animals & Nature", + "name": "shark", + "unicode": "1f988" + }, + ":shaved_ice:": { + "category": "Food & Drink", + "name": "shaved ice", + "unicode": "1f367" + }, + ":sheep:": { + "category": "Animals & Nature", + "name": "ewe", + "unicode": "1f411" + }, + ":shell:": { + "category": "Animals & Nature", + "name": "spiral shell", + "unicode": "1f41a" + }, + ":shield:": { + "category": "Objects", + "name": "shield", + "unicode": "1f6e1", + "unicode_alt": "1f6e1-fe0f" + }, + ":shinto_shrine:": { + "category": "Travel & Places", + "name": "shinto shrine", + "unicode": "26e9", + "unicode_alt": "26e9-fe0f" + }, + ":ship:": { + "category": "Travel & Places", + "name": "ship", + "unicode": "1f6a2" + }, + ":shirt:": { + "category": "Objects", + "name": "t-shirt", + "unicode": "1f455" + }, + ":shopping:": { + "category": "Objects", + "name": "shopping bags", + "unicode": "1f6cd", + "unicode_alt": "1f6cd-fe0f" + }, + ":shopping_cart:": { + "category": "Objects", + "name": "shopping cart", + "unicode": "1f6d2" + }, + ":shorts:": { + "category": "Objects", + "name": "shorts", + "unicode": "1fa73" + }, + ":shower:": { + "category": "Objects", + "name": "shower", + "unicode": "1f6bf" + }, + ":shrimp:": { + "category": "Food & Drink", + "name": "shrimp", + "unicode": "1f990" + }, + ":shrug:": { + "category": "People & Body", + "name": "person shrugging", + "unicode": "1f937" + }, + ":shushing_face:": { + "category": "Smileys & Emotion", + "name": "shushing face", + "unicode": "1f92b" + }, + ":sierra_leone:": { + "category": "Flags", + "name": "flag: Sierra Leone", + "unicode": "1f1f8-1f1f1" + }, + ":signal_strength:": { + "category": "Symbols", + "name": "antenna bars", + "unicode": "1f4f6" + }, + ":singapore:": { + "category": "Flags", + "name": "flag: Singapore", + "unicode": "1f1f8-1f1ec" + }, + ":singer:": { + "category": "People & Body", + "name": "singer", + "unicode": "1f9d1-1f3a4", + "unicode_alt": "1f9d1-200d-1f3a4" + }, + ":sint_maarten:": { + "category": "Flags", + "name": "flag: Sint Maarten", + "unicode": "1f1f8-1f1fd" + }, + ":six:": { + "category": "Symbols", + "name": "keycap: 6", + "unicode": "0036-20e3", + "unicode_alt": "0036-fe0f-20e3" + }, + ":six_pointed_star:": { + "category": "Symbols", + "name": "dotted six-pointed star", + "unicode": "1f52f" + }, + ":skateboard:": { + "category": "Travel & Places", + "name": "skateboard", + "unicode": "1f6f9" + }, + ":ski:": { + "category": "Activities", + "name": "skis", + "unicode": "1f3bf" + }, + ":skier:": { + "category": "People & Body", + "name": "skier", + "unicode": "26f7", + "unicode_alt": "26f7-fe0f" + }, + ":skull:": { + "category": "Smileys & Emotion", + "name": "skull", + "unicode": "1f480" + }, + ":skull_and_crossbones:": { + "category": "Smileys & Emotion", + "name": "skull and crossbones", + "unicode": "2620", + "unicode_alt": "2620-fe0f" + }, + ":skunk:": { + "category": "Animals & Nature", + "name": "skunk", + "unicode": "1f9a8" + }, + ":sled:": { + "category": "Activities", + "name": "sled", + "unicode": "1f6f7" + }, + ":sleeping:": { + "category": "Smileys & Emotion", + "name": "sleeping face", + "unicode": "1f634" + }, + ":sleeping_bed:": { + "category": "People & Body", + "name": "person in bed", + "unicode": "1f6cc" + }, + ":sleepy:": { + "category": "Smileys & Emotion", + "name": "sleepy face", + "unicode": "1f62a" + }, + ":slightly_frowning_face:": { + "category": "Smileys & Emotion", + "name": "slightly frowning face", + "unicode": "1f641" + }, + ":slightly_smiling_face:": { + "category": "Smileys & Emotion", + "name": "slightly smiling face", + "unicode": "1f642" + }, + ":slot_machine:": { + "category": "Activities", + "name": "slot machine", + "unicode": "1f3b0" + }, + ":sloth:": { + "category": "Animals & Nature", + "name": "sloth", + "unicode": "1f9a5" + }, + ":slovakia:": { + "category": "Flags", + "name": "flag: Slovakia", + "unicode": "1f1f8-1f1f0" + }, + ":slovenia:": { + "category": "Flags", + "name": "flag: Slovenia", + "unicode": "1f1f8-1f1ee" + }, + ":small_airplane:": { + "category": "Travel & Places", + "name": "small airplane", + "unicode": "1f6e9", + "unicode_alt": "1f6e9-fe0f" + }, + ":small_blue_diamond:": { + "category": "Symbols", + "name": "small blue diamond", + "unicode": "1f539" + }, + ":small_orange_diamond:": { + "category": "Symbols", + "name": "small orange diamond", + "unicode": "1f538" + }, + ":small_red_triangle:": { + "category": "Symbols", + "name": "red triangle pointed up", + "unicode": "1f53a" + }, + ":small_red_triangle_down:": { + "category": "Symbols", + "name": "red triangle pointed down", + "unicode": "1f53b" + }, + ":smile:": { + "category": "Smileys & Emotion", + "name": "grinning face with smiling eyes", + "unicode": "1f604" + }, + ":smile_cat:": { + "category": "Smileys & Emotion", + "name": "grinning cat with smiling eyes", + "unicode": "1f638" + }, + ":smiley:": { + "category": "Smileys & Emotion", + "name": "grinning face with big eyes", + "unicode": "1f603" + }, + ":smiley_cat:": { + "category": "Smileys & Emotion", + "name": "grinning cat", + "unicode": "1f63a" + }, + ":smiling_face_with_tear:": { + "category": "Smileys & Emotion", + "name": "smiling face with tear", + "unicode": "1f972" + }, + ":smiling_face_with_three_hearts:": { + "category": "Smileys & Emotion", + "name": "smiling face with hearts", + "unicode": "1f970" + }, + ":smiling_imp:": { + "category": "Smileys & Emotion", + "name": "smiling face with horns", + "unicode": "1f608" + }, + ":smirk:": { + "category": "Smileys & Emotion", + "name": "smirking face", + "unicode": "1f60f" + }, + ":smirk_cat:": { + "category": "Smileys & Emotion", + "name": "cat with wry smile", + "unicode": "1f63c" + }, + ":smoking:": { + "category": "Objects", + "name": "cigarette", + "unicode": "1f6ac" + }, + ":snail:": { + "category": "Animals & Nature", + "name": "snail", + "unicode": "1f40c" + }, + ":snake:": { + "category": "Animals & Nature", + "name": "snake", + "unicode": "1f40d" + }, + ":sneezing_face:": { + "category": "Smileys & Emotion", + "name": "sneezing face", + "unicode": "1f927" + }, + ":snowboarder:": { + "category": "People & Body", + "name": "snowboarder", + "unicode": "1f3c2" + }, + ":snowflake:": { + "category": "Travel & Places", + "name": "snowflake", + "unicode": "2744", + "unicode_alt": "2744-fe0f" + }, + ":snowman:": { + "category": "Travel & Places", + "name": "snowman without snow", + "unicode": "26c4" + }, + ":snowman_with_snow:": { + "category": "Travel & Places", + "name": "snowman", + "unicode": "2603", + "unicode_alt": "2603-fe0f" + }, + ":soap:": { + "category": "Objects", + "name": "soap", + "unicode": "1f9fc" + }, + ":sob:": { + "category": "Smileys & Emotion", + "name": "loudly crying face", + "unicode": "1f62d" + }, + ":soccer:": { + "category": "Activities", + "name": "soccer ball", + "unicode": "26bd" + }, + ":socks:": { + "category": "Objects", + "name": "socks", + "unicode": "1f9e6" + }, + ":softball:": { + "category": "Activities", + "name": "softball", + "unicode": "1f94e" + }, + ":solomon_islands:": { + "category": "Flags", + "name": "flag: Solomon Islands", + "unicode": "1f1f8-1f1e7" + }, + ":somalia:": { + "category": "Flags", + "name": "flag: Somalia", + "unicode": "1f1f8-1f1f4" + }, + ":soon:": { + "category": "Symbols", + "name": "SOON arrow", + "unicode": "1f51c" + }, + ":sos:": { + "category": "Symbols", + "name": "SOS button", + "unicode": "1f198" + }, + ":sound:": { + "category": "Objects", + "name": "speaker medium volume", + "unicode": "1f509" + }, + ":south_africa:": { + "category": "Flags", + "name": "flag: South Africa", + "unicode": "1f1ff-1f1e6" + }, + ":south_georgia_south_sandwich_islands:": { + "category": "Flags", + "name": "flag: South Georgia & South Sandwich Islands", + "unicode": "1f1ec-1f1f8" + }, + ":south_sudan:": { + "category": "Flags", + "name": "flag: South Sudan", + "unicode": "1f1f8-1f1f8" + }, + ":space_invader:": { + "category": "Smileys & Emotion", + "name": "alien monster", + "unicode": "1f47e" + }, + ":spades:": { + "category": "Activities", + "name": "spade suit", + "unicode": "2660", + "unicode_alt": "2660-fe0f" + }, + ":spaghetti:": { + "category": "Food & Drink", + "name": "spaghetti", + "unicode": "1f35d" + }, + ":sparkle:": { + "category": "Symbols", + "name": "sparkle", + "unicode": "2747", + "unicode_alt": "2747-fe0f" + }, + ":sparkler:": { + "category": "Activities", + "name": "sparkler", + "unicode": "1f387" + }, + ":sparkles:": { + "category": "Activities", + "name": "sparkles", + "unicode": "2728" + }, + ":sparkling_heart:": { + "category": "Smileys & Emotion", + "name": "sparkling heart", + "unicode": "1f496" + }, + ":speak_no_evil:": { + "category": "Smileys & Emotion", + "name": "speak-no-evil monkey", + "unicode": "1f64a" + }, + ":speaker:": { + "category": "Objects", + "name": "speaker low volume", + "unicode": "1f508" + }, + ":speaking_head:": { + "category": "People & Body", + "name": "speaking head", + "unicode": "1f5e3", + "unicode_alt": "1f5e3-fe0f" + }, + ":speech_balloon:": { + "category": "Smileys & Emotion", + "name": "speech balloon", + "unicode": "1f4ac" + }, + ":speedboat:": { + "category": "Travel & Places", + "name": "speedboat", + "unicode": "1f6a4" + }, + ":spider:": { + "category": "Animals & Nature", + "name": "spider", + "unicode": "1f577", + "unicode_alt": "1f577-fe0f" + }, + ":spider_web:": { + "category": "Animals & Nature", + "name": "spider web", + "unicode": "1f578", + "unicode_alt": "1f578-fe0f" + }, + ":spiral_calendar:": { + "category": "Objects", + "name": "spiral calendar", + "unicode": "1f5d3", + "unicode_alt": "1f5d3-fe0f" + }, + ":spiral_notepad:": { + "category": "Objects", + "name": "spiral notepad", + "unicode": "1f5d2", + "unicode_alt": "1f5d2-fe0f" + }, + ":sponge:": { + "category": "Objects", + "name": "sponge", + "unicode": "1f9fd" + }, + ":spoon:": { + "category": "Food & Drink", + "name": "spoon", + "unicode": "1f944" + }, + ":squid:": { + "category": "Food & Drink", + "name": "squid", + "unicode": "1f991" + }, + ":sri_lanka:": { + "category": "Flags", + "name": "flag: Sri Lanka", + "unicode": "1f1f1-1f1f0" + }, + ":st_barthelemy:": { + "category": "Flags", + "name": "flag: St. Barth\u00e9lemy", + "unicode": "1f1e7-1f1f1" + }, + ":st_helena:": { + "category": "Flags", + "name": "flag: St. Helena", + "unicode": "1f1f8-1f1ed" + }, + ":st_kitts_nevis:": { + "category": "Flags", + "name": "flag: St. Kitts & Nevis", + "unicode": "1f1f0-1f1f3" + }, + ":st_lucia:": { + "category": "Flags", + "name": "flag: St. Lucia", + "unicode": "1f1f1-1f1e8" + }, + ":st_martin:": { + "category": "Flags", + "name": "flag: St. Martin", + "unicode": "1f1f2-1f1eb" + }, + ":st_pierre_miquelon:": { + "category": "Flags", + "name": "flag: St. Pierre & Miquelon", + "unicode": "1f1f5-1f1f2" + }, + ":st_vincent_grenadines:": { + "category": "Flags", + "name": "flag: St. Vincent & Grenadines", + "unicode": "1f1fb-1f1e8" + }, + ":stadium:": { + "category": "Travel & Places", + "name": "stadium", + "unicode": "1f3df", + "unicode_alt": "1f3df-fe0f" + }, + ":standing_man:": { + "category": "People & Body", + "name": "man standing", + "unicode": "1f9cd-2642", + "unicode_alt": "1f9cd-200d-2642-fe0f" + }, + ":standing_person:": { + "category": "People & Body", + "name": "person standing", + "unicode": "1f9cd" + }, + ":standing_woman:": { + "category": "People & Body", + "name": "woman standing", + "unicode": "1f9cd-2640", + "unicode_alt": "1f9cd-200d-2640-fe0f" + }, + ":star2:": { + "category": "Travel & Places", + "name": "glowing star", + "unicode": "1f31f" + }, + ":star:": { + "category": "Travel & Places", + "name": "star", + "unicode": "2b50" + }, + ":star_and_crescent:": { + "category": "Symbols", + "name": "star and crescent", + "unicode": "262a", + "unicode_alt": "262a-fe0f" + }, + ":star_of_david:": { + "category": "Symbols", + "name": "star of David", + "unicode": "2721", + "unicode_alt": "2721-fe0f" + }, + ":star_struck:": { + "category": "Smileys & Emotion", + "name": "star-struck", + "unicode": "1f929" + }, + ":stars:": { + "category": "Travel & Places", + "name": "shooting star", + "unicode": "1f320" + }, + ":station:": { + "category": "Travel & Places", + "name": "station", + "unicode": "1f689" + }, + ":statue_of_liberty:": { + "category": "Travel & Places", + "name": "Statue of Liberty", + "unicode": "1f5fd" + }, + ":steam_locomotive:": { + "category": "Travel & Places", + "name": "locomotive", + "unicode": "1f682" + }, + ":stethoscope:": { + "category": "Objects", + "name": "stethoscope", + "unicode": "1fa7a" + }, + ":stew:": { + "category": "Food & Drink", + "name": "pot of food", + "unicode": "1f372" + }, + ":stop_button:": { + "category": "Symbols", + "name": "stop button", + "unicode": "23f9", + "unicode_alt": "23f9-fe0f" + }, + ":stop_sign:": { + "category": "Travel & Places", + "name": "stop sign", + "unicode": "1f6d1" + }, + ":stopwatch:": { + "category": "Travel & Places", + "name": "stopwatch", + "unicode": "23f1", + "unicode_alt": "23f1-fe0f" + }, + ":straight_ruler:": { + "category": "Objects", + "name": "straight ruler", + "unicode": "1f4cf" + }, + ":strawberry:": { + "category": "Food & Drink", + "name": "strawberry", + "unicode": "1f353" + }, + ":stuck_out_tongue:": { + "category": "Smileys & Emotion", + "name": "face with tongue", + "unicode": "1f61b" + }, + ":stuck_out_tongue_closed_eyes:": { + "category": "Smileys & Emotion", + "name": "squinting face with tongue", + "unicode": "1f61d" + }, + ":stuck_out_tongue_winking_eye:": { + "category": "Smileys & Emotion", + "name": "winking face with tongue", + "unicode": "1f61c" + }, + ":student:": { + "category": "People & Body", + "name": "student", + "unicode": "1f9d1-1f393", + "unicode_alt": "1f9d1-200d-1f393" + }, + ":studio_microphone:": { + "category": "Objects", + "name": "studio microphone", + "unicode": "1f399", + "unicode_alt": "1f399-fe0f" + }, + ":stuffed_flatbread:": { + "category": "Food & Drink", + "name": "stuffed flatbread", + "unicode": "1f959" + }, + ":sudan:": { + "category": "Flags", + "name": "flag: Sudan", + "unicode": "1f1f8-1f1e9" + }, + ":sun_behind_large_cloud:": { + "category": "Travel & Places", + "name": "sun behind large cloud", + "unicode": "1f325", + "unicode_alt": "1f325-fe0f" + }, + ":sun_behind_rain_cloud:": { + "category": "Travel & Places", + "name": "sun behind rain cloud", + "unicode": "1f326", + "unicode_alt": "1f326-fe0f" + }, + ":sun_behind_small_cloud:": { + "category": "Travel & Places", + "name": "sun behind small cloud", + "unicode": "1f324", + "unicode_alt": "1f324-fe0f" + }, + ":sun_with_face:": { + "category": "Travel & Places", + "name": "sun with face", + "unicode": "1f31e" + }, + ":sunflower:": { + "category": "Animals & Nature", + "name": "sunflower", + "unicode": "1f33b" + }, + ":sunglasses:": { + "category": "Smileys & Emotion", + "name": "smiling face with sunglasses", + "unicode": "1f60e" + }, + ":sunny:": { + "category": "Travel & Places", + "name": "sun", + "unicode": "2600", + "unicode_alt": "2600-fe0f" + }, + ":sunrise:": { + "category": "Travel & Places", + "name": "sunrise", + "unicode": "1f305" + }, + ":sunrise_over_mountains:": { + "category": "Travel & Places", + "name": "sunrise over mountains", + "unicode": "1f304" + }, + ":superhero:": { + "category": "People & Body", + "name": "superhero", + "unicode": "1f9b8" + }, + ":superhero_man:": { + "category": "People & Body", + "name": "man superhero", + "unicode": "1f9b8-2642", + "unicode_alt": "1f9b8-200d-2642-fe0f" + }, + ":superhero_woman:": { + "category": "People & Body", + "name": "woman superhero", + "unicode": "1f9b8-2640", + "unicode_alt": "1f9b8-200d-2640-fe0f" + }, + ":supervillain:": { + "category": "People & Body", + "name": "supervillain", + "unicode": "1f9b9" + }, + ":supervillain_man:": { + "category": "People & Body", + "name": "man supervillain", + "unicode": "1f9b9-2642", + "unicode_alt": "1f9b9-200d-2642-fe0f" + }, + ":supervillain_woman:": { + "category": "People & Body", + "name": "woman supervillain", + "unicode": "1f9b9-2640", + "unicode_alt": "1f9b9-200d-2640-fe0f" + }, + ":surfer:": { + "category": "People & Body", + "name": "person surfing", + "unicode": "1f3c4" + }, + ":surfing_man:": { + "category": "People & Body", + "name": "man surfing", + "unicode": "1f3c4-2642", + "unicode_alt": "1f3c4-200d-2642-fe0f" + }, + ":surfing_woman:": { + "category": "People & Body", + "name": "woman surfing", + "unicode": "1f3c4-2640", + "unicode_alt": "1f3c4-200d-2640-fe0f" + }, + ":suriname:": { + "category": "Flags", + "name": "flag: Suriname", + "unicode": "1f1f8-1f1f7" + }, + ":sushi:": { + "category": "Food & Drink", + "name": "sushi", + "unicode": "1f363" + }, + ":suspension_railway:": { + "category": "Travel & Places", + "name": "suspension railway", + "unicode": "1f69f" + }, + ":svalbard_jan_mayen:": { + "category": "Flags", + "name": "flag: Svalbard & Jan Mayen", + "unicode": "1f1f8-1f1ef" + }, + ":swan:": { + "category": "Animals & Nature", + "name": "swan", + "unicode": "1f9a2" + }, + ":swaziland:": { + "category": "Flags", + "name": "flag: Eswatini", + "unicode": "1f1f8-1f1ff" + }, + ":sweat:": { + "category": "Smileys & Emotion", + "name": "downcast face with sweat", + "unicode": "1f613" + }, + ":sweat_drops:": { + "category": "Smileys & Emotion", + "name": "sweat droplets", + "unicode": "1f4a6" + }, + ":sweat_smile:": { + "category": "Smileys & Emotion", + "name": "grinning face with sweat", + "unicode": "1f605" + }, + ":sweden:": { + "category": "Flags", + "name": "flag: Sweden", + "unicode": "1f1f8-1f1ea" + }, + ":sweet_potato:": { + "category": "Food & Drink", + "name": "roasted sweet potato", + "unicode": "1f360" + }, + ":swim_brief:": { + "category": "Objects", + "name": "briefs", + "unicode": "1fa72" + }, + ":swimmer:": { + "category": "People & Body", + "name": "person swimming", + "unicode": "1f3ca" + }, + ":swimming_man:": { + "category": "People & Body", + "name": "man swimming", + "unicode": "1f3ca-2642", + "unicode_alt": "1f3ca-200d-2642-fe0f" + }, + ":swimming_woman:": { + "category": "People & Body", + "name": "woman swimming", + "unicode": "1f3ca-2640", + "unicode_alt": "1f3ca-200d-2640-fe0f" + }, + ":switzerland:": { + "category": "Flags", + "name": "flag: Switzerland", + "unicode": "1f1e8-1f1ed" + }, + ":symbols:": { + "category": "Symbols", + "name": "input symbols", + "unicode": "1f523" + }, + ":synagogue:": { + "category": "Travel & Places", + "name": "synagogue", + "unicode": "1f54d" + }, + ":syria:": { + "category": "Flags", + "name": "flag: Syria", + "unicode": "1f1f8-1f1fe" + }, + ":syringe:": { + "category": "Objects", + "name": "syringe", + "unicode": "1f489" + }, + ":t-rex:": { + "category": "Animals & Nature", + "name": "T-Rex", + "unicode": "1f996" + }, + ":taco:": { + "category": "Food & Drink", + "name": "taco", + "unicode": "1f32e" + }, + ":tada:": { + "category": "Activities", + "name": "party popper", + "unicode": "1f389" + }, + ":taiwan:": { + "category": "Flags", + "name": "flag: Taiwan", + "unicode": "1f1f9-1f1fc" + }, + ":tajikistan:": { + "category": "Flags", + "name": "flag: Tajikistan", + "unicode": "1f1f9-1f1ef" + }, + ":takeout_box:": { + "category": "Food & Drink", + "name": "takeout box", + "unicode": "1f961" + }, + ":tamale:": { + "category": "Food & Drink", + "name": "tamale", + "unicode": "1fad4" + }, + ":tanabata_tree:": { + "category": "Activities", + "name": "tanabata tree", + "unicode": "1f38b" + }, + ":tangerine:": { + "category": "Food & Drink", + "name": "tangerine", + "unicode": "1f34a" + }, + ":tanzania:": { + "category": "Flags", + "name": "flag: Tanzania", + "unicode": "1f1f9-1f1ff" + }, + ":taurus:": { + "category": "Symbols", + "name": "Taurus", + "unicode": "2649" + }, + ":taxi:": { + "category": "Travel & Places", + "name": "taxi", + "unicode": "1f695" + }, + ":tea:": { + "category": "Food & Drink", + "name": "teacup without handle", + "unicode": "1f375" + }, + ":teacher:": { + "category": "People & Body", + "name": "teacher", + "unicode": "1f9d1-1f3eb", + "unicode_alt": "1f9d1-200d-1f3eb" + }, + ":teapot:": { + "category": "Food & Drink", + "name": "teapot", + "unicode": "1fad6" + }, + ":technologist:": { + "category": "People & Body", + "name": "technologist", + "unicode": "1f9d1-1f4bb", + "unicode_alt": "1f9d1-200d-1f4bb" + }, + ":teddy_bear:": { + "category": "Activities", + "name": "teddy bear", + "unicode": "1f9f8" + }, + ":telephone_receiver:": { + "category": "Objects", + "name": "telephone receiver", + "unicode": "1f4de" + }, + ":telescope:": { + "category": "Objects", + "name": "telescope", + "unicode": "1f52d" + }, + ":tennis:": { + "category": "Activities", + "name": "tennis", + "unicode": "1f3be" + }, + ":tent:": { + "category": "Travel & Places", + "name": "tent", + "unicode": "26fa" + }, + ":test_tube:": { + "category": "Objects", + "name": "test tube", + "unicode": "1f9ea" + }, + ":thailand:": { + "category": "Flags", + "name": "flag: Thailand", + "unicode": "1f1f9-1f1ed" + }, + ":thermometer:": { + "category": "Travel & Places", + "name": "thermometer", + "unicode": "1f321", + "unicode_alt": "1f321-fe0f" + }, + ":thinking:": { + "category": "Smileys & Emotion", + "name": "thinking face", + "unicode": "1f914" + }, + ":thong_sandal:": { + "category": "Objects", + "name": "thong sandal", + "unicode": "1fa74" + }, + ":thought_balloon:": { + "category": "Smileys & Emotion", + "name": "thought balloon", + "unicode": "1f4ad" + }, + ":thread:": { + "category": "Activities", + "name": "thread", + "unicode": "1f9f5" + }, + ":three:": { + "category": "Symbols", + "name": "keycap: 3", + "unicode": "0033-20e3", + "unicode_alt": "0033-fe0f-20e3" + }, + ":ticket:": { + "category": "Activities", + "name": "ticket", + "unicode": "1f3ab" + }, + ":tickets:": { + "category": "Activities", + "name": "admission tickets", + "unicode": "1f39f", + "unicode_alt": "1f39f-fe0f" + }, + ":tiger2:": { + "category": "Animals & Nature", + "name": "tiger", + "unicode": "1f405" + }, + ":tiger:": { + "category": "Animals & Nature", + "name": "tiger face", + "unicode": "1f42f" + }, + ":timer_clock:": { + "category": "Travel & Places", + "name": "timer clock", + "unicode": "23f2", + "unicode_alt": "23f2-fe0f" + }, + ":timor_leste:": { + "category": "Flags", + "name": "flag: Timor-Leste", + "unicode": "1f1f9-1f1f1" + }, + ":tipping_hand_man:": { + "category": "People & Body", + "name": "man tipping hand", + "unicode": "1f481-2642", + "unicode_alt": "1f481-200d-2642-fe0f" + }, + ":tipping_hand_person:": { + "category": "People & Body", + "name": "person tipping hand", + "unicode": "1f481" + }, + ":tipping_hand_woman:": { + "category": "People & Body", + "name": "woman tipping hand", + "unicode": "1f481-2640", + "unicode_alt": "1f481-200d-2640-fe0f" + }, + ":tired_face:": { + "category": "Smileys & Emotion", + "name": "tired face", + "unicode": "1f62b" + }, + ":tm:": { + "category": "Symbols", + "name": "trade mark", + "unicode": "2122", + "unicode_alt": "2122-fe0f" + }, + ":togo:": { + "category": "Flags", + "name": "flag: Togo", + "unicode": "1f1f9-1f1ec" + }, + ":toilet:": { + "category": "Objects", + "name": "toilet", + "unicode": "1f6bd" + }, + ":tokelau:": { + "category": "Flags", + "name": "flag: Tokelau", + "unicode": "1f1f9-1f1f0" + }, + ":tokyo_tower:": { + "category": "Travel & Places", + "name": "Tokyo tower", + "unicode": "1f5fc" + }, + ":tomato:": { + "category": "Food & Drink", + "name": "tomato", + "unicode": "1f345" + }, + ":tonga:": { + "category": "Flags", + "name": "flag: Tonga", + "unicode": "1f1f9-1f1f4" + }, + ":tongue:": { + "category": "People & Body", + "name": "tongue", + "unicode": "1f445" + }, + ":toolbox:": { + "category": "Objects", + "name": "toolbox", + "unicode": "1f9f0" + }, + ":tooth:": { + "category": "People & Body", + "name": "tooth", + "unicode": "1f9b7" + }, + ":toothbrush:": { + "category": "Objects", + "name": "toothbrush", + "unicode": "1faa5" + }, + ":top:": { + "category": "Symbols", + "name": "TOP arrow", + "unicode": "1f51d" + }, + ":tophat:": { + "category": "Objects", + "name": "top hat", + "unicode": "1f3a9" + }, + ":tornado:": { + "category": "Travel & Places", + "name": "tornado", + "unicode": "1f32a", + "unicode_alt": "1f32a-fe0f" + }, + ":tr:": { + "category": "Flags", + "name": "flag: Turkey", + "unicode": "1f1f9-1f1f7" + }, + ":trackball:": { + "category": "Objects", + "name": "trackball", + "unicode": "1f5b2", + "unicode_alt": "1f5b2-fe0f" + }, + ":tractor:": { + "category": "Travel & Places", + "name": "tractor", + "unicode": "1f69c" + }, + ":traffic_light:": { + "category": "Travel & Places", + "name": "horizontal traffic light", + "unicode": "1f6a5" + }, + ":train2:": { + "category": "Travel & Places", + "name": "train", + "unicode": "1f686" + }, + ":train:": { + "category": "Travel & Places", + "name": "tram car", + "unicode": "1f68b" + }, + ":tram:": { + "category": "Travel & Places", + "name": "tram", + "unicode": "1f68a" + }, + ":transgender_flag:": { + "category": "Flags", + "name": "transgender flag", + "unicode": "1f3f3-26a7", + "unicode_alt": "1f3f3-fe0f-200d-26a7-fe0f" + }, + ":transgender_symbol:": { + "category": "Symbols", + "name": "transgender symbol", + "unicode": "26a7", + "unicode_alt": "26a7-fe0f" + }, + ":triangular_flag_on_post:": { + "category": "Flags", + "name": "triangular flag", + "unicode": "1f6a9" + }, + ":triangular_ruler:": { + "category": "Objects", + "name": "triangular ruler", + "unicode": "1f4d0" + }, + ":trident:": { + "category": "Symbols", + "name": "trident emblem", + "unicode": "1f531" + }, + ":trinidad_tobago:": { + "category": "Flags", + "name": "flag: Trinidad & Tobago", + "unicode": "1f1f9-1f1f9" + }, + ":tristan_da_cunha:": { + "category": "Flags", + "name": "flag: Tristan da Cunha", + "unicode": "1f1f9-1f1e6" + }, + ":triumph:": { + "category": "Smileys & Emotion", + "name": "face with steam from nose", + "unicode": "1f624" + }, + ":troll:": { + "category": "People & Body", + "name": "troll", + "unicode": "1f9cc" + }, + ":trolleybus:": { + "category": "Travel & Places", + "name": "trolleybus", + "unicode": "1f68e" + }, + ":trophy:": { + "category": "Activities", + "name": "trophy", + "unicode": "1f3c6" + }, + ":tropical_drink:": { + "category": "Food & Drink", + "name": "tropical drink", + "unicode": "1f379" + }, + ":tropical_fish:": { + "category": "Animals & Nature", + "name": "tropical fish", + "unicode": "1f420" + }, + ":truck:": { + "category": "Travel & Places", + "name": "delivery truck", + "unicode": "1f69a" + }, + ":trumpet:": { + "category": "Objects", + "name": "trumpet", + "unicode": "1f3ba" + }, + ":tulip:": { + "category": "Animals & Nature", + "name": "tulip", + "unicode": "1f337" + }, + ":tumbler_glass:": { + "category": "Food & Drink", + "name": "tumbler glass", + "unicode": "1f943" + }, + ":tunisia:": { + "category": "Flags", + "name": "flag: Tunisia", + "unicode": "1f1f9-1f1f3" + }, + ":turkey:": { + "category": "Animals & Nature", + "name": "turkey", + "unicode": "1f983" + }, + ":turkmenistan:": { + "category": "Flags", + "name": "flag: Turkmenistan", + "unicode": "1f1f9-1f1f2" + }, + ":turks_caicos_islands:": { + "category": "Flags", + "name": "flag: Turks & Caicos Islands", + "unicode": "1f1f9-1f1e8" + }, + ":turtle:": { + "category": "Animals & Nature", + "name": "turtle", + "unicode": "1f422" + }, + ":tuvalu:": { + "category": "Flags", + "name": "flag: Tuvalu", + "unicode": "1f1f9-1f1fb" + }, + ":tv:": { + "category": "Objects", + "name": "television", + "unicode": "1f4fa" + }, + ":twisted_rightwards_arrows:": { + "category": "Symbols", + "name": "shuffle tracks button", + "unicode": "1f500" + }, + ":two:": { + "category": "Symbols", + "name": "keycap: 2", + "unicode": "0032-20e3", + "unicode_alt": "0032-fe0f-20e3" + }, + ":two_hearts:": { + "category": "Smileys & Emotion", + "name": "two hearts", + "unicode": "1f495" + }, + ":two_men_holding_hands:": { + "category": "People & Body", + "name": "men holding hands", + "unicode": "1f46c" + }, + ":two_women_holding_hands:": { + "category": "People & Body", + "name": "women holding hands", + "unicode": "1f46d" + }, + ":u5272:": { + "category": "Symbols", + "name": "Japanese \u201cdiscount\u201d button", + "unicode": "1f239" + }, + ":u5408:": { + "category": "Symbols", + "name": "Japanese \u201cpassing grade\u201d button", + "unicode": "1f234" + }, + ":u55b6:": { + "category": "Symbols", + "name": "Japanese \u201copen for business\u201d button", + "unicode": "1f23a" + }, + ":u6307:": { + "category": "Symbols", + "name": "Japanese \u201creserved\u201d button", + "unicode": "1f22f" + }, + ":u6708:": { + "category": "Symbols", + "name": "Japanese \u201cmonthly amount\u201d button", + "unicode": "1f237", + "unicode_alt": "1f237-fe0f" + }, + ":u6709:": { + "category": "Symbols", + "name": "Japanese \u201cnot free of charge\u201d button", + "unicode": "1f236" + }, + ":u6e80:": { + "category": "Symbols", + "name": "Japanese \u201cno vacancy\u201d button", + "unicode": "1f235" + }, + ":u7121:": { + "category": "Symbols", + "name": "Japanese \u201cfree of charge\u201d button", + "unicode": "1f21a" + }, + ":u7533:": { + "category": "Symbols", + "name": "Japanese \u201capplication\u201d button", + "unicode": "1f238" + }, + ":u7981:": { + "category": "Symbols", + "name": "Japanese \u201cprohibited\u201d button", + "unicode": "1f232" + }, + ":u7a7a:": { + "category": "Symbols", + "name": "Japanese \u201cvacancy\u201d button", + "unicode": "1f233" + }, + ":uganda:": { + "category": "Flags", + "name": "flag: Uganda", + "unicode": "1f1fa-1f1ec" + }, + ":ukraine:": { + "category": "Flags", + "name": "flag: Ukraine", + "unicode": "1f1fa-1f1e6" + }, + ":umbrella:": { + "category": "Travel & Places", + "name": "umbrella with rain drops", + "unicode": "2614" + }, + ":unamused:": { + "category": "Smileys & Emotion", + "name": "unamused face", + "unicode": "1f612" + }, + ":underage:": { + "category": "Symbols", + "name": "no one under eighteen", + "unicode": "1f51e" + }, + ":unicorn:": { + "category": "Animals & Nature", + "name": "unicorn", + "unicode": "1f984" + }, + ":united_arab_emirates:": { + "category": "Flags", + "name": "flag: United Arab Emirates", + "unicode": "1f1e6-1f1ea" + }, + ":united_nations:": { + "category": "Flags", + "name": "flag: United Nations", + "unicode": "1f1fa-1f1f3" + }, + ":unlock:": { + "category": "Objects", + "name": "unlocked", + "unicode": "1f513" + }, + ":up:": { + "category": "Symbols", + "name": "UP! button", + "unicode": "1f199" + }, + ":upside_down_face:": { + "category": "Smileys & Emotion", + "name": "upside-down face", + "unicode": "1f643" + }, + ":uruguay:": { + "category": "Flags", + "name": "flag: Uruguay", + "unicode": "1f1fa-1f1fe" + }, + ":us:": { + "category": "Flags", + "name": "flag: United States", + "unicode": "1f1fa-1f1f8" + }, + ":us_outlying_islands:": { + "category": "Flags", + "name": "flag: U.S. Outlying Islands", + "unicode": "1f1fa-1f1f2" + }, + ":us_virgin_islands:": { + "category": "Flags", + "name": "flag: U.S. Virgin Islands", + "unicode": "1f1fb-1f1ee" + }, + ":uzbekistan:": { + "category": "Flags", + "name": "flag: Uzbekistan", + "unicode": "1f1fa-1f1ff" + }, + ":v:": { + "category": "People & Body", + "name": "victory hand", + "unicode": "270c", + "unicode_alt": "270c-fe0f" + }, + ":vampire:": { + "category": "People & Body", + "name": "vampire", + "unicode": "1f9db" + }, + ":vampire_man:": { + "category": "People & Body", + "name": "man vampire", + "unicode": "1f9db-2642", + "unicode_alt": "1f9db-200d-2642-fe0f" + }, + ":vampire_woman:": { + "category": "People & Body", + "name": "woman vampire", + "unicode": "1f9db-2640", + "unicode_alt": "1f9db-200d-2640-fe0f" + }, + ":vanuatu:": { + "category": "Flags", + "name": "flag: Vanuatu", + "unicode": "1f1fb-1f1fa" + }, + ":vatican_city:": { + "category": "Flags", + "name": "flag: Vatican City", + "unicode": "1f1fb-1f1e6" + }, + ":venezuela:": { + "category": "Flags", + "name": "flag: Venezuela", + "unicode": "1f1fb-1f1ea" + }, + ":vertical_traffic_light:": { + "category": "Travel & Places", + "name": "vertical traffic light", + "unicode": "1f6a6" + }, + ":vhs:": { + "category": "Objects", + "name": "videocassette", + "unicode": "1f4fc" + }, + ":vibration_mode:": { + "category": "Symbols", + "name": "vibration mode", + "unicode": "1f4f3" + }, + ":video_camera:": { + "category": "Objects", + "name": "video camera", + "unicode": "1f4f9" + }, + ":video_game:": { + "category": "Activities", + "name": "video game", + "unicode": "1f3ae" + }, + ":vietnam:": { + "category": "Flags", + "name": "flag: Vietnam", + "unicode": "1f1fb-1f1f3" + }, + ":violin:": { + "category": "Objects", + "name": "violin", + "unicode": "1f3bb" + }, + ":virgo:": { + "category": "Symbols", + "name": "Virgo", + "unicode": "264d" + }, + ":volcano:": { + "category": "Travel & Places", + "name": "volcano", + "unicode": "1f30b" + }, + ":volleyball:": { + "category": "Activities", + "name": "volleyball", + "unicode": "1f3d0" + }, + ":vomiting_face:": { + "category": "Smileys & Emotion", + "name": "face vomiting", + "unicode": "1f92e" + }, + ":vs:": { + "category": "Symbols", + "name": "VS button", + "unicode": "1f19a" + }, + ":vulcan_salute:": { + "category": "People & Body", + "name": "vulcan salute", + "unicode": "1f596" + }, + ":waffle:": { + "category": "Food & Drink", + "name": "waffle", + "unicode": "1f9c7" + }, + ":wales:": { + "category": "Flags", + "name": "flag: Wales", + "unicode": "1f3f4-e0067-e0062-e0077-e006c-e0073-e007f" + }, + ":walking:": { + "category": "People & Body", + "name": "person walking", + "unicode": "1f6b6" + }, + ":walking_man:": { + "category": "People & Body", + "name": "man walking", + "unicode": "1f6b6-2642", + "unicode_alt": "1f6b6-200d-2642-fe0f" + }, + ":walking_woman:": { + "category": "People & Body", + "name": "woman walking", + "unicode": "1f6b6-2640", + "unicode_alt": "1f6b6-200d-2640-fe0f" + }, + ":wallis_futuna:": { + "category": "Flags", + "name": "flag: Wallis & Futuna", + "unicode": "1f1fc-1f1eb" + }, + ":waning_crescent_moon:": { + "category": "Travel & Places", + "name": "waning crescent moon", + "unicode": "1f318" + }, + ":waning_gibbous_moon:": { + "category": "Travel & Places", + "name": "waning gibbous moon", + "unicode": "1f316" + }, + ":warning:": { + "category": "Symbols", + "name": "warning", + "unicode": "26a0", + "unicode_alt": "26a0-fe0f" + }, + ":wastebasket:": { + "category": "Objects", + "name": "wastebasket", + "unicode": "1f5d1", + "unicode_alt": "1f5d1-fe0f" + }, + ":watch:": { + "category": "Travel & Places", + "name": "watch", + "unicode": "231a" + }, + ":water_buffalo:": { + "category": "Animals & Nature", + "name": "water buffalo", + "unicode": "1f403" + }, + ":water_polo:": { + "category": "People & Body", + "name": "person playing water polo", + "unicode": "1f93d" + }, + ":watermelon:": { + "category": "Food & Drink", + "name": "watermelon", + "unicode": "1f349" + }, + ":wave:": { + "category": "People & Body", + "name": "waving hand", + "unicode": "1f44b" + }, + ":wavy_dash:": { + "category": "Symbols", + "name": "wavy dash", + "unicode": "3030", + "unicode_alt": "3030-fe0f" + }, + ":waxing_crescent_moon:": { + "category": "Travel & Places", + "name": "waxing crescent moon", + "unicode": "1f312" + }, + ":wc:": { + "category": "Symbols", + "name": "water closet", + "unicode": "1f6be" + }, + ":weary:": { + "category": "Smileys & Emotion", + "name": "weary face", + "unicode": "1f629" + }, + ":wedding:": { + "category": "Travel & Places", + "name": "wedding", + "unicode": "1f492" + }, + ":weight_lifting:": { + "category": "People & Body", + "name": "person lifting weights", + "unicode": "1f3cb", + "unicode_alt": "1f3cb-fe0f" + }, + ":weight_lifting_man:": { + "category": "People & Body", + "name": "man lifting weights", + "unicode": "1f3cb-2642", + "unicode_alt": "1f3cb-fe0f-200d-2642-fe0f" + }, + ":weight_lifting_woman:": { + "category": "People & Body", + "name": "woman lifting weights", + "unicode": "1f3cb-2640", + "unicode_alt": "1f3cb-fe0f-200d-2640-fe0f" + }, + ":western_sahara:": { + "category": "Flags", + "name": "flag: Western Sahara", + "unicode": "1f1ea-1f1ed" + }, + ":whale2:": { + "category": "Animals & Nature", + "name": "whale", + "unicode": "1f40b" + }, + ":whale:": { + "category": "Animals & Nature", + "name": "spouting whale", + "unicode": "1f433" + }, + ":wheel:": { + "category": "Travel & Places", + "name": "wheel", + "unicode": "1f6de" + }, + ":wheel_of_dharma:": { + "category": "Symbols", + "name": "wheel of dharma", + "unicode": "2638", + "unicode_alt": "2638-fe0f" + }, + ":wheelchair:": { + "category": "Symbols", + "name": "wheelchair symbol", + "unicode": "267f" + }, + ":white_check_mark:": { + "category": "Symbols", + "name": "check mark button", + "unicode": "2705" + }, + ":white_circle:": { + "category": "Symbols", + "name": "white circle", + "unicode": "26aa" + }, + ":white_flag:": { + "category": "Flags", + "name": "white flag", + "unicode": "1f3f3", + "unicode_alt": "1f3f3-fe0f" + }, + ":white_flower:": { + "category": "Animals & Nature", + "name": "white flower", + "unicode": "1f4ae" + }, + ":white_haired_man:": { + "category": "People & Body", + "name": "man: white hair", + "unicode": "1f468-1f9b3", + "unicode_alt": "1f468-200d-1f9b3" + }, + ":white_haired_woman:": { + "category": "People & Body", + "name": "woman: white hair", + "unicode": "1f469-1f9b3", + "unicode_alt": "1f469-200d-1f9b3" + }, + ":white_heart:": { + "category": "Smileys & Emotion", + "name": "white heart", + "unicode": "1f90d" + }, + ":white_large_square:": { + "category": "Symbols", + "name": "white large square", + "unicode": "2b1c" + }, + ":white_medium_small_square:": { + "category": "Symbols", + "name": "white medium-small square", + "unicode": "25fd" + }, + ":white_medium_square:": { + "category": "Symbols", + "name": "white medium square", + "unicode": "25fb", + "unicode_alt": "25fb-fe0f" + }, + ":white_small_square:": { + "category": "Symbols", + "name": "white small square", + "unicode": "25ab", + "unicode_alt": "25ab-fe0f" + }, + ":white_square_button:": { + "category": "Symbols", + "name": "white square button", + "unicode": "1f533" + }, + ":wilted_flower:": { + "category": "Animals & Nature", + "name": "wilted flower", + "unicode": "1f940" + }, + ":wind_chime:": { + "category": "Activities", + "name": "wind chime", + "unicode": "1f390" + }, + ":wind_face:": { + "category": "Travel & Places", + "name": "wind face", + "unicode": "1f32c", + "unicode_alt": "1f32c-fe0f" + }, + ":window:": { + "category": "Objects", + "name": "window", + "unicode": "1fa9f" + }, + ":wine_glass:": { + "category": "Food & Drink", + "name": "wine glass", + "unicode": "1f377" + }, + ":wing:": { + "category": "Animals & Nature", + "name": "wing", + "unicode": "1fabd" + }, + ":wink:": { + "category": "Smileys & Emotion", + "name": "winking face", + "unicode": "1f609" + }, + ":wireless:": { + "category": "Symbols", + "name": "wireless", + "unicode": "1f6dc" + }, + ":wolf:": { + "category": "Animals & Nature", + "name": "wolf", + "unicode": "1f43a" + }, + ":woman:": { + "category": "People & Body", + "name": "woman", + "unicode": "1f469" + }, + ":woman_artist:": { + "category": "People & Body", + "name": "woman artist", + "unicode": "1f469-1f3a8", + "unicode_alt": "1f469-200d-1f3a8" + }, + ":woman_astronaut:": { + "category": "People & Body", + "name": "woman astronaut", + "unicode": "1f469-1f680", + "unicode_alt": "1f469-200d-1f680" + }, + ":woman_beard:": { + "category": "People & Body", + "name": "woman: beard", + "unicode": "1f9d4-2640", + "unicode_alt": "1f9d4-200d-2640-fe0f" + }, + ":woman_cartwheeling:": { + "category": "People & Body", + "name": "woman cartwheeling", + "unicode": "1f938-2640", + "unicode_alt": "1f938-200d-2640-fe0f" + }, + ":woman_cook:": { + "category": "People & Body", + "name": "woman cook", + "unicode": "1f469-1f373", + "unicode_alt": "1f469-200d-1f373" + }, + ":woman_dancing:": { + "category": "People & Body", + "name": "woman dancing", + "unicode": "1f483" + }, + ":woman_facepalming:": { + "category": "People & Body", + "name": "woman facepalming", + "unicode": "1f926-2640", + "unicode_alt": "1f926-200d-2640-fe0f" + }, + ":woman_factory_worker:": { + "category": "People & Body", + "name": "woman factory worker", + "unicode": "1f469-1f3ed", + "unicode_alt": "1f469-200d-1f3ed" + }, + ":woman_farmer:": { + "category": "People & Body", + "name": "woman farmer", + "unicode": "1f469-1f33e", + "unicode_alt": "1f469-200d-1f33e" + }, + ":woman_feeding_baby:": { + "category": "People & Body", + "name": "woman feeding baby", + "unicode": "1f469-1f37c", + "unicode_alt": "1f469-200d-1f37c" + }, + ":woman_firefighter:": { + "category": "People & Body", + "name": "woman firefighter", + "unicode": "1f469-1f692", + "unicode_alt": "1f469-200d-1f692" + }, + ":woman_health_worker:": { + "category": "People & Body", + "name": "woman health worker", + "unicode": "1f469-2695", + "unicode_alt": "1f469-200d-2695-fe0f" + }, + ":woman_in_manual_wheelchair:": { + "category": "People & Body", + "name": "woman in manual wheelchair", + "unicode": "1f469-1f9bd", + "unicode_alt": "1f469-200d-1f9bd" + }, + ":woman_in_motorized_wheelchair:": { + "category": "People & Body", + "name": "woman in motorized wheelchair", + "unicode": "1f469-1f9bc", + "unicode_alt": "1f469-200d-1f9bc" + }, + ":woman_in_tuxedo:": { + "category": "People & Body", + "name": "woman in tuxedo", + "unicode": "1f935-2640", + "unicode_alt": "1f935-200d-2640-fe0f" + }, + ":woman_judge:": { + "category": "People & Body", + "name": "woman judge", + "unicode": "1f469-2696", + "unicode_alt": "1f469-200d-2696-fe0f" + }, + ":woman_juggling:": { + "category": "People & Body", + "name": "woman juggling", + "unicode": "1f939-2640", + "unicode_alt": "1f939-200d-2640-fe0f" + }, + ":woman_mechanic:": { + "category": "People & Body", + "name": "woman mechanic", + "unicode": "1f469-1f527", + "unicode_alt": "1f469-200d-1f527" + }, + ":woman_office_worker:": { + "category": "People & Body", + "name": "woman office worker", + "unicode": "1f469-1f4bc", + "unicode_alt": "1f469-200d-1f4bc" + }, + ":woman_pilot:": { + "category": "People & Body", + "name": "woman pilot", + "unicode": "1f469-2708", + "unicode_alt": "1f469-200d-2708-fe0f" + }, + ":woman_playing_handball:": { + "category": "People & Body", + "name": "woman playing handball", + "unicode": "1f93e-2640", + "unicode_alt": "1f93e-200d-2640-fe0f" + }, + ":woman_playing_water_polo:": { + "category": "People & Body", + "name": "woman playing water polo", + "unicode": "1f93d-2640", + "unicode_alt": "1f93d-200d-2640-fe0f" + }, + ":woman_scientist:": { + "category": "People & Body", + "name": "woman scientist", + "unicode": "1f469-1f52c", + "unicode_alt": "1f469-200d-1f52c" + }, + ":woman_shrugging:": { + "category": "People & Body", + "name": "woman shrugging", + "unicode": "1f937-2640", + "unicode_alt": "1f937-200d-2640-fe0f" + }, + ":woman_singer:": { + "category": "People & Body", + "name": "woman singer", + "unicode": "1f469-1f3a4", + "unicode_alt": "1f469-200d-1f3a4" + }, + ":woman_student:": { + "category": "People & Body", + "name": "woman student", + "unicode": "1f469-1f393", + "unicode_alt": "1f469-200d-1f393" + }, + ":woman_teacher:": { + "category": "People & Body", + "name": "woman teacher", + "unicode": "1f469-1f3eb", + "unicode_alt": "1f469-200d-1f3eb" + }, + ":woman_technologist:": { + "category": "People & Body", + "name": "woman technologist", + "unicode": "1f469-1f4bb", + "unicode_alt": "1f469-200d-1f4bb" + }, + ":woman_with_headscarf:": { + "category": "People & Body", + "name": "woman with headscarf", + "unicode": "1f9d5" + }, + ":woman_with_probing_cane:": { + "category": "People & Body", + "name": "woman with white cane", + "unicode": "1f469-1f9af", + "unicode_alt": "1f469-200d-1f9af" + }, + ":woman_with_turban:": { + "category": "People & Body", + "name": "woman wearing turban", + "unicode": "1f473-2640", + "unicode_alt": "1f473-200d-2640-fe0f" + }, + ":woman_with_veil:": { + "category": "People & Body", + "name": "woman with veil", + "unicode": "1f470-2640", + "unicode_alt": "1f470-200d-2640-fe0f" + }, + ":womans_clothes:": { + "category": "Objects", + "name": "woman\u2019s clothes", + "unicode": "1f45a" + }, + ":womans_hat:": { + "category": "Objects", + "name": "woman\u2019s hat", + "unicode": "1f452" + }, + ":women_wrestling:": { + "category": "People & Body", + "name": "women wrestling", + "unicode": "1f93c-2640", + "unicode_alt": "1f93c-200d-2640-fe0f" + }, + ":womens:": { + "category": "Symbols", + "name": "women\u2019s room", + "unicode": "1f6ba" + }, + ":wood:": { + "category": "Travel & Places", + "name": "wood", + "unicode": "1fab5" + }, + ":woozy_face:": { + "category": "Smileys & Emotion", + "name": "woozy face", + "unicode": "1f974" + }, + ":world_map:": { + "category": "Travel & Places", + "name": "world map", + "unicode": "1f5fa", + "unicode_alt": "1f5fa-fe0f" + }, + ":worm:": { + "category": "Animals & Nature", + "name": "worm", + "unicode": "1fab1" + }, + ":worried:": { + "category": "Smileys & Emotion", + "name": "worried face", + "unicode": "1f61f" + }, + ":wrench:": { + "category": "Objects", + "name": "wrench", + "unicode": "1f527" + }, + ":wrestling:": { + "category": "People & Body", + "name": "people wrestling", + "unicode": "1f93c" + }, + ":writing_hand:": { + "category": "People & Body", + "name": "writing hand", + "unicode": "270d", + "unicode_alt": "270d-fe0f" + }, + ":x:": { + "category": "Symbols", + "name": "cross mark", + "unicode": "274c" + }, + ":x_ray:": { + "category": "Objects", + "name": "x-ray", + "unicode": "1fa7b" + }, + ":yarn:": { + "category": "Activities", + "name": "yarn", + "unicode": "1f9f6" + }, + ":yawning_face:": { + "category": "Smileys & Emotion", + "name": "yawning face", + "unicode": "1f971" + }, + ":yellow_circle:": { + "category": "Symbols", + "name": "yellow circle", + "unicode": "1f7e1" + }, + ":yellow_heart:": { + "category": "Smileys & Emotion", + "name": "yellow heart", + "unicode": "1f49b" + }, + ":yellow_square:": { + "category": "Symbols", + "name": "yellow square", + "unicode": "1f7e8" + }, + ":yemen:": { + "category": "Flags", + "name": "flag: Yemen", + "unicode": "1f1fe-1f1ea" + }, + ":yen:": { + "category": "Objects", + "name": "yen banknote", + "unicode": "1f4b4" + }, + ":yin_yang:": { + "category": "Symbols", + "name": "yin yang", + "unicode": "262f", + "unicode_alt": "262f-fe0f" + }, + ":yo_yo:": { + "category": "Activities", + "name": "yo-yo", + "unicode": "1fa80" + }, + ":yum:": { + "category": "Smileys & Emotion", + "name": "face savoring food", + "unicode": "1f60b" + }, + ":zambia:": { + "category": "Flags", + "name": "flag: Zambia", + "unicode": "1f1ff-1f1f2" + }, + ":zany_face:": { + "category": "Smileys & Emotion", + "name": "zany face", + "unicode": "1f92a" + }, + ":zap:": { + "category": "Travel & Places", + "name": "high voltage", + "unicode": "26a1" + }, + ":zebra:": { + "category": "Animals & Nature", + "name": "zebra", + "unicode": "1f993" + }, + ":zero:": { + "category": "Symbols", + "name": "keycap: 0", + "unicode": "0030-20e3", + "unicode_alt": "0030-fe0f-20e3" + }, + ":zimbabwe:": { + "category": "Flags", + "name": "flag: Zimbabwe", + "unicode": "1f1ff-1f1fc" + }, + ":zipper_mouth_face:": { + "category": "Smileys & Emotion", + "name": "zipper-mouth face", + "unicode": "1f910" + }, + ":zombie:": { + "category": "People & Body", + "name": "zombie", + "unicode": "1f9df" + }, + ":zombie_man:": { + "category": "People & Body", + "name": "man zombie", + "unicode": "1f9df-2642", + "unicode_alt": "1f9df-200d-2642-fe0f" + }, + ":zombie_woman:": { + "category": "People & Body", + "name": "woman zombie", + "unicode": "1f9df-2640", + "unicode_alt": "1f9df-200d-2640-fe0f" + }, + ":zzz:": { + "category": "Smileys & Emotion", + "name": "ZZZ", + "unicode": "1f4a4" + } +} +aliases = { + ":basketball_man:": ":bouncing_ball_man:", + ":basketball_woman:": ":bouncing_ball_woman:", + ":blonde_woman:": ":blond_haired_woman:", + ":bride_with_veil:": ":woman_with_veil:", + ":collision:": ":boom:", + ":cop:": ":police_officer:", + ":dancer:": ":woman_dancing:", + ":e-mail:": ":email:", + ":european_union:": ":eu:", + ":facepunch:": ":fist_oncoming:", + ":fist:": ":fist_raised:", + ":flipper:": ":dolphin:", + ":fu:": ":middle_finger:", + ":heavy_exclamation_mark:": ":exclamation:", + ":honeybee:": ":bee:", + ":information_desk_person:": ":tipping_hand_person:", + ":knife:": ":hocho:", + ":lantern:": ":izakaya_lantern:", + ":mandarin:": ":tangerine:", + ":ng_man:": ":no_good_man:", + ":ng_woman:": ":no_good_woman:", + ":open_book:": ":book:", + ":orange:": ":tangerine:", + ":paw_prints:": ":feet:", + ":pencil:": ":memo:", + ":poop:": ":hankey:", + ":pout:": ":rage:", + ":punch:": ":fist_oncoming:", + ":raised_hand:": ":hand:", + ":red_car:": ":car:", + ":running:": ":runner:", + ":sailboat:": ":boat:", + ":sassy_man:": ":tipping_hand_man:", + ":sassy_woman:": ":tipping_hand_woman:", + ":satisfied:": ":laughing:", + ":shit:": ":hankey:", + ":shoe:": ":mans_shoe:", + ":telephone:": ":phone:", + ":thumbsdown:": ":-1:", + ":thumbsup:": ":+1:", + ":tshirt:": ":shirt:", + ":uk:": ":gb:", + ":waxing_gibbous_moon:": ":moon:" +} diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/highlight.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/highlight.py new file mode 100644 index 0000000000000000000000000000000000000000..3f303dc5094acc9bc613d41e77961e9c20d93242 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/highlight.py @@ -0,0 +1,615 @@ +""" +Highlight. + +A library for managing code highlighting. + +All Changes Copyright 2014-2017 Isaac Muse. + +--- + +CodeHilite Extension for Python-Markdown +======================================== + +Adds code/syntax highlighting to standard Python-Markdown code blocks. + +See +for documentation. + +Original code Copyright 2006-2008 [Waylan Limberg](https://github.com/waylan). + +All changes Copyright 2008-2014 The Python Markdown Project + +License: [BSD](http://www.opensource.org/licenses/bsd-license.php) +""" +import re +from markdown import Extension +from markdown.treeprocessors import Treeprocessor +import xml.etree.ElementTree as etree +import copy +from collections import OrderedDict +try: + from pygments import highlight + from pygments.lexers import get_lexer_by_name, guess_lexer + from pygments.formatters import find_formatter_class + from pygments import __version__ as pygments_ver + p_ver = tuple([int(n) for n in pygments_ver.split('.')[:2]]) + HtmlFormatter = find_formatter_class('html') + pygments = True +except ImportError: # pragma: no cover + pygments = False + p_ver = (0, 0) + +RE_PYG_CODE = re.compile(r'^<(div)(\s*class="(.*?)")?\s*>') +CODE_WRAP = '{}

  • ' +CODE_WRAP_ON_PRE = '{}
    ' +CLASS_ATTR = ' class="{}"' +ID_ATTR = ' id="{}"' +DEFAULT_CONFIG = { + 'use_pygments': [ + True, + 'Use Pygments to highlight code blocks. ' + 'Disable if using a JavaScript library. ' + 'Default: True' + ], + 'guess_lang': [ + 0, + "Automatic language detection - Default: False" + ], + 'css_class': [ + 'highlight', + "CSS class to apply to wrapper element." + ], + 'pygments_style': [ + 'default', + 'Pygments HTML Formatter Style ' + '(color scheme) - Default: default' + ], + 'noclasses': [ + False, + 'Use inline styles instead of CSS classes - ' + 'Default false' + ], + 'linenums': [ + None, + 'Display line numbers in block code output (not inline) - Default: False' + ], + 'linenums_style': [ + 'table', + 'Line number style -Default: "table"' + ], + 'linenums_special': [ + -1, + 'Globally make nth line special - Default: -1' + ], + 'linenums_class': [ + "linenums", + "Control the linenums class name when not using Pygments - Default: 'linenums'" + ], + 'extend_pygments_lang': [ + [], + 'Extend pygments language with special language entry - Default: []' + ], + 'language_prefix': [ + 'language-', + 'Controls the language prefix for non-Pygments code blocks. - Defaults: "language-"' + ], + 'code_attr_on_pre': [ + False, + "Attach attribute list values on pre element instead of code element - Default: False" + ], + 'auto_title': [ + False, + 'Inject the lexer name as the title for block code - Defaults: False' + ], + 'auto_title_map': [ + {}, + 'User defined mapping of overrides for "auto_title" - Defaults: {}' + ], + 'line_spans': [ + '', + 'If set to a nonempty string, e.g. foo, the formatter will wrap each output line ' + 'in a span tag with an id of foo--. . - Defaults: ""' + ], + 'anchor_linenums': [ + False, + 'If set to True, will wrap line numbers in
    tags. Used in combination with linenums and line_anchors.' + ' - Defaults: False' + ], + 'line_anchors': [ + '', + 'If set to a nonempty string, e.g. foo, the formatter will wrap each output line in an anchor tag with' + ' an id (and name) of foo--. - Defaults: ""' + ], + 'pygments_lang_class': [ + False, + 'If set to True, the language name used will be included as a class attached to the element. - Defaults: False' + ], + 'stripnl': [ + True, + 'Strips leading and trailing newlines from code blocks. This is Pygments default behavior. Setting this to ' + 'False disables this and will retain leading and trailing newlines. This has no affect on inline code. ' + '- Defaults: True' + ], + 'default_lang': [ + '', + 'The assumed highlight language of a code block when no language is set. - Default text' + ], + '_enabled': [ + True, + 'Used internally to communicate if extension has been explicitly enabled - Default: False' + ] +} + +if pygments: + class InlineHtmlFormatter(HtmlFormatter): + """Format the code blocks.""" + + def _wrap_div(self, inner): + """Do not wrap with `div`.""" + + yield from inner + + def wrap(self, source): + """Overload wrap.""" + + return self._wrap_code(source) + + def _wrap_code(self, source): + """Return source, but do not wrap in inline block.""" + + yield 0, '' + for i, t in source: + yield i, t.strip() + yield 0, '' + + class BlockHtmlFormatter(HtmlFormatter): + """Adds ability to output line numbers in a new way.""" + + # Capture ` 1 ` + RE_SPAN_NUMS = re.compile(r'(]*?)(class="[^"]*\blinenos?\b[^"]*)"([^>]*)>([^<]+)()') + # Capture `
    ` that is not followed by ``
    +        RE_TABLE_NUMS = re.compile(r'(]*>)(?!)')
    +
    +        def __init__(self, **options):
    +            """Initialize."""
    +
    +            self.pymdownx_inline = options.get('linenos', False) == 'pymdownx-inline'
    +            if self.pymdownx_inline:
    +                options['linenos'] = 'inline'
    +            HtmlFormatter.__init__(self, **options)
    +
    +        def _format_custom_line(self, m):
    +            """Format the custom line number."""
    +
    +            # We've broken up the match in such a way that we not only
    +            # move the line number value to `data-linenos`, but we could
    +            # wrap the gutter number in the future with a highlight class.
    +            # The decision to do this has still not be made.
    +
    +            return (
    +                m.group(1) +
    +                m.group(2) +
    +                '"' +
    +                m.group(3) +
    +                ' data-linenos="' + m.group(4) + ' ">' +
    +                m.group(5)
    +            )
    +
    +        def _wrap_customlinenums(self, inner):
    +            """
    +            Wrapper to handle block inline line numbers.
    +
    +            For our special inline version, don't display line numbers via `  1`,
    +            but include as `` and use CSS to display them:
    +            `[data-linenos]:before {content: attr(data-linenos);}`.  This allows us to use
    +            inline and copy and paste without issue.
    +            """
    +
    +            for t, line in inner:
    +                if t:
    +                    line = self.RE_SPAN_NUMS.sub(self._format_custom_line, line)
    +                yield t, line
    +
    +        def wrap(self, source):
    +            """Wrap the source code."""
    +
    +            if self.linenos == 2 and self.pymdownx_inline:
    +                source = self._wrap_customlinenums(source)
    +            return HtmlFormatter.wrap(self, source)
    +
    +        def _wrap_tablelinenos(self, inner):
    +            """
    +            Wrapper to handle line numbers better in table.
    +
    +            Pygments currently has a bug with line step where leading blank lines collapse.
    +            Use the same fix Pygments uses for code content for code line numbers.
    +            This fix should be pull requested on the Pygments repository.
    +            """
    +
    +            for t, line in HtmlFormatter._wrap_tablelinenos(self, inner):
    +                yield t, self.RE_TABLE_NUMS.sub(r'\1', line)
    +
    +
    +class Highlight:
    +    """Highlight class."""
    +
    +    def __init__(
    +        self, guess_lang=False, pygments_style='default', use_pygments=True,
    +        noclasses=False, extend_pygments_lang=None, linenums=None, linenums_special=-1,
    +        linenums_style='table', linenums_class='linenums', language_prefix='language-',
    +        code_attr_on_pre=False, auto_title=False, auto_title_map=None, line_spans='',
    +        anchor_linenums=False, line_anchors='', pygments_lang_class=False, stripnl=True,
    +        default_lang=''
    +    ):
    +        """Initialize."""
    +
    +        self.guess_lang = guess_lang
    +        self.pygments_style = pygments_style
    +        self.use_pygments = use_pygments
    +        self.noclasses = noclasses
    +        self.linenums = linenums
    +        self.linenums_style = linenums_style
    +        self.linenums_special = linenums_special
    +        self.linenums_class = linenums_class
    +        self.language_prefix = language_prefix
    +        self.code_attr_on_pre = code_attr_on_pre
    +        self.auto_title = auto_title
    +        self.line_spans = line_spans
    +        self.line_anchors = line_anchors
    +        self.anchor_linenums = anchor_linenums
    +        self.pygments_lang_class = pygments_lang_class
    +        self.stripnl = stripnl
    +        self.default_lang = default_lang
    +
    +        if self.anchor_linenums and not self.line_anchors:
    +            self.line_anchors = '__codelineno'
    +
    +        if auto_title_map is None:
    +            auto_title_map = {}
    +        self.auto_title_map = auto_title_map
    +
    +        if extend_pygments_lang is None:  # pragma: no cover
    +            extend_pygments_lang = []
    +        self.extend_pygments_lang = {}
    +        for language in extend_pygments_lang:
    +            if isinstance(language, (dict, OrderedDict)):
    +                name = language.get('name')
    +                if name is not None and name not in self.extend_pygments_lang:
    +                    self.extend_pygments_lang[name.lower()] = [
    +                        language.get('lang'),
    +                        language.get('options', {})
    +                    ]
    +
    +    def get_extended_language(self, language):
    +        """Get extended language."""
    +
    +        return self.extend_pygments_lang.get(language.lower(), (language, {}))
    +
    +    def get_lexer(self, src, language, inline, stripnl):
    +        """Get the Pygments lexer."""
    +
    +        name = language
    +
    +        lexer_options = {'stripnl': stripnl}
    +        if language:
    +            language, options = self.get_extended_language(language)
    +            lexer_options.update(options)
    +
    +        # Try and get lexer by the name given.
    +        try:
    +            lexer = get_lexer_by_name(language, **lexer_options)
    +        except Exception:
    +            lexer = None
    +
    +        if lexer is None:
    +            if (self.guess_lang is True) or (self.guess_lang == 'inline' if inline else self.guess_lang == 'block'):
    +                try:
    +                    lexer = guess_lexer(src, **lexer_options)
    +                    name = lexer.aliases[0]
    +                except Exception:  # pragma: no cover
    +                    pass
    +        if lexer is None:
    +            lexer = get_lexer_by_name(self.default_lang or 'text', **lexer_options)
    +            name = lexer.aliases[0]
    +        return lexer, name
    +
    +    def escape(self, txt):
    +        """Basic HTML escaping."""
    +
    +        txt = txt.replace('&', '&')
    +        txt = txt.replace('<', '<')
    +        txt = txt.replace('>', '>')
    +        return txt
    +
    +    def highlight(
    +        self, src, language, css_class='highlight', hl_lines=None,
    +        linestart=-1, linestep=-1, linespecial=-1, inline=False, classes=None, id_value='', attrs=None,
    +        title=None, code_block_count=0
    +    ):
    +        """Highlight code."""
    +
    +        if attrs is None:
    +            attrs = {}
    +        class_names = classes[:] if classes else []
    +        linenums_enabled = (
    +            (self.linenums and linestart != 0) or
    +            (self.linenums is not False and linestart > 0)
    +        ) and not inline > 0
    +        class_str = ''
    +
    +        if not language and self.default_lang:
    +            language = self.default_lang
    +
    +        # Convert with Pygments.
    +        if pygments and self.use_pygments:
    +
    +            if p_ver < (2, 12):  # pragma: no cover
    +                raise RuntimeError('Pymdownx Highlight requires at least Pygments 2.12+ if enabling Pygments')
    +
    +            if inline:
    +                stripnl = True
    +            else:
    +                stripnl = self.stripnl
    +
    +            # Setup language lexer.
    +            lexer, lang_name = self.get_lexer(src, language, inline, stripnl)
    +            if self.pygments_lang_class:
    +                class_names.insert(0, self.language_prefix + lang_name)
    +            linenums = self.linenums_style if linenums_enabled else False
    +
    +            if class_names:
    +                if inline:
    +                    css_class = ' {}'.format('' if not css_class else css_class)
    +                    css_class = ' '.join(class_names) + css_class
    +                    stripped = css_class.strip()
    +                    css_class = stripped
    +
    +            id_str = ID_ATTR.format(id_value) if id_value else ''
    +
    +            lineno_id = id_value if id_value else str(code_block_count)
    +
    +            if not attrs:
    +                attr_str = ''
    +            else:
    +                temp = []
    +                for k, v in attrs.items():
    +                    if k.startswith('data-'):
    +                        temp.append(f'{k}="{v}"')
    +                attr_str = ' ' + ' '.join(temp) if temp else ''
    +
    +            # Setup line specific settings.
    +            if not linenums or linestep < 1:
    +                linestep = 1
    +            if not linenums or linestart < 1:
    +                linestart = 1
    +            if self.linenums_special >= 0 and linespecial < 0:
    +                linespecial = self.linenums_special
    +            if not linenums or linespecial < 0:
    +                linespecial = 0
    +            if hl_lines is None or inline:
    +                hl_lines = []
    +
    +            if title is None and self.auto_title:
    +                name = " ".join([w.title() if w.islower() else w for w in lexer.name.split()])
    +                title = self.auto_title_map.get(name, name)
    +            if title:
    +                title = title.strip()
    +            if title is None:
    +                title = ''
    +
    +            # Setup formatter
    +            html_formatter = InlineHtmlFormatter if inline else BlockHtmlFormatter
    +            formatter = html_formatter(
    +                cssclass=css_class,
    +                linenos=linenums,
    +                linenostart=linestart,
    +                linenostep=linestep,
    +                linenospecial=linespecial,
    +                style=self.pygments_style,
    +                noclasses=self.noclasses,
    +                hl_lines=hl_lines,
    +                wrapcode=True,
    +                filename=title if not inline else "",
    +                linespans=f"{self.line_spans}-{lineno_id}" if self.line_spans and not inline else '',
    +                lineanchors=(
    +                    f"{self.line_anchors}-{lineno_id}" if self.line_anchors and not inline else ""
    +                ),
    +                anchorlinenos=self.anchor_linenums if not inline else False
    +            )
    +
    +            # Convert
    +            code = highlight(src, lexer, formatter)
    +            if inline:
    +                class_str = css_class
    +                attr_str = ''
    +            else:
    +                m = RE_PYG_CODE.match(code)
    +                if m is not None:
    +                    end = m.end(0)
    +                    start = m.start(0)
    +                    if class_names:
    +                        if m.group(2):
    +                            classes = ' class="{} {}"'.format(' '.join(class_names), m.group(3).strip())
    +                        else:
    +                            classes = ' class="{}"'.format(' '.join(class_names))
    +                    else:
    +                        classes = ' ' + m.group(2).lstrip() if m.group(2) else ''
    +
    +                    code = f'{code[:start]}<{m.group(1)}{id_str}{classes}{attr_str}>{code[end:]}'
    +
    +        elif inline:
    +            # Format inline code for a JavaScript Syntax Highlighter by specifying language.
    +            code = self.escape(src)
    +            if css_class:
    +                class_names.insert(0, css_class)
    +            if language:
    +                class_names.insert(0, self.language_prefix + language)
    +            class_str = ' '.join(class_names) if class_names else ''
    +            id_str = id_value
    +        else:
    +            # Format block code for a JavaScript Syntax Highlighter by specifying language.
    +            if self.code_attr_on_pre and css_class:
    +                class_names.insert(0, css_class)
    +            if language:
    +                class_names.insert(0, self.language_prefix + language)
    +            class_str = CLASS_ATTR.format(' '.join(class_names)) if class_names else ''
    +            id_str = ID_ATTR.format(id_value) if id_value else ''
    +            attr_str = ' ' + ' '.join(f'{k}="{v}"' for k, v in attrs.items()) if attrs else ''
    +            if not self.code_attr_on_pre:
    +                highlight_class = (CLASS_ATTR.format(css_class)) if css_class else ''
    +                code = CODE_WRAP.format(highlight_class, id_str, class_str, attr_str, self.escape(src))
    +            else:
    +                code = CODE_WRAP_ON_PRE.format(id_str, class_str, attr_str, self.escape(src))
    +
    +        if inline:
    +            attributes = {}
    +
    +            if class_str:
    +                attributes['class'] = class_str
    +
    +            # This code exists for consistency, but we currently don't
    +            # ever feed extra ids or attributes for inline code.
    +            # We let `attr_list` handle this directly, but if we did
    +            # need this, we would then want to exercise this logic.
    +            if id_str:  # pragma: no cover
    +                attributes['id'] = id_str
    +            for k, v in attrs:  # pragma: no cover
    +                attributes[k] = v  # noqa: PERF403
    +
    +            el = etree.Element('code', attributes)
    +            el.text = code
    +            return el
    +        else:
    +            return code.strip()
    +
    +
    +class HighlightTreeprocessor(Treeprocessor):
    +    """Highlight source code in code blocks."""
    +
    +    def __init__(self, md, ext):
    +        """Initialize."""
    +
    +        self.ext = ext
    +        super().__init__(md)
    +
    +    def code_unescape(self, text):
    +        """Unescape code."""
    +        text = text.replace("<", "<")
    +        text = text.replace(">", ">")
    +        text = text.replace("&", "&")
    +        return text
    +
    +    def run(self, root):
    +        """Find code blocks and store in `htmlStash`."""
    +
    +        blocks = root.iter('pre')
    +        for block in blocks:
    +            if len(block) == 1 and block[0].tag == 'code':
    +
    +                self.ext.pygments_code_block += 1
    +                code = Highlight(
    +                    guess_lang=self.config['guess_lang'],
    +                    pygments_style=self.config['pygments_style'],
    +                    use_pygments=self.config['use_pygments'],
    +                    noclasses=self.config['noclasses'],
    +                    linenums=self.config['linenums'],
    +                    linenums_style=self.config['linenums_style'],
    +                    linenums_special=self.config['linenums_special'],
    +                    linenums_class=self.config['linenums_class'],
    +                    extend_pygments_lang=self.config['extend_pygments_lang'],
    +                    language_prefix=self.config['language_prefix'],
    +                    code_attr_on_pre=self.config['code_attr_on_pre'],
    +                    auto_title=self.config['auto_title'],
    +                    auto_title_map=self.config['auto_title_map'],
    +                    pygments_lang_class=self.config['pygments_lang_class'],
    +                    stripnl=self.config['stripnl'],
    +                    default_lang=self.config['default_lang']
    +                )
    +                placeholder = self.md.htmlStash.store(
    +                    code.highlight(
    +                        self.code_unescape(block[0].text).rstrip('\n'),
    +                        '',
    +                        self.config['css_class'],
    +                        code_block_count=self.ext.pygments_code_block
    +                    )
    +                )
    +
    +                # Clear code block in `etree` instance
    +                block.clear()
    +                # Change to `p` element which will later
    +                # be removed when inserting raw HTML
    +                block.tag = 'p'
    +                block.text = placeholder
    +
    +
    +class HighlightExtension(Extension):
    +    """Configure highlight settings globally."""
    +
    +    def __init__(self, *args, **kwargs):
    +        """Initialize."""
    +
    +        self.config = copy.deepcopy(DEFAULT_CONFIG)
    +        super().__init__(*args, **kwargs)
    +
    +    def get_pymdownx_highlight_settings(self):
    +        """Get the specified extension."""
    +
    +        target = None
    +
    +        if self.enabled:
    +            target = self.getConfigs()
    +
    +        if target is None:
    +            target = {}
    +            config_clone = copy.deepcopy(DEFAULT_CONFIG)
    +            for k in config_clone.keys():
    +                target[k] = config_clone[k][0]
    +
    +        return target
    +
    +    def get_pymdownx_highlighter(self):
    +        """Get the highlighter."""
    +
    +        return Highlight
    +
    +    def extendMarkdown(self, md):
    +        """Add support for code highlighting."""
    +
    +        config = self.getConfigs()
    +        self.pygments_code_block = -1
    +        self.md = md
    +        self.enabled = config.get("_enabled", False)
    +
    +        if self.enabled:
    +            ht = HighlightTreeprocessor(self.md, self)
    +            ht.config = self.getConfigs()
    +            self.md.treeprocessors.register(ht, "indent-highlight", 30)
    +
    +        index = 0
    +        register = None
    +        for ext in self.md.registeredExtensions:
    +            if isinstance(ext, HighlightExtension):
    +                register = not ext.enabled and self.enabled
    +                break
    +            index += 1
    +
    +        if register is None:
    +            register = True
    +            index = -1
    +
    +        if register:
    +            if index == -1:
    +                self.md.registerExtension(self)
    +            else:
    +                self.md.registeredExtensions[index] = self
    +
    +    def reset(self):
    +        """Reset."""
    +
    +        self.pygments_code_block = -1
    +
    +
    +def makeExtension(*args, **kwargs):
    +    """Return extension."""
    +
    +    return HighlightExtension(*args, **kwargs)
    diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/inlinehilite.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/inlinehilite.py
    new file mode 100644
    index 0000000000000000000000000000000000000000..4e3800a04fddbdb255894071b2407d8f64beddd3
    --- /dev/null
    +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/inlinehilite.py
    @@ -0,0 +1,228 @@
    +"""
    +Inline Highlighting.
    +
    +pymdownx.inlinehilite
    +
    +An alternative inline code extension that highlights code.  Can
    +use CodeHilite to source its settings or pymdownx.highlight.
    +
    +`:::javascript var test = 0;`
    +
    +- or -
    +
    +`#!javascript var test = 0;`
    +
    +Copyright 2014 - 2017 Isaac Muse 
    +"""
    +
    +from markdown import Extension
    +from markdown.inlinepatterns import InlineProcessor
    +from markdown import util as md_util
    +import xml.etree.ElementTree as etree
    +import functools
    +
    +ESCAPED_BSLASH = '{}{}{}'.format(md_util.STX, ord('\\'), md_util.ETX)
    +DOUBLE_BSLASH = '\\\\'
    +BACKTICK_CODE_RE = r'''(?x)
    +(?:
    +(?(?:\\{2})+)(?=`+) |  # Process code escapes before code
    +(?`+)
    +((?:\:{3,}|\#!)(?P[\w#.+-]*)\s+)? # Optional language
    +(?P.+?)                           # Code
    +(?', '>')
    +    return txt
    +
    +
    +def _test(language, test_language=None):
    +    """Test language."""
    +
    +    return test_language is None or test_language == '*' or language == test_language
    +
    +
    +def _formatter(src="", language="", md=None, class_name="", fmt=None):
    +    """Formatter wrapper."""
    +
    +    return fmt(src, language, class_name, md)
    +
    +
    +class InlineHilitePattern(InlineProcessor):
    +    """Handle the inline code patterns."""
    +
    +    def __init__(self, pattern, config, md):
    +        """Initialize."""
    +
    +        self.config = config
    +        InlineProcessor.__init__(self, pattern, md)
    +        self.md = md
    +
    +        self.formatters = [
    +            {
    +                "name": "inlinehilite",
    +                "test": _test,
    +                "formatter": self.highlight_code
    +            }
    +        ]
    +
    +        # Custom Fences
    +        custom_inline = self.config.get('custom_inline', [])
    +        for custom in custom_inline:
    +            name = custom.get('name')
    +            class_name = custom.get('class')
    +            inline_format = custom.get('format', self.highlight_code)
    +            if name is not None and class_name is not None:
    +                self.extend_custom_inline(
    +                    name,
    +                    functools.partial(_formatter, class_name=class_name, fmt=inline_format)
    +                )
    +
    +        self.get_hl_settings = False
    +
    +    def extend_custom_inline(self, name, formatter):
    +        """Extend SuperFences with the given name, language, and formatter."""
    +
    +        obj = {
    +            "name": name,
    +            "test": functools.partial(_test, test_language=name),
    +            "formatter": formatter
    +        }
    +
    +        if name == '*':
    +            self.formatters[0] = obj
    +        else:
    +            self.formatters.append(obj)
    +
    +    def get_settings(self):
    +        """Check for Highlight extension settings."""
    +
    +        if not self.get_hl_settings:
    +            self.get_hl_settings = True
    +            self.style_plain_text = self.config['style_plain_text']
    +
    +            config = None
    +            self.highlighter = None
    +            for ext in self.md.registeredExtensions:
    +                try:
    +                    config = ext.get_pymdownx_highlight_settings()
    +                    self.highlighter = ext.get_pymdownx_highlighter()
    +                    break
    +                except AttributeError:
    +                    pass
    +
    +            css_class = self.config['css_class']
    +            self.css_class = css_class if css_class else config['css_class']
    +
    +            self.extend_pygments_lang = config.get('extend_pygments_lang', None)
    +            self.guess_lang = config['guess_lang']
    +            self.pygments_style = config['pygments_style']
    +            self.use_pygments = config['use_pygments']
    +            self.noclasses = config['noclasses']
    +            self.language_prefix = config['language_prefix']
    +            self.pygments_lang_class = config['pygments_lang_class']
    +
    +    def highlight_code(self, src='', language='', classname=None, md=None):
    +        """Syntax highlight the inline code block."""
    +
    +        process_text = self.style_plain_text or language or self.guess_lang
    +        default_lang = self.style_plain_text if isinstance(self.style_plain_text, str) else ''
    +
    +        if process_text:
    +            el = self.highlighter(
    +                guess_lang=self.guess_lang,
    +                pygments_style=self.pygments_style,
    +                use_pygments=self.use_pygments,
    +                noclasses=self.noclasses,
    +                extend_pygments_lang=self.extend_pygments_lang,
    +                language_prefix=self.language_prefix,
    +                pygments_lang_class=self.pygments_lang_class,
    +                default_lang=default_lang
    +            ).highlight(src, language, self.css_class, inline=True)
    +            el.text = self.md.htmlStash.store(el.text)
    +        else:
    +            el = etree.Element('code')
    +            el.text = self.md.htmlStash.store(_escape(src))
    +        return el
    +
    +    def handle_code(self, lang, src):
    +        """Handle code block."""
    +
    +        for entry in reversed(self.formatters):
    +            if entry["test"](lang):
    +                value = entry["formatter"](
    +                    src=src,
    +                    language=lang,
    +                    md=self.md
    +                )
    +                if isinstance(value, str):
    +                    value = self.md.htmlStash.store(value)
    +                return value
    +
    +    def handleMatch(self, m, data):
    +        """Handle the pattern match."""
    +
    +        if m.group('escapes'):
    +            return m.group('escapes').replace(DOUBLE_BSLASH, ESCAPED_BSLASH), m.start(0), m.end(0)
    +        else:
    +            lang = m.group('lang') if m.group('lang') else ''
    +            src = m.group('code').strip()
    +            self.get_settings()
    +            try:
    +                return self.handle_code(lang, src), m.start(0), m.end(0)
    +            except InlineHiliteException:
    +                raise
    +            except Exception:
    +                return m.group(0), None, None
    +
    +
    +class InlineHiliteExtension(Extension):
    +    """Add inline highlighting extension to Markdown class."""
    +
    +    def __init__(self, *args, **kwargs):
    +        """Initialize."""
    +
    +        self.inlinehilite = []
    +        self.config = {
    +            'style_plain_text': [
    +                0,
    +                "Process inline code even when a language is not specified. "
    +                "When 'False', no classes will be added to code blocks without shebangs "
    +                "and no scoping will performed. The content will just be escaped."
    +                "If a language string is provided, then that language will be assumed "
    +                "for any inline code block without a shebang. "
    +                "- Default: False"
    +            ],
    +            'css_class': [
    +                '',
    +                "Set class name for wrapper element. The default of Highlight will be used"
    +                "if nothing is set. - "
    +                "Default: ''"
    +            ],
    +            'custom_inline': [[], "Custom inline - default []"]
    +        }
    +        super().__init__(*args, **kwargs)
    +
    +    def extendMarkdown(self, md):
    +        """Add support for `:::language code` and `#!language code` highlighting."""
    +
    +        config = self.getConfigs()
    +        md.inlinePatterns.register(InlineHilitePattern(BACKTICK_CODE_RE, config, md), "backtick", 190)
    +        md.registerExtensions(["pymdownx.highlight"], {"pymdownx.highlight": {"_enabled": False}})
    +
    +
    +def makeExtension(*args, **kwargs):
    +    """Return extension."""
    +
    +    return InlineHiliteExtension(*args, **kwargs)
    diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/keymap_db.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/keymap_db.py
    new file mode 100644
    index 0000000000000000000000000000000000000000..3c76ef3f694b174d44b466572286203df6024d1b
    --- /dev/null
    +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/keymap_db.py
    @@ -0,0 +1,324 @@
    +"""English US keymap."""
    +
    +keymap = {
    +    # Digits
    +    "0": "0",
    +    "1": "1",
    +    "2": "2",
    +    "3": "3",
    +    "4": "4",
    +    "5": "5",
    +    "6": "6",
    +    "7": "7",
    +    "8": "8",
    +    "9": "9",
    +
    +    # Letters
    +    "a": "A",
    +    "b": "B",
    +    "c": "C",
    +    "d": "D",
    +    "e": "E",
    +    "f": "F",
    +    "g": "G",
    +    "h": "H",
    +    "i": "I",
    +    "j": "J",
    +    "k": "K",
    +    "l": "L",
    +    "m": "M",
    +    "n": "N",
    +    "o": "O",
    +    "p": "P",
    +    "q": "Q",
    +    "r": "R",
    +    "s": "S",
    +    "t": "T",
    +    "u": "U",
    +    "v": "V",
    +    "w": "W",
    +    "x": "X",
    +    "y": "Y",
    +    "z": "Z",
    +
    +    # Space
    +    "space": "Space",
    +
    +    # Punctuation
    +    "backslash": "\\",
    +    "bar": "|",
    +    "brace-left": "{",
    +    "brace-right": "}",
    +    "bracket-left": "[",
    +    "bracket-right": "]",
    +    "colon": ":",
    +    "comma": ",",
    +    "double-quote": "\"",
    +    "equal": "=",
    +    "exclam": "!",
    +    "grave": "`",
    +    "greater": ">",
    +    "less": "<",
    +    "minus": "-",
    +    "period": ".",
    +    "plus": "+",
    +    "question": "?",
    +    "semicolon": ";",
    +    "single-quote": "'",
    +    "slash": "/",
    +    "tilde": "~",
    +    "underscore": "_",
    +
    +    # Navigation keys
    +    "arrow-up": "Up",
    +    "arrow-down": "Down",
    +    "arrow-left": "Left",
    +    "arrow-right": "Right",
    +    "page-up": "Page Up",
    +    "page-down": "Page Down",
    +    "home": "Home",
    +    "end": "End",
    +
    +
    +    # Edit keys
    +    "backspace": "Backspace",
    +    "delete": "Del",
    +    "insert": "Ins",
    +    "tab": "Tab",
    +
    +    # Action keys
    +    "break": "Break",
    +    "caps-lock": "Caps Lock",
    +    "clear": "Clear",
    +    "eject": "Eject",
    +    "enter": "Enter",
    +    "escape": "Esc",
    +    "help": "Help",
    +    "print-screen": "Print Screen",
    +    "scroll-lock": "Scroll Lock",
    +
    +    # Numeric keypad
    +    "num0": "Num 0",
    +    "num1": "Num 1",
    +    "num2": "Num 2",
    +    "num3": "Num 3",
    +    "num4": "Num 4",
    +    "num5": "Num 5",
    +    "num6": "Num 6",
    +    "num7": "Num 7",
    +    "num8": "Num 8",
    +    "num9": "Num 9",
    +    "num-asterisk": "Num *",
    +    "num-clear": "Num Clear",
    +    "num-delete": "Num Del",
    +    "num-equal": "Num =",
    +    "num-lock": "Num Lock",
    +    "num-minus": "Num -",
    +    "num-plus": "Num +",
    +    "num-separator": "Num .",
    +    "num-slash": "Num /",
    +    "num-enter": "Num Enter",
    +
    +    # Modifier keys
    +    "alt": "Alt",
    +    "alt-graph": "AltGr",
    +    "command": "Cmd",
    +    "control": "Ctrl",
    +    "function": "Fn",
    +    "left-alt": "Left Alt",
    +    "left-command": "Left Command",
    +    "left-control": "Left Ctrl",
    +    "left-meta": "Left Meta",
    +    "left-option": "Left Option",
    +    "left-shift": "Left Shift",
    +    "left-super": "Left Super",
    +    "left-windows": "Left Win",
    +    "meta": "Meta",
    +    "option": "Option",
    +    "right-alt": "Right Alt",
    +    "right-command": "Right Command",
    +    "right-control": "Right Ctrl",
    +    "right-meta": "Right Meta",
    +    "right-option": "Right Option",
    +    "right-shift": "Right Shift",
    +    "right-super": "Right Super",
    +    "right-windows": "Right Win",
    +    "shift": "Shift",
    +    "super": "Super",
    +    "windows": "Win",
    +
    +    # Function keys
    +    "f1": "F1",
    +    "f2": "F2",
    +    "f3": "F3",
    +    "f4": "F4",
    +    "f5": "F5",
    +    "f6": "F6",
    +    "f7": "F7",
    +    "f8": "F8",
    +    "f9": "F9",
    +    "f10": "F10",
    +    "f11": "F11",
    +    "f12": "F12",
    +    "f13": "F13",
    +    "f14": "F14",
    +    "f15": "F15",
    +    "f16": "F16",
    +    "f17": "F17",
    +    "f18": "F18",
    +    "f19": "F19",
    +    "f20": "F20",
    +    "f21": "F21",
    +    "f22": "F22",
    +    "f23": "F23",
    +    "f24": "F24",
    +
    +    # Extra keys
    +    "backtab": "Back Tab",
    +    "browser-back": "Browser Back",
    +    "browser-favorites": "Browser Favorites",
    +    "browser-forward": "Browser Forward",
    +    "browser-home": "Browser Home",
    +    "browser-refresh": "Browser Refresh",
    +    "browser-search": "Browser Search",
    +    "browser-stop": "Browser Stop",
    +    "context-menu": "Menu",
    +    "copy": "Copy",
    +    "mail": "Mail",
    +    "media": "Media",
    +    "media-next-track": "Next Track",
    +    "media-pause": "Pause",
    +    "media-play": "Play",
    +    "media-play-pause": "Play/Pause",
    +    "media-prev-track": "Previous Track",
    +    "media-stop": "Stop",
    +    "print": "Print",
    +    "reset": "Reset",
    +    "select": "Select",
    +    "sleep": "Sleep",
    +    "volume-down": "Volume Down",
    +    "volume-mute": "Mute",
    +    "volume-up": "Volume Up",
    +    "zoom": "Zoom",
    +    "power": "Power",
    +    "fingerprint": "Fingerprint",
    +
    +    # Mouse
    +    "left-button": "Left Button",
    +    "middle-button": "Middle Button",
    +    "right-button": "Right Button",
    +    "x-button1": "X Button 1",
    +    "x-button2": "X Button 2"
    +}
    +
    +aliases = {
    +    "add": "num-plus",
    +    "altgr": "alt-graph",
    +    "apps": "context-menu",
    +    "back": "backspace",
    +    "bksp": "backspace",
    +    "bktab": "backtab",
    +    "cancel": "break",
    +    "capital": "caps-lock",
    +    "close-brace": "brace-right",
    +    "close-bracket": "bracket-right",
    +    "clr": "clear",
    +    "cmd": "command",
    +    "cplk": "caps-lock",
    +    "ctrl": "control",
    +    "dblquote": "double-quote",
    +    "decimal": "num-separator",
    +    "del": "delete",
    +    "divide": "num-slash",
    +    "down": "arrow-down",
    +    "esc": "escape",
    +    "return": "enter",
    +    "exclamation": "exclam",
    +    "favorites": "browser-favorites",
    +    "fn": "function",
    +    "forward": "browser-forward",
    +    "grave-accent": "grave",
    +    "greater-than": "greater",
    +    "gt": "greater",
    +    "hyphen": "minus",
    +    "ins": "insert",
    +    "lalt": "left-alt",
    +    "launch-mail": "mail",
    +    "launch-media": "media",
    +    "lbutton": "left-button",
    +    "lcmd": "left-command",
    +    "lcommand": "left-command",
    +    "lcontrol": "left-control",
    +    "lctrl": "left-control",
    +    "left": "arrow-left",
    +    "left-cmd": "left-command",
    +    "left-ctrl": "left-control",
    +    "lopt": "left-option",
    +    "loption": "left-option",
    +    "left-opt": "left-option",
    +    "left-win": "left-windows",
    +    "less-than": "less",
    +    "lmeta": "left-meta",
    +    "lshift": "left-shift",
    +    "lsuper": "left-super",
    +    "lt": "less",
    +    "lwin": "left-windows",
    +    "lwindows": "left-windows",
    +    "mbutton": "middle-button",
    +    "menu": "context-menu",
    +    "multiply": "num-asterisk",
    +    "mute": "volume-mute",
    +    "next": "page-down",
    +    "next-track": "media-next-track",
    +    "num-del": "num-delete",
    +    "numlk": "num-lock",
    +    "open-brace": "brace-left",
    +    "open-bracket": "bracket-left",
    +    "opt": "option",
    +    "page-dn": "page-down",
    +    "page-up": "page-up",
    +    "pause": "media-pause",
    +    "pg-dn": "page-down",
    +    "pg-up": "page-up",
    +    "pipe": "bar",
    +    "play": "media-play",
    +    "play-pause": "media-play-pause",
    +    "prev-track": "media-prev-track",
    +    "prior": "page-up",
    +    "prtsc": "print-screen",
    +    "question-mark": "question",
    +    "ralt": "right-alt",
    +    "rbutton": "right-button",
    +    "rcontrol": "right-control",
    +    "rcmd": "right-command",
    +    "rcommand": "right-command",
    +    "rctrl": "right-control",
    +    "refresh": "browser-refresh",
    +    "right": "arrow-right",
    +    "right-cmd": "right-command",
    +    "right-ctrl": "right-control",
    +    "right-meta": "right-meta",
    +    "right-opt": "right-option",
    +    "right-win": "right-windows",
    +    "rmeta": "right-meta",
    +    "ropt": "right-option",
    +    "roption": "right-option",
    +    "rshift": "right-shift",
    +    "rsuper": "right-super",
    +    "rwin": "right-windows",
    +    "rwindows": "right-windows",
    +    "scroll": "scroll-lock",
    +    "search": "browser-search",
    +    "separator": "num-separator",
    +    "spc": "space",
    +    "stop": "media-stop",
    +    "subtract": "num-minus",
    +    "tabulator": "tab",
    +    "up": "arrow-up",
    +    "vol-down": "volume-down",
    +    "vol-mute": "volume-mute",
    +    "vol-up": "volume-up",
    +    "win": "windows",
    +    "xbutton1": "x-button1",
    +    "xbutton2": "x-button2"
    +}
    diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/keys.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/keys.py
    new file mode 100644
    index 0000000000000000000000000000000000000000..24f5b9066c0633d2efeb6ee2086216ed600e902d
    --- /dev/null
    +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/keys.py
    @@ -0,0 +1,240 @@
    +"""
    +Keys.
    +
    +pymdownx.keys
    +Markdown extension for keystroke (user keyboard input) formatting.
    +
    +It wraps the syntax `++key+key+key++` (for individual keystrokes with modifiers)
    +or `++"string"++` (for continuous keyboard input) into HTML `` elements.
    +
    +If a key is found in the extension's database, its `` element gets a matching class.
    +Common synonyms are included, e.g. `++pg-up++` will match as `++page-up++`.
    +
    +## Config
    +
    +If `strict` is `True`, the entire series of keystrokes is wrapped into an outer`` element, and then,
    +each keystroke is wrapped into a separate inner `` element, which matches the HTML5 spec.
    +If `strict` is `False`, an outer `` is used, which matches the practice on Github or StackOverflow.
    +
    +The resulting `` elements are separated by `separator` (`+` by default, can be `''` or something else).
    +
    +If `camel_case` is `True`, `++PageUp++` will match the same as `++page-up++`.
    +
    +The database can be extended or modified with the `key_map` dict.
    +
    +## Examples
    +
    +### Input
    +
    +```
    +Press ++Shift+Alt+PgUp++, type in ++"Hello"++ and press ++Enter++.
    +```
    +
    +### Config 1
    +
    +```
    +  pymdownx.keys:
    +    camel_case: true
    +    strict: false
    +    separator: '+'
    +```
    +
    +### Output 1
    +
    +```
    +

    Press Shift+Alt+Page Up, type in Hello and press Enter.

    +``` + +### Config 2 + +``` + pymdownx.keys: + camel_case: true + strict: true + separator: '' +``` + +### Output 2 + +``` +

    Press ShiftAltPage Up, type in Hello and press Enter.

    +``` + +Idea by Adam Twardoch and coded by Isaac Muse. + +Copyright (c) 2017 Isaac Muse + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, +and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +""" +import html +from markdown import Extension +from markdown.inlinepatterns import InlineProcessor +from markdown import util as md_util +import xml.etree.ElementTree as etree +from . import util +from . import keymap_db as keymap +import re + +RE_EARLY_KBD = r'''(?x) +(?: + # Escape + (?(?:\\{2})+)(?=\+)| + # Key + (? pg-dn - Default: False'], + 'key_map': [{}, 'Additional keys to include or keys to override - Default: {}'] + } + super().__init__(*args, **kwargs) + + def extendMarkdown(self, md): + """Add support for keys.""" + + util.escape_chars(md, ['+']) + md.inlinePatterns.register(KeysPattern(RE_EARLY_KBD, self.getConfigs(), md, early=True), "keys-custom", 185) + md.inlinePatterns.register(KeysPattern(RE_KBD, self.getConfigs(), md), "keys", 70) + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return KeysExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/magiclink.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/magiclink.py new file mode 100644 index 0000000000000000000000000000000000000000..62c1dc94bd932242f78c89d10c55c4b849cf3fb1 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/magiclink.py @@ -0,0 +1,1332 @@ +""" +Magic Link. + +pymdownx.magiclink +An extension for Python Markdown. +Find HTML, FTP links, and email address and turn them to actual links + +MIT license. + +Copyright (c) 2014 - 2017 Isaac Muse + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, +and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +""" +from markdown import Extension +from markdown.treeprocessors import Treeprocessor +from markdown import util as md_util +from .util import warn_deprecated +import xml.etree.ElementTree as etree +from . import util +import re +from markdown.inlinepatterns import LinkInlineProcessor, InlineProcessor + +MAGIC_LINK = 1 +MAGIC_AUTO_LINK = 2 + +DEFAULT_EXCLUDES = { + "bitbucket": ['dashboard', 'account', 'plans', 'support', 'repo'], + "github": ['marketplace', 'notifications', 'issues', 'pull', 'sponsors', 'settings', 'support'], + "gitlab": ['dashboard', '-', 'explore', 'help', 'projects'], + "twitter": ['i', 'messages', 'bookmarks', 'home'], + "x": ['i', 'messages', 'bookmarks', 'home'] +} + +# Bare link/email detection +RE_MAIL = r'''(?xi) +(?P + (? + (?:(?<=\b)|(?<=_))(?: + (?:ht|f)tps?://[^_\W][-\w]*(?:\.[-\w.]+)*| # (http|ftp):// + (?Pw{3}\.)[^_\W][-\w]*(?:\.[-\w.]+)* # www. + ) + /?[-\w.?,!'(){}\[\]/+&@%$#=:"|~;]* # url path, fragments, and query stuff + (?:[^_\W]|[-/#@$+=]) # allowed end chars +) +''' + +RE_AUTOLINK = r'(?i)<((?:ht|f)tps?://[^<>]*)>' + +RE_CUSTOM_NAME = re.compile(r'^[a-zA-Z0-9]+$') + +# Provider specific user regex rules +RE_TWITTER_USER = r'\w{1,15}' +RE_X_USER = r'\w{1,15}' +RE_GITHUB_USER = r'[a-zA-Z\d](?:[-a-zA-Z\d_]{0,37}[a-zA-Z\d])?' +RE_GITLAB_USER = r'[\.a-zA-Z\d_](?:[-a-zA-Z\d_\.]{0,37}[-a-zA-Z\d_])?' +RE_BITBUCKET_USER = r'[-a-zA-Z\d_]{1,39}' + +# External mention patterns +RE_ALL_EXT_MENTIONS = r'''(?x) +(?P + (?(? + (?[-._a-zA-Z\d]{{0,99}}[a-zA-Z\d])\b +''' + +# Internal repo mention patterns +RE_GIT_INT_REPO_MENTIONS = r'''(?x) +(?P(?[-._a-zA-Z\d]{{0,99}}[a-zA-Z\d])\b +''' + +# External reference patterns (issue, pull request, commit, compare) +RE_GIT_EXT_REFS = r'''(?x) +(?P(?\b{})/) +(?P[-._a-zA-Z\d]{{0,99}}[a-zA-Z\d]) +(?:(?P(?:\#|!|\?)[1-9][0-9]*)|(?P@[a-f\d]{{40}})(?:\.{{3}}(?P[a-f\d]{{40}}))?))\b +''' + +# Internal reference patterns (issue, pull request, commit, compare) +RE_GIT_INT_EXT_REFS = r'''(?x) +(?P(?\b{})/)? +(?P[-._a-zA-Z\d]{{0,99}}[a-zA-Z\d]) +(?:(?P(?:\#|!|\?)[1-9][0-9]*)|(?P@[a-f\d]{{40}})(?:\.{{3}}(?P[a-f\d]{{40}}))?))\b +''' + +# Internal reference patterns for default user and repository (issue, pull request, commit, compare) +RE_GIT_INT_MICRO_REFS = r'''(?x) +(?P + (?:(?(?:\#|!|\?)[1-9][0-9]*)|(?P(?[a-f\d]{40}))?) +)\b +''' + +RE_WWW = re.compile(r'(https?://)(?:www\\\.)?(.*)') + +REPO_LINK_TEMPLATES = { + 'github': ( + r''' + (?P(?P{}/ + (?P(?P{})/[^/]+))/ + (?:issues/(?P\d+)/?| + pull/(?P\d+)/?| + discussions/(?P\d+)/?| + commit/(?P[\da-f]{{7,40}})/?| + compare/(?P[\da-f]{{7,40}})\.{{3}} + (?P[\da-f]{{7,40}})))''', + RE_GITHUB_USER + ), + 'bitbucket': ( + r''' + (?P(?P{}/ + (?P(?P{})/[^/]+))/ + (?:issues/(?P\d+)(?:/[^/]+)?/?| + pull-requests/(?P\d+)(?:/[^/]+(?:/diff)?)?/?| + commits/commit/(?P[\da-f]{{7,40}})/?| + branches/commits/(?P[\da-f]{{7,40}}) + (?:\.{{2}}|%0d)(?P[\da-f]{{7,40}})\#diff))''', + RE_BITBUCKET_USER + ), + 'gitlab': ( + r''' + (?P(?P{}/ + (?P(?P{})/[^/]+))/(?:-/)? + (?:issues/(?P\d+)/?| + merge_requests/(?P\d+)/?| + commit/(?P[\da-f]{{8,40}})/?| + compare/(?P[\da-f]{{8,40}})\.{{3}} + (?P[\da-f]{{8,40}})))''', + RE_GITLAB_USER + ) +} + + +def create_repo_link_pattern(provider, host, www=True): + """Create repository link provider.""" + + template = REPO_LINK_TEMPLATES[provider] + host_pat = re.escape(host.lower().rstrip('/')) + if www: + m = RE_WWW.match(host_pat) + if m: + host_pat = m.group(1) + r'(?:w{3}\.)?' + m.group(2) + return template[0].format(host_pat, template[1]) + + +# Repository link shortening pattern +RE_REPO_LINK = re.compile( + r'''(?xi)^(?:{}|{}|{})/?$'''.format( + create_repo_link_pattern('github', "https://github.com"), + create_repo_link_pattern('bitbucket', "https://bitbucket.org"), + create_repo_link_pattern('gitlab', 'https://gitlab.com'), + ) +) + + +USER_LINK_TEMPLATES = { + 'github': ( + r''' + (?P(?P{}/ + (?P(?P{})(?:/(?P[^/]+))?))) + ''', + RE_GITHUB_USER + ), + 'bitbucket': ( + r''' + (?P(?P{}/ + (?P(?P{})(?:/(?P[^/]+)/?)?))) + ''', + RE_BITBUCKET_USER + ), + 'gitlab': ( + r''' + (?P(?P{}/ + (?P(?P{})(?:/(?P[^/]+))?))) + ''', + RE_GITLAB_USER + ) +} + + +def create_user_link_pattern(provider, host, www=True): + """Create repository link provider.""" + + template = USER_LINK_TEMPLATES[provider] + host_pat = re.escape(host.lower().rstrip('/')) + if www: + m = RE_WWW.match(host_pat) + if m: + host_pat = m.group(1) + r'(?:w{3}\.)?' + m.group(2) + return template[0].format(host_pat, template[1]) + + +# Repository link shortening pattern +RE_USER_REPO_LINK = re.compile( + r'''(?xi)^(?:{}|{}|{})/?$'''.format( + create_user_link_pattern('github', 'https://github.com'), + create_user_link_pattern('bitbucket', 'https://bitbucket.org'), + create_user_link_pattern('gitlab', 'https://gitlab.com') + ) +) + +RE_SOCIAL_LINK = re.compile( + r'''(?xi) + ^(?: + (?P(?Phttps://(?:w{{3}}\.)?twitter\.com/(?P{}))) | + (?P(?Phttps://(?:w{{3}}\.)?x\.com/(?P{}))) + )/?$ + '''.format(RE_TWITTER_USER, RE_X_USER) +) + +# Provider specific info (links, names, specific patterns, etc.) +SOCIAL_PROVIDERS = {'x', 'twitter'} + +# Templates for providers +PROVIDER_TEMPLATES = { + "gitlab": { + "provider": "GitLab", + "type": "gitlab", + "url": "{}", + "user_pattern": RE_GITLAB_USER, + "issue": "{}/{{}}/{{}}/-/issues/{{}}", + "pull": "{}/{{}}/{{}}/-/merge_requests/{{}}", + "commit": "{}/{{}}/{{}}/-/commit/{{}}", + "compare": "{}/{{}}/{{}}/-/compare/{{}}...{{}}", + "hash_size": 8 + }, + "bitbucket": { + "provider": "Bitbucket", + "type": "bitbucket", + "url": "{}", + "user_pattern": RE_BITBUCKET_USER, + "issue": "{}/{{}}/{{}}/issues/{{}}", + "pull": "{}/{{}}/{{}}/pull-requests/{{}}", + "commit": "{}/{{}}/{{}}/commits/commit/{{}}", + "compare": "{}/{{}}/{{}}/branches/commits/{{}}..{{}}#diff", + "hash_size": 7 + }, + "github": { + "provider": "GitHub", + "type": "github", + "url": "{}", + "user_pattern": RE_GITHUB_USER, + "issue": "{}/{{}}/{{}}/issues/{{}}", + "pull": "{}/{{}}/{{}}/pull/{{}}", + "discuss": '{}/{{}}/{{}}/discussions/{{}}', + "commit": "{}/{{}}/{{}}/commit/{{}}", + "compare": "{}/{{}}/{{}}/compare/{{}}...{{}}", + "hash_size": 7 + }, + "twitter": { + "provider": "Twitter", + "type": "twitter", + "url": "{}", + "user_pattern": RE_TWITTER_USER + }, + "x": { + "provider": "X", + "type": "x", + "url": "{}", + "user_pattern": RE_X_USER + } +} + + +def create_provider(provider, host): + """Create the provider with the provided host.""" + + entry = PROVIDER_TEMPLATES[provider].copy() + for key in ('url', 'issue', 'pull', 'commit', 'compare', 'discuss'): + if key not in entry: + continue + entry[key] = entry[key].format(host.lower().rstrip('/')) + return entry + + +PROVIDER_INFO = { + "twitter": create_provider('twitter', "https://twitter.com"), + "x": create_provider('x', "https://x.com"), + "gitlab": create_provider('gitlab', 'https://gitlab.com'), + "bitbucket": create_provider('bitbucket', "https://bitbucket.org"), + "github": create_provider('github', "https://github.com") +} + + +class _MagiclinkShorthandPattern(InlineProcessor): + """Base shorthand link class.""" + + def __init__(self, pattern, md, user, repo, provider, labels, normalize, provider_info): + """Initialize.""" + + self.user = user + self.repo = repo + self.labels = labels + self.normalize = normalize + self.provider_info = provider_info + self.provider = provider if provider in self.provider_info else '' + InlineProcessor.__init__(self, pattern, md) + + +class _MagiclinkReferencePattern(_MagiclinkShorthandPattern): + """Convert #1, repo#1, user/repo#1, !1, repo!1, user/repo!1, hash, repo@hash, or user/repo@hash to links.""" + + def process_issues(self, el, provider, user, repo, issue): + """Process issues.""" + + issue_type = issue[:1] + issue_value = issue[1:] + + if issue_type == '#': + issue_link = self.provider_info[provider]['issue'] + issue_label = self.labels.get('issue', 'Issue') + class_name = 'magiclink-issue' + icon = issue_type + elif issue_type == '!': + issue_link = self.provider_info[provider]['pull'] + issue_label = self.labels.get('pull', 'Pull Request') + class_name = 'magiclink-pull' + icon = '#' if self.normalize else issue_type + elif self.provider_info[provider]['type'] == "github" and issue_type == '?': + issue_link = self.provider_info[provider]['discuss'] + issue_label = self.labels.get('discuss', 'Discussion') + class_name = 'magiclink-discussion' + icon = '#' if self.normalize else issue_type + else: + return False + + if self.my_repo: + el.text = md_util.AtomicString(f'{icon}{issue_value}') + elif self.my_user: + el.text = md_util.AtomicString(f'{repo}{icon}{issue_value}') + else: + el.text = md_util.AtomicString(f'{user}/{repo}{icon}{issue_value}') + + el.set('href', issue_link.format(user, repo, issue_value)) + el.set('class', f'magiclink magiclink-{provider} {class_name}') + el.set( + 'title', + '{} {}: {}/{} #{}'.format( + self.provider_info[provider]['provider'], + issue_label, + user, + repo, + issue_value + ) + ) + return True + + def process_commit(self, el, provider, user, repo, commit): + """Process commit.""" + + hash_ref = commit[0:self.provider_info[provider]['hash_size']] + if self.my_repo: + text = hash_ref + elif self.my_user: + text = f'{repo}@{hash_ref}' + else: + text = f'{user}/{repo}@{hash_ref}' + + el.set('href', self.provider_info[provider]['commit'].format(user, repo, commit)) + el.text = md_util.AtomicString(text) + el.set('class', f'magiclink magiclink-{provider} magiclink-commit') + el.set( + 'title', + '{} {}: {}/{}@{}'.format( + self.provider_info[provider]['provider'], + self.labels.get('commit', 'Commit'), + user, + repo, + hash_ref + ) + ) + + def process_compare(self, el, provider, user, repo, commit1, commit2): + """Process commit.""" + + hash_ref1 = commit1[0:self.provider_info[provider]['hash_size']] + hash_ref2 = commit2[0:self.provider_info[provider]['hash_size']] + if self.my_repo: + text = f'{hash_ref1}...{hash_ref2}' + elif self.my_user: + text = f'{repo}@{hash_ref1}...{hash_ref2}' + else: + text = f'{user}/{repo}@{hash_ref1}...{hash_ref2}' + + el.set('href', self.provider_info[provider]['compare'].format(user, repo, commit1, commit2)) + el.text = md_util.AtomicString(text) + el.set('class', f'magiclink magiclink-{provider} magiclink-compare') + el.set( + 'title', + '{} {}: {}/{}@{}...{}'.format( + self.provider_info[provider]['provider'], + self.labels.get('compare', 'Compare'), + user, + repo, + hash_ref1, + hash_ref2 + ) + ) + + +class MagicShortenerTreeprocessor(Treeprocessor): + """Tree processor that finds repo issue and commit links and shortens them.""" + + # Repo link types + ISSUE = 0 + PULL = 1 + COMMIT = 2 + DISCUSS = 3 + DIFF = 4 + REPO = 5 + USER = 6 + + def __init__( + self, + md, + base_url, + base_user_url, + labels, + normalize, + repo_shortner, + social_shortener, + custom_shortners, + excludes, + provider, + provider_info + ): + """Initialize.""" + + self.base = base_url + self.repo_shortner = repo_shortner + self.social_shortener = social_shortener + self.custom_shortners = custom_shortners + self.base_user = base_user_url + self.repo_labels = labels + self.normalize = normalize + self.provider = provider + self.provider_info = provider_info + self.labels = { + "github": "GitHub", + "bitbucket": "Bitbucket", + "gitlab": "GitLab" + } + self.excludes = excludes + Treeprocessor.__init__(self, md) + + def shorten_repo(self, link, class_name, label, user_repo): + """Shorten repo link.""" + + text = user_repo + link.text = md_util.AtomicString(text) + + if 'magiclink-repository' not in class_name: + class_name.append('magiclink-repository') + + link.set( + 'title', + "{} {}: {}".format( + label, self.repo_labels.get('repository', 'Repository'), user_repo + ) + ) + + def shorten_user(self, link, class_name, label, user_repo): + """Shorten user link.""" + + link.text = md_util.AtomicString(f'@{user_repo}') + + if 'magiclink-mention' not in class_name: + class_name.append('magiclink-mention') + + link.set( + 'title', + "{} {}: {}".format( + label, self.repo_labels.get('metion', 'User'), user_repo + ) + ) + + def shorten_diff(self, link, class_name, label, user_repo, value, hash_size): + """Shorten diff/compare links.""" + + repo_label = self.repo_labels.get('compare', 'Compare') + if self.my_repo: + text = f'{value[0][0:hash_size]}...{value[1][0:hash_size]}' + elif self.my_user: + text = '{}@{}...{}'.format(user_repo.split('/')[1], value[0][0:hash_size], value[1][0:hash_size]) + else: + text = f'{user_repo}@{value[0][0:hash_size]}...{value[1][0:hash_size]}' + link.text = md_util.AtomicString(text) + + if 'magiclink-compare' not in class_name: + class_name.append('magiclink-compare') + + link.set( + 'title', + '{} {}: {}@{}...{}'.format( + label, repo_label, user_repo.rstrip('/'), value[0][0:hash_size], value[1][0:hash_size] + ) + ) + + def shorten_commit(self, link, class_name, label, user_repo, value, hash_size): + """Shorten commit link.""" + + # user/repo@hash + repo_label = self.repo_labels.get('commit', 'Commit') + if self.my_repo: + text = value[0:hash_size] + elif self.my_user: + text = '{}@{}'.format(user_repo.split('/')[1], value[0:hash_size]) + else: + text = f'{user_repo}@{value[0:hash_size]}' + link.text = md_util.AtomicString(text) + + if 'magiclink-commit' not in class_name: + class_name.append('magiclink-commit') + + link.set( + 'title', + '{} {}: {}@{}'.format(label, repo_label, user_repo.rstrip('/'), value[0:hash_size]) + ) + + def shorten_issue(self, provider, link, class_name, label, user_repo, value, link_type): + """Shorten issue/pull link.""" + + # user/repo#(issue|pull) + provider_type = self.provider_info[provider]['type'] + if link_type == self.ISSUE: + issue_type = self.repo_labels.get('issue', 'Issue') + icon = '#' + if 'magiclink-issue' not in class_name: + class_name.append('magiclink-issue') + elif link_type == self.PULL: + issue_type = self.repo_labels.get('pull', 'Pull Request') + icon = '#' if self.normalize else '!' + if 'magiclink-pull' not in class_name: + class_name.append('magiclink-pull') + elif provider_type == 'github' and link_type == self.DISCUSS: + issue_type = self.repo_labels.get('discuss', 'Discussion') + icon = '#' if self.normalize else '?' + if 'magiclink-discussion' not in class_name: + class_name.append('magiclink-discussion') + + if self.my_repo: + link.text = md_util.AtomicString(f"{icon}{value}") + elif self.my_user: + link.text = md_util.AtomicString("{}{}{}".format(user_repo.split('/')[1], icon, value)) + else: + link.text = md_util.AtomicString(f"{user_repo}{icon}{value}") + + link.set('title', '{} {}: {} #{}'.format(label, issue_type, user_repo.rstrip('/'), value)) + + def shorten_issue_commit(self, link, provider, link_type, user_repo, value, hash_size): + """Shorten URL.""" + + label = self.provider_info[provider]['provider'] + prov_class = f'magiclink-{provider}' + class_attr = link.get('class', '') + class_name = class_attr.split(' ') if class_attr else [] + + if 'magiclink' not in class_name: + class_name.append('magiclink') + + if prov_class not in class_name: + class_name.append(prov_class) + + # Link specific shortening logic + if link_type is self.DIFF: + self.shorten_diff(link, class_name, label, user_repo, value, hash_size) + elif link_type is self.COMMIT: + self.shorten_commit(link, class_name, label, user_repo, value, hash_size) + else: + self.shorten_issue(provider, link, class_name, label, user_repo, value, link_type) + link.set('class', ' '.join(class_name)) + + def shorten_user_repo(self, link, provider, link_type, user_repo): + """Shorten URL.""" + + label = self.provider_info[provider]['provider'] + prov_class = f'magiclink-{provider}' + class_attr = link.get('class', '') + class_name = class_attr.split(' ') if class_attr else [] + + if 'magiclink' not in class_name: + class_name.append('magiclink') + + if prov_class not in class_name: + class_name.append(prov_class) + + # Link specific shortening logic + if link_type is self.REPO: + self.shorten_repo(link, class_name, label, user_repo) + else: + self.shorten_user(link, class_name, label, user_repo) + link.set('class', ' '.join(class_name)) + + def get_provider_type(self, match): + """Get the provider and hash size.""" + + # Set provider specific variables + if match.group('github'): + provider = 'github' + elif match.group('bitbucket'): + provider = 'bitbucket' + elif match.group('gitlab'): + provider = 'gitlab' + return provider + + def get_social_provider(self, match): + """Get social provider.""" + + if match.group('twitter'): + provider = 'twitter' + + elif match.group('x'): + provider = 'x' + return provider + + def get_type(self, provider, match): + """Get the link type.""" + + try: + # Gather info about link type + if match.group(provider + '_diff1') is not None: + value = (match.group(provider + '_diff1'), match.group(provider + '_diff2')) + link_type = self.DIFF + elif match.group(provider + '_commit') is not None: + value = match.group(provider + '_commit') + link_type = self.COMMIT + elif match.group(provider + '_pull') is not None: + value = match.group(provider + '_pull') + link_type = self.PULL + elif provider == "github" and match.group(provider + '_discuss') is not None: + value = match.group(provider + '_discuss') + link_type = self.DISCUSS + else: + value = match.group(provider + '_issue') + link_type = self.ISSUE + except IndexError: + # Gather info about link type + found = False + try: + if match.group(provider + '_repo') is not None: + value = None + link_type = self.REPO + found = True + except IndexError: + pass + if not found: + value = None + link_type = self.USER + return value, link_type + + def is_my_repo(self, provider_type, match): + """Check if link is from our specified user and repo.""" + + # See if these links are from the specified repo. + return self.base and match.group(provider_type + '_base') + '/' == self.base + + def is_my_user(self, provider_type, match): + """Check if link is from our specified user.""" + + return self.base_user and match.group(provider_type + '_base').startswith(self.base_user) + + def excluded(self, provider_type, provider, match): + """Check if user has been excluded.""" + + user = match.group(provider_type + '_user') + return user.lower() in self.excludes.get(provider, set()) + + def run(self, root): + """Shorten popular git repository links.""" + + self.hide_protocol = self.config['hide_protocol'] + + links = root.iter('a') + for link in links: + has_child = len(list(link)) + is_magic = link.attrib.get('magiclink') + href = link.attrib.get('href', '') + text = link.text + found = False + + if is_magic: + del link.attrib['magiclink'] + + # We want a normal link. No sub-elements embedded in it, just a normal string. + if has_child or not text: # pragma: no cover + continue + + # Make sure the text matches the `href`. If needed, add back protocol to be sure. + # Not all links will pass through MagicLink, so we try both with and without protocol. + if (text == href or (is_magic and self.hide_protocol and ('https://' + text) == href)): + if self.repo_shortner: + m = RE_REPO_LINK.match(href) + if m: + provider_type = self.get_provider_type(m) + provider = provider_type + self.my_repo = self.is_my_repo(provider_type, m) + self.my_user = self.my_repo or self.is_my_user(provider_type, m) + value, link_type = self.get_type(provider_type, m) + found = True + + # All right, everything set, let's shorten. + if not self.excluded(provider_type, provider, m): + self.shorten_issue_commit( + link, + provider, + link_type, + m.group(provider_type + '_user_repo'), + value, + self.provider_info[provider]['hash_size'] + ) + if not found and self.repo_shortner: + m = RE_USER_REPO_LINK.match(href) + if m: + provider_type = self.get_provider_type(m) + provider = provider_type + self.my_repo = self.is_my_repo(provider_type, m) + self.my_user = self.my_repo or self.is_my_user(provider_type, m) + value, link_type = self.get_type(provider_type, m) + found = True + + if not self.excluded(provider_type, provider, m): + # All right, everything set, let's shorten. + self.shorten_user_repo( + link, + provider, + link_type, + m.group(provider_type + '_user_repo') + ) + if not found and self.custom_shortners: + for custom, entry in self.custom_shortners.items(): + m = entry['repo'].match(href) + if m: + provider = custom + provider_type = self.provider_info[custom]['type'] + self.my_repo = self.is_my_repo(provider_type, m) + self.my_user = self.my_repo or self.is_my_user(provider_type, m) + value, link_type = self.get_type(provider_type, m) + found = True + + # All right, everything set, let's shorten. + if not self.excluded(provider_type, provider, m): + self.shorten_issue_commit( + link, + provider, + link_type, + m.group(provider_type + '_user_repo'), + value, + self.provider_info[provider]['hash_size'] + ) + if not found: + m = entry['user'].match(href) + if m: + provider = custom + provider_type = self.provider_info[custom]['type'] + self.my_repo = self.is_my_repo(provider_type, m) + self.my_user = self.my_repo or self.is_my_user(provider_type, m) + value, link_type = self.get_type(provider_type, m) + found = True + + if not self.excluded(provider_type, provider, m): + # All right, everything set, let's shorten. + self.shorten_user_repo( + link, + provider, + link_type, + m.group(provider_type + '_user_repo') + ) + + if not found and self.social_shortener: + m = RE_SOCIAL_LINK.match(href) + if m: + provider = self.get_social_provider(m) + if provider == 'twitter': + warn_deprecated("The 'twitter' social provider has been deprecated, please use 'x' instead") + self.my_repo = self.is_my_repo(provider, m) + self.my_user = self.my_repo or self.is_my_user(provider, m) + value, link_type = self.get_type(provider, m) + + if not self.excluded(provider, provider, m): + # All right, everything set, let's shorten. + self.shorten_user_repo( + link, + provider, + link_type, + m.group(provider + '_user') + ) + return root + + +class MagiclinkPattern(LinkInlineProcessor): + """Convert html, ftp links to clickable links.""" + + ANCESTOR_EXCLUDES = ('a',) + + def handleMatch(self, m, data): + """Handle URL matches.""" + + el = etree.Element("a") + el.text = md_util.AtomicString(m.group('link')) + if m.group("www"): + href = "http://{}".format(m.group('link')) + else: + href = m.group('link') + if self.config['hide_protocol']: + el.text = md_util.AtomicString(el.text[el.text.find("://") + 3:]) + el.set("href", self.unescape(href.strip())) + + if self.config.get('repo_url_shortener', False): + el.set('magiclink', str(MAGIC_LINK)) + + return el, m.start(0), m.end(0) + + +class MagiclinkAutoPattern(InlineProcessor): + """Return a link Element given an auto link ``.""" + + def handleMatch(self, m, data): + """Return link optionally without protocol.""" + + el = etree.Element("a") + el.set('href', self.unescape(m.group(1))) + el.text = md_util.AtomicString(m.group(1)) + if self.config['hide_protocol']: + el.text = md_util.AtomicString(el.text[el.text.find("://") + 3:]) + + if self.config.get('repo_url_shortener', False): + el.set('magiclink', str(MAGIC_AUTO_LINK)) + + return el, m.start(0), m.end(0) + + +class MagiclinkMailPattern(InlineProcessor): + """Convert emails to clickable email links.""" + + ANCESTOR_EXCLUDES = ('a',) + + def email_encode(self, code): + """Return entity definition by code, or the code if not defined.""" + return f"{md_util.AMP_SUBSTITUTE}#{code:d};" + + def handleMatch(self, m, data): + """Handle email link patterns.""" + + el = etree.Element("a") + email = self.unescape(m.group('mail')) + href = f"mailto:{email}" + el.text = md_util.AtomicString(''.join([self.email_encode(ord(c)) for c in email])) + el.set("href", ''.join([md_util.AMP_SUBSTITUTE + f'#{ord(c):d};' for c in href])) + return el, m.start(0), m.end(0) + + +class MagiclinkMentionPattern(_MagiclinkShorthandPattern): + """Convert @mention to links.""" + + ANCESTOR_EXCLUDES = ('a',) + + def handleMatch(self, m, data): + """Handle email link patterns.""" + + text = m.group('mention')[1:] + parts = text.split(':') + if len(parts) > 1: + provider = parts[0] + mention = parts[1] + else: + provider = self.provider + mention = parts[0] + + if provider == 'twitter': + warn_deprecated("The 'twitter' social provider has been deprecated, please use 'x' instead") + + el = etree.Element("a") + el.set('href', '{}/{}'.format(self.provider_info[provider]['url'], mention)) + el.set( + 'title', + "{} {}: {}".format(self.provider_info[provider]['provider'], self.labels.get('mention', "User"), mention) + ) + el.set('class', f'magiclink magiclink-{provider} magiclink-mention') + el.text = md_util.AtomicString(f'@{mention}') + + return el, m.start(0), m.end(0) + + +class MagiclinkRepositoryPattern(_MagiclinkShorthandPattern): + """Convert @user/repo to links.""" + + ANCESTOR_EXCLUDES = ('a',) + + def handleMatch(self, m, data): + """Handle email link patterns.""" + + text = m.group('mention')[1:] + parts = text.split(':') + if len(parts) > 1: + provider = parts[0] + user = parts[1] + else: + provider = self.provider + user = parts[0] + repo = m.group('mention_repo') + + el = etree.Element("a") + el.set('href', '{}/{}/{}'.format(self.provider_info[provider]['url'], user, repo)) + el.set( + 'title', + "{} {}: {}/{}".format( + self.provider_info[provider]['provider'], self.labels.get('repository', 'Repository'), user, repo + ) + ) + el.set('class', f'magiclink magiclink-{provider} magiclink-repository') + el.text = md_util.AtomicString(f'{user}/{repo}') + return el, m.start(0), m.end(0) + + +class MagiclinkExternalRefsPattern(_MagiclinkReferencePattern): + """Convert repo#1, user/repo#1, repo!1, user/repo!1, repo@hash, or user/repo@hash to links.""" + + ANCESTOR_EXCLUDES = ('a',) + + def handleMatch(self, m, data): + """Handle email link patterns.""" + + is_commit = m.group('commit') + is_diff = m.group('diff') + value = m.group('commit')[1:] if is_commit else m.group('issue') + value2 = m.group('diff') if is_diff else None + repo = m.group('repo') + user = m.group('user') + + if not user: + user = self.user + + parts = user.split(':') + if len(parts) > 1: + provider = parts[0] + user = parts[1] + else: + provider = self.provider + + # If there is no valid user or provider, reject + if not user: + return None, None, None + + self.my_user = user == self.user and provider == self.provider + self.my_repo = self.my_user and repo == self.repo + + el = etree.Element("a") + if is_diff: + self.process_compare(el, provider, user, repo, value, value2) + elif is_commit: + self.process_commit(el, provider, user, repo, value) + else: + if not self.process_issues(el, provider, user, repo, value): + return m.group(0), m.start(0), m.end(0) + return el, m.start(0), m.end(0) + + +class MagiclinkInternalRefsPattern(_MagiclinkReferencePattern): + """Convert #1, !1, and commit_hash.""" + + ANCESTOR_EXCLUDES = ('a',) + + def handleMatch(self, m, data): + """Handle email link patterns.""" + + # We don't have a valid provider, user, and repo, reject + if not self.user or not self.repo: + return None, None, None + + is_commit = m.group('commit') + is_diff = m.group('diff') + value = m.group('commit') if is_commit else m.group('issue') + value2 = m.group('diff') if is_diff else None + + repo = self.repo + user = self.user + provider = self.provider + self.my_repo = True + self.my_user = True + + el = etree.Element("a") + if is_diff: + self.process_compare(el, provider, user, repo, value, value2) + elif is_commit: + self.process_commit(el, provider, user, repo, value) + else: + if not self.process_issues(el, provider, user, repo, value): + return m.group(0), m.start(0), m.end(0) + return el, m.start(0), m.end(0) + + +class MagiclinkExtension(Extension): + """Add auto link and link transformation extensions to Markdown class.""" + + def __init__(self, *args, **kwargs): + """Initialize.""" + + self.config = { + 'hide_protocol': [ + False, + "If 'True', links are displayed without the initial ftp://, http:// or https://" + "- Default: False" + ], + 'repo_url_shortener': [ + False, + "If 'True' repo commit and issue links are shortened - Default: False" + ], + 'social_url_shortener': [ + False, + "If 'True' social links are shortened - Default: False" + ], + 'shortener_user_exclude': [ + { + "bitbucket": ['dashboard', 'account', 'plans', 'support', 'repo'], + "github": ['marketplace', 'notifications', 'issues', 'pull', 'sponsors', 'settings', 'support'], + "gitlab": ['dashboard', '-', 'explore', 'help', 'projects'], + "twitter": ['i', 'messages', 'bookmarks', 'home'], + "x": ['i', 'messages', 'bookmarks', 'home'] + }, + "A list of user names to exclude from URL shortening." + ], + 'repo_url_shorthand': [ + False, + "If 'True' repo shorthand syntax is converted to links - Default: False" + ], + 'social_url_shorthand': [ + False, + "If 'True' social shorthand syntax is converted to links - Default: False" + ], + 'provider': [ + 'github', + 'The base provider to use (github, gitlab, bitbucket, x) - Default: "github"' + ], + 'labels': [ + {}, + "Title labels - Default: {}" + ], + 'normalize_issue_symbols': [ + False, + 'Normalize issue, pull, and discussions symbols all to use # - Default: False' + ], + 'user': [ + '', + 'The base user name to use - Default: ""' + ], + 'repo': [ + '', + 'The base repo to use - Default: ""' + ], + 'custom': [ + {}, + "Custom repositories hosts - Default {}" + ] + } + super().__init__(*args, **kwargs) + + def setup_autolinks(self, md, config): + """Setup auto links.""" + + # Setup general link patterns + auto_link_pattern = MagiclinkAutoPattern(RE_AUTOLINK, md) + auto_link_pattern.config = config + md.inlinePatterns.register(auto_link_pattern, "autolink", 120) + + link_pattern = MagiclinkPattern(RE_LINK, md) + link_pattern.config = config + md.inlinePatterns.register(link_pattern, "magic-link", 85) + + md.inlinePatterns.register(MagiclinkMailPattern(RE_MAIL, md), "magic-mail", 84.9) + + def setup_shorthand(self, md): + """Setup shorthand.""" + + # Setup URL shortener + escape_chars = ['@'] + util.escape_chars(md, escape_chars) + + # Repository shorthand + if self.git_short: + git_ext_repo = MagiclinkRepositoryPattern( + self.re_git_ext_repo_mentions, + md, + self.user, + self.repo, + self.provider, + self.labels, + self.normalize, + self.provider_info + ) + md.inlinePatterns.register(git_ext_repo, "magic-repo-ext-mention", 79.9) + if not self.is_social: + git_int_repo = MagiclinkRepositoryPattern( + RE_GIT_INT_REPO_MENTIONS.format(self.int_mentions), + md, + self.user, + self.repo, + self.provider, + self.labels, + self.normalize, + self.provider_info + ) + md.inlinePatterns.register(git_int_repo, "magic-repo-int-mention", 79.8) + + # Mentions + pattern = RE_ALL_EXT_MENTIONS.format('|'.join(self.ext_mentions)) + git_mention = MagiclinkMentionPattern( + pattern, + md, + self.user, + self.repo, + self.provider, + self.labels, + self.normalize, + self.provider_info + ) + md.inlinePatterns.register(git_mention, "magic-ext-mention", 79.7) + + git_mention = MagiclinkMentionPattern( + RE_INT_MENTIONS.format(self.int_mentions), + md, + self.user, + self.repo, + self.provider, + self.labels, + self.normalize, + self.provider_info + ) + md.inlinePatterns.register(git_mention, "magic-int-mention", 79.6) + + # Other project refs + if self.git_short: + git_ext_refs = MagiclinkExternalRefsPattern( + self.re_git_ext_refs, + md, + self.user, + self.repo, + self.provider, + self.labels, + self.normalize, + self.provider_info + ) + md.inlinePatterns.register(git_ext_refs, "magic-ext-refs", 79.5) + if not self.is_social: + git_int_refs = MagiclinkExternalRefsPattern( + RE_GIT_INT_EXT_REFS.format(self.int_mentions), + md, + self.user, + self.repo, + self.provider, + self.labels, + self.normalize, + self.provider_info + ) + md.inlinePatterns.register(git_int_refs, "magic-int-refs", 79.4) + git_int_micro_refs = MagiclinkInternalRefsPattern( + RE_GIT_INT_MICRO_REFS, + md, + self.user, + self.repo, + self.provider, + self.labels, + self.normalize, + self.provider_info + ) + md.inlinePatterns.register(git_int_micro_refs, "magic-int-micro-refs", 79.3) + + def setup_shortener( + self, + md, + config + ): + """Setup shortener.""" + + shortener = MagicShortenerTreeprocessor( + md, + self.base_url, + self.base_user_url, + self.labels, + self.normalize, + self.repo_shortner, + self.social_shortener, + self.custom_shortners, + self.shortener_exclusions, + self.provider, + self.provider_info + ) + shortener.config = config + md.treeprocessors.register(shortener, "magic-repo-shortener", 9.9) + + def get_base_urls(self, config): + """Get base URLs.""" + + base_url = '' + base_user_url = '' + + if self.is_social: + return base_url, base_user_url + + if self.user and self.repo: + base_url = '{}/{}/{}/'.format(self.provider_info[self.provider]['url'], self.user, self.repo) + base_user_url = '{}/{}/'.format(self.provider_info[self.provider]['url'], self.user) + + return base_url, base_user_url + + def extendMarkdown(self, md): + """Add support for turning html links and emails to link tags.""" + + config = self.getConfigs() + + # Setup repo variables + self.user = config.get('user', '') + self.repo = config.get('repo', '') + self.provider = config.get('provider', 'github') + self.labels = config.get('labels', {}) + self.normalize = config.get('normalize_issue_symbols', False) + self.is_social = self.provider in SOCIAL_PROVIDERS + self.git_short = config.get('repo_url_shorthand', False) + self.social_short = config.get('social_url_shorthand', False) + self.repo_shortner = config.get('repo_url_shortener', False) + self.social_shortener = config.get('social_url_shortener', False) + self.shortener_exclusions = {k: set(v) for k, v in DEFAULT_EXCLUDES.items()} + + self.provider_info = PROVIDER_INFO.copy() + custom_provider = config.get('custom', {}) + excludes = config.get('shortener_user_exclude', {}) + self.custom_shortners = {} + external_users = [RE_GITHUB_EXT_MENTIONS, RE_GITLAB_EXT_MENTIONS, RE_BITBUCKET_EXT_MENTIONS] + for custom, entry in custom_provider.items(): + if not RE_CUSTOM_NAME.match(custom): + raise ValueError( + f"Name '{custom}' not allowed, provider name must contain only letters and numbers" + ) + if custom not in self.provider_info: + self.provider_info[custom] = create_provider(entry['type'], entry['host']) + self.provider_info[custom]['provider'] = entry['label'] + self.custom_shortners[custom] = { + 'repo': re.compile( + r'(?xi)^{}/?$'.format( + create_repo_link_pattern(entry['type'], entry['host'], entry.get('www', True)) + ) + ), + 'user': re.compile( + r'(?xi)^{}/?$'.format( + create_user_link_pattern(entry['type'], entry['host'], entry.get('www', True)) + ) + ) + } + if custom not in excludes: + excludes[custom] = excludes.get(entry['type'], []) + external_users.append(create_ext_mentions(custom, entry['type'])) + + self.re_git_ext_repo_mentions = RE_GIT_EXT_REPO_MENTIONS.format('|'.join(external_users)) + self.re_git_ext_refs = RE_GIT_EXT_REFS.format('|'.join(external_users)) + + for key, value in config.get('shortener_user_exclude', {}).items(): + if key in self.provider_info and isinstance(value, (list, tuple, set)): + self.shortener_exclusions[key] = {x.lower() for x in value} + + # Ensure valid provider + if self.provider not in self.provider_info: + self.provider = 'github' + + self.setup_autolinks(md, config) + + if self.git_short or self.social_short: + self.ext_mentions = [] + if self.git_short: + self.ext_mentions.extend(external_users) + + if self.social_short: + self.ext_mentions.append(RE_X_EXT_MENTIONS) + self.ext_mentions.append(RE_TWITTER_EXT_MENTIONS) + self.int_mentions = self.provider_info[self.provider]['user_pattern'] + self.setup_shorthand(md) + + # Setup link post processor for shortening repository links + if self.repo_shortner or self.social_shortener: + self.base_url, self.base_user_url = self.get_base_urls(config) + self.setup_shortener(md, config) + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return MagiclinkExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/mark.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/mark.py new file mode 100644 index 0000000000000000000000000000000000000000..99ca2deefe058eb090a431b3ae9994681c3fd2ad --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/mark.py @@ -0,0 +1,91 @@ +""" +Mark. + +pymdownx.mark +Really simple plugin to add support for +test tags as ==test== + +MIT license. + +Copyright (c) 2014 - 2017 Isaac Muse + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, +and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +""" +import re +from markdown import Extension +from markdown.inlinepatterns import SimpleTextInlineProcessor +from . import util + +SMART_CONTENT = r'((?:(?<=\s)=+?(?=\s)|.)+?=*?)' +CONTENT = r'((?:[^=]|(?test` tags as `==test==`.""" + + config = self.getConfigs() + smart = bool(config.get('smart_mark', True)) + + md.registerExtension(self) + + escape_chars = [] + escape_chars.append('=') + util.escape_chars(md, escape_chars) + + md.inlinePatterns.register(SimpleTextInlineProcessor(NOT_MARK), 'not_tilde', 70) + mark = MarkSmartProcessor(r'=') if smart else MarkProcessor(r'=') + md.inlinePatterns.register(mark, "mark", 65) + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return MarkExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/pathconverter.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/pathconverter.py new file mode 100644 index 0000000000000000000000000000000000000000..b2359ebc927d34c73cf06386b46575b3954184ee --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/pathconverter.py @@ -0,0 +1,190 @@ +""" +Path Converter. + +pymdownx.pathconverter +An extension for Python Markdown. + +An extension to covert tag paths to relative or absolute: + +Given an absolute base and a target relative path, this extension searches for file +references that are relative and converts them to a path relative +to the base path. + +-or- + +Given an absolute base path, this extension searches for file +references that are relative and converts them to absolute paths. + +MIT license. + +Copyright (c) 2014 - 2017 Isaac Muse + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, +and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +""" +from markdown import Extension +from markdown.postprocessors import Postprocessor +from . import util +import os +import re +from urllib.parse import urlunparse + +RE_TAG_HTML = r'''(?xus) + (?: + (?P + <\s*(?Pscript|style)[^>]*>.*? | + (?:(\r?\n?\s*)(\s*)(?=\r?\n)|) + )| + (?P<\s*(?P(?:%s))) + (?P(?:\s+[\w\-:]+(?:\s*=\s*(?:"[^"]*"|'[^']*'))?)*) + (?P\s*(?:\/?)>) + ) + ''' + +RE_TAG_LINK_ATTR = re.compile( + r'''(?xus) + (?P + (?: + (?P\s+(?:href|src)\s*=\s*) + (?P"[^"]*"|'[^']*') + ) + ) + ''' +) + + +def repl_relative(m, base_path, relative_path): + """Replace path with relative path.""" + + link = m.group(0) + try: + scheme, netloc, path, params, query, fragment, is_url, is_absolute = util.parse_url(m.group('path')[1:-1]) + + if not is_url: + # Get the absolute path of the file or return + # if we can't resolve the path + path = util.url2path(path) + if (not is_absolute): + # Convert current relative path to absolute + path = os.path.relpath( + os.path.normpath(os.path.join(base_path, path)), + os.path.normpath(relative_path) + ) + # Convert the path, URL encode it, and format it as a link + path = util.path2url(path) + link = '{}"{}"'.format( + m.group('name'), + urlunparse((scheme, netloc, path, params, query, fragment)) + ) + except Exception: # pragma: no cover + # Parsing crashed and burned; no need to continue. + pass + + return link + + +def repl_absolute(m, base_path, file_scheme): + """Replace path with absolute path.""" + + link = m.group(0) + try: + scheme, netloc, path, params, query, fragment, is_url, is_absolute = util.parse_url(m.group('path')[1:-1]) + + if (not is_absolute and not is_url): + path = util.url2path(path) + path = os.path.normpath(os.path.join(base_path, path)) + path = util.path2url(path) + if file_scheme: + if not path.startswith('/'): + path = '/' + path + link = '{}"{}"'.format( + m.group('name'), + urlunparse(("file", netloc, path, params, query, fragment)) + ) + else: + start = '/' if not path.startswith('/') else '' + link = '{}"{}{}"'.format( + m.group('name'), + start, + urlunparse((scheme, netloc, path, params, query, fragment)) + ) + except Exception: # pragma: no cover + # Parsing crashed and burned; no need to continue. + pass + + return link + + +def repl(m, base_path, rel_path=None, file_scheme=None): + """Replace.""" + + if m.group('avoid'): + tag = m.group('avoid') + else: + tag = m.group('open') + if rel_path is None: + tag += RE_TAG_LINK_ATTR.sub(lambda m2: repl_absolute(m2, base_path, file_scheme), m.group('attr')) + else: + tag += RE_TAG_LINK_ATTR.sub(lambda m2: repl_relative(m2, base_path, rel_path), m.group('attr')) + tag += m.group('close') + return tag + + +class PathConverterPostprocessor(Postprocessor): + """Post process to find tag lings to convert.""" + + def run(self, text): + """Find and convert paths.""" + + basepath = self.config['base_path'] + relativepath = self.config['relative_path'] + absolute = bool(self.config['absolute']) + filescheme = bool(self.config['file_scheme']) + tags = re.compile(RE_TAG_HTML % '|'.join(self.config['tags'].split())) + if not absolute and basepath and relativepath: + text = tags.sub(lambda m: repl(m, basepath, rel_path=relativepath), text) + elif absolute and basepath: + text = tags.sub(lambda m: repl(m, basepath, file_scheme=filescheme), text) + return text + + +class PathConverterExtension(Extension): + """PathConverter extension.""" + + def __init__(self, *args, **kwargs): + """Initialize.""" + + self.config = { + 'base_path': ["", "Base path used to find files - Default: \"\""], + 'relative_path': ["", "Path that files will be relative to (not needed if using absolute) - Default: \"\""], + 'absolute': [False, "Paths are absolute by default; disable for relative - Default: False"], + 'tags': ["img script a link", "tags to convert src and/or href in - Default: 'img scripts a link'"], + 'file_scheme': [False, "Use file:// scheme for absolute paths - Default: False"], + } + + super().__init__(*args, **kwargs) + + def extendMarkdown(self, md): + """Add post processor to Markdown instance.""" + + rel_path = PathConverterPostprocessor(md) + rel_path.config = self.getConfigs() + md.postprocessors.register(rel_path, "path-converter", 2) + md.registerExtension(self) + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return PathConverterExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/progressbar.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/progressbar.py new file mode 100644 index 0000000000000000000000000000000000000000..01f959596f550acb76e23f5fff142c2d9fcc302c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/progressbar.py @@ -0,0 +1,252 @@ +""" +Progress Bar. + +pymdownx.progressbar +Simple plugin to add support for progress bars + +``` +/* No label */ +[==30%] + +/* Label */ +[==30% MyLabel] + +/* works with attr_list inline style */ +[==50/200 MyLabel]{: .additional-class } +``` + +New line is not required before the progress bar but suggested unless in a table. +Can take percentages and divisions. +Floats are okay. Numbers must be positive. This is an experimental extension. +Functionality is subject to change. + +Minimum Recommended Styling +(but you could add gloss, candy striping, animation, or anything else): + +``` +.progress { + display: block; + width: 300px; + margin: 10px 0; + height: 24px; + border: 1px solid #ccc; + -webkit-border-radius: 3px; + -moz-border-radius: 3px; + border-radius: 3px; + background-color: #F8F8F8; + position: relative; + box-shadow: inset -1px 1px 3px rgba(0, 0, 0, .1); +} + +.progress-label { + position: absolute; + text-align: center; + font-weight: bold; + width: 100%; margin: 0; + line-height: 24px; + color: #333; + -webkit-font-smoothing: antialiased !important; + white-space: nowrap; + overflow: hidden; +} + +.progress-bar { + height: 24px; + float: left; + border-right: 1px solid #ccc; + -webkit-border-radius: 3px; + -moz-border-radius: 3px; + border-radius: 3px; + background-color: #34c2e3; + box-shadow: inset 0 1px 0px rgba(255, 255, 255, .5); +} + +For Level Colors + +.progress-100plus .progress-bar { + background-color: #1ee038; +} + +.progress-80plus .progress-bar { + background-color: #86e01e; +} + +.progress-60plus .progress-bar { + background-color: #f2d31b; +} + +.progress-40plus .progress-bar { + background-color: #f2b01e; +} + +.progress-20plus .progress-bar { + background-color: #f27011; +} + +.progress-0plus .progress-bar { + background-color: #f63a0f; +} +``` + +MIT license. + +Copyright (c) 2014 - 2017 Isaac Muse + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, +and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +""" +from markdown import Extension +from markdown.inlinepatterns import InlineProcessor, dequote +import xml.etree.ElementTree as etree +from markdown.extensions.attr_list import AttrListTreeprocessor +from . import util + +RE_PROGRESS = r'''(?x) +\[={1,}\s* # Opening +(?: + (?P100(?:.0+)?|[1-9]?[0-9](?:\.\d+)?)% | # Percent + (?:(?P\d+(?:\.\d+)?)\s*/\s*(?P\d+(?:\.\d+)?)) # Fraction +) +(?P\s+(?P<quote>['"]).*?(?P=quote))?\s* # Title +\] # Closing +(?P<attr_list>\{\:?([^\}]*)\})? # Optional attr list +''' + +CLASS_LEVEL = "progress-%dplus" + + +class ProgressBarTreeProcessor(AttrListTreeprocessor): + """Used for AttrList compatibility.""" + + def run(self, elem): + """Inline check for attributes at start of tail.""" + + if elem.tail: + m = self.INLINE_RE.match(elem.tail) + if m: + self.assign_attrs(elem, m.group(1)) + elem.tail = elem.tail[m.end():] + + +class ProgressBarPattern(InlineProcessor): + """Pattern handler for the progress bars.""" + + def __init__(self, pattern, md): + """Initialize.""" + + InlineProcessor.__init__(self, pattern, md) + + def create_tag(self, width, label, add_classes, alist): + """Create the tag.""" + + # Create list of all classes and remove duplicates + classes = list( + set( + ["progress"] + + self.config.get('add_classes', '').split() + + add_classes + ) + ) + classes.sort() + el = etree.Element("div") + el.set('class', ' '.join(classes)) + bar = etree.SubElement(el, 'div') + bar.set('class', "progress-bar") + bar.set('style', 'width:%s%%' % width) + p = etree.SubElement(bar, 'p') + p.set('class', 'progress-label') + p.text = label + if alist is not None: + el.tail = alist + if 'attr_list' in self.md.treeprocessors: + ProgressBarTreeProcessor(self.md).run(el) + return el + + def handleMatch(self, m, data): + """Handle the match.""" + + label = "" + level_class = self.config.get('level_class', False) + increment = self.config.get('progress_increment', 20) + add_classes = [] + alist = None + if m.group(5): + label = dequote(self.unescape(m.group('title').strip())) + if m.group('attr_list'): + alist = m.group('attr_list') + if m.group('percent'): + value = float(m.group('percent')) + else: + try: + num = float(m.group('frac_num')) + except Exception: # pragma: no cover + num = 0.0 + try: + den = float(m.group('frac_den')) + except Exception: # pragma: no cover + den = 0.0 + if den == 0.0: + value = 0.0 + else: + value = (num / den) * 100.0 + + # We can never get a value < 0, + # but we must check for > 100. + if value > 100.0: + value = 100.0 + + # Round down to nearest increment step and include class if desired + if level_class: + add_classes.append(CLASS_LEVEL % int(value - (value % increment))) + + return self.create_tag('%.2f' % value, label, add_classes, alist), m.start(0), m.end(0) + + +class ProgressBarExtension(Extension): + """Add progress bar extension to Markdown class.""" + + def __init__(self, *args, **kwargs): + """Initialize.""" + + self.config = { + 'level_class': [ + True, + "Include class that defines progress level - Default: True" + ], + 'progress_increment': [ + 20, + "Progress increment step - Default: 20" + ], + 'add_classes': [ + '', + "Add additional classes to the progress tag for styling. " + "Classes are separated by spaces. - Default: None" + ] + } + + super().__init__(*args, **kwargs) + + def extendMarkdown(self, md): + """Add the progress bar pattern handler.""" + + util.escape_chars(md, ['=']) + progress = ProgressBarPattern(RE_PROGRESS, md) + progress.config = self.getConfigs() + md.inlinePatterns.register(progress, "progress-bar", 179) + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return ProgressBarExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/quotes.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/quotes.py new file mode 100644 index 0000000000000000000000000000000000000000..9b3f5db2b94d54df3c0d30633b69a483f2704a47 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/quotes.py @@ -0,0 +1,149 @@ +""" +Extension for "enhanced" blockquotes. + +This extension deviates from Python Markdown's original blockquote extension by: + +- not grouping consecutive block quotes together. +- Allowing optional callout behavior that mimics GitHub or Obsidian. +""" +import re +import xml.etree.ElementTree as etree +from markdown.blockprocessors import BlockProcessor +from markdown.treeprocessors import Treeprocessor +from markdown import util +from markdown import Extension, Markdown +from markdown.blockparser import BlockParser +from typing import Any + + +class QuotesProcessor(BlockProcessor): + """Process blockquotes.""" + + RE = re.compile(r'(^|\n)[ ]{0,3}>[ ]?(.*)') + RE_CALLOUT = re.compile(r'> *\[!([\w-]+(?: *\| *[\w-]+)*)]([-+])?(.*?)(?:\n|$)') + + def __init__(self, parser: BlockParser, config: dict[str, Any]) -> None: + """Initialize.""" + + super().__init__(parser) + self.callouts = config['callouts'] + + def test(self, parent: etree.Element, block: str) -> bool: + """Test for block quote.""" + + return bool(self.RE.search(block)) and not util.nearing_recursion_limit() + + def run(self, parent: etree.Element, blocks: list[str]) -> None: + """Create blockquote.""" + + block = blocks.pop(0) + alert = [] + details = '' + m = self.RE.search(block) + if m: + before = block[:m.start()] # Lines before blockquote + # Pass lines before blockquote in recursively for parsing first. + self.parser.parseBlocks(parent, [before]) + # Remove `> ` from beginning of each line. + lines = block[m.start():].split('\n') + if lines and self.callouts: + m2 = None + index = 0 + for line in lines: + if line and line.strip() != '>': + m2 = self.RE_CALLOUT.match(line) + break + index += 1 + if m2: + alert = [x.strip() for x in m2.group(1).split('|')] + if m2.group(2): + details = 'open' if m2.group(2) == '+' else 'closed' + title = m2.group(3).strip() if m2.group(3) else '' + if not title: + title = alert[0].title() + lines[index] = '' + lines.insert(index, title) + if alert: + alert[0] = alert[0].lower() + block = '\n'.join([self.clean(l) for l in lines]) + + # This is a new blockquote. Create a new parent element. + attrs = {'data-alert': ' '.join(alert), 'data-alert-collapse': details} if alert else {} + quote = etree.SubElement(parent, 'blockquote', attrs) + + # Recursively parse block with blockquote as parent. + # change parser state so blockquotes embedded in lists use `p` tags + self.parser.state.set('blockquote') + self.parser.parseChunk(quote, block) + self.parser.state.reset() + + def clean(self, line: str) -> str: + """Remove `>` from beginning of a line.""" + + m = self.RE.match(line) + if line.strip() == ">": + return "" + elif m: + return m.group(2) + else: + return line + + +class QuotesTreeprocessor(Treeprocessor): + """Convert "special" quotes to the common output format for Admonitions and Details.""" + + def run(self, root: etree.Element) -> etree.Element: + """Find and convert "special" blockquotes.""" + + for b in root.iter('blockquote'): + if b.attrib.get('data-alert'): + collapse = b.attrib.get('data-alert-collapse', '') + if collapse: + b.tag = 'details' + child = b.find('*') + if collapse == 'open': + b.attrib['open'] = 'open' + c = b.attrib.get('class', '').split(' ') + if child is not None and child.tag.lower() == 'p': + child.tag = 'summary' + else: + b.tag = 'div' + child = b.find('*') + c = b.attrib.get('class', '').split(' ') + c.append('admonition') + if child is not None and child.tag.lower() == 'p': + c2 = child.attrib.get('class', '').split(' ') + c2.append('admonition-title') + child.attrib['class'] = ' '.join(_c for _c in c2 if _c) + c.append(b.attrib.get('data-alert', '')) + b.attrib['class'] = ' '.join(_c for _c in c if _c) + del b.attrib['data-alert'] + del b.attrib['data-alert-collapse'] + return root + + +class QuotesExtension(Extension): + """Add blockquotes extension to Markdown class.""" + + def __init__(self, *args: Any, **kwargs: Any) -> None: + """Initialize.""" + + self.config = { + 'callouts': [False, "Enable GitHub/Obsidian style callouts - Default: False"] + } + super().__init__(*args, **kwargs) + + def extendMarkdown(self, md: Markdown) -> None: + """Add support for blockquotes.""" + + md.registerExtension(self) + config = self.getConfigs() + md.parser.blockprocessors.register(QuotesProcessor(md.parser, config), "quote", 20) + if config['callouts']: + md.treeprocessors.register(QuotesTreeprocessor(md), 'quotes', 19.99) + + +def makeExtension(*args: Any, **kwargs: Any) -> Extension: + """Return extension.""" + + return QuotesExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/saneheaders.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/saneheaders.py new file mode 100644 index 0000000000000000000000000000000000000000..53e2c3d2bc705f116660ac48d3a0ea5faa3e2cb5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/saneheaders.py @@ -0,0 +1,33 @@ +""" +Sane headers. + +Allow for a header implementation that requires `#` headers to have a space +after the `#` portion. This allows for things like Magiclink issues to work +at the beginning of lines, and potentially other things like tag extensions +etc. +""" +import re +from markdown import Extension +from markdown.blockprocessors import HashHeaderProcessor + + +class SaneHeadersProcessor(HashHeaderProcessor): + """Process hash headers syntax.""" + + RE = re.compile(r'(?:^|\n)(?P<level>#{1,6})(?=[ ])(?P<header>(?:\\.|[^\\])*?)#*(?:\n|$)') + + +class SaneHeadersExtension(Extension): + """Adds the sane headers extension.""" + + def extendMarkdown(self, md): + """Extend the inline and block processor objects.""" + + md.parser.blockprocessors.register(SaneHeadersProcessor(md.parser), 'hashheader', 70) + md.registerExtension(self) + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return SaneHeadersExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/slugs.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/slugs.py new file mode 100644 index 0000000000000000000000000000000000000000..8a3870e27ea19d1ad52977211d3563688f973121 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/slugs.py @@ -0,0 +1,125 @@ +""" +Slugs. + +Additional slug outputs. + +MIT license. + +Copyright (c) 2014 - 2017 Isaac Muse <isaacmuse@gmail.com> + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, +and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +""" +import re +import unicodedata +import functools +from urllib.parse import quote +from . import util + +RE_TAGS = re.compile(r'</?[^>]*>', re.UNICODE) +RE_INVALID_SLUG_CHAR = re.compile(r'[^\w\- ]', re.UNICODE) +RE_SEP = re.compile(r' ', re.UNICODE) +RE_ASCII_LETTERS = re.compile(r'[A-Z]', re.UNICODE) + + +def _uslugify(text, sep, case="none", percent_encode=False, normalize='NFC'): + """Unicode slugify (`utf-8`).""" + + # Normalize, Strip html tags, strip leading and trailing whitespace, and lower + slug = RE_TAGS.sub('', unicodedata.normalize(normalize, text)).strip() + + if case == 'lower': + slug = slug.lower() + elif case == 'lower-ascii': + def lower(m): + """Lowercase character.""" + return m.group(0).lower() + + slug = RE_ASCII_LETTERS.sub(lower, slug) + elif case == 'fold': + slug = slug.casefold() + + # Remove non word characters, non spaces, and non dashes, and convert spaces to dashes. + slug = RE_SEP.sub(sep, RE_INVALID_SLUG_CHAR.sub('', slug)) + + return quote(slug.encode('utf-8')) if percent_encode else slug + + +def slugify(**kwargs): + """Configurable slugify.""" + + case = kwargs.get('case', 'none') + percent = kwargs.get('percent_encode', False) + normalize = kwargs.get('normalize', 'NFC') + return functools.partial(_uslugify, case=case, percent_encode=percent, normalize=normalize) + + +@util.deprecated( + "'uslugify' is deprecated in favor of the configurable 'slugify' function. " + "See documentation for more info." +) +def uslugify(text, sep): + """Unicode slugify.""" + + return slugify(case='lower')(text, sep) + + +@util.deprecated( + "'uslugify_encoded' is deprecated in favor of the configurable 'slugify' function. " + "See documentation for more info." +) +def uslugify_encoded(text, sep): + """Unicode slugify (percent encoded).""" + + return slugify(case='lower', percent_encode=True)(text, sep) + + +@util.deprecated( + "'uslugify_cased' is deprecated in favor of the configurable 'slugify' function. " + "See documentation for more info." +) +def uslugify_cased(text, sep): + """Unicode slugify cased (keep case) (`utf-8`).""" + + return slugify()(text, sep) + + +@util.deprecated( + "'uslugify_cased_encode' is deprecated in favor of the configurable 'slugify' function. " + "See documentation for more info." +) +def uslugify_cased_encoded(text, sep): + """Unicode slugify cased (keep case) (percent encoded).""" + + return slugify(percent_encode=True)(text, sep) + + +@util.deprecated( + "'gfm' is deprecated in favor of the configurable 'slugify' function. " + "See documentation for more info." +) +def gfm(text, sep): + """Unicode slugify cased (cased Unicode only) (`utf-8`).""" + + return slugify(case="lower-ascii")(text, sep) + + +@util.deprecated( + "'gfm_encoded' is deprecated in favor of the configurable 'slugify' function. " + "See documentation for more info." +) +def gfm_encoded(text, sep): + """Unicode slugify cased (cased Unicode only) (percent encoded).""" + + return slugify(case='lower-ascii', percent_encode=True)(text, sep) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/smartsymbols.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/smartsymbols.py new file mode 100644 index 0000000000000000000000000000000000000000..18b584192eafd2a799fba5417370d03fb932c507 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/smartsymbols.py @@ -0,0 +1,173 @@ +""" +Smart Symbols. + +pymdownx.smartsymbols +Really simple plugin to add support for: + copyright, trademark, and registered symbols + plus/minus, not equal, arrows via: + + copyright = `(c)` + trademark = `(tm)` + registered = `(r)` + plus/minus = `+/-` + care/of = `c/o` + fractions = `1/2` etc. + (only certain available unicode fractions) + arrows: + left = `<--` + right = `-->` + both = `<-->` + not equal = `=/=` + (maybe this could be =/= in the future as this might be more + intuitive to non-programmers) + +MIT license. + +Copyright (c) 2014 - 2017 Isaac Muse <isaacmuse@gmail.com> + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, +and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +""" +from markdown import Extension +from markdown import treeprocessors +from markdown.util import Registry +from markdown.inlinepatterns import HtmlInlineProcessor + +RE_TRADE = ("smart-trademark", r'\(tm\)', r'™') +RE_COPY = ("smart-copyright", r'\(c\)', r'©') +RE_REG = ("smart-registered", r'\(r\)', r'®') +RE_PLUSMINUS = ("smart-plus-minus", r'\+/-', r'±') +RE_NOT_EQUAL = ("smart-not-equal", r'=/=', r'≠') +RE_CARE_OF = ("smart-care-of", r'\bc/o\b', r'℅') +RE_ORDINAL_NUMBERS = ( + "smart-ordinal-numbers", + r'''(?x) + \b + (?P<leading>(?:[1-9][0-9]*)?) + (?P<tail>(?<=1)(?:1|2|3)th|1st|2nd|3rd|[04-9]th) + \b + ''', + lambda m: '{}{}<sup>{}</sup>'.format( + m.group('leading') if m.group('leading') else '', + m.group('tail')[:-2], m.group('tail')[1:] + ) +) +RE_ARROWS = ( + "smart-arrows", + r'(?P<arrows>\<-{2}\>|(?<!-)-{2}\>|\<-{2}(?!-))', + lambda m: ARR[m.group('arrows')] +) +RE_FRACTIONS = ( + "smart-fractions", + r'(?<!\d)(?P<fractions>1/4|1/2|3/4|1/3|2/3|1/5|2/5|3/5|4/5|1/6|5/6|1/8|3/8|5/8|7/8)(?!\d)', + lambda m: FRAC[m.group('fractions')] +) + +REPL = { + 'trademark': RE_TRADE, + 'copyright': RE_COPY, + 'registered': RE_REG, + 'plusminus': RE_PLUSMINUS, + 'arrows': RE_ARROWS, + 'notequal': RE_NOT_EQUAL, + 'fractions': RE_FRACTIONS, + 'ordinal_numbers': RE_ORDINAL_NUMBERS, + 'care_of': RE_CARE_OF +} + +FRAC = { + "1/4": "¼", + "1/2": "½", + "3/4": "¾", + "1/3": "⅓", + "2/3": "⅔", + "1/5": "⅕", + "2/5": "⅖", + "3/5": "⅗", + "4/5": "⅘", + "1/6": "⅙", + "5/6": "⅚", + "1/8": "⅛", + "3/8": "⅜", + "5/8": "⅝", + "7/8": "⅞" +} + +ARR = { + '-->': "→", + '<--': "←", + '<-->': "↔" +} + + +class SmartSymbolsPattern(HtmlInlineProcessor): + """Smart symbols patterns handler.""" + + def __init__(self, pattern, replace, md): + """Setup replace pattern.""" + + super().__init__(pattern, md) + self.replace = replace + + def handleMatch(self, m, data): + """Replace symbol.""" + + return self.md.htmlStash.store( + m.expand(self.replace(m) if callable(self.replace) else self.replace), + ), m.start(0), m.end(0) + + +class SmartSymbolsExtension(Extension): + """Smart Symbols extension.""" + + def __init__(self, *args, **kwargs): + """Setup config of which symbols are enabled.""" + + self.config = { + 'trademark': [True, 'Trademark'], + 'copyright': [True, 'Copyright'], + 'registered': [True, 'Registered'], + 'plusminus': [True, 'Plus/Minus'], + 'arrows': [True, 'Arrows'], + 'notequal': [True, 'Not Equal'], + 'fractions': [True, 'Fractions'], + 'ordinal_numbers': [True, 'Ordinal Numbers'], + 'care_of': [True, 'Care/of'] + } + super().__init__(*args, **kwargs) + + def add_pattern(self, patterns, md): + """Construct the inline symbol pattern.""" + + self.patterns.register(SmartSymbolsPattern(patterns[1], patterns[2], md), patterns[0], 30) + + def extendMarkdown(self, md): + """Create a dict of inline replace patterns and add to the tree processor.""" + + configs = self.getConfigs() + self.patterns = Registry() + + for k, v in REPL.items(): + if configs[k]: + self.add_pattern(v, md) + + inline_processor = treeprocessors.InlineProcessor(md) + inline_processor.inlinePatterns = self.patterns + md.treeprocessors.register(inline_processor, "smart-symbols", 6.1) + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return SmartSymbolsExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/snippets.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/snippets.py new file mode 100644 index 0000000000000000000000000000000000000000..305c7c0aae68516f4aad77c2430234762e981688 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/snippets.py @@ -0,0 +1,473 @@ +""" +Snippet ---8<---. + +pymdownx.snippet +Inject snippets + +MIT license. + +Copyright (c) 2017 Isaac Muse <isaacmuse@gmail.com> + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, +and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +""" +from markdown import Extension +from markdown.preprocessors import Preprocessor +import functools +import urllib +import re +import os +from . import util +import textwrap +import time + +MI = 1024 * 1024 # mebibyte (MiB) +DEFAULT_URL_SIZE = MI * 32 +DEFAULT_URL_TIMEOUT = 10.0 # in seconds +DEFAULT_URL_REQUEST_HEADERS = {} +DEFAULT_MAX_RETRIES = 3 +DEFAULT_BACKOFF_FACTOR = 2 + + +class SnippetMissingError(Exception): + """Snippet missing exception.""" + + +class SnippetPreprocessor(Preprocessor): + """Handle snippets in Markdown content.""" + + RE_ALL_SNIPPETS = re.compile( + r'''(?x) + ^(?P<space>[ \t]*) + (?P<escape>;*) + (?P<all> + (?P<inline_marker>-{1,}8<-{1,}[ \t]+) + (?P<snippet>(?:"(?:\\"|[^"\n\r])+?"|'(?:\\'|[^'\n\r])+?'))(?![ \t]) | + (?P<block_marker>-{1,}8<-{1,})(?![ \t]) + )\r?$ + ''' + ) + + RE_SNIPPET = re.compile( + r'''(?x) + ^(?P<space>[ \t]*) + (?P<snippet>.*?)\r?$ + ''' + ) + + RE_SNIPPET_SECTION = re.compile( + r'''(?xi) + ^(?P<pre>.*?) + (?P<escape>;*) + (?P<inline_marker>-{1,}8<-{1,}[ \t]+) + (?P<section>\[[ \t]*(?P<type>start|end)[ \t]*:[ \t]*(?P<name>[a-z][-_0-9a-z]*)[ \t]*\]) + (?P<post>.*?)$ + ''' + ) + + RE_SNIPPET_FILE = re.compile( + r'(?i)(.*?)(?:((?::-?[0-9]*){1,2}(?:(?:,(?=[-0-9:])-?[0-9]*)(?::-?[0-9]*)?)*)|(:[a-z][-_0-9a-z]*))?$' + ) + + def __init__(self, config, md): + """Initialize.""" + + base = config.get('base_path') + if isinstance(base, (str, os.PathLike)): + base = [base] + self.base_path = [os.path.abspath(b) for b in base] + self.restrict_base_path = config['restrict_base_path'] + self.encoding = config.get('encoding') + self.check_paths = config.get('check_paths') + self.auto_append = config.get('auto_append') + self.url_download = config['url_download'] + self.url_max_size = config['url_max_size'] + self.url_timeout = config['url_timeout'] + self.url_request_headers = config['url_request_headers'] + self.dedent_subsections = config['dedent_subsections'] + self.max_retries = config['max_retries'] + self.backoff_factor = config['backoff_factor'] + self.tab_length = md.tab_length + super().__init__() + + self.download.cache_clear() + + def extract_section(self, section, lines): + """Extract the specified section from the lines.""" + + new_lines = [] + start = False + found = False + for l in lines: + + # Found a snippet section marker with our specified name + m = self.RE_SNIPPET_SECTION.match(l) + + # Handle escaped line + if m and start and m.group('escape'): + l = ( + m.group('pre') + m.group('escape').replace(';', '', 1) + m.group('inline_marker') + + m.group('section') + m.group('post') + ) + + # Found a section we are looking for. + elif m is not None and m.group('name') == section: + + # We found the start + if not start and m.group('type') == 'start': + start = True + found = True + continue + + # Ignore duplicate start + elif start and m.group('type') == 'start': + continue + + # We found the end + elif start and m.group('type') == 'end': + start = False + break + + # We found an end, but no start + else: + break + + # Found a section we don't care about, so ignore it. + elif m and start: + continue + + # We are currently in a section, so append the line + if start: + new_lines.append(l) + + if not found and self.check_paths: + raise SnippetMissingError(f"Snippet section '{section}' could not be located") + + return self.dedent(new_lines) if self.dedent_subsections else new_lines + + def dedent(self, lines): + """De-indent lines.""" + + return textwrap.dedent('\n'.join(lines)).split('\n') + + def get_snippet_path(self, path): + """Get snippet path.""" + + snippet = None + for base in self.base_path: + if os.path.exists(base): + if os.path.isdir(base): + if self.restrict_base_path: + filename = os.path.abspath(os.path.join(base, path)) + # If the absolute path is no longer under the specified base path, reject the file + if not filename.startswith(base): + continue + else: + filename = os.path.join(base, path) + if os.path.exists(filename): + snippet = filename + break + else: + dirname = os.path.dirname(base) + filename = os.path.join(dirname, path) + if os.path.exists(filename) and os.path.samefile(filename, base): + snippet = filename + break + return snippet + + @functools.lru_cache # noqa: B019 + def download(self, url): + """ + Actually download the snippet pointed to by the passed URL. + + The most recently used files are kept in a cache until the next reset. + """ + + retries = self.max_retries + + while True: + try: + http_request = urllib.request.Request(url, headers=self.url_request_headers) + timeout = None if self.url_timeout == 0 else self.url_timeout + with urllib.request.urlopen(http_request, timeout=timeout) as response: + # Fail if status is not OK + status = response.status if util.PY39 else response.code + + if status != 200: + raise SnippetMissingError(f"Cannot download snippet '{url}' (HTTP Error {status})") + + # We provide some basic protection against absurdly large files. + # 32MB is chosen as an arbitrary upper limit. This can be raised if desired. + content = None + if "content-length" not in response.headers: + # we have to read to know if we went over the max, but never more than `url_max_size` + # where `url_max_size` == 0 means unlimited + content = response.read(self.url_max_size) if self.url_max_size != 0 else response.read() + content_length = len(content) + else: + content_length = int(response.headers["content-length"]) + + if self.url_max_size != 0 and content_length >= self.url_max_size: + raise ValueError(f"refusing to read payloads larger than or equal to {self.url_max_size}") + + # Nothing to return + if content_length == 0: + return [''] + + if content is None: + # content-length was in the header, so we did not read yet + content = response.read() + + # Process lines + last = content.endswith((b'\r', b'\n')) + s_lines = [l.decode(self.encoding) for l in content.splitlines()] + if last: + s_lines.append('') + return s_lines + + except urllib.error.HTTPError as e: # noqa: PERF203 + # Handle rate limited error codes + if e.code == 429 and retries: + retries -= 1 + wait = self.backoff_factor * (self.max_retries - retries) + time.sleep(wait) + continue + raise SnippetMissingError(f"Cannot download snippet '{url}' (HTTP Error {e.code})") from e + + + def parse_snippets(self, lines, file_name=None, is_url=False, is_section=False): + """Parse snippets snippet.""" + + if file_name: + # Track this file. + self.seen.add(file_name) + + new_lines = [] + inline = False + block = False + for line in lines: + # Check for snippets on line + inline = False + m = self.RE_ALL_SNIPPETS.match(line) + if m: + if m.group('escape'): + # The snippet has been escaped, replace first `;` and continue. + new_lines.append(line.replace(';', '', 1)) + continue + + if block and m.group('inline_marker'): + # Don't use inline notation directly under a block. + # It's okay if inline is used again in sub file though. + continue + + elif m.group('inline_marker'): + # Inline + inline = True + + else: + # Block + block = not block + continue + + elif not block: + if not is_section: + # Check for section line, if present remove, if escaped, reformat it + m2 = self.RE_SNIPPET_SECTION.match(line) + if m2 and m2.group('escape'): + line = ( + m2.group('pre') + m2.group('escape').replace(';', '', 1) + m2.group('inline_marker') + + m2.group('section') + m2.group('post') + ) + m2 = None + + # Found a section that must be removed + if m2 is not None: + continue + + # Not in snippet, and we didn't find an inline, + # so just a normal line + new_lines.append(line) + continue + + if block and not inline: + # We are in a block and we didn't just find a nested inline + # So check if a block path + m = self.RE_SNIPPET.match(line) + + if m: + # Get spaces and snippet path. Remove quotes if inline. + space = m.group('space').expandtabs(self.tab_length) + path = m.group('snippet')[1:-1].strip() if inline else m.group('snippet').strip() + + if not inline: + # Block path handling + if not path: + # Empty path line, insert a blank line + new_lines.append('') + continue + + # Ignore commented out lines + if path.startswith(';'): + continue + + # Get line numbers (if specified) + end = [] + start = [] + section = None + m = self.RE_SNIPPET_FILE.match(path) + path = '' if m is None else m.group(1).strip() + # Looks like we have an empty file and only lines specified + if not path: + if self.check_paths: + raise SnippetMissingError(f"Snippet at path '{path}' could not be found") + else: + continue + if m.group(2): + for nums in m.group(2)[1:].split(','): + span = nums.split(':') + st = int(span[0]) if span[0] else None + start.append(st if st is None or st < 0 else max(0, st - 1)) + en = int(span[1]) if len(span) > 1 and span[1] else None + end.append(en) + elif m.group(3): + section = m.group(3)[1:] + + # Ignore path links if we are in external, downloaded content + is_link = path.lower().startswith(('https://', 'http://')) + if is_url and not is_link: + continue + + # If this is a link, and we are allowing URLs, set `url` to true. + # Make sure we don't process `path` as a local file reference. + url = self.url_download and is_link + snippet = self.get_snippet_path(path) if not url else path + + if snippet: + + # This is in the stack and we don't want an infinite loop! + if snippet in self.seen: + continue + + if not url: + # Read file content + with open(snippet, 'r', encoding=self.encoding) as f: + last = False + s_lines = [] + for l in f: + last = l.endswith(('\r', '\n')) + s_lines.append(l.strip('\r\n')) + if last: + s_lines.append('') + else: + # Read URL content + try: + s_lines = self.download(snippet) + except SnippetMissingError: + if self.check_paths: + raise + s_lines = [] + + if s_lines: + total = len(s_lines) + if start and end: + final_lines = [] + for sel in zip(start, end): + s_start = util.clamp(total + sel[0], 0, total) if sel[0] and sel[0] < 0 else sel[0] + s_end = util.clamp(total + 1 + sel[1], 0, total) if sel[1] and sel[1] < 0 else sel[1] + final_lines.extend(s_lines[slice(s_start, s_end, None)]) + s_lines = self.dedent(final_lines) if self.dedent_subsections else final_lines + elif section: + s_lines = self.extract_section(section, s_lines) + + # Process lines looking for more snippets + new_lines.extend( + [ + space + l2 for l2 in self.parse_snippets( + s_lines, + snippet, + is_url=url, + is_section=section is not None + ) + ] + ) + + elif self.check_paths: + raise SnippetMissingError(f"Snippet at path '{path}' could not be found") + + # Pop the current file name out of the cache + if file_name: + self.seen.remove(file_name) + + return new_lines + + def run(self, lines): + """Process snippets.""" + + self.seen = set() + if self.auto_append: + lines.extend("\n\n-8<-\n{}\n-8<-\n".format('\n\n'.join(self.auto_append)).split('\n')) + + return self.parse_snippets(lines) + + +class SnippetExtension(Extension): + """Snippet extension.""" + + def __init__(self, *args, **kwargs): + """Initialize.""" + + self.config = { + 'base_path': [["."], "Base path for snippet paths - Default: [\".\"]"], + 'restrict_base_path': [ + True, + "Restrict snippet paths such that they are under the base paths - Default: True" + ], + 'encoding': ["utf-8", "Encoding of snippets - Default: \"utf-8\""], + 'check_paths': [False, "Make the build fail if a snippet can't be found - Default: \"False\""], + "auto_append": [ + [], + "A list of snippets (relative to the 'base_path') to auto append to the Markdown content - Default: []" + ], + 'url_download': [False, "Download external URLs as snippets - Default: \"False\""], + 'url_max_size': [DEFAULT_URL_SIZE, "External URL max size (0 means no limit)- Default: 32 MiB"], + 'url_timeout': [DEFAULT_URL_TIMEOUT, 'Defualt URL timeout (0 means no timeout) - Default: 10 sec'], + 'url_request_headers': [DEFAULT_URL_REQUEST_HEADERS, "Extra request Headers - Default: {}"], + 'dedent_subsections': [False, "Dedent subsection extractions e.g. 'sections' and/or 'lines'."], + 'max_retries': [ + DEFAULT_MAX_RETRIES, "Maximum number of retry attempts for rate-limited requests - Default: 3" + ], + 'backoff_factor': [DEFAULT_BACKOFF_FACTOR, "Backoff factor for retry attempts - Default: 2"] + } + + super().__init__(*args, **kwargs) + + def extendMarkdown(self, md): + """Register the extension.""" + + self.md = md + md.registerExtension(self) + config = self.getConfigs() + snippet = SnippetPreprocessor(config, md) + md.preprocessors.register(snippet, "snippet", 32) + + def reset(self): + """Reset.""" + + self.md.preprocessors['snippet'].download.cache_clear() + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return SnippetExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/striphtml.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/striphtml.py new file mode 100644 index 0000000000000000000000000000000000000000..1bc4312a0d9b15db229a6807b50a284db36412e6 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/striphtml.py @@ -0,0 +1,151 @@ +""" +Strip HTML (previously named Plain HTML). + +pymdownx.striphtml +An extension for Python Markdown. +Strip classes, styles, and ids from html + +MIT license. + +Copyright (c) 2014 - 2017 Isaac Muse <isaacmuse@gmail.com> + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, +and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +""" +from markdown import Extension +from markdown.postprocessors import Postprocessor +import re + + +RE_TAG_HTML = re.compile( + r'''(?x) + (?: + (?P<comments>(?:\r?\n?\s*)<!--(?:-(?!->)|[^-])*?-->(?:\s*)(?=\r?\n)|<!--[\s\S]*?-->)| + (?P<scripts> + (?P<script_open><(?P<script_name>style|script)) + (?P<script_attr>(?:\s+[\w\-:]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s"'`=<>]+))?)*) + (?P<script_rest>\s*>.*?</(?P=script_name)\s*>) + )| + (?P<open><(?P<name>[\w\:\.\-]+)) + (?P<attr>(?:\s+[\w\-:]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s"'`=<>]+))?)*) + (?P<close>\s*(?P<self_close>/)?>)| + (?P<close_tag></(?P<close_name>[\w\:\.\-]+)\s*>) + ) + ''', + re.DOTALL | re.UNICODE +) + +TAG_BAD_ATTR = r'''(?x) +(?P<attr> + (?: + \s+(?:%s) + (?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s"'`=<>]+)) + )* +) +''' + + +class StripHtmlPostprocessor(Postprocessor): + """Post processor to strip out unwanted content.""" + + def __init__(self, strip_comments, strip_js_on_attributes, strip_attributes, md): + """Initialize.""" + + self.strip_comments = strip_comments + self.re_attributes = None + attributes = [re.escape(a.strip()) for a in strip_attributes] + if strip_js_on_attributes: + attributes.append(r'on[\w]+') + if attributes: + self.re_attributes = re.compile( + TAG_BAD_ATTR % '|'.join(attributes), + re.DOTALL | re.UNICODE + ) + + super().__init__(md) + + def repl(self, m): + """Replace comments and unwanted attributes.""" + + if m.group('comments'): + tag = '' if self.strip_comments else m.group('comments') + else: + if m.group('scripts'): + tag = m.group('script_open') + if self.re_attributes is not None: + tag += self.re_attributes.sub('', m.group('script_attr')) + else: + tag += m.group('script_attr') + tag += m.group('script_rest') + elif m.group('close_tag'): + tag = m.group(0) + else: + tag = m.group('open') + if self.re_attributes is not None: + tag += self.re_attributes.sub('', m.group('attr')) + else: + tag += m.group('attr') + tag += m.group('close') + return tag + + def run(self, text): + """Strip out ids and classes for a simplified HTML output.""" + + strip = self.strip_comments or self.strip_js_on_attributes or self.re_attributes + return RE_TAG_HTML.sub(self.repl, text) if strip else text + + +class StripHtmlExtension(Extension): + """StripHTML extension.""" + + def __init__(self, *args, **kwargs): + """Initialize.""" + + self.config = { + 'strip_comments': [ + True, + "Strip HTML comments at the end of processing. " + "- Default: True" + ], + 'strip_attributes': [ + [], + "A string of attributes separated by spaces." + "- Default: 'id class style']" + ], + 'strip_js_on_attributes': [ + True, + "Strip JavaScript script attribues with the pattern on*. " + " - Default: True" + ] + } + super().__init__(*args, **kwargs) + + def extendMarkdown(self, md): + """Strip unwanted HTML attributes and/or comments.""" + + md.registerExtension(self) + config = self.getConfigs() + striphtml = StripHtmlPostprocessor( + config.get('strip_comments'), + config.get('strip_js_on_attributes'), + config.get('strip_attributes'), + md + ) + md.postprocessors.register(striphtml, "strip-html", 1) + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return StripHtmlExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/superfences.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/superfences.py new file mode 100644 index 0000000000000000000000000000000000000000..b1115942ca930480207d1c4d630d6e12595843f4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/superfences.py @@ -0,0 +1,1070 @@ +""" +SuperFences. + +pymdownx.superfences +Nested Fenced Code Blocks + +This is a modification of the original Fenced Code Extension. +Algorithm has been rewritten to allow for fenced blocks in blockquotes, +lists, etc. And also , allow for special UML fences like 'flow' for flowcharts +and `sequence` for sequence diagrams. + +Modified: 2014 - 2017 Isaac Muse <isaacmuse@gmail.com> +--- + +Fenced Code Extension for Python Markdown +========================================= + +This extension adds Fenced Code Blocks to Python-Markdown. + +See <https://pythonhosted.org/Markdown/extensions/fenced_code_blocks.html> +for documentation. + +Original code Copyright 2007-2008 [Waylan Limberg](https://github.com/waylan). + + +All changes Copyright 2008-2014 The Python Markdown Project + +License: [BSD](http://www.opensource.org/licenses/bsd-license.php) +""" +from markdown.extensions import Extension +from markdown.preprocessors import Preprocessor +from markdown.blockprocessors import CodeBlockProcessor +from markdown.extensions.attr_list import get_attrs +from markdown import util as md_util +import functools +import re +from .quotes import QuotesExtension + +SOH = '\u0001' # start +EOT = '\u0004' # end + +PREFIX_CHARS = ('>', ' ', '\t') + +RE_NESTED_FENCE_START = re.compile( + r'''(?x) + (?P<fence>~{3,}|`{3,}) + (?:[ \t]*\.?(?P<lang>[\w#.+-]+)(?=[\t ]|$))? # Language + (?: + [ \t]*(\{(?P<attrs>[^\n]*)\}) | # Optional attributes or + (?P<options> + (?: + (?:[ \t]*[a-zA-Z][a-zA-Z0-9_]*(?:=(?P<quot>"|').*?(?P=quot))?)(?=[\t ]|$) # Options + )+ + ) | + (?P<unrecognized> + (?:([ \t]*[^\s]+)(?=[\t ]|$))+ + ) + )?[ \t]*$ + ''' +) + +RE_HL_LINES = re.compile(r'^(?P<hl_lines>\d+(?:-\d+)?(?:[ \t]+\d+(?:-\d+)?)*)$') +RE_LINENUMS = re.compile(r'(?P<linestart>[\d]+)(?:[ \t]+(?P<linestep>[\d]+))?(?:[ \t]+(?P<linespecial>[\d]+))?') +RE_OPTIONS = re.compile( + r'''(?x) + (?: + (?P<key>[a-zA-Z][a-zA-Z0-9_]*)(?:=(?P<quot>"|')(?P<value>.*?)(?P=quot))? + ) + ''' +) + +NESTED_FENCE_END = r'%s[ \t]*$' + +FENCED_BLOCK_RE = re.compile( + r'^([\> ]*){}({}){}$'.format( + md_util.HTML_PLACEHOLDER[0], + md_util.HTML_PLACEHOLDER[1:-1] % r'([0-9]+)', + md_util.HTML_PLACEHOLDER[-1] + ) +) + + +class SuperFencesException(Exception): + """Special exception to ensure one is raised when a fence fails.""" + + +def _escape(txt): + """Basic html escaping.""" + + txt = txt.replace('&', '&') + txt = txt.replace('<', '<') + txt = txt.replace('>', '>') + return txt + + +class CodeStash: + """ + Stash code for later retrieval. + + Store original fenced code here in case we were + too greedy and need to restore in an indented code + block. + """ + + def __init__(self): + """Initialize.""" + + self.stash = {} + + def __len__(self): # pragma: no cover + """Length of stash.""" + + return len(self.stash) + + def get(self, key, default=None): + """Get the code from the key.""" + + code = self.stash.get(key, default) + return code + + def remove(self, key): + """Remove the stashed code.""" + + del self.stash[key] + + def store(self, key, code, indent_level): + """Store the code in the stash.""" + + self.stash[key] = (code, indent_level) + + def clear_stash(self): + """Clear the stash.""" + + self.stash = {} + + +def fence_code_format(source, language, class_name, options, md, **kwargs): + """Format source as code blocks.""" + + classes = kwargs['classes'] + id_value = kwargs['id_value'] + attrs = kwargs['attrs'] + + if class_name: + classes.insert(0, class_name) + + id_value = f' id="{id_value}"' if id_value else '' + classes = ' class="{}"'.format(' '.join(classes)) if classes else '' + attrs = ' ' + ' '.join(f'{k}="{v}"' for k, v in attrs.items()) if attrs else '' + + return '<pre{}{}{}><code>{}</code></pre>'.format(id_value, classes, attrs, _escape(source)) + + +def fence_div_format(source, language, class_name, options, md, **kwargs): + """Format source as div.""" + + classes = kwargs['classes'] + id_value = kwargs['id_value'] + attrs = kwargs['attrs'] + + if class_name: + classes.insert(0, class_name) + + id_value = f' id="{id_value}"' if id_value else '' + classes = ' class="{}"'.format(' '.join(classes)) if classes else '' + attrs = ' ' + ' '.join(f'{k}="{v}"' for k, v in attrs.items()) if attrs else '' + + return '<div{}{}{}>{}</div>'.format(id_value, classes, attrs, _escape(source)) + + +def highlight_validator(language, inputs, options, attrs, md): + """Highlight validator.""" + + use_pygments = md.preprocessors['fenced_code_block'].use_pygments + + for k, v in inputs.items(): + matched = False + if use_pygments: + if k.startswith('data-'): + attrs[k] = v + continue + for opt, validator in (('hl_lines', RE_HL_LINES), ('linenums', RE_LINENUMS), ('title', None)): + if k == opt: + if v is not True and (validator is None or validator.match(v) is not None): + options[k] = v + matched = True + break + if not matched: + attrs[k] = v + + return True + + +def default_validator(language, inputs, options, attrs, md): + """Default validator.""" + + for k, v in inputs.items(): + attrs[k] = v + return True + + +def _validator(language, inputs, options, attrs, md, validator=None): + """Validator wrapper.""" + + md.preprocessors['fenced_code_block'].get_hl_settings() + return validator(language, inputs, options, attrs, md) + + +def _formatter(src='', language='', options=None, md=None, class_name="", _fmt=None, **kwargs): + """Formatter wrapper.""" + + return _fmt(src, language, class_name, options, md, **kwargs) + + +def _test(language, test_language=None): + """Test language.""" + + return test_language is None or test_language == "*" or language == test_language + + +class SuperFencesCodeExtension(Extension): + """SuperFences code block extension.""" + + def __init__(self, *args, **kwargs): + """Initialize.""" + + self.superfences = [] + self.config = { + 'disable_indented_code_blocks': [False, "Disable indented code blocks - Default: False"], + 'custom_fences': [[], 'Specify custom fences. Default: See documentation.'], + 'css_class': [ + '', + "Set class name for wrapper element. The default of CodeHilite or Highlight will be used" + "if nothing is set. - " + "Default: ''" + ], + 'preserve_tabs': [False, "Preserve tabs in fences - Default: False"], + 'relaxed_headers': [False, "Relaxed fenced code headers - Default: False"] + } + super().__init__(*args, **kwargs) + + def extend_super_fences(self, name, formatter, validator): + """Extend SuperFences with the given name, language, and formatter.""" + + obj = { + "name": name, + "test": functools.partial(_test, test_language=name), + "formatter": formatter, + "validator": validator + } + + if name == '*': + self.superfences[0] = obj + else: + self.superfences.append(obj) + + def extendMarkdown(self, md): + """Add fenced block preprocessor to the Markdown instance.""" + + # Not super yet, so let's make it super + md.registerExtension(self) + config = self.getConfigs() + + # Default fenced blocks + self.superfences.insert( + 0, + { + "name": "superfences", + "test": _test, + "formatter": None, + "validator": functools.partial(_validator, validator=highlight_validator) + } + ) + + # Custom Fences + custom_fences = config.get('custom_fences', []) + for custom in custom_fences: + name = custom.get('name') + class_name = custom.get('class') + fence_format = custom.get('format', fence_code_format) + validator = custom.get('validator', default_validator) + if name is not None and class_name is not None: + self.extend_super_fences( + name, + functools.partial(_formatter, class_name=class_name, _fmt=fence_format), + functools.partial(_validator, validator=validator) + ) + + self.md = md + self.patch_fenced_rule() + self.stash = CodeStash() + + def patch_fenced_rule(self): + """ + Patch Python Markdown with our own fenced block extension. + + We don't attempt to protect against a user loading the `fenced_code` extension with this. + Most likely they will have issues, but they shouldn't have loaded them together in the first place :). + """ + + config = self.getConfigs() + + fenced = SuperFencesBlockPreprocessor(self.md) + fenced.config = config + fenced.extension = self + if self.superfences[0]['name'] == "superfences": + self.superfences[0]["formatter"] = fenced.highlight + self.md.preprocessors.register(fenced, "fenced_code_block", 25) + + indented_code = SuperFencesCodeBlockProcessor(self.md.parser) + indented_code.config = config + indented_code.extension = self + self.md.parser.blockprocessors.register(indented_code, "code", 80) + + if config["preserve_tabs"]: + # Need to squeeze in right after critic. + raw_fenced = SuperFencesRawBlockPreprocessor(self.md) + raw_fenced.config = config + raw_fenced.extension = self + self.md.preprocessors.register(raw_fenced, "fenced_raw_block", 31.05) + self.md.registerExtensions(["pymdownx._bypassnorm"], {}) + + # Add the highlight extension, but do so in a disabled state so we can just retrieve default configurations + self.md.registerExtensions(["pymdownx.highlight"], {"pymdownx.highlight": {"_enabled": False}}) + + def reset(self): + """Clear the stash.""" + + self.stash.clear_stash() + + +class SuperFencesBlockPreprocessor(Preprocessor): + """ + Preprocessor to find fenced code blocks. + + Because this is done as a preprocessor, it might be too greedy. + We will stash the blocks code and restore if we mistakenly processed + text from an indented code block. + """ + + CODE_WRAP = '<pre%s><code%s>%s</code></pre>' + + def __init__(self, md): + """Initialize.""" + + super().__init__(md) + self.tab_len = self.md.tab_length + self.checked_hl_settings = False + self.codehilite_conf = {} + self.checked_quotes = False + self.quotes_logic = False + + def normalize_ws(self, text): + """Normalize whitespace.""" + + return text.expandtabs(self.tab_len) + + def rebuild_block(self, lines): + """Dedent the fenced block lines.""" + + return '\n'.join([line[self.ws_virtual_len:] for line in lines]) + + def is_pymdownx_quotes_logic(self): + """Check if we are using the Quotes blockquote logic.""" + + if not self.checked_quotes: + self.checked_quotes = True + for ext in self.md.registeredExtensions: + if isinstance(ext, QuotesExtension): + self.quotes_logic = True + break + return self.quotes_logic + + def get_hl_settings(self): + """Check for Highlight extension to get its configurations.""" + + if not self.checked_hl_settings: + self.checked_hl_settings = True + + config = None + self.highlighter = None + for ext in self.md.registeredExtensions: + self.highlight_ext = ext + try: + config = ext.get_pymdownx_highlight_settings() + self.highlighter = ext.get_pymdownx_highlighter() + break + except AttributeError: + pass + + self.attr_list = 'attr_list' in self.md.treeprocessors + + css_class = self.config['css_class'] + self.css_class = css_class if css_class else config['css_class'] + + self.relaxed_headers = self.config.get('relaxed_headers', False) + self.extend_pygments_lang = config.get('extend_pygments_lang', None) + self.guess_lang = config['guess_lang'] + self.pygments_style = config['pygments_style'] + self.use_pygments = config['use_pygments'] + self.noclasses = config['noclasses'] + self.linenums = config['linenums'] + self.linenums_style = config.get('linenums_style', 'table') + self.linenums_class = config.get('linenums_class', 'linenums') + self.linenums_special = config.get('linenums_special', -1) + self.language_prefix = config.get('language_prefix', 'language-') + self.code_attr_on_pre = config.get('code_attr_on_pre', False) + self.auto_title = config.get('auto_title', False) + self.auto_title_map = config.get('auto_title_map', {}) + self.line_spans = config.get('line_spans', '') + self.line_anchors = config.get('line_anchors', '') + self.anchor_linenums = config.get('anchor_linenums', False) + self.pygments_lang_class = config.get('pygments_lang_class', False) + self.stripnl = config.get('stripnl', True) + self.default_lang = config.get('default_lang', True) + + def clear(self): + """Reset the class variables.""" + + self.ws = None + self.ws_len = 0 + self.ws_virtual_len = 0 + self.fence = None + self.lang = None + self.quote_level = 0 + self.code = [] + self.empty_lines = 0 + self.fence_end = None + self.options = {} + self.classes = [] + self.id = '' + self.attrs = {} + self.formatter = None + + def eval_fence(self, ws, content, start, end): + """Evaluate a normal fence.""" + + if (ws + content).strip() == '': + # Empty line is okay + self.empty_lines += 1 + self.code.append(ws + content) + elif len(ws) != self.ws_virtual_len and content != '': + # Not indented enough + self.clear() + elif self.fence_end.match(content) is not None and not content.startswith((' ', '\t')): + # End of fence + try: + self.process_nested_block(ws, content, start, end) + except SuperFencesException: + raise + except Exception: + self.clear() + else: + # Content line + self.empty_lines = 0 + self.code.append(ws + content) + + def eval_quoted(self, ws, content, quote_level, start, end): + """Evaluate fence inside a blockquote.""" + + quotes_logic = self.is_pymdownx_quotes_logic() + + if quote_level > self.quote_level: + # Quote level exceeds the starting quote level + self.clear() + return + + if quotes_logic and quote_level != self.quote_level: + # If we are using the Quotes extension, quote levels on each line must match. + self.clear() + return + + if content == '': + # Empty line is okay + self.code.append(ws + content) + self.empty_lines += 1 + elif len(ws) < self.ws_len: + # Not indented enough + self.clear() + elif self.empty_lines and quote_level < self.quote_level: + # Quote levels don't match and we are signified + # the end of the block with an empty line + self.clear() + elif self.fence_end.match(content) is not None: + # End of fence + try: + self.process_nested_block(ws, content, start, end) + except SuperFencesException: + raise + except Exception: + self.clear() + else: + # Content line + self.empty_lines = 0 + self.code.append(ws + content) + + def process_nested_block(self, ws, content, start, end): + """Process the contents of the nested block.""" + + self.last = ws + self.normalize_ws(content) + code = None + if self.formatter is not None: + self.line_count = end - start - 2 + + code = self.formatter( + src=self.rebuild_block(self.code), + language=self.lang, + md=self.md, + options=self.options, + classes=self.classes, + id_value=self.id, + attrs=self.attrs if self.attr_list else {} + ) + + if code is not None: + self._store(self.normalize_ws('\n'.join(self.code)) + '\n', code, start, end) + self.clear() + + def normalize_hl_line(self, number): + """ + Normalize highlight line number. + + Clamp outrages numbers. Numbers out of range will be only one increment out range. + This prevents people from create massive buffers of line numbers that exceed real + number of code lines. + """ + + number = int(number) + if number < 1: + number = 0 + elif number > self.line_count: + number = self.line_count + 1 + return number + + def parse_hl_lines(self, hl_lines): + """Parse the lines to highlight.""" + + lines = [] + if hl_lines: + for entry in hl_lines.split(): + line_range = [self.normalize_hl_line(e) for e in entry.split('-')] + if len(line_range) > 1: + if line_range[0] <= line_range[1]: + lines.extend(list(range(line_range[0], line_range[1] + 1))) + elif 1 <= line_range[0] <= self.line_count: + lines.extend(line_range) + return lines + + def parse_line_start(self, linestart): + """Parse line start.""" + + return int(linestart) if linestart else -1 + + def parse_line_step(self, linestep): + """Parse line start.""" + + step = int(linestep) if linestep else -1 + + return step if step > 1 else -1 + + def parse_line_special(self, linespecial): + """Parse line start.""" + + return int(linespecial) if linespecial else -1 + + def parse_fence_line(self, line): + """Parse fence line.""" + + ws_len = 0 + ws_virtual_len = 0 + ws = [] + index = 0 + for c in line: + if ws_virtual_len >= self.ws_virtual_len: + break + if c not in PREFIX_CHARS: + break + ws_len += 1 + if c == '\t': + tab_size = self.tab_len - (index % self.tab_len) + ws_virtual_len += tab_size + ws.append(' ' * tab_size) + else: + tab_size = 1 + ws_virtual_len += 1 + ws.append(c) + index += tab_size + + return ''.join(ws), line[ws_len:] + + def parse_whitespace(self, line): + """Parse the whitespace (blockquote syntax is counted as well).""" + + self.ws_len = 0 + self.ws_virtual_len = 0 + ws = [] + for c in line: + if c not in PREFIX_CHARS: + break + self.ws_len += 1 + ws.append(c) + + ws = self.normalize_ws(''.join(ws)) + self.ws_virtual_len = len(ws) + + return ws + + def parse_options(self, m): + """Get options.""" + + okay = False + + if m.group('lang'): + self.lang = m.group('lang') + + string = m.group('options') + + self.options = {} + self.attrs = {} + self.formatter = None + values = {} + if string: + for m2 in RE_OPTIONS.finditer(string): + key = m2.group('key') + value = m2.group('value') + if value is None: + value = key + values[key] = value + + # Run per language validator + for entry in reversed(self.extension.superfences): + if entry["test"](self.lang): + options = {} + attrs = {} + validator = entry.get("validator", functools.partial(_validator, validator=default_validator)) + try: + okay = validator(self.lang, values, options, attrs, self.md) + except SuperFencesException: + raise + except Exception: + pass + if attrs: + okay = False + if okay: + self.formatter = entry.get("formatter") + self.options = options + break + + if not okay and self.relaxed_headers: + return self.handle_unrecognized(m) + + return okay + + def handle_unrecognized(self, m): + """Handle unrecognized code headers.""" + + okay = False + if not self.relaxed_headers: + return okay + + if m.group('lang'): + self.lang = m.group('lang') + + self.options = {} + self.attrs = {} + self.formatter = None + + # Run per language validator + for entry in reversed(self.extension.superfences): + if entry["test"](self.lang): + options = {} + attrs = {} + validator = entry.get("validator", functools.partial(_validator, validator=default_validator)) + try: + okay = validator(self.lang, {}, options, attrs, self.md) + except SuperFencesException: + raise + except Exception: + pass + if okay: + self.formatter = entry.get("formatter") + self.options = options + if self.attr_list: + self.attrs = attrs + break + + if not okay: + self.lang = None # pragma: no cover + return True + + def handle_attrs(self, m): + """Handle attribute list.""" + + okay = False + attributes = get_attrs(m.group('attrs').replace('\t', ' ' * self.tab_len)) + + self.options = {} + self.attrs = {} + self.formatter = None + values = {} + for k, v in attributes: + if k == 'id': + self.id = v + elif k == '.': + self.classes.append(v) + else: + values[k] = v + + if m.group('lang'): + self.lang = m.group('lang') + else: + self.lang = self.classes.pop(0) if self.classes else '' + + # Run per language validator + for entry in reversed(self.extension.superfences): + if entry["test"](self.lang): + options = {} + attrs = {} + validator = entry.get("validator", functools.partial(_validator, validator=default_validator)) + try: + okay = validator(self.lang, values, options, attrs, self.md) + except SuperFencesException: + raise + except Exception: + pass + if okay: + self.formatter = entry.get("formatter") + self.options = options + if self.attr_list: + self.attrs = attrs + break + + if not okay and self.relaxed_headers: + return self.handle_unrecognized(m) # pragma: no cover + + return okay + + def search_nested(self, lines): + """Search for nested fenced blocks.""" + + count = 0 + for line in lines: + # Strip carriage returns if the lines end with them. + # This is necessary since we are handling preserved tabs + # Before whitespace normalization. + line = line.rstrip('\r') + if self.fence is None: + ws = self.parse_whitespace(line) + + # Found the start of a fenced block. + m = RE_NESTED_FENCE_START.match(line, self.ws_len) + if m is not None: + + # Parse options + if m.group('unrecognized'): + okay = self.handle_unrecognized(m) + elif m.group('attrs'): + okay = self.handle_attrs(m) + else: + okay = self.parse_options(m) + + if okay: + # Valid fence options, handle fence + start = count + self.first = ws + self.normalize_ws(m.group(0)) + self.ws = ws + self.quote_level = self.ws.count(">") + self.empty_lines = 0 + self.fence = m.group('fence') + self.fence_end = re.compile(NESTED_FENCE_END % self.fence) + else: + # Option parsing failed, abandon fence + self.clear() + else: + # Evaluate lines + # - Determine if it is the ending line or content line + # - If is a content line, make sure it is all indented + # with the opening and closing lines (lines with just + # whitespace will be stripped so those don't matter). + # - When content lines are inside blockquotes, make sure + # the nested block quote levels make sense according to + # blockquote rules. + ws, content = self.parse_fence_line(line) + + end = count + 1 + quote_level = ws.count(">") + + if self.quote_level: + # Handle blockquotes + self.eval_quoted(ws, content, quote_level, start, end) + elif quote_level == 0: + # Handle all other cases + self.eval_fence(ws, content, start, end) + else: + # Looks like we got a blockquote line + # when not in a blockquote. + self.clear() + + count += 1 + + return self.reassemble(lines) + + def reassemble(self, lines): + """Reassemble text.""" + + # Now that we are done iterating the lines, + # let's replace the original content with the + # fenced blocks. + while len(self.stack): + fenced, start, end = self.stack.pop() + lines = lines[:start] + [fenced] + lines[end:] + return lines + + def highlight(self, src="", language="", options=None, md=None, **kwargs): + """ + Syntax highlight the code block. + + If configuration is not empty, then the CodeHilite extension + is enabled, so we call into it to highlight the code. + """ + + classes = kwargs['classes'] + id_value = kwargs['id_value'] + attrs = kwargs['attrs'] + + if classes is None: # pragma: no cover + classes = [] + + # Default format options + linestep = None + linestart = None + linespecial = None + hl_lines = None + title = None + + if self.use_pygments: + if 'hl_lines' in options: + m = RE_HL_LINES.match(options['hl_lines']) + hl_lines = m.group('hl_lines') + del options['hl_lines'] + if 'linenums' in options: + m = RE_LINENUMS.match(options['linenums']) + linestart = m.group('linestart') + linestep = m.group('linestep') + linespecial = m.group('linespecial') + del options['linenums'] + if 'title' in options: + title = options['title'] + del options['title'] + + linestep = self.parse_line_step(linestep) + linestart = self.parse_line_start(linestart) + linespecial = self.parse_line_special(linespecial) + hl_lines = self.parse_hl_lines(hl_lines) + + self.highlight_ext.pygments_code_block += 1 + + el = self.highlighter( + guess_lang=self.guess_lang, + pygments_style=self.pygments_style, + use_pygments=self.use_pygments, + noclasses=self.noclasses, + linenums=self.linenums, + linenums_style=self.linenums_style, + linenums_special=self.linenums_special, + linenums_class=self.linenums_class, + extend_pygments_lang=self.extend_pygments_lang, + language_prefix=self.language_prefix, + code_attr_on_pre=self.code_attr_on_pre, + auto_title=self.auto_title, + auto_title_map=self.auto_title_map, + line_spans=self.line_spans, + line_anchors=self.line_anchors, + anchor_linenums=self.anchor_linenums, + pygments_lang_class=self.pygments_lang_class, + stripnl=self.stripnl, + default_lang=self.default_lang + ).highlight( + src, + language, + self.css_class, + hl_lines=hl_lines, + linestart=linestart, + linestep=linestep, + linespecial=linespecial, + classes=classes, + id_value=id_value, + attrs=attrs, + title=title, + code_block_count=self.highlight_ext.pygments_code_block + ) + + return el + + def _store(self, source, code, start, end): + """ + Store the fenced blocks in the stack to be replaced when done iterating. + + Store the original text in case we need to restore if we are too greedy. + """ + # Save the fenced blocks to add once we are done iterating the lines + placeholder = self.md.htmlStash.store(code) + self.stack.append(('{}{}'.format(self.ws, placeholder), start, end)) + if not self.disabled_indented: + # If an indented block consumes this placeholder, + # we can restore the original source + self.extension.stash.store( + placeholder[1:-1], + "{}\n{}{}".format(self.first, self.normalize_ws(source), self.last), + self.ws_virtual_len + ) + + def reindent(self, text, pos, level): + """Reindent the code to where it is supposed to be.""" + + indented = [] + for line in text.split('\n'): + index = pos - level + indented.append(line[index:]) + return indented + + def restore_raw_text(self, lines): + """Revert a prematurely converted fenced block.""" + + new_lines = [] + for line in lines: + m = FENCED_BLOCK_RE.match(line) + if m: + key = m.group(2) + indent_level = len(m.group(1)) + original = None + original, pos = self.extension.stash.get(key, (None, None)) + if original is not None: + code = self.reindent(original, pos, indent_level) + new_lines.extend(code) + self.extension.stash.remove(key) + if original is None: # pragma: no cover + # Too much work to test this. This is just a fall back in case + # we find a placeholder, and we went to revert it and it wasn't in our stash. + # Most likely this would be caused by someone else. We just want to put it + # back in the block if we can't revert it. Maybe we can do a more directed + # unit test in the future. + new_lines.append(line) + else: + new_lines.append(line) + return new_lines + + def run(self, lines): + """Search for fenced blocks.""" + + self.get_hl_settings() + self.clear() + self.stack = [] + self.disabled_indented = self.config.get("disable_indented_code_blocks", False) + self.preserve_tabs = self.config.get("preserve_tabs", False) + + if self.preserve_tabs: + lines = self.restore_raw_text(lines) + return self.search_nested(lines) + + +class SuperFencesRawBlockPreprocessor(SuperFencesBlockPreprocessor): + """Special class for preserving tabs before normalizing whitespace.""" + + def process_nested_block(self, ws, content, start, end): + """Process the contents of the nested block.""" + + self.last = ws + self.normalize_ws(content) + code = '\n'.join(self.code) + self._store(code + '\n', code, start, end) + self.clear() + + def _store(self, source, code, start, end): + """ + Store the fenced blocks in the stack to be replaced when done iterating. + + Store the original text in case we need to restore if we are too greedy. + """ + # Just get a placeholder, we won't ever actually retrieve this source + placeholder = self.md.htmlStash.store('') + self.stack.append(('{}{}'.format(self.ws, placeholder), start, end)) + # Here is the source we'll actually retrieve. + self.extension.stash.store( + placeholder[1:-1], + "{}\n{}{}".format(self.first, source, self.last), + self.ws_virtual_len + ) + + def reassemble(self, lines): + """Reassemble text.""" + + # Now that we are done iterating the lines, + # let's replace the original content with the + # fenced blocks. + while len(self.stack): + fenced, start, end = self.stack.pop() + lines = lines[:start] + [fenced.replace(md_util.STX, SOH, 1)[:-1] + EOT] + lines[end:] + return lines + + def run(self, lines): + """Search for fenced blocks.""" + + self.get_hl_settings() + self.clear() + self.stack = [] + self.disabled_indented = self.config.get("disable_indented_code_blocks", False) + return self.search_nested(lines) + + +class SuperFencesCodeBlockProcessor(CodeBlockProcessor): + """Process indented code blocks to see if we accidentally processed its content as a fenced block.""" + + def test(self, parent, block): + """Test method that is one day to be deprecated.""" + + return True + + def reindent(self, text, pos, level): + """Reindent the code to where it is supposed to be.""" + + indented = [] + for line in text.split('\n'): + index = pos - level + indented.append(line[index:]) + return '\n'.join(indented) + + def revert_greedy_fences(self, block): + """Revert a prematurely converted fenced block.""" + + new_block = [] + for line in block.split('\n'): + m = FENCED_BLOCK_RE.match(line) + if m: + key = m.group(2) + indent_level = len(m.group(1)) + original = None + original, pos = self.extension.stash.get(key, (None, None)) + if original is not None: + code = self.reindent(original, pos, indent_level) + new_block.append(code) + self.extension.stash.remove(key) + if original is None: # pragma: no cover + # Too much work to test this. This is just a fall back in case + # we find a placeholder, and we went to revert it and it wasn't in our stash. + # Most likely this would be caused by someone else. We just want to put it + # back in the block if we can't revert it. Maybe we can do a more directed + # unit test in the future. + new_block.append(line) + else: + new_block.append(line) + return '\n'.join(new_block) + + def run(self, parent, blocks): + """Look for and parse code block.""" + + handled = False + + if not self.config.get("disable_indented_code_blocks", False): + handled = CodeBlockProcessor.test(self, parent, blocks[0]) + if handled: + if self.config.get("nested", True): + blocks[0] = self.revert_greedy_fences(blocks[0]) + handled = CodeBlockProcessor.run(self, parent, blocks) is not False + return handled + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return SuperFencesCodeExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/tabbed.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/tabbed.py new file mode 100644 index 0000000000000000000000000000000000000000..858fbf3da63a530ebcbea20367e07197b99e828a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/tabbed.py @@ -0,0 +1,427 @@ +""" +Tabbed. + +pymdownx.tabbed + +MIT license. + +Copyright (c) 2017 Isaac Muse <isaacmuse@gmail.com> + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, +and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +""" +from markdown import Extension +from markdown.blockprocessors import BlockProcessor +from markdown.treeprocessors import Treeprocessor +from markdown.extensions import toc +import xml.etree.ElementTree as etree +import re +import html + +HEADERS = {'h1', 'h2', 'h3', 'h4', 'h5', 'h6'} + + +class TabbedProcessor(BlockProcessor): + """Tabbed block processor.""" + + START = re.compile( + r'(?:^|\n)={3}(\+|\+!|!\+|!)? +"(.*?)" *(?:\n|$)' + ) + COMPRESS_SPACES = re.compile(r' {2,}') + + def __init__(self, parser, config): + """Initialize.""" + + super().__init__(parser) + self.tab_group_count = 0 + self.current_sibling = None + self.content_indention = 0 + self.alternate_style = config['alternate_style'] + self.slugify = callable(config['slugify']) + + def detab_by_length(self, text, length): + """Remove a tab from the front of each line of the given text.""" + + newtext = [] + lines = text.split('\n') + for line in lines: + if line.startswith(' ' * length): + newtext.append(line[length:]) + elif not line.strip(): + newtext.append('') # pragma: no cover + else: + break + return '\n'.join(newtext), '\n'.join(lines[len(newtext):]) + + def parse_content(self, parent, block): + """ + Get sibling tab. + + Retrieve the appropriate sibling element. This can get tricky when + dealing with lists. + + """ + + old_block = block + non_tabs = '' + tabbed_set = 'tabbed-set' if not self.alternate_style else 'tabbed-set tabbed-alternate' + + # We already acquired the block via test + if self.current_sibling is not None: + sibling = self.current_sibling + block, non_tabs = self.detab_by_length(block, self.content_indent) + self.current_sibling = None + self.content_indent = 0 + return sibling, block, non_tabs + + sibling = self.lastChild(parent) + + if sibling is None or sibling.tag.lower() != 'div' or sibling.attrib.get('class', '') != tabbed_set: + sibling = None + else: + # If the last child is a list and the content is indented sufficient + # to be under it, then the content's is sibling is in the list. + if self.alternate_style: + last_child = self.lastChild(self.lastChild(sibling)) + tabbed_content = 'tabbed-block' + else: + last_child = self.lastChild(sibling) + tabbed_content = 'tabbed-content' + child_class = last_child.attrib.get('class', '') if last_child is not None else '' + indent = 0 + while last_child is not None: + if ( + sibling is not None and block.startswith(' ' * self.tab_length * 2) and + last_child is not None and ( + last_child.tag in ('ul', 'ol', 'dl') or + ( + last_child.tag == 'div' and + child_class == tabbed_content + ) + ) + ): + + # Handle nested tabbed content + if last_child.tag == 'div' and child_class == tabbed_content: + temp_child = self.lastChild(last_child) + if temp_child is None or temp_child.tag not in ('ul', 'ol', 'dl'): + break + last_child = temp_child + child_class = last_child.attrib.get('class', '') if last_child is not None else '' + + # The expectation is that we'll find an `<li>`. + # We should get it's last child as well. + sibling = self.lastChild(last_child) + last_child = self.lastChild(sibling) if sibling is not None else None + child_class = last_child.attrib.get('class', '') if last_child is not None else '' + + # Context has been lost at this point, so we must adjust the + # text's indentation level so it will be evaluated correctly + # under the list. + block = block[self.tab_length:] + indent += self.tab_length + else: + last_child = None + + if not block.startswith(' ' * self.tab_length): + sibling = None + + if sibling is not None: + indent += self.tab_length + block, non_tabs = self.detab_by_length(old_block, indent) + self.current_sibling = sibling + self.content_indent = indent + + return sibling, block, non_tabs + + def test(self, parent, block): + """Test block.""" + + if self.START.search(block): + return True + else: + return self.parse_content(parent, block)[0] is not None + + def run(self, parent, blocks): + """Convert to tabbed block.""" + + block = blocks.pop(0) + m = self.START.search(block) + tabbed_set = 'tabbed-set' if not self.alternate_style else 'tabbed-set tabbed-alternate' + + if m: + # removes the first line + if m.start() > 0: + self.parser.parseBlocks(parent, [block[:m.start()]]) + block = block[m.end():] + sibling = self.lastChild(parent) + block, non_tabs = self.detab(block) + else: + sibling, block, non_tabs = self.parse_content(parent, block) + + if m: + special = m.group(1) if m.group(1) else '' + title = m.group(2) if m.group(2) else m.group(3) + index = 0 + labels = None + content = None + + if ( + sibling is not None and sibling.tag.lower() == 'div' and + sibling.attrib.get('class', '') == tabbed_set and + '!' not in special + ): + first = False + tab_group = sibling + if self.alternate_style: + index = [index for index, _ in enumerate(tab_group.findall('input'), 1)][-1] + for d in tab_group.findall('div'): + if d.attrib['class'] == 'tabbed-labels': + labels = d + elif d.attrib['class'] == 'tabbed-content': + content = d + if labels is not None and content is not None: + break + else: + first = True + self.tab_group_count += 1 + tab_group = etree.SubElement( + parent, + 'div', + {'class': tabbed_set, 'data-tabs': '%d:0' % self.tab_group_count} + ) + if self.alternate_style: + labels = etree.SubElement( + tab_group, + 'div', + {'class': 'tabbed-labels'} + ) + content = etree.SubElement( + tab_group, + 'div', + {'class': 'tabbed-content'} + ) + + data = tab_group.attrib['data-tabs'].split(':') + tab_set = int(data[0]) + tab_count = int(data[1]) + 1 + + attributes = { + "name": "__tabbed_%d" % tab_set, + "type": "radio" + } + + if not self.slugify: + attributes['id'] = "__tabbed_%d_%d" % (tab_set, tab_count) + + if first or '+' in special: + attributes['checked'] = 'checked' + # Remove any previously assigned "checked states" to siblings + for i in tab_group.findall('input'): + if i.attrib.get('name', '') == f'__tabbed_{tab_set}': + if 'checked' in i.attrib: + del i.attrib['checked'] + + attributes2 = {"for": "__tabbed_%d_%d" % (tab_set, tab_count)} if not self.slugify else {} + + if self.alternate_style: + input_el = etree.Element( + 'input', + attributes + ) + tab_group.insert(index, input_el) + lab = etree.SubElement( + labels, + "label", + attributes2 + ) + lab.text = title + + div = etree.SubElement( + content, + "div", + {'class': 'tabbed-block'} + ) + else: + etree.SubElement( + tab_group, + 'input', + attributes + ) + lab = etree.SubElement( + tab_group, + "label", + attributes2 + ) + lab.text = title + + div = etree.SubElement( + tab_group, + "div", + { + "class": "tabbed-content" + } + ) + + tab_group.attrib['data-tabs'] = '%d:%d' % (tab_set, tab_count) + else: + if sibling.tag in ('li', 'dd') and sibling.text: + # Sibling is a list item, but we need to wrap it's content should be wrapped in <p> + text = sibling.text + sibling.text = '' + p = etree.SubElement(sibling, 'p') + p.text = text + div = sibling + elif sibling.tag == 'div' and sibling.attrib.get('class', '') == tabbed_set: + # Get `tabbed-content` under `tabbed-set` + if self.alternate_style: + div = self.lastChild(self.lastChild(sibling)) + else: + div = self.lastChild(sibling) + else: + # Pass anything else as the parent + div = sibling + + self.parser.parseChunk(div, block) + + if non_tabs: + # Insert the tabbed content back into blocks + blocks.insert(0, non_tabs) + + +class TabbedTreeprocessor(Treeprocessor): + """Tab tree processor.""" + + def __init__(self, md, config): + """Initialize.""" + + super().__init__(md) + + self.slugify = config["slugify"] + self.alternate = config["alternate_style"] + self.sep = config["separator"] + self.combine_header_slug = config["combine_header_slug"] + + def get_parent_header_slug(self, root, header_map, parent_map, el): + """Attempt retrieval of parent header slug.""" + + parent = el + last_parent = parent + while parent is not root: + last_parent = parent + parent = parent_map[parent] + if parent in header_map: + headers = header_map[parent] + header = None + for i in list(parent): + if i is el and header is None: + break + if i is last_parent and header is not None: + return header.attrib.get("id", '') + if i in headers: + header = i + return '' + + def run(self, doc): + """Update tab IDs.""" + + # Get a list of id attributes + used_ids = set() + parent_map = {} + header_map = {} + + if self.combine_header_slug: + parent_map = {c: p for p in doc.iter() for c in p} + + for el in doc.iter(): + if "id" in el.attrib: + if self.combine_header_slug and el.tag in HEADERS: + parent = parent_map[el] + if parent in header_map: + header_map[parent].append(el) + else: + header_map[parent] = [el] + used_ids.add(el.attrib["id"]) + + for el in doc.iter(): + if isinstance(el.tag, str) and el.tag.lower() == 'div': + classes = el.attrib.get('class', '').split() + if 'tabbed-set' in classes and (not self.alternate or 'tabbed-alternate' in classes): + inputs = [] + labels = [] + if self.alternate: + for i in list(el): + if i.tag == 'input': + inputs.append(i) + if i.tag == 'div' and i.attrib.get('class', '') == 'tabbed-labels': + labels = [j for j in list(i) if j.tag == 'label'] + else: + for i in list(el): + if i.tag == 'input': + inputs.append(i) + if i.tag == 'label': + labels.append(i) + + # Generate slugged IDs + for inpt, label in zip(inputs, labels): + innerhtml = toc.render_inner_html(toc.remove_fnrefs(label), self.md) + innertext = html.unescape(toc.strip_tags(innerhtml)) + if self.combine_header_slug: + parent_slug = self.get_parent_header_slug(doc, header_map, parent_map, el) + else: + parent_slug = '' + slug = self.slugify(innertext, self.sep) + if parent_slug: + slug = parent_slug + self.sep + slug + slug = toc.unique(slug, used_ids) + inpt.attrib["id"] = slug + label.attrib["for"] = slug + + +class TabbedExtension(Extension): + """Add Tabbed extension.""" + + def __init__(self, *args, **kwargs): + """Initialize.""" + + self.config = { + 'alternate_style': [False, "Use alternate style - Default: False"], + 'slugify': [0, "Slugify function used to create tab specific IDs - Default: None"], + 'combine_header_slug': [False, "Combine the tab slug with the slug of the parent header - Default: False"], + 'separator': ['-', "Slug separator - Default: '-'"] + } + + super().__init__(*args, **kwargs) + + def extendMarkdown(self, md): + """Add Tabbed to Markdown instance.""" + md.registerExtension(self) + + config = self.getConfigs() + self.tab_processor = TabbedProcessor(md.parser, config) + md.parser.blockprocessors.register(self.tab_processor, "tabbed", 105) + if config['slugify']: + slugs = TabbedTreeprocessor(md, config) + md.treeprocessors.register(slugs, 'tab_slugs', 4) + + def reset(self): + """Reset.""" + + self.tab_processor.tab_group_count = 0 + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return TabbedExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/tasklist.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/tasklist.py new file mode 100644 index 0000000000000000000000000000000000000000..cd7cd95c6cc118c37a510e3148f83aab1d2e0e71 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/tasklist.py @@ -0,0 +1,149 @@ +""" +Tasklist. + +pymdownx.tasklist +An extension for Python Markdown. +Github style tasklists + +MIT license. + +Copyright (c) 2014 - 2017 Isaac Muse <isaacmuse@gmail.com> + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, +and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +""" +from markdown import Extension +from markdown.treeprocessors import Treeprocessor +import re + +RE_CHECKBOX = re.compile(r"^(?P<checkbox> *\[(?P<state>(?:x|X| ){1})\] +)(?P<line>.*)", re.DOTALL) + + +def get_checkbox(state, custom_checkbox=False, clickable_checkbox=False): + """Get checkbox tag.""" + + if custom_checkbox: + return ( + '<label class="task-list-control">' + + '<input type="checkbox"{}{}/>'.format( + ' disabled' if not clickable_checkbox else '', + ' checked' if state.lower() == 'x' else '') + + '<span class="task-list-indicator"></span></label> ' + ) + return '<input type="checkbox"{}{}/> '.format( + ' disabled' if not clickable_checkbox else '', + ' checked' if state.lower() == 'x' else '') + + +class TasklistTreeprocessor(Treeprocessor): + """Tasklist tree processor that finds lists with checkboxes.""" + + def __init__(self, md): + """Initialize.""" + + super().__init__(md) + + def inline(self, li): + """Search for checkbox directly in `li` tag.""" + + found = False + m = RE_CHECKBOX.match(li.text) + if m is not None: + li.text = self.md.htmlStash.store( + get_checkbox(m.group('state'), self.custom_checkbox, self.clickable_checkbox) + ) + m.group('line') + found = True + return found + + def sub_paragraph(self, li): + """Search for checkbox in sub-paragraph.""" + + found = False + if len(li): + first = next(iter(li)) + if first.tag == "p" and first.text is not None: + m = RE_CHECKBOX.match(first.text) + if m is not None: + first.text = self.md.htmlStash.store( + get_checkbox(m.group('state'), self.custom_checkbox, self.clickable_checkbox) + ) + m.group('line') + found = True + return found + + def run(self, root): + """Find list items that start with [ ] or [x] or [X].""" + + self.custom_checkbox = bool(self.config["custom_checkbox"]) + self.clickable_checkbox = bool(self.config["clickable_checkbox"]) + parent_map = {c: p for p in root.iter() for c in p} + task_items = [] + lilinks = root.iter('li') + for li in lilinks: + if li.text is None or li.text == "": + if not self.sub_paragraph(li): + continue + elif not self.inline(li): + continue + + # Checkbox found + c = li.attrib.get("class", "") + classes = [] if c == "" else c.split() + classes.append("task-list-item") + li.attrib["class"] = ' '.join(classes) + task_items.append(li) + + for li in task_items: + parent = parent_map[li] + c = parent.attrib.get("class", "") + classes = [] if c == "" else c.split() + if "task-list" not in classes: + classes.append("task-list") + parent.attrib["class"] = ' '.join(classes) + return root + + +class TasklistExtension(Extension): + """Tasklist extension.""" + + def __init__(self, *args, **kwargs): + """Initialize.""" + + self.config = { + 'custom_checkbox': [ + False, + "Add an empty label tag after the input tag to allow for custom styling - Default: False" + ], + 'clickable_checkbox': [ + False, + "Allow user to check/uncheck the checkbox - Default: False" + ], + 'delete': [True, "Enable delete - Default: True"], + 'subscript': [True, "Enable subscript - Default: True"] + } + + super().__init__(*args, **kwargs) + + def extendMarkdown(self, md): + """Add checklist tree processor to Markdown instance.""" + + tasklist = TasklistTreeprocessor(md) + tasklist.config = self.getConfigs() + md.treeprocessors.register(tasklist, "task-list", 25) + md.registerExtension(self) + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return TasklistExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/tilde.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/tilde.py new file mode 100644 index 0000000000000000000000000000000000000000..e58c1f6a7ccc72240d68d70b8dc5fcff70ae8032 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/tilde.py @@ -0,0 +1,185 @@ +""" +Tilde. + +pymdownx.tilde +Really simple plugin to add support for +`<del>test</del>` tags as `~~test~~` and +`<sub>test</sub>` tags as `~test~` + +MIT license. + +Copyright (c) 2014 - 2017 Isaac Muse <isaacmuse@gmail.com> + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, +and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +""" +import re +from markdown import Extension +from markdown.inlinepatterns import SimpleTextInlineProcessor +from . import util + +SMART_CONTENT = r'(.+?~*?)' +SMART_LIMITED_CONTENT = r'((?:[^~]|(?<=\w)~+?(?=\w)|(?<=\s)~+?(?=\s))+?)' +CONTENT = r'(~|[^\s]+?)' +CONTENT2 = r'((?:[^~]|(?<!~{2})~)+?)' + +# Avoid starting a pattern with tilde tokens that are surrounded by white space. +NOT_TILDE = r'((^|(?<=\s))(~+)(?=\s|$))' + +# `~~~del,sub~~~` +DEL_SUB = r'(~{3})(?!\s)(~{1,2}|[^~\s]+?)(?<!\s)\1' +# `~~~del,sub~del~~` +DEL_SUB2 = r'(~{{3}})(?![\s~]){}(?<!\s)~{}(?<!\s)~{{2}}'.format(CONTENT, CONTENT2) +# `~~~sub,del~~sub~` +SUB_DEL = r'(~{{3}})(?![\s~]){}(?<!\s)~{{2}}{}(?<!\s)~'.format(CONTENT, CONTENT) +# `~~del~sub,del~~~` +DEL_SUB3 = r'(~{{2}})(?![\s~]){}~(?![\s~]){}(?<!\s)~{{3}}'.format(CONTENT2, CONTENT) +# `~~del~~` +DEL = r'(~{{2}})(?!\s){}(?<!\s)\1'.format(CONTENT2) +# `~sub~` +SUB = r'(~)(?!\s){}(?<!\s)\1'.format(CONTENT) +# `~sub ~~sub,del~~~` +SUB_DEL2 = r'(?<!~)(~)(?![~\s]){}~{{2}}{}~{{3}}'.format(CONTENT, CONTENT) +# Prioritize ~value~ when ~~value~~ is nested within +SUB2 = r'(?<!~)(~)(?![~\s])((?:[^\s~]|~{2,})+?)(?<![~\s])(~)(?!~)' + +# Smart rules for when "smart tilde" is enabled +# SMART: `~~~del,sub~~~` +SMART_DEL_SUB = r'(~{{3}})(?![\s~]){}(?<!\s)\1'.format(CONTENT) +# SMART: `~~~del,sub~ del~~` +SMART_DEL_SUB2 = \ + r'(~{{3}})(?![\s~]){}(?<!\s)~(?:(?=_)|(?![\w~])){}(?<!\s)~{{2}}'.format( + CONTENT, SMART_LIMITED_CONTENT + ) +# SMART: `~~~sub,del~~ sub~` +SMART_SUB_DEL = \ + r'(~{{3}})(?![\s~]){}(?<!\s)~{{2}}(?:(?=_)|(?![\w~])){}(?<!\s)~'.format( + CONTENT, CONTENT + ) +# SMART: `~~del~~` +SMART_DEL = r'(?:(?<=_)|(?<![\w~]))(~{{2}})(?![\s~]){}(?<!\s)\1(?:(?=_)|(?![\w~]))'.format(SMART_CONTENT) +# SMART: `~sub ~~sub,del~~~` +SMART_SUB_DEL2 = \ + r'(?<!~)(~)(?![\s~]){}(?:(?<=_)|(?<![\w~]))~{{2}}(?![\s~]){}(?<!\s)~{{3}}'.format( + CONTENT, CONTENT + ) +# SMART: `~sub ~~sub,del~~~` +SMART_DEL_SUB3 = \ + r'(?<!~)(~{{2}})(?![\s~]){}(?:(?<=_)|(?<![\w~]))~(?![\s~]){}(?<!\s)~{{3}}'.format( + SMART_LIMITED_CONTENT, CONTENT + ) + + +class TildeProcessor(util.PatternSequenceProcessor): + """Emphasis processor for handling delete and subscript matches.""" + + PATTERNS = [ + util.PatSeqItem(re.compile(DEL_SUB, re.DOTALL | re.UNICODE), 'double', 'del,sub'), + util.PatSeqItem(re.compile(SUB_DEL, re.DOTALL | re.UNICODE), 'double', 'sub,del'), + util.PatSeqItem(re.compile(DEL_SUB2, re.DOTALL | re.UNICODE), 'double', 'del,sub'), + util.PatSeqItem(re.compile(DEL_SUB3, re.DOTALL | re.UNICODE), 'double2', 'del,sub'), + util.PatSeqItem(re.compile(DEL, re.DOTALL | re.UNICODE), 'single', 'del'), + util.PatSeqItem(re.compile(SUB_DEL2, re.DOTALL | re.UNICODE), 'double2', 'sub,del'), + util.PatSeqItem(re.compile(SUB2, re.DOTALL | re.UNICODE), 'single', 'sub', True), + util.PatSeqItem(re.compile(SUB, re.DOTALL | re.UNICODE), 'single', 'sub') + ] + + +class TildeSmartProcessor(util.PatternSequenceProcessor): + """Smart delete and subscript processor.""" + + PATTERNS = [ + util.PatSeqItem(re.compile(SMART_DEL_SUB, re.DOTALL | re.UNICODE), 'double', 'del,sub'), + util.PatSeqItem(re.compile(SMART_SUB_DEL, re.DOTALL | re.UNICODE), 'double', 'sub,del'), + util.PatSeqItem(re.compile(SMART_DEL_SUB2, re.DOTALL | re.UNICODE), 'double', 'del,sub'), + util.PatSeqItem(re.compile(SMART_DEL_SUB3, re.DOTALL | re.UNICODE), 'double2', 'del,sub'), + util.PatSeqItem(re.compile(SMART_DEL, re.DOTALL | re.UNICODE), 'single', 'del'), + util.PatSeqItem(re.compile(SMART_SUB_DEL2, re.DOTALL | re.UNICODE), 'double2', 'sub,del'), + util.PatSeqItem(re.compile(SUB2, re.DOTALL | re.UNICODE), 'single', 'sub', True), + util.PatSeqItem(re.compile(SUB, re.DOTALL | re.UNICODE), 'single', 'sub') + ] + + +class TildeSubProcessor(util.PatternSequenceProcessor): + """Just subscript processor.""" + + PATTERNS = [ + util.PatSeqItem(re.compile(SUB, re.DOTALL | re.UNICODE), 'single', 'sub') + ] + + +class TildeDeleteProcessor(util.PatternSequenceProcessor): + """Just delete processor.""" + + PATTERNS = [ + util.PatSeqItem(re.compile(DEL, re.DOTALL | re.UNICODE), 'single', 'del') + ] + + +class TildeSmartDeleteProcessor(util.PatternSequenceProcessor): + """Just smart delete processor.""" + + PATTERNS = [ + util.PatSeqItem(re.compile(SMART_DEL, re.DOTALL | re.UNICODE), 'single', 'del') + ] + + +class DeleteSubExtension(Extension): + """Add delete and/or subscript extension to Markdown class.""" + + def __init__(self, *args, **kwargs): + """Initialize.""" + + self.config = { + 'smart_delete': [True, "Treat ~~connected~~words~~ intelligently - Default: True"], + 'delete': [True, "Enable delete - Default: True"], + 'subscript': [True, "Enable subscript - Default: True"] + } + + super().__init__(*args, **kwargs) + + def extendMarkdown(self, md): + """Insert `<del>test</del>` tags as `~~test~~` and `<sub>test</sub>` tags as `~test~`.""" + + config = self.getConfigs() + delete = bool(config.get('delete', True)) + subscript = bool(config.get('subscript', True)) + smart = bool(config.get('smart_delete', True)) + + md.registerExtension(self) + + escape_chars = [] + if delete or subscript: + escape_chars.append('~') + if subscript: + escape_chars.append(' ') + util.escape_chars(md, escape_chars) + + tilde = None + md.inlinePatterns.register(SimpleTextInlineProcessor(NOT_TILDE), 'not_tilde', 70) + if delete and subscript: + tilde = TildeSmartProcessor(r'~') if smart else TildeProcessor(r'~') + elif delete: + tilde = TildeSmartDeleteProcessor(r'~') if smart else TildeDeleteProcessor(r'~') + elif subscript: + tilde = TildeSubProcessor(r'~') + + if tilde is not None: + md.inlinePatterns.register(tilde, "sub_del", 65) + + +def makeExtension(*args, **kwargs): + """Return extension.""" + + return DeleteSubExtension(*args, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/twemoji_db.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/twemoji_db.py new file mode 100644 index 0000000000000000000000000000000000000000..ba932da956bbc12bf8578f3300c3c56c6aea1fb9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/twemoji_db.py @@ -0,0 +1,21637 @@ +"""Twemoji autogen. + +Names from emojione database. Do not edit by hand. +""" +version = "v16.0.1" +index_version = "10.0.0" +name = "twemoji" +emoji = { + ":100:": { + "category": "symbols", + "name": "hundred points", + "unicode": "1f4af" + }, + ":1234:": { + "category": "symbols", + "name": "input numbers", + "unicode": "1f522" + }, + ":8ball:": { + "category": "activity", + "name": "pool 8 ball", + "unicode": "1f3b1" + }, + ":a:": { + "category": "symbols", + "name": "A button (blood type)", + "unicode": "1f170" + }, + ":ab:": { + "category": "symbols", + "name": "AB button (blood type)", + "unicode": "1f18e" + }, + ":abacus:": { + "category": "objects", + "name": "abacus", + "unicode": "1f9ee" + }, + ":abc:": { + "category": "symbols", + "name": "input latin letters", + "unicode": "1f524" + }, + ":abcd:": { + "category": "symbols", + "name": "input latin lowercase", + "unicode": "1f521" + }, + ":accept:": { + "category": "symbols", + "name": "Japanese \u201cacceptable\u201d button", + "unicode": "1f251" + }, + ":accordion:": { + "category": "activity", + "name": "accordion", + "unicode": "1fa97" + }, + ":adhesive_bandage:": { + "category": "objects", + "name": "adhesive bandage", + "unicode": "1fa79" + }, + ":adult:": { + "category": "people", + "name": "person", + "unicode": "1f9d1" + }, + ":adult_tone1:": { + "category": "people", + "name": "person: light skin tone", + "unicode": "1f9d1-1f3fb" + }, + ":adult_tone2:": { + "category": "people", + "name": "person: medium-light skin tone", + "unicode": "1f9d1-1f3fc" + }, + ":adult_tone3:": { + "category": "people", + "name": "person: medium skin tone", + "unicode": "1f9d1-1f3fd" + }, + ":adult_tone4:": { + "category": "people", + "name": "person: medium-dark skin tone", + "unicode": "1f9d1-1f3fe" + }, + ":adult_tone5:": { + "category": "people", + "name": "person: dark skin tone", + "unicode": "1f9d1-1f3ff" + }, + ":aerial_tramway:": { + "category": "travel", + "name": "aerial tramway", + "unicode": "1f6a1" + }, + ":airplane:": { + "category": "travel", + "name": "airplane", + "unicode": "2708" + }, + ":airplane_arriving:": { + "category": "travel", + "name": "airplane arrival", + "unicode": "1f6ec" + }, + ":airplane_departure:": { + "category": "travel", + "name": "airplane departure", + "unicode": "1f6eb" + }, + ":airplane_small:": { + "category": "travel", + "name": "small airplane", + "unicode": "1f6e9" + }, + ":alarm_clock:": { + "category": "objects", + "name": "alarm clock", + "unicode": "23f0" + }, + ":alembic:": { + "category": "objects", + "name": "alembic", + "unicode": "2697" + }, + ":alien:": { + "category": "people", + "name": "alien", + "unicode": "1f47d" + }, + ":ambulance:": { + "category": "travel", + "name": "ambulance", + "unicode": "1f691" + }, + ":amphora:": { + "category": "objects", + "name": "amphora", + "unicode": "1f3fa" + }, + ":anatomical_heart:": { + "category": "people", + "name": "anatomical heart", + "unicode": "1fac0" + }, + ":anchor:": { + "category": "travel", + "name": "anchor", + "unicode": "2693" + }, + ":angel:": { + "category": "people", + "name": "baby angel", + "unicode": "1f47c" + }, + ":angel_tone1:": { + "category": "people", + "name": "baby angel: light skin tone", + "unicode": "1f47c-1f3fb" + }, + ":angel_tone2:": { + "category": "people", + "name": "baby angel: medium-light skin tone", + "unicode": "1f47c-1f3fc" + }, + ":angel_tone3:": { + "category": "people", + "name": "baby angel: medium skin tone", + "unicode": "1f47c-1f3fd" + }, + ":angel_tone4:": { + "category": "people", + "name": "baby angel: medium-dark skin tone", + "unicode": "1f47c-1f3fe" + }, + ":angel_tone5:": { + "category": "people", + "name": "baby angel: dark skin tone", + "unicode": "1f47c-1f3ff" + }, + ":anger:": { + "category": "symbols", + "name": "anger symbol", + "unicode": "1f4a2" + }, + ":anger_right:": { + "category": "symbols", + "name": "right anger bubble", + "unicode": "1f5ef" + }, + ":angry:": { + "category": "people", + "name": "angry face", + "unicode": "1f620" + }, + ":anguished:": { + "category": "people", + "name": "anguished face", + "unicode": "1f627" + }, + ":ant:": { + "category": "nature", + "name": "ant", + "unicode": "1f41c" + }, + ":apple:": { + "category": "food", + "name": "red apple", + "unicode": "1f34e" + }, + ":aquarius:": { + "category": "symbols", + "name": "Aquarius", + "unicode": "2652" + }, + ":aries:": { + "category": "symbols", + "name": "Aries", + "unicode": "2648" + }, + ":arrow_backward:": { + "category": "symbols", + "name": "reverse button", + "unicode": "25c0" + }, + ":arrow_double_down:": { + "category": "symbols", + "name": "fast down button", + "unicode": "23ec" + }, + ":arrow_double_up:": { + "category": "symbols", + "name": "fast up button", + "unicode": "23eb" + }, + ":arrow_down:": { + "category": "symbols", + "name": "down arrow", + "unicode": "2b07" + }, + ":arrow_down_small:": { + "category": "symbols", + "name": "downwards button", + "unicode": "1f53d" + }, + ":arrow_forward:": { + "category": "symbols", + "name": "play button", + "unicode": "25b6" + }, + ":arrow_heading_down:": { + "category": "symbols", + "name": "right arrow curving down", + "unicode": "2935" + }, + ":arrow_heading_up:": { + "category": "symbols", + "name": "right arrow curving up", + "unicode": "2934" + }, + ":arrow_left:": { + "category": "symbols", + "name": "left arrow", + "unicode": "2b05" + }, + ":arrow_lower_left:": { + "category": "symbols", + "name": "down-left arrow", + "unicode": "2199" + }, + ":arrow_lower_right:": { + "category": "symbols", + "name": "down-right arrow", + "unicode": "2198" + }, + ":arrow_right:": { + "category": "symbols", + "name": "right arrow", + "unicode": "27a1" + }, + ":arrow_right_hook:": { + "category": "symbols", + "name": "left arrow curving right", + "unicode": "21aa" + }, + ":arrow_up:": { + "category": "symbols", + "name": "up arrow", + "unicode": "2b06" + }, + ":arrow_up_down:": { + "category": "symbols", + "name": "up-down arrow", + "unicode": "2195" + }, + ":arrow_up_small:": { + "category": "symbols", + "name": "upwards button", + "unicode": "1f53c" + }, + ":arrow_upper_left:": { + "category": "symbols", + "name": "up-left arrow", + "unicode": "2196" + }, + ":arrow_upper_right:": { + "category": "symbols", + "name": "up-right arrow", + "unicode": "2197" + }, + ":arrows_clockwise:": { + "category": "symbols", + "name": "clockwise vertical arrows", + "unicode": "1f503" + }, + ":arrows_counterclockwise:": { + "category": "symbols", + "name": "counterclockwise arrows button", + "unicode": "1f504" + }, + ":art:": { + "category": "activity", + "name": "artist palette", + "unicode": "1f3a8" + }, + ":articulated_lorry:": { + "category": "travel", + "name": "articulated lorry", + "unicode": "1f69b" + }, + ":artist:": { + "category": "people", + "name": "artist", + "unicode": "1f9d1-200d-1f3a8" + }, + ":artist_tone1:": { + "category": "people", + "name": "artist: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f3a8" + }, + ":artist_tone2:": { + "category": "people", + "name": "artist: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f3a8" + }, + ":artist_tone3:": { + "category": "people", + "name": "artist: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f3a8" + }, + ":artist_tone4:": { + "category": "people", + "name": "artist: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f3a8" + }, + ":artist_tone5:": { + "category": "people", + "name": "artist: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f3a8" + }, + ":asterisk:": { + "category": "symbols", + "name": "keycap: asterisk", + "unicode": "2a-20e3", + "unicode_alt": "002a-20e3" + }, + ":astonished:": { + "category": "people", + "name": "astonished face", + "unicode": "1f632" + }, + ":astronaut:": { + "category": "people", + "name": "astronaut", + "unicode": "1f9d1-200d-1f680" + }, + ":astronaut_tone1:": { + "category": "people", + "name": "astronaut: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f680" + }, + ":astronaut_tone2:": { + "category": "people", + "name": "astronaut: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f680" + }, + ":astronaut_tone3:": { + "category": "people", + "name": "astronaut: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f680" + }, + ":astronaut_tone4:": { + "category": "people", + "name": "astronaut: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f680" + }, + ":astronaut_tone5:": { + "category": "people", + "name": "astronaut: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f680" + }, + ":athletic_shoe:": { + "category": "people", + "name": "running shoe", + "unicode": "1f45f" + }, + ":atm:": { + "category": "symbols", + "name": "ATM sign", + "unicode": "1f3e7" + }, + ":atom:": { + "category": "symbols", + "name": "atom symbol", + "unicode": "269b" + }, + ":auto_rickshaw:": { + "category": "travel", + "name": "auto rickshaw", + "unicode": "1f6fa" + }, + ":avocado:": { + "category": "food", + "name": "avocado", + "unicode": "1f951" + }, + ":axe:": { + "category": "objects", + "name": "axe", + "unicode": "1fa93" + }, + ":b:": { + "category": "symbols", + "name": "B button (blood type)", + "unicode": "1f171" + }, + ":baby:": { + "category": "people", + "name": "baby", + "unicode": "1f476" + }, + ":baby_bottle:": { + "category": "food", + "name": "baby bottle", + "unicode": "1f37c" + }, + ":baby_chick:": { + "category": "nature", + "name": "baby chick", + "unicode": "1f424" + }, + ":baby_symbol:": { + "category": "symbols", + "name": "baby symbol", + "unicode": "1f6bc" + }, + ":baby_tone1:": { + "category": "people", + "name": "baby: light skin tone", + "unicode": "1f476-1f3fb" + }, + ":baby_tone2:": { + "category": "people", + "name": "baby: medium-light skin tone", + "unicode": "1f476-1f3fc" + }, + ":baby_tone3:": { + "category": "people", + "name": "baby: medium skin tone", + "unicode": "1f476-1f3fd" + }, + ":baby_tone4:": { + "category": "people", + "name": "baby: medium-dark skin tone", + "unicode": "1f476-1f3fe" + }, + ":baby_tone5:": { + "category": "people", + "name": "baby: dark skin tone", + "unicode": "1f476-1f3ff" + }, + ":back:": { + "category": "symbols", + "name": "BACK arrow", + "unicode": "1f519" + }, + ":bacon:": { + "category": "food", + "name": "bacon", + "unicode": "1f953" + }, + ":badger:": { + "category": "nature", + "name": "badger", + "unicode": "1f9a1" + }, + ":badminton:": { + "category": "activity", + "name": "badminton", + "unicode": "1f3f8" + }, + ":bagel:": { + "category": "food", + "name": "bagel", + "unicode": "1f96f" + }, + ":baggage_claim:": { + "category": "symbols", + "name": "baggage claim", + "unicode": "1f6c4" + }, + ":bald:": { + "category": "people", + "name": "bald", + "unicode": "1f9b2" + }, + ":ballet_shoes:": { + "category": "activity", + "name": "ballet shoes", + "unicode": "1fa70" + }, + ":balloon:": { + "category": "objects", + "name": "balloon", + "unicode": "1f388" + }, + ":ballot_box:": { + "category": "objects", + "name": "ballot box with ballot", + "unicode": "1f5f3" + }, + ":ballot_box_with_check:": { + "category": "symbols", + "name": "check box with check", + "unicode": "2611" + }, + ":bamboo:": { + "category": "nature", + "name": "pine decoration", + "unicode": "1f38d" + }, + ":banana:": { + "category": "food", + "name": "banana", + "unicode": "1f34c" + }, + ":bangbang:": { + "category": "symbols", + "name": "double exclamation mark", + "unicode": "203c" + }, + ":banjo:": { + "category": "activity", + "name": "banjo", + "unicode": "1fa95" + }, + ":bank:": { + "category": "travel", + "name": "bank", + "unicode": "1f3e6" + }, + ":bar_chart:": { + "category": "objects", + "name": "bar chart", + "unicode": "1f4ca" + }, + ":barber:": { + "category": "objects", + "name": "barber pole", + "unicode": "1f488" + }, + ":baseball:": { + "category": "activity", + "name": "baseball", + "unicode": "26be" + }, + ":basket:": { + "category": "objects", + "name": "basket", + "unicode": "1f9fa" + }, + ":basketball:": { + "category": "activity", + "name": "basketball", + "unicode": "1f3c0" + }, + ":bat:": { + "category": "nature", + "name": "bat", + "unicode": "1f987" + }, + ":bath:": { + "category": "objects", + "name": "person taking bath", + "unicode": "1f6c0" + }, + ":bath_tone1:": { + "category": "objects", + "name": "person taking bath: light skin tone", + "unicode": "1f6c0-1f3fb" + }, + ":bath_tone2:": { + "category": "objects", + "name": "person taking bath: medium-light skin tone", + "unicode": "1f6c0-1f3fc" + }, + ":bath_tone3:": { + "category": "objects", + "name": "person taking bath: medium skin tone", + "unicode": "1f6c0-1f3fd" + }, + ":bath_tone4:": { + "category": "objects", + "name": "person taking bath: medium-dark skin tone", + "unicode": "1f6c0-1f3fe" + }, + ":bath_tone5:": { + "category": "objects", + "name": "person taking bath: dark skin tone", + "unicode": "1f6c0-1f3ff" + }, + ":bathtub:": { + "category": "objects", + "name": "bathtub", + "unicode": "1f6c1" + }, + ":battery:": { + "category": "objects", + "name": "battery", + "unicode": "1f50b" + }, + ":beach:": { + "category": "travel", + "name": "beach with umbrella", + "unicode": "1f3d6" + }, + ":beach_umbrella:": { + "category": "travel", + "name": "umbrella on ground", + "unicode": "26f1" + }, + ":beans:": { + "category": "food", + "name": "beans", + "unicode": "1fad8" + }, + ":bear:": { + "category": "nature", + "name": "bear", + "unicode": "1f43b" + }, + ":bearded_person:": { + "category": "people", + "name": "person: beard", + "unicode": "1f9d4" + }, + ":bearded_person_tone1:": { + "category": "people", + "name": "bearded person: light skin tone", + "unicode": "1f9d4-1f3fb" + }, + ":bearded_person_tone2:": { + "category": "people", + "name": "bearded person: medium-light skin tone", + "unicode": "1f9d4-1f3fc" + }, + ":bearded_person_tone3:": { + "category": "people", + "name": "bearded person: medium skin tone", + "unicode": "1f9d4-1f3fd" + }, + ":bearded_person_tone4:": { + "category": "people", + "name": "bearded person: medium-dark skin tone", + "unicode": "1f9d4-1f3fe" + }, + ":bearded_person_tone5:": { + "category": "people", + "name": "bearded person: dark skin tone", + "unicode": "1f9d4-1f3ff" + }, + ":beaver:": { + "category": "nature", + "name": "beaver", + "unicode": "1f9ab" + }, + ":bed:": { + "category": "objects", + "name": "bed", + "unicode": "1f6cf" + }, + ":bee:": { + "category": "nature", + "name": "honeybee", + "unicode": "1f41d" + }, + ":beer:": { + "category": "food", + "name": "beer mug", + "unicode": "1f37a" + }, + ":beers:": { + "category": "food", + "name": "clinking beer mugs", + "unicode": "1f37b" + }, + ":beetle:": { + "category": "nature", + "name": "beetle", + "unicode": "1fab2" + }, + ":beginner:": { + "category": "symbols", + "name": "Japanese symbol for beginner", + "unicode": "1f530" + }, + ":bell:": { + "category": "symbols", + "name": "bell", + "unicode": "1f514" + }, + ":bell_pepper:": { + "category": "food", + "name": "bell pepper", + "unicode": "1fad1" + }, + ":bellhop:": { + "category": "objects", + "name": "bellhop bell", + "unicode": "1f6ce" + }, + ":bento:": { + "category": "food", + "name": "bento box", + "unicode": "1f371" + }, + ":beverage_box:": { + "category": "food", + "name": "beverage box", + "unicode": "1f9c3" + }, + ":bike:": { + "category": "travel", + "name": "bicycle", + "unicode": "1f6b2" + }, + ":bikini:": { + "category": "people", + "name": "bikini", + "unicode": "1f459" + }, + ":billed_cap:": { + "category": "people", + "name": "billed cap", + "unicode": "1f9e2" + }, + ":biohazard:": { + "category": "symbols", + "name": "biohazard", + "unicode": "2623" + }, + ":bird:": { + "category": "nature", + "name": "bird", + "unicode": "1f426" + }, + ":birthday:": { + "category": "food", + "name": "birthday cake", + "unicode": "1f382" + }, + ":bison:": { + "category": "nature", + "name": "bison", + "unicode": "1f9ac" + }, + ":biting_lip:": { + "category": "people", + "name": "biting lip", + "unicode": "1fae6" + }, + ":black_bird:": { + "category": "nature", + "name": "black bird", + "unicode": "1f426-200d-2b1b" + }, + ":black_cat:": { + "category": "nature", + "name": "black cat", + "unicode": "1f408-200d-2b1b" + }, + ":black_circle:": { + "category": "symbols", + "name": "black circle", + "unicode": "26ab" + }, + ":black_heart:": { + "category": "symbols", + "name": "black heart", + "unicode": "1f5a4" + }, + ":black_joker:": { + "category": "symbols", + "name": "joker", + "unicode": "1f0cf" + }, + ":black_large_square:": { + "category": "symbols", + "name": "black large square", + "unicode": "2b1b" + }, + ":black_medium_small_square:": { + "category": "symbols", + "name": "black medium-small square", + "unicode": "25fe" + }, + ":black_medium_square:": { + "category": "symbols", + "name": "black medium square", + "unicode": "25fc" + }, + ":black_nib:": { + "category": "objects", + "name": "black nib", + "unicode": "2712" + }, + ":black_small_square:": { + "category": "symbols", + "name": "black small square", + "unicode": "25aa" + }, + ":black_square_button:": { + "category": "symbols", + "name": "black square button", + "unicode": "1f532" + }, + ":blond-haired_man:": { + "category": "people", + "name": "man: blond hair", + "unicode": "1f471-200d-2642-fe0f" + }, + ":blond-haired_man_tone1:": { + "category": "people", + "name": "blond-haired man: light skin tone", + "unicode": "1f471-1f3fb-200d-2642-fe0f" + }, + ":blond-haired_man_tone2:": { + "category": "people", + "name": "blond-haired man: medium-light skin tone", + "unicode": "1f471-1f3fc-200d-2642-fe0f" + }, + ":blond-haired_man_tone3:": { + "category": "people", + "name": "blond-haired man: medium skin tone", + "unicode": "1f471-1f3fd-200d-2642-fe0f" + }, + ":blond-haired_man_tone4:": { + "category": "people", + "name": "blond-haired man: medium-dark skin tone", + "unicode": "1f471-1f3fe-200d-2642-fe0f" + }, + ":blond-haired_man_tone5:": { + "category": "people", + "name": "blond-haired man: dark skin tone", + "unicode": "1f471-1f3ff-200d-2642-fe0f" + }, + ":blond-haired_woman:": { + "category": "people", + "name": "woman: blond hair", + "unicode": "1f471-200d-2640-fe0f" + }, + ":blond-haired_woman_tone1:": { + "category": "people", + "name": "blond-haired woman: light skin tone", + "unicode": "1f471-1f3fb-200d-2640-fe0f" + }, + ":blond-haired_woman_tone2:": { + "category": "people", + "name": "blond-haired woman: medium-light skin tone", + "unicode": "1f471-1f3fc-200d-2640-fe0f" + }, + ":blond-haired_woman_tone3:": { + "category": "people", + "name": "blond-haired woman: medium skin tone", + "unicode": "1f471-1f3fd-200d-2640-fe0f" + }, + ":blond-haired_woman_tone4:": { + "category": "people", + "name": "blond-haired woman: medium-dark skin tone", + "unicode": "1f471-1f3fe-200d-2640-fe0f" + }, + ":blond-haired_woman_tone5:": { + "category": "people", + "name": "blond-haired woman: dark skin tone", + "unicode": "1f471-1f3ff-200d-2640-fe0f" + }, + ":blond_haired_person:": { + "category": "people", + "name": "person: blond hair", + "unicode": "1f471" + }, + ":blond_haired_person_tone1:": { + "category": "people", + "name": "blond-haired person: light skin tone", + "unicode": "1f471-1f3fb" + }, + ":blond_haired_person_tone2:": { + "category": "people", + "name": "blond-haired person: medium-light skin tone", + "unicode": "1f471-1f3fc" + }, + ":blond_haired_person_tone3:": { + "category": "people", + "name": "blond-haired person: medium skin tone", + "unicode": "1f471-1f3fd" + }, + ":blond_haired_person_tone4:": { + "category": "people", + "name": "blond-haired person: medium-dark skin tone", + "unicode": "1f471-1f3fe" + }, + ":blond_haired_person_tone5:": { + "category": "people", + "name": "blond-haired person: dark skin tone", + "unicode": "1f471-1f3ff" + }, + ":blossom:": { + "category": "nature", + "name": "blossom", + "unicode": "1f33c" + }, + ":blowfish:": { + "category": "nature", + "name": "blowfish", + "unicode": "1f421" + }, + ":blue_book:": { + "category": "objects", + "name": "blue book", + "unicode": "1f4d8" + }, + ":blue_car:": { + "category": "travel", + "name": "sport utility vehicle", + "unicode": "1f699" + }, + ":blue_circle:": { + "category": "symbols", + "name": "blue circle", + "unicode": "1f535" + }, + ":blue_heart:": { + "category": "symbols", + "name": "blue heart", + "unicode": "1f499" + }, + ":blue_square:": { + "category": "symbols", + "name": "blue square", + "unicode": "1f7e6" + }, + ":blueberries:": { + "category": "food", + "name": "blueberries", + "unicode": "1fad0" + }, + ":blush:": { + "category": "people", + "name": "smiling face with smiling eyes", + "unicode": "1f60a" + }, + ":boar:": { + "category": "nature", + "name": "boar", + "unicode": "1f417" + }, + ":bomb:": { + "category": "objects", + "name": "bomb", + "unicode": "1f4a3" + }, + ":bone:": { + "category": "food", + "name": "bone", + "unicode": "1f9b4" + }, + ":book:": { + "category": "objects", + "name": "open book", + "unicode": "1f4d6" + }, + ":bookmark:": { + "category": "objects", + "name": "bookmark", + "unicode": "1f516" + }, + ":bookmark_tabs:": { + "category": "objects", + "name": "bookmark tabs", + "unicode": "1f4d1" + }, + ":books:": { + "category": "objects", + "name": "books", + "unicode": "1f4da" + }, + ":boom:": { + "category": "nature", + "name": "collision", + "unicode": "1f4a5" + }, + ":boomerang:": { + "category": "activity", + "name": "boomerang", + "unicode": "1fa83" + }, + ":boot:": { + "category": "people", + "name": "woman\u2019s boot", + "unicode": "1f462" + }, + ":bouquet:": { + "category": "nature", + "name": "bouquet", + "unicode": "1f490" + }, + ":bow_and_arrow:": { + "category": "activity", + "name": "bow and arrow", + "unicode": "1f3f9" + }, + ":bowl_with_spoon:": { + "category": "food", + "name": "bowl with spoon", + "unicode": "1f963" + }, + ":bowling:": { + "category": "activity", + "name": "bowling", + "unicode": "1f3b3" + }, + ":boxing_glove:": { + "category": "activity", + "name": "boxing glove", + "unicode": "1f94a" + }, + ":boy:": { + "category": "people", + "name": "boy", + "unicode": "1f466" + }, + ":boy_tone1:": { + "category": "people", + "name": "boy: light skin tone", + "unicode": "1f466-1f3fb" + }, + ":boy_tone2:": { + "category": "people", + "name": "boy: medium-light skin tone", + "unicode": "1f466-1f3fc" + }, + ":boy_tone3:": { + "category": "people", + "name": "boy: medium skin tone", + "unicode": "1f466-1f3fd" + }, + ":boy_tone4:": { + "category": "people", + "name": "boy: medium-dark skin tone", + "unicode": "1f466-1f3fe" + }, + ":boy_tone5:": { + "category": "people", + "name": "boy: dark skin tone", + "unicode": "1f466-1f3ff" + }, + ":brain:": { + "category": "people", + "name": "brain", + "unicode": "1f9e0" + }, + ":bread:": { + "category": "food", + "name": "bread", + "unicode": "1f35e" + }, + ":breast_feeding:": { + "category": "people", + "name": "breast-feeding", + "unicode": "1f931" + }, + ":breast_feeding_tone1:": { + "category": "people", + "name": "breast-feeding: light skin tone", + "unicode": "1f931-1f3fb" + }, + ":breast_feeding_tone2:": { + "category": "people", + "name": "breast-feeding: medium-light skin tone", + "unicode": "1f931-1f3fc" + }, + ":breast_feeding_tone3:": { + "category": "people", + "name": "breast-feeding: medium skin tone", + "unicode": "1f931-1f3fd" + }, + ":breast_feeding_tone4:": { + "category": "people", + "name": "breast-feeding: medium-dark skin tone", + "unicode": "1f931-1f3fe" + }, + ":breast_feeding_tone5:": { + "category": "people", + "name": "breast-feeding: dark skin tone", + "unicode": "1f931-1f3ff" + }, + ":bricks:": { + "category": "objects", + "name": "brick", + "unicode": "1f9f1" + }, + ":bridge_at_night:": { + "category": "travel", + "name": "bridge at night", + "unicode": "1f309" + }, + ":briefcase:": { + "category": "people", + "name": "briefcase", + "unicode": "1f4bc" + }, + ":briefs:": { + "category": "people", + "name": "briefs", + "unicode": "1fa72" + }, + ":broccoli:": { + "category": "food", + "name": "broccoli", + "unicode": "1f966" + }, + ":broken_chain:": { + "category": "objects", + "name": "broken chain", + "unicode": "26d3-fe0f-200d-1f4a5" + }, + ":broken_heart:": { + "category": "symbols", + "name": "broken heart", + "unicode": "1f494" + }, + ":broom:": { + "category": "objects", + "name": "broom", + "unicode": "1f9f9" + }, + ":brown_circle:": { + "category": "symbols", + "name": "brown circle", + "unicode": "1f7e4" + }, + ":brown_heart:": { + "category": "symbols", + "name": "brown heart", + "unicode": "1f90e" + }, + ":brown_mushroom:": { + "category": "nature", + "name": "brown mushroom", + "unicode": "1f344-200d-1f7eb" + }, + ":brown_square:": { + "category": "symbols", + "name": "brown square", + "unicode": "1f7eb" + }, + ":bubble_tea:": { + "category": "food", + "name": "bubble tea", + "unicode": "1f9cb" + }, + ":bubbles:": { + "category": "nature", + "name": "bubbles", + "unicode": "1fae7" + }, + ":bucket:": { + "category": "objects", + "name": "bucket", + "unicode": "1faa3" + }, + ":bug:": { + "category": "nature", + "name": "bug", + "unicode": "1f41b" + }, + ":bulb:": { + "category": "objects", + "name": "light bulb", + "unicode": "1f4a1" + }, + ":bullettrain_front:": { + "category": "travel", + "name": "bullet train", + "unicode": "1f685" + }, + ":bullettrain_side:": { + "category": "travel", + "name": "high-speed train", + "unicode": "1f684" + }, + ":burrito:": { + "category": "food", + "name": "burrito", + "unicode": "1f32f" + }, + ":bus:": { + "category": "travel", + "name": "bus", + "unicode": "1f68c" + }, + ":busstop:": { + "category": "travel", + "name": "bus stop", + "unicode": "1f68f" + }, + ":bust_in_silhouette:": { + "category": "people", + "name": "bust in silhouette", + "unicode": "1f464" + }, + ":busts_in_silhouette:": { + "category": "people", + "name": "busts in silhouette", + "unicode": "1f465" + }, + ":butter:": { + "category": "food", + "name": "butter", + "unicode": "1f9c8" + }, + ":butterfly:": { + "category": "nature", + "name": "butterfly", + "unicode": "1f98b" + }, + ":cactus:": { + "category": "nature", + "name": "cactus", + "unicode": "1f335" + }, + ":cake:": { + "category": "food", + "name": "shortcake", + "unicode": "1f370" + }, + ":calendar:": { + "category": "objects", + "name": "tear-off calendar", + "unicode": "1f4c6" + }, + ":calendar_spiral:": { + "category": "objects", + "name": "spiral calendar", + "unicode": "1f5d3" + }, + ":call_me:": { + "category": "people", + "name": "call me hand", + "unicode": "1f919" + }, + ":call_me_tone1:": { + "category": "people", + "name": "call me hand: light skin tone", + "unicode": "1f919-1f3fb" + }, + ":call_me_tone2:": { + "category": "people", + "name": "call me hand: medium-light skin tone", + "unicode": "1f919-1f3fc" + }, + ":call_me_tone3:": { + "category": "people", + "name": "call me hand: medium skin tone", + "unicode": "1f919-1f3fd" + }, + ":call_me_tone4:": { + "category": "people", + "name": "call me hand: medium-dark skin tone", + "unicode": "1f919-1f3fe" + }, + ":call_me_tone5:": { + "category": "people", + "name": "call me hand: dark skin tone", + "unicode": "1f919-1f3ff" + }, + ":calling:": { + "category": "objects", + "name": "mobile phone with arrow", + "unicode": "1f4f2" + }, + ":camel:": { + "category": "nature", + "name": "two-hump camel", + "unicode": "1f42b" + }, + ":camera:": { + "category": "objects", + "name": "camera", + "unicode": "1f4f7" + }, + ":camera_with_flash:": { + "category": "objects", + "name": "camera with flash", + "unicode": "1f4f8" + }, + ":camping:": { + "category": "travel", + "name": "camping", + "unicode": "1f3d5" + }, + ":cancer:": { + "category": "symbols", + "name": "Cancer", + "unicode": "264b" + }, + ":candle:": { + "category": "objects", + "name": "candle", + "unicode": "1f56f" + }, + ":candy:": { + "category": "food", + "name": "candy", + "unicode": "1f36c" + }, + ":canned_food:": { + "category": "food", + "name": "canned food", + "unicode": "1f96b" + }, + ":canoe:": { + "category": "travel", + "name": "canoe", + "unicode": "1f6f6" + }, + ":capital_abcd:": { + "category": "symbols", + "name": "input latin uppercase", + "unicode": "1f520" + }, + ":capricorn:": { + "category": "symbols", + "name": "Capricorn", + "unicode": "2651" + }, + ":card_box:": { + "category": "objects", + "name": "card file box", + "unicode": "1f5c3" + }, + ":card_index:": { + "category": "objects", + "name": "card index", + "unicode": "1f4c7" + }, + ":carousel_horse:": { + "category": "travel", + "name": "carousel horse", + "unicode": "1f3a0" + }, + ":carpentry_saw:": { + "category": "objects", + "name": "carpentry saw", + "unicode": "1fa9a" + }, + ":carrot:": { + "category": "food", + "name": "carrot", + "unicode": "1f955" + }, + ":cat2:": { + "category": "nature", + "name": "cat", + "unicode": "1f408" + }, + ":cat:": { + "category": "nature", + "name": "cat face", + "unicode": "1f431" + }, + ":cd:": { + "category": "objects", + "name": "optical disk", + "unicode": "1f4bf" + }, + ":chains:": { + "category": "objects", + "name": "chains", + "unicode": "26d3" + }, + ":chair:": { + "category": "objects", + "name": "chair", + "unicode": "1fa91" + }, + ":champagne:": { + "category": "food", + "name": "bottle with popping cork", + "unicode": "1f37e" + }, + ":champagne_glass:": { + "category": "food", + "name": "clinking glasses", + "unicode": "1f942" + }, + ":chart:": { + "category": "symbols", + "name": "chart increasing with yen", + "unicode": "1f4b9" + }, + ":chart_with_downwards_trend:": { + "category": "objects", + "name": "chart decreasing", + "unicode": "1f4c9" + }, + ":chart_with_upwards_trend:": { + "category": "objects", + "name": "chart increasing", + "unicode": "1f4c8" + }, + ":checkered_flag:": { + "category": "flags", + "name": "chequered flag", + "unicode": "1f3c1" + }, + ":cheese:": { + "category": "food", + "name": "cheese wedge", + "unicode": "1f9c0" + }, + ":cherries:": { + "category": "food", + "name": "cherries", + "unicode": "1f352" + }, + ":cherry_blossom:": { + "category": "nature", + "name": "cherry blossom", + "unicode": "1f338" + }, + ":chess_pawn:": { + "category": "activity", + "name": "chess pawn", + "unicode": "265f" + }, + ":chestnut:": { + "category": "food", + "name": "chestnut", + "unicode": "1f330" + }, + ":chicken:": { + "category": "nature", + "name": "chicken", + "unicode": "1f414" + }, + ":child:": { + "category": "people", + "name": "child", + "unicode": "1f9d2" + }, + ":child_tone1:": { + "category": "people", + "name": "child: light skin tone", + "unicode": "1f9d2-1f3fb" + }, + ":child_tone2:": { + "category": "people", + "name": "child: medium-light skin tone", + "unicode": "1f9d2-1f3fc" + }, + ":child_tone3:": { + "category": "people", + "name": "child: medium skin tone", + "unicode": "1f9d2-1f3fd" + }, + ":child_tone4:": { + "category": "people", + "name": "child: medium-dark skin tone", + "unicode": "1f9d2-1f3fe" + }, + ":child_tone5:": { + "category": "people", + "name": "child: dark skin tone", + "unicode": "1f9d2-1f3ff" + }, + ":children_crossing:": { + "category": "symbols", + "name": "children crossing", + "unicode": "1f6b8" + }, + ":chipmunk:": { + "category": "nature", + "name": "chipmunk", + "unicode": "1f43f" + }, + ":chocolate_bar:": { + "category": "food", + "name": "chocolate bar", + "unicode": "1f36b" + }, + ":chopsticks:": { + "category": "food", + "name": "chopsticks", + "unicode": "1f962" + }, + ":christmas_tree:": { + "category": "nature", + "name": "Christmas tree", + "unicode": "1f384" + }, + ":church:": { + "category": "travel", + "name": "church", + "unicode": "26ea" + }, + ":cinema:": { + "category": "symbols", + "name": "cinema", + "unicode": "1f3a6" + }, + ":circus_tent:": { + "category": "activity", + "name": "circus tent", + "unicode": "1f3aa" + }, + ":city_dusk:": { + "category": "travel", + "name": "cityscape at dusk", + "unicode": "1f306" + }, + ":city_sunset:": { + "category": "travel", + "name": "sunset", + "unicode": "1f307" + }, + ":cityscape:": { + "category": "travel", + "name": "cityscape", + "unicode": "1f3d9" + }, + ":cl:": { + "category": "symbols", + "name": "CL button", + "unicode": "1f191" + }, + ":clap:": { + "category": "people", + "name": "clapping hands", + "unicode": "1f44f" + }, + ":clap_tone1:": { + "category": "people", + "name": "clapping hands: light skin tone", + "unicode": "1f44f-1f3fb" + }, + ":clap_tone2:": { + "category": "people", + "name": "clapping hands: medium-light skin tone", + "unicode": "1f44f-1f3fc" + }, + ":clap_tone3:": { + "category": "people", + "name": "clapping hands: medium skin tone", + "unicode": "1f44f-1f3fd" + }, + ":clap_tone4:": { + "category": "people", + "name": "clapping hands: medium-dark skin tone", + "unicode": "1f44f-1f3fe" + }, + ":clap_tone5:": { + "category": "people", + "name": "clapping hands: dark skin tone", + "unicode": "1f44f-1f3ff" + }, + ":clapper:": { + "category": "activity", + "name": "clapper board", + "unicode": "1f3ac" + }, + ":classical_building:": { + "category": "travel", + "name": "classical building", + "unicode": "1f3db" + }, + ":clipboard:": { + "category": "objects", + "name": "clipboard", + "unicode": "1f4cb" + }, + ":clock1030:": { + "category": "symbols", + "name": "ten-thirty", + "unicode": "1f565" + }, + ":clock10:": { + "category": "symbols", + "name": "ten o\u2019clock", + "unicode": "1f559" + }, + ":clock1130:": { + "category": "symbols", + "name": "eleven-thirty", + "unicode": "1f566" + }, + ":clock11:": { + "category": "symbols", + "name": "eleven o\u2019clock", + "unicode": "1f55a" + }, + ":clock1230:": { + "category": "symbols", + "name": "twelve-thirty", + "unicode": "1f567" + }, + ":clock12:": { + "category": "symbols", + "name": "twelve o\u2019clock", + "unicode": "1f55b" + }, + ":clock130:": { + "category": "symbols", + "name": "one-thirty", + "unicode": "1f55c" + }, + ":clock1:": { + "category": "symbols", + "name": "one o\u2019clock", + "unicode": "1f550" + }, + ":clock230:": { + "category": "symbols", + "name": "two-thirty", + "unicode": "1f55d" + }, + ":clock2:": { + "category": "symbols", + "name": "two o\u2019clock", + "unicode": "1f551" + }, + ":clock330:": { + "category": "symbols", + "name": "three-thirty", + "unicode": "1f55e" + }, + ":clock3:": { + "category": "symbols", + "name": "three o\u2019clock", + "unicode": "1f552" + }, + ":clock430:": { + "category": "symbols", + "name": "four-thirty", + "unicode": "1f55f" + }, + ":clock4:": { + "category": "symbols", + "name": "four o\u2019clock", + "unicode": "1f553" + }, + ":clock530:": { + "category": "symbols", + "name": "five-thirty", + "unicode": "1f560" + }, + ":clock5:": { + "category": "symbols", + "name": "five o\u2019clock", + "unicode": "1f554" + }, + ":clock630:": { + "category": "symbols", + "name": "six-thirty", + "unicode": "1f561" + }, + ":clock6:": { + "category": "symbols", + "name": "six o\u2019clock", + "unicode": "1f555" + }, + ":clock730:": { + "category": "symbols", + "name": "seven-thirty", + "unicode": "1f562" + }, + ":clock7:": { + "category": "symbols", + "name": "seven o\u2019clock", + "unicode": "1f556" + }, + ":clock830:": { + "category": "symbols", + "name": "eight-thirty", + "unicode": "1f563" + }, + ":clock8:": { + "category": "symbols", + "name": "eight o\u2019clock", + "unicode": "1f557" + }, + ":clock930:": { + "category": "symbols", + "name": "nine-thirty", + "unicode": "1f564" + }, + ":clock9:": { + "category": "symbols", + "name": "nine o\u2019clock", + "unicode": "1f558" + }, + ":clock:": { + "category": "objects", + "name": "mantelpiece clock", + "unicode": "1f570" + }, + ":closed_book:": { + "category": "objects", + "name": "closed book", + "unicode": "1f4d5" + }, + ":closed_lock_with_key:": { + "category": "objects", + "name": "locked with key", + "unicode": "1f510" + }, + ":closed_umbrella:": { + "category": "people", + "name": "closed umbrella", + "unicode": "1f302" + }, + ":cloud:": { + "category": "nature", + "name": "cloud", + "unicode": "2601" + }, + ":cloud_lightning:": { + "category": "nature", + "name": "cloud with lightning", + "unicode": "1f329" + }, + ":cloud_rain:": { + "category": "nature", + "name": "cloud with rain", + "unicode": "1f327" + }, + ":cloud_snow:": { + "category": "nature", + "name": "cloud with snow", + "unicode": "1f328" + }, + ":cloud_tornado:": { + "category": "nature", + "name": "tornado", + "unicode": "1f32a" + }, + ":clown:": { + "category": "people", + "name": "clown face", + "unicode": "1f921" + }, + ":clubs:": { + "category": "symbols", + "name": "club suit", + "unicode": "2663" + }, + ":coat:": { + "category": "people", + "name": "coat", + "unicode": "1f9e5" + }, + ":cockroach:": { + "category": "nature", + "name": "cockroach", + "unicode": "1fab3" + }, + ":cocktail:": { + "category": "food", + "name": "cocktail glass", + "unicode": "1f378" + }, + ":coconut:": { + "category": "food", + "name": "coconut", + "unicode": "1f965" + }, + ":coffee:": { + "category": "food", + "name": "hot beverage", + "unicode": "2615" + }, + ":coffin:": { + "category": "objects", + "name": "coffin", + "unicode": "26b0" + }, + ":coin:": { + "category": "objects", + "name": "coin", + "unicode": "1fa99" + }, + ":cold_face:": { + "category": "people", + "name": "cold face", + "unicode": "1f976" + }, + ":cold_sweat:": { + "category": "people", + "name": "anxious face with sweat", + "unicode": "1f630" + }, + ":comet:": { + "category": "nature", + "name": "comet", + "unicode": "2604" + }, + ":compass:": { + "category": "objects", + "name": "compass", + "unicode": "1f9ed" + }, + ":compression:": { + "category": "objects", + "name": "clamp", + "unicode": "1f5dc" + }, + ":computer:": { + "category": "objects", + "name": "laptop computer", + "unicode": "1f4bb" + }, + ":confetti_ball:": { + "category": "objects", + "name": "confetti ball", + "unicode": "1f38a" + }, + ":confounded:": { + "category": "people", + "name": "confounded face", + "unicode": "1f616" + }, + ":confused:": { + "category": "people", + "name": "confused face", + "unicode": "1f615" + }, + ":congratulations:": { + "category": "symbols", + "name": "Japanese \u201ccongratulations\u201d button", + "unicode": "3297" + }, + ":construction:": { + "category": "travel", + "name": "construction", + "unicode": "1f6a7" + }, + ":construction_site:": { + "category": "travel", + "name": "building construction", + "unicode": "1f3d7" + }, + ":construction_worker:": { + "category": "people", + "name": "construction worker", + "unicode": "1f477" + }, + ":construction_worker_tone1:": { + "category": "people", + "name": "construction worker: light skin tone", + "unicode": "1f477-1f3fb" + }, + ":construction_worker_tone2:": { + "category": "people", + "name": "construction worker: medium-light skin tone", + "unicode": "1f477-1f3fc" + }, + ":construction_worker_tone3:": { + "category": "people", + "name": "construction worker: medium skin tone", + "unicode": "1f477-1f3fd" + }, + ":construction_worker_tone4:": { + "category": "people", + "name": "construction worker: medium-dark skin tone", + "unicode": "1f477-1f3fe" + }, + ":construction_worker_tone5:": { + "category": "people", + "name": "construction worker: dark skin tone", + "unicode": "1f477-1f3ff" + }, + ":control_knobs:": { + "category": "objects", + "name": "control knobs", + "unicode": "1f39b" + }, + ":convenience_store:": { + "category": "travel", + "name": "convenience store", + "unicode": "1f3ea" + }, + ":cook:": { + "category": "people", + "name": "cook", + "unicode": "1f9d1-200d-1f373" + }, + ":cook_tone1:": { + "category": "people", + "name": "cook: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f373" + }, + ":cook_tone2:": { + "category": "people", + "name": "cook: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f373" + }, + ":cook_tone3:": { + "category": "people", + "name": "cook: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f373" + }, + ":cook_tone4:": { + "category": "people", + "name": "cook: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f373" + }, + ":cook_tone5:": { + "category": "people", + "name": "cook: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f373" + }, + ":cookie:": { + "category": "food", + "name": "cookie", + "unicode": "1f36a" + }, + ":cooking:": { + "category": "food", + "name": "cooking", + "unicode": "1f373" + }, + ":cool:": { + "category": "symbols", + "name": "COOL button", + "unicode": "1f192" + }, + ":copyright:": { + "category": "symbols", + "name": "copyright", + "unicode": "a9", + "unicode_alt": "00a9" + }, + ":coral:": { + "category": "nature", + "name": "coral", + "unicode": "1fab8" + }, + ":corn:": { + "category": "food", + "name": "ear of corn", + "unicode": "1f33d" + }, + ":couch:": { + "category": "objects", + "name": "couch and lamp", + "unicode": "1f6cb" + }, + ":couple:": { + "category": "people", + "name": "woman and man holding hands", + "unicode": "1f46b" + }, + ":couple_mm:": { + "category": "people", + "name": "couple with heart: man, man", + "unicode": "1f468-200d-2764-fe0f-200d-1f468" + }, + ":couple_with_heart:": { + "category": "people", + "name": "couple with heart", + "unicode": "1f491" + }, + ":couple_with_heart_man_man_tone1:": { + "category": "people", + "name": "couple with heart: man, man, light skin tone", + "unicode": "1f468-1f3fb-200d-2764-fe0f-200d-1f468-1f3fb" + }, + ":couple_with_heart_man_man_tone1_tone2:": { + "category": "people", + "name": "couple with heart: man, man, light skin tone, medium-light skin tone", + "unicode": "1f468-1f3fb-200d-2764-fe0f-200d-1f468-1f3fc" + }, + ":couple_with_heart_man_man_tone1_tone3:": { + "category": "people", + "name": "couple with heart: man, man, light skin tone, medium skin tone", + "unicode": "1f468-1f3fb-200d-2764-fe0f-200d-1f468-1f3fd" + }, + ":couple_with_heart_man_man_tone1_tone4:": { + "category": "people", + "name": "couple with heart: man, man, light skin tone, medium-dark skin tone", + "unicode": "1f468-1f3fb-200d-2764-fe0f-200d-1f468-1f3fe" + }, + ":couple_with_heart_man_man_tone1_tone5:": { + "category": "people", + "name": "couple with heart: man, man, light skin tone, dark skin tone", + "unicode": "1f468-1f3fb-200d-2764-fe0f-200d-1f468-1f3ff" + }, + ":couple_with_heart_man_man_tone2:": { + "category": "people", + "name": "couple with heart: man, man, medium-light skin tone", + "unicode": "1f468-1f3fc-200d-2764-fe0f-200d-1f468-1f3fc" + }, + ":couple_with_heart_man_man_tone2_tone1:": { + "category": "people", + "name": "couple with heart: man, man, medium-light skin tone, light skin tone", + "unicode": "1f468-1f3fc-200d-2764-fe0f-200d-1f468-1f3fb" + }, + ":couple_with_heart_man_man_tone2_tone3:": { + "category": "people", + "name": "couple with heart: man, man, medium-light skin tone, medium skin tone", + "unicode": "1f468-1f3fc-200d-2764-fe0f-200d-1f468-1f3fd" + }, + ":couple_with_heart_man_man_tone2_tone4:": { + "category": "people", + "name": "couple with heart: man, man, medium-light skin tone, medium-dark skin tone", + "unicode": "1f468-1f3fc-200d-2764-fe0f-200d-1f468-1f3fe" + }, + ":couple_with_heart_man_man_tone2_tone5:": { + "category": "people", + "name": "couple with heart: man, man, medium-light skin tone, dark skin tone", + "unicode": "1f468-1f3fc-200d-2764-fe0f-200d-1f468-1f3ff" + }, + ":couple_with_heart_man_man_tone3:": { + "category": "people", + "name": "couple with heart: man, man, medium skin tone", + "unicode": "1f468-1f3fd-200d-2764-fe0f-200d-1f468-1f3fd" + }, + ":couple_with_heart_man_man_tone3_tone1:": { + "category": "people", + "name": "couple with heart: man, man, medium skin tone, light skin tone", + "unicode": "1f468-1f3fd-200d-2764-fe0f-200d-1f468-1f3fb" + }, + ":couple_with_heart_man_man_tone3_tone2:": { + "category": "people", + "name": "couple with heart: man, man, medium skin tone, medium-light skin tone", + "unicode": "1f468-1f3fd-200d-2764-fe0f-200d-1f468-1f3fc" + }, + ":couple_with_heart_man_man_tone3_tone4:": { + "category": "people", + "name": "couple with heart: man, man, medium skin tone, medium-dark skin tone", + "unicode": "1f468-1f3fd-200d-2764-fe0f-200d-1f468-1f3fe" + }, + ":couple_with_heart_man_man_tone3_tone5:": { + "category": "people", + "name": "couple with heart: man, man, medium skin tone, dark skin tone", + "unicode": "1f468-1f3fd-200d-2764-fe0f-200d-1f468-1f3ff" + }, + ":couple_with_heart_man_man_tone4:": { + "category": "people", + "name": "couple with heart: man, man, medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-2764-fe0f-200d-1f468-1f3fe" + }, + ":couple_with_heart_man_man_tone4_tone1:": { + "category": "people", + "name": "couple with heart: man, man, medium-dark skin tone, light skin tone", + "unicode": "1f468-1f3fe-200d-2764-fe0f-200d-1f468-1f3fb" + }, + ":couple_with_heart_man_man_tone4_tone2:": { + "category": "people", + "name": "couple with heart: man, man, medium-dark skin tone, medium-light skin tone", + "unicode": "1f468-1f3fe-200d-2764-fe0f-200d-1f468-1f3fc" + }, + ":couple_with_heart_man_man_tone4_tone3:": { + "category": "people", + "name": "couple with heart: man, man, medium-dark skin tone, medium skin tone", + "unicode": "1f468-1f3fe-200d-2764-fe0f-200d-1f468-1f3fd" + }, + ":couple_with_heart_man_man_tone4_tone5:": { + "category": "people", + "name": "couple with heart: man, man, medium-dark skin tone, dark skin tone", + "unicode": "1f468-1f3fe-200d-2764-fe0f-200d-1f468-1f3ff" + }, + ":couple_with_heart_man_man_tone5:": { + "category": "people", + "name": "couple with heart: man, man, dark skin tone", + "unicode": "1f468-1f3ff-200d-2764-fe0f-200d-1f468-1f3ff" + }, + ":couple_with_heart_man_man_tone5_tone1:": { + "category": "people", + "name": "couple with heart: man, man, dark skin tone, light skin tone", + "unicode": "1f468-1f3ff-200d-2764-fe0f-200d-1f468-1f3fb" + }, + ":couple_with_heart_man_man_tone5_tone2:": { + "category": "people", + "name": "couple with heart: man, man, dark skin tone, medium-light skin tone", + "unicode": "1f468-1f3ff-200d-2764-fe0f-200d-1f468-1f3fc" + }, + ":couple_with_heart_man_man_tone5_tone3:": { + "category": "people", + "name": "couple with heart: man, man, dark skin tone, medium skin tone", + "unicode": "1f468-1f3ff-200d-2764-fe0f-200d-1f468-1f3fd" + }, + ":couple_with_heart_man_man_tone5_tone4:": { + "category": "people", + "name": "couple with heart: man, man, dark skin tone, medium-dark skin tone", + "unicode": "1f468-1f3ff-200d-2764-fe0f-200d-1f468-1f3fe" + }, + ":couple_with_heart_person_person_tone1_tone2:": { + "category": "people", + "name": "couple with heart: person, person, light skin tone, medium-light skin tone", + "unicode": "1f9d1-1f3fb-200d-2764-fe0f-200d-1f9d1-1f3fc" + }, + ":couple_with_heart_person_person_tone1_tone3:": { + "category": "people", + "name": "couple with heart: person, person, light skin tone, medium skin tone", + "unicode": "1f9d1-1f3fb-200d-2764-fe0f-200d-1f9d1-1f3fd" + }, + ":couple_with_heart_person_person_tone1_tone4:": { + "category": "people", + "name": "couple with heart: person, person, light skin tone, medium-dark skin tone", + "unicode": "1f9d1-1f3fb-200d-2764-fe0f-200d-1f9d1-1f3fe" + }, + ":couple_with_heart_person_person_tone1_tone5:": { + "category": "people", + "name": "couple with heart: person, person, light skin tone, dark skin tone", + "unicode": "1f9d1-1f3fb-200d-2764-fe0f-200d-1f9d1-1f3ff" + }, + ":couple_with_heart_person_person_tone2_tone1:": { + "category": "people", + "name": "couple with heart: person, person, medium-light skin tone, light skin tone", + "unicode": "1f9d1-1f3fc-200d-2764-fe0f-200d-1f9d1-1f3fb" + }, + ":couple_with_heart_person_person_tone2_tone3:": { + "category": "people", + "name": "couple with heart: person, person, medium-light skin tone, medium skin tone", + "unicode": "1f9d1-1f3fc-200d-2764-fe0f-200d-1f9d1-1f3fd" + }, + ":couple_with_heart_person_person_tone2_tone4:": { + "category": "people", + "name": "couple with heart: person, person, medium-light skin tone, medium-dark skin tone", + "unicode": "1f9d1-1f3fc-200d-2764-fe0f-200d-1f9d1-1f3fe" + }, + ":couple_with_heart_person_person_tone2_tone5:": { + "category": "people", + "name": "couple with heart: person, person, medium-light skin tone, dark skin tone", + "unicode": "1f9d1-1f3fc-200d-2764-fe0f-200d-1f9d1-1f3ff" + }, + ":couple_with_heart_person_person_tone3_tone1:": { + "category": "people", + "name": "couple with heart: person, person, medium skin tone, light skin tone", + "unicode": "1f9d1-1f3fd-200d-2764-fe0f-200d-1f9d1-1f3fb" + }, + ":couple_with_heart_person_person_tone3_tone2:": { + "category": "people", + "name": "couple with heart: person, person, medium skin tone, medium-light skin tone", + "unicode": "1f9d1-1f3fd-200d-2764-fe0f-200d-1f9d1-1f3fc" + }, + ":couple_with_heart_person_person_tone3_tone4:": { + "category": "people", + "name": "couple with heart: person, person, medium skin tone, medium-dark skin tone", + "unicode": "1f9d1-1f3fd-200d-2764-fe0f-200d-1f9d1-1f3fe" + }, + ":couple_with_heart_person_person_tone3_tone5:": { + "category": "people", + "name": "couple with heart: person, person, medium skin tone, dark skin tone", + "unicode": "1f9d1-1f3fd-200d-2764-fe0f-200d-1f9d1-1f3ff" + }, + ":couple_with_heart_person_person_tone4_tone1:": { + "category": "people", + "name": "couple with heart: person, person, medium-dark skin tone, light skin tone", + "unicode": "1f9d1-1f3fe-200d-2764-fe0f-200d-1f9d1-1f3fb" + }, + ":couple_with_heart_person_person_tone4_tone2:": { + "category": "people", + "name": "couple with heart: person, person, medium-dark skin tone, medium-light skin tone", + "unicode": "1f9d1-1f3fe-200d-2764-fe0f-200d-1f9d1-1f3fc" + }, + ":couple_with_heart_person_person_tone4_tone3:": { + "category": "people", + "name": "couple with heart: person, person, medium-dark skin tone, medium skin tone", + "unicode": "1f9d1-1f3fe-200d-2764-fe0f-200d-1f9d1-1f3fd" + }, + ":couple_with_heart_person_person_tone4_tone5:": { + "category": "people", + "name": "couple with heart: person, person, medium-dark skin tone, dark skin tone", + "unicode": "1f9d1-1f3fe-200d-2764-fe0f-200d-1f9d1-1f3ff" + }, + ":couple_with_heart_person_person_tone5_tone1:": { + "category": "people", + "name": "couple with heart: person, person, dark skin tone, light skin tone", + "unicode": "1f9d1-1f3ff-200d-2764-fe0f-200d-1f9d1-1f3fb" + }, + ":couple_with_heart_person_person_tone5_tone2:": { + "category": "people", + "name": "couple with heart: person, person, dark skin tone, medium-light skin tone", + "unicode": "1f9d1-1f3ff-200d-2764-fe0f-200d-1f9d1-1f3fc" + }, + ":couple_with_heart_person_person_tone5_tone3:": { + "category": "people", + "name": "couple with heart: person, person, dark skin tone, medium skin tone", + "unicode": "1f9d1-1f3ff-200d-2764-fe0f-200d-1f9d1-1f3fd" + }, + ":couple_with_heart_person_person_tone5_tone4:": { + "category": "people", + "name": "couple with heart: person, person, dark skin tone, medium-dark skin tone", + "unicode": "1f9d1-1f3ff-200d-2764-fe0f-200d-1f9d1-1f3fe" + }, + ":couple_with_heart_tone1:": { + "category": "people", + "name": "couple with heart: light skin tone", + "unicode": "1f491-1f3fb" + }, + ":couple_with_heart_tone2:": { + "category": "people", + "name": "couple with heart: medium-light skin tone", + "unicode": "1f491-1f3fc" + }, + ":couple_with_heart_tone3:": { + "category": "people", + "name": "couple with heart: medium skin tone", + "unicode": "1f491-1f3fd" + }, + ":couple_with_heart_tone4:": { + "category": "people", + "name": "couple with heart: medium-dark skin tone", + "unicode": "1f491-1f3fe" + }, + ":couple_with_heart_tone5:": { + "category": "people", + "name": "couple with heart: dark skin tone", + "unicode": "1f491-1f3ff" + }, + ":couple_with_heart_woman_man:": { + "category": "people", + "name": "couple with heart: woman, man", + "unicode": "1f469-200d-2764-fe0f-200d-1f468" + }, + ":couple_with_heart_woman_man_tone1:": { + "category": "people", + "name": "couple with heart: woman, man, light skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f468-1f3fb" + }, + ":couple_with_heart_woman_man_tone1_tone2:": { + "category": "people", + "name": "couple with heart: woman, man, light skin tone, medium-light skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f468-1f3fc" + }, + ":couple_with_heart_woman_man_tone1_tone3:": { + "category": "people", + "name": "couple with heart: woman, man, light skin tone, medium skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f468-1f3fd" + }, + ":couple_with_heart_woman_man_tone1_tone4:": { + "category": "people", + "name": "couple with heart: woman, man, light skin tone, medium-dark skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f468-1f3fe" + }, + ":couple_with_heart_woman_man_tone1_tone5:": { + "category": "people", + "name": "couple with heart: woman, man, light skin tone, dark skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f468-1f3ff" + }, + ":couple_with_heart_woman_man_tone2:": { + "category": "people", + "name": "couple with heart: woman, man, medium-light skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f468-1f3fc" + }, + ":couple_with_heart_woman_man_tone2_tone1:": { + "category": "people", + "name": "couple with heart: woman, man, medium-light skin tone, light skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f468-1f3fb" + }, + ":couple_with_heart_woman_man_tone2_tone3:": { + "category": "people", + "name": "couple with heart: woman, man, medium-light skin tone, medium skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f468-1f3fd" + }, + ":couple_with_heart_woman_man_tone2_tone4:": { + "category": "people", + "name": "couple with heart: woman, man, medium-light skin tone, medium-dark skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f468-1f3fe" + }, + ":couple_with_heart_woman_man_tone2_tone5:": { + "category": "people", + "name": "couple with heart: woman, man, medium-light skin tone, dark skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f468-1f3ff" + }, + ":couple_with_heart_woman_man_tone3:": { + "category": "people", + "name": "couple with heart: woman, man, medium skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f468-1f3fd" + }, + ":couple_with_heart_woman_man_tone3_tone1:": { + "category": "people", + "name": "couple with heart: woman, man, medium skin tone, light skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f468-1f3fb" + }, + ":couple_with_heart_woman_man_tone3_tone2:": { + "category": "people", + "name": "couple with heart: woman, man, medium skin tone, medium-light skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f468-1f3fc" + }, + ":couple_with_heart_woman_man_tone3_tone4:": { + "category": "people", + "name": "couple with heart: woman, man, medium skin tone, medium-dark skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f468-1f3fe" + }, + ":couple_with_heart_woman_man_tone3_tone5:": { + "category": "people", + "name": "couple with heart: woman, man, medium skin tone, dark skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f468-1f3ff" + }, + ":couple_with_heart_woman_man_tone4:": { + "category": "people", + "name": "couple with heart: woman, man, medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f468-1f3fe" + }, + ":couple_with_heart_woman_man_tone4_tone1:": { + "category": "people", + "name": "couple with heart: woman, man, medium-dark skin tone, light skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f468-1f3fb" + }, + ":couple_with_heart_woman_man_tone4_tone2:": { + "category": "people", + "name": "couple with heart: woman, man, medium-dark skin tone, medium-light skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f468-1f3fc" + }, + ":couple_with_heart_woman_man_tone4_tone3:": { + "category": "people", + "name": "couple with heart: woman, man, medium-dark skin tone, medium skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f468-1f3fd" + }, + ":couple_with_heart_woman_man_tone4_tone5:": { + "category": "people", + "name": "couple with heart: woman, man, medium-dark skin tone, dark skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f468-1f3ff" + }, + ":couple_with_heart_woman_man_tone5:": { + "category": "people", + "name": "couple with heart: woman, man, dark skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f468-1f3ff" + }, + ":couple_with_heart_woman_man_tone5_tone1:": { + "category": "people", + "name": "couple with heart: woman, man, dark skin tone, light skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f468-1f3fb" + }, + ":couple_with_heart_woman_man_tone5_tone2:": { + "category": "people", + "name": "couple with heart: woman, man, dark skin tone, medium-light skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f468-1f3fc" + }, + ":couple_with_heart_woman_man_tone5_tone3:": { + "category": "people", + "name": "couple with heart: woman, man, dark skin tone, medium skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f468-1f3fd" + }, + ":couple_with_heart_woman_man_tone5_tone4:": { + "category": "people", + "name": "couple with heart: woman, man, dark skin tone, medium-dark skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f468-1f3fe" + }, + ":couple_with_heart_woman_woman_tone1:": { + "category": "people", + "name": "couple with heart: woman, woman, light skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f469-1f3fb" + }, + ":couple_with_heart_woman_woman_tone1_tone2:": { + "category": "people", + "name": "couple with heart: woman, woman, light skin tone, medium-light skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f469-1f3fc" + }, + ":couple_with_heart_woman_woman_tone1_tone3:": { + "category": "people", + "name": "couple with heart: woman, woman, light skin tone, medium skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f469-1f3fd" + }, + ":couple_with_heart_woman_woman_tone1_tone4:": { + "category": "people", + "name": "couple with heart: woman, woman, light skin tone, medium-dark skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f469-1f3fe" + }, + ":couple_with_heart_woman_woman_tone1_tone5:": { + "category": "people", + "name": "couple with heart: woman, woman, light skin tone, dark skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f469-1f3ff" + }, + ":couple_with_heart_woman_woman_tone2:": { + "category": "people", + "name": "couple with heart: woman, woman, medium-light skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f469-1f3fc" + }, + ":couple_with_heart_woman_woman_tone2_tone1:": { + "category": "people", + "name": "couple with heart: woman, woman, medium-light skin tone, light skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f469-1f3fb" + }, + ":couple_with_heart_woman_woman_tone2_tone3:": { + "category": "people", + "name": "couple with heart: woman, woman, medium-light skin tone, medium skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f469-1f3fd" + }, + ":couple_with_heart_woman_woman_tone2_tone4:": { + "category": "people", + "name": "couple with heart: woman, woman, medium-light skin tone, medium-dark skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f469-1f3fe" + }, + ":couple_with_heart_woman_woman_tone2_tone5:": { + "category": "people", + "name": "couple with heart: woman, woman, medium-light skin tone, dark skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f469-1f3ff" + }, + ":couple_with_heart_woman_woman_tone3:": { + "category": "people", + "name": "couple with heart: woman, woman, medium skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f469-1f3fd" + }, + ":couple_with_heart_woman_woman_tone3_tone1:": { + "category": "people", + "name": "couple with heart: woman, woman, medium skin tone, light skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f469-1f3fb" + }, + ":couple_with_heart_woman_woman_tone3_tone2:": { + "category": "people", + "name": "couple with heart: woman, woman, medium skin tone, medium-light skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f469-1f3fc" + }, + ":couple_with_heart_woman_woman_tone3_tone4:": { + "category": "people", + "name": "couple with heart: woman, woman, medium skin tone, medium-dark skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f469-1f3fe" + }, + ":couple_with_heart_woman_woman_tone3_tone5:": { + "category": "people", + "name": "couple with heart: woman, woman, medium skin tone, dark skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f469-1f3ff" + }, + ":couple_with_heart_woman_woman_tone4:": { + "category": "people", + "name": "couple with heart: woman, woman, medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f469-1f3fe" + }, + ":couple_with_heart_woman_woman_tone4_tone1:": { + "category": "people", + "name": "couple with heart: woman, woman, medium-dark skin tone, light skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f469-1f3fb" + }, + ":couple_with_heart_woman_woman_tone4_tone2:": { + "category": "people", + "name": "couple with heart: woman, woman, medium-dark skin tone, medium-light skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f469-1f3fc" + }, + ":couple_with_heart_woman_woman_tone4_tone3:": { + "category": "people", + "name": "couple with heart: woman, woman, medium-dark skin tone, medium skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f469-1f3fd" + }, + ":couple_with_heart_woman_woman_tone4_tone5:": { + "category": "people", + "name": "couple with heart: woman, woman, medium-dark skin tone, dark skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f469-1f3ff" + }, + ":couple_with_heart_woman_woman_tone5:": { + "category": "people", + "name": "couple with heart: woman, woman, dark skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f469-1f3ff" + }, + ":couple_with_heart_woman_woman_tone5_tone1:": { + "category": "people", + "name": "couple with heart: woman, woman, dark skin tone, light skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f469-1f3fb" + }, + ":couple_with_heart_woman_woman_tone5_tone2:": { + "category": "people", + "name": "couple with heart: woman, woman, dark skin tone, medium-light skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f469-1f3fc" + }, + ":couple_with_heart_woman_woman_tone5_tone3:": { + "category": "people", + "name": "couple with heart: woman, woman, dark skin tone, medium skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f469-1f3fd" + }, + ":couple_with_heart_woman_woman_tone5_tone4:": { + "category": "people", + "name": "couple with heart: woman, woman, dark skin tone, medium-dark skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f469-1f3fe" + }, + ":couple_ww:": { + "category": "people", + "name": "couple with heart: woman, woman", + "unicode": "1f469-200d-2764-fe0f-200d-1f469" + }, + ":couplekiss:": { + "category": "people", + "name": "kiss", + "unicode": "1f48f" + }, + ":cow2:": { + "category": "nature", + "name": "cow", + "unicode": "1f404" + }, + ":cow:": { + "category": "nature", + "name": "cow face", + "unicode": "1f42e" + }, + ":cowboy:": { + "category": "people", + "name": "cowboy hat face", + "unicode": "1f920" + }, + ":crab:": { + "category": "nature", + "name": "crab", + "unicode": "1f980" + }, + ":crayon:": { + "category": "objects", + "name": "crayon", + "unicode": "1f58d" + }, + ":credit_card:": { + "category": "objects", + "name": "credit card", + "unicode": "1f4b3" + }, + ":crescent_moon:": { + "category": "nature", + "name": "crescent moon", + "unicode": "1f319" + }, + ":cricket:": { + "category": "nature", + "name": "cricket", + "unicode": "1f997" + }, + ":cricket_game:": { + "category": "activity", + "name": "cricket game", + "unicode": "1f3cf" + }, + ":crocodile:": { + "category": "nature", + "name": "crocodile", + "unicode": "1f40a" + }, + ":croissant:": { + "category": "food", + "name": "croissant", + "unicode": "1f950" + }, + ":cross:": { + "category": "symbols", + "name": "latin cross", + "unicode": "271d" + }, + ":crossed_flags:": { + "category": "flags", + "name": "crossed flags", + "unicode": "1f38c" + }, + ":crossed_swords:": { + "category": "objects", + "name": "crossed swords", + "unicode": "2694" + }, + ":crown:": { + "category": "people", + "name": "crown", + "unicode": "1f451" + }, + ":cruise_ship:": { + "category": "travel", + "name": "passenger ship", + "unicode": "1f6f3" + }, + ":crutch:": { + "category": "travel", + "name": "crutch", + "unicode": "1fa7c" + }, + ":cry:": { + "category": "people", + "name": "crying face", + "unicode": "1f622" + }, + ":crying_cat_face:": { + "category": "people", + "name": "crying cat", + "unicode": "1f63f" + }, + ":crystal_ball:": { + "category": "objects", + "name": "crystal ball", + "unicode": "1f52e" + }, + ":cucumber:": { + "category": "food", + "name": "cucumber", + "unicode": "1f952" + }, + ":cup_with_straw:": { + "category": "food", + "name": "cup with straw", + "unicode": "1f964" + }, + ":cupcake:": { + "category": "food", + "name": "cupcake", + "unicode": "1f9c1" + }, + ":cupid:": { + "category": "symbols", + "name": "heart with arrow", + "unicode": "1f498" + }, + ":curling_stone:": { + "category": "activity", + "name": "curling stone", + "unicode": "1f94c" + }, + ":curly_haired:": { + "category": "people", + "name": "curly hair", + "unicode": "1f9b1" + }, + ":curly_loop:": { + "category": "symbols", + "name": "curly loop", + "unicode": "27b0" + }, + ":currency_exchange:": { + "category": "symbols", + "name": "currency exchange", + "unicode": "1f4b1" + }, + ":curry:": { + "category": "food", + "name": "curry rice", + "unicode": "1f35b" + }, + ":custard:": { + "category": "food", + "name": "custard", + "unicode": "1f36e" + }, + ":customs:": { + "category": "symbols", + "name": "customs", + "unicode": "1f6c3" + }, + ":cut_of_meat:": { + "category": "food", + "name": "cut of meat", + "unicode": "1f969" + }, + ":cyclone:": { + "category": "symbols", + "name": "cyclone", + "unicode": "1f300" + }, + ":dagger:": { + "category": "objects", + "name": "dagger", + "unicode": "1f5e1" + }, + ":dancer:": { + "category": "people", + "name": "woman dancing", + "unicode": "1f483" + }, + ":dancer_tone1:": { + "category": "people", + "name": "woman dancing: light skin tone", + "unicode": "1f483-1f3fb" + }, + ":dancer_tone2:": { + "category": "people", + "name": "woman dancing: medium-light skin tone", + "unicode": "1f483-1f3fc" + }, + ":dancer_tone3:": { + "category": "people", + "name": "woman dancing: medium skin tone", + "unicode": "1f483-1f3fd" + }, + ":dancer_tone4:": { + "category": "people", + "name": "woman dancing: medium-dark skin tone", + "unicode": "1f483-1f3fe" + }, + ":dancer_tone5:": { + "category": "people", + "name": "woman dancing: dark skin tone", + "unicode": "1f483-1f3ff" + }, + ":dango:": { + "category": "food", + "name": "dango", + "unicode": "1f361" + }, + ":dark_sunglasses:": { + "category": "people", + "name": "sunglasses", + "unicode": "1f576" + }, + ":dart:": { + "category": "activity", + "name": "direct hit", + "unicode": "1f3af" + }, + ":dash:": { + "category": "nature", + "name": "dashing away", + "unicode": "1f4a8" + }, + ":date:": { + "category": "objects", + "name": "calendar", + "unicode": "1f4c5" + }, + ":deaf_man:": { + "category": "people", + "name": "deaf man", + "unicode": "1f9cf-200d-2642-fe0f" + }, + ":deaf_man_tone1:": { + "category": "people", + "name": "deaf man: light skin tone", + "unicode": "1f9cf-1f3fb-200d-2642-fe0f" + }, + ":deaf_man_tone2:": { + "category": "people", + "name": "deaf man: medium-light skin tone", + "unicode": "1f9cf-1f3fc-200d-2642-fe0f" + }, + ":deaf_man_tone3:": { + "category": "people", + "name": "deaf man: medium skin tone", + "unicode": "1f9cf-1f3fd-200d-2642-fe0f" + }, + ":deaf_man_tone4:": { + "category": "people", + "name": "deaf man: medium-dark skin tone", + "unicode": "1f9cf-1f3fe-200d-2642-fe0f" + }, + ":deaf_man_tone5:": { + "category": "people", + "name": "deaf man: dark skin tone", + "unicode": "1f9cf-1f3ff-200d-2642-fe0f" + }, + ":deaf_person:": { + "category": "people", + "name": "deaf person", + "unicode": "1f9cf" + }, + ":deaf_person_tone1:": { + "category": "people", + "name": "deaf person: light skin tone", + "unicode": "1f9cf-1f3fb" + }, + ":deaf_person_tone2:": { + "category": "people", + "name": "deaf person: medium-light skin tone", + "unicode": "1f9cf-1f3fc" + }, + ":deaf_person_tone3:": { + "category": "people", + "name": "deaf person: medium skin tone", + "unicode": "1f9cf-1f3fd" + }, + ":deaf_person_tone4:": { + "category": "people", + "name": "deaf person: medium-dark skin tone", + "unicode": "1f9cf-1f3fe" + }, + ":deaf_person_tone5:": { + "category": "people", + "name": "deaf person: dark skin tone", + "unicode": "1f9cf-1f3ff" + }, + ":deaf_woman:": { + "category": "people", + "name": "deaf woman", + "unicode": "1f9cf-200d-2640-fe0f" + }, + ":deaf_woman_tone1:": { + "category": "people", + "name": "deaf woman: light skin tone", + "unicode": "1f9cf-1f3fb-200d-2640-fe0f" + }, + ":deaf_woman_tone2:": { + "category": "people", + "name": "deaf woman: medium-light skin tone", + "unicode": "1f9cf-1f3fc-200d-2640-fe0f" + }, + ":deaf_woman_tone3:": { + "category": "people", + "name": "deaf woman: medium skin tone", + "unicode": "1f9cf-1f3fd-200d-2640-fe0f" + }, + ":deaf_woman_tone4:": { + "category": "people", + "name": "deaf woman: medium-dark skin tone", + "unicode": "1f9cf-1f3fe-200d-2640-fe0f" + }, + ":deaf_woman_tone5:": { + "category": "people", + "name": "deaf woman: dark skin tone", + "unicode": "1f9cf-1f3ff-200d-2640-fe0f" + }, + ":deciduous_tree:": { + "category": "nature", + "name": "deciduous tree", + "unicode": "1f333" + }, + ":deer:": { + "category": "nature", + "name": "deer", + "unicode": "1f98c" + }, + ":department_store:": { + "category": "travel", + "name": "department store", + "unicode": "1f3ec" + }, + ":desert:": { + "category": "travel", + "name": "desert", + "unicode": "1f3dc" + }, + ":desktop:": { + "category": "objects", + "name": "desktop computer", + "unicode": "1f5a5" + }, + ":detective:": { + "category": "people", + "name": "detective", + "unicode": "1f575" + }, + ":detective_tone1:": { + "category": "people", + "name": "detective: light skin tone", + "unicode": "1f575-1f3fb" + }, + ":detective_tone2:": { + "category": "people", + "name": "detective: medium-light skin tone", + "unicode": "1f575-1f3fc" + }, + ":detective_tone3:": { + "category": "people", + "name": "detective: medium skin tone", + "unicode": "1f575-1f3fd" + }, + ":detective_tone4:": { + "category": "people", + "name": "detective: medium-dark skin tone", + "unicode": "1f575-1f3fe" + }, + ":detective_tone5:": { + "category": "people", + "name": "detective: dark skin tone", + "unicode": "1f575-1f3ff" + }, + ":diamond_shape_with_a_dot_inside:": { + "category": "symbols", + "name": "diamond with a dot", + "unicode": "1f4a0" + }, + ":diamonds:": { + "category": "symbols", + "name": "diamond suit", + "unicode": "2666" + }, + ":disappointed:": { + "category": "people", + "name": "disappointed face", + "unicode": "1f61e" + }, + ":disappointed_relieved:": { + "category": "people", + "name": "sad but relieved face", + "unicode": "1f625" + }, + ":disguised_face:": { + "category": "people", + "name": "disguised face", + "unicode": "1f978" + }, + ":dividers:": { + "category": "objects", + "name": "card index dividers", + "unicode": "1f5c2" + }, + ":diving_mask:": { + "category": "activity", + "name": "diving mask", + "unicode": "1f93f" + }, + ":diya_lamp:": { + "category": "objects", + "name": "diya lamp", + "unicode": "1fa94" + }, + ":dizzy:": { + "category": "nature", + "name": "dizzy", + "unicode": "1f4ab" + }, + ":dizzy_face:": { + "category": "people", + "name": "dizzy face", + "unicode": "1f635" + }, + ":dna:": { + "category": "objects", + "name": "dna", + "unicode": "1f9ec" + }, + ":do_not_litter:": { + "category": "symbols", + "name": "no littering", + "unicode": "1f6af" + }, + ":dodo:": { + "category": "nature", + "name": "dodo", + "unicode": "1f9a4" + }, + ":dog2:": { + "category": "nature", + "name": "dog", + "unicode": "1f415" + }, + ":dog:": { + "category": "nature", + "name": "dog face", + "unicode": "1f436" + }, + ":dollar:": { + "category": "objects", + "name": "dollar banknote", + "unicode": "1f4b5" + }, + ":dolls:": { + "category": "objects", + "name": "Japanese dolls", + "unicode": "1f38e" + }, + ":dolphin:": { + "category": "nature", + "name": "dolphin", + "unicode": "1f42c" + }, + ":donkey:": { + "category": "nature", + "name": "donkey", + "unicode": "1facf" + }, + ":door:": { + "category": "objects", + "name": "door", + "unicode": "1f6aa" + }, + ":dotted_line_face:": { + "category": "people", + "name": "dotted line face", + "unicode": "1fae5" + }, + ":doughnut:": { + "category": "food", + "name": "doughnut", + "unicode": "1f369" + }, + ":dove:": { + "category": "nature", + "name": "dove", + "unicode": "1f54a" + }, + ":dragon:": { + "category": "nature", + "name": "dragon", + "unicode": "1f409" + }, + ":dragon_face:": { + "category": "nature", + "name": "dragon face", + "unicode": "1f432" + }, + ":dress:": { + "category": "people", + "name": "dress", + "unicode": "1f457" + }, + ":dromedary_camel:": { + "category": "nature", + "name": "camel", + "unicode": "1f42a" + }, + ":drooling_face:": { + "category": "people", + "name": "drooling face", + "unicode": "1f924" + }, + ":drop_of_blood:": { + "category": "objects", + "name": "drop of blood", + "unicode": "1fa78" + }, + ":droplet:": { + "category": "nature", + "name": "droplet", + "unicode": "1f4a7" + }, + ":drum:": { + "category": "activity", + "name": "drum", + "unicode": "1f941" + }, + ":duck:": { + "category": "nature", + "name": "duck", + "unicode": "1f986" + }, + ":dumpling:": { + "category": "food", + "name": "dumpling", + "unicode": "1f95f" + }, + ":dvd:": { + "category": "objects", + "name": "dvd", + "unicode": "1f4c0" + }, + ":e-mail:": { + "category": "objects", + "name": "e-mail", + "unicode": "1f4e7" + }, + ":eagle:": { + "category": "nature", + "name": "eagle", + "unicode": "1f985" + }, + ":ear:": { + "category": "people", + "name": "ear", + "unicode": "1f442" + }, + ":ear_of_rice:": { + "category": "nature", + "name": "sheaf of rice", + "unicode": "1f33e" + }, + ":ear_tone1:": { + "category": "people", + "name": "ear: light skin tone", + "unicode": "1f442-1f3fb" + }, + ":ear_tone2:": { + "category": "people", + "name": "ear: medium-light skin tone", + "unicode": "1f442-1f3fc" + }, + ":ear_tone3:": { + "category": "people", + "name": "ear: medium skin tone", + "unicode": "1f442-1f3fd" + }, + ":ear_tone4:": { + "category": "people", + "name": "ear: medium-dark skin tone", + "unicode": "1f442-1f3fe" + }, + ":ear_tone5:": { + "category": "people", + "name": "ear: dark skin tone", + "unicode": "1f442-1f3ff" + }, + ":ear_with_hearing_aid:": { + "category": "people", + "name": "ear with hearing aid", + "unicode": "1f9bb" + }, + ":ear_with_hearing_aid_tone1:": { + "category": "people", + "name": "ear with hearing aid: light skin tone", + "unicode": "1f9bb-1f3fb" + }, + ":ear_with_hearing_aid_tone2:": { + "category": "people", + "name": "ear with hearing aid: medium-light skin tone", + "unicode": "1f9bb-1f3fc" + }, + ":ear_with_hearing_aid_tone3:": { + "category": "people", + "name": "ear with hearing aid: medium skin tone", + "unicode": "1f9bb-1f3fd" + }, + ":ear_with_hearing_aid_tone4:": { + "category": "people", + "name": "ear with hearing aid: medium-dark skin tone", + "unicode": "1f9bb-1f3fe" + }, + ":ear_with_hearing_aid_tone5:": { + "category": "people", + "name": "ear with hearing aid: dark skin tone", + "unicode": "1f9bb-1f3ff" + }, + ":earth_africa:": { + "category": "nature", + "name": "globe showing Europe-Africa", + "unicode": "1f30d" + }, + ":earth_americas:": { + "category": "nature", + "name": "globe showing Americas", + "unicode": "1f30e" + }, + ":earth_asia:": { + "category": "nature", + "name": "globe showing Asia-Australia", + "unicode": "1f30f" + }, + ":egg:": { + "category": "food", + "name": "egg", + "unicode": "1f95a" + }, + ":eggplant:": { + "category": "food", + "name": "eggplant", + "unicode": "1f346" + }, + ":eight:": { + "category": "symbols", + "name": "keycap: 8", + "unicode": "38-20e3", + "unicode_alt": "0038-20e3" + }, + ":eight_pointed_black_star:": { + "category": "symbols", + "name": "eight-pointed star", + "unicode": "2734" + }, + ":eight_spoked_asterisk:": { + "category": "symbols", + "name": "eight-spoked asterisk", + "unicode": "2733" + }, + ":eject:": { + "category": "symbols", + "name": "eject button", + "unicode": "23cf" + }, + ":electric_plug:": { + "category": "objects", + "name": "electric plug", + "unicode": "1f50c" + }, + ":elephant:": { + "category": "nature", + "name": "elephant", + "unicode": "1f418" + }, + ":elevator:": { + "category": "symbols", + "name": "elevator", + "unicode": "1f6d7" + }, + ":elf:": { + "category": "people", + "name": "elf", + "unicode": "1f9dd" + }, + ":elf_tone1:": { + "category": "people", + "name": "elf: light skin tone", + "unicode": "1f9dd-1f3fb" + }, + ":elf_tone2:": { + "category": "people", + "name": "elf: medium-light skin tone", + "unicode": "1f9dd-1f3fc" + }, + ":elf_tone3:": { + "category": "people", + "name": "elf: medium skin tone", + "unicode": "1f9dd-1f3fd" + }, + ":elf_tone4:": { + "category": "people", + "name": "elf: medium-dark skin tone", + "unicode": "1f9dd-1f3fe" + }, + ":elf_tone5:": { + "category": "people", + "name": "elf: dark skin tone", + "unicode": "1f9dd-1f3ff" + }, + ":empty_nest:": { + "category": "nature", + "name": "empty nest", + "unicode": "1fab9" + }, + ":end:": { + "category": "symbols", + "name": "END arrow", + "unicode": "1f51a" + }, + ":england:": { + "category": "flags", + "name": "flag: England", + "unicode": "1f3f4-e0067-e0062-e0065-e006e-e0067-e007f" + }, + ":envelope:": { + "category": "objects", + "name": "envelope", + "unicode": "2709" + }, + ":envelope_with_arrow:": { + "category": "objects", + "name": "envelope with arrow", + "unicode": "1f4e9" + }, + ":euro:": { + "category": "objects", + "name": "euro banknote", + "unicode": "1f4b6" + }, + ":european_castle:": { + "category": "travel", + "name": "castle", + "unicode": "1f3f0" + }, + ":european_post_office:": { + "category": "travel", + "name": "post office", + "unicode": "1f3e4" + }, + ":evergreen_tree:": { + "category": "nature", + "name": "evergreen tree", + "unicode": "1f332" + }, + ":exclamation:": { + "category": "symbols", + "name": "exclamation mark", + "unicode": "2757" + }, + ":exploding_head:": { + "category": "people", + "name": "exploding head", + "unicode": "1f92f" + }, + ":expressionless:": { + "category": "people", + "name": "expressionless face", + "unicode": "1f611" + }, + ":eye:": { + "category": "people", + "name": "eye", + "unicode": "1f441" + }, + ":eye_in_speech_bubble:": { + "category": "symbols", + "name": "eye in speech bubble", + "unicode": "1f441-200d-1f5e8" + }, + ":eyeglasses:": { + "category": "people", + "name": "glasses", + "unicode": "1f453" + }, + ":eyes:": { + "category": "people", + "name": "eyes", + "unicode": "1f440" + }, + ":face_exhaling:": { + "category": "people", + "name": "face exhaling", + "unicode": "1f62e-200d-1f4a8" + }, + ":face_holding_back_tears:": { + "category": "people", + "name": "face holding back tears", + "unicode": "1f979" + }, + ":face_in_clouds:": { + "category": "people", + "name": "face in clouds", + "unicode": "1f636-200d-1f32b-fe0f" + }, + ":face_vomiting:": { + "category": "people", + "name": "face vomiting", + "unicode": "1f92e" + }, + ":face_with_bags_under_eyes:": { + "category": "people", + "name": "face with bags under eyes", + "unicode": "1fae9" + }, + ":face_with_diagonal_mouth:": { + "category": "people", + "name": "face with diagonal mouth", + "unicode": "1fae4" + }, + ":face_with_hand_over_mouth:": { + "category": "people", + "name": "face with hand over mouth", + "unicode": "1f92d" + }, + ":face_with_monocle:": { + "category": "people", + "name": "face with monocle", + "unicode": "1f9d0" + }, + ":face_with_open_eyes_and_hand_over_mouth:": { + "category": "people", + "name": "face with open eyes and hand over mouth", + "unicode": "1fae2" + }, + ":face_with_peeking_eye:": { + "category": "people", + "name": "face with peeking eye", + "unicode": "1fae3" + }, + ":face_with_raised_eyebrow:": { + "category": "people", + "name": "face with raised eyebrow", + "unicode": "1f928" + }, + ":face_with_spiral_eyes:": { + "category": "people", + "name": "face with spiral eyes", + "unicode": "1f635-200d-1f4ab" + }, + ":face_with_symbols_over_mouth:": { + "category": "people", + "name": "face with symbols on mouth", + "unicode": "1f92c" + }, + ":factory:": { + "category": "travel", + "name": "factory", + "unicode": "1f3ed" + }, + ":factory_worker:": { + "category": "people", + "name": "factory worker", + "unicode": "1f9d1-200d-1f3ed" + }, + ":factory_worker_tone1:": { + "category": "people", + "name": "factory worker: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f3ed" + }, + ":factory_worker_tone2:": { + "category": "people", + "name": "factory worker: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f3ed" + }, + ":factory_worker_tone3:": { + "category": "people", + "name": "factory worker: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f3ed" + }, + ":factory_worker_tone4:": { + "category": "people", + "name": "factory worker: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f3ed" + }, + ":factory_worker_tone5:": { + "category": "people", + "name": "factory worker: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f3ed" + }, + ":fairy:": { + "category": "people", + "name": "fairy", + "unicode": "1f9da" + }, + ":fairy_tone1:": { + "category": "people", + "name": "fairy: light skin tone", + "unicode": "1f9da-1f3fb" + }, + ":fairy_tone2:": { + "category": "people", + "name": "fairy: medium-light skin tone", + "unicode": "1f9da-1f3fc" + }, + ":fairy_tone3:": { + "category": "people", + "name": "fairy: medium skin tone", + "unicode": "1f9da-1f3fd" + }, + ":fairy_tone4:": { + "category": "people", + "name": "fairy: medium-dark skin tone", + "unicode": "1f9da-1f3fe" + }, + ":fairy_tone5:": { + "category": "people", + "name": "fairy: dark skin tone", + "unicode": "1f9da-1f3ff" + }, + ":falafel:": { + "category": "food", + "name": "falafel", + "unicode": "1f9c6" + }, + ":fallen_leaf:": { + "category": "nature", + "name": "fallen leaf", + "unicode": "1f342" + }, + ":family:": { + "category": "people", + "name": "family", + "unicode": "1f46a" + }, + ":family_adult_adult_child:": { + "category": "people", + "name": "family: adult, adult, child", + "unicode": "1f9d1-200d-1f9d1-200d-1f9d2" + }, + ":family_adult_adult_child_child:": { + "category": "people", + "name": "family: adult, adult, child, child", + "unicode": "1f9d1-200d-1f9d1-200d-1f9d2-200d-1f9d2" + }, + ":family_adult_child:": { + "category": "people", + "name": "family: adult, child", + "unicode": "1f9d1-200d-1f9d2" + }, + ":family_adult_child_child:": { + "category": "people", + "name": "family: adult, child, child", + "unicode": "1f9d1-200d-1f9d2-200d-1f9d2" + }, + ":family_man_boy:": { + "category": "people", + "name": "family: man, boy", + "unicode": "1f468-200d-1f466" + }, + ":family_man_boy_boy:": { + "category": "people", + "name": "family: man, boy, boy", + "unicode": "1f468-200d-1f466-200d-1f466" + }, + ":family_man_girl:": { + "category": "people", + "name": "family: man, girl", + "unicode": "1f468-200d-1f467" + }, + ":family_man_girl_boy:": { + "category": "people", + "name": "family: man, girl, boy", + "unicode": "1f468-200d-1f467-200d-1f466" + }, + ":family_man_girl_girl:": { + "category": "people", + "name": "family: man, girl, girl", + "unicode": "1f468-200d-1f467-200d-1f467" + }, + ":family_man_woman_boy:": { + "category": "people", + "name": "family: man, woman, boy", + "unicode": "1f468-200d-1f469-200d-1f466" + }, + ":family_mmb:": { + "category": "people", + "name": "family: man, man, boy", + "unicode": "1f468-200d-1f468-200d-1f466" + }, + ":family_mmbb:": { + "category": "people", + "name": "family: man, man, boy, boy", + "unicode": "1f468-200d-1f468-200d-1f466-200d-1f466" + }, + ":family_mmg:": { + "category": "people", + "name": "family: man, man, girl", + "unicode": "1f468-200d-1f468-200d-1f467" + }, + ":family_mmgb:": { + "category": "people", + "name": "family: man, man, girl, boy", + "unicode": "1f468-200d-1f468-200d-1f467-200d-1f466" + }, + ":family_mmgg:": { + "category": "people", + "name": "family: man, man, girl, girl", + "unicode": "1f468-200d-1f468-200d-1f467-200d-1f467" + }, + ":family_mwbb:": { + "category": "people", + "name": "family: man, woman, boy, boy", + "unicode": "1f468-200d-1f469-200d-1f466-200d-1f466" + }, + ":family_mwg:": { + "category": "people", + "name": "family: man, woman, girl", + "unicode": "1f468-200d-1f469-200d-1f467" + }, + ":family_mwgb:": { + "category": "people", + "name": "family: man, woman, girl, boy", + "unicode": "1f468-200d-1f469-200d-1f467-200d-1f466" + }, + ":family_mwgg:": { + "category": "people", + "name": "family: man, woman, girl, girl", + "unicode": "1f468-200d-1f469-200d-1f467-200d-1f467" + }, + ":family_woman_boy:": { + "category": "people", + "name": "family: woman, boy", + "unicode": "1f469-200d-1f466" + }, + ":family_woman_boy_boy:": { + "category": "people", + "name": "family: woman, boy, boy", + "unicode": "1f469-200d-1f466-200d-1f466" + }, + ":family_woman_girl:": { + "category": "people", + "name": "family: woman, girl", + "unicode": "1f469-200d-1f467" + }, + ":family_woman_girl_boy:": { + "category": "people", + "name": "family: woman, girl, boy", + "unicode": "1f469-200d-1f467-200d-1f466" + }, + ":family_woman_girl_girl:": { + "category": "people", + "name": "family: woman, girl, girl", + "unicode": "1f469-200d-1f467-200d-1f467" + }, + ":family_wwb:": { + "category": "people", + "name": "family: woman, woman, boy", + "unicode": "1f469-200d-1f469-200d-1f466" + }, + ":family_wwbb:": { + "category": "people", + "name": "family: woman, woman, boy, boy", + "unicode": "1f469-200d-1f469-200d-1f466-200d-1f466" + }, + ":family_wwg:": { + "category": "people", + "name": "family: woman, woman, girl", + "unicode": "1f469-200d-1f469-200d-1f467" + }, + ":family_wwgb:": { + "category": "people", + "name": "family: woman, woman, girl, boy", + "unicode": "1f469-200d-1f469-200d-1f467-200d-1f466" + }, + ":family_wwgg:": { + "category": "people", + "name": "family: woman, woman, girl, girl", + "unicode": "1f469-200d-1f469-200d-1f467-200d-1f467" + }, + ":farmer:": { + "category": "people", + "name": "farmer", + "unicode": "1f9d1-200d-1f33e" + }, + ":farmer_tone1:": { + "category": "people", + "name": "farmer: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f33e" + }, + ":farmer_tone2:": { + "category": "people", + "name": "farmer: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f33e" + }, + ":farmer_tone3:": { + "category": "people", + "name": "farmer: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f33e" + }, + ":farmer_tone4:": { + "category": "people", + "name": "farmer: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f33e" + }, + ":farmer_tone5:": { + "category": "people", + "name": "farmer: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f33e" + }, + ":fast_forward:": { + "category": "symbols", + "name": "fast-forward button", + "unicode": "23e9" + }, + ":fax:": { + "category": "objects", + "name": "fax machine", + "unicode": "1f4e0" + }, + ":fearful:": { + "category": "people", + "name": "fearful face", + "unicode": "1f628" + }, + ":feather:": { + "category": "nature", + "name": "feather", + "unicode": "1fab6" + }, + ":feet:": { + "category": "nature", + "name": "paw prints", + "unicode": "1f43e" + }, + ":female_sign:": { + "category": "symbols", + "name": "female sign", + "unicode": "2640" + }, + ":ferris_wheel:": { + "category": "travel", + "name": "ferris wheel", + "unicode": "1f3a1" + }, + ":ferry:": { + "category": "travel", + "name": "ferry", + "unicode": "26f4" + }, + ":field_hockey:": { + "category": "activity", + "name": "field hockey", + "unicode": "1f3d1" + }, + ":file_cabinet:": { + "category": "objects", + "name": "file cabinet", + "unicode": "1f5c4" + }, + ":file_folder:": { + "category": "objects", + "name": "file folder", + "unicode": "1f4c1" + }, + ":film_frames:": { + "category": "objects", + "name": "film frames", + "unicode": "1f39e" + }, + ":fingerprint:": { + "category": "people", + "name": "fingerprint", + "unicode": "1fac6" + }, + ":fingers_crossed:": { + "category": "people", + "name": "crossed fingers", + "unicode": "1f91e" + }, + ":fingers_crossed_tone1:": { + "category": "people", + "name": "crossed fingers: light skin tone", + "unicode": "1f91e-1f3fb" + }, + ":fingers_crossed_tone2:": { + "category": "people", + "name": "crossed fingers: medium-light skin tone", + "unicode": "1f91e-1f3fc" + }, + ":fingers_crossed_tone3:": { + "category": "people", + "name": "crossed fingers: medium skin tone", + "unicode": "1f91e-1f3fd" + }, + ":fingers_crossed_tone4:": { + "category": "people", + "name": "crossed fingers: medium-dark skin tone", + "unicode": "1f91e-1f3fe" + }, + ":fingers_crossed_tone5:": { + "category": "people", + "name": "crossed fingers: dark skin tone", + "unicode": "1f91e-1f3ff" + }, + ":fire:": { + "category": "nature", + "name": "fire", + "unicode": "1f525" + }, + ":fire_engine:": { + "category": "travel", + "name": "fire engine", + "unicode": "1f692" + }, + ":fire_extinguisher:": { + "category": "objects", + "name": "fire extinguisher", + "unicode": "1f9ef" + }, + ":firecracker:": { + "category": "objects", + "name": "firecracker", + "unicode": "1f9e8" + }, + ":firefighter:": { + "category": "people", + "name": "firefighter", + "unicode": "1f9d1-200d-1f692" + }, + ":firefighter_tone1:": { + "category": "people", + "name": "firefighter: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f692" + }, + ":firefighter_tone2:": { + "category": "people", + "name": "firefighter: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f692" + }, + ":firefighter_tone3:": { + "category": "people", + "name": "firefighter: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f692" + }, + ":firefighter_tone4:": { + "category": "people", + "name": "firefighter: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f692" + }, + ":firefighter_tone5:": { + "category": "people", + "name": "firefighter: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f692" + }, + ":fireworks:": { + "category": "travel", + "name": "fireworks", + "unicode": "1f386" + }, + ":first_place:": { + "category": "activity", + "name": "1st place medal", + "unicode": "1f947" + }, + ":first_quarter_moon:": { + "category": "nature", + "name": "first quarter moon", + "unicode": "1f313" + }, + ":first_quarter_moon_with_face:": { + "category": "nature", + "name": "first quarter moon face", + "unicode": "1f31b" + }, + ":fish:": { + "category": "nature", + "name": "fish", + "unicode": "1f41f" + }, + ":fish_cake:": { + "category": "food", + "name": "fish cake with swirl", + "unicode": "1f365" + }, + ":fishing_pole_and_fish:": { + "category": "activity", + "name": "fishing pole", + "unicode": "1f3a3" + }, + ":fist:": { + "category": "people", + "name": "raised fist", + "unicode": "270a" + }, + ":fist_tone1:": { + "category": "people", + "name": "raised fist: light skin tone", + "unicode": "270a-1f3fb" + }, + ":fist_tone2:": { + "category": "people", + "name": "raised fist: medium-light skin tone", + "unicode": "270a-1f3fc" + }, + ":fist_tone3:": { + "category": "people", + "name": "raised fist: medium skin tone", + "unicode": "270a-1f3fd" + }, + ":fist_tone4:": { + "category": "people", + "name": "raised fist: medium-dark skin tone", + "unicode": "270a-1f3fe" + }, + ":fist_tone5:": { + "category": "people", + "name": "raised fist: dark skin tone", + "unicode": "270a-1f3ff" + }, + ":five:": { + "category": "symbols", + "name": "keycap: 5", + "unicode": "35-20e3", + "unicode_alt": "0035-20e3" + }, + ":flag_ac:": { + "category": "flags", + "name": "flag: Ascension Island", + "unicode": "1f1e6-1f1e8" + }, + ":flag_ad:": { + "category": "flags", + "name": "flag: Andorra", + "unicode": "1f1e6-1f1e9" + }, + ":flag_ae:": { + "category": "flags", + "name": "flag: United Arab Emirates", + "unicode": "1f1e6-1f1ea" + }, + ":flag_af:": { + "category": "flags", + "name": "flag: Afghanistan", + "unicode": "1f1e6-1f1eb" + }, + ":flag_ag:": { + "category": "flags", + "name": "flag: Antigua & Barbuda", + "unicode": "1f1e6-1f1ec" + }, + ":flag_ai:": { + "category": "flags", + "name": "flag: Anguilla", + "unicode": "1f1e6-1f1ee" + }, + ":flag_al:": { + "category": "flags", + "name": "flag: Albania", + "unicode": "1f1e6-1f1f1" + }, + ":flag_am:": { + "category": "flags", + "name": "flag: Armenia", + "unicode": "1f1e6-1f1f2" + }, + ":flag_ao:": { + "category": "flags", + "name": "flag: Angola", + "unicode": "1f1e6-1f1f4" + }, + ":flag_aq:": { + "category": "flags", + "name": "flag: Antarctica", + "unicode": "1f1e6-1f1f6" + }, + ":flag_ar:": { + "category": "flags", + "name": "flag: Argentina", + "unicode": "1f1e6-1f1f7" + }, + ":flag_as:": { + "category": "flags", + "name": "flag: American Samoa", + "unicode": "1f1e6-1f1f8" + }, + ":flag_at:": { + "category": "flags", + "name": "flag: Austria", + "unicode": "1f1e6-1f1f9" + }, + ":flag_au:": { + "category": "flags", + "name": "flag: Australia", + "unicode": "1f1e6-1f1fa" + }, + ":flag_aw:": { + "category": "flags", + "name": "flag: Aruba", + "unicode": "1f1e6-1f1fc" + }, + ":flag_ax:": { + "category": "flags", + "name": "flag: \u00c5land Islands", + "unicode": "1f1e6-1f1fd" + }, + ":flag_az:": { + "category": "flags", + "name": "flag: Azerbaijan", + "unicode": "1f1e6-1f1ff" + }, + ":flag_ba:": { + "category": "flags", + "name": "flag: Bosnia & Herzegovina", + "unicode": "1f1e7-1f1e6" + }, + ":flag_bb:": { + "category": "flags", + "name": "flag: Barbados", + "unicode": "1f1e7-1f1e7" + }, + ":flag_bd:": { + "category": "flags", + "name": "flag: Bangladesh", + "unicode": "1f1e7-1f1e9" + }, + ":flag_be:": { + "category": "flags", + "name": "flag: Belgium", + "unicode": "1f1e7-1f1ea" + }, + ":flag_bf:": { + "category": "flags", + "name": "flag: Burkina Faso", + "unicode": "1f1e7-1f1eb" + }, + ":flag_bg:": { + "category": "flags", + "name": "flag: Bulgaria", + "unicode": "1f1e7-1f1ec" + }, + ":flag_bh:": { + "category": "flags", + "name": "flag: Bahrain", + "unicode": "1f1e7-1f1ed" + }, + ":flag_bi:": { + "category": "flags", + "name": "flag: Burundi", + "unicode": "1f1e7-1f1ee" + }, + ":flag_bj:": { + "category": "flags", + "name": "flag: Benin", + "unicode": "1f1e7-1f1ef" + }, + ":flag_bl:": { + "category": "flags", + "name": "flag: St. Barth\u00e9lemy", + "unicode": "1f1e7-1f1f1" + }, + ":flag_black:": { + "category": "flags", + "name": "black flag", + "unicode": "1f3f4" + }, + ":flag_bm:": { + "category": "flags", + "name": "flag: Bermuda", + "unicode": "1f1e7-1f1f2" + }, + ":flag_bn:": { + "category": "flags", + "name": "flag: Brunei", + "unicode": "1f1e7-1f1f3" + }, + ":flag_bo:": { + "category": "flags", + "name": "flag: Bolivia", + "unicode": "1f1e7-1f1f4" + }, + ":flag_bq:": { + "category": "flags", + "name": "flag: Caribbean Netherlands", + "unicode": "1f1e7-1f1f6" + }, + ":flag_br:": { + "category": "flags", + "name": "flag: Brazil", + "unicode": "1f1e7-1f1f7" + }, + ":flag_bs:": { + "category": "flags", + "name": "flag: Bahamas", + "unicode": "1f1e7-1f1f8" + }, + ":flag_bt:": { + "category": "flags", + "name": "flag: Bhutan", + "unicode": "1f1e7-1f1f9" + }, + ":flag_bv:": { + "category": "flags", + "name": "flag: Bouvet Island", + "unicode": "1f1e7-1f1fb" + }, + ":flag_bw:": { + "category": "flags", + "name": "flag: Botswana", + "unicode": "1f1e7-1f1fc" + }, + ":flag_by:": { + "category": "flags", + "name": "flag: Belarus", + "unicode": "1f1e7-1f1fe" + }, + ":flag_bz:": { + "category": "flags", + "name": "flag: Belize", + "unicode": "1f1e7-1f1ff" + }, + ":flag_ca:": { + "category": "flags", + "name": "flag: Canada", + "unicode": "1f1e8-1f1e6" + }, + ":flag_cc:": { + "category": "flags", + "name": "flag: Cocos (Keeling) Islands", + "unicode": "1f1e8-1f1e8" + }, + ":flag_cd:": { + "category": "flags", + "name": "flag: Congo - Kinshasa", + "unicode": "1f1e8-1f1e9" + }, + ":flag_cf:": { + "category": "flags", + "name": "flag: Central African Republic", + "unicode": "1f1e8-1f1eb" + }, + ":flag_cg:": { + "category": "flags", + "name": "flag: Congo - Brazzaville", + "unicode": "1f1e8-1f1ec" + }, + ":flag_ch:": { + "category": "flags", + "name": "flag: Switzerland", + "unicode": "1f1e8-1f1ed" + }, + ":flag_ci:": { + "category": "flags", + "name": "flag: C\u00f4te d\u2019Ivoire", + "unicode": "1f1e8-1f1ee" + }, + ":flag_ck:": { + "category": "flags", + "name": "flag: Cook Islands", + "unicode": "1f1e8-1f1f0" + }, + ":flag_cl:": { + "category": "flags", + "name": "flag: Chile", + "unicode": "1f1e8-1f1f1" + }, + ":flag_cm:": { + "category": "flags", + "name": "flag: Cameroon", + "unicode": "1f1e8-1f1f2" + }, + ":flag_cn:": { + "category": "flags", + "name": "flag: China", + "unicode": "1f1e8-1f1f3" + }, + ":flag_co:": { + "category": "flags", + "name": "flag: Colombia", + "unicode": "1f1e8-1f1f4" + }, + ":flag_cp:": { + "category": "flags", + "name": "flag: Clipperton Island", + "unicode": "1f1e8-1f1f5" + }, + ":flag_cr:": { + "category": "flags", + "name": "flag: Costa Rica", + "unicode": "1f1e8-1f1f7" + }, + ":flag_cu:": { + "category": "flags", + "name": "flag: Cuba", + "unicode": "1f1e8-1f1fa" + }, + ":flag_cv:": { + "category": "flags", + "name": "flag: Cape Verde", + "unicode": "1f1e8-1f1fb" + }, + ":flag_cw:": { + "category": "flags", + "name": "flag: Cura\u00e7ao", + "unicode": "1f1e8-1f1fc" + }, + ":flag_cx:": { + "category": "flags", + "name": "flag: Christmas Island", + "unicode": "1f1e8-1f1fd" + }, + ":flag_cy:": { + "category": "flags", + "name": "flag: Cyprus", + "unicode": "1f1e8-1f1fe" + }, + ":flag_cz:": { + "category": "flags", + "name": "flag: Czechia", + "unicode": "1f1e8-1f1ff" + }, + ":flag_de:": { + "category": "flags", + "name": "flag: Germany", + "unicode": "1f1e9-1f1ea" + }, + ":flag_dg:": { + "category": "flags", + "name": "flag: Diego Garcia", + "unicode": "1f1e9-1f1ec" + }, + ":flag_dj:": { + "category": "flags", + "name": "flag: Djibouti", + "unicode": "1f1e9-1f1ef" + }, + ":flag_dk:": { + "category": "flags", + "name": "flag: Denmark", + "unicode": "1f1e9-1f1f0" + }, + ":flag_dm:": { + "category": "flags", + "name": "flag: Dominica", + "unicode": "1f1e9-1f1f2" + }, + ":flag_do:": { + "category": "flags", + "name": "flag: Dominican Republic", + "unicode": "1f1e9-1f1f4" + }, + ":flag_dz:": { + "category": "flags", + "name": "flag: Algeria", + "unicode": "1f1e9-1f1ff" + }, + ":flag_ea:": { + "category": "flags", + "name": "flag: Ceuta & Melilla", + "unicode": "1f1ea-1f1e6" + }, + ":flag_ec:": { + "category": "flags", + "name": "flag: Ecuador", + "unicode": "1f1ea-1f1e8" + }, + ":flag_ee:": { + "category": "flags", + "name": "flag: Estonia", + "unicode": "1f1ea-1f1ea" + }, + ":flag_eg:": { + "category": "flags", + "name": "flag: Egypt", + "unicode": "1f1ea-1f1ec" + }, + ":flag_eh:": { + "category": "flags", + "name": "flag: Western Sahara", + "unicode": "1f1ea-1f1ed" + }, + ":flag_er:": { + "category": "flags", + "name": "flag: Eritrea", + "unicode": "1f1ea-1f1f7" + }, + ":flag_es:": { + "category": "flags", + "name": "flag: Spain", + "unicode": "1f1ea-1f1f8" + }, + ":flag_et:": { + "category": "flags", + "name": "flag: Ethiopia", + "unicode": "1f1ea-1f1f9" + }, + ":flag_eu:": { + "category": "flags", + "name": "flag: European Union", + "unicode": "1f1ea-1f1fa" + }, + ":flag_fi:": { + "category": "flags", + "name": "flag: Finland", + "unicode": "1f1eb-1f1ee" + }, + ":flag_fj:": { + "category": "flags", + "name": "flag: Fiji", + "unicode": "1f1eb-1f1ef" + }, + ":flag_fk:": { + "category": "flags", + "name": "flag: Falkland Islands", + "unicode": "1f1eb-1f1f0" + }, + ":flag_fm:": { + "category": "flags", + "name": "flag: Micronesia", + "unicode": "1f1eb-1f1f2" + }, + ":flag_fo:": { + "category": "flags", + "name": "flag: Faroe Islands", + "unicode": "1f1eb-1f1f4" + }, + ":flag_fr:": { + "category": "flags", + "name": "flag: France", + "unicode": "1f1eb-1f1f7" + }, + ":flag_ga:": { + "category": "flags", + "name": "flag: Gabon", + "unicode": "1f1ec-1f1e6" + }, + ":flag_gb:": { + "category": "flags", + "name": "flag: United Kingdom", + "unicode": "1f1ec-1f1e7" + }, + ":flag_gd:": { + "category": "flags", + "name": "flag: Grenada", + "unicode": "1f1ec-1f1e9" + }, + ":flag_ge:": { + "category": "flags", + "name": "flag: Georgia", + "unicode": "1f1ec-1f1ea" + }, + ":flag_gf:": { + "category": "flags", + "name": "flag: French Guiana", + "unicode": "1f1ec-1f1eb" + }, + ":flag_gg:": { + "category": "flags", + "name": "flag: Guernsey", + "unicode": "1f1ec-1f1ec" + }, + ":flag_gh:": { + "category": "flags", + "name": "flag: Ghana", + "unicode": "1f1ec-1f1ed" + }, + ":flag_gi:": { + "category": "flags", + "name": "flag: Gibraltar", + "unicode": "1f1ec-1f1ee" + }, + ":flag_gl:": { + "category": "flags", + "name": "flag: Greenland", + "unicode": "1f1ec-1f1f1" + }, + ":flag_gm:": { + "category": "flags", + "name": "flag: Gambia", + "unicode": "1f1ec-1f1f2" + }, + ":flag_gn:": { + "category": "flags", + "name": "flag: Guinea", + "unicode": "1f1ec-1f1f3" + }, + ":flag_gp:": { + "category": "flags", + "name": "flag: Guadeloupe", + "unicode": "1f1ec-1f1f5" + }, + ":flag_gq:": { + "category": "flags", + "name": "flag: Equatorial Guinea", + "unicode": "1f1ec-1f1f6" + }, + ":flag_gr:": { + "category": "flags", + "name": "flag: Greece", + "unicode": "1f1ec-1f1f7" + }, + ":flag_gs:": { + "category": "flags", + "name": "flag: South Georgia & South Sandwich Islands", + "unicode": "1f1ec-1f1f8" + }, + ":flag_gt:": { + "category": "flags", + "name": "flag: Guatemala", + "unicode": "1f1ec-1f1f9" + }, + ":flag_gu:": { + "category": "flags", + "name": "flag: Guam", + "unicode": "1f1ec-1f1fa" + }, + ":flag_gw:": { + "category": "flags", + "name": "flag: Guinea-Bissau", + "unicode": "1f1ec-1f1fc" + }, + ":flag_gy:": { + "category": "flags", + "name": "flag: Guyana", + "unicode": "1f1ec-1f1fe" + }, + ":flag_hk:": { + "category": "flags", + "name": "flag: Hong Kong SAR China", + "unicode": "1f1ed-1f1f0" + }, + ":flag_hm:": { + "category": "flags", + "name": "flag: Heard & McDonald Islands", + "unicode": "1f1ed-1f1f2" + }, + ":flag_hn:": { + "category": "flags", + "name": "flag: Honduras", + "unicode": "1f1ed-1f1f3" + }, + ":flag_hr:": { + "category": "flags", + "name": "flag: Croatia", + "unicode": "1f1ed-1f1f7" + }, + ":flag_ht:": { + "category": "flags", + "name": "flag: Haiti", + "unicode": "1f1ed-1f1f9" + }, + ":flag_hu:": { + "category": "flags", + "name": "flag: Hungary", + "unicode": "1f1ed-1f1fa" + }, + ":flag_ic:": { + "category": "flags", + "name": "flag: Canary Islands", + "unicode": "1f1ee-1f1e8" + }, + ":flag_id:": { + "category": "flags", + "name": "flag: Indonesia", + "unicode": "1f1ee-1f1e9" + }, + ":flag_ie:": { + "category": "flags", + "name": "flag: Ireland", + "unicode": "1f1ee-1f1ea" + }, + ":flag_il:": { + "category": "flags", + "name": "flag: Israel", + "unicode": "1f1ee-1f1f1" + }, + ":flag_im:": { + "category": "flags", + "name": "flag: Isle of Man", + "unicode": "1f1ee-1f1f2" + }, + ":flag_in:": { + "category": "flags", + "name": "flag: India", + "unicode": "1f1ee-1f1f3" + }, + ":flag_io:": { + "category": "flags", + "name": "flag: British Indian Ocean Territory", + "unicode": "1f1ee-1f1f4" + }, + ":flag_iq:": { + "category": "flags", + "name": "flag: Iraq", + "unicode": "1f1ee-1f1f6" + }, + ":flag_ir:": { + "category": "flags", + "name": "flag: Iran", + "unicode": "1f1ee-1f1f7" + }, + ":flag_is:": { + "category": "flags", + "name": "flag: Iceland", + "unicode": "1f1ee-1f1f8" + }, + ":flag_it:": { + "category": "flags", + "name": "flag: Italy", + "unicode": "1f1ee-1f1f9" + }, + ":flag_je:": { + "category": "flags", + "name": "flag: Jersey", + "unicode": "1f1ef-1f1ea" + }, + ":flag_jm:": { + "category": "flags", + "name": "flag: Jamaica", + "unicode": "1f1ef-1f1f2" + }, + ":flag_jo:": { + "category": "flags", + "name": "flag: Jordan", + "unicode": "1f1ef-1f1f4" + }, + ":flag_jp:": { + "category": "flags", + "name": "flag: Japan", + "unicode": "1f1ef-1f1f5" + }, + ":flag_ke:": { + "category": "flags", + "name": "flag: Kenya", + "unicode": "1f1f0-1f1ea" + }, + ":flag_kg:": { + "category": "flags", + "name": "flag: Kyrgyzstan", + "unicode": "1f1f0-1f1ec" + }, + ":flag_kh:": { + "category": "flags", + "name": "flag: Cambodia", + "unicode": "1f1f0-1f1ed" + }, + ":flag_ki:": { + "category": "flags", + "name": "flag: Kiribati", + "unicode": "1f1f0-1f1ee" + }, + ":flag_km:": { + "category": "flags", + "name": "flag: Comoros", + "unicode": "1f1f0-1f1f2" + }, + ":flag_kn:": { + "category": "flags", + "name": "flag: St. Kitts & Nevis", + "unicode": "1f1f0-1f1f3" + }, + ":flag_kp:": { + "category": "flags", + "name": "flag: North Korea", + "unicode": "1f1f0-1f1f5" + }, + ":flag_kr:": { + "category": "flags", + "name": "flag: South Korea", + "unicode": "1f1f0-1f1f7" + }, + ":flag_kw:": { + "category": "flags", + "name": "flag: Kuwait", + "unicode": "1f1f0-1f1fc" + }, + ":flag_ky:": { + "category": "flags", + "name": "flag: Cayman Islands", + "unicode": "1f1f0-1f1fe" + }, + ":flag_kz:": { + "category": "flags", + "name": "flag: Kazakhstan", + "unicode": "1f1f0-1f1ff" + }, + ":flag_la:": { + "category": "flags", + "name": "flag: Laos", + "unicode": "1f1f1-1f1e6" + }, + ":flag_lb:": { + "category": "flags", + "name": "flag: Lebanon", + "unicode": "1f1f1-1f1e7" + }, + ":flag_lc:": { + "category": "flags", + "name": "flag: St. Lucia", + "unicode": "1f1f1-1f1e8" + }, + ":flag_li:": { + "category": "flags", + "name": "flag: Liechtenstein", + "unicode": "1f1f1-1f1ee" + }, + ":flag_lk:": { + "category": "flags", + "name": "flag: Sri Lanka", + "unicode": "1f1f1-1f1f0" + }, + ":flag_lr:": { + "category": "flags", + "name": "flag: Liberia", + "unicode": "1f1f1-1f1f7" + }, + ":flag_ls:": { + "category": "flags", + "name": "flag: Lesotho", + "unicode": "1f1f1-1f1f8" + }, + ":flag_lt:": { + "category": "flags", + "name": "flag: Lithuania", + "unicode": "1f1f1-1f1f9" + }, + ":flag_lu:": { + "category": "flags", + "name": "flag: Luxembourg", + "unicode": "1f1f1-1f1fa" + }, + ":flag_lv:": { + "category": "flags", + "name": "flag: Latvia", + "unicode": "1f1f1-1f1fb" + }, + ":flag_ly:": { + "category": "flags", + "name": "flag: Libya", + "unicode": "1f1f1-1f1fe" + }, + ":flag_ma:": { + "category": "flags", + "name": "flag: Morocco", + "unicode": "1f1f2-1f1e6" + }, + ":flag_mc:": { + "category": "flags", + "name": "flag: Monaco", + "unicode": "1f1f2-1f1e8" + }, + ":flag_md:": { + "category": "flags", + "name": "flag: Moldova", + "unicode": "1f1f2-1f1e9" + }, + ":flag_me:": { + "category": "flags", + "name": "flag: Montenegro", + "unicode": "1f1f2-1f1ea" + }, + ":flag_mf:": { + "category": "flags", + "name": "flag: St. Martin", + "unicode": "1f1f2-1f1eb" + }, + ":flag_mg:": { + "category": "flags", + "name": "flag: Madagascar", + "unicode": "1f1f2-1f1ec" + }, + ":flag_mh:": { + "category": "flags", + "name": "flag: Marshall Islands", + "unicode": "1f1f2-1f1ed" + }, + ":flag_mk:": { + "category": "flags", + "name": "flag: Macedonia", + "unicode": "1f1f2-1f1f0" + }, + ":flag_ml:": { + "category": "flags", + "name": "flag: Mali", + "unicode": "1f1f2-1f1f1" + }, + ":flag_mm:": { + "category": "flags", + "name": "flag: Myanmar (Burma)", + "unicode": "1f1f2-1f1f2" + }, + ":flag_mn:": { + "category": "flags", + "name": "flag: Mongolia", + "unicode": "1f1f2-1f1f3" + }, + ":flag_mo:": { + "category": "flags", + "name": "flag: Macao SAR China", + "unicode": "1f1f2-1f1f4" + }, + ":flag_mp:": { + "category": "flags", + "name": "flag: Northern Mariana Islands", + "unicode": "1f1f2-1f1f5" + }, + ":flag_mq:": { + "category": "flags", + "name": "flag: Martinique", + "unicode": "1f1f2-1f1f6" + }, + ":flag_mr:": { + "category": "flags", + "name": "flag: Mauritania", + "unicode": "1f1f2-1f1f7" + }, + ":flag_ms:": { + "category": "flags", + "name": "flag: Montserrat", + "unicode": "1f1f2-1f1f8" + }, + ":flag_mt:": { + "category": "flags", + "name": "flag: Malta", + "unicode": "1f1f2-1f1f9" + }, + ":flag_mu:": { + "category": "flags", + "name": "flag: Mauritius", + "unicode": "1f1f2-1f1fa" + }, + ":flag_mv:": { + "category": "flags", + "name": "flag: Maldives", + "unicode": "1f1f2-1f1fb" + }, + ":flag_mw:": { + "category": "flags", + "name": "flag: Malawi", + "unicode": "1f1f2-1f1fc" + }, + ":flag_mx:": { + "category": "flags", + "name": "flag: Mexico", + "unicode": "1f1f2-1f1fd" + }, + ":flag_my:": { + "category": "flags", + "name": "flag: Malaysia", + "unicode": "1f1f2-1f1fe" + }, + ":flag_mz:": { + "category": "flags", + "name": "flag: Mozambique", + "unicode": "1f1f2-1f1ff" + }, + ":flag_na:": { + "category": "flags", + "name": "flag: Namibia", + "unicode": "1f1f3-1f1e6" + }, + ":flag_nc:": { + "category": "flags", + "name": "flag: New Caledonia", + "unicode": "1f1f3-1f1e8" + }, + ":flag_ne:": { + "category": "flags", + "name": "flag: Niger", + "unicode": "1f1f3-1f1ea" + }, + ":flag_nf:": { + "category": "flags", + "name": "flag: Norfolk Island", + "unicode": "1f1f3-1f1eb" + }, + ":flag_ng:": { + "category": "flags", + "name": "flag: Nigeria", + "unicode": "1f1f3-1f1ec" + }, + ":flag_ni:": { + "category": "flags", + "name": "flag: Nicaragua", + "unicode": "1f1f3-1f1ee" + }, + ":flag_nl:": { + "category": "flags", + "name": "flag: Netherlands", + "unicode": "1f1f3-1f1f1" + }, + ":flag_no:": { + "category": "flags", + "name": "flag: Norway", + "unicode": "1f1f3-1f1f4" + }, + ":flag_np:": { + "category": "flags", + "name": "flag: Nepal", + "unicode": "1f1f3-1f1f5" + }, + ":flag_nr:": { + "category": "flags", + "name": "flag: Nauru", + "unicode": "1f1f3-1f1f7" + }, + ":flag_nu:": { + "category": "flags", + "name": "flag: Niue", + "unicode": "1f1f3-1f1fa" + }, + ":flag_nz:": { + "category": "flags", + "name": "flag: New Zealand", + "unicode": "1f1f3-1f1ff" + }, + ":flag_om:": { + "category": "flags", + "name": "flag: Oman", + "unicode": "1f1f4-1f1f2" + }, + ":flag_pa:": { + "category": "flags", + "name": "flag: Panama", + "unicode": "1f1f5-1f1e6" + }, + ":flag_pe:": { + "category": "flags", + "name": "flag: Peru", + "unicode": "1f1f5-1f1ea" + }, + ":flag_pf:": { + "category": "flags", + "name": "flag: French Polynesia", + "unicode": "1f1f5-1f1eb" + }, + ":flag_pg:": { + "category": "flags", + "name": "flag: Papua New Guinea", + "unicode": "1f1f5-1f1ec" + }, + ":flag_ph:": { + "category": "flags", + "name": "flag: Philippines", + "unicode": "1f1f5-1f1ed" + }, + ":flag_pk:": { + "category": "flags", + "name": "flag: Pakistan", + "unicode": "1f1f5-1f1f0" + }, + ":flag_pl:": { + "category": "flags", + "name": "flag: Poland", + "unicode": "1f1f5-1f1f1" + }, + ":flag_pm:": { + "category": "flags", + "name": "flag: St. Pierre & Miquelon", + "unicode": "1f1f5-1f1f2" + }, + ":flag_pn:": { + "category": "flags", + "name": "flag: Pitcairn Islands", + "unicode": "1f1f5-1f1f3" + }, + ":flag_pr:": { + "category": "flags", + "name": "flag: Puerto Rico", + "unicode": "1f1f5-1f1f7" + }, + ":flag_ps:": { + "category": "flags", + "name": "flag: Palestinian Territories", + "unicode": "1f1f5-1f1f8" + }, + ":flag_pt:": { + "category": "flags", + "name": "flag: Portugal", + "unicode": "1f1f5-1f1f9" + }, + ":flag_pw:": { + "category": "flags", + "name": "flag: Palau", + "unicode": "1f1f5-1f1fc" + }, + ":flag_py:": { + "category": "flags", + "name": "flag: Paraguay", + "unicode": "1f1f5-1f1fe" + }, + ":flag_qa:": { + "category": "flags", + "name": "flag: Qatar", + "unicode": "1f1f6-1f1e6" + }, + ":flag_re:": { + "category": "flags", + "name": "flag: R\u00e9union", + "unicode": "1f1f7-1f1ea" + }, + ":flag_ro:": { + "category": "flags", + "name": "flag: Romania", + "unicode": "1f1f7-1f1f4" + }, + ":flag_rs:": { + "category": "flags", + "name": "flag: Serbia", + "unicode": "1f1f7-1f1f8" + }, + ":flag_ru:": { + "category": "flags", + "name": "flag: Russia", + "unicode": "1f1f7-1f1fa" + }, + ":flag_rw:": { + "category": "flags", + "name": "flag: Rwanda", + "unicode": "1f1f7-1f1fc" + }, + ":flag_sa:": { + "category": "flags", + "name": "flag: Saudi Arabia", + "unicode": "1f1f8-1f1e6" + }, + ":flag_sark:": { + "category": "flags", + "name": "flag: Sark", + "unicode": "1f1e8-1f1f6" + }, + ":flag_sb:": { + "category": "flags", + "name": "flag: Solomon Islands", + "unicode": "1f1f8-1f1e7" + }, + ":flag_sc:": { + "category": "flags", + "name": "flag: Seychelles", + "unicode": "1f1f8-1f1e8" + }, + ":flag_sd:": { + "category": "flags", + "name": "flag: Sudan", + "unicode": "1f1f8-1f1e9" + }, + ":flag_se:": { + "category": "flags", + "name": "flag: Sweden", + "unicode": "1f1f8-1f1ea" + }, + ":flag_sg:": { + "category": "flags", + "name": "flag: Singapore", + "unicode": "1f1f8-1f1ec" + }, + ":flag_sh:": { + "category": "flags", + "name": "flag: St. Helena", + "unicode": "1f1f8-1f1ed" + }, + ":flag_si:": { + "category": "flags", + "name": "flag: Slovenia", + "unicode": "1f1f8-1f1ee" + }, + ":flag_sj:": { + "category": "flags", + "name": "flag: Svalbard & Jan Mayen", + "unicode": "1f1f8-1f1ef" + }, + ":flag_sk:": { + "category": "flags", + "name": "flag: Slovakia", + "unicode": "1f1f8-1f1f0" + }, + ":flag_sl:": { + "category": "flags", + "name": "flag: Sierra Leone", + "unicode": "1f1f8-1f1f1" + }, + ":flag_sm:": { + "category": "flags", + "name": "flag: San Marino", + "unicode": "1f1f8-1f1f2" + }, + ":flag_sn:": { + "category": "flags", + "name": "flag: Senegal", + "unicode": "1f1f8-1f1f3" + }, + ":flag_so:": { + "category": "flags", + "name": "flag: Somalia", + "unicode": "1f1f8-1f1f4" + }, + ":flag_sr:": { + "category": "flags", + "name": "flag: Suriname", + "unicode": "1f1f8-1f1f7" + }, + ":flag_ss:": { + "category": "flags", + "name": "flag: South Sudan", + "unicode": "1f1f8-1f1f8" + }, + ":flag_st:": { + "category": "flags", + "name": "flag: S\u00e3o Tom\u00e9 & Pr\u00edncipe", + "unicode": "1f1f8-1f1f9" + }, + ":flag_sv:": { + "category": "flags", + "name": "flag: El Salvador", + "unicode": "1f1f8-1f1fb" + }, + ":flag_sx:": { + "category": "flags", + "name": "flag: Sint Maarten", + "unicode": "1f1f8-1f1fd" + }, + ":flag_sy:": { + "category": "flags", + "name": "flag: Syria", + "unicode": "1f1f8-1f1fe" + }, + ":flag_sz:": { + "category": "flags", + "name": "flag: Eswatini", + "unicode": "1f1f8-1f1ff" + }, + ":flag_ta:": { + "category": "flags", + "name": "flag: Tristan da Cunha", + "unicode": "1f1f9-1f1e6" + }, + ":flag_tc:": { + "category": "flags", + "name": "flag: Turks & Caicos Islands", + "unicode": "1f1f9-1f1e8" + }, + ":flag_td:": { + "category": "flags", + "name": "flag: Chad", + "unicode": "1f1f9-1f1e9" + }, + ":flag_tf:": { + "category": "flags", + "name": "flag: French Southern Territories", + "unicode": "1f1f9-1f1eb" + }, + ":flag_tg:": { + "category": "flags", + "name": "flag: Togo", + "unicode": "1f1f9-1f1ec" + }, + ":flag_th:": { + "category": "flags", + "name": "flag: Thailand", + "unicode": "1f1f9-1f1ed" + }, + ":flag_tj:": { + "category": "flags", + "name": "flag: Tajikistan", + "unicode": "1f1f9-1f1ef" + }, + ":flag_tk:": { + "category": "flags", + "name": "flag: Tokelau", + "unicode": "1f1f9-1f1f0" + }, + ":flag_tl:": { + "category": "flags", + "name": "flag: Timor-Leste", + "unicode": "1f1f9-1f1f1" + }, + ":flag_tm:": { + "category": "flags", + "name": "flag: Turkmenistan", + "unicode": "1f1f9-1f1f2" + }, + ":flag_tn:": { + "category": "flags", + "name": "flag: Tunisia", + "unicode": "1f1f9-1f1f3" + }, + ":flag_to:": { + "category": "flags", + "name": "flag: Tonga", + "unicode": "1f1f9-1f1f4" + }, + ":flag_tr:": { + "category": "flags", + "name": "flag: Turkey", + "unicode": "1f1f9-1f1f7" + }, + ":flag_tt:": { + "category": "flags", + "name": "flag: Trinidad & Tobago", + "unicode": "1f1f9-1f1f9" + }, + ":flag_tv:": { + "category": "flags", + "name": "flag: Tuvalu", + "unicode": "1f1f9-1f1fb" + }, + ":flag_tw:": { + "category": "flags", + "name": "flag: Taiwan", + "unicode": "1f1f9-1f1fc" + }, + ":flag_tz:": { + "category": "flags", + "name": "flag: Tanzania", + "unicode": "1f1f9-1f1ff" + }, + ":flag_ua:": { + "category": "flags", + "name": "flag: Ukraine", + "unicode": "1f1fa-1f1e6" + }, + ":flag_ug:": { + "category": "flags", + "name": "flag: Uganda", + "unicode": "1f1fa-1f1ec" + }, + ":flag_um:": { + "category": "flags", + "name": "flag: U.S. Outlying Islands", + "unicode": "1f1fa-1f1f2" + }, + ":flag_us:": { + "category": "flags", + "name": "flag: United States", + "unicode": "1f1fa-1f1f8" + }, + ":flag_uy:": { + "category": "flags", + "name": "flag: Uruguay", + "unicode": "1f1fa-1f1fe" + }, + ":flag_uz:": { + "category": "flags", + "name": "flag: Uzbekistan", + "unicode": "1f1fa-1f1ff" + }, + ":flag_va:": { + "category": "flags", + "name": "flag: Vatican City", + "unicode": "1f1fb-1f1e6" + }, + ":flag_vc:": { + "category": "flags", + "name": "flag: St. Vincent & Grenadines", + "unicode": "1f1fb-1f1e8" + }, + ":flag_ve:": { + "category": "flags", + "name": "flag: Venezuela", + "unicode": "1f1fb-1f1ea" + }, + ":flag_vg:": { + "category": "flags", + "name": "flag: British Virgin Islands", + "unicode": "1f1fb-1f1ec" + }, + ":flag_vi:": { + "category": "flags", + "name": "flag: U.S. Virgin Islands", + "unicode": "1f1fb-1f1ee" + }, + ":flag_vn:": { + "category": "flags", + "name": "flag: Vietnam", + "unicode": "1f1fb-1f1f3" + }, + ":flag_vu:": { + "category": "flags", + "name": "flag: Vanuatu", + "unicode": "1f1fb-1f1fa" + }, + ":flag_wf:": { + "category": "flags", + "name": "flag: Wallis & Futuna", + "unicode": "1f1fc-1f1eb" + }, + ":flag_white:": { + "category": "flags", + "name": "white flag", + "unicode": "1f3f3" + }, + ":flag_ws:": { + "category": "flags", + "name": "flag: Samoa", + "unicode": "1f1fc-1f1f8" + }, + ":flag_xk:": { + "category": "flags", + "name": "flag: Kosovo", + "unicode": "1f1fd-1f1f0" + }, + ":flag_ye:": { + "category": "flags", + "name": "flag: Yemen", + "unicode": "1f1fe-1f1ea" + }, + ":flag_yt:": { + "category": "flags", + "name": "flag: Mayotte", + "unicode": "1f1fe-1f1f9" + }, + ":flag_za:": { + "category": "flags", + "name": "flag: South Africa", + "unicode": "1f1ff-1f1e6" + }, + ":flag_zm:": { + "category": "flags", + "name": "flag: Zambia", + "unicode": "1f1ff-1f1f2" + }, + ":flag_zw:": { + "category": "flags", + "name": "flag: Zimbabwe", + "unicode": "1f1ff-1f1fc" + }, + ":flags:": { + "category": "objects", + "name": "carp streamer", + "unicode": "1f38f" + }, + ":flamingo:": { + "category": "nature", + "name": "flamingo", + "unicode": "1f9a9" + }, + ":flashlight:": { + "category": "objects", + "name": "flashlight", + "unicode": "1f526" + }, + ":flatbread:": { + "category": "food", + "name": "flatbread", + "unicode": "1fad3" + }, + ":fleur-de-lis:": { + "category": "symbols", + "name": "fleur-de-lis", + "unicode": "269c" + }, + ":floppy_disk:": { + "category": "objects", + "name": "floppy disk", + "unicode": "1f4be" + }, + ":flower_playing_cards:": { + "category": "symbols", + "name": "flower playing cards", + "unicode": "1f3b4" + }, + ":flushed:": { + "category": "people", + "name": "flushed face", + "unicode": "1f633" + }, + ":flute:": { + "category": "activity", + "name": "flute", + "unicode": "1fa88" + }, + ":fly:": { + "category": "nature", + "name": "fly", + "unicode": "1fab0" + }, + ":flying_disc:": { + "category": "activity", + "name": "flying disc", + "unicode": "1f94f" + }, + ":flying_saucer:": { + "category": "travel", + "name": "flying saucer", + "unicode": "1f6f8" + }, + ":fog:": { + "category": "nature", + "name": "fog", + "unicode": "1f32b" + }, + ":foggy:": { + "category": "travel", + "name": "foggy", + "unicode": "1f301" + }, + ":folding_hand_fan:": { + "category": "objects", + "name": "folding hand fan", + "unicode": "1faad" + }, + ":fondue:": { + "category": "food", + "name": "fondue", + "unicode": "1fad5" + }, + ":foot:": { + "category": "people", + "name": "foot", + "unicode": "1f9b6" + }, + ":foot_tone1:": { + "category": "people", + "name": "foot: light skin tone", + "unicode": "1f9b6-1f3fb" + }, + ":foot_tone2:": { + "category": "people", + "name": "foot: medium-light skin tone", + "unicode": "1f9b6-1f3fc" + }, + ":foot_tone3:": { + "category": "people", + "name": "foot: medium skin tone", + "unicode": "1f9b6-1f3fd" + }, + ":foot_tone4:": { + "category": "people", + "name": "foot: medium-dark skin tone", + "unicode": "1f9b6-1f3fe" + }, + ":foot_tone5:": { + "category": "people", + "name": "foot: dark skin tone", + "unicode": "1f9b6-1f3ff" + }, + ":football:": { + "category": "activity", + "name": "american football", + "unicode": "1f3c8" + }, + ":footprints:": { + "category": "people", + "name": "footprints", + "unicode": "1f463" + }, + ":fork_and_knife:": { + "category": "food", + "name": "fork and knife", + "unicode": "1f374" + }, + ":fork_knife_plate:": { + "category": "food", + "name": "fork and knife with plate", + "unicode": "1f37d" + }, + ":fortune_cookie:": { + "category": "food", + "name": "fortune cookie", + "unicode": "1f960" + }, + ":fountain:": { + "category": "travel", + "name": "fountain", + "unicode": "26f2" + }, + ":four:": { + "category": "symbols", + "name": "keycap: 4", + "unicode": "34-20e3", + "unicode_alt": "0034-20e3" + }, + ":four_leaf_clover:": { + "category": "nature", + "name": "four leaf clover", + "unicode": "1f340" + }, + ":fox:": { + "category": "nature", + "name": "fox", + "unicode": "1f98a" + }, + ":frame_photo:": { + "category": "objects", + "name": "framed picture", + "unicode": "1f5bc" + }, + ":free:": { + "category": "symbols", + "name": "FREE button", + "unicode": "1f193" + }, + ":french_bread:": { + "category": "food", + "name": "baguette bread", + "unicode": "1f956" + }, + ":fried_shrimp:": { + "category": "food", + "name": "fried shrimp", + "unicode": "1f364" + }, + ":fries:": { + "category": "food", + "name": "french fries", + "unicode": "1f35f" + }, + ":frog:": { + "category": "nature", + "name": "frog", + "unicode": "1f438" + }, + ":frowning2:": { + "category": "people", + "name": "frowning face", + "unicode": "2639" + }, + ":frowning:": { + "category": "people", + "name": "frowning face with open mouth", + "unicode": "1f626" + }, + ":fuelpump:": { + "category": "travel", + "name": "fuel pump", + "unicode": "26fd" + }, + ":full_moon:": { + "category": "nature", + "name": "full moon", + "unicode": "1f315" + }, + ":full_moon_with_face:": { + "category": "nature", + "name": "full moon face", + "unicode": "1f31d" + }, + ":game_die:": { + "category": "activity", + "name": "game die", + "unicode": "1f3b2" + }, + ":garlic:": { + "category": "food", + "name": "garlic", + "unicode": "1f9c4" + }, + ":gear:": { + "category": "objects", + "name": "gear", + "unicode": "2699" + }, + ":gem:": { + "category": "objects", + "name": "gem stone", + "unicode": "1f48e" + }, + ":gemini:": { + "category": "symbols", + "name": "Gemini", + "unicode": "264a" + }, + ":genie:": { + "category": "people", + "name": "genie", + "unicode": "1f9de" + }, + ":ghost:": { + "category": "people", + "name": "ghost", + "unicode": "1f47b" + }, + ":gift:": { + "category": "objects", + "name": "wrapped gift", + "unicode": "1f381" + }, + ":gift_heart:": { + "category": "symbols", + "name": "heart with ribbon", + "unicode": "1f49d" + }, + ":ginger_root:": { + "category": "food", + "name": "ginger root", + "unicode": "1fada" + }, + ":giraffe:": { + "category": "nature", + "name": "giraffe", + "unicode": "1f992" + }, + ":girl:": { + "category": "people", + "name": "girl", + "unicode": "1f467" + }, + ":girl_tone1:": { + "category": "people", + "name": "girl: light skin tone", + "unicode": "1f467-1f3fb" + }, + ":girl_tone2:": { + "category": "people", + "name": "girl: medium-light skin tone", + "unicode": "1f467-1f3fc" + }, + ":girl_tone3:": { + "category": "people", + "name": "girl: medium skin tone", + "unicode": "1f467-1f3fd" + }, + ":girl_tone4:": { + "category": "people", + "name": "girl: medium-dark skin tone", + "unicode": "1f467-1f3fe" + }, + ":girl_tone5:": { + "category": "people", + "name": "girl: dark skin tone", + "unicode": "1f467-1f3ff" + }, + ":globe_with_meridians:": { + "category": "symbols", + "name": "globe with meridians", + "unicode": "1f310" + }, + ":gloves:": { + "category": "people", + "name": "gloves", + "unicode": "1f9e4" + }, + ":goal:": { + "category": "activity", + "name": "goal net", + "unicode": "1f945" + }, + ":goat:": { + "category": "nature", + "name": "goat", + "unicode": "1f410" + }, + ":goggles:": { + "category": "people", + "name": "goggles", + "unicode": "1f97d" + }, + ":golf:": { + "category": "activity", + "name": "flag in hole", + "unicode": "26f3" + }, + ":goose:": { + "category": "nature", + "name": "goose", + "unicode": "1fabf" + }, + ":gorilla:": { + "category": "nature", + "name": "gorilla", + "unicode": "1f98d" + }, + ":grapes:": { + "category": "food", + "name": "grapes", + "unicode": "1f347" + }, + ":green_apple:": { + "category": "food", + "name": "green apple", + "unicode": "1f34f" + }, + ":green_book:": { + "category": "objects", + "name": "green book", + "unicode": "1f4d7" + }, + ":green_circle:": { + "category": "symbols", + "name": "green circle", + "unicode": "1f7e2" + }, + ":green_heart:": { + "category": "symbols", + "name": "green heart", + "unicode": "1f49a" + }, + ":green_square:": { + "category": "symbols", + "name": "green square", + "unicode": "1f7e9" + }, + ":grey_exclamation:": { + "category": "symbols", + "name": "white exclamation mark", + "unicode": "2755" + }, + ":grey_heart:": { + "category": "symbols", + "name": "grey heart", + "unicode": "1fa76" + }, + ":grey_question:": { + "category": "symbols", + "name": "white question mark", + "unicode": "2754" + }, + ":grimacing:": { + "category": "people", + "name": "grimacing face", + "unicode": "1f62c" + }, + ":grin:": { + "category": "people", + "name": "beaming face with smiling eyes", + "unicode": "1f601" + }, + ":grinning:": { + "category": "people", + "name": "grinning face", + "unicode": "1f600" + }, + ":guard:": { + "category": "people", + "name": "guard", + "unicode": "1f482" + }, + ":guard_tone1:": { + "category": "people", + "name": "guard: light skin tone", + "unicode": "1f482-1f3fb" + }, + ":guard_tone2:": { + "category": "people", + "name": "guard: medium-light skin tone", + "unicode": "1f482-1f3fc" + }, + ":guard_tone3:": { + "category": "people", + "name": "guard: medium skin tone", + "unicode": "1f482-1f3fd" + }, + ":guard_tone4:": { + "category": "people", + "name": "guard: medium-dark skin tone", + "unicode": "1f482-1f3fe" + }, + ":guard_tone5:": { + "category": "people", + "name": "guard: dark skin tone", + "unicode": "1f482-1f3ff" + }, + ":guide_dog:": { + "category": "nature", + "name": "guide dog", + "unicode": "1f9ae" + }, + ":guitar:": { + "category": "activity", + "name": "guitar", + "unicode": "1f3b8" + }, + ":gun:": { + "category": "objects", + "name": "pistol", + "unicode": "1f52b" + }, + ":hair_pick:": { + "category": "objects", + "name": "hair pick", + "unicode": "1faae" + }, + ":hamburger:": { + "category": "food", + "name": "hamburger", + "unicode": "1f354" + }, + ":hammer:": { + "category": "objects", + "name": "hammer", + "unicode": "1f528" + }, + ":hammer_pick:": { + "category": "objects", + "name": "hammer and pick", + "unicode": "2692" + }, + ":hamsa:": { + "category": "objects", + "name": "hamsa", + "unicode": "1faac" + }, + ":hamster:": { + "category": "nature", + "name": "hamster", + "unicode": "1f439" + }, + ":hand_splayed:": { + "category": "people", + "name": "hand with fingers splayed", + "unicode": "1f590" + }, + ":hand_splayed_tone1:": { + "category": "people", + "name": "hand with fingers splayed: light skin tone", + "unicode": "1f590-1f3fb" + }, + ":hand_splayed_tone2:": { + "category": "people", + "name": "hand with fingers splayed: medium-light skin tone", + "unicode": "1f590-1f3fc" + }, + ":hand_splayed_tone3:": { + "category": "people", + "name": "hand with fingers splayed: medium skin tone", + "unicode": "1f590-1f3fd" + }, + ":hand_splayed_tone4:": { + "category": "people", + "name": "hand with fingers splayed: medium-dark skin tone", + "unicode": "1f590-1f3fe" + }, + ":hand_splayed_tone5:": { + "category": "people", + "name": "hand with fingers splayed: dark skin tone", + "unicode": "1f590-1f3ff" + }, + ":hand_with_index_finger_and_thumb_crossed:": { + "category": "people", + "name": "hand with index finger and thumb crossed", + "unicode": "1faf0" + }, + ":hand_with_index_finger_and_thumb_crossed_tone1:": { + "category": "people", + "name": "hand with index finger and thumb crossed: light skin tone", + "unicode": "1faf0-1f3fb" + }, + ":hand_with_index_finger_and_thumb_crossed_tone2:": { + "category": "people", + "name": "hand with index finger and thumb crossed: medium-light skin tone", + "unicode": "1faf0-1f3fc" + }, + ":hand_with_index_finger_and_thumb_crossed_tone3:": { + "category": "people", + "name": "hand with index finger and thumb crossed: medium skin tone", + "unicode": "1faf0-1f3fd" + }, + ":hand_with_index_finger_and_thumb_crossed_tone4:": { + "category": "people", + "name": "hand with index finger and thumb crossed: medium-dark skin tone", + "unicode": "1faf0-1f3fe" + }, + ":hand_with_index_finger_and_thumb_crossed_tone5:": { + "category": "people", + "name": "hand with index finger and thumb crossed: dark skin tone", + "unicode": "1faf0-1f3ff" + }, + ":handbag:": { + "category": "people", + "name": "handbag", + "unicode": "1f45c" + }, + ":handshake:": { + "category": "people", + "name": "handshake", + "unicode": "1f91d" + }, + ":handshake_tone1:": { + "category": "people", + "name": "handshake: light skin tone", + "unicode": "1f91d-1f3fb" + }, + ":handshake_tone1_tone2:": { + "category": "people", + "name": "handshake: light skin tone, medium-light skin tone", + "unicode": "1faf1-1f3fb-200d-1faf2-1f3fc" + }, + ":handshake_tone1_tone3:": { + "category": "people", + "name": "handshake: light skin tone, medium skin tone", + "unicode": "1faf1-1f3fb-200d-1faf2-1f3fd" + }, + ":handshake_tone1_tone4:": { + "category": "people", + "name": "handshake: light skin tone, medium-dark skin tone", + "unicode": "1faf1-1f3fb-200d-1faf2-1f3fe" + }, + ":handshake_tone1_tone5:": { + "category": "people", + "name": "handshake: light skin tone, dark skin tone", + "unicode": "1faf1-1f3fb-200d-1faf2-1f3ff" + }, + ":handshake_tone2:": { + "category": "people", + "name": "handshake: medium-light skin tone", + "unicode": "1f91d-1f3fc" + }, + ":handshake_tone2_tone1:": { + "category": "people", + "name": "handshake: medium-light skin tone, light skin tone", + "unicode": "1faf1-1f3fc-200d-1faf2-1f3fb" + }, + ":handshake_tone2_tone3:": { + "category": "people", + "name": "handshake: medium-light skin tone, medium skin tone", + "unicode": "1faf1-1f3fc-200d-1faf2-1f3fd" + }, + ":handshake_tone2_tone4:": { + "category": "people", + "name": "handshake: medium-light skin tone, medium-dark skin tone", + "unicode": "1faf1-1f3fc-200d-1faf2-1f3fe" + }, + ":handshake_tone2_tone5:": { + "category": "people", + "name": "handshake: medium-light skin tone, dark skin tone", + "unicode": "1faf1-1f3fc-200d-1faf2-1f3ff" + }, + ":handshake_tone3:": { + "category": "people", + "name": "handshake: medium skin tone", + "unicode": "1f91d-1f3fd" + }, + ":handshake_tone3_tone1:": { + "category": "people", + "name": "handshake: medium skin tone, light skin tone", + "unicode": "1faf1-1f3fd-200d-1faf2-1f3fb" + }, + ":handshake_tone3_tone2:": { + "category": "people", + "name": "handshake: medium skin tone, medium-light skin tone", + "unicode": "1faf1-1f3fd-200d-1faf2-1f3fc" + }, + ":handshake_tone3_tone4:": { + "category": "people", + "name": "handshake: medium skin tone, medium-dark skin tone", + "unicode": "1faf1-1f3fd-200d-1faf2-1f3fe" + }, + ":handshake_tone3_tone5:": { + "category": "people", + "name": "handshake: medium skin tone, dark skin tone", + "unicode": "1faf1-1f3fd-200d-1faf2-1f3ff" + }, + ":handshake_tone4:": { + "category": "people", + "name": "handshake: medium-dark skin tone", + "unicode": "1f91d-1f3fe" + }, + ":handshake_tone4_tone1:": { + "category": "people", + "name": "handshake: medium-dark skin tone, light skin tone", + "unicode": "1faf1-1f3fe-200d-1faf2-1f3fb" + }, + ":handshake_tone4_tone2:": { + "category": "people", + "name": "handshake: medium-dark skin tone, medium-light skin tone", + "unicode": "1faf1-1f3fe-200d-1faf2-1f3fc" + }, + ":handshake_tone4_tone3:": { + "category": "people", + "name": "handshake: medium-dark skin tone, medium skin tone", + "unicode": "1faf1-1f3fe-200d-1faf2-1f3fd" + }, + ":handshake_tone4_tone5:": { + "category": "people", + "name": "handshake: medium-dark skin tone, dark skin tone", + "unicode": "1faf1-1f3fe-200d-1faf2-1f3ff" + }, + ":handshake_tone5:": { + "category": "people", + "name": "handshake: dark skin tone", + "unicode": "1f91d-1f3ff" + }, + ":handshake_tone5_tone1:": { + "category": "people", + "name": "handshake: dark skin tone, light skin tone", + "unicode": "1faf1-1f3ff-200d-1faf2-1f3fb" + }, + ":handshake_tone5_tone2:": { + "category": "people", + "name": "handshake: dark skin tone, medium-light skin tone", + "unicode": "1faf1-1f3ff-200d-1faf2-1f3fc" + }, + ":handshake_tone5_tone3:": { + "category": "people", + "name": "handshake: dark skin tone, medium skin tone", + "unicode": "1faf1-1f3ff-200d-1faf2-1f3fd" + }, + ":handshake_tone5_tone4:": { + "category": "people", + "name": "handshake: dark skin tone, medium-dark skin tone", + "unicode": "1faf1-1f3ff-200d-1faf2-1f3fe" + }, + ":harp:": { + "category": "activity", + "name": "harp", + "unicode": "1fa89" + }, + ":hash:": { + "category": "symbols", + "name": "keycap: pound", + "unicode": "23-20e3", + "unicode_alt": "0023-20e3" + }, + ":hatched_chick:": { + "category": "nature", + "name": "front-facing baby chick", + "unicode": "1f425" + }, + ":hatching_chick:": { + "category": "nature", + "name": "hatching chick", + "unicode": "1f423" + }, + ":head_bandage:": { + "category": "people", + "name": "face with head-bandage", + "unicode": "1f915" + }, + ":head_shaking_horizontally:": { + "category": "people", + "name": "head shaking horizontally", + "unicode": "1f642-200d-2194-fe0f" + }, + ":head_shaking_vertically:": { + "category": "people", + "name": "head shaking vertically", + "unicode": "1f642-200d-2195-fe0f" + }, + ":headphones:": { + "category": "activity", + "name": "headphone", + "unicode": "1f3a7" + }, + ":headstone:": { + "category": "objects", + "name": "headstone", + "unicode": "1faa6" + }, + ":health_worker:": { + "category": "people", + "name": "health worker", + "unicode": "1f9d1-200d-2695-fe0f" + }, + ":health_worker_tone1:": { + "category": "people", + "name": "health worker: light skin tone", + "unicode": "1f9d1-1f3fb-200d-2695-fe0f" + }, + ":health_worker_tone2:": { + "category": "people", + "name": "health worker: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-2695-fe0f" + }, + ":health_worker_tone3:": { + "category": "people", + "name": "health worker: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-2695-fe0f" + }, + ":health_worker_tone4:": { + "category": "people", + "name": "health worker: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-2695-fe0f" + }, + ":health_worker_tone5:": { + "category": "people", + "name": "health worker: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-2695-fe0f" + }, + ":hear_no_evil:": { + "category": "nature", + "name": "hear-no-evil monkey", + "unicode": "1f649" + }, + ":heart:": { + "category": "symbols", + "name": "red heart", + "unicode": "2764" + }, + ":heart_decoration:": { + "category": "symbols", + "name": "heart decoration", + "unicode": "1f49f" + }, + ":heart_exclamation:": { + "category": "symbols", + "name": "heart exclamation", + "unicode": "2763" + }, + ":heart_eyes:": { + "category": "people", + "name": "smiling face with heart-eyes", + "unicode": "1f60d" + }, + ":heart_eyes_cat:": { + "category": "people", + "name": "smiling cat with heart-eyes", + "unicode": "1f63b" + }, + ":heart_hands:": { + "category": "people", + "name": "heart hands", + "unicode": "1faf6" + }, + ":heart_hands_tone1:": { + "category": "people", + "name": "heart hands: light skin tone", + "unicode": "1faf6-1f3fb" + }, + ":heart_hands_tone2:": { + "category": "people", + "name": "heart hands: medium-light skin tone", + "unicode": "1faf6-1f3fc" + }, + ":heart_hands_tone3:": { + "category": "people", + "name": "heart hands: medium skin tone", + "unicode": "1faf6-1f3fd" + }, + ":heart_hands_tone4:": { + "category": "people", + "name": "heart hands: medium-dark skin tone", + "unicode": "1faf6-1f3fe" + }, + ":heart_hands_tone5:": { + "category": "people", + "name": "heart hands: dark skin tone", + "unicode": "1faf6-1f3ff" + }, + ":heart_on_fire:": { + "category": "symbols", + "name": "heart on fire", + "unicode": "2764-fe0f-200d-1f525" + }, + ":heartbeat:": { + "category": "symbols", + "name": "beating heart", + "unicode": "1f493" + }, + ":heartpulse:": { + "category": "symbols", + "name": "growing heart", + "unicode": "1f497" + }, + ":hearts:": { + "category": "symbols", + "name": "heart suit", + "unicode": "2665" + }, + ":heavy_check_mark:": { + "category": "symbols", + "name": "check mark", + "unicode": "2714" + }, + ":heavy_division_sign:": { + "category": "symbols", + "name": "division sign", + "unicode": "2797" + }, + ":heavy_dollar_sign:": { + "category": "symbols", + "name": "heavy dollar sign", + "unicode": "1f4b2" + }, + ":heavy_equals_sign:": { + "category": "symbols", + "name": "heavy equals sign", + "unicode": "1f7f0" + }, + ":heavy_minus_sign:": { + "category": "symbols", + "name": "minus sign", + "unicode": "2796" + }, + ":heavy_multiplication_x:": { + "category": "symbols", + "name": "multiplication sign", + "unicode": "2716" + }, + ":heavy_plus_sign:": { + "category": "symbols", + "name": "plus sign", + "unicode": "2795" + }, + ":hedgehog:": { + "category": "nature", + "name": "hedgehog", + "unicode": "1f994" + }, + ":helicopter:": { + "category": "travel", + "name": "helicopter", + "unicode": "1f681" + }, + ":helmet_with_cross:": { + "category": "people", + "name": "rescue worker\u2019s helmet", + "unicode": "26d1" + }, + ":herb:": { + "category": "nature", + "name": "herb", + "unicode": "1f33f" + }, + ":hibiscus:": { + "category": "nature", + "name": "hibiscus", + "unicode": "1f33a" + }, + ":high_brightness:": { + "category": "symbols", + "name": "bright button", + "unicode": "1f506" + }, + ":high_heel:": { + "category": "people", + "name": "high-heeled shoe", + "unicode": "1f460" + }, + ":hiking_boot:": { + "category": "people", + "name": "hiking boot", + "unicode": "1f97e" + }, + ":hindu_temple:": { + "category": "travel", + "name": "hindu temple", + "unicode": "1f6d5" + }, + ":hippopotamus:": { + "category": "nature", + "name": "hippopotamus", + "unicode": "1f99b" + }, + ":hockey:": { + "category": "activity", + "name": "ice hockey", + "unicode": "1f3d2" + }, + ":hole:": { + "category": "objects", + "name": "hole", + "unicode": "1f573" + }, + ":homes:": { + "category": "travel", + "name": "houses", + "unicode": "1f3d8" + }, + ":honey_pot:": { + "category": "food", + "name": "honey pot", + "unicode": "1f36f" + }, + ":hook:": { + "category": "travel", + "name": "hook", + "unicode": "1fa9d" + }, + ":horse:": { + "category": "nature", + "name": "horse face", + "unicode": "1f434" + }, + ":horse_racing:": { + "category": "activity", + "name": "horse racing", + "unicode": "1f3c7" + }, + ":horse_racing_tone1:": { + "category": "activity", + "name": "horse racing: light skin tone", + "unicode": "1f3c7-1f3fb" + }, + ":horse_racing_tone2:": { + "category": "activity", + "name": "horse racing: medium-light skin tone", + "unicode": "1f3c7-1f3fc" + }, + ":horse_racing_tone3:": { + "category": "activity", + "name": "horse racing: medium skin tone", + "unicode": "1f3c7-1f3fd" + }, + ":horse_racing_tone4:": { + "category": "activity", + "name": "horse racing: medium-dark skin tone", + "unicode": "1f3c7-1f3fe" + }, + ":horse_racing_tone5:": { + "category": "activity", + "name": "horse racing: dark skin tone", + "unicode": "1f3c7-1f3ff" + }, + ":hospital:": { + "category": "travel", + "name": "hospital", + "unicode": "1f3e5" + }, + ":hot_face:": { + "category": "people", + "name": "hot face", + "unicode": "1f975" + }, + ":hot_pepper:": { + "category": "food", + "name": "hot pepper", + "unicode": "1f336" + }, + ":hotdog:": { + "category": "food", + "name": "hot dog", + "unicode": "1f32d" + }, + ":hotel:": { + "category": "travel", + "name": "hotel", + "unicode": "1f3e8" + }, + ":hotsprings:": { + "category": "symbols", + "name": "hot springs", + "unicode": "2668" + }, + ":hourglass:": { + "category": "objects", + "name": "hourglass done", + "unicode": "231b" + }, + ":hourglass_flowing_sand:": { + "category": "objects", + "name": "hourglass not done", + "unicode": "23f3" + }, + ":house:": { + "category": "travel", + "name": "house", + "unicode": "1f3e0" + }, + ":house_abandoned:": { + "category": "travel", + "name": "derelict house", + "unicode": "1f3da" + }, + ":house_with_garden:": { + "category": "travel", + "name": "house with garden", + "unicode": "1f3e1" + }, + ":hugging:": { + "category": "people", + "name": "hugging face", + "unicode": "1f917" + }, + ":hushed:": { + "category": "people", + "name": "hushed face", + "unicode": "1f62f" + }, + ":hut:": { + "category": "travel", + "name": "hut", + "unicode": "1f6d6" + }, + ":hyacinth:": { + "category": "nature", + "name": "hyacinth", + "unicode": "1fabb" + }, + ":ice_cream:": { + "category": "food", + "name": "ice cream", + "unicode": "1f368" + }, + ":ice_cube:": { + "category": "food", + "name": "ice cube", + "unicode": "1f9ca" + }, + ":ice_skate:": { + "category": "activity", + "name": "ice skate", + "unicode": "26f8" + }, + ":icecream:": { + "category": "food", + "name": "soft ice cream", + "unicode": "1f366" + }, + ":id:": { + "category": "symbols", + "name": "ID button", + "unicode": "1f194" + }, + ":identification_card:": { + "category": "objects", + "name": "identification card", + "unicode": "1faaa" + }, + ":ideograph_advantage:": { + "category": "symbols", + "name": "Japanese \u201cbargain\u201d button", + "unicode": "1f250" + }, + ":imp:": { + "category": "people", + "name": "angry face with horns", + "unicode": "1f47f" + }, + ":inbox_tray:": { + "category": "objects", + "name": "inbox tray", + "unicode": "1f4e5" + }, + ":incoming_envelope:": { + "category": "objects", + "name": "incoming envelope", + "unicode": "1f4e8" + }, + ":index_pointing_at_the_viewer:": { + "category": "people", + "name": "index pointing at the viewer", + "unicode": "1faf5" + }, + ":index_pointing_at_the_viewer_tone1:": { + "category": "people", + "name": "index pointing at the viewer: light skin tone", + "unicode": "1faf5-1f3fb" + }, + ":index_pointing_at_the_viewer_tone2:": { + "category": "people", + "name": "index pointing at the viewer: medium-light skin tone", + "unicode": "1faf5-1f3fc" + }, + ":index_pointing_at_the_viewer_tone3:": { + "category": "people", + "name": "index pointing at the viewer: medium skin tone", + "unicode": "1faf5-1f3fd" + }, + ":index_pointing_at_the_viewer_tone4:": { + "category": "people", + "name": "index pointing at the viewer: medium-dark skin tone", + "unicode": "1faf5-1f3fe" + }, + ":index_pointing_at_the_viewer_tone5:": { + "category": "people", + "name": "index pointing at the viewer: dark skin tone", + "unicode": "1faf5-1f3ff" + }, + ":infinity:": { + "category": "symbols", + "name": "infinity", + "unicode": "267e" + }, + ":information_source:": { + "category": "symbols", + "name": "information", + "unicode": "2139" + }, + ":innocent:": { + "category": "people", + "name": "smiling face with halo", + "unicode": "1f607" + }, + ":interrobang:": { + "category": "symbols", + "name": "exclamation question mark", + "unicode": "2049" + }, + ":island:": { + "category": "travel", + "name": "desert island", + "unicode": "1f3dd" + }, + ":izakaya_lantern:": { + "category": "objects", + "name": "red paper lantern", + "unicode": "1f3ee" + }, + ":jack_o_lantern:": { + "category": "people", + "name": "jack-o-lantern", + "unicode": "1f383" + }, + ":japan:": { + "category": "travel", + "name": "map of Japan", + "unicode": "1f5fe" + }, + ":japanese_castle:": { + "category": "travel", + "name": "Japanese castle", + "unicode": "1f3ef" + }, + ":japanese_goblin:": { + "category": "people", + "name": "goblin", + "unicode": "1f47a" + }, + ":japanese_ogre:": { + "category": "people", + "name": "ogre", + "unicode": "1f479" + }, + ":jar:": { + "category": "food", + "name": "jar", + "unicode": "1fad9" + }, + ":jeans:": { + "category": "people", + "name": "jeans", + "unicode": "1f456" + }, + ":jellyfish:": { + "category": "nature", + "name": "jellyfish", + "unicode": "1fabc" + }, + ":jigsaw:": { + "category": "activity", + "name": "puzzle piece", + "unicode": "1f9e9" + }, + ":joy:": { + "category": "people", + "name": "face with tears of joy", + "unicode": "1f602" + }, + ":joy_cat:": { + "category": "people", + "name": "cat with tears of joy", + "unicode": "1f639" + }, + ":joystick:": { + "category": "objects", + "name": "joystick", + "unicode": "1f579" + }, + ":judge:": { + "category": "people", + "name": "judge", + "unicode": "1f9d1-200d-2696-fe0f" + }, + ":judge_tone1:": { + "category": "people", + "name": "judge: light skin tone", + "unicode": "1f9d1-1f3fb-200d-2696-fe0f" + }, + ":judge_tone2:": { + "category": "people", + "name": "judge: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-2696-fe0f" + }, + ":judge_tone3:": { + "category": "people", + "name": "judge: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-2696-fe0f" + }, + ":judge_tone4:": { + "category": "people", + "name": "judge: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-2696-fe0f" + }, + ":judge_tone5:": { + "category": "people", + "name": "judge: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-2696-fe0f" + }, + ":kaaba:": { + "category": "travel", + "name": "kaaba", + "unicode": "1f54b" + }, + ":kangaroo:": { + "category": "nature", + "name": "kangaroo", + "unicode": "1f998" + }, + ":key2:": { + "category": "objects", + "name": "old key", + "unicode": "1f5dd" + }, + ":key:": { + "category": "objects", + "name": "key", + "unicode": "1f511" + }, + ":keyboard:": { + "category": "objects", + "name": "keyboard", + "unicode": "2328" + }, + ":keycap_ten:": { + "category": "symbols", + "name": "keycap: 10", + "unicode": "1f51f" + }, + ":khanda:": { + "category": "symbols", + "name": "khanda", + "unicode": "1faaf" + }, + ":kimono:": { + "category": "people", + "name": "kimono", + "unicode": "1f458" + }, + ":kiss:": { + "category": "people", + "name": "kiss mark", + "unicode": "1f48b" + }, + ":kiss_man_man_tone1:": { + "category": "people", + "name": "kiss: man, man, light skin tone", + "unicode": "1f468-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fb" + }, + ":kiss_man_man_tone1_tone2:": { + "category": "people", + "name": "kiss: man, man, light skin tone, medium-light skin tone", + "unicode": "1f468-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fc" + }, + ":kiss_man_man_tone1_tone3:": { + "category": "people", + "name": "kiss: man, man, light skin tone, medium skin tone", + "unicode": "1f468-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fd" + }, + ":kiss_man_man_tone1_tone4:": { + "category": "people", + "name": "kiss: man, man, light skin tone, medium-dark skin tone", + "unicode": "1f468-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fe" + }, + ":kiss_man_man_tone1_tone5:": { + "category": "people", + "name": "kiss: man, man, light skin tone, dark skin tone", + "unicode": "1f468-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3ff" + }, + ":kiss_man_man_tone2:": { + "category": "people", + "name": "kiss: man, man, medium-light skin tone", + "unicode": "1f468-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fc" + }, + ":kiss_man_man_tone2_tone1:": { + "category": "people", + "name": "kiss: man, man, medium-light skin tone, light skin tone", + "unicode": "1f468-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fb" + }, + ":kiss_man_man_tone2_tone3:": { + "category": "people", + "name": "kiss: man, man, medium-light skin tone, medium skin tone", + "unicode": "1f468-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fd" + }, + ":kiss_man_man_tone2_tone4:": { + "category": "people", + "name": "kiss: man, man, medium-light skin tone, medium-dark skin tone", + "unicode": "1f468-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fe" + }, + ":kiss_man_man_tone2_tone5:": { + "category": "people", + "name": "kiss: man, man, medium-light skin tone, dark skin tone", + "unicode": "1f468-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3ff" + }, + ":kiss_man_man_tone3:": { + "category": "people", + "name": "kiss: man, man, medium skin tone", + "unicode": "1f468-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fd" + }, + ":kiss_man_man_tone3_tone1:": { + "category": "people", + "name": "kiss: man, man, medium skin tone, light skin tone", + "unicode": "1f468-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fb" + }, + ":kiss_man_man_tone3_tone2:": { + "category": "people", + "name": "kiss: man, man, medium skin tone, medium-light skin tone", + "unicode": "1f468-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fc" + }, + ":kiss_man_man_tone3_tone4:": { + "category": "people", + "name": "kiss: man, man, medium skin tone, medium-dark skin tone", + "unicode": "1f468-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fe" + }, + ":kiss_man_man_tone3_tone5:": { + "category": "people", + "name": "kiss: man, man, medium skin tone, dark skin tone", + "unicode": "1f468-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3ff" + }, + ":kiss_man_man_tone4:": { + "category": "people", + "name": "kiss: man, man, medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fe" + }, + ":kiss_man_man_tone4_tone1:": { + "category": "people", + "name": "kiss: man, man, medium-dark skin tone, light skin tone", + "unicode": "1f468-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fb" + }, + ":kiss_man_man_tone4_tone2:": { + "category": "people", + "name": "kiss: man, man, medium-dark skin tone, medium-light skin tone", + "unicode": "1f468-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fc" + }, + ":kiss_man_man_tone4_tone3:": { + "category": "people", + "name": "kiss: man, man, medium-dark skin tone, medium skin tone", + "unicode": "1f468-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fd" + }, + ":kiss_man_man_tone4_tone5:": { + "category": "people", + "name": "kiss: man, man, medium-dark skin tone, dark skin tone", + "unicode": "1f468-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3ff" + }, + ":kiss_man_man_tone5:": { + "category": "people", + "name": "kiss: man, man, dark skin tone", + "unicode": "1f468-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3ff" + }, + ":kiss_man_man_tone5_tone1:": { + "category": "people", + "name": "kiss: man, man, dark skin tone, light skin tone", + "unicode": "1f468-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fb" + }, + ":kiss_man_man_tone5_tone2:": { + "category": "people", + "name": "kiss: man, man, dark skin tone, medium-light skin tone", + "unicode": "1f468-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fc" + }, + ":kiss_man_man_tone5_tone3:": { + "category": "people", + "name": "kiss: man, man, dark skin tone, medium skin tone", + "unicode": "1f468-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fd" + }, + ":kiss_man_man_tone5_tone4:": { + "category": "people", + "name": "kiss: man, man, dark skin tone, medium-dark skin tone", + "unicode": "1f468-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fe" + }, + ":kiss_mm:": { + "category": "people", + "name": "kiss: man, man", + "unicode": "1f468-200d-2764-fe0f-200d-1f48b-200d-1f468" + }, + ":kiss_person_person_tone1_tone2:": { + "category": "people", + "name": "kiss: person, person, light skin tone, medium-light skin tone", + "unicode": "1f9d1-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3fc" + }, + ":kiss_person_person_tone1_tone3:": { + "category": "people", + "name": "kiss: person, person, light skin tone, medium skin tone", + "unicode": "1f9d1-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3fd" + }, + ":kiss_person_person_tone1_tone4:": { + "category": "people", + "name": "kiss: person, person, light skin tone, medium-dark skin tone", + "unicode": "1f9d1-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3fe" + }, + ":kiss_person_person_tone1_tone5:": { + "category": "people", + "name": "kiss: person, person, light skin tone, dark skin tone", + "unicode": "1f9d1-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3ff" + }, + ":kiss_person_person_tone2_tone1:": { + "category": "people", + "name": "kiss: person, person, medium-light skin tone, light skin tone", + "unicode": "1f9d1-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3fb" + }, + ":kiss_person_person_tone2_tone3:": { + "category": "people", + "name": "kiss: person, person, medium-light skin tone, medium skin tone", + "unicode": "1f9d1-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3fd" + }, + ":kiss_person_person_tone2_tone4:": { + "category": "people", + "name": "kiss: person, person, medium-light skin tone, medium-dark skin tone", + "unicode": "1f9d1-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3fe" + }, + ":kiss_person_person_tone2_tone5:": { + "category": "people", + "name": "kiss: person, person, medium-light skin tone, dark skin tone", + "unicode": "1f9d1-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3ff" + }, + ":kiss_person_person_tone3_tone1:": { + "category": "people", + "name": "kiss: person, person, medium skin tone, light skin tone", + "unicode": "1f9d1-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3fb" + }, + ":kiss_person_person_tone3_tone2:": { + "category": "people", + "name": "kiss: person, person, medium skin tone, medium-light skin tone", + "unicode": "1f9d1-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3fc" + }, + ":kiss_person_person_tone3_tone4:": { + "category": "people", + "name": "kiss: person, person, medium skin tone, medium-dark skin tone", + "unicode": "1f9d1-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3fe" + }, + ":kiss_person_person_tone3_tone5:": { + "category": "people", + "name": "kiss: person, person, medium skin tone, dark skin tone", + "unicode": "1f9d1-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3ff" + }, + ":kiss_person_person_tone4_tone1:": { + "category": "people", + "name": "kiss: person, person, medium-dark skin tone, light skin tone", + "unicode": "1f9d1-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3fb" + }, + ":kiss_person_person_tone4_tone2:": { + "category": "people", + "name": "kiss: person, person, medium-dark skin tone, medium-light skin tone", + "unicode": "1f9d1-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3fc" + }, + ":kiss_person_person_tone4_tone3:": { + "category": "people", + "name": "kiss: person, person, medium-dark skin tone, medium skin tone", + "unicode": "1f9d1-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3fd" + }, + ":kiss_person_person_tone4_tone5:": { + "category": "people", + "name": "kiss: person, person, medium-dark skin tone, dark skin tone", + "unicode": "1f9d1-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3ff" + }, + ":kiss_person_person_tone5_tone1:": { + "category": "people", + "name": "kiss: person, person, dark skin tone, light skin tone", + "unicode": "1f9d1-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3fb" + }, + ":kiss_person_person_tone5_tone2:": { + "category": "people", + "name": "kiss: person, person, dark skin tone, medium-light skin tone", + "unicode": "1f9d1-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3fc" + }, + ":kiss_person_person_tone5_tone3:": { + "category": "people", + "name": "kiss: person, person, dark skin tone, medium skin tone", + "unicode": "1f9d1-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3fd" + }, + ":kiss_person_person_tone5_tone4:": { + "category": "people", + "name": "kiss: person, person, dark skin tone, medium-dark skin tone", + "unicode": "1f9d1-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f9d1-1f3fe" + }, + ":kiss_tone1:": { + "category": "people", + "name": "kiss: light skin tone", + "unicode": "1f48f-1f3fb" + }, + ":kiss_tone2:": { + "category": "people", + "name": "kiss: medium-light skin tone", + "unicode": "1f48f-1f3fc" + }, + ":kiss_tone3:": { + "category": "people", + "name": "kiss: medium skin tone", + "unicode": "1f48f-1f3fd" + }, + ":kiss_tone4:": { + "category": "people", + "name": "kiss: medium-dark skin tone", + "unicode": "1f48f-1f3fe" + }, + ":kiss_tone5:": { + "category": "people", + "name": "kiss: dark skin tone", + "unicode": "1f48f-1f3ff" + }, + ":kiss_woman_man:": { + "category": "people", + "name": "kiss: woman, man", + "unicode": "1f469-200d-2764-fe0f-200d-1f48b-200d-1f468" + }, + ":kiss_woman_man_tone1:": { + "category": "people", + "name": "kiss: woman, man, light skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fb" + }, + ":kiss_woman_man_tone1_tone2:": { + "category": "people", + "name": "kiss: woman, man, light skin tone, medium-light skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fc" + }, + ":kiss_woman_man_tone1_tone3:": { + "category": "people", + "name": "kiss: woman, man, light skin tone, medium skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fd" + }, + ":kiss_woman_man_tone1_tone4:": { + "category": "people", + "name": "kiss: woman, man, light skin tone, medium-dark skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fe" + }, + ":kiss_woman_man_tone1_tone5:": { + "category": "people", + "name": "kiss: woman, man, light skin tone, dark skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3ff" + }, + ":kiss_woman_man_tone2:": { + "category": "people", + "name": "kiss: woman, man, medium-light skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fc" + }, + ":kiss_woman_man_tone2_tone1:": { + "category": "people", + "name": "kiss: woman, man, medium-light skin tone, light skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fb" + }, + ":kiss_woman_man_tone2_tone3:": { + "category": "people", + "name": "kiss: woman, man, medium-light skin tone, medium skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fd" + }, + ":kiss_woman_man_tone2_tone4:": { + "category": "people", + "name": "kiss: woman, man, medium-light skin tone, medium-dark skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fe" + }, + ":kiss_woman_man_tone2_tone5:": { + "category": "people", + "name": "kiss: woman, man, medium-light skin tone, dark skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3ff" + }, + ":kiss_woman_man_tone3:": { + "category": "people", + "name": "kiss: woman, man, medium skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fd" + }, + ":kiss_woman_man_tone3_tone1:": { + "category": "people", + "name": "kiss: woman, man, medium skin tone, light skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fb" + }, + ":kiss_woman_man_tone3_tone2:": { + "category": "people", + "name": "kiss: woman, man, medium skin tone, medium-light skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fc" + }, + ":kiss_woman_man_tone3_tone4:": { + "category": "people", + "name": "kiss: woman, man, medium skin tone, medium-dark skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fe" + }, + ":kiss_woman_man_tone3_tone5:": { + "category": "people", + "name": "kiss: woman, man, medium skin tone, dark skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3ff" + }, + ":kiss_woman_man_tone4:": { + "category": "people", + "name": "kiss: woman, man, medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fe" + }, + ":kiss_woman_man_tone4_tone1:": { + "category": "people", + "name": "kiss: woman, man, medium-dark skin tone, light skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fb" + }, + ":kiss_woman_man_tone4_tone2:": { + "category": "people", + "name": "kiss: woman, man, medium-dark skin tone, medium-light skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fc" + }, + ":kiss_woman_man_tone4_tone3:": { + "category": "people", + "name": "kiss: woman, man, medium-dark skin tone, medium skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fd" + }, + ":kiss_woman_man_tone4_tone5:": { + "category": "people", + "name": "kiss: woman, man, medium-dark skin tone, dark skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3ff" + }, + ":kiss_woman_man_tone5:": { + "category": "people", + "name": "kiss: woman, man, dark skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3ff" + }, + ":kiss_woman_man_tone5_tone1:": { + "category": "people", + "name": "kiss: woman, man, dark skin tone, light skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fb" + }, + ":kiss_woman_man_tone5_tone2:": { + "category": "people", + "name": "kiss: woman, man, dark skin tone, medium-light skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fc" + }, + ":kiss_woman_man_tone5_tone3:": { + "category": "people", + "name": "kiss: woman, man, dark skin tone, medium skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fd" + }, + ":kiss_woman_man_tone5_tone4:": { + "category": "people", + "name": "kiss: woman, man, dark skin tone, medium-dark skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f468-1f3fe" + }, + ":kiss_woman_woman_tone1:": { + "category": "people", + "name": "kiss: woman, woman, light skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fb" + }, + ":kiss_woman_woman_tone1_tone2:": { + "category": "people", + "name": "kiss: woman, woman, light skin tone, medium-light skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fc" + }, + ":kiss_woman_woman_tone1_tone3:": { + "category": "people", + "name": "kiss: woman, woman, light skin tone, medium skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fd" + }, + ":kiss_woman_woman_tone1_tone4:": { + "category": "people", + "name": "kiss: woman, woman, light skin tone, medium-dark skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fe" + }, + ":kiss_woman_woman_tone1_tone5:": { + "category": "people", + "name": "kiss: woman, woman, light skin tone, dark skin tone", + "unicode": "1f469-1f3fb-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3ff" + }, + ":kiss_woman_woman_tone2:": { + "category": "people", + "name": "kiss: woman, woman, medium-light skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fc" + }, + ":kiss_woman_woman_tone2_tone1:": { + "category": "people", + "name": "kiss: woman, woman, medium-light skin tone, light skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fb" + }, + ":kiss_woman_woman_tone2_tone3:": { + "category": "people", + "name": "kiss: woman, woman, medium-light skin tone, medium skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fd" + }, + ":kiss_woman_woman_tone2_tone4:": { + "category": "people", + "name": "kiss: woman, woman, medium-light skin tone, medium-dark skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fe" + }, + ":kiss_woman_woman_tone2_tone5:": { + "category": "people", + "name": "kiss: woman, woman, medium-light skin tone, dark skin tone", + "unicode": "1f469-1f3fc-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3ff" + }, + ":kiss_woman_woman_tone3:": { + "category": "people", + "name": "kiss: woman, woman, medium skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fd" + }, + ":kiss_woman_woman_tone3_tone1:": { + "category": "people", + "name": "kiss: woman, woman, medium skin tone, light skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fb" + }, + ":kiss_woman_woman_tone3_tone2:": { + "category": "people", + "name": "kiss: woman, woman, medium skin tone, medium-light skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fc" + }, + ":kiss_woman_woman_tone3_tone4:": { + "category": "people", + "name": "kiss: woman, woman, medium skin tone, medium-dark skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fe" + }, + ":kiss_woman_woman_tone3_tone5:": { + "category": "people", + "name": "kiss: woman, woman, medium skin tone, dark skin tone", + "unicode": "1f469-1f3fd-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3ff" + }, + ":kiss_woman_woman_tone4:": { + "category": "people", + "name": "kiss: woman, woman, medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fe" + }, + ":kiss_woman_woman_tone4_tone1:": { + "category": "people", + "name": "kiss: woman, woman, medium-dark skin tone, light skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fb" + }, + ":kiss_woman_woman_tone4_tone2:": { + "category": "people", + "name": "kiss: woman, woman, medium-dark skin tone, medium-light skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fc" + }, + ":kiss_woman_woman_tone4_tone3:": { + "category": "people", + "name": "kiss: woman, woman, medium-dark skin tone, medium skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fd" + }, + ":kiss_woman_woman_tone4_tone5:": { + "category": "people", + "name": "kiss: woman, woman, medium-dark skin tone, dark skin tone", + "unicode": "1f469-1f3fe-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3ff" + }, + ":kiss_woman_woman_tone5:": { + "category": "people", + "name": "kiss: woman, woman, dark skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3ff" + }, + ":kiss_woman_woman_tone5_tone1:": { + "category": "people", + "name": "kiss: woman, woman, dark skin tone, light skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fb" + }, + ":kiss_woman_woman_tone5_tone2:": { + "category": "people", + "name": "kiss: woman, woman, dark skin tone, medium-light skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fc" + }, + ":kiss_woman_woman_tone5_tone3:": { + "category": "people", + "name": "kiss: woman, woman, dark skin tone, medium skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fd" + }, + ":kiss_woman_woman_tone5_tone4:": { + "category": "people", + "name": "kiss: woman, woman, dark skin tone, medium-dark skin tone", + "unicode": "1f469-1f3ff-200d-2764-fe0f-200d-1f48b-200d-1f469-1f3fe" + }, + ":kiss_ww:": { + "category": "people", + "name": "kiss: woman, woman", + "unicode": "1f469-200d-2764-fe0f-200d-1f48b-200d-1f469" + }, + ":kissing:": { + "category": "people", + "name": "kissing face", + "unicode": "1f617" + }, + ":kissing_cat:": { + "category": "people", + "name": "kissing cat", + "unicode": "1f63d" + }, + ":kissing_closed_eyes:": { + "category": "people", + "name": "kissing face with closed eyes", + "unicode": "1f61a" + }, + ":kissing_heart:": { + "category": "people", + "name": "face blowing a kiss", + "unicode": "1f618" + }, + ":kissing_smiling_eyes:": { + "category": "people", + "name": "kissing face with smiling eyes", + "unicode": "1f619" + }, + ":kite:": { + "category": "activity", + "name": "kite", + "unicode": "1fa81" + }, + ":kiwi:": { + "category": "food", + "name": "kiwi fruit", + "unicode": "1f95d" + }, + ":knife:": { + "category": "objects", + "name": "kitchen knife", + "unicode": "1f52a" + }, + ":knot:": { + "category": "people", + "name": "knot", + "unicode": "1faa2" + }, + ":koala:": { + "category": "nature", + "name": "koala", + "unicode": "1f428" + }, + ":koko:": { + "category": "symbols", + "name": "Japanese \u201chere\u201d button", + "unicode": "1f201" + }, + ":lab_coat:": { + "category": "people", + "name": "lab coat", + "unicode": "1f97c" + }, + ":label:": { + "category": "objects", + "name": "label", + "unicode": "1f3f7" + }, + ":lacrosse:": { + "category": "activity", + "name": "lacrosse", + "unicode": "1f94d" + }, + ":ladder:": { + "category": "objects", + "name": "ladder", + "unicode": "1fa9c" + }, + ":lady_beetle:": { + "category": "nature", + "name": "lady beetle", + "unicode": "1f41e" + }, + ":large_blue_diamond:": { + "category": "symbols", + "name": "large blue diamond", + "unicode": "1f537" + }, + ":large_orange_diamond:": { + "category": "symbols", + "name": "large orange diamond", + "unicode": "1f536" + }, + ":last_quarter_moon:": { + "category": "nature", + "name": "last quarter moon", + "unicode": "1f317" + }, + ":last_quarter_moon_with_face:": { + "category": "nature", + "name": "last quarter moon face", + "unicode": "1f31c" + }, + ":laughing:": { + "category": "people", + "name": "grinning squinting face", + "unicode": "1f606" + }, + ":leafless_tree:": { + "category": "nature", + "name": "leafless tree", + "unicode": "1fabe" + }, + ":leafy_green:": { + "category": "food", + "name": "leafy green", + "unicode": "1f96c" + }, + ":leaves:": { + "category": "nature", + "name": "leaf fluttering in wind", + "unicode": "1f343" + }, + ":ledger:": { + "category": "objects", + "name": "ledger", + "unicode": "1f4d2" + }, + ":left_facing_fist:": { + "category": "people", + "name": "left-facing fist", + "unicode": "1f91b" + }, + ":left_facing_fist_tone1:": { + "category": "people", + "name": "left-facing fist: light skin tone", + "unicode": "1f91b-1f3fb" + }, + ":left_facing_fist_tone2:": { + "category": "people", + "name": "left-facing fist: medium-light skin tone", + "unicode": "1f91b-1f3fc" + }, + ":left_facing_fist_tone3:": { + "category": "people", + "name": "left-facing fist: medium skin tone", + "unicode": "1f91b-1f3fd" + }, + ":left_facing_fist_tone4:": { + "category": "people", + "name": "left-facing fist: medium-dark skin tone", + "unicode": "1f91b-1f3fe" + }, + ":left_facing_fist_tone5:": { + "category": "people", + "name": "left-facing fist: dark skin tone", + "unicode": "1f91b-1f3ff" + }, + ":left_luggage:": { + "category": "symbols", + "name": "left luggage", + "unicode": "1f6c5" + }, + ":left_right_arrow:": { + "category": "symbols", + "name": "left-right arrow", + "unicode": "2194" + }, + ":leftwards_arrow_with_hook:": { + "category": "symbols", + "name": "right arrow curving left", + "unicode": "21a9" + }, + ":leftwards_hand:": { + "category": "people", + "name": "leftwards hand", + "unicode": "1faf2" + }, + ":leftwards_hand_tone1:": { + "category": "people", + "name": "leftwards hand: light skin tone", + "unicode": "1faf2-1f3fb" + }, + ":leftwards_hand_tone2:": { + "category": "people", + "name": "leftwards hand: medium-light skin tone", + "unicode": "1faf2-1f3fc" + }, + ":leftwards_hand_tone3:": { + "category": "people", + "name": "leftwards hand: medium skin tone", + "unicode": "1faf2-1f3fd" + }, + ":leftwards_hand_tone4:": { + "category": "people", + "name": "leftwards hand: medium-dark skin tone", + "unicode": "1faf2-1f3fe" + }, + ":leftwards_hand_tone5:": { + "category": "people", + "name": "leftwards hand: dark skin tone", + "unicode": "1faf2-1f3ff" + }, + ":leftwards_pushing_hand:": { + "category": "people", + "name": "leftwards pushing hand", + "unicode": "1faf7" + }, + ":leftwards_pushing_hand_tone1:": { + "category": "people", + "name": "leftwards pushing hand: light skin tone", + "unicode": "1faf7-1f3fb" + }, + ":leftwards_pushing_hand_tone2:": { + "category": "people", + "name": "leftwards pushing hand: medium-light skin tone", + "unicode": "1faf7-1f3fc" + }, + ":leftwards_pushing_hand_tone3:": { + "category": "people", + "name": "leftwards pushing hand: medium skin tone", + "unicode": "1faf7-1f3fd" + }, + ":leftwards_pushing_hand_tone4:": { + "category": "people", + "name": "leftwards pushing hand: medium-dark skin tone", + "unicode": "1faf7-1f3fe" + }, + ":leftwards_pushing_hand_tone5:": { + "category": "people", + "name": "leftwards pushing hand: dark skin tone", + "unicode": "1faf7-1f3ff" + }, + ":leg:": { + "category": "people", + "name": "leg", + "unicode": "1f9b5" + }, + ":leg_tone1:": { + "category": "people", + "name": "leg: light skin tone", + "unicode": "1f9b5-1f3fb" + }, + ":leg_tone2:": { + "category": "people", + "name": "leg: medium-light skin tone", + "unicode": "1f9b5-1f3fc" + }, + ":leg_tone3:": { + "category": "people", + "name": "leg: medium skin tone", + "unicode": "1f9b5-1f3fd" + }, + ":leg_tone4:": { + "category": "people", + "name": "leg: medium-dark skin tone", + "unicode": "1f9b5-1f3fe" + }, + ":leg_tone5:": { + "category": "people", + "name": "leg: dark skin tone", + "unicode": "1f9b5-1f3ff" + }, + ":lemon:": { + "category": "food", + "name": "lemon", + "unicode": "1f34b" + }, + ":leo:": { + "category": "symbols", + "name": "Leo", + "unicode": "264c" + }, + ":leopard:": { + "category": "nature", + "name": "leopard", + "unicode": "1f406" + }, + ":level_slider:": { + "category": "objects", + "name": "level slider", + "unicode": "1f39a" + }, + ":levitate:": { + "category": "people", + "name": "man in suit levitating", + "unicode": "1f574" + }, + ":levitate_tone1:": { + "category": "people", + "name": "man in suit levitating: light skin tone", + "unicode": "1f574-1f3fb" + }, + ":levitate_tone2:": { + "category": "people", + "name": "man in suit levitating: medium-light skin tone", + "unicode": "1f574-1f3fc" + }, + ":levitate_tone3:": { + "category": "people", + "name": "man in suit levitating: medium skin tone", + "unicode": "1f574-1f3fd" + }, + ":levitate_tone4:": { + "category": "people", + "name": "man in suit levitating: medium-dark skin tone", + "unicode": "1f574-1f3fe" + }, + ":levitate_tone5:": { + "category": "people", + "name": "man in suit levitating: dark skin tone", + "unicode": "1f574-1f3ff" + }, + ":libra:": { + "category": "symbols", + "name": "Libra", + "unicode": "264e" + }, + ":light_blue_heart:": { + "category": "symbols", + "name": "light blue heart", + "unicode": "1fa75" + }, + ":light_rail:": { + "category": "travel", + "name": "light rail", + "unicode": "1f688" + }, + ":lime:": { + "category": "food", + "name": "lime", + "unicode": "1f34b-200d-1f7e9" + }, + ":link:": { + "category": "objects", + "name": "link", + "unicode": "1f517" + }, + ":lion_face:": { + "category": "nature", + "name": "lion", + "unicode": "1f981" + }, + ":lips:": { + "category": "people", + "name": "mouth", + "unicode": "1f444" + }, + ":lipstick:": { + "category": "people", + "name": "lipstick", + "unicode": "1f484" + }, + ":lizard:": { + "category": "nature", + "name": "lizard", + "unicode": "1f98e" + }, + ":llama:": { + "category": "nature", + "name": "llama", + "unicode": "1f999" + }, + ":lobster:": { + "category": "nature", + "name": "lobster", + "unicode": "1f99e" + }, + ":lock:": { + "category": "objects", + "name": "locked", + "unicode": "1f512" + }, + ":lock_with_ink_pen:": { + "category": "objects", + "name": "locked with pen", + "unicode": "1f50f" + }, + ":lollipop:": { + "category": "food", + "name": "lollipop", + "unicode": "1f36d" + }, + ":long_drum:": { + "category": "activity", + "name": "long drum", + "unicode": "1fa98" + }, + ":loop:": { + "category": "symbols", + "name": "double curly loop", + "unicode": "27bf" + }, + ":lotus:": { + "category": "nature", + "name": "lotus", + "unicode": "1fab7" + }, + ":loud_sound:": { + "category": "symbols", + "name": "speaker high volume", + "unicode": "1f50a" + }, + ":loudspeaker:": { + "category": "symbols", + "name": "loudspeaker", + "unicode": "1f4e2" + }, + ":love_hotel:": { + "category": "travel", + "name": "love hotel", + "unicode": "1f3e9" + }, + ":love_letter:": { + "category": "objects", + "name": "love letter", + "unicode": "1f48c" + }, + ":love_you_gesture:": { + "category": "people", + "name": "love-you gesture", + "unicode": "1f91f" + }, + ":love_you_gesture_tone1:": { + "category": "people", + "name": "love-you gesture: light skin tone", + "unicode": "1f91f-1f3fb" + }, + ":love_you_gesture_tone2:": { + "category": "people", + "name": "love-you gesture: medium-light skin tone", + "unicode": "1f91f-1f3fc" + }, + ":love_you_gesture_tone3:": { + "category": "people", + "name": "love-you gesture: medium skin tone", + "unicode": "1f91f-1f3fd" + }, + ":love_you_gesture_tone4:": { + "category": "people", + "name": "love-you gesture: medium-dark skin tone", + "unicode": "1f91f-1f3fe" + }, + ":love_you_gesture_tone5:": { + "category": "people", + "name": "love-you gesture: dark skin tone", + "unicode": "1f91f-1f3ff" + }, + ":low_battery:": { + "category": "objects", + "name": "low battery", + "unicode": "1faab" + }, + ":low_brightness:": { + "category": "symbols", + "name": "dim button", + "unicode": "1f505" + }, + ":luggage:": { + "category": "people", + "name": "luggage", + "unicode": "1f9f3" + }, + ":lungs:": { + "category": "people", + "name": "lungs", + "unicode": "1fac1" + }, + ":lying_face:": { + "category": "people", + "name": "lying face", + "unicode": "1f925" + }, + ":m:": { + "category": "symbols", + "name": "circled M", + "unicode": "24c2" + }, + ":mag:": { + "category": "objects", + "name": "magnifying glass tilted left", + "unicode": "1f50d" + }, + ":mag_right:": { + "category": "objects", + "name": "magnifying glass tilted right", + "unicode": "1f50e" + }, + ":mage:": { + "category": "people", + "name": "mage", + "unicode": "1f9d9" + }, + ":mage_tone1:": { + "category": "people", + "name": "mage: light skin tone", + "unicode": "1f9d9-1f3fb" + }, + ":mage_tone2:": { + "category": "people", + "name": "mage: medium-light skin tone", + "unicode": "1f9d9-1f3fc" + }, + ":mage_tone3:": { + "category": "people", + "name": "mage: medium skin tone", + "unicode": "1f9d9-1f3fd" + }, + ":mage_tone4:": { + "category": "people", + "name": "mage: medium-dark skin tone", + "unicode": "1f9d9-1f3fe" + }, + ":mage_tone5:": { + "category": "people", + "name": "mage: dark skin tone", + "unicode": "1f9d9-1f3ff" + }, + ":magic_wand:": { + "category": "objects", + "name": "magic wand", + "unicode": "1fa84" + }, + ":magnet:": { + "category": "objects", + "name": "magnet", + "unicode": "1f9f2" + }, + ":mahjong:": { + "category": "symbols", + "name": "mahjong red dragon", + "unicode": "1f004" + }, + ":mailbox:": { + "category": "objects", + "name": "closed mailbox with raised flag", + "unicode": "1f4eb" + }, + ":mailbox_closed:": { + "category": "objects", + "name": "closed mailbox with lowered flag", + "unicode": "1f4ea" + }, + ":mailbox_with_mail:": { + "category": "objects", + "name": "open mailbox with raised flag", + "unicode": "1f4ec" + }, + ":mailbox_with_no_mail:": { + "category": "objects", + "name": "open mailbox with lowered flag", + "unicode": "1f4ed" + }, + ":male_sign:": { + "category": "symbols", + "name": "male sign", + "unicode": "2642" + }, + ":mammoth:": { + "category": "nature", + "name": "mammoth", + "unicode": "1f9a3" + }, + ":man:": { + "category": "people", + "name": "man", + "unicode": "1f468" + }, + ":man_artist:": { + "category": "people", + "name": "man artist", + "unicode": "1f468-200d-1f3a8" + }, + ":man_artist_tone1:": { + "category": "people", + "name": "man artist: light skin tone", + "unicode": "1f468-1f3fb-200d-1f3a8" + }, + ":man_artist_tone2:": { + "category": "people", + "name": "man artist: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f3a8" + }, + ":man_artist_tone3:": { + "category": "people", + "name": "man artist: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f3a8" + }, + ":man_artist_tone4:": { + "category": "people", + "name": "man artist: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f3a8" + }, + ":man_artist_tone5:": { + "category": "people", + "name": "man artist: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f3a8" + }, + ":man_astronaut:": { + "category": "people", + "name": "man astronaut", + "unicode": "1f468-200d-1f680" + }, + ":man_astronaut_tone1:": { + "category": "people", + "name": "man astronaut: light skin tone", + "unicode": "1f468-1f3fb-200d-1f680" + }, + ":man_astronaut_tone2:": { + "category": "people", + "name": "man astronaut: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f680" + }, + ":man_astronaut_tone3:": { + "category": "people", + "name": "man astronaut: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f680" + }, + ":man_astronaut_tone4:": { + "category": "people", + "name": "man astronaut: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f680" + }, + ":man_astronaut_tone5:": { + "category": "people", + "name": "man astronaut: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f680" + }, + ":man_bald:": { + "category": "people", + "name": "man: bald", + "unicode": "1f468-200d-1f9b2" + }, + ":man_bald_tone1:": { + "category": "people", + "name": "man, bald: light skin tone", + "unicode": "1f468-1f3fb-200d-1f9b2" + }, + ":man_bald_tone2:": { + "category": "people", + "name": "man, bald: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f9b2" + }, + ":man_bald_tone3:": { + "category": "people", + "name": "man, bald: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f9b2" + }, + ":man_bald_tone4:": { + "category": "people", + "name": "man, bald: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f9b2" + }, + ":man_bald_tone5:": { + "category": "people", + "name": "man, bald: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f9b2" + }, + ":man_beard:": { + "category": "people", + "name": "man: beard", + "unicode": "1f9d4-200d-2642-fe0f" + }, + ":man_biking:": { + "category": "activity", + "name": "man biking", + "unicode": "1f6b4-200d-2642-fe0f" + }, + ":man_biking_tone1:": { + "category": "activity", + "name": "man biking: light skin tone", + "unicode": "1f6b4-1f3fb-200d-2642-fe0f" + }, + ":man_biking_tone2:": { + "category": "activity", + "name": "man biking: medium-light skin tone", + "unicode": "1f6b4-1f3fc-200d-2642-fe0f" + }, + ":man_biking_tone3:": { + "category": "activity", + "name": "man biking: medium skin tone", + "unicode": "1f6b4-1f3fd-200d-2642-fe0f" + }, + ":man_biking_tone4:": { + "category": "activity", + "name": "man biking: medium-dark skin tone", + "unicode": "1f6b4-1f3fe-200d-2642-fe0f" + }, + ":man_biking_tone5:": { + "category": "activity", + "name": "man biking: dark skin tone", + "unicode": "1f6b4-1f3ff-200d-2642-fe0f" + }, + ":man_bouncing_ball:": { + "category": "activity", + "name": "man bouncing ball", + "unicode": "26f9-fe0f-200d-2642-fe0f" + }, + ":man_bouncing_ball_tone1:": { + "category": "activity", + "name": "man bouncing ball: light skin tone", + "unicode": "26f9-1f3fb-200d-2642-fe0f" + }, + ":man_bouncing_ball_tone2:": { + "category": "activity", + "name": "man bouncing ball: medium-light skin tone", + "unicode": "26f9-1f3fc-200d-2642-fe0f" + }, + ":man_bouncing_ball_tone3:": { + "category": "activity", + "name": "man bouncing ball: medium skin tone", + "unicode": "26f9-1f3fd-200d-2642-fe0f" + }, + ":man_bouncing_ball_tone4:": { + "category": "activity", + "name": "man bouncing ball: medium-dark skin tone", + "unicode": "26f9-1f3fe-200d-2642-fe0f" + }, + ":man_bouncing_ball_tone5:": { + "category": "activity", + "name": "man bouncing ball: dark skin tone", + "unicode": "26f9-1f3ff-200d-2642-fe0f" + }, + ":man_bowing:": { + "category": "people", + "name": "man bowing", + "unicode": "1f647-200d-2642-fe0f" + }, + ":man_bowing_tone1:": { + "category": "people", + "name": "man bowing: light skin tone", + "unicode": "1f647-1f3fb-200d-2642-fe0f" + }, + ":man_bowing_tone2:": { + "category": "people", + "name": "man bowing: medium-light skin tone", + "unicode": "1f647-1f3fc-200d-2642-fe0f" + }, + ":man_bowing_tone3:": { + "category": "people", + "name": "man bowing: medium skin tone", + "unicode": "1f647-1f3fd-200d-2642-fe0f" + }, + ":man_bowing_tone4:": { + "category": "people", + "name": "man bowing: medium-dark skin tone", + "unicode": "1f647-1f3fe-200d-2642-fe0f" + }, + ":man_bowing_tone5:": { + "category": "people", + "name": "man bowing: dark skin tone", + "unicode": "1f647-1f3ff-200d-2642-fe0f" + }, + ":man_cartwheeling:": { + "category": "activity", + "name": "man cartwheeling", + "unicode": "1f938-200d-2642-fe0f" + }, + ":man_cartwheeling_tone1:": { + "category": "activity", + "name": "man cartwheeling: light skin tone", + "unicode": "1f938-1f3fb-200d-2642-fe0f" + }, + ":man_cartwheeling_tone2:": { + "category": "activity", + "name": "man cartwheeling: medium-light skin tone", + "unicode": "1f938-1f3fc-200d-2642-fe0f" + }, + ":man_cartwheeling_tone3:": { + "category": "activity", + "name": "man cartwheeling: medium skin tone", + "unicode": "1f938-1f3fd-200d-2642-fe0f" + }, + ":man_cartwheeling_tone4:": { + "category": "activity", + "name": "man cartwheeling: medium-dark skin tone", + "unicode": "1f938-1f3fe-200d-2642-fe0f" + }, + ":man_cartwheeling_tone5:": { + "category": "activity", + "name": "man cartwheeling: dark skin tone", + "unicode": "1f938-1f3ff-200d-2642-fe0f" + }, + ":man_climbing:": { + "category": "activity", + "name": "man climbing", + "unicode": "1f9d7-200d-2642-fe0f" + }, + ":man_climbing_tone1:": { + "category": "activity", + "name": "man climbing: light skin tone", + "unicode": "1f9d7-1f3fb-200d-2642-fe0f" + }, + ":man_climbing_tone2:": { + "category": "activity", + "name": "man climbing: medium-light skin tone", + "unicode": "1f9d7-1f3fc-200d-2642-fe0f" + }, + ":man_climbing_tone3:": { + "category": "activity", + "name": "man climbing: medium skin tone", + "unicode": "1f9d7-1f3fd-200d-2642-fe0f" + }, + ":man_climbing_tone4:": { + "category": "activity", + "name": "man climbing: medium-dark skin tone", + "unicode": "1f9d7-1f3fe-200d-2642-fe0f" + }, + ":man_climbing_tone5:": { + "category": "activity", + "name": "man climbing: dark skin tone", + "unicode": "1f9d7-1f3ff-200d-2642-fe0f" + }, + ":man_construction_worker:": { + "category": "people", + "name": "man construction worker", + "unicode": "1f477-200d-2642-fe0f" + }, + ":man_construction_worker_tone1:": { + "category": "people", + "name": "man construction worker: light skin tone", + "unicode": "1f477-1f3fb-200d-2642-fe0f" + }, + ":man_construction_worker_tone2:": { + "category": "people", + "name": "man construction worker: medium-light skin tone", + "unicode": "1f477-1f3fc-200d-2642-fe0f" + }, + ":man_construction_worker_tone3:": { + "category": "people", + "name": "man construction worker: medium skin tone", + "unicode": "1f477-1f3fd-200d-2642-fe0f" + }, + ":man_construction_worker_tone4:": { + "category": "people", + "name": "man construction worker: medium-dark skin tone", + "unicode": "1f477-1f3fe-200d-2642-fe0f" + }, + ":man_construction_worker_tone5:": { + "category": "people", + "name": "man construction worker: dark skin tone", + "unicode": "1f477-1f3ff-200d-2642-fe0f" + }, + ":man_cook:": { + "category": "people", + "name": "man cook", + "unicode": "1f468-200d-1f373" + }, + ":man_cook_tone1:": { + "category": "people", + "name": "man cook: light skin tone", + "unicode": "1f468-1f3fb-200d-1f373" + }, + ":man_cook_tone2:": { + "category": "people", + "name": "man cook: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f373" + }, + ":man_cook_tone3:": { + "category": "people", + "name": "man cook: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f373" + }, + ":man_cook_tone4:": { + "category": "people", + "name": "man cook: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f373" + }, + ":man_cook_tone5:": { + "category": "people", + "name": "man cook: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f373" + }, + ":man_curly_haired:": { + "category": "people", + "name": "man: curly hair", + "unicode": "1f468-200d-1f9b1" + }, + ":man_curly_haired_tone1:": { + "category": "people", + "name": "man, curly haired: light skin tone", + "unicode": "1f468-1f3fb-200d-1f9b1" + }, + ":man_curly_haired_tone2:": { + "category": "people", + "name": "man, curly haired: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f9b1" + }, + ":man_curly_haired_tone3:": { + "category": "people", + "name": "man, curly haired: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f9b1" + }, + ":man_curly_haired_tone4:": { + "category": "people", + "name": "man, curly haired: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f9b1" + }, + ":man_curly_haired_tone5:": { + "category": "people", + "name": "man, curly haired: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f9b1" + }, + ":man_dancing:": { + "category": "people", + "name": "man dancing", + "unicode": "1f57a" + }, + ":man_dancing_tone1:": { + "category": "people", + "name": "man dancing: light skin tone", + "unicode": "1f57a-1f3fb" + }, + ":man_dancing_tone2:": { + "category": "people", + "name": "man dancing: medium-light skin tone", + "unicode": "1f57a-1f3fc" + }, + ":man_dancing_tone3:": { + "category": "people", + "name": "man dancing: medium skin tone", + "unicode": "1f57a-1f3fd" + }, + ":man_dancing_tone4:": { + "category": "people", + "name": "man dancing: medium-dark skin tone", + "unicode": "1f57a-1f3fe" + }, + ":man_dancing_tone5:": { + "category": "people", + "name": "man dancing: dark skin tone", + "unicode": "1f57a-1f3ff" + }, + ":man_detective:": { + "category": "people", + "name": "man detective", + "unicode": "1f575-fe0f-200d-2642-fe0f" + }, + ":man_detective_tone1:": { + "category": "people", + "name": "man detective: light skin tone", + "unicode": "1f575-1f3fb-200d-2642-fe0f" + }, + ":man_detective_tone2:": { + "category": "people", + "name": "man detective: medium-light skin tone", + "unicode": "1f575-1f3fc-200d-2642-fe0f" + }, + ":man_detective_tone3:": { + "category": "people", + "name": "man detective: medium skin tone", + "unicode": "1f575-1f3fd-200d-2642-fe0f" + }, + ":man_detective_tone4:": { + "category": "people", + "name": "man detective: medium-dark skin tone", + "unicode": "1f575-1f3fe-200d-2642-fe0f" + }, + ":man_detective_tone5:": { + "category": "people", + "name": "man detective: dark skin tone", + "unicode": "1f575-1f3ff-200d-2642-fe0f" + }, + ":man_elf:": { + "category": "people", + "name": "man elf", + "unicode": "1f9dd-200d-2642-fe0f" + }, + ":man_elf_tone1:": { + "category": "people", + "name": "man elf: light skin tone", + "unicode": "1f9dd-1f3fb-200d-2642-fe0f" + }, + ":man_elf_tone2:": { + "category": "people", + "name": "man elf: medium-light skin tone", + "unicode": "1f9dd-1f3fc-200d-2642-fe0f" + }, + ":man_elf_tone3:": { + "category": "people", + "name": "man elf: medium skin tone", + "unicode": "1f9dd-1f3fd-200d-2642-fe0f" + }, + ":man_elf_tone4:": { + "category": "people", + "name": "man elf: medium-dark skin tone", + "unicode": "1f9dd-1f3fe-200d-2642-fe0f" + }, + ":man_elf_tone5:": { + "category": "people", + "name": "man elf: dark skin tone", + "unicode": "1f9dd-1f3ff-200d-2642-fe0f" + }, + ":man_facepalming:": { + "category": "people", + "name": "man facepalming", + "unicode": "1f926-200d-2642-fe0f" + }, + ":man_facepalming_tone1:": { + "category": "people", + "name": "man facepalming: light skin tone", + "unicode": "1f926-1f3fb-200d-2642-fe0f" + }, + ":man_facepalming_tone2:": { + "category": "people", + "name": "man facepalming: medium-light skin tone", + "unicode": "1f926-1f3fc-200d-2642-fe0f" + }, + ":man_facepalming_tone3:": { + "category": "people", + "name": "man facepalming: medium skin tone", + "unicode": "1f926-1f3fd-200d-2642-fe0f" + }, + ":man_facepalming_tone4:": { + "category": "people", + "name": "man facepalming: medium-dark skin tone", + "unicode": "1f926-1f3fe-200d-2642-fe0f" + }, + ":man_facepalming_tone5:": { + "category": "people", + "name": "man facepalming: dark skin tone", + "unicode": "1f926-1f3ff-200d-2642-fe0f" + }, + ":man_factory_worker:": { + "category": "people", + "name": "man factory worker", + "unicode": "1f468-200d-1f3ed" + }, + ":man_factory_worker_tone1:": { + "category": "people", + "name": "man factory worker: light skin tone", + "unicode": "1f468-1f3fb-200d-1f3ed" + }, + ":man_factory_worker_tone2:": { + "category": "people", + "name": "man factory worker: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f3ed" + }, + ":man_factory_worker_tone3:": { + "category": "people", + "name": "man factory worker: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f3ed" + }, + ":man_factory_worker_tone4:": { + "category": "people", + "name": "man factory worker: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f3ed" + }, + ":man_factory_worker_tone5:": { + "category": "people", + "name": "man factory worker: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f3ed" + }, + ":man_fairy:": { + "category": "people", + "name": "man fairy", + "unicode": "1f9da-200d-2642-fe0f" + }, + ":man_fairy_tone1:": { + "category": "people", + "name": "man fairy: light skin tone", + "unicode": "1f9da-1f3fb-200d-2642-fe0f" + }, + ":man_fairy_tone2:": { + "category": "people", + "name": "man fairy: medium-light skin tone", + "unicode": "1f9da-1f3fc-200d-2642-fe0f" + }, + ":man_fairy_tone3:": { + "category": "people", + "name": "man fairy: medium skin tone", + "unicode": "1f9da-1f3fd-200d-2642-fe0f" + }, + ":man_fairy_tone4:": { + "category": "people", + "name": "man fairy: medium-dark skin tone", + "unicode": "1f9da-1f3fe-200d-2642-fe0f" + }, + ":man_fairy_tone5:": { + "category": "people", + "name": "man fairy: dark skin tone", + "unicode": "1f9da-1f3ff-200d-2642-fe0f" + }, + ":man_farmer:": { + "category": "people", + "name": "man farmer", + "unicode": "1f468-200d-1f33e" + }, + ":man_farmer_tone1:": { + "category": "people", + "name": "man farmer: light skin tone", + "unicode": "1f468-1f3fb-200d-1f33e" + }, + ":man_farmer_tone2:": { + "category": "people", + "name": "man farmer: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f33e" + }, + ":man_farmer_tone3:": { + "category": "people", + "name": "man farmer: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f33e" + }, + ":man_farmer_tone4:": { + "category": "people", + "name": "man farmer: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f33e" + }, + ":man_farmer_tone5:": { + "category": "people", + "name": "man farmer: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f33e" + }, + ":man_feeding_baby:": { + "category": "people", + "name": "man feeding baby", + "unicode": "1f468-200d-1f37c" + }, + ":man_feeding_baby_tone1:": { + "category": "people", + "name": "man feeding baby: light skin tone", + "unicode": "1f468-1f3fb-200d-1f37c" + }, + ":man_feeding_baby_tone2:": { + "category": "people", + "name": "man feeding baby: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f37c" + }, + ":man_feeding_baby_tone3:": { + "category": "people", + "name": "man feeding baby: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f37c" + }, + ":man_feeding_baby_tone4:": { + "category": "people", + "name": "man feeding baby: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f37c" + }, + ":man_feeding_baby_tone5:": { + "category": "people", + "name": "man feeding baby: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f37c" + }, + ":man_firefighter:": { + "category": "people", + "name": "man firefighter", + "unicode": "1f468-200d-1f692" + }, + ":man_firefighter_tone1:": { + "category": "people", + "name": "man firefighter: light skin tone", + "unicode": "1f468-1f3fb-200d-1f692" + }, + ":man_firefighter_tone2:": { + "category": "people", + "name": "man firefighter: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f692" + }, + ":man_firefighter_tone3:": { + "category": "people", + "name": "man firefighter: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f692" + }, + ":man_firefighter_tone4:": { + "category": "people", + "name": "man firefighter: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f692" + }, + ":man_firefighter_tone5:": { + "category": "people", + "name": "man firefighter: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f692" + }, + ":man_frowning:": { + "category": "people", + "name": "man frowning", + "unicode": "1f64d-200d-2642-fe0f" + }, + ":man_frowning_tone1:": { + "category": "people", + "name": "man frowning: light skin tone", + "unicode": "1f64d-1f3fb-200d-2642-fe0f" + }, + ":man_frowning_tone2:": { + "category": "people", + "name": "man frowning: medium-light skin tone", + "unicode": "1f64d-1f3fc-200d-2642-fe0f" + }, + ":man_frowning_tone3:": { + "category": "people", + "name": "man frowning: medium skin tone", + "unicode": "1f64d-1f3fd-200d-2642-fe0f" + }, + ":man_frowning_tone4:": { + "category": "people", + "name": "man frowning: medium-dark skin tone", + "unicode": "1f64d-1f3fe-200d-2642-fe0f" + }, + ":man_frowning_tone5:": { + "category": "people", + "name": "man frowning: dark skin tone", + "unicode": "1f64d-1f3ff-200d-2642-fe0f" + }, + ":man_genie:": { + "category": "people", + "name": "man genie", + "unicode": "1f9de-200d-2642-fe0f" + }, + ":man_gesturing_no:": { + "category": "people", + "name": "man gesturing NO", + "unicode": "1f645-200d-2642-fe0f" + }, + ":man_gesturing_no_tone1:": { + "category": "people", + "name": "man gesturing NO: light skin tone", + "unicode": "1f645-1f3fb-200d-2642-fe0f" + }, + ":man_gesturing_no_tone2:": { + "category": "people", + "name": "man gesturing NO: medium-light skin tone", + "unicode": "1f645-1f3fc-200d-2642-fe0f" + }, + ":man_gesturing_no_tone3:": { + "category": "people", + "name": "man gesturing NO: medium skin tone", + "unicode": "1f645-1f3fd-200d-2642-fe0f" + }, + ":man_gesturing_no_tone4:": { + "category": "people", + "name": "man gesturing NO: medium-dark skin tone", + "unicode": "1f645-1f3fe-200d-2642-fe0f" + }, + ":man_gesturing_no_tone5:": { + "category": "people", + "name": "man gesturing NO: dark skin tone", + "unicode": "1f645-1f3ff-200d-2642-fe0f" + }, + ":man_gesturing_ok:": { + "category": "people", + "name": "man gesturing OK", + "unicode": "1f646-200d-2642-fe0f" + }, + ":man_gesturing_ok_tone1:": { + "category": "people", + "name": "man gesturing OK: light skin tone", + "unicode": "1f646-1f3fb-200d-2642-fe0f" + }, + ":man_gesturing_ok_tone2:": { + "category": "people", + "name": "man gesturing OK: medium-light skin tone", + "unicode": "1f646-1f3fc-200d-2642-fe0f" + }, + ":man_gesturing_ok_tone3:": { + "category": "people", + "name": "man gesturing OK: medium skin tone", + "unicode": "1f646-1f3fd-200d-2642-fe0f" + }, + ":man_gesturing_ok_tone4:": { + "category": "people", + "name": "man gesturing OK: medium-dark skin tone", + "unicode": "1f646-1f3fe-200d-2642-fe0f" + }, + ":man_gesturing_ok_tone5:": { + "category": "people", + "name": "man gesturing OK: dark skin tone", + "unicode": "1f646-1f3ff-200d-2642-fe0f" + }, + ":man_getting_face_massage:": { + "category": "people", + "name": "man getting massage", + "unicode": "1f486-200d-2642-fe0f" + }, + ":man_getting_face_massage_tone1:": { + "category": "people", + "name": "man getting massage: light skin tone", + "unicode": "1f486-1f3fb-200d-2642-fe0f" + }, + ":man_getting_face_massage_tone2:": { + "category": "people", + "name": "man getting massage: medium-light skin tone", + "unicode": "1f486-1f3fc-200d-2642-fe0f" + }, + ":man_getting_face_massage_tone3:": { + "category": "people", + "name": "man getting massage: medium skin tone", + "unicode": "1f486-1f3fd-200d-2642-fe0f" + }, + ":man_getting_face_massage_tone4:": { + "category": "people", + "name": "man getting massage: medium-dark skin tone", + "unicode": "1f486-1f3fe-200d-2642-fe0f" + }, + ":man_getting_face_massage_tone5:": { + "category": "people", + "name": "man getting massage: dark skin tone", + "unicode": "1f486-1f3ff-200d-2642-fe0f" + }, + ":man_getting_haircut:": { + "category": "people", + "name": "man getting haircut", + "unicode": "1f487-200d-2642-fe0f" + }, + ":man_getting_haircut_tone1:": { + "category": "people", + "name": "man getting haircut: light skin tone", + "unicode": "1f487-1f3fb-200d-2642-fe0f" + }, + ":man_getting_haircut_tone2:": { + "category": "people", + "name": "man getting haircut: medium-light skin tone", + "unicode": "1f487-1f3fc-200d-2642-fe0f" + }, + ":man_getting_haircut_tone3:": { + "category": "people", + "name": "man getting haircut: medium skin tone", + "unicode": "1f487-1f3fd-200d-2642-fe0f" + }, + ":man_getting_haircut_tone4:": { + "category": "people", + "name": "man getting haircut: medium-dark skin tone", + "unicode": "1f487-1f3fe-200d-2642-fe0f" + }, + ":man_getting_haircut_tone5:": { + "category": "people", + "name": "man getting haircut: dark skin tone", + "unicode": "1f487-1f3ff-200d-2642-fe0f" + }, + ":man_golfing:": { + "category": "activity", + "name": "man golfing", + "unicode": "1f3cc-fe0f-200d-2642-fe0f" + }, + ":man_golfing_tone1:": { + "category": "activity", + "name": "man golfing: light skin tone", + "unicode": "1f3cc-1f3fb-200d-2642-fe0f" + }, + ":man_golfing_tone2:": { + "category": "activity", + "name": "man golfing: medium-light skin tone", + "unicode": "1f3cc-1f3fc-200d-2642-fe0f" + }, + ":man_golfing_tone3:": { + "category": "activity", + "name": "man golfing: medium skin tone", + "unicode": "1f3cc-1f3fd-200d-2642-fe0f" + }, + ":man_golfing_tone4:": { + "category": "activity", + "name": "man golfing: medium-dark skin tone", + "unicode": "1f3cc-1f3fe-200d-2642-fe0f" + }, + ":man_golfing_tone5:": { + "category": "activity", + "name": "man golfing: dark skin tone", + "unicode": "1f3cc-1f3ff-200d-2642-fe0f" + }, + ":man_guard:": { + "category": "people", + "name": "man guard", + "unicode": "1f482-200d-2642-fe0f" + }, + ":man_guard_tone1:": { + "category": "people", + "name": "man guard: light skin tone", + "unicode": "1f482-1f3fb-200d-2642-fe0f" + }, + ":man_guard_tone2:": { + "category": "people", + "name": "man guard: medium-light skin tone", + "unicode": "1f482-1f3fc-200d-2642-fe0f" + }, + ":man_guard_tone3:": { + "category": "people", + "name": "man guard: medium skin tone", + "unicode": "1f482-1f3fd-200d-2642-fe0f" + }, + ":man_guard_tone4:": { + "category": "people", + "name": "man guard: medium-dark skin tone", + "unicode": "1f482-1f3fe-200d-2642-fe0f" + }, + ":man_guard_tone5:": { + "category": "people", + "name": "man guard: dark skin tone", + "unicode": "1f482-1f3ff-200d-2642-fe0f" + }, + ":man_health_worker:": { + "category": "people", + "name": "man health worker", + "unicode": "1f468-200d-2695-fe0f" + }, + ":man_health_worker_tone1:": { + "category": "people", + "name": "man health worker: light skin tone", + "unicode": "1f468-1f3fb-200d-2695-fe0f" + }, + ":man_health_worker_tone2:": { + "category": "people", + "name": "man health worker: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-2695-fe0f" + }, + ":man_health_worker_tone3:": { + "category": "people", + "name": "man health worker: medium skin tone", + "unicode": "1f468-1f3fd-200d-2695-fe0f" + }, + ":man_health_worker_tone4:": { + "category": "people", + "name": "man health worker: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-2695-fe0f" + }, + ":man_health_worker_tone5:": { + "category": "people", + "name": "man health worker: dark skin tone", + "unicode": "1f468-1f3ff-200d-2695-fe0f" + }, + ":man_in_lotus_position:": { + "category": "activity", + "name": "man in lotus position", + "unicode": "1f9d8-200d-2642-fe0f" + }, + ":man_in_lotus_position_tone1:": { + "category": "activity", + "name": "man in lotus position: light skin tone", + "unicode": "1f9d8-1f3fb-200d-2642-fe0f" + }, + ":man_in_lotus_position_tone2:": { + "category": "activity", + "name": "man in lotus position: medium-light skin tone", + "unicode": "1f9d8-1f3fc-200d-2642-fe0f" + }, + ":man_in_lotus_position_tone3:": { + "category": "activity", + "name": "man in lotus position: medium skin tone", + "unicode": "1f9d8-1f3fd-200d-2642-fe0f" + }, + ":man_in_lotus_position_tone4:": { + "category": "activity", + "name": "man in lotus position: medium-dark skin tone", + "unicode": "1f9d8-1f3fe-200d-2642-fe0f" + }, + ":man_in_lotus_position_tone5:": { + "category": "activity", + "name": "man in lotus position: dark skin tone", + "unicode": "1f9d8-1f3ff-200d-2642-fe0f" + }, + ":man_in_manual_wheelchair:": { + "category": "people", + "name": "man in manual wheelchair", + "unicode": "1f468-200d-1f9bd" + }, + ":man_in_manual_wheelchair_facing_right:": { + "category": "people", + "name": "man in manual wheelchair facing right", + "unicode": "1f468-200d-1f9bd-200d-27a1-fe0f" + }, + ":man_in_manual_wheelchair_facing_right_tone1:": { + "category": "people", + "name": "man in manual wheelchair facing right: light skin tone", + "unicode": "1f468-1f3fb-200d-1f9bd-200d-27a1-fe0f" + }, + ":man_in_manual_wheelchair_facing_right_tone2:": { + "category": "people", + "name": "man in manual wheelchair facing right: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f9bd-200d-27a1-fe0f" + }, + ":man_in_manual_wheelchair_facing_right_tone3:": { + "category": "people", + "name": "man in manual wheelchair facing right: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f9bd-200d-27a1-fe0f" + }, + ":man_in_manual_wheelchair_facing_right_tone4:": { + "category": "people", + "name": "man in manual wheelchair facing right: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f9bd-200d-27a1-fe0f" + }, + ":man_in_manual_wheelchair_facing_right_tone5:": { + "category": "people", + "name": "man in manual wheelchair facing right: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f9bd-200d-27a1-fe0f" + }, + ":man_in_manual_wheelchair_tone1:": { + "category": "people", + "name": "man in manual wheelchair: light skin tone", + "unicode": "1f468-1f3fb-200d-1f9bd" + }, + ":man_in_manual_wheelchair_tone2:": { + "category": "people", + "name": "man in manual wheelchair: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f9bd" + }, + ":man_in_manual_wheelchair_tone3:": { + "category": "people", + "name": "man in manual wheelchair: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f9bd" + }, + ":man_in_manual_wheelchair_tone4:": { + "category": "people", + "name": "man in manual wheelchair: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f9bd" + }, + ":man_in_manual_wheelchair_tone5:": { + "category": "people", + "name": "man in manual wheelchair: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f9bd" + }, + ":man_in_motorized_wheelchair:": { + "category": "people", + "name": "man in motorized wheelchair", + "unicode": "1f468-200d-1f9bc" + }, + ":man_in_motorized_wheelchair_facing_right:": { + "category": "people", + "name": "man in motorized wheelchair facing right", + "unicode": "1f468-200d-1f9bc-200d-27a1-fe0f" + }, + ":man_in_motorized_wheelchair_facing_right_tone1:": { + "category": "people", + "name": "man in motorized wheelchair facing right: light skin tone", + "unicode": "1f468-1f3fb-200d-1f9bc-200d-27a1-fe0f" + }, + ":man_in_motorized_wheelchair_facing_right_tone2:": { + "category": "people", + "name": "man in motorized wheelchair facing right: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f9bc-200d-27a1-fe0f" + }, + ":man_in_motorized_wheelchair_facing_right_tone3:": { + "category": "people", + "name": "man in motorized wheelchair facing right: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f9bc-200d-27a1-fe0f" + }, + ":man_in_motorized_wheelchair_facing_right_tone4:": { + "category": "people", + "name": "man in motorized wheelchair facing right: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f9bc-200d-27a1-fe0f" + }, + ":man_in_motorized_wheelchair_facing_right_tone5:": { + "category": "people", + "name": "man in motorized wheelchair facing right: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f9bc-200d-27a1-fe0f" + }, + ":man_in_motorized_wheelchair_tone1:": { + "category": "people", + "name": "man in motorized wheelchair: light skin tone", + "unicode": "1f468-1f3fb-200d-1f9bc" + }, + ":man_in_motorized_wheelchair_tone2:": { + "category": "people", + "name": "man in motorized wheelchair: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f9bc" + }, + ":man_in_motorized_wheelchair_tone3:": { + "category": "people", + "name": "man in motorized wheelchair: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f9bc" + }, + ":man_in_motorized_wheelchair_tone4:": { + "category": "people", + "name": "man in motorized wheelchair: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f9bc" + }, + ":man_in_motorized_wheelchair_tone5:": { + "category": "people", + "name": "man in motorized wheelchair: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f9bc" + }, + ":man_in_santa_hat:": { + "category": "people", + "name": "man in santa hat", + "unicode": "1f468-200d-1f384" + }, + ":man_in_santa_hat_tone1:": { + "category": "people", + "name": "man in santa hat: light skin tone", + "unicode": "1f468-1f3fb-200d-1f384" + }, + ":man_in_santa_hat_tone2:": { + "category": "people", + "name": "man in santa hat: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f384" + }, + ":man_in_santa_hat_tone3:": { + "category": "people", + "name": "man in santa hat: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f384" + }, + ":man_in_santa_hat_tone4:": { + "category": "people", + "name": "man in santa hat: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f384" + }, + ":man_in_santa_hat_tone5:": { + "category": "people", + "name": "man in santa hat: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f384" + }, + ":man_in_steamy_room:": { + "category": "people", + "name": "man in steamy room", + "unicode": "1f9d6-200d-2642-fe0f" + }, + ":man_in_steamy_room_tone1:": { + "category": "people", + "name": "man in steamy room: light skin tone", + "unicode": "1f9d6-1f3fb-200d-2642-fe0f" + }, + ":man_in_steamy_room_tone2:": { + "category": "people", + "name": "man in steamy room: medium-light skin tone", + "unicode": "1f9d6-1f3fc-200d-2642-fe0f" + }, + ":man_in_steamy_room_tone3:": { + "category": "people", + "name": "man in steamy room: medium skin tone", + "unicode": "1f9d6-1f3fd-200d-2642-fe0f" + }, + ":man_in_steamy_room_tone4:": { + "category": "people", + "name": "man in steamy room: medium-dark skin tone", + "unicode": "1f9d6-1f3fe-200d-2642-fe0f" + }, + ":man_in_steamy_room_tone5:": { + "category": "people", + "name": "man in steamy room: dark skin tone", + "unicode": "1f9d6-1f3ff-200d-2642-fe0f" + }, + ":man_in_tuxedo:": { + "category": "people", + "name": "man in tuxedo", + "unicode": "1f935-200d-2642-fe0f" + }, + ":man_in_tuxedo_tone1:": { + "category": "people", + "name": "man in tuxedo: light skin tone", + "unicode": "1f935-1f3fb-200d-2642-fe0f" + }, + ":man_in_tuxedo_tone2:": { + "category": "people", + "name": "man in tuxedo: medium-light skin tone", + "unicode": "1f935-1f3fc-200d-2642-fe0f" + }, + ":man_in_tuxedo_tone3:": { + "category": "people", + "name": "man in tuxedo: medium skin tone", + "unicode": "1f935-1f3fd-200d-2642-fe0f" + }, + ":man_in_tuxedo_tone4:": { + "category": "people", + "name": "man in tuxedo: medium-dark skin tone", + "unicode": "1f935-1f3fe-200d-2642-fe0f" + }, + ":man_in_tuxedo_tone5:": { + "category": "people", + "name": "man in tuxedo: dark skin tone", + "unicode": "1f935-1f3ff-200d-2642-fe0f" + }, + ":man_judge:": { + "category": "people", + "name": "man judge", + "unicode": "1f468-200d-2696-fe0f" + }, + ":man_judge_tone1:": { + "category": "people", + "name": "man judge: light skin tone", + "unicode": "1f468-1f3fb-200d-2696-fe0f" + }, + ":man_judge_tone2:": { + "category": "people", + "name": "man judge: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-2696-fe0f" + }, + ":man_judge_tone3:": { + "category": "people", + "name": "man judge: medium skin tone", + "unicode": "1f468-1f3fd-200d-2696-fe0f" + }, + ":man_judge_tone4:": { + "category": "people", + "name": "man judge: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-2696-fe0f" + }, + ":man_judge_tone5:": { + "category": "people", + "name": "man judge: dark skin tone", + "unicode": "1f468-1f3ff-200d-2696-fe0f" + }, + ":man_juggling:": { + "category": "activity", + "name": "man juggling", + "unicode": "1f939-200d-2642-fe0f" + }, + ":man_juggling_tone1:": { + "category": "activity", + "name": "man juggling: light skin tone", + "unicode": "1f939-1f3fb-200d-2642-fe0f" + }, + ":man_juggling_tone2:": { + "category": "activity", + "name": "man juggling: medium-light skin tone", + "unicode": "1f939-1f3fc-200d-2642-fe0f" + }, + ":man_juggling_tone3:": { + "category": "activity", + "name": "man juggling: medium skin tone", + "unicode": "1f939-1f3fd-200d-2642-fe0f" + }, + ":man_juggling_tone4:": { + "category": "activity", + "name": "man juggling: medium-dark skin tone", + "unicode": "1f939-1f3fe-200d-2642-fe0f" + }, + ":man_juggling_tone5:": { + "category": "activity", + "name": "man juggling: dark skin tone", + "unicode": "1f939-1f3ff-200d-2642-fe0f" + }, + ":man_kneeling:": { + "category": "people", + "name": "man kneeling", + "unicode": "1f9ce-200d-2642-fe0f" + }, + ":man_kneeling_facing_right:": { + "category": "people", + "name": "man kneeling facing right", + "unicode": "1f9ce-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_kneeling_facing_right_tone1:": { + "category": "people", + "name": "man kneeling facing right: light skin tone", + "unicode": "1f9ce-1f3fb-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_kneeling_facing_right_tone2:": { + "category": "people", + "name": "man kneeling facing right: medium-light skin tone", + "unicode": "1f9ce-1f3fc-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_kneeling_facing_right_tone3:": { + "category": "people", + "name": "man kneeling facing right: medium skin tone", + "unicode": "1f9ce-1f3fd-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_kneeling_facing_right_tone4:": { + "category": "people", + "name": "man kneeling facing right: medium-dark skin tone", + "unicode": "1f9ce-1f3fe-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_kneeling_facing_right_tone5:": { + "category": "people", + "name": "man kneeling facing right: dark skin tone", + "unicode": "1f9ce-1f3ff-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_kneeling_tone1:": { + "category": "people", + "name": "man kneeling: light skin tone", + "unicode": "1f9ce-1f3fb-200d-2642-fe0f" + }, + ":man_kneeling_tone2:": { + "category": "people", + "name": "man kneeling: medium-light skin tone", + "unicode": "1f9ce-1f3fc-200d-2642-fe0f" + }, + ":man_kneeling_tone3:": { + "category": "people", + "name": "man kneeling: medium skin tone", + "unicode": "1f9ce-1f3fd-200d-2642-fe0f" + }, + ":man_kneeling_tone4:": { + "category": "people", + "name": "man kneeling: medium-dark skin tone", + "unicode": "1f9ce-1f3fe-200d-2642-fe0f" + }, + ":man_kneeling_tone5:": { + "category": "people", + "name": "man kneeling: dark skin tone", + "unicode": "1f9ce-1f3ff-200d-2642-fe0f" + }, + ":man_lifting_weights:": { + "category": "activity", + "name": "man lifting weights", + "unicode": "1f3cb-fe0f-200d-2642-fe0f" + }, + ":man_lifting_weights_tone1:": { + "category": "activity", + "name": "man lifting weights: light skin tone", + "unicode": "1f3cb-1f3fb-200d-2642-fe0f" + }, + ":man_lifting_weights_tone2:": { + "category": "activity", + "name": "man lifting weights: medium-light skin tone", + "unicode": "1f3cb-1f3fc-200d-2642-fe0f" + }, + ":man_lifting_weights_tone3:": { + "category": "activity", + "name": "man lifting weights: medium skin tone", + "unicode": "1f3cb-1f3fd-200d-2642-fe0f" + }, + ":man_lifting_weights_tone4:": { + "category": "activity", + "name": "man lifting weights: medium-dark skin tone", + "unicode": "1f3cb-1f3fe-200d-2642-fe0f" + }, + ":man_lifting_weights_tone5:": { + "category": "activity", + "name": "man lifting weights: dark skin tone", + "unicode": "1f3cb-1f3ff-200d-2642-fe0f" + }, + ":man_mage:": { + "category": "people", + "name": "man mage", + "unicode": "1f9d9-200d-2642-fe0f" + }, + ":man_mage_tone1:": { + "category": "people", + "name": "man mage: light skin tone", + "unicode": "1f9d9-1f3fb-200d-2642-fe0f" + }, + ":man_mage_tone2:": { + "category": "people", + "name": "man mage: medium-light skin tone", + "unicode": "1f9d9-1f3fc-200d-2642-fe0f" + }, + ":man_mage_tone3:": { + "category": "people", + "name": "man mage: medium skin tone", + "unicode": "1f9d9-1f3fd-200d-2642-fe0f" + }, + ":man_mage_tone4:": { + "category": "people", + "name": "man mage: medium-dark skin tone", + "unicode": "1f9d9-1f3fe-200d-2642-fe0f" + }, + ":man_mage_tone5:": { + "category": "people", + "name": "man mage: dark skin tone", + "unicode": "1f9d9-1f3ff-200d-2642-fe0f" + }, + ":man_mechanic:": { + "category": "people", + "name": "man mechanic", + "unicode": "1f468-200d-1f527" + }, + ":man_mechanic_tone1:": { + "category": "people", + "name": "man mechanic: light skin tone", + "unicode": "1f468-1f3fb-200d-1f527" + }, + ":man_mechanic_tone2:": { + "category": "people", + "name": "man mechanic: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f527" + }, + ":man_mechanic_tone3:": { + "category": "people", + "name": "man mechanic: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f527" + }, + ":man_mechanic_tone4:": { + "category": "people", + "name": "man mechanic: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f527" + }, + ":man_mechanic_tone5:": { + "category": "people", + "name": "man mechanic: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f527" + }, + ":man_mountain_biking:": { + "category": "activity", + "name": "man mountain biking", + "unicode": "1f6b5-200d-2642-fe0f" + }, + ":man_mountain_biking_tone1:": { + "category": "activity", + "name": "man mountain biking: light skin tone", + "unicode": "1f6b5-1f3fb-200d-2642-fe0f" + }, + ":man_mountain_biking_tone2:": { + "category": "activity", + "name": "man mountain biking: medium-light skin tone", + "unicode": "1f6b5-1f3fc-200d-2642-fe0f" + }, + ":man_mountain_biking_tone3:": { + "category": "activity", + "name": "man mountain biking: medium skin tone", + "unicode": "1f6b5-1f3fd-200d-2642-fe0f" + }, + ":man_mountain_biking_tone4:": { + "category": "activity", + "name": "man mountain biking: medium-dark skin tone", + "unicode": "1f6b5-1f3fe-200d-2642-fe0f" + }, + ":man_mountain_biking_tone5:": { + "category": "activity", + "name": "man mountain biking: dark skin tone", + "unicode": "1f6b5-1f3ff-200d-2642-fe0f" + }, + ":man_office_worker:": { + "category": "people", + "name": "man office worker", + "unicode": "1f468-200d-1f4bc" + }, + ":man_office_worker_tone1:": { + "category": "people", + "name": "man office worker: light skin tone", + "unicode": "1f468-1f3fb-200d-1f4bc" + }, + ":man_office_worker_tone2:": { + "category": "people", + "name": "man office worker: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f4bc" + }, + ":man_office_worker_tone3:": { + "category": "people", + "name": "man office worker: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f4bc" + }, + ":man_office_worker_tone4:": { + "category": "people", + "name": "man office worker: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f4bc" + }, + ":man_office_worker_tone5:": { + "category": "people", + "name": "man office worker: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f4bc" + }, + ":man_pilot:": { + "category": "people", + "name": "man pilot", + "unicode": "1f468-200d-2708-fe0f" + }, + ":man_pilot_tone1:": { + "category": "people", + "name": "man pilot: light skin tone", + "unicode": "1f468-1f3fb-200d-2708-fe0f" + }, + ":man_pilot_tone2:": { + "category": "people", + "name": "man pilot: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-2708-fe0f" + }, + ":man_pilot_tone3:": { + "category": "people", + "name": "man pilot: medium skin tone", + "unicode": "1f468-1f3fd-200d-2708-fe0f" + }, + ":man_pilot_tone4:": { + "category": "people", + "name": "man pilot: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-2708-fe0f" + }, + ":man_pilot_tone5:": { + "category": "people", + "name": "man pilot: dark skin tone", + "unicode": "1f468-1f3ff-200d-2708-fe0f" + }, + ":man_playing_handball:": { + "category": "activity", + "name": "man playing handball", + "unicode": "1f93e-200d-2642-fe0f" + }, + ":man_playing_handball_tone1:": { + "category": "activity", + "name": "man playing handball: light skin tone", + "unicode": "1f93e-1f3fb-200d-2642-fe0f" + }, + ":man_playing_handball_tone2:": { + "category": "activity", + "name": "man playing handball: medium-light skin tone", + "unicode": "1f93e-1f3fc-200d-2642-fe0f" + }, + ":man_playing_handball_tone3:": { + "category": "activity", + "name": "man playing handball: medium skin tone", + "unicode": "1f93e-1f3fd-200d-2642-fe0f" + }, + ":man_playing_handball_tone4:": { + "category": "activity", + "name": "man playing handball: medium-dark skin tone", + "unicode": "1f93e-1f3fe-200d-2642-fe0f" + }, + ":man_playing_handball_tone5:": { + "category": "activity", + "name": "man playing handball: dark skin tone", + "unicode": "1f93e-1f3ff-200d-2642-fe0f" + }, + ":man_playing_water_polo:": { + "category": "activity", + "name": "man playing water polo", + "unicode": "1f93d-200d-2642-fe0f" + }, + ":man_playing_water_polo_tone1:": { + "category": "activity", + "name": "man playing water polo: light skin tone", + "unicode": "1f93d-1f3fb-200d-2642-fe0f" + }, + ":man_playing_water_polo_tone2:": { + "category": "activity", + "name": "man playing water polo: medium-light skin tone", + "unicode": "1f93d-1f3fc-200d-2642-fe0f" + }, + ":man_playing_water_polo_tone3:": { + "category": "activity", + "name": "man playing water polo: medium skin tone", + "unicode": "1f93d-1f3fd-200d-2642-fe0f" + }, + ":man_playing_water_polo_tone4:": { + "category": "activity", + "name": "man playing water polo: medium-dark skin tone", + "unicode": "1f93d-1f3fe-200d-2642-fe0f" + }, + ":man_playing_water_polo_tone5:": { + "category": "activity", + "name": "man playing water polo: dark skin tone", + "unicode": "1f93d-1f3ff-200d-2642-fe0f" + }, + ":man_police_officer:": { + "category": "people", + "name": "man police officer", + "unicode": "1f46e-200d-2642-fe0f" + }, + ":man_police_officer_tone1:": { + "category": "people", + "name": "man police officer: light skin tone", + "unicode": "1f46e-1f3fb-200d-2642-fe0f" + }, + ":man_police_officer_tone2:": { + "category": "people", + "name": "man police officer: medium-light skin tone", + "unicode": "1f46e-1f3fc-200d-2642-fe0f" + }, + ":man_police_officer_tone3:": { + "category": "people", + "name": "man police officer: medium skin tone", + "unicode": "1f46e-1f3fd-200d-2642-fe0f" + }, + ":man_police_officer_tone4:": { + "category": "people", + "name": "man police officer: medium-dark skin tone", + "unicode": "1f46e-1f3fe-200d-2642-fe0f" + }, + ":man_police_officer_tone5:": { + "category": "people", + "name": "man police officer: dark skin tone", + "unicode": "1f46e-1f3ff-200d-2642-fe0f" + }, + ":man_pouting:": { + "category": "people", + "name": "man pouting", + "unicode": "1f64e-200d-2642-fe0f" + }, + ":man_pouting_tone1:": { + "category": "people", + "name": "man pouting: light skin tone", + "unicode": "1f64e-1f3fb-200d-2642-fe0f" + }, + ":man_pouting_tone2:": { + "category": "people", + "name": "man pouting: medium-light skin tone", + "unicode": "1f64e-1f3fc-200d-2642-fe0f" + }, + ":man_pouting_tone3:": { + "category": "people", + "name": "man pouting: medium skin tone", + "unicode": "1f64e-1f3fd-200d-2642-fe0f" + }, + ":man_pouting_tone4:": { + "category": "people", + "name": "man pouting: medium-dark skin tone", + "unicode": "1f64e-1f3fe-200d-2642-fe0f" + }, + ":man_pouting_tone5:": { + "category": "people", + "name": "man pouting: dark skin tone", + "unicode": "1f64e-1f3ff-200d-2642-fe0f" + }, + ":man_raising_hand:": { + "category": "people", + "name": "man raising hand", + "unicode": "1f64b-200d-2642-fe0f" + }, + ":man_raising_hand_tone1:": { + "category": "people", + "name": "man raising hand: light skin tone", + "unicode": "1f64b-1f3fb-200d-2642-fe0f" + }, + ":man_raising_hand_tone2:": { + "category": "people", + "name": "man raising hand: medium-light skin tone", + "unicode": "1f64b-1f3fc-200d-2642-fe0f" + }, + ":man_raising_hand_tone3:": { + "category": "people", + "name": "man raising hand: medium skin tone", + "unicode": "1f64b-1f3fd-200d-2642-fe0f" + }, + ":man_raising_hand_tone4:": { + "category": "people", + "name": "man raising hand: medium-dark skin tone", + "unicode": "1f64b-1f3fe-200d-2642-fe0f" + }, + ":man_raising_hand_tone5:": { + "category": "people", + "name": "man raising hand: dark skin tone", + "unicode": "1f64b-1f3ff-200d-2642-fe0f" + }, + ":man_red_haired:": { + "category": "people", + "name": "man: red hair", + "unicode": "1f468-200d-1f9b0" + }, + ":man_red_haired_tone1:": { + "category": "people", + "name": "man, red haired: light skin tone", + "unicode": "1f468-1f3fb-200d-1f9b0" + }, + ":man_red_haired_tone2:": { + "category": "people", + "name": "man, red haired: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f9b0" + }, + ":man_red_haired_tone3:": { + "category": "people", + "name": "man, red haired: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f9b0" + }, + ":man_red_haired_tone4:": { + "category": "people", + "name": "man, red haired: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f9b0" + }, + ":man_red_haired_tone5:": { + "category": "people", + "name": "man, red haired: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f9b0" + }, + ":man_rowing_boat:": { + "category": "activity", + "name": "man rowing boat", + "unicode": "1f6a3-200d-2642-fe0f" + }, + ":man_rowing_boat_tone1:": { + "category": "activity", + "name": "man rowing boat: light skin tone", + "unicode": "1f6a3-1f3fb-200d-2642-fe0f" + }, + ":man_rowing_boat_tone2:": { + "category": "activity", + "name": "man rowing boat: medium-light skin tone", + "unicode": "1f6a3-1f3fc-200d-2642-fe0f" + }, + ":man_rowing_boat_tone3:": { + "category": "activity", + "name": "man rowing boat: medium skin tone", + "unicode": "1f6a3-1f3fd-200d-2642-fe0f" + }, + ":man_rowing_boat_tone4:": { + "category": "activity", + "name": "man rowing boat: medium-dark skin tone", + "unicode": "1f6a3-1f3fe-200d-2642-fe0f" + }, + ":man_rowing_boat_tone5:": { + "category": "activity", + "name": "man rowing boat: dark skin tone", + "unicode": "1f6a3-1f3ff-200d-2642-fe0f" + }, + ":man_running:": { + "category": "people", + "name": "man running", + "unicode": "1f3c3-200d-2642-fe0f" + }, + ":man_running_facing_right:": { + "category": "people", + "name": "man running facing right", + "unicode": "1f3c3-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_running_facing_right_tone1:": { + "category": "people", + "name": "man running facing right: light skin tone", + "unicode": "1f3c3-1f3fb-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_running_facing_right_tone2:": { + "category": "people", + "name": "man running facing right: medium-light skin tone", + "unicode": "1f3c3-1f3fc-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_running_facing_right_tone3:": { + "category": "people", + "name": "man running facing right: medium skin tone", + "unicode": "1f3c3-1f3fd-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_running_facing_right_tone4:": { + "category": "people", + "name": "man running facing right: medium-dark skin tone", + "unicode": "1f3c3-1f3fe-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_running_facing_right_tone5:": { + "category": "people", + "name": "man running facing right: dark skin tone", + "unicode": "1f3c3-1f3ff-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_running_tone1:": { + "category": "people", + "name": "man running: light skin tone", + "unicode": "1f3c3-1f3fb-200d-2642-fe0f" + }, + ":man_running_tone2:": { + "category": "people", + "name": "man running: medium-light skin tone", + "unicode": "1f3c3-1f3fc-200d-2642-fe0f" + }, + ":man_running_tone3:": { + "category": "people", + "name": "man running: medium skin tone", + "unicode": "1f3c3-1f3fd-200d-2642-fe0f" + }, + ":man_running_tone4:": { + "category": "people", + "name": "man running: medium-dark skin tone", + "unicode": "1f3c3-1f3fe-200d-2642-fe0f" + }, + ":man_running_tone5:": { + "category": "people", + "name": "man running: dark skin tone", + "unicode": "1f3c3-1f3ff-200d-2642-fe0f" + }, + ":man_scientist:": { + "category": "people", + "name": "man scientist", + "unicode": "1f468-200d-1f52c" + }, + ":man_scientist_tone1:": { + "category": "people", + "name": "man scientist: light skin tone", + "unicode": "1f468-1f3fb-200d-1f52c" + }, + ":man_scientist_tone2:": { + "category": "people", + "name": "man scientist: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f52c" + }, + ":man_scientist_tone3:": { + "category": "people", + "name": "man scientist: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f52c" + }, + ":man_scientist_tone4:": { + "category": "people", + "name": "man scientist: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f52c" + }, + ":man_scientist_tone5:": { + "category": "people", + "name": "man scientist: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f52c" + }, + ":man_shrugging:": { + "category": "people", + "name": "man shrugging", + "unicode": "1f937-200d-2642-fe0f" + }, + ":man_shrugging_tone1:": { + "category": "people", + "name": "man shrugging: light skin tone", + "unicode": "1f937-1f3fb-200d-2642-fe0f" + }, + ":man_shrugging_tone2:": { + "category": "people", + "name": "man shrugging: medium-light skin tone", + "unicode": "1f937-1f3fc-200d-2642-fe0f" + }, + ":man_shrugging_tone3:": { + "category": "people", + "name": "man shrugging: medium skin tone", + "unicode": "1f937-1f3fd-200d-2642-fe0f" + }, + ":man_shrugging_tone4:": { + "category": "people", + "name": "man shrugging: medium-dark skin tone", + "unicode": "1f937-1f3fe-200d-2642-fe0f" + }, + ":man_shrugging_tone5:": { + "category": "people", + "name": "man shrugging: dark skin tone", + "unicode": "1f937-1f3ff-200d-2642-fe0f" + }, + ":man_singer:": { + "category": "people", + "name": "man singer", + "unicode": "1f468-200d-1f3a4" + }, + ":man_singer_tone1:": { + "category": "people", + "name": "man singer: light skin tone", + "unicode": "1f468-1f3fb-200d-1f3a4" + }, + ":man_singer_tone2:": { + "category": "people", + "name": "man singer: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f3a4" + }, + ":man_singer_tone3:": { + "category": "people", + "name": "man singer: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f3a4" + }, + ":man_singer_tone4:": { + "category": "people", + "name": "man singer: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f3a4" + }, + ":man_singer_tone5:": { + "category": "people", + "name": "man singer: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f3a4" + }, + ":man_standing:": { + "category": "people", + "name": "man standing", + "unicode": "1f9cd-200d-2642-fe0f" + }, + ":man_standing_tone1:": { + "category": "people", + "name": "man standing: light skin tone", + "unicode": "1f9cd-1f3fb-200d-2642-fe0f" + }, + ":man_standing_tone2:": { + "category": "people", + "name": "man standing: medium-light skin tone", + "unicode": "1f9cd-1f3fc-200d-2642-fe0f" + }, + ":man_standing_tone3:": { + "category": "people", + "name": "man standing: medium skin tone", + "unicode": "1f9cd-1f3fd-200d-2642-fe0f" + }, + ":man_standing_tone4:": { + "category": "people", + "name": "man standing: medium-dark skin tone", + "unicode": "1f9cd-1f3fe-200d-2642-fe0f" + }, + ":man_standing_tone5:": { + "category": "people", + "name": "man standing: dark skin tone", + "unicode": "1f9cd-1f3ff-200d-2642-fe0f" + }, + ":man_student:": { + "category": "people", + "name": "man student", + "unicode": "1f468-200d-1f393" + }, + ":man_student_tone1:": { + "category": "people", + "name": "man student: light skin tone", + "unicode": "1f468-1f3fb-200d-1f393" + }, + ":man_student_tone2:": { + "category": "people", + "name": "man student: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f393" + }, + ":man_student_tone3:": { + "category": "people", + "name": "man student: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f393" + }, + ":man_student_tone4:": { + "category": "people", + "name": "man student: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f393" + }, + ":man_student_tone5:": { + "category": "people", + "name": "man student: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f393" + }, + ":man_superhero:": { + "category": "people", + "name": "man superhero", + "unicode": "1f9b8-200d-2642-fe0f" + }, + ":man_superhero_tone1:": { + "category": "people", + "name": "man superhero: light skin tone", + "unicode": "1f9b8-1f3fb-200d-2642-fe0f" + }, + ":man_superhero_tone2:": { + "category": "people", + "name": "man superhero: medium-light skin tone", + "unicode": "1f9b8-1f3fc-200d-2642-fe0f" + }, + ":man_superhero_tone3:": { + "category": "people", + "name": "man superhero: medium skin tone", + "unicode": "1f9b8-1f3fd-200d-2642-fe0f" + }, + ":man_superhero_tone4:": { + "category": "people", + "name": "man superhero: medium-dark skin tone", + "unicode": "1f9b8-1f3fe-200d-2642-fe0f" + }, + ":man_superhero_tone5:": { + "category": "people", + "name": "man superhero: dark skin tone", + "unicode": "1f9b8-1f3ff-200d-2642-fe0f" + }, + ":man_supervillain:": { + "category": "people", + "name": "man supervillain", + "unicode": "1f9b9-200d-2642-fe0f" + }, + ":man_supervillain_tone1:": { + "category": "people", + "name": "man supervillain: light skin tone", + "unicode": "1f9b9-1f3fb-200d-2642-fe0f" + }, + ":man_supervillain_tone2:": { + "category": "people", + "name": "man supervillain: medium-light skin tone", + "unicode": "1f9b9-1f3fc-200d-2642-fe0f" + }, + ":man_supervillain_tone3:": { + "category": "people", + "name": "man supervillain: medium skin tone", + "unicode": "1f9b9-1f3fd-200d-2642-fe0f" + }, + ":man_supervillain_tone4:": { + "category": "people", + "name": "man supervillain: medium-dark skin tone", + "unicode": "1f9b9-1f3fe-200d-2642-fe0f" + }, + ":man_supervillain_tone5:": { + "category": "people", + "name": "man supervillain: dark skin tone", + "unicode": "1f9b9-1f3ff-200d-2642-fe0f" + }, + ":man_surfing:": { + "category": "activity", + "name": "man surfing", + "unicode": "1f3c4-200d-2642-fe0f" + }, + ":man_surfing_tone1:": { + "category": "activity", + "name": "man surfing: light skin tone", + "unicode": "1f3c4-1f3fb-200d-2642-fe0f" + }, + ":man_surfing_tone2:": { + "category": "activity", + "name": "man surfing: medium-light skin tone", + "unicode": "1f3c4-1f3fc-200d-2642-fe0f" + }, + ":man_surfing_tone3:": { + "category": "activity", + "name": "man surfing: medium skin tone", + "unicode": "1f3c4-1f3fd-200d-2642-fe0f" + }, + ":man_surfing_tone4:": { + "category": "activity", + "name": "man surfing: medium-dark skin tone", + "unicode": "1f3c4-1f3fe-200d-2642-fe0f" + }, + ":man_surfing_tone5:": { + "category": "activity", + "name": "man surfing: dark skin tone", + "unicode": "1f3c4-1f3ff-200d-2642-fe0f" + }, + ":man_swimming:": { + "category": "activity", + "name": "man swimming", + "unicode": "1f3ca-200d-2642-fe0f" + }, + ":man_swimming_tone1:": { + "category": "activity", + "name": "man swimming: light skin tone", + "unicode": "1f3ca-1f3fb-200d-2642-fe0f" + }, + ":man_swimming_tone2:": { + "category": "activity", + "name": "man swimming: medium-light skin tone", + "unicode": "1f3ca-1f3fc-200d-2642-fe0f" + }, + ":man_swimming_tone3:": { + "category": "activity", + "name": "man swimming: medium skin tone", + "unicode": "1f3ca-1f3fd-200d-2642-fe0f" + }, + ":man_swimming_tone4:": { + "category": "activity", + "name": "man swimming: medium-dark skin tone", + "unicode": "1f3ca-1f3fe-200d-2642-fe0f" + }, + ":man_swimming_tone5:": { + "category": "activity", + "name": "man swimming: dark skin tone", + "unicode": "1f3ca-1f3ff-200d-2642-fe0f" + }, + ":man_teacher:": { + "category": "people", + "name": "man teacher", + "unicode": "1f468-200d-1f3eb" + }, + ":man_teacher_tone1:": { + "category": "people", + "name": "man teacher: light skin tone", + "unicode": "1f468-1f3fb-200d-1f3eb" + }, + ":man_teacher_tone2:": { + "category": "people", + "name": "man teacher: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f3eb" + }, + ":man_teacher_tone3:": { + "category": "people", + "name": "man teacher: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f3eb" + }, + ":man_teacher_tone4:": { + "category": "people", + "name": "man teacher: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f3eb" + }, + ":man_teacher_tone5:": { + "category": "people", + "name": "man teacher: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f3eb" + }, + ":man_technologist:": { + "category": "people", + "name": "man technologist", + "unicode": "1f468-200d-1f4bb" + }, + ":man_technologist_tone1:": { + "category": "people", + "name": "man technologist: light skin tone", + "unicode": "1f468-1f3fb-200d-1f4bb" + }, + ":man_technologist_tone2:": { + "category": "people", + "name": "man technologist: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f4bb" + }, + ":man_technologist_tone3:": { + "category": "people", + "name": "man technologist: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f4bb" + }, + ":man_technologist_tone4:": { + "category": "people", + "name": "man technologist: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f4bb" + }, + ":man_technologist_tone5:": { + "category": "people", + "name": "man technologist: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f4bb" + }, + ":man_tipping_hand:": { + "category": "people", + "name": "man tipping hand", + "unicode": "1f481-200d-2642-fe0f" + }, + ":man_tipping_hand_tone1:": { + "category": "people", + "name": "man tipping hand: light skin tone", + "unicode": "1f481-1f3fb-200d-2642-fe0f" + }, + ":man_tipping_hand_tone2:": { + "category": "people", + "name": "man tipping hand: medium-light skin tone", + "unicode": "1f481-1f3fc-200d-2642-fe0f" + }, + ":man_tipping_hand_tone3:": { + "category": "people", + "name": "man tipping hand: medium skin tone", + "unicode": "1f481-1f3fd-200d-2642-fe0f" + }, + ":man_tipping_hand_tone4:": { + "category": "people", + "name": "man tipping hand: medium-dark skin tone", + "unicode": "1f481-1f3fe-200d-2642-fe0f" + }, + ":man_tipping_hand_tone5:": { + "category": "people", + "name": "man tipping hand: dark skin tone", + "unicode": "1f481-1f3ff-200d-2642-fe0f" + }, + ":man_tone1:": { + "category": "people", + "name": "man: light skin tone", + "unicode": "1f468-1f3fb" + }, + ":man_tone1_beard:": { + "category": "people", + "name": "man: light skin tone, beard", + "unicode": "1f9d4-1f3fb-200d-2642-fe0f" + }, + ":man_tone2:": { + "category": "people", + "name": "man: medium-light skin tone", + "unicode": "1f468-1f3fc" + }, + ":man_tone2_beard:": { + "category": "people", + "name": "man: medium-light skin tone, beard", + "unicode": "1f9d4-1f3fc-200d-2642-fe0f" + }, + ":man_tone3:": { + "category": "people", + "name": "man: medium skin tone", + "unicode": "1f468-1f3fd" + }, + ":man_tone3_beard:": { + "category": "people", + "name": "man: medium skin tone, beard", + "unicode": "1f9d4-1f3fd-200d-2642-fe0f" + }, + ":man_tone4:": { + "category": "people", + "name": "man: medium-dark skin tone", + "unicode": "1f468-1f3fe" + }, + ":man_tone4_beard:": { + "category": "people", + "name": "man: medium-dark skin tone, beard", + "unicode": "1f9d4-1f3fe-200d-2642-fe0f" + }, + ":man_tone5:": { + "category": "people", + "name": "man: dark skin tone", + "unicode": "1f468-1f3ff" + }, + ":man_tone5_beard:": { + "category": "people", + "name": "man: dark skin tone, beard", + "unicode": "1f9d4-1f3ff-200d-2642-fe0f" + }, + ":man_vampire:": { + "category": "people", + "name": "man vampire", + "unicode": "1f9db-200d-2642-fe0f" + }, + ":man_vampire_tone1:": { + "category": "people", + "name": "man vampire: light skin tone", + "unicode": "1f9db-1f3fb-200d-2642-fe0f" + }, + ":man_vampire_tone2:": { + "category": "people", + "name": "man vampire: medium-light skin tone", + "unicode": "1f9db-1f3fc-200d-2642-fe0f" + }, + ":man_vampire_tone3:": { + "category": "people", + "name": "man vampire: medium skin tone", + "unicode": "1f9db-1f3fd-200d-2642-fe0f" + }, + ":man_vampire_tone4:": { + "category": "people", + "name": "man vampire: medium-dark skin tone", + "unicode": "1f9db-1f3fe-200d-2642-fe0f" + }, + ":man_vampire_tone5:": { + "category": "people", + "name": "man vampire: dark skin tone", + "unicode": "1f9db-1f3ff-200d-2642-fe0f" + }, + ":man_walking:": { + "category": "people", + "name": "man walking", + "unicode": "1f6b6-200d-2642-fe0f" + }, + ":man_walking_facing_right:": { + "category": "people", + "name": "man walking facing right", + "unicode": "1f6b6-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_walking_facing_right_tone1:": { + "category": "people", + "name": "man walking facing right: light skin tone", + "unicode": "1f6b6-1f3fb-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_walking_facing_right_tone2:": { + "category": "people", + "name": "man walking facing right: medium-light skin tone", + "unicode": "1f6b6-1f3fc-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_walking_facing_right_tone3:": { + "category": "people", + "name": "man walking facing right: medium skin tone", + "unicode": "1f6b6-1f3fd-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_walking_facing_right_tone4:": { + "category": "people", + "name": "man walking facing right: medium-dark skin tone", + "unicode": "1f6b6-1f3fe-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_walking_facing_right_tone5:": { + "category": "people", + "name": "man walking facing right: dark skin tone", + "unicode": "1f6b6-1f3ff-200d-2642-fe0f-200d-27a1-fe0f" + }, + ":man_walking_tone1:": { + "category": "people", + "name": "man walking: light skin tone", + "unicode": "1f6b6-1f3fb-200d-2642-fe0f" + }, + ":man_walking_tone2:": { + "category": "people", + "name": "man walking: medium-light skin tone", + "unicode": "1f6b6-1f3fc-200d-2642-fe0f" + }, + ":man_walking_tone3:": { + "category": "people", + "name": "man walking: medium skin tone", + "unicode": "1f6b6-1f3fd-200d-2642-fe0f" + }, + ":man_walking_tone4:": { + "category": "people", + "name": "man walking: medium-dark skin tone", + "unicode": "1f6b6-1f3fe-200d-2642-fe0f" + }, + ":man_walking_tone5:": { + "category": "people", + "name": "man walking: dark skin tone", + "unicode": "1f6b6-1f3ff-200d-2642-fe0f" + }, + ":man_wearing_turban:": { + "category": "people", + "name": "man wearing turban", + "unicode": "1f473-200d-2642-fe0f" + }, + ":man_wearing_turban_tone1:": { + "category": "people", + "name": "man wearing turban: light skin tone", + "unicode": "1f473-1f3fb-200d-2642-fe0f" + }, + ":man_wearing_turban_tone2:": { + "category": "people", + "name": "man wearing turban: medium-light skin tone", + "unicode": "1f473-1f3fc-200d-2642-fe0f" + }, + ":man_wearing_turban_tone3:": { + "category": "people", + "name": "man wearing turban: medium skin tone", + "unicode": "1f473-1f3fd-200d-2642-fe0f" + }, + ":man_wearing_turban_tone4:": { + "category": "people", + "name": "man wearing turban: medium-dark skin tone", + "unicode": "1f473-1f3fe-200d-2642-fe0f" + }, + ":man_wearing_turban_tone5:": { + "category": "people", + "name": "man wearing turban: dark skin tone", + "unicode": "1f473-1f3ff-200d-2642-fe0f" + }, + ":man_white_haired:": { + "category": "people", + "name": "man: white hair", + "unicode": "1f468-200d-1f9b3" + }, + ":man_white_haired_tone1:": { + "category": "people", + "name": "man, white haired: light skin tone", + "unicode": "1f468-1f3fb-200d-1f9b3" + }, + ":man_white_haired_tone2:": { + "category": "people", + "name": "man, white haired: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f9b3" + }, + ":man_white_haired_tone3:": { + "category": "people", + "name": "man, white haired: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f9b3" + }, + ":man_white_haired_tone4:": { + "category": "people", + "name": "man, white haired: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f9b3" + }, + ":man_white_haired_tone5:": { + "category": "people", + "name": "man, white haired: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f9b3" + }, + ":man_with_chinese_cap:": { + "category": "people", + "name": "man with Chinese cap", + "unicode": "1f472" + }, + ":man_with_chinese_cap_tone1:": { + "category": "people", + "name": "man with Chinese cap: light skin tone", + "unicode": "1f472-1f3fb" + }, + ":man_with_chinese_cap_tone2:": { + "category": "people", + "name": "man with Chinese cap: medium-light skin tone", + "unicode": "1f472-1f3fc" + }, + ":man_with_chinese_cap_tone3:": { + "category": "people", + "name": "man with Chinese cap: medium skin tone", + "unicode": "1f472-1f3fd" + }, + ":man_with_chinese_cap_tone4:": { + "category": "people", + "name": "man with Chinese cap: medium-dark skin tone", + "unicode": "1f472-1f3fe" + }, + ":man_with_chinese_cap_tone5:": { + "category": "people", + "name": "man with Chinese cap: dark skin tone", + "unicode": "1f472-1f3ff" + }, + ":man_with_probing_cane:": { + "category": "people", + "name": "man with probing cane", + "unicode": "1f468-200d-1f9af" + }, + ":man_with_probing_cane_tone1:": { + "category": "people", + "name": "man with probing cane: light skin tone", + "unicode": "1f468-1f3fb-200d-1f9af" + }, + ":man_with_probing_cane_tone2:": { + "category": "people", + "name": "man with probing cane: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f9af" + }, + ":man_with_probing_cane_tone3:": { + "category": "people", + "name": "man with probing cane: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f9af" + }, + ":man_with_probing_cane_tone4:": { + "category": "people", + "name": "man with probing cane: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f9af" + }, + ":man_with_probing_cane_tone5:": { + "category": "people", + "name": "man with probing cane: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f9af" + }, + ":man_with_veil:": { + "category": "people", + "name": "man with veil", + "unicode": "1f470-200d-2642-fe0f" + }, + ":man_with_veil_tone1:": { + "category": "people", + "name": "man with veil: light skin tone", + "unicode": "1f470-1f3fb-200d-2642-fe0f" + }, + ":man_with_veil_tone2:": { + "category": "people", + "name": "man with veil: medium-light skin tone", + "unicode": "1f470-1f3fc-200d-2642-fe0f" + }, + ":man_with_veil_tone3:": { + "category": "people", + "name": "man with veil: medium skin tone", + "unicode": "1f470-1f3fd-200d-2642-fe0f" + }, + ":man_with_veil_tone4:": { + "category": "people", + "name": "man with veil: medium-dark skin tone", + "unicode": "1f470-1f3fe-200d-2642-fe0f" + }, + ":man_with_veil_tone5:": { + "category": "people", + "name": "man with veil: dark skin tone", + "unicode": "1f470-1f3ff-200d-2642-fe0f" + }, + ":man_with_white_cane_facing_right:": { + "category": "people", + "name": "man with white cane facing right", + "unicode": "1f468-200d-1f9af-200d-27a1-fe0f" + }, + ":man_with_white_cane_facing_right_tone1:": { + "category": "people", + "name": "man with white cane facing right: light skin tone", + "unicode": "1f468-1f3fb-200d-1f9af-200d-27a1-fe0f" + }, + ":man_with_white_cane_facing_right_tone2:": { + "category": "people", + "name": "man with white cane facing right: medium-light skin tone", + "unicode": "1f468-1f3fc-200d-1f9af-200d-27a1-fe0f" + }, + ":man_with_white_cane_facing_right_tone3:": { + "category": "people", + "name": "man with white cane facing right: medium skin tone", + "unicode": "1f468-1f3fd-200d-1f9af-200d-27a1-fe0f" + }, + ":man_with_white_cane_facing_right_tone4:": { + "category": "people", + "name": "man with white cane facing right: medium-dark skin tone", + "unicode": "1f468-1f3fe-200d-1f9af-200d-27a1-fe0f" + }, + ":man_with_white_cane_facing_right_tone5:": { + "category": "people", + "name": "man with white cane facing right: dark skin tone", + "unicode": "1f468-1f3ff-200d-1f9af-200d-27a1-fe0f" + }, + ":man_zombie:": { + "category": "people", + "name": "man zombie", + "unicode": "1f9df-200d-2642-fe0f" + }, + ":mango:": { + "category": "food", + "name": "mango", + "unicode": "1f96d" + }, + ":mans_shoe:": { + "category": "people", + "name": "man\u2019s shoe", + "unicode": "1f45e" + }, + ":manual_wheelchair:": { + "category": "travel", + "name": "manual wheelchair", + "unicode": "1f9bd" + }, + ":map:": { + "category": "travel", + "name": "world map", + "unicode": "1f5fa" + }, + ":maple_leaf:": { + "category": "nature", + "name": "maple leaf", + "unicode": "1f341" + }, + ":maracas:": { + "category": "activity", + "name": "maracas", + "unicode": "1fa87" + }, + ":martial_arts_uniform:": { + "category": "activity", + "name": "martial arts uniform", + "unicode": "1f94b" + }, + ":mask:": { + "category": "people", + "name": "face with medical mask", + "unicode": "1f637" + }, + ":mate:": { + "category": "food", + "name": "mate", + "unicode": "1f9c9" + }, + ":meat_on_bone:": { + "category": "food", + "name": "meat on bone", + "unicode": "1f356" + }, + ":mechanic:": { + "category": "people", + "name": "mechanic", + "unicode": "1f9d1-200d-1f527" + }, + ":mechanic_tone1:": { + "category": "people", + "name": "mechanic: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f527" + }, + ":mechanic_tone2:": { + "category": "people", + "name": "mechanic: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f527" + }, + ":mechanic_tone3:": { + "category": "people", + "name": "mechanic: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f527" + }, + ":mechanic_tone4:": { + "category": "people", + "name": "mechanic: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f527" + }, + ":mechanic_tone5:": { + "category": "people", + "name": "mechanic: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f527" + }, + ":mechanical_arm:": { + "category": "people", + "name": "mechanical arm", + "unicode": "1f9be" + }, + ":mechanical_leg:": { + "category": "people", + "name": "mechanical leg", + "unicode": "1f9bf" + }, + ":medal:": { + "category": "activity", + "name": "sports medal", + "unicode": "1f3c5" + }, + ":medical_symbol:": { + "category": "symbols", + "name": "medical symbol", + "unicode": "2695" + }, + ":mega:": { + "category": "symbols", + "name": "megaphone", + "unicode": "1f4e3" + }, + ":melon:": { + "category": "food", + "name": "melon", + "unicode": "1f348" + }, + ":melting_face:": { + "category": "people", + "name": "melting face", + "unicode": "1fae0" + }, + ":men_holding_hands_tone1:": { + "category": "people", + "name": "men holding hands: light skin tone", + "unicode": "1f46c-1f3fb" + }, + ":men_holding_hands_tone1_tone2:": { + "category": "people", + "name": "men holding hands: light skin tone, medium-light skin tone", + "unicode": "1f468-1f3fb-200d-1f91d-200d-1f468-1f3fc" + }, + ":men_holding_hands_tone1_tone3:": { + "category": "people", + "name": "men holding hands: light skin tone, medium skin tone", + "unicode": "1f468-1f3fb-200d-1f91d-200d-1f468-1f3fd" + }, + ":men_holding_hands_tone1_tone4:": { + "category": "people", + "name": "men holding hands: light skin tone, medium-dark skin tone", + "unicode": "1f468-1f3fb-200d-1f91d-200d-1f468-1f3fe" + }, + ":men_holding_hands_tone1_tone5:": { + "category": "people", + "name": "men holding hands: light skin tone, dark skin tone", + "unicode": "1f468-1f3fb-200d-1f91d-200d-1f468-1f3ff" + }, + ":men_holding_hands_tone2:": { + "category": "people", + "name": "men holding hands: medium-light skin tone", + "unicode": "1f46c-1f3fc" + }, + ":men_holding_hands_tone2_tone1:": { + "category": "people", + "name": "men holding hands: medium-light skin tone, light skin tone", + "unicode": "1f468-1f3fc-200d-1f91d-200d-1f468-1f3fb" + }, + ":men_holding_hands_tone2_tone3:": { + "category": "people", + "name": "men holding hands: medium-light skin tone, medium skin tone", + "unicode": "1f468-1f3fc-200d-1f91d-200d-1f468-1f3fd" + }, + ":men_holding_hands_tone2_tone4:": { + "category": "people", + "name": "men holding hands: medium-light skin tone, medium-dark skin tone", + "unicode": "1f468-1f3fc-200d-1f91d-200d-1f468-1f3fe" + }, + ":men_holding_hands_tone2_tone5:": { + "category": "people", + "name": "men holding hands: medium-light skin tone, dark skin tone", + "unicode": "1f468-1f3fc-200d-1f91d-200d-1f468-1f3ff" + }, + ":men_holding_hands_tone3:": { + "category": "people", + "name": "men holding hands: medium skin tone", + "unicode": "1f46c-1f3fd" + }, + ":men_holding_hands_tone3_tone1:": { + "category": "people", + "name": "men holding hands: medium skin tone, light skin tone", + "unicode": "1f468-1f3fd-200d-1f91d-200d-1f468-1f3fb" + }, + ":men_holding_hands_tone3_tone2:": { + "category": "people", + "name": "men holding hands: medium skin tone, medium-light skin tone", + "unicode": "1f468-1f3fd-200d-1f91d-200d-1f468-1f3fc" + }, + ":men_holding_hands_tone3_tone4:": { + "category": "people", + "name": "men holding hands: medium skin tone, medium-dark skin tone", + "unicode": "1f468-1f3fd-200d-1f91d-200d-1f468-1f3fe" + }, + ":men_holding_hands_tone3_tone5:": { + "category": "people", + "name": "men holding hands: medium skin tone, dark skin tone", + "unicode": "1f468-1f3fd-200d-1f91d-200d-1f468-1f3ff" + }, + ":men_holding_hands_tone4:": { + "category": "people", + "name": "men holding hands: medium-dark skin tone", + "unicode": "1f46c-1f3fe" + }, + ":men_holding_hands_tone4_tone1:": { + "category": "people", + "name": "men holding hands: medium-dark skin tone, light skin tone", + "unicode": "1f468-1f3fe-200d-1f91d-200d-1f468-1f3fb" + }, + ":men_holding_hands_tone4_tone2:": { + "category": "people", + "name": "men holding hands: medium dark skin tone, medium light skin tone", + "unicode": "1f468-1f3fe-200d-1f91d-200d-1f468-1f3fc" + }, + ":men_holding_hands_tone4_tone3:": { + "category": "people", + "name": "men holding hands: medium-dark skin tone, medium skin tone", + "unicode": "1f468-1f3fe-200d-1f91d-200d-1f468-1f3fd" + }, + ":men_holding_hands_tone4_tone5:": { + "category": "people", + "name": "men holding hands: medium-dark skin tone, dark skin tone", + "unicode": "1f468-1f3fe-200d-1f91d-200d-1f468-1f3ff" + }, + ":men_holding_hands_tone5:": { + "category": "people", + "name": "men holding hands: dark skin tone", + "unicode": "1f46c-1f3ff" + }, + ":men_holding_hands_tone5_tone1:": { + "category": "people", + "name": "men holding hands: dark skin tone, light skin tone", + "unicode": "1f468-1f3ff-200d-1f91d-200d-1f468-1f3fb" + }, + ":men_holding_hands_tone5_tone2:": { + "category": "people", + "name": "men holding hands: dark skin tone, medium-light skin tone", + "unicode": "1f468-1f3ff-200d-1f91d-200d-1f468-1f3fc" + }, + ":men_holding_hands_tone5_tone3:": { + "category": "people", + "name": "men holding hands: dark skin tone, medium skin tone", + "unicode": "1f468-1f3ff-200d-1f91d-200d-1f468-1f3fd" + }, + ":men_holding_hands_tone5_tone4:": { + "category": "people", + "name": "men holding hands: dark skin tone, medium-dark skin tone", + "unicode": "1f468-1f3ff-200d-1f91d-200d-1f468-1f3fe" + }, + ":men_with_bunny_ears_partying:": { + "category": "people", + "name": "men with bunny ears", + "unicode": "1f46f-200d-2642-fe0f" + }, + ":men_wrestling:": { + "category": "activity", + "name": "men wrestling", + "unicode": "1f93c-200d-2642-fe0f" + }, + ":mending_heart:": { + "category": "symbols", + "name": "mending heart", + "unicode": "2764-fe0f-200d-1fa79" + }, + ":menorah:": { + "category": "symbols", + "name": "menorah", + "unicode": "1f54e" + }, + ":mens:": { + "category": "symbols", + "name": "men\u2019s room", + "unicode": "1f6b9" + }, + ":mermaid:": { + "category": "people", + "name": "mermaid", + "unicode": "1f9dc-200d-2640-fe0f" + }, + ":mermaid_tone1:": { + "category": "people", + "name": "mermaid: light skin tone", + "unicode": "1f9dc-1f3fb-200d-2640-fe0f" + }, + ":mermaid_tone2:": { + "category": "people", + "name": "mermaid: medium-light skin tone", + "unicode": "1f9dc-1f3fc-200d-2640-fe0f" + }, + ":mermaid_tone3:": { + "category": "people", + "name": "mermaid: medium skin tone", + "unicode": "1f9dc-1f3fd-200d-2640-fe0f" + }, + ":mermaid_tone4:": { + "category": "people", + "name": "mermaid: medium-dark skin tone", + "unicode": "1f9dc-1f3fe-200d-2640-fe0f" + }, + ":mermaid_tone5:": { + "category": "people", + "name": "mermaid: dark skin tone", + "unicode": "1f9dc-1f3ff-200d-2640-fe0f" + }, + ":merman:": { + "category": "people", + "name": "merman", + "unicode": "1f9dc-200d-2642-fe0f" + }, + ":merman_tone1:": { + "category": "people", + "name": "merman: light skin tone", + "unicode": "1f9dc-1f3fb-200d-2642-fe0f" + }, + ":merman_tone2:": { + "category": "people", + "name": "merman: medium-light skin tone", + "unicode": "1f9dc-1f3fc-200d-2642-fe0f" + }, + ":merman_tone3:": { + "category": "people", + "name": "merman: medium skin tone", + "unicode": "1f9dc-1f3fd-200d-2642-fe0f" + }, + ":merman_tone4:": { + "category": "people", + "name": "merman: medium-dark skin tone", + "unicode": "1f9dc-1f3fe-200d-2642-fe0f" + }, + ":merman_tone5:": { + "category": "people", + "name": "merman: dark skin tone", + "unicode": "1f9dc-1f3ff-200d-2642-fe0f" + }, + ":merperson:": { + "category": "people", + "name": "merperson", + "unicode": "1f9dc" + }, + ":merperson_tone1:": { + "category": "people", + "name": "merperson: light skin tone", + "unicode": "1f9dc-1f3fb" + }, + ":merperson_tone2:": { + "category": "people", + "name": "merperson: medium-light skin tone", + "unicode": "1f9dc-1f3fc" + }, + ":merperson_tone3:": { + "category": "people", + "name": "merperson: medium skin tone", + "unicode": "1f9dc-1f3fd" + }, + ":merperson_tone4:": { + "category": "people", + "name": "merperson: medium-dark skin tone", + "unicode": "1f9dc-1f3fe" + }, + ":merperson_tone5:": { + "category": "people", + "name": "merperson: dark skin tone", + "unicode": "1f9dc-1f3ff" + }, + ":metal:": { + "category": "people", + "name": "sign of the horns", + "unicode": "1f918" + }, + ":metal_tone1:": { + "category": "people", + "name": "sign of the horns: light skin tone", + "unicode": "1f918-1f3fb" + }, + ":metal_tone2:": { + "category": "people", + "name": "sign of the horns: medium-light skin tone", + "unicode": "1f918-1f3fc" + }, + ":metal_tone3:": { + "category": "people", + "name": "sign of the horns: medium skin tone", + "unicode": "1f918-1f3fd" + }, + ":metal_tone4:": { + "category": "people", + "name": "sign of the horns: medium-dark skin tone", + "unicode": "1f918-1f3fe" + }, + ":metal_tone5:": { + "category": "people", + "name": "sign of the horns: dark skin tone", + "unicode": "1f918-1f3ff" + }, + ":metro:": { + "category": "travel", + "name": "metro", + "unicode": "1f687" + }, + ":microbe:": { + "category": "objects", + "name": "microbe", + "unicode": "1f9a0" + }, + ":microphone2:": { + "category": "objects", + "name": "studio microphone", + "unicode": "1f399" + }, + ":microphone:": { + "category": "activity", + "name": "microphone", + "unicode": "1f3a4" + }, + ":microscope:": { + "category": "objects", + "name": "microscope", + "unicode": "1f52c" + }, + ":middle_finger:": { + "category": "people", + "name": "middle finger", + "unicode": "1f595" + }, + ":middle_finger_tone1:": { + "category": "people", + "name": "middle finger: light skin tone", + "unicode": "1f595-1f3fb" + }, + ":middle_finger_tone2:": { + "category": "people", + "name": "middle finger: medium-light skin tone", + "unicode": "1f595-1f3fc" + }, + ":middle_finger_tone3:": { + "category": "people", + "name": "middle finger: medium skin tone", + "unicode": "1f595-1f3fd" + }, + ":middle_finger_tone4:": { + "category": "people", + "name": "middle finger: medium-dark skin tone", + "unicode": "1f595-1f3fe" + }, + ":middle_finger_tone5:": { + "category": "people", + "name": "middle finger: dark skin tone", + "unicode": "1f595-1f3ff" + }, + ":military_helmet:": { + "category": "people", + "name": "military helmet", + "unicode": "1fa96" + }, + ":military_medal:": { + "category": "activity", + "name": "military medal", + "unicode": "1f396" + }, + ":milk:": { + "category": "food", + "name": "glass of milk", + "unicode": "1f95b" + }, + ":milky_way:": { + "category": "travel", + "name": "milky way", + "unicode": "1f30c" + }, + ":minibus:": { + "category": "travel", + "name": "minibus", + "unicode": "1f690" + }, + ":minidisc:": { + "category": "objects", + "name": "computer disk", + "unicode": "1f4bd" + }, + ":mirror:": { + "category": "objects", + "name": "mirror", + "unicode": "1fa9e" + }, + ":mirror_ball:": { + "category": "objects", + "name": "mirror ball", + "unicode": "1faa9" + }, + ":mobile_phone:": { + "category": "objects", + "name": "mobile phone", + "unicode": "1f4f1" + }, + ":mobile_phone_off:": { + "category": "symbols", + "name": "mobile phone off", + "unicode": "1f4f4" + }, + ":money_mouth:": { + "category": "people", + "name": "money-mouth face", + "unicode": "1f911" + }, + ":money_with_wings:": { + "category": "objects", + "name": "money with wings", + "unicode": "1f4b8" + }, + ":moneybag:": { + "category": "objects", + "name": "money bag", + "unicode": "1f4b0" + }, + ":monkey:": { + "category": "nature", + "name": "monkey", + "unicode": "1f412" + }, + ":monkey_face:": { + "category": "nature", + "name": "monkey face", + "unicode": "1f435" + }, + ":monorail:": { + "category": "travel", + "name": "monorail", + "unicode": "1f69d" + }, + ":moon_cake:": { + "category": "food", + "name": "moon cake", + "unicode": "1f96e" + }, + ":moose:": { + "category": "nature", + "name": "moose", + "unicode": "1face" + }, + ":mortar_board:": { + "category": "people", + "name": "graduation cap", + "unicode": "1f393" + }, + ":mosque:": { + "category": "travel", + "name": "mosque", + "unicode": "1f54c" + }, + ":mosquito:": { + "category": "nature", + "name": "mosquito", + "unicode": "1f99f" + }, + ":motor_scooter:": { + "category": "travel", + "name": "motor scooter", + "unicode": "1f6f5" + }, + ":motorboat:": { + "category": "travel", + "name": "motor boat", + "unicode": "1f6e5" + }, + ":motorcycle:": { + "category": "travel", + "name": "motorcycle", + "unicode": "1f3cd" + }, + ":motorized_wheelchair:": { + "category": "travel", + "name": "motorized wheelchair", + "unicode": "1f9bc" + }, + ":motorway:": { + "category": "travel", + "name": "motorway", + "unicode": "1f6e3" + }, + ":mount_fuji:": { + "category": "travel", + "name": "mount fuji", + "unicode": "1f5fb" + }, + ":mountain:": { + "category": "travel", + "name": "mountain", + "unicode": "26f0" + }, + ":mountain_cableway:": { + "category": "travel", + "name": "mountain cableway", + "unicode": "1f6a0" + }, + ":mountain_railway:": { + "category": "travel", + "name": "mountain railway", + "unicode": "1f69e" + }, + ":mountain_snow:": { + "category": "travel", + "name": "snow-capped mountain", + "unicode": "1f3d4" + }, + ":mouse2:": { + "category": "nature", + "name": "mouse", + "unicode": "1f401" + }, + ":mouse:": { + "category": "nature", + "name": "mouse face", + "unicode": "1f42d" + }, + ":mouse_three_button:": { + "category": "objects", + "name": "computer mouse", + "unicode": "1f5b1" + }, + ":mouse_trap:": { + "category": "objects", + "name": "mouse trap", + "unicode": "1faa4" + }, + ":movie_camera:": { + "category": "objects", + "name": "movie camera", + "unicode": "1f3a5" + }, + ":moyai:": { + "category": "travel", + "name": "moai", + "unicode": "1f5ff" + }, + ":mrs_claus:": { + "category": "people", + "name": "Mrs. Claus", + "unicode": "1f936" + }, + ":mrs_claus_tone1:": { + "category": "people", + "name": "Mrs. Claus: light skin tone", + "unicode": "1f936-1f3fb" + }, + ":mrs_claus_tone2:": { + "category": "people", + "name": "Mrs. Claus: medium-light skin tone", + "unicode": "1f936-1f3fc" + }, + ":mrs_claus_tone3:": { + "category": "people", + "name": "Mrs. Claus: medium skin tone", + "unicode": "1f936-1f3fd" + }, + ":mrs_claus_tone4:": { + "category": "people", + "name": "Mrs. Claus: medium-dark skin tone", + "unicode": "1f936-1f3fe" + }, + ":mrs_claus_tone5:": { + "category": "people", + "name": "Mrs. Claus: dark skin tone", + "unicode": "1f936-1f3ff" + }, + ":muscle:": { + "category": "people", + "name": "flexed biceps", + "unicode": "1f4aa" + }, + ":muscle_tone1:": { + "category": "people", + "name": "flexed biceps: light skin tone", + "unicode": "1f4aa-1f3fb" + }, + ":muscle_tone2:": { + "category": "people", + "name": "flexed biceps: medium-light skin tone", + "unicode": "1f4aa-1f3fc" + }, + ":muscle_tone3:": { + "category": "people", + "name": "flexed biceps: medium skin tone", + "unicode": "1f4aa-1f3fd" + }, + ":muscle_tone4:": { + "category": "people", + "name": "flexed biceps: medium-dark skin tone", + "unicode": "1f4aa-1f3fe" + }, + ":muscle_tone5:": { + "category": "people", + "name": "flexed biceps: dark skin tone", + "unicode": "1f4aa-1f3ff" + }, + ":mushroom:": { + "category": "nature", + "name": "mushroom", + "unicode": "1f344" + }, + ":musical_keyboard:": { + "category": "activity", + "name": "musical keyboard", + "unicode": "1f3b9" + }, + ":musical_note:": { + "category": "symbols", + "name": "musical note", + "unicode": "1f3b5" + }, + ":musical_score:": { + "category": "activity", + "name": "musical score", + "unicode": "1f3bc" + }, + ":mute:": { + "category": "symbols", + "name": "muted speaker", + "unicode": "1f507" + }, + ":mx_claus:": { + "category": "people", + "name": "mx claus", + "unicode": "1f9d1-200d-1f384" + }, + ":mx_claus_tone1:": { + "category": "people", + "name": "mx claus: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f384" + }, + ":mx_claus_tone2:": { + "category": "people", + "name": "mx claus: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f384" + }, + ":mx_claus_tone3:": { + "category": "people", + "name": "mx claus: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f384" + }, + ":mx_claus_tone4:": { + "category": "people", + "name": "mx claus: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f384" + }, + ":mx_claus_tone5:": { + "category": "people", + "name": "mx claus: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f384" + }, + ":nail_care:": { + "category": "people", + "name": "nail polish", + "unicode": "1f485" + }, + ":nail_care_tone1:": { + "category": "people", + "name": "nail polish: light skin tone", + "unicode": "1f485-1f3fb" + }, + ":nail_care_tone2:": { + "category": "people", + "name": "nail polish: medium-light skin tone", + "unicode": "1f485-1f3fc" + }, + ":nail_care_tone3:": { + "category": "people", + "name": "nail polish: medium skin tone", + "unicode": "1f485-1f3fd" + }, + ":nail_care_tone4:": { + "category": "people", + "name": "nail polish: medium-dark skin tone", + "unicode": "1f485-1f3fe" + }, + ":nail_care_tone5:": { + "category": "people", + "name": "nail polish: dark skin tone", + "unicode": "1f485-1f3ff" + }, + ":name_badge:": { + "category": "symbols", + "name": "name badge", + "unicode": "1f4db" + }, + ":nauseated_face:": { + "category": "people", + "name": "nauseated face", + "unicode": "1f922" + }, + ":nazar_amulet:": { + "category": "objects", + "name": "nazar amulet", + "unicode": "1f9ff" + }, + ":necktie:": { + "category": "people", + "name": "necktie", + "unicode": "1f454" + }, + ":negative_squared_cross_mark:": { + "category": "symbols", + "name": "cross mark button", + "unicode": "274e" + }, + ":nerd:": { + "category": "people", + "name": "nerd face", + "unicode": "1f913" + }, + ":nest_with_eggs:": { + "category": "nature", + "name": "nest with eggs", + "unicode": "1faba" + }, + ":nesting_dolls:": { + "category": "objects", + "name": "nesting dolls", + "unicode": "1fa86" + }, + ":neutral_face:": { + "category": "people", + "name": "neutral face", + "unicode": "1f610" + }, + ":new:": { + "category": "symbols", + "name": "NEW button", + "unicode": "1f195" + }, + ":new_moon:": { + "category": "nature", + "name": "new moon", + "unicode": "1f311" + }, + ":new_moon_with_face:": { + "category": "nature", + "name": "new moon face", + "unicode": "1f31a" + }, + ":newspaper2:": { + "category": "objects", + "name": "rolled-up newspaper", + "unicode": "1f5de" + }, + ":newspaper:": { + "category": "objects", + "name": "newspaper", + "unicode": "1f4f0" + }, + ":ng:": { + "category": "symbols", + "name": "NG button", + "unicode": "1f196" + }, + ":night_with_stars:": { + "category": "travel", + "name": "night with stars", + "unicode": "1f303" + }, + ":nine:": { + "category": "symbols", + "name": "keycap: 9", + "unicode": "39-20e3", + "unicode_alt": "0039-20e3" + }, + ":ninja:": { + "category": "people", + "name": "ninja", + "unicode": "1f977" + }, + ":ninja_tone1:": { + "category": "people", + "name": "ninja: light skin tone", + "unicode": "1f977-1f3fb" + }, + ":ninja_tone2:": { + "category": "people", + "name": "ninja: medium-light skin tone", + "unicode": "1f977-1f3fc" + }, + ":ninja_tone3:": { + "category": "people", + "name": "ninja: medium skin tone", + "unicode": "1f977-1f3fd" + }, + ":ninja_tone4:": { + "category": "people", + "name": "ninja: medium-dark skin tone", + "unicode": "1f977-1f3fe" + }, + ":ninja_tone5:": { + "category": "people", + "name": "ninja: dark skin tone", + "unicode": "1f977-1f3ff" + }, + ":no_bell:": { + "category": "symbols", + "name": "bell with slash", + "unicode": "1f515" + }, + ":no_bicycles:": { + "category": "symbols", + "name": "no bicycles", + "unicode": "1f6b3" + }, + ":no_entry:": { + "category": "symbols", + "name": "no entry", + "unicode": "26d4" + }, + ":no_entry_sign:": { + "category": "symbols", + "name": "prohibited", + "unicode": "1f6ab" + }, + ":no_mobile_phones:": { + "category": "symbols", + "name": "no mobile phones", + "unicode": "1f4f5" + }, + ":no_mouth:": { + "category": "people", + "name": "face without mouth", + "unicode": "1f636" + }, + ":no_pedestrians:": { + "category": "symbols", + "name": "no pedestrians", + "unicode": "1f6b7" + }, + ":no_smoking:": { + "category": "symbols", + "name": "no smoking", + "unicode": "1f6ad" + }, + ":non-potable_water:": { + "category": "symbols", + "name": "non-potable water", + "unicode": "1f6b1" + }, + ":nose:": { + "category": "people", + "name": "nose", + "unicode": "1f443" + }, + ":nose_tone1:": { + "category": "people", + "name": "nose: light skin tone", + "unicode": "1f443-1f3fb" + }, + ":nose_tone2:": { + "category": "people", + "name": "nose: medium-light skin tone", + "unicode": "1f443-1f3fc" + }, + ":nose_tone3:": { + "category": "people", + "name": "nose: medium skin tone", + "unicode": "1f443-1f3fd" + }, + ":nose_tone4:": { + "category": "people", + "name": "nose: medium-dark skin tone", + "unicode": "1f443-1f3fe" + }, + ":nose_tone5:": { + "category": "people", + "name": "nose: dark skin tone", + "unicode": "1f443-1f3ff" + }, + ":notebook:": { + "category": "objects", + "name": "notebook", + "unicode": "1f4d3" + }, + ":notebook_with_decorative_cover:": { + "category": "objects", + "name": "notebook with decorative cover", + "unicode": "1f4d4" + }, + ":notepad_spiral:": { + "category": "objects", + "name": "spiral notepad", + "unicode": "1f5d2" + }, + ":notes:": { + "category": "symbols", + "name": "musical notes", + "unicode": "1f3b6" + }, + ":nut_and_bolt:": { + "category": "objects", + "name": "nut and bolt", + "unicode": "1f529" + }, + ":o2:": { + "category": "symbols", + "name": "O button (blood type)", + "unicode": "1f17e" + }, + ":o:": { + "category": "symbols", + "name": "hollow red circle", + "unicode": "2b55" + }, + ":ocean:": { + "category": "nature", + "name": "water wave", + "unicode": "1f30a" + }, + ":octagonal_sign:": { + "category": "symbols", + "name": "stop sign", + "unicode": "1f6d1" + }, + ":octopus:": { + "category": "nature", + "name": "octopus", + "unicode": "1f419" + }, + ":oden:": { + "category": "food", + "name": "oden", + "unicode": "1f362" + }, + ":office:": { + "category": "travel", + "name": "office building", + "unicode": "1f3e2" + }, + ":office_worker:": { + "category": "people", + "name": "office worker", + "unicode": "1f9d1-200d-1f4bc" + }, + ":office_worker_tone1:": { + "category": "people", + "name": "office worker: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f4bc" + }, + ":office_worker_tone2:": { + "category": "people", + "name": "office worker: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f4bc" + }, + ":office_worker_tone3:": { + "category": "people", + "name": "office worker: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f4bc" + }, + ":office_worker_tone4:": { + "category": "people", + "name": "office worker: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f4bc" + }, + ":office_worker_tone5:": { + "category": "people", + "name": "office worker: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f4bc" + }, + ":oil:": { + "category": "objects", + "name": "oil drum", + "unicode": "1f6e2" + }, + ":ok:": { + "category": "symbols", + "name": "OK button", + "unicode": "1f197" + }, + ":ok_hand:": { + "category": "people", + "name": "OK hand", + "unicode": "1f44c" + }, + ":ok_hand_tone1:": { + "category": "people", + "name": "OK hand: light skin tone", + "unicode": "1f44c-1f3fb" + }, + ":ok_hand_tone2:": { + "category": "people", + "name": "OK hand: medium-light skin tone", + "unicode": "1f44c-1f3fc" + }, + ":ok_hand_tone3:": { + "category": "people", + "name": "OK hand: medium skin tone", + "unicode": "1f44c-1f3fd" + }, + ":ok_hand_tone4:": { + "category": "people", + "name": "OK hand: medium-dark skin tone", + "unicode": "1f44c-1f3fe" + }, + ":ok_hand_tone5:": { + "category": "people", + "name": "OK hand: dark skin tone", + "unicode": "1f44c-1f3ff" + }, + ":older_adult:": { + "category": "people", + "name": "older person", + "unicode": "1f9d3" + }, + ":older_adult_tone1:": { + "category": "people", + "name": "older person: light skin tone", + "unicode": "1f9d3-1f3fb" + }, + ":older_adult_tone2:": { + "category": "people", + "name": "older person: medium-light skin tone", + "unicode": "1f9d3-1f3fc" + }, + ":older_adult_tone3:": { + "category": "people", + "name": "older person: medium skin tone", + "unicode": "1f9d3-1f3fd" + }, + ":older_adult_tone4:": { + "category": "people", + "name": "older person: medium-dark skin tone", + "unicode": "1f9d3-1f3fe" + }, + ":older_adult_tone5:": { + "category": "people", + "name": "older person: dark skin tone", + "unicode": "1f9d3-1f3ff" + }, + ":older_man:": { + "category": "people", + "name": "old man", + "unicode": "1f474" + }, + ":older_man_tone1:": { + "category": "people", + "name": "old man: light skin tone", + "unicode": "1f474-1f3fb" + }, + ":older_man_tone2:": { + "category": "people", + "name": "old man: medium-light skin tone", + "unicode": "1f474-1f3fc" + }, + ":older_man_tone3:": { + "category": "people", + "name": "old man: medium skin tone", + "unicode": "1f474-1f3fd" + }, + ":older_man_tone4:": { + "category": "people", + "name": "old man: medium-dark skin tone", + "unicode": "1f474-1f3fe" + }, + ":older_man_tone5:": { + "category": "people", + "name": "old man: dark skin tone", + "unicode": "1f474-1f3ff" + }, + ":older_woman:": { + "category": "people", + "name": "old woman", + "unicode": "1f475" + }, + ":older_woman_tone1:": { + "category": "people", + "name": "old woman: light skin tone", + "unicode": "1f475-1f3fb" + }, + ":older_woman_tone2:": { + "category": "people", + "name": "old woman: medium-light skin tone", + "unicode": "1f475-1f3fc" + }, + ":older_woman_tone3:": { + "category": "people", + "name": "old woman: medium skin tone", + "unicode": "1f475-1f3fd" + }, + ":older_woman_tone4:": { + "category": "people", + "name": "old woman: medium-dark skin tone", + "unicode": "1f475-1f3fe" + }, + ":older_woman_tone5:": { + "category": "people", + "name": "old woman: dark skin tone", + "unicode": "1f475-1f3ff" + }, + ":olive:": { + "category": "food", + "name": "olive", + "unicode": "1fad2" + }, + ":om_symbol:": { + "category": "symbols", + "name": "om", + "unicode": "1f549" + }, + ":on:": { + "category": "symbols", + "name": "ON! arrow", + "unicode": "1f51b" + }, + ":oncoming_automobile:": { + "category": "travel", + "name": "oncoming automobile", + "unicode": "1f698" + }, + ":oncoming_bus:": { + "category": "travel", + "name": "oncoming bus", + "unicode": "1f68d" + }, + ":oncoming_police_car:": { + "category": "travel", + "name": "oncoming police car", + "unicode": "1f694" + }, + ":oncoming_taxi:": { + "category": "travel", + "name": "oncoming taxi", + "unicode": "1f696" + }, + ":one:": { + "category": "symbols", + "name": "keycap: 1", + "unicode": "31-20e3", + "unicode_alt": "0031-20e3" + }, + ":one_piece_swimsuit:": { + "category": "people", + "name": "one-piece swimsuit", + "unicode": "1fa71" + }, + ":onion:": { + "category": "food", + "name": "onion", + "unicode": "1f9c5" + }, + ":open_file_folder:": { + "category": "objects", + "name": "open file folder", + "unicode": "1f4c2" + }, + ":open_hands:": { + "category": "people", + "name": "open hands", + "unicode": "1f450" + }, + ":open_hands_tone1:": { + "category": "people", + "name": "open hands: light skin tone", + "unicode": "1f450-1f3fb" + }, + ":open_hands_tone2:": { + "category": "people", + "name": "open hands: medium-light skin tone", + "unicode": "1f450-1f3fc" + }, + ":open_hands_tone3:": { + "category": "people", + "name": "open hands: medium skin tone", + "unicode": "1f450-1f3fd" + }, + ":open_hands_tone4:": { + "category": "people", + "name": "open hands: medium-dark skin tone", + "unicode": "1f450-1f3fe" + }, + ":open_hands_tone5:": { + "category": "people", + "name": "open hands: dark skin tone", + "unicode": "1f450-1f3ff" + }, + ":open_mouth:": { + "category": "people", + "name": "face with open mouth", + "unicode": "1f62e" + }, + ":ophiuchus:": { + "category": "symbols", + "name": "Ophiuchus", + "unicode": "26ce" + }, + ":orange_book:": { + "category": "objects", + "name": "orange book", + "unicode": "1f4d9" + }, + ":orange_circle:": { + "category": "symbols", + "name": "orange circle", + "unicode": "1f7e0" + }, + ":orange_heart:": { + "category": "symbols", + "name": "orange heart", + "unicode": "1f9e1" + }, + ":orange_square:": { + "category": "symbols", + "name": "orange square", + "unicode": "1f7e7" + }, + ":orangutan:": { + "category": "nature", + "name": "orangutan", + "unicode": "1f9a7" + }, + ":orthodox_cross:": { + "category": "symbols", + "name": "orthodox cross", + "unicode": "2626" + }, + ":otter:": { + "category": "nature", + "name": "otter", + "unicode": "1f9a6" + }, + ":outbox_tray:": { + "category": "objects", + "name": "outbox tray", + "unicode": "1f4e4" + }, + ":owl:": { + "category": "nature", + "name": "owl", + "unicode": "1f989" + }, + ":ox:": { + "category": "nature", + "name": "ox", + "unicode": "1f402" + }, + ":oyster:": { + "category": "food", + "name": "oyster", + "unicode": "1f9aa" + }, + ":package:": { + "category": "objects", + "name": "package", + "unicode": "1f4e6" + }, + ":page_facing_up:": { + "category": "objects", + "name": "page facing up", + "unicode": "1f4c4" + }, + ":page_with_curl:": { + "category": "objects", + "name": "page with curl", + "unicode": "1f4c3" + }, + ":pager:": { + "category": "objects", + "name": "pager", + "unicode": "1f4df" + }, + ":paintbrush:": { + "category": "objects", + "name": "paintbrush", + "unicode": "1f58c" + }, + ":palm_down_hand:": { + "category": "people", + "name": "palm down hand", + "unicode": "1faf3" + }, + ":palm_down_hand_tone1:": { + "category": "people", + "name": "palm down hand: light skin tone", + "unicode": "1faf3-1f3fb" + }, + ":palm_down_hand_tone2:": { + "category": "people", + "name": "palm down hand: medium-light skin tone", + "unicode": "1faf3-1f3fc" + }, + ":palm_down_hand_tone3:": { + "category": "people", + "name": "palm down hand: medium skin tone", + "unicode": "1faf3-1f3fd" + }, + ":palm_down_hand_tone4:": { + "category": "people", + "name": "palm down hand: medium-dark skin tone", + "unicode": "1faf3-1f3fe" + }, + ":palm_down_hand_tone5:": { + "category": "people", + "name": "palm down hand: dark skin tone", + "unicode": "1faf3-1f3ff" + }, + ":palm_tree:": { + "category": "nature", + "name": "palm tree", + "unicode": "1f334" + }, + ":palm_up_hand:": { + "category": "people", + "name": "palm up hand", + "unicode": "1faf4" + }, + ":palm_up_hand_tone1:": { + "category": "people", + "name": "palm up hand: light skin tone", + "unicode": "1faf4-1f3fb" + }, + ":palm_up_hand_tone2:": { + "category": "people", + "name": "palm up hand: medium-light skin tone", + "unicode": "1faf4-1f3fc" + }, + ":palm_up_hand_tone3:": { + "category": "people", + "name": "palm up hand: medium skin tone", + "unicode": "1faf4-1f3fd" + }, + ":palm_up_hand_tone4:": { + "category": "people", + "name": "palm up hand: medium-dark skin tone", + "unicode": "1faf4-1f3fe" + }, + ":palm_up_hand_tone5:": { + "category": "people", + "name": "palm up hand: dark skin tone", + "unicode": "1faf4-1f3ff" + }, + ":palms_up_together:": { + "category": "people", + "name": "palms up together", + "unicode": "1f932" + }, + ":palms_up_together_tone1:": { + "category": "people", + "name": "palms up together: light skin tone", + "unicode": "1f932-1f3fb" + }, + ":palms_up_together_tone2:": { + "category": "people", + "name": "palms up together: medium-light skin tone", + "unicode": "1f932-1f3fc" + }, + ":palms_up_together_tone3:": { + "category": "people", + "name": "palms up together: medium skin tone", + "unicode": "1f932-1f3fd" + }, + ":palms_up_together_tone4:": { + "category": "people", + "name": "palms up together: medium-dark skin tone", + "unicode": "1f932-1f3fe" + }, + ":palms_up_together_tone5:": { + "category": "people", + "name": "palms up together: dark skin tone", + "unicode": "1f932-1f3ff" + }, + ":pancakes:": { + "category": "food", + "name": "pancakes", + "unicode": "1f95e" + }, + ":panda_face:": { + "category": "nature", + "name": "panda", + "unicode": "1f43c" + }, + ":paperclip:": { + "category": "objects", + "name": "paperclip", + "unicode": "1f4ce" + }, + ":paperclips:": { + "category": "objects", + "name": "linked paperclips", + "unicode": "1f587" + }, + ":parachute:": { + "category": "activity", + "name": "parachute", + "unicode": "1fa82" + }, + ":park:": { + "category": "travel", + "name": "national park", + "unicode": "1f3de" + }, + ":parking:": { + "category": "symbols", + "name": "P button", + "unicode": "1f17f" + }, + ":parrot:": { + "category": "nature", + "name": "parrot", + "unicode": "1f99c" + }, + ":part_alternation_mark:": { + "category": "symbols", + "name": "part alternation mark", + "unicode": "303d" + }, + ":partly_sunny:": { + "category": "nature", + "name": "sun behind cloud", + "unicode": "26c5" + }, + ":partying_face:": { + "category": "people", + "name": "partying face", + "unicode": "1f973" + }, + ":passport_control:": { + "category": "symbols", + "name": "passport control", + "unicode": "1f6c2" + }, + ":pause_button:": { + "category": "symbols", + "name": "pause button", + "unicode": "23f8" + }, + ":pea_pod:": { + "category": "food", + "name": "pea pod", + "unicode": "1fadb" + }, + ":peace:": { + "category": "symbols", + "name": "peace symbol", + "unicode": "262e" + }, + ":peach:": { + "category": "food", + "name": "peach", + "unicode": "1f351" + }, + ":peacock:": { + "category": "nature", + "name": "peacock", + "unicode": "1f99a" + }, + ":peanuts:": { + "category": "food", + "name": "peanuts", + "unicode": "1f95c" + }, + ":pear:": { + "category": "food", + "name": "pear", + "unicode": "1f350" + }, + ":pen_ballpoint:": { + "category": "objects", + "name": "pen", + "unicode": "1f58a" + }, + ":pen_fountain:": { + "category": "objects", + "name": "fountain pen", + "unicode": "1f58b" + }, + ":pencil2:": { + "category": "objects", + "name": "pencil", + "unicode": "270f" + }, + ":pencil:": { + "category": "objects", + "name": "memo", + "unicode": "1f4dd" + }, + ":penguin:": { + "category": "nature", + "name": "penguin", + "unicode": "1f427" + }, + ":pensive:": { + "category": "people", + "name": "pensive face", + "unicode": "1f614" + }, + ":people_holding_hands:": { + "category": "people", + "name": "people holding hands", + "unicode": "1f9d1-200d-1f91d-200d-1f9d1" + }, + ":people_holding_hands_tone1:": { + "category": "people", + "name": "people holding hands: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f91d-200d-1f9d1-1f3fb" + }, + ":people_holding_hands_tone1_tone2:": { + "category": "people", + "name": "people holding hands: light skin tone, medium-light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f91d-200d-1f9d1-1f3fc" + }, + ":people_holding_hands_tone1_tone3:": { + "category": "people", + "name": "people holding hands: light skin tone, medium skin tone", + "unicode": "1f9d1-1f3fb-200d-1f91d-200d-1f9d1-1f3fd" + }, + ":people_holding_hands_tone1_tone4:": { + "category": "people", + "name": "people holding hands: light skin tone, medium-dark skin tone", + "unicode": "1f9d1-1f3fb-200d-1f91d-200d-1f9d1-1f3fe" + }, + ":people_holding_hands_tone1_tone5:": { + "category": "people", + "name": "people holding hands: light skin tone, dark skin tone", + "unicode": "1f9d1-1f3fb-200d-1f91d-200d-1f9d1-1f3ff" + }, + ":people_holding_hands_tone2:": { + "category": "people", + "name": "people holding hands: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f91d-200d-1f9d1-1f3fc" + }, + ":people_holding_hands_tone2_tone1:": { + "category": "people", + "name": "people holding hands: medium-light skin tone, light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f91d-200d-1f9d1-1f3fb" + }, + ":people_holding_hands_tone2_tone3:": { + "category": "people", + "name": "people holding hands: medium-light skin tone, medium skin tone", + "unicode": "1f9d1-1f3fc-200d-1f91d-200d-1f9d1-1f3fd" + }, + ":people_holding_hands_tone2_tone4:": { + "category": "people", + "name": "people holding hands: medium-light skin tone, medium-dark skin tone", + "unicode": "1f9d1-1f3fc-200d-1f91d-200d-1f9d1-1f3fe" + }, + ":people_holding_hands_tone2_tone5:": { + "category": "people", + "name": "people holding hands: medium-light skin tone, dark skin tone", + "unicode": "1f9d1-1f3fc-200d-1f91d-200d-1f9d1-1f3ff" + }, + ":people_holding_hands_tone3:": { + "category": "people", + "name": "people holding hands: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f91d-200d-1f9d1-1f3fd" + }, + ":people_holding_hands_tone3_tone1:": { + "category": "people", + "name": "people holding hands: medium skin tone, light skin tone", + "unicode": "1f9d1-1f3fd-200d-1f91d-200d-1f9d1-1f3fb" + }, + ":people_holding_hands_tone3_tone2:": { + "category": "people", + "name": "people holding hands: medium skin tone, medium-light skin tone", + "unicode": "1f9d1-1f3fd-200d-1f91d-200d-1f9d1-1f3fc" + }, + ":people_holding_hands_tone3_tone4:": { + "category": "people", + "name": "people holding hands: medium skin tone, medium-dark skin tone", + "unicode": "1f9d1-1f3fd-200d-1f91d-200d-1f9d1-1f3fe" + }, + ":people_holding_hands_tone3_tone5:": { + "category": "people", + "name": "people holding hands: medium skin tone, dark skin tone", + "unicode": "1f9d1-1f3fd-200d-1f91d-200d-1f9d1-1f3ff" + }, + ":people_holding_hands_tone4:": { + "category": "people", + "name": "people holding hands: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f91d-200d-1f9d1-1f3fe" + }, + ":people_holding_hands_tone4_tone1:": { + "category": "people", + "name": "people holding hands: medium-dark skin tone, light skin tone", + "unicode": "1f9d1-1f3fe-200d-1f91d-200d-1f9d1-1f3fb" + }, + ":people_holding_hands_tone4_tone2:": { + "category": "people", + "name": "people holding hands: medium dark skin tone, medium light skin tone", + "unicode": "1f9d1-1f3fe-200d-1f91d-200d-1f9d1-1f3fc" + }, + ":people_holding_hands_tone4_tone3:": { + "category": "people", + "name": "people holding hands: medium-dark skin tone, medium skin tone", + "unicode": "1f9d1-1f3fe-200d-1f91d-200d-1f9d1-1f3fd" + }, + ":people_holding_hands_tone4_tone5:": { + "category": "people", + "name": "people holding hands: medium-dark skin tone, dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f91d-200d-1f9d1-1f3ff" + }, + ":people_holding_hands_tone5:": { + "category": "people", + "name": "people holding hands: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f91d-200d-1f9d1-1f3ff" + }, + ":people_holding_hands_tone5_tone1:": { + "category": "people", + "name": "people holding hands: dark skin tone, light skin tone", + "unicode": "1f9d1-1f3ff-200d-1f91d-200d-1f9d1-1f3fb" + }, + ":people_holding_hands_tone5_tone2:": { + "category": "people", + "name": "people holding hands: dark skin tone, medium-light skin tone", + "unicode": "1f9d1-1f3ff-200d-1f91d-200d-1f9d1-1f3fc" + }, + ":people_holding_hands_tone5_tone3:": { + "category": "people", + "name": "people holding hands: dark skin tone, medium skin tone", + "unicode": "1f9d1-1f3ff-200d-1f91d-200d-1f9d1-1f3fd" + }, + ":people_holding_hands_tone5_tone4:": { + "category": "people", + "name": "people holding hands: dark skin tone, medium-dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f91d-200d-1f9d1-1f3fe" + }, + ":people_hugging:": { + "category": "people", + "name": "people hugging", + "unicode": "1fac2" + }, + ":people_with_bunny_ears_partying:": { + "category": "people", + "name": "people with bunny ears", + "unicode": "1f46f" + }, + ":people_wrestling:": { + "category": "activity", + "name": "people wrestling", + "unicode": "1f93c" + }, + ":performing_arts:": { + "category": "activity", + "name": "performing arts", + "unicode": "1f3ad" + }, + ":persevere:": { + "category": "people", + "name": "persevering face", + "unicode": "1f623" + }, + ":person_bald:": { + "category": "people", + "name": "person: bald", + "unicode": "1f9d1-200d-1f9b2" + }, + ":person_biking:": { + "category": "activity", + "name": "person biking", + "unicode": "1f6b4" + }, + ":person_biking_tone1:": { + "category": "activity", + "name": "person biking: light skin tone", + "unicode": "1f6b4-1f3fb" + }, + ":person_biking_tone2:": { + "category": "activity", + "name": "person biking: medium-light skin tone", + "unicode": "1f6b4-1f3fc" + }, + ":person_biking_tone3:": { + "category": "activity", + "name": "person biking: medium skin tone", + "unicode": "1f6b4-1f3fd" + }, + ":person_biking_tone4:": { + "category": "activity", + "name": "person biking: medium-dark skin tone", + "unicode": "1f6b4-1f3fe" + }, + ":person_biking_tone5:": { + "category": "activity", + "name": "person biking: dark skin tone", + "unicode": "1f6b4-1f3ff" + }, + ":person_bouncing_ball:": { + "category": "activity", + "name": "person bouncing ball", + "unicode": "26f9" + }, + ":person_bouncing_ball_tone1:": { + "category": "activity", + "name": "person bouncing ball: light skin tone", + "unicode": "26f9-1f3fb" + }, + ":person_bouncing_ball_tone2:": { + "category": "activity", + "name": "person bouncing ball: medium-light skin tone", + "unicode": "26f9-1f3fc" + }, + ":person_bouncing_ball_tone3:": { + "category": "activity", + "name": "person bouncing ball: medium skin tone", + "unicode": "26f9-1f3fd" + }, + ":person_bouncing_ball_tone4:": { + "category": "activity", + "name": "person bouncing ball: medium-dark skin tone", + "unicode": "26f9-1f3fe" + }, + ":person_bouncing_ball_tone5:": { + "category": "activity", + "name": "person bouncing ball: dark skin tone", + "unicode": "26f9-1f3ff" + }, + ":person_bowing:": { + "category": "people", + "name": "person bowing", + "unicode": "1f647" + }, + ":person_bowing_tone1:": { + "category": "people", + "name": "person bowing: light skin tone", + "unicode": "1f647-1f3fb" + }, + ":person_bowing_tone2:": { + "category": "people", + "name": "person bowing: medium-light skin tone", + "unicode": "1f647-1f3fc" + }, + ":person_bowing_tone3:": { + "category": "people", + "name": "person bowing: medium skin tone", + "unicode": "1f647-1f3fd" + }, + ":person_bowing_tone4:": { + "category": "people", + "name": "person bowing: medium-dark skin tone", + "unicode": "1f647-1f3fe" + }, + ":person_bowing_tone5:": { + "category": "people", + "name": "person bowing: dark skin tone", + "unicode": "1f647-1f3ff" + }, + ":person_climbing:": { + "category": "activity", + "name": "person climbing", + "unicode": "1f9d7" + }, + ":person_climbing_tone1:": { + "category": "activity", + "name": "person climbing: light skin tone", + "unicode": "1f9d7-1f3fb" + }, + ":person_climbing_tone2:": { + "category": "activity", + "name": "person climbing: medium-light skin tone", + "unicode": "1f9d7-1f3fc" + }, + ":person_climbing_tone3:": { + "category": "activity", + "name": "person climbing: medium skin tone", + "unicode": "1f9d7-1f3fd" + }, + ":person_climbing_tone4:": { + "category": "activity", + "name": "person climbing: medium-dark skin tone", + "unicode": "1f9d7-1f3fe" + }, + ":person_climbing_tone5:": { + "category": "activity", + "name": "person climbing: dark skin tone", + "unicode": "1f9d7-1f3ff" + }, + ":person_curly_hair:": { + "category": "people", + "name": "person: curly hair", + "unicode": "1f9d1-200d-1f9b1" + }, + ":person_doing_cartwheel:": { + "category": "activity", + "name": "person cartwheeling", + "unicode": "1f938" + }, + ":person_doing_cartwheel_tone1:": { + "category": "activity", + "name": "person cartwheeling: light skin tone", + "unicode": "1f938-1f3fb" + }, + ":person_doing_cartwheel_tone2:": { + "category": "activity", + "name": "person cartwheeling: medium-light skin tone", + "unicode": "1f938-1f3fc" + }, + ":person_doing_cartwheel_tone3:": { + "category": "activity", + "name": "person cartwheeling: medium skin tone", + "unicode": "1f938-1f3fd" + }, + ":person_doing_cartwheel_tone4:": { + "category": "activity", + "name": "person cartwheeling: medium-dark skin tone", + "unicode": "1f938-1f3fe" + }, + ":person_doing_cartwheel_tone5:": { + "category": "activity", + "name": "person cartwheeling: dark skin tone", + "unicode": "1f938-1f3ff" + }, + ":person_facepalming:": { + "category": "people", + "name": "person facepalming", + "unicode": "1f926" + }, + ":person_facepalming_tone1:": { + "category": "people", + "name": "person facepalming: light skin tone", + "unicode": "1f926-1f3fb" + }, + ":person_facepalming_tone2:": { + "category": "people", + "name": "person facepalming: medium-light skin tone", + "unicode": "1f926-1f3fc" + }, + ":person_facepalming_tone3:": { + "category": "people", + "name": "person facepalming: medium skin tone", + "unicode": "1f926-1f3fd" + }, + ":person_facepalming_tone4:": { + "category": "people", + "name": "person facepalming: medium-dark skin tone", + "unicode": "1f926-1f3fe" + }, + ":person_facepalming_tone5:": { + "category": "people", + "name": "person facepalming: dark skin tone", + "unicode": "1f926-1f3ff" + }, + ":person_feeding_baby:": { + "category": "people", + "name": "person feeding baby", + "unicode": "1f9d1-200d-1f37c" + }, + ":person_feeding_baby_tone1:": { + "category": "people", + "name": "person feeding baby: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f37c" + }, + ":person_feeding_baby_tone2:": { + "category": "people", + "name": "person feeding baby: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f37c" + }, + ":person_feeding_baby_tone3:": { + "category": "people", + "name": "person feeding baby: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f37c" + }, + ":person_feeding_baby_tone4:": { + "category": "people", + "name": "person feeding baby: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f37c" + }, + ":person_feeding_baby_tone5:": { + "category": "people", + "name": "person feeding baby: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f37c" + }, + ":person_fencing:": { + "category": "activity", + "name": "person fencing", + "unicode": "1f93a" + }, + ":person_frowning:": { + "category": "people", + "name": "person frowning", + "unicode": "1f64d" + }, + ":person_frowning_tone1:": { + "category": "people", + "name": "person frowning: light skin tone", + "unicode": "1f64d-1f3fb" + }, + ":person_frowning_tone2:": { + "category": "people", + "name": "person frowning: medium-light skin tone", + "unicode": "1f64d-1f3fc" + }, + ":person_frowning_tone3:": { + "category": "people", + "name": "person frowning: medium skin tone", + "unicode": "1f64d-1f3fd" + }, + ":person_frowning_tone4:": { + "category": "people", + "name": "person frowning: medium-dark skin tone", + "unicode": "1f64d-1f3fe" + }, + ":person_frowning_tone5:": { + "category": "people", + "name": "person frowning: dark skin tone", + "unicode": "1f64d-1f3ff" + }, + ":person_gesturing_no:": { + "category": "people", + "name": "person gesturing NO", + "unicode": "1f645" + }, + ":person_gesturing_no_tone1:": { + "category": "people", + "name": "person gesturing NO: light skin tone", + "unicode": "1f645-1f3fb" + }, + ":person_gesturing_no_tone2:": { + "category": "people", + "name": "person gesturing NO: medium-light skin tone", + "unicode": "1f645-1f3fc" + }, + ":person_gesturing_no_tone3:": { + "category": "people", + "name": "person gesturing NO: medium skin tone", + "unicode": "1f645-1f3fd" + }, + ":person_gesturing_no_tone4:": { + "category": "people", + "name": "person gesturing NO: medium-dark skin tone", + "unicode": "1f645-1f3fe" + }, + ":person_gesturing_no_tone5:": { + "category": "people", + "name": "person gesturing NO: dark skin tone", + "unicode": "1f645-1f3ff" + }, + ":person_gesturing_ok:": { + "category": "people", + "name": "person gesturing OK", + "unicode": "1f646" + }, + ":person_gesturing_ok_tone1:": { + "category": "people", + "name": "person gesturing OK: light skin tone", + "unicode": "1f646-1f3fb" + }, + ":person_gesturing_ok_tone2:": { + "category": "people", + "name": "person gesturing OK: medium-light skin tone", + "unicode": "1f646-1f3fc" + }, + ":person_gesturing_ok_tone3:": { + "category": "people", + "name": "person gesturing OK: medium skin tone", + "unicode": "1f646-1f3fd" + }, + ":person_gesturing_ok_tone4:": { + "category": "people", + "name": "person gesturing OK: medium-dark skin tone", + "unicode": "1f646-1f3fe" + }, + ":person_gesturing_ok_tone5:": { + "category": "people", + "name": "person gesturing OK: dark skin tone", + "unicode": "1f646-1f3ff" + }, + ":person_getting_haircut:": { + "category": "people", + "name": "person getting haircut", + "unicode": "1f487" + }, + ":person_getting_haircut_tone1:": { + "category": "people", + "name": "person getting haircut: light skin tone", + "unicode": "1f487-1f3fb" + }, + ":person_getting_haircut_tone2:": { + "category": "people", + "name": "person getting haircut: medium-light skin tone", + "unicode": "1f487-1f3fc" + }, + ":person_getting_haircut_tone3:": { + "category": "people", + "name": "person getting haircut: medium skin tone", + "unicode": "1f487-1f3fd" + }, + ":person_getting_haircut_tone4:": { + "category": "people", + "name": "person getting haircut: medium-dark skin tone", + "unicode": "1f487-1f3fe" + }, + ":person_getting_haircut_tone5:": { + "category": "people", + "name": "person getting haircut: dark skin tone", + "unicode": "1f487-1f3ff" + }, + ":person_getting_massage:": { + "category": "people", + "name": "person getting massage", + "unicode": "1f486" + }, + ":person_getting_massage_tone1:": { + "category": "people", + "name": "person getting massage: light skin tone", + "unicode": "1f486-1f3fb" + }, + ":person_getting_massage_tone2:": { + "category": "people", + "name": "person getting massage: medium-light skin tone", + "unicode": "1f486-1f3fc" + }, + ":person_getting_massage_tone3:": { + "category": "people", + "name": "person getting massage: medium skin tone", + "unicode": "1f486-1f3fd" + }, + ":person_getting_massage_tone4:": { + "category": "people", + "name": "person getting massage: medium-dark skin tone", + "unicode": "1f486-1f3fe" + }, + ":person_getting_massage_tone5:": { + "category": "people", + "name": "person getting massage: dark skin tone", + "unicode": "1f486-1f3ff" + }, + ":person_golfing:": { + "category": "activity", + "name": "person golfing", + "unicode": "1f3cc" + }, + ":person_golfing_tone1:": { + "category": "activity", + "name": "person golfing: light skin tone", + "unicode": "1f3cc-1f3fb" + }, + ":person_golfing_tone2:": { + "category": "activity", + "name": "person golfing: medium-light skin tone", + "unicode": "1f3cc-1f3fc" + }, + ":person_golfing_tone3:": { + "category": "activity", + "name": "person golfing: medium skin tone", + "unicode": "1f3cc-1f3fd" + }, + ":person_golfing_tone4:": { + "category": "activity", + "name": "person golfing: medium-dark skin tone", + "unicode": "1f3cc-1f3fe" + }, + ":person_golfing_tone5:": { + "category": "activity", + "name": "person golfing: dark skin tone", + "unicode": "1f3cc-1f3ff" + }, + ":person_in_bed_tone1:": { + "category": "objects", + "name": "person in bed: light skin tone", + "unicode": "1f6cc-1f3fb" + }, + ":person_in_bed_tone2:": { + "category": "objects", + "name": "person in bed: medium-light skin tone", + "unicode": "1f6cc-1f3fc" + }, + ":person_in_bed_tone3:": { + "category": "objects", + "name": "person in bed: medium skin tone", + "unicode": "1f6cc-1f3fd" + }, + ":person_in_bed_tone4:": { + "category": "objects", + "name": "person in bed: medium-dark skin tone", + "unicode": "1f6cc-1f3fe" + }, + ":person_in_bed_tone5:": { + "category": "objects", + "name": "person in bed: dark skin tone", + "unicode": "1f6cc-1f3ff" + }, + ":person_in_lotus_position:": { + "category": "activity", + "name": "person in lotus position", + "unicode": "1f9d8" + }, + ":person_in_lotus_position_tone1:": { + "category": "activity", + "name": "person in lotus position: light skin tone", + "unicode": "1f9d8-1f3fb" + }, + ":person_in_lotus_position_tone2:": { + "category": "activity", + "name": "person in lotus position: medium-light skin tone", + "unicode": "1f9d8-1f3fc" + }, + ":person_in_lotus_position_tone3:": { + "category": "activity", + "name": "person in lotus position: medium skin tone", + "unicode": "1f9d8-1f3fd" + }, + ":person_in_lotus_position_tone4:": { + "category": "activity", + "name": "person in lotus position: medium-dark skin tone", + "unicode": "1f9d8-1f3fe" + }, + ":person_in_lotus_position_tone5:": { + "category": "activity", + "name": "person in lotus position: dark skin tone", + "unicode": "1f9d8-1f3ff" + }, + ":person_in_manual_wheelchair:": { + "category": "people", + "name": "person in manual wheelchair", + "unicode": "1f9d1-200d-1f9bd" + }, + ":person_in_manual_wheelchair_facing_right:": { + "category": "people", + "name": "person in manual wheelchair facing right", + "unicode": "1f9d1-200d-1f9bd-200d-27a1-fe0f" + }, + ":person_in_manual_wheelchair_facing_right_tone1:": { + "category": "people", + "name": "person in manual wheelchair facing right: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f9bd-200d-27a1-fe0f" + }, + ":person_in_manual_wheelchair_facing_right_tone2:": { + "category": "people", + "name": "person in manual wheelchair facing right: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f9bd-200d-27a1-fe0f" + }, + ":person_in_manual_wheelchair_facing_right_tone3:": { + "category": "people", + "name": "person in manual wheelchair facing right: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f9bd-200d-27a1-fe0f" + }, + ":person_in_manual_wheelchair_facing_right_tone4:": { + "category": "people", + "name": "person in manual wheelchair facing right: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f9bd-200d-27a1-fe0f" + }, + ":person_in_manual_wheelchair_facing_right_tone5:": { + "category": "people", + "name": "person in manual wheelchair facing right: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f9bd-200d-27a1-fe0f" + }, + ":person_in_manual_wheelchair_tone1:": { + "category": "people", + "name": "person in manual wheelchair: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f9bd" + }, + ":person_in_manual_wheelchair_tone2:": { + "category": "people", + "name": "person in manual wheelchair: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f9bd" + }, + ":person_in_manual_wheelchair_tone3:": { + "category": "people", + "name": "person in manual wheelchair: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f9bd" + }, + ":person_in_manual_wheelchair_tone4:": { + "category": "people", + "name": "person in manual wheelchair: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f9bd" + }, + ":person_in_manual_wheelchair_tone5:": { + "category": "people", + "name": "person in manual wheelchair: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f9bd" + }, + ":person_in_motorized_wheelchair:": { + "category": "people", + "name": "person in motorized wheelchair", + "unicode": "1f9d1-200d-1f9bc" + }, + ":person_in_motorized_wheelchair_facing_right:": { + "category": "people", + "name": "person in motorized wheelchair facing right", + "unicode": "1f9d1-200d-1f9bc-200d-27a1-fe0f" + }, + ":person_in_motorized_wheelchair_facing_right_tone1:": { + "category": "people", + "name": "person in motorized wheelchair facing right: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f9bc-200d-27a1-fe0f" + }, + ":person_in_motorized_wheelchair_facing_right_tone2:": { + "category": "people", + "name": "person in motorized wheelchair facing right: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f9bc-200d-27a1-fe0f" + }, + ":person_in_motorized_wheelchair_facing_right_tone3:": { + "category": "people", + "name": "person in motorized wheelchair facing right: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f9bc-200d-27a1-fe0f" + }, + ":person_in_motorized_wheelchair_facing_right_tone4:": { + "category": "people", + "name": "person in motorized wheelchair facing right: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f9bc-200d-27a1-fe0f" + }, + ":person_in_motorized_wheelchair_facing_right_tone5:": { + "category": "people", + "name": "person in motorized wheelchair facing right: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f9bc-200d-27a1-fe0f" + }, + ":person_in_motorized_wheelchair_tone1:": { + "category": "people", + "name": "person in motorized wheelchair: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f9bc" + }, + ":person_in_motorized_wheelchair_tone2:": { + "category": "people", + "name": "person in motorized wheelchair: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f9bc" + }, + ":person_in_motorized_wheelchair_tone3:": { + "category": "people", + "name": "person in motorized wheelchair: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f9bc" + }, + ":person_in_motorized_wheelchair_tone4:": { + "category": "people", + "name": "person in motorized wheelchair: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f9bc" + }, + ":person_in_motorized_wheelchair_tone5:": { + "category": "people", + "name": "person in motorized wheelchair: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f9bc" + }, + ":person_in_steamy_room:": { + "category": "people", + "name": "person in steamy room", + "unicode": "1f9d6" + }, + ":person_in_steamy_room_tone1:": { + "category": "people", + "name": "person in steamy room: light skin tone", + "unicode": "1f9d6-1f3fb" + }, + ":person_in_steamy_room_tone2:": { + "category": "people", + "name": "person in steamy room: medium-light skin tone", + "unicode": "1f9d6-1f3fc" + }, + ":person_in_steamy_room_tone3:": { + "category": "people", + "name": "person in steamy room: medium skin tone", + "unicode": "1f9d6-1f3fd" + }, + ":person_in_steamy_room_tone4:": { + "category": "people", + "name": "person in steamy room: medium-dark skin tone", + "unicode": "1f9d6-1f3fe" + }, + ":person_in_steamy_room_tone5:": { + "category": "people", + "name": "person in steamy room: dark skin tone", + "unicode": "1f9d6-1f3ff" + }, + ":person_in_tuxedo:": { + "category": "people", + "name": "person in tuxedo", + "unicode": "1f935" + }, + ":person_in_tuxedo_tone1:": { + "category": "people", + "name": "person in tuxedo: light skin tone", + "unicode": "1f935-1f3fb" + }, + ":person_in_tuxedo_tone2:": { + "category": "people", + "name": "person in tuxedo: medium-light skin tone", + "unicode": "1f935-1f3fc" + }, + ":person_in_tuxedo_tone3:": { + "category": "people", + "name": "person in tuxedo: medium skin tone", + "unicode": "1f935-1f3fd" + }, + ":person_in_tuxedo_tone4:": { + "category": "people", + "name": "person in tuxedo: medium-dark skin tone", + "unicode": "1f935-1f3fe" + }, + ":person_in_tuxedo_tone5:": { + "category": "people", + "name": "person in tuxedo: dark skin tone", + "unicode": "1f935-1f3ff" + }, + ":person_juggling:": { + "category": "activity", + "name": "person juggling", + "unicode": "1f939" + }, + ":person_juggling_tone1:": { + "category": "activity", + "name": "person juggling: light skin tone", + "unicode": "1f939-1f3fb" + }, + ":person_juggling_tone2:": { + "category": "activity", + "name": "person juggling: medium-light skin tone", + "unicode": "1f939-1f3fc" + }, + ":person_juggling_tone3:": { + "category": "activity", + "name": "person juggling: medium skin tone", + "unicode": "1f939-1f3fd" + }, + ":person_juggling_tone4:": { + "category": "activity", + "name": "person juggling: medium-dark skin tone", + "unicode": "1f939-1f3fe" + }, + ":person_juggling_tone5:": { + "category": "activity", + "name": "person juggling: dark skin tone", + "unicode": "1f939-1f3ff" + }, + ":person_kneeling:": { + "category": "people", + "name": "person kneeling", + "unicode": "1f9ce" + }, + ":person_kneeling_facing_right:": { + "category": "people", + "name": "person kneeling facing right", + "unicode": "1f9ce-200d-27a1-fe0f" + }, + ":person_kneeling_facing_right_tone1:": { + "category": "people", + "name": "person kneeling facing right: light skin tone", + "unicode": "1f9ce-1f3fb-200d-27a1-fe0f" + }, + ":person_kneeling_facing_right_tone2:": { + "category": "people", + "name": "person kneeling facing right: medium-light skin tone", + "unicode": "1f9ce-1f3fc-200d-27a1-fe0f" + }, + ":person_kneeling_facing_right_tone3:": { + "category": "people", + "name": "person kneeling facing right: medium skin tone", + "unicode": "1f9ce-1f3fd-200d-27a1-fe0f" + }, + ":person_kneeling_facing_right_tone4:": { + "category": "people", + "name": "person kneeling facing right: medium-dark skin tone", + "unicode": "1f9ce-1f3fe-200d-27a1-fe0f" + }, + ":person_kneeling_facing_right_tone5:": { + "category": "people", + "name": "person kneeling facing right: dark skin tone", + "unicode": "1f9ce-1f3ff-200d-27a1-fe0f" + }, + ":person_kneeling_tone1:": { + "category": "people", + "name": "person kneeling: light skin tone", + "unicode": "1f9ce-1f3fb" + }, + ":person_kneeling_tone2:": { + "category": "people", + "name": "person kneeling: medium-light skin tone", + "unicode": "1f9ce-1f3fc" + }, + ":person_kneeling_tone3:": { + "category": "people", + "name": "person kneeling: medium skin tone", + "unicode": "1f9ce-1f3fd" + }, + ":person_kneeling_tone4:": { + "category": "people", + "name": "person kneeling: medium-dark skin tone", + "unicode": "1f9ce-1f3fe" + }, + ":person_kneeling_tone5:": { + "category": "people", + "name": "person kneeling: dark skin tone", + "unicode": "1f9ce-1f3ff" + }, + ":person_lifting_weights:": { + "category": "activity", + "name": "person lifting weights", + "unicode": "1f3cb" + }, + ":person_lifting_weights_tone1:": { + "category": "activity", + "name": "person lifting weights: light skin tone", + "unicode": "1f3cb-1f3fb" + }, + ":person_lifting_weights_tone2:": { + "category": "activity", + "name": "person lifting weights: medium-light skin tone", + "unicode": "1f3cb-1f3fc" + }, + ":person_lifting_weights_tone3:": { + "category": "activity", + "name": "person lifting weights: medium skin tone", + "unicode": "1f3cb-1f3fd" + }, + ":person_lifting_weights_tone4:": { + "category": "activity", + "name": "person lifting weights: medium-dark skin tone", + "unicode": "1f3cb-1f3fe" + }, + ":person_lifting_weights_tone5:": { + "category": "activity", + "name": "person lifting weights: dark skin tone", + "unicode": "1f3cb-1f3ff" + }, + ":person_mountain_biking:": { + "category": "activity", + "name": "person mountain biking", + "unicode": "1f6b5" + }, + ":person_mountain_biking_tone1:": { + "category": "activity", + "name": "person mountain biking: light skin tone", + "unicode": "1f6b5-1f3fb" + }, + ":person_mountain_biking_tone2:": { + "category": "activity", + "name": "person mountain biking: medium-light skin tone", + "unicode": "1f6b5-1f3fc" + }, + ":person_mountain_biking_tone3:": { + "category": "activity", + "name": "person mountain biking: medium skin tone", + "unicode": "1f6b5-1f3fd" + }, + ":person_mountain_biking_tone4:": { + "category": "activity", + "name": "person mountain biking: medium-dark skin tone", + "unicode": "1f6b5-1f3fe" + }, + ":person_mountain_biking_tone5:": { + "category": "activity", + "name": "person mountain biking: dark skin tone", + "unicode": "1f6b5-1f3ff" + }, + ":person_playing_handball:": { + "category": "activity", + "name": "person playing handball", + "unicode": "1f93e" + }, + ":person_playing_handball_tone1:": { + "category": "activity", + "name": "person playing handball: light skin tone", + "unicode": "1f93e-1f3fb" + }, + ":person_playing_handball_tone2:": { + "category": "activity", + "name": "person playing handball: medium-light skin tone", + "unicode": "1f93e-1f3fc" + }, + ":person_playing_handball_tone3:": { + "category": "activity", + "name": "person playing handball: medium skin tone", + "unicode": "1f93e-1f3fd" + }, + ":person_playing_handball_tone4:": { + "category": "activity", + "name": "person playing handball: medium-dark skin tone", + "unicode": "1f93e-1f3fe" + }, + ":person_playing_handball_tone5:": { + "category": "activity", + "name": "person playing handball: dark skin tone", + "unicode": "1f93e-1f3ff" + }, + ":person_playing_water_polo:": { + "category": "activity", + "name": "person playing water polo", + "unicode": "1f93d" + }, + ":person_playing_water_polo_tone1:": { + "category": "activity", + "name": "person playing water polo: light skin tone", + "unicode": "1f93d-1f3fb" + }, + ":person_playing_water_polo_tone2:": { + "category": "activity", + "name": "person playing water polo: medium-light skin tone", + "unicode": "1f93d-1f3fc" + }, + ":person_playing_water_polo_tone3:": { + "category": "activity", + "name": "person playing water polo: medium skin tone", + "unicode": "1f93d-1f3fd" + }, + ":person_playing_water_polo_tone4:": { + "category": "activity", + "name": "person playing water polo: medium-dark skin tone", + "unicode": "1f93d-1f3fe" + }, + ":person_playing_water_polo_tone5:": { + "category": "activity", + "name": "person playing water polo: dark skin tone", + "unicode": "1f93d-1f3ff" + }, + ":person_pouting:": { + "category": "people", + "name": "person pouting", + "unicode": "1f64e" + }, + ":person_pouting_tone1:": { + "category": "people", + "name": "person pouting: light skin tone", + "unicode": "1f64e-1f3fb" + }, + ":person_pouting_tone2:": { + "category": "people", + "name": "person pouting: medium-light skin tone", + "unicode": "1f64e-1f3fc" + }, + ":person_pouting_tone3:": { + "category": "people", + "name": "person pouting: medium skin tone", + "unicode": "1f64e-1f3fd" + }, + ":person_pouting_tone4:": { + "category": "people", + "name": "person pouting: medium-dark skin tone", + "unicode": "1f64e-1f3fe" + }, + ":person_pouting_tone5:": { + "category": "people", + "name": "person pouting: dark skin tone", + "unicode": "1f64e-1f3ff" + }, + ":person_raising_hand:": { + "category": "people", + "name": "person raising hand", + "unicode": "1f64b" + }, + ":person_raising_hand_tone1:": { + "category": "people", + "name": "person raising hand: light skin tone", + "unicode": "1f64b-1f3fb" + }, + ":person_raising_hand_tone2:": { + "category": "people", + "name": "person raising hand: medium-light skin tone", + "unicode": "1f64b-1f3fc" + }, + ":person_raising_hand_tone3:": { + "category": "people", + "name": "person raising hand: medium skin tone", + "unicode": "1f64b-1f3fd" + }, + ":person_raising_hand_tone4:": { + "category": "people", + "name": "person raising hand: medium-dark skin tone", + "unicode": "1f64b-1f3fe" + }, + ":person_raising_hand_tone5:": { + "category": "people", + "name": "person raising hand: dark skin tone", + "unicode": "1f64b-1f3ff" + }, + ":person_red_hair:": { + "category": "people", + "name": "person: red hair", + "unicode": "1f9d1-200d-1f9b0" + }, + ":person_rowing_boat:": { + "category": "activity", + "name": "person rowing boat", + "unicode": "1f6a3" + }, + ":person_rowing_boat_tone1:": { + "category": "activity", + "name": "person rowing boat: light skin tone", + "unicode": "1f6a3-1f3fb" + }, + ":person_rowing_boat_tone2:": { + "category": "activity", + "name": "person rowing boat: medium-light skin tone", + "unicode": "1f6a3-1f3fc" + }, + ":person_rowing_boat_tone3:": { + "category": "activity", + "name": "person rowing boat: medium skin tone", + "unicode": "1f6a3-1f3fd" + }, + ":person_rowing_boat_tone4:": { + "category": "activity", + "name": "person rowing boat: medium-dark skin tone", + "unicode": "1f6a3-1f3fe" + }, + ":person_rowing_boat_tone5:": { + "category": "activity", + "name": "person rowing boat: dark skin tone", + "unicode": "1f6a3-1f3ff" + }, + ":person_running:": { + "category": "people", + "name": "person running", + "unicode": "1f3c3" + }, + ":person_running_facing_right:": { + "category": "people", + "name": "person running facing right", + "unicode": "1f3c3-200d-27a1-fe0f" + }, + ":person_running_facing_right_tone1:": { + "category": "people", + "name": "person running facing right: light skin tone", + "unicode": "1f3c3-1f3fb-200d-27a1-fe0f" + }, + ":person_running_facing_right_tone2:": { + "category": "people", + "name": "person running facing right: medium-light skin tone", + "unicode": "1f3c3-1f3fc-200d-27a1-fe0f" + }, + ":person_running_facing_right_tone3:": { + "category": "people", + "name": "person running facing right: medium skin tone", + "unicode": "1f3c3-1f3fd-200d-27a1-fe0f" + }, + ":person_running_facing_right_tone4:": { + "category": "people", + "name": "person running facing right: medium-dark skin tone", + "unicode": "1f3c3-1f3fe-200d-27a1-fe0f" + }, + ":person_running_facing_right_tone5:": { + "category": "people", + "name": "person running facing right: dark skin tone", + "unicode": "1f3c3-1f3ff-200d-27a1-fe0f" + }, + ":person_running_tone1:": { + "category": "people", + "name": "person running: light skin tone", + "unicode": "1f3c3-1f3fb" + }, + ":person_running_tone2:": { + "category": "people", + "name": "person running: medium-light skin tone", + "unicode": "1f3c3-1f3fc" + }, + ":person_running_tone3:": { + "category": "people", + "name": "person running: medium skin tone", + "unicode": "1f3c3-1f3fd" + }, + ":person_running_tone4:": { + "category": "people", + "name": "person running: medium-dark skin tone", + "unicode": "1f3c3-1f3fe" + }, + ":person_running_tone5:": { + "category": "people", + "name": "person running: dark skin tone", + "unicode": "1f3c3-1f3ff" + }, + ":person_shrugging:": { + "category": "people", + "name": "person shrugging", + "unicode": "1f937" + }, + ":person_shrugging_tone1:": { + "category": "people", + "name": "person shrugging: light skin tone", + "unicode": "1f937-1f3fb" + }, + ":person_shrugging_tone2:": { + "category": "people", + "name": "person shrugging: medium-light skin tone", + "unicode": "1f937-1f3fc" + }, + ":person_shrugging_tone3:": { + "category": "people", + "name": "person shrugging: medium skin tone", + "unicode": "1f937-1f3fd" + }, + ":person_shrugging_tone4:": { + "category": "people", + "name": "person shrugging: medium-dark skin tone", + "unicode": "1f937-1f3fe" + }, + ":person_shrugging_tone5:": { + "category": "people", + "name": "person shrugging: dark skin tone", + "unicode": "1f937-1f3ff" + }, + ":person_standing:": { + "category": "people", + "name": "person standing", + "unicode": "1f9cd" + }, + ":person_standing_tone1:": { + "category": "people", + "name": "person standing: light skin tone", + "unicode": "1f9cd-1f3fb" + }, + ":person_standing_tone2:": { + "category": "people", + "name": "person standing: medium-light skin tone", + "unicode": "1f9cd-1f3fc" + }, + ":person_standing_tone3:": { + "category": "people", + "name": "person standing: medium skin tone", + "unicode": "1f9cd-1f3fd" + }, + ":person_standing_tone4:": { + "category": "people", + "name": "person standing: medium-dark skin tone", + "unicode": "1f9cd-1f3fe" + }, + ":person_standing_tone5:": { + "category": "people", + "name": "person standing: dark skin tone", + "unicode": "1f9cd-1f3ff" + }, + ":person_surfing:": { + "category": "activity", + "name": "person surfing", + "unicode": "1f3c4" + }, + ":person_surfing_tone1:": { + "category": "activity", + "name": "person surfing: light skin tone", + "unicode": "1f3c4-1f3fb" + }, + ":person_surfing_tone2:": { + "category": "activity", + "name": "person surfing: medium-light skin tone", + "unicode": "1f3c4-1f3fc" + }, + ":person_surfing_tone3:": { + "category": "activity", + "name": "person surfing: medium skin tone", + "unicode": "1f3c4-1f3fd" + }, + ":person_surfing_tone4:": { + "category": "activity", + "name": "person surfing: medium-dark skin tone", + "unicode": "1f3c4-1f3fe" + }, + ":person_surfing_tone5:": { + "category": "activity", + "name": "person surfing: dark skin tone", + "unicode": "1f3c4-1f3ff" + }, + ":person_swimming:": { + "category": "activity", + "name": "person swimming", + "unicode": "1f3ca" + }, + ":person_swimming_tone1:": { + "category": "activity", + "name": "person swimming: light skin tone", + "unicode": "1f3ca-1f3fb" + }, + ":person_swimming_tone2:": { + "category": "activity", + "name": "person swimming: medium-light skin tone", + "unicode": "1f3ca-1f3fc" + }, + ":person_swimming_tone3:": { + "category": "activity", + "name": "person swimming: medium skin tone", + "unicode": "1f3ca-1f3fd" + }, + ":person_swimming_tone4:": { + "category": "activity", + "name": "person swimming: medium-dark skin tone", + "unicode": "1f3ca-1f3fe" + }, + ":person_swimming_tone5:": { + "category": "activity", + "name": "person swimming: dark skin tone", + "unicode": "1f3ca-1f3ff" + }, + ":person_tipping_hand:": { + "category": "people", + "name": "person tipping hand", + "unicode": "1f481" + }, + ":person_tipping_hand_tone1:": { + "category": "people", + "name": "person tipping hand: light skin tone", + "unicode": "1f481-1f3fb" + }, + ":person_tipping_hand_tone2:": { + "category": "people", + "name": "person tipping hand: medium-light skin tone", + "unicode": "1f481-1f3fc" + }, + ":person_tipping_hand_tone3:": { + "category": "people", + "name": "person tipping hand: medium skin tone", + "unicode": "1f481-1f3fd" + }, + ":person_tipping_hand_tone4:": { + "category": "people", + "name": "person tipping hand: medium-dark skin tone", + "unicode": "1f481-1f3fe" + }, + ":person_tipping_hand_tone5:": { + "category": "people", + "name": "person tipping hand: dark skin tone", + "unicode": "1f481-1f3ff" + }, + ":person_tone1_bald:": { + "category": "people", + "name": "person: light skin tone, bald", + "unicode": "1f9d1-1f3fb-200d-1f9b2" + }, + ":person_tone1_curly_hair:": { + "category": "people", + "name": "person: light skin tone, curly hair", + "unicode": "1f9d1-1f3fb-200d-1f9b1" + }, + ":person_tone1_red_hair:": { + "category": "people", + "name": "person: light skin tone, red hair", + "unicode": "1f9d1-1f3fb-200d-1f9b0" + }, + ":person_tone1_white_hair:": { + "category": "people", + "name": "person: light skin tone, white hair", + "unicode": "1f9d1-1f3fb-200d-1f9b3" + }, + ":person_tone2_bald:": { + "category": "people", + "name": "person: medium-light skin tone, bald", + "unicode": "1f9d1-1f3fc-200d-1f9b2" + }, + ":person_tone2_curly_hair:": { + "category": "people", + "name": "person: medium-light skin tone, curly hair", + "unicode": "1f9d1-1f3fc-200d-1f9b1" + }, + ":person_tone2_red_hair:": { + "category": "people", + "name": "person: medium-light skin tone, red hair", + "unicode": "1f9d1-1f3fc-200d-1f9b0" + }, + ":person_tone2_white_hair:": { + "category": "people", + "name": "person: medium-light skin tone, white hair", + "unicode": "1f9d1-1f3fc-200d-1f9b3" + }, + ":person_tone3_bald:": { + "category": "people", + "name": "person: medium skin tone, bald", + "unicode": "1f9d1-1f3fd-200d-1f9b2" + }, + ":person_tone3_curly_hair:": { + "category": "people", + "name": "person: medium skin tone, curly hair", + "unicode": "1f9d1-1f3fd-200d-1f9b1" + }, + ":person_tone3_red_hair:": { + "category": "people", + "name": "person: medium skin tone, red hair", + "unicode": "1f9d1-1f3fd-200d-1f9b0" + }, + ":person_tone3_white_hair:": { + "category": "people", + "name": "person: medium skin tone, white hair", + "unicode": "1f9d1-1f3fd-200d-1f9b3" + }, + ":person_tone4_bald:": { + "category": "people", + "name": "person: medium-dark skin tone, bald", + "unicode": "1f9d1-1f3fe-200d-1f9b2" + }, + ":person_tone4_curly_hair:": { + "category": "people", + "name": "person: medium-dark skin tone, curly hair", + "unicode": "1f9d1-1f3fe-200d-1f9b1" + }, + ":person_tone4_red_hair:": { + "category": "people", + "name": "person: medium-dark skin tone, red hair", + "unicode": "1f9d1-1f3fe-200d-1f9b0" + }, + ":person_tone4_white_hair:": { + "category": "people", + "name": "person: medium-dark skin tone, white hair", + "unicode": "1f9d1-1f3fe-200d-1f9b3" + }, + ":person_tone5_bald:": { + "category": "people", + "name": "person: dark skin tone, bald", + "unicode": "1f9d1-1f3ff-200d-1f9b2" + }, + ":person_tone5_curly_hair:": { + "category": "people", + "name": "person: dark skin tone, curly hair", + "unicode": "1f9d1-1f3ff-200d-1f9b1" + }, + ":person_tone5_red_hair:": { + "category": "people", + "name": "person: dark skin tone, red hair", + "unicode": "1f9d1-1f3ff-200d-1f9b0" + }, + ":person_tone5_white_hair:": { + "category": "people", + "name": "person: dark skin tone, white hair", + "unicode": "1f9d1-1f3ff-200d-1f9b3" + }, + ":person_walking:": { + "category": "people", + "name": "person walking", + "unicode": "1f6b6" + }, + ":person_walking_facing_right:": { + "category": "people", + "name": "person walking facing right", + "unicode": "1f6b6-200d-27a1-fe0f" + }, + ":person_walking_facing_right_tone1:": { + "category": "people", + "name": "person walking facing right: light skin tone", + "unicode": "1f6b6-1f3fb-200d-27a1-fe0f" + }, + ":person_walking_facing_right_tone2:": { + "category": "people", + "name": "person walking facing right: medium-light skin tone", + "unicode": "1f6b6-1f3fc-200d-27a1-fe0f" + }, + ":person_walking_facing_right_tone3:": { + "category": "people", + "name": "person walking facing right: medium skin tone", + "unicode": "1f6b6-1f3fd-200d-27a1-fe0f" + }, + ":person_walking_facing_right_tone4:": { + "category": "people", + "name": "person walking facing right: medium-dark skin tone", + "unicode": "1f6b6-1f3fe-200d-27a1-fe0f" + }, + ":person_walking_facing_right_tone5:": { + "category": "people", + "name": "person walking facing right: dark skin tone", + "unicode": "1f6b6-1f3ff-200d-27a1-fe0f" + }, + ":person_walking_tone1:": { + "category": "people", + "name": "person walking: light skin tone", + "unicode": "1f6b6-1f3fb" + }, + ":person_walking_tone2:": { + "category": "people", + "name": "person walking: medium-light skin tone", + "unicode": "1f6b6-1f3fc" + }, + ":person_walking_tone3:": { + "category": "people", + "name": "person walking: medium skin tone", + "unicode": "1f6b6-1f3fd" + }, + ":person_walking_tone4:": { + "category": "people", + "name": "person walking: medium-dark skin tone", + "unicode": "1f6b6-1f3fe" + }, + ":person_walking_tone5:": { + "category": "people", + "name": "person walking: dark skin tone", + "unicode": "1f6b6-1f3ff" + }, + ":person_wearing_turban:": { + "category": "people", + "name": "person wearing turban", + "unicode": "1f473" + }, + ":person_wearing_turban_tone1:": { + "category": "people", + "name": "person wearing turban: light skin tone", + "unicode": "1f473-1f3fb" + }, + ":person_wearing_turban_tone2:": { + "category": "people", + "name": "person wearing turban: medium-light skin tone", + "unicode": "1f473-1f3fc" + }, + ":person_wearing_turban_tone3:": { + "category": "people", + "name": "person wearing turban: medium skin tone", + "unicode": "1f473-1f3fd" + }, + ":person_wearing_turban_tone4:": { + "category": "people", + "name": "person wearing turban: medium-dark skin tone", + "unicode": "1f473-1f3fe" + }, + ":person_wearing_turban_tone5:": { + "category": "people", + "name": "person wearing turban: dark skin tone", + "unicode": "1f473-1f3ff" + }, + ":person_white_hair:": { + "category": "people", + "name": "person: white hair", + "unicode": "1f9d1-200d-1f9b3" + }, + ":person_with_crown:": { + "category": "people", + "name": "person with crown", + "unicode": "1fac5" + }, + ":person_with_crown_tone1:": { + "category": "people", + "name": "person with crown: light skin tone", + "unicode": "1fac5-1f3fb" + }, + ":person_with_crown_tone2:": { + "category": "people", + "name": "person with crown: medium-light skin tone", + "unicode": "1fac5-1f3fc" + }, + ":person_with_crown_tone3:": { + "category": "people", + "name": "person with crown: medium skin tone", + "unicode": "1fac5-1f3fd" + }, + ":person_with_crown_tone4:": { + "category": "people", + "name": "person with crown: medium-dark skin tone", + "unicode": "1fac5-1f3fe" + }, + ":person_with_crown_tone5:": { + "category": "people", + "name": "person with crown: dark skin tone", + "unicode": "1fac5-1f3ff" + }, + ":person_with_probing_cane:": { + "category": "people", + "name": "person with probing cane", + "unicode": "1f9d1-200d-1f9af" + }, + ":person_with_probing_cane_tone1:": { + "category": "people", + "name": "person with probing cane: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f9af" + }, + ":person_with_probing_cane_tone2:": { + "category": "people", + "name": "person with probing cane: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f9af" + }, + ":person_with_probing_cane_tone3:": { + "category": "people", + "name": "person with probing cane: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f9af" + }, + ":person_with_probing_cane_tone4:": { + "category": "people", + "name": "person with probing cane: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f9af" + }, + ":person_with_probing_cane_tone5:": { + "category": "people", + "name": "person with probing cane: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f9af" + }, + ":person_with_veil:": { + "category": "people", + "name": "person with veil", + "unicode": "1f470" + }, + ":person_with_veil_tone1:": { + "category": "people", + "name": "person with veil: light skin tone", + "unicode": "1f470-1f3fb" + }, + ":person_with_veil_tone2:": { + "category": "people", + "name": "person with veil: medium-light skin tone", + "unicode": "1f470-1f3fc" + }, + ":person_with_veil_tone3:": { + "category": "people", + "name": "person with veil: medium skin tone", + "unicode": "1f470-1f3fd" + }, + ":person_with_veil_tone4:": { + "category": "people", + "name": "person with veil: medium-dark skin tone", + "unicode": "1f470-1f3fe" + }, + ":person_with_veil_tone5:": { + "category": "people", + "name": "person with veil: dark skin tone", + "unicode": "1f470-1f3ff" + }, + ":person_with_white_cane_facing_right:": { + "category": "people", + "name": "person with white cane facing right", + "unicode": "1f9d1-200d-1f9af-200d-27a1-fe0f" + }, + ":person_with_white_cane_facing_right_tone1:": { + "category": "people", + "name": "person with white cane facing right: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f9af-200d-27a1-fe0f" + }, + ":person_with_white_cane_facing_right_tone2:": { + "category": "people", + "name": "person with white cane facing right: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f9af-200d-27a1-fe0f" + }, + ":person_with_white_cane_facing_right_tone3:": { + "category": "people", + "name": "person with white cane facing right: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f9af-200d-27a1-fe0f" + }, + ":person_with_white_cane_facing_right_tone4:": { + "category": "people", + "name": "person with white cane facing right: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f9af-200d-27a1-fe0f" + }, + ":person_with_white_cane_facing_right_tone5:": { + "category": "people", + "name": "person with white cane facing right: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f9af-200d-27a1-fe0f" + }, + ":petri_dish:": { + "category": "objects", + "name": "petri dish", + "unicode": "1f9eb" + }, + ":phoenix:": { + "category": "nature", + "name": "phoenix", + "unicode": "1f426-200d-1f525" + }, + ":pick:": { + "category": "objects", + "name": "pick", + "unicode": "26cf" + }, + ":pickup_truck:": { + "category": "travel", + "name": "pickup truck", + "unicode": "1f6fb" + }, + ":pie:": { + "category": "food", + "name": "pie", + "unicode": "1f967" + }, + ":pig2:": { + "category": "nature", + "name": "pig", + "unicode": "1f416" + }, + ":pig:": { + "category": "nature", + "name": "pig face", + "unicode": "1f437" + }, + ":pig_nose:": { + "category": "nature", + "name": "pig nose", + "unicode": "1f43d" + }, + ":pill:": { + "category": "objects", + "name": "pill", + "unicode": "1f48a" + }, + ":pilot:": { + "category": "people", + "name": "pilot", + "unicode": "1f9d1-200d-2708-fe0f" + }, + ":pilot_tone1:": { + "category": "people", + "name": "pilot: light skin tone", + "unicode": "1f9d1-1f3fb-200d-2708-fe0f" + }, + ":pilot_tone2:": { + "category": "people", + "name": "pilot: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-2708-fe0f" + }, + ":pilot_tone3:": { + "category": "people", + "name": "pilot: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-2708-fe0f" + }, + ":pilot_tone4:": { + "category": "people", + "name": "pilot: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-2708-fe0f" + }, + ":pilot_tone5:": { + "category": "people", + "name": "pilot: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-2708-fe0f" + }, + ":pinched_fingers:": { + "category": "people", + "name": "pinched fingers", + "unicode": "1f90c" + }, + ":pinched_fingers_tone1:": { + "category": "people", + "name": "pinched fingers: light skin tone", + "unicode": "1f90c-1f3fb" + }, + ":pinched_fingers_tone2:": { + "category": "people", + "name": "pinched fingers: medium-light skin tone", + "unicode": "1f90c-1f3fc" + }, + ":pinched_fingers_tone3:": { + "category": "people", + "name": "pinched fingers: medium skin tone", + "unicode": "1f90c-1f3fd" + }, + ":pinched_fingers_tone4:": { + "category": "people", + "name": "pinched fingers: medium-dark skin tone", + "unicode": "1f90c-1f3fe" + }, + ":pinched_fingers_tone5:": { + "category": "people", + "name": "pinched fingers: dark skin tone", + "unicode": "1f90c-1f3ff" + }, + ":pinching_hand:": { + "category": "people", + "name": "pinching hand", + "unicode": "1f90f" + }, + ":pinching_hand_tone1:": { + "category": "people", + "name": "pinching hand: light skin tone", + "unicode": "1f90f-1f3fb" + }, + ":pinching_hand_tone2:": { + "category": "people", + "name": "pinching hand: medium-light skin tone", + "unicode": "1f90f-1f3fc" + }, + ":pinching_hand_tone3:": { + "category": "people", + "name": "pinching hand: medium skin tone", + "unicode": "1f90f-1f3fd" + }, + ":pinching_hand_tone4:": { + "category": "people", + "name": "pinching hand: medium-dark skin tone", + "unicode": "1f90f-1f3fe" + }, + ":pinching_hand_tone5:": { + "category": "people", + "name": "pinching hand: dark skin tone", + "unicode": "1f90f-1f3ff" + }, + ":pineapple:": { + "category": "food", + "name": "pineapple", + "unicode": "1f34d" + }, + ":ping_pong:": { + "category": "activity", + "name": "ping pong", + "unicode": "1f3d3" + }, + ":pink_heart:": { + "category": "symbols", + "name": "pink heart", + "unicode": "1fa77" + }, + ":pirate_flag:": { + "category": "flags", + "name": "pirate flag", + "unicode": "1f3f4-200d-2620-fe0f" + }, + ":pisces:": { + "category": "symbols", + "name": "Pisces", + "unicode": "2653" + }, + ":pizza:": { + "category": "food", + "name": "pizza", + "unicode": "1f355" + }, + ":pi\u00f1ata:": { + "category": "objects", + "name": "pi\u00f1ata", + "unicode": "1fa85" + }, + ":placard:": { + "category": "objects", + "name": "placard", + "unicode": "1faa7" + }, + ":place_of_worship:": { + "category": "symbols", + "name": "place of worship", + "unicode": "1f6d0" + }, + ":play_pause:": { + "category": "symbols", + "name": "play or pause button", + "unicode": "23ef" + }, + ":playground_slide:": { + "category": "activity", + "name": "playground slide", + "unicode": "1f6dd" + }, + ":pleading_face:": { + "category": "people", + "name": "pleading face", + "unicode": "1f97a" + }, + ":plunger:": { + "category": "objects", + "name": "plunger", + "unicode": "1faa0" + }, + ":point_down:": { + "category": "people", + "name": "backhand index pointing down", + "unicode": "1f447" + }, + ":point_down_tone1:": { + "category": "people", + "name": "backhand index pointing down: light skin tone", + "unicode": "1f447-1f3fb" + }, + ":point_down_tone2:": { + "category": "people", + "name": "backhand index pointing down: medium-light skin tone", + "unicode": "1f447-1f3fc" + }, + ":point_down_tone3:": { + "category": "people", + "name": "backhand index pointing down: medium skin tone", + "unicode": "1f447-1f3fd" + }, + ":point_down_tone4:": { + "category": "people", + "name": "backhand index pointing down: medium-dark skin tone", + "unicode": "1f447-1f3fe" + }, + ":point_down_tone5:": { + "category": "people", + "name": "backhand index pointing down: dark skin tone", + "unicode": "1f447-1f3ff" + }, + ":point_left:": { + "category": "people", + "name": "backhand index pointing left", + "unicode": "1f448" + }, + ":point_left_tone1:": { + "category": "people", + "name": "backhand index pointing left: light skin tone", + "unicode": "1f448-1f3fb" + }, + ":point_left_tone2:": { + "category": "people", + "name": "backhand index pointing left: medium-light skin tone", + "unicode": "1f448-1f3fc" + }, + ":point_left_tone3:": { + "category": "people", + "name": "backhand index pointing left: medium skin tone", + "unicode": "1f448-1f3fd" + }, + ":point_left_tone4:": { + "category": "people", + "name": "backhand index pointing left: medium-dark skin tone", + "unicode": "1f448-1f3fe" + }, + ":point_left_tone5:": { + "category": "people", + "name": "backhand index pointing left: dark skin tone", + "unicode": "1f448-1f3ff" + }, + ":point_right:": { + "category": "people", + "name": "backhand index pointing right", + "unicode": "1f449" + }, + ":point_right_tone1:": { + "category": "people", + "name": "backhand index pointing right: light skin tone", + "unicode": "1f449-1f3fb" + }, + ":point_right_tone2:": { + "category": "people", + "name": "backhand index pointing right: medium-light skin tone", + "unicode": "1f449-1f3fc" + }, + ":point_right_tone3:": { + "category": "people", + "name": "backhand index pointing right: medium skin tone", + "unicode": "1f449-1f3fd" + }, + ":point_right_tone4:": { + "category": "people", + "name": "backhand index pointing right: medium-dark skin tone", + "unicode": "1f449-1f3fe" + }, + ":point_right_tone5:": { + "category": "people", + "name": "backhand index pointing right: dark skin tone", + "unicode": "1f449-1f3ff" + }, + ":point_up:": { + "category": "people", + "name": "index pointing up", + "unicode": "261d" + }, + ":point_up_2:": { + "category": "people", + "name": "backhand index pointing up", + "unicode": "1f446" + }, + ":point_up_2_tone1:": { + "category": "people", + "name": "backhand index pointing up: light skin tone", + "unicode": "1f446-1f3fb" + }, + ":point_up_2_tone2:": { + "category": "people", + "name": "backhand index pointing up: medium-light skin tone", + "unicode": "1f446-1f3fc" + }, + ":point_up_2_tone3:": { + "category": "people", + "name": "backhand index pointing up: medium skin tone", + "unicode": "1f446-1f3fd" + }, + ":point_up_2_tone4:": { + "category": "people", + "name": "backhand index pointing up: medium-dark skin tone", + "unicode": "1f446-1f3fe" + }, + ":point_up_2_tone5:": { + "category": "people", + "name": "backhand index pointing up: dark skin tone", + "unicode": "1f446-1f3ff" + }, + ":point_up_tone1:": { + "category": "people", + "name": "index pointing up: light skin tone", + "unicode": "261d-1f3fb" + }, + ":point_up_tone2:": { + "category": "people", + "name": "index pointing up: medium-light skin tone", + "unicode": "261d-1f3fc" + }, + ":point_up_tone3:": { + "category": "people", + "name": "index pointing up: medium skin tone", + "unicode": "261d-1f3fd" + }, + ":point_up_tone4:": { + "category": "people", + "name": "index pointing up: medium-dark skin tone", + "unicode": "261d-1f3fe" + }, + ":point_up_tone5:": { + "category": "people", + "name": "index pointing up: dark skin tone", + "unicode": "261d-1f3ff" + }, + ":polar_bear:": { + "category": "nature", + "name": "polar bear", + "unicode": "1f43b-200d-2744-fe0f" + }, + ":police_car:": { + "category": "travel", + "name": "police car", + "unicode": "1f693" + }, + ":police_officer:": { + "category": "people", + "name": "police officer", + "unicode": "1f46e" + }, + ":police_officer_tone1:": { + "category": "people", + "name": "police officer: light skin tone", + "unicode": "1f46e-1f3fb" + }, + ":police_officer_tone2:": { + "category": "people", + "name": "police officer: medium-light skin tone", + "unicode": "1f46e-1f3fc" + }, + ":police_officer_tone3:": { + "category": "people", + "name": "police officer: medium skin tone", + "unicode": "1f46e-1f3fd" + }, + ":police_officer_tone4:": { + "category": "people", + "name": "police officer: medium-dark skin tone", + "unicode": "1f46e-1f3fe" + }, + ":police_officer_tone5:": { + "category": "people", + "name": "police officer: dark skin tone", + "unicode": "1f46e-1f3ff" + }, + ":poodle:": { + "category": "nature", + "name": "poodle", + "unicode": "1f429" + }, + ":poop:": { + "category": "people", + "name": "pile of poo", + "unicode": "1f4a9" + }, + ":popcorn:": { + "category": "food", + "name": "popcorn", + "unicode": "1f37f" + }, + ":post_office:": { + "category": "travel", + "name": "Japanese post office", + "unicode": "1f3e3" + }, + ":postal_horn:": { + "category": "objects", + "name": "postal horn", + "unicode": "1f4ef" + }, + ":postbox:": { + "category": "objects", + "name": "postbox", + "unicode": "1f4ee" + }, + ":potable_water:": { + "category": "objects", + "name": "potable water", + "unicode": "1f6b0" + }, + ":potato:": { + "category": "food", + "name": "potato", + "unicode": "1f954" + }, + ":potted_plant:": { + "category": "nature", + "name": "potted plant", + "unicode": "1fab4" + }, + ":pouch:": { + "category": "people", + "name": "clutch bag", + "unicode": "1f45d" + }, + ":poultry_leg:": { + "category": "food", + "name": "poultry leg", + "unicode": "1f357" + }, + ":pound:": { + "category": "objects", + "name": "pound banknote", + "unicode": "1f4b7" + }, + ":pouring_liquid:": { + "category": "food", + "name": "pouring liquid", + "unicode": "1fad7" + }, + ":pouting_cat:": { + "category": "people", + "name": "pouting cat", + "unicode": "1f63e" + }, + ":pray:": { + "category": "people", + "name": "folded hands", + "unicode": "1f64f" + }, + ":pray_tone1:": { + "category": "people", + "name": "folded hands: light skin tone", + "unicode": "1f64f-1f3fb" + }, + ":pray_tone2:": { + "category": "people", + "name": "folded hands: medium-light skin tone", + "unicode": "1f64f-1f3fc" + }, + ":pray_tone3:": { + "category": "people", + "name": "folded hands: medium skin tone", + "unicode": "1f64f-1f3fd" + }, + ":pray_tone4:": { + "category": "people", + "name": "folded hands: medium-dark skin tone", + "unicode": "1f64f-1f3fe" + }, + ":pray_tone5:": { + "category": "people", + "name": "folded hands: dark skin tone", + "unicode": "1f64f-1f3ff" + }, + ":prayer_beads:": { + "category": "objects", + "name": "prayer beads", + "unicode": "1f4ff" + }, + ":pregnant_man:": { + "category": "people", + "name": "pregnant man", + "unicode": "1fac3" + }, + ":pregnant_man_tone1:": { + "category": "people", + "name": "pregnant man: light skin tone", + "unicode": "1fac3-1f3fb" + }, + ":pregnant_man_tone2:": { + "category": "people", + "name": "pregnant man: medium-light skin tone", + "unicode": "1fac3-1f3fc" + }, + ":pregnant_man_tone3:": { + "category": "people", + "name": "pregnant man: medium skin tone", + "unicode": "1fac3-1f3fd" + }, + ":pregnant_man_tone4:": { + "category": "people", + "name": "pregnant man: medium-dark skin tone", + "unicode": "1fac3-1f3fe" + }, + ":pregnant_man_tone5:": { + "category": "people", + "name": "pregnant man: dark skin tone", + "unicode": "1fac3-1f3ff" + }, + ":pregnant_person:": { + "category": "people", + "name": "pregnant person", + "unicode": "1fac4" + }, + ":pregnant_person_tone1:": { + "category": "people", + "name": "pregnant person: light skin tone", + "unicode": "1fac4-1f3fb" + }, + ":pregnant_person_tone2:": { + "category": "people", + "name": "pregnant person: medium-light skin tone", + "unicode": "1fac4-1f3fc" + }, + ":pregnant_person_tone3:": { + "category": "people", + "name": "pregnant person: medium skin tone", + "unicode": "1fac4-1f3fd" + }, + ":pregnant_person_tone4:": { + "category": "people", + "name": "pregnant person: medium-dark skin tone", + "unicode": "1fac4-1f3fe" + }, + ":pregnant_person_tone5:": { + "category": "people", + "name": "pregnant person: dark skin tone", + "unicode": "1fac4-1f3ff" + }, + ":pregnant_woman:": { + "category": "people", + "name": "pregnant woman", + "unicode": "1f930" + }, + ":pregnant_woman_tone1:": { + "category": "people", + "name": "pregnant woman: light skin tone", + "unicode": "1f930-1f3fb" + }, + ":pregnant_woman_tone2:": { + "category": "people", + "name": "pregnant woman: medium-light skin tone", + "unicode": "1f930-1f3fc" + }, + ":pregnant_woman_tone3:": { + "category": "people", + "name": "pregnant woman: medium skin tone", + "unicode": "1f930-1f3fd" + }, + ":pregnant_woman_tone4:": { + "category": "people", + "name": "pregnant woman: medium-dark skin tone", + "unicode": "1f930-1f3fe" + }, + ":pregnant_woman_tone5:": { + "category": "people", + "name": "pregnant woman: dark skin tone", + "unicode": "1f930-1f3ff" + }, + ":pretzel:": { + "category": "food", + "name": "pretzel", + "unicode": "1f968" + }, + ":prince:": { + "category": "people", + "name": "prince", + "unicode": "1f934" + }, + ":prince_tone1:": { + "category": "people", + "name": "prince: light skin tone", + "unicode": "1f934-1f3fb" + }, + ":prince_tone2:": { + "category": "people", + "name": "prince: medium-light skin tone", + "unicode": "1f934-1f3fc" + }, + ":prince_tone3:": { + "category": "people", + "name": "prince: medium skin tone", + "unicode": "1f934-1f3fd" + }, + ":prince_tone4:": { + "category": "people", + "name": "prince: medium-dark skin tone", + "unicode": "1f934-1f3fe" + }, + ":prince_tone5:": { + "category": "people", + "name": "prince: dark skin tone", + "unicode": "1f934-1f3ff" + }, + ":princess:": { + "category": "people", + "name": "princess", + "unicode": "1f478" + }, + ":princess_tone1:": { + "category": "people", + "name": "princess: light skin tone", + "unicode": "1f478-1f3fb" + }, + ":princess_tone2:": { + "category": "people", + "name": "princess: medium-light skin tone", + "unicode": "1f478-1f3fc" + }, + ":princess_tone3:": { + "category": "people", + "name": "princess: medium skin tone", + "unicode": "1f478-1f3fd" + }, + ":princess_tone4:": { + "category": "people", + "name": "princess: medium-dark skin tone", + "unicode": "1f478-1f3fe" + }, + ":princess_tone5:": { + "category": "people", + "name": "princess: dark skin tone", + "unicode": "1f478-1f3ff" + }, + ":printer:": { + "category": "objects", + "name": "printer", + "unicode": "1f5a8" + }, + ":probing_cane:": { + "category": "travel", + "name": "probing cane", + "unicode": "1f9af" + }, + ":projector:": { + "category": "objects", + "name": "film projector", + "unicode": "1f4fd" + }, + ":punch:": { + "category": "people", + "name": "oncoming fist", + "unicode": "1f44a" + }, + ":punch_tone1:": { + "category": "people", + "name": "oncoming fist: light skin tone", + "unicode": "1f44a-1f3fb" + }, + ":punch_tone2:": { + "category": "people", + "name": "oncoming fist: medium-light skin tone", + "unicode": "1f44a-1f3fc" + }, + ":punch_tone3:": { + "category": "people", + "name": "oncoming fist: medium skin tone", + "unicode": "1f44a-1f3fd" + }, + ":punch_tone4:": { + "category": "people", + "name": "oncoming fist: medium-dark skin tone", + "unicode": "1f44a-1f3fe" + }, + ":punch_tone5:": { + "category": "people", + "name": "oncoming fist: dark skin tone", + "unicode": "1f44a-1f3ff" + }, + ":purple_circle:": { + "category": "symbols", + "name": "purple circle", + "unicode": "1f7e3" + }, + ":purple_heart:": { + "category": "symbols", + "name": "purple heart", + "unicode": "1f49c" + }, + ":purple_square:": { + "category": "symbols", + "name": "purple square", + "unicode": "1f7ea" + }, + ":purse:": { + "category": "people", + "name": "purse", + "unicode": "1f45b" + }, + ":pushpin:": { + "category": "objects", + "name": "pushpin", + "unicode": "1f4cc" + }, + ":put_litter_in_its_place:": { + "category": "symbols", + "name": "litter in bin sign", + "unicode": "1f6ae" + }, + ":question:": { + "category": "symbols", + "name": "question mark", + "unicode": "2753" + }, + ":rabbit2:": { + "category": "nature", + "name": "rabbit", + "unicode": "1f407" + }, + ":rabbit:": { + "category": "nature", + "name": "rabbit face", + "unicode": "1f430" + }, + ":raccoon:": { + "category": "nature", + "name": "raccoon", + "unicode": "1f99d" + }, + ":race_car:": { + "category": "travel", + "name": "racing car", + "unicode": "1f3ce" + }, + ":racehorse:": { + "category": "nature", + "name": "horse", + "unicode": "1f40e" + }, + ":radio:": { + "category": "objects", + "name": "radio", + "unicode": "1f4fb" + }, + ":radio_button:": { + "category": "symbols", + "name": "radio button", + "unicode": "1f518" + }, + ":radioactive:": { + "category": "symbols", + "name": "radioactive", + "unicode": "2622" + }, + ":rage:": { + "category": "people", + "name": "pouting face", + "unicode": "1f621" + }, + ":railway_car:": { + "category": "travel", + "name": "railway car", + "unicode": "1f683" + }, + ":railway_track:": { + "category": "travel", + "name": "railway track", + "unicode": "1f6e4" + }, + ":rainbow:": { + "category": "nature", + "name": "rainbow", + "unicode": "1f308" + }, + ":rainbow_flag:": { + "category": "flags", + "name": "rainbow flag", + "unicode": "1f3f3-fe0f-200d-1f308" + }, + ":raised_back_of_hand:": { + "category": "people", + "name": "raised back of hand", + "unicode": "1f91a" + }, + ":raised_back_of_hand_tone1:": { + "category": "people", + "name": "raised back of hand: light skin tone", + "unicode": "1f91a-1f3fb" + }, + ":raised_back_of_hand_tone2:": { + "category": "people", + "name": "raised back of hand: medium-light skin tone", + "unicode": "1f91a-1f3fc" + }, + ":raised_back_of_hand_tone3:": { + "category": "people", + "name": "raised back of hand: medium skin tone", + "unicode": "1f91a-1f3fd" + }, + ":raised_back_of_hand_tone4:": { + "category": "people", + "name": "raised back of hand: medium-dark skin tone", + "unicode": "1f91a-1f3fe" + }, + ":raised_back_of_hand_tone5:": { + "category": "people", + "name": "raised back of hand: dark skin tone", + "unicode": "1f91a-1f3ff" + }, + ":raised_hand:": { + "category": "people", + "name": "raised hand", + "unicode": "270b" + }, + ":raised_hand_tone1:": { + "category": "people", + "name": "raised hand: light skin tone", + "unicode": "270b-1f3fb" + }, + ":raised_hand_tone2:": { + "category": "people", + "name": "raised hand: medium-light skin tone", + "unicode": "270b-1f3fc" + }, + ":raised_hand_tone3:": { + "category": "people", + "name": "raised hand: medium skin tone", + "unicode": "270b-1f3fd" + }, + ":raised_hand_tone4:": { + "category": "people", + "name": "raised hand: medium-dark skin tone", + "unicode": "270b-1f3fe" + }, + ":raised_hand_tone5:": { + "category": "people", + "name": "raised hand: dark skin tone", + "unicode": "270b-1f3ff" + }, + ":raised_hands:": { + "category": "people", + "name": "raising hands", + "unicode": "1f64c" + }, + ":raised_hands_tone1:": { + "category": "people", + "name": "raising hands: light skin tone", + "unicode": "1f64c-1f3fb" + }, + ":raised_hands_tone2:": { + "category": "people", + "name": "raising hands: medium-light skin tone", + "unicode": "1f64c-1f3fc" + }, + ":raised_hands_tone3:": { + "category": "people", + "name": "raising hands: medium skin tone", + "unicode": "1f64c-1f3fd" + }, + ":raised_hands_tone4:": { + "category": "people", + "name": "raising hands: medium-dark skin tone", + "unicode": "1f64c-1f3fe" + }, + ":raised_hands_tone5:": { + "category": "people", + "name": "raising hands: dark skin tone", + "unicode": "1f64c-1f3ff" + }, + ":ram:": { + "category": "nature", + "name": "ram", + "unicode": "1f40f" + }, + ":ramen:": { + "category": "food", + "name": "steaming bowl", + "unicode": "1f35c" + }, + ":rat:": { + "category": "nature", + "name": "rat", + "unicode": "1f400" + }, + ":razor:": { + "category": "objects", + "name": "razor", + "unicode": "1fa92" + }, + ":receipt:": { + "category": "objects", + "name": "receipt", + "unicode": "1f9fe" + }, + ":record_button:": { + "category": "symbols", + "name": "record button", + "unicode": "23fa" + }, + ":recycle:": { + "category": "symbols", + "name": "recycling symbol", + "unicode": "267b" + }, + ":red_car:": { + "category": "travel", + "name": "automobile", + "unicode": "1f697" + }, + ":red_circle:": { + "category": "symbols", + "name": "red circle", + "unicode": "1f534" + }, + ":red_envelope:": { + "category": "objects", + "name": "red envelope", + "unicode": "1f9e7" + }, + ":red_haired:": { + "category": "people", + "name": "red hair", + "unicode": "1f9b0" + }, + ":red_square:": { + "category": "symbols", + "name": "red square", + "unicode": "1f7e5" + }, + ":regional_indicator_a:": { + "category": "regional", + "name": "regional indicator symbol letter a", + "unicode": "1f1e6" + }, + ":regional_indicator_b:": { + "category": "regional", + "name": "regional indicator symbol letter b", + "unicode": "1f1e7" + }, + ":regional_indicator_c:": { + "category": "regional", + "name": "regional indicator symbol letter c", + "unicode": "1f1e8" + }, + ":regional_indicator_d:": { + "category": "regional", + "name": "regional indicator symbol letter d", + "unicode": "1f1e9" + }, + ":regional_indicator_e:": { + "category": "regional", + "name": "regional indicator symbol letter e", + "unicode": "1f1ea" + }, + ":regional_indicator_f:": { + "category": "regional", + "name": "regional indicator symbol letter f", + "unicode": "1f1eb" + }, + ":regional_indicator_g:": { + "category": "regional", + "name": "regional indicator symbol letter g", + "unicode": "1f1ec" + }, + ":regional_indicator_h:": { + "category": "regional", + "name": "regional indicator symbol letter h", + "unicode": "1f1ed" + }, + ":regional_indicator_i:": { + "category": "regional", + "name": "regional indicator symbol letter i", + "unicode": "1f1ee" + }, + ":regional_indicator_j:": { + "category": "regional", + "name": "regional indicator symbol letter j", + "unicode": "1f1ef" + }, + ":regional_indicator_k:": { + "category": "regional", + "name": "regional indicator symbol letter k", + "unicode": "1f1f0" + }, + ":regional_indicator_l:": { + "category": "regional", + "name": "regional indicator symbol letter l", + "unicode": "1f1f1" + }, + ":regional_indicator_m:": { + "category": "regional", + "name": "regional indicator symbol letter m", + "unicode": "1f1f2" + }, + ":regional_indicator_n:": { + "category": "regional", + "name": "regional indicator symbol letter n", + "unicode": "1f1f3" + }, + ":regional_indicator_o:": { + "category": "regional", + "name": "regional indicator symbol letter o", + "unicode": "1f1f4" + }, + ":regional_indicator_p:": { + "category": "regional", + "name": "regional indicator symbol letter p", + "unicode": "1f1f5" + }, + ":regional_indicator_q:": { + "category": "regional", + "name": "regional indicator symbol letter q", + "unicode": "1f1f6" + }, + ":regional_indicator_r:": { + "category": "regional", + "name": "regional indicator symbol letter r", + "unicode": "1f1f7" + }, + ":regional_indicator_s:": { + "category": "regional", + "name": "regional indicator symbol letter s", + "unicode": "1f1f8" + }, + ":regional_indicator_t:": { + "category": "regional", + "name": "regional indicator symbol letter t", + "unicode": "1f1f9" + }, + ":regional_indicator_u:": { + "category": "regional", + "name": "regional indicator symbol letter u", + "unicode": "1f1fa" + }, + ":regional_indicator_v:": { + "category": "regional", + "name": "regional indicator symbol letter v", + "unicode": "1f1fb" + }, + ":regional_indicator_w:": { + "category": "regional", + "name": "regional indicator symbol letter w", + "unicode": "1f1fc" + }, + ":regional_indicator_x:": { + "category": "regional", + "name": "regional indicator symbol letter x", + "unicode": "1f1fd" + }, + ":regional_indicator_y:": { + "category": "regional", + "name": "regional indicator symbol letter y", + "unicode": "1f1fe" + }, + ":regional_indicator_z:": { + "category": "regional", + "name": "regional indicator symbol letter z", + "unicode": "1f1ff" + }, + ":registered:": { + "category": "symbols", + "name": "registered", + "unicode": "ae", + "unicode_alt": "00ae" + }, + ":relaxed:": { + "category": "people", + "name": "smiling face", + "unicode": "263a" + }, + ":relieved:": { + "category": "people", + "name": "relieved face", + "unicode": "1f60c" + }, + ":reminder_ribbon:": { + "category": "activity", + "name": "reminder ribbon", + "unicode": "1f397" + }, + ":repeat:": { + "category": "symbols", + "name": "repeat button", + "unicode": "1f501" + }, + ":repeat_one:": { + "category": "symbols", + "name": "repeat single button", + "unicode": "1f502" + }, + ":restroom:": { + "category": "symbols", + "name": "restroom", + "unicode": "1f6bb" + }, + ":revolving_hearts:": { + "category": "symbols", + "name": "revolving hearts", + "unicode": "1f49e" + }, + ":rewind:": { + "category": "symbols", + "name": "fast reverse button", + "unicode": "23ea" + }, + ":rhino:": { + "category": "nature", + "name": "rhinoceros", + "unicode": "1f98f" + }, + ":ribbon:": { + "category": "objects", + "name": "ribbon", + "unicode": "1f380" + }, + ":rice:": { + "category": "food", + "name": "cooked rice", + "unicode": "1f35a" + }, + ":rice_ball:": { + "category": "food", + "name": "rice ball", + "unicode": "1f359" + }, + ":rice_cracker:": { + "category": "food", + "name": "rice cracker", + "unicode": "1f358" + }, + ":rice_scene:": { + "category": "travel", + "name": "moon viewing ceremony", + "unicode": "1f391" + }, + ":right_facing_fist:": { + "category": "people", + "name": "right-facing fist", + "unicode": "1f91c" + }, + ":right_facing_fist_tone1:": { + "category": "people", + "name": "right-facing fist: light skin tone", + "unicode": "1f91c-1f3fb" + }, + ":right_facing_fist_tone2:": { + "category": "people", + "name": "right-facing fist: medium-light skin tone", + "unicode": "1f91c-1f3fc" + }, + ":right_facing_fist_tone3:": { + "category": "people", + "name": "right-facing fist: medium skin tone", + "unicode": "1f91c-1f3fd" + }, + ":right_facing_fist_tone4:": { + "category": "people", + "name": "right-facing fist: medium-dark skin tone", + "unicode": "1f91c-1f3fe" + }, + ":right_facing_fist_tone5:": { + "category": "people", + "name": "right-facing fist: dark skin tone", + "unicode": "1f91c-1f3ff" + }, + ":rightwards_hand:": { + "category": "people", + "name": "rightwards hand", + "unicode": "1faf1" + }, + ":rightwards_hand_tone1:": { + "category": "people", + "name": "rightwards hand: light skin tone", + "unicode": "1faf1-1f3fb" + }, + ":rightwards_hand_tone2:": { + "category": "people", + "name": "rightwards hand: medium-light skin tone", + "unicode": "1faf1-1f3fc" + }, + ":rightwards_hand_tone3:": { + "category": "people", + "name": "rightwards hand: medium skin tone", + "unicode": "1faf1-1f3fd" + }, + ":rightwards_hand_tone4:": { + "category": "people", + "name": "rightwards hand: medium-dark skin tone", + "unicode": "1faf1-1f3fe" + }, + ":rightwards_hand_tone5:": { + "category": "people", + "name": "rightwards hand: dark skin tone", + "unicode": "1faf1-1f3ff" + }, + ":rightwards_pushing_hand:": { + "category": "people", + "name": "rightwards pushing hand", + "unicode": "1faf8" + }, + ":rightwards_pushing_hand_tone1:": { + "category": "people", + "name": "rightwards pushing hand: light skin tone", + "unicode": "1faf8-1f3fb" + }, + ":rightwards_pushing_hand_tone2:": { + "category": "people", + "name": "rightwards pushing hand: medium-light skin tone", + "unicode": "1faf8-1f3fc" + }, + ":rightwards_pushing_hand_tone3:": { + "category": "people", + "name": "rightwards pushing hand: medium skin tone", + "unicode": "1faf8-1f3fd" + }, + ":rightwards_pushing_hand_tone4:": { + "category": "people", + "name": "rightwards pushing hand: medium-dark skin tone", + "unicode": "1faf8-1f3fe" + }, + ":rightwards_pushing_hand_tone5:": { + "category": "people", + "name": "rightwards pushing hand: dark skin tone", + "unicode": "1faf8-1f3ff" + }, + ":ring:": { + "category": "people", + "name": "ring", + "unicode": "1f48d" + }, + ":ring_buoy:": { + "category": "travel", + "name": "ring buoy", + "unicode": "1f6df" + }, + ":ringed_planet:": { + "category": "nature", + "name": "ringed planet", + "unicode": "1fa90" + }, + ":robot:": { + "category": "people", + "name": "robot", + "unicode": "1f916" + }, + ":rock:": { + "category": "nature", + "name": "rock", + "unicode": "1faa8" + }, + ":rocket:": { + "category": "travel", + "name": "rocket", + "unicode": "1f680" + }, + ":rofl:": { + "category": "people", + "name": "rolling on the floor laughing", + "unicode": "1f923" + }, + ":roll_of_paper:": { + "category": "objects", + "name": "roll of paper", + "unicode": "1f9fb" + }, + ":roller_coaster:": { + "category": "travel", + "name": "roller coaster", + "unicode": "1f3a2" + }, + ":roller_skate:": { + "category": "activity", + "name": "roller skate", + "unicode": "1f6fc" + }, + ":rolling_eyes:": { + "category": "people", + "name": "face with rolling eyes", + "unicode": "1f644" + }, + ":rooster:": { + "category": "nature", + "name": "rooster", + "unicode": "1f413" + }, + ":root_vegetable:": { + "category": "food", + "name": "root vegetable", + "unicode": "1fadc" + }, + ":rose:": { + "category": "nature", + "name": "rose", + "unicode": "1f339" + }, + ":rosette:": { + "category": "activity", + "name": "rosette", + "unicode": "1f3f5" + }, + ":rotating_light:": { + "category": "travel", + "name": "police car light", + "unicode": "1f6a8" + }, + ":round_pushpin:": { + "category": "objects", + "name": "round pushpin", + "unicode": "1f4cd" + }, + ":rugby_football:": { + "category": "activity", + "name": "rugby football", + "unicode": "1f3c9" + }, + ":running_shirt_with_sash:": { + "category": "activity", + "name": "running shirt", + "unicode": "1f3bd" + }, + ":sa:": { + "category": "symbols", + "name": "Japanese \u201cservice charge\u201d button", + "unicode": "1f202" + }, + ":safety_pin:": { + "category": "objects", + "name": "safety pin", + "unicode": "1f9f7" + }, + ":safety_vest:": { + "category": "people", + "name": "safety vest", + "unicode": "1f9ba" + }, + ":sagittarius:": { + "category": "symbols", + "name": "Sagittarius", + "unicode": "2650" + }, + ":sailboat:": { + "category": "travel", + "name": "sailboat", + "unicode": "26f5" + }, + ":sake:": { + "category": "food", + "name": "sake", + "unicode": "1f376" + }, + ":salad:": { + "category": "food", + "name": "green salad", + "unicode": "1f957" + }, + ":salt:": { + "category": "food", + "name": "salt", + "unicode": "1f9c2" + }, + ":saluting_face:": { + "category": "people", + "name": "saluting face", + "unicode": "1fae1" + }, + ":sandal:": { + "category": "people", + "name": "woman\u2019s sandal", + "unicode": "1f461" + }, + ":sandwich:": { + "category": "food", + "name": "sandwich", + "unicode": "1f96a" + }, + ":santa:": { + "category": "people", + "name": "Santa Claus", + "unicode": "1f385" + }, + ":santa_tone1:": { + "category": "people", + "name": "Santa Claus: light skin tone", + "unicode": "1f385-1f3fb" + }, + ":santa_tone2:": { + "category": "people", + "name": "Santa Claus: medium-light skin tone", + "unicode": "1f385-1f3fc" + }, + ":santa_tone3:": { + "category": "people", + "name": "Santa Claus: medium skin tone", + "unicode": "1f385-1f3fd" + }, + ":santa_tone4:": { + "category": "people", + "name": "Santa Claus: medium-dark skin tone", + "unicode": "1f385-1f3fe" + }, + ":santa_tone5:": { + "category": "people", + "name": "Santa Claus: dark skin tone", + "unicode": "1f385-1f3ff" + }, + ":sari:": { + "category": "people", + "name": "sari", + "unicode": "1f97b" + }, + ":satellite:": { + "category": "objects", + "name": "satellite antenna", + "unicode": "1f4e1" + }, + ":satellite_orbital:": { + "category": "travel", + "name": "satellite", + "unicode": "1f6f0" + }, + ":sauropod:": { + "category": "nature", + "name": "sauropod", + "unicode": "1f995" + }, + ":saxophone:": { + "category": "activity", + "name": "saxophone", + "unicode": "1f3b7" + }, + ":scales:": { + "category": "objects", + "name": "balance scale", + "unicode": "2696" + }, + ":scarf:": { + "category": "people", + "name": "scarf", + "unicode": "1f9e3" + }, + ":school:": { + "category": "travel", + "name": "school", + "unicode": "1f3eb" + }, + ":school_satchel:": { + "category": "people", + "name": "backpack", + "unicode": "1f392" + }, + ":scientist:": { + "category": "people", + "name": "scientist", + "unicode": "1f9d1-200d-1f52c" + }, + ":scientist_tone1:": { + "category": "people", + "name": "scientist: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f52c" + }, + ":scientist_tone2:": { + "category": "people", + "name": "scientist: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f52c" + }, + ":scientist_tone3:": { + "category": "people", + "name": "scientist: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f52c" + }, + ":scientist_tone4:": { + "category": "people", + "name": "scientist: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f52c" + }, + ":scientist_tone5:": { + "category": "people", + "name": "scientist: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f52c" + }, + ":scissors:": { + "category": "objects", + "name": "scissors", + "unicode": "2702" + }, + ":scooter:": { + "category": "travel", + "name": "kick scooter", + "unicode": "1f6f4" + }, + ":scorpion:": { + "category": "nature", + "name": "scorpion", + "unicode": "1f982" + }, + ":scorpius:": { + "category": "symbols", + "name": "Scorpio", + "unicode": "264f" + }, + ":scotland:": { + "category": "flags", + "name": "flag: Scotland", + "unicode": "1f3f4-e0067-e0062-e0073-e0063-e0074-e007f" + }, + ":scream:": { + "category": "people", + "name": "face screaming in fear", + "unicode": "1f631" + }, + ":scream_cat:": { + "category": "people", + "name": "weary cat", + "unicode": "1f640" + }, + ":screwdriver:": { + "category": "objects", + "name": "screwdriver", + "unicode": "1fa9b" + }, + ":scroll:": { + "category": "objects", + "name": "scroll", + "unicode": "1f4dc" + }, + ":seal:": { + "category": "nature", + "name": "seal", + "unicode": "1f9ad" + }, + ":seat:": { + "category": "travel", + "name": "seat", + "unicode": "1f4ba" + }, + ":second_place:": { + "category": "activity", + "name": "2nd place medal", + "unicode": "1f948" + }, + ":secret:": { + "category": "symbols", + "name": "Japanese \u201csecret\u201d button", + "unicode": "3299" + }, + ":see_no_evil:": { + "category": "nature", + "name": "see-no-evil monkey", + "unicode": "1f648" + }, + ":seedling:": { + "category": "nature", + "name": "seedling", + "unicode": "1f331" + }, + ":selfie:": { + "category": "people", + "name": "selfie", + "unicode": "1f933" + }, + ":selfie_tone1:": { + "category": "people", + "name": "selfie: light skin tone", + "unicode": "1f933-1f3fb" + }, + ":selfie_tone2:": { + "category": "people", + "name": "selfie: medium-light skin tone", + "unicode": "1f933-1f3fc" + }, + ":selfie_tone3:": { + "category": "people", + "name": "selfie: medium skin tone", + "unicode": "1f933-1f3fd" + }, + ":selfie_tone4:": { + "category": "people", + "name": "selfie: medium-dark skin tone", + "unicode": "1f933-1f3fe" + }, + ":selfie_tone5:": { + "category": "people", + "name": "selfie: dark skin tone", + "unicode": "1f933-1f3ff" + }, + ":service_dog:": { + "category": "nature", + "name": "service dog", + "unicode": "1f415-200d-1f9ba" + }, + ":seven:": { + "category": "symbols", + "name": "keycap: 7", + "unicode": "37-20e3", + "unicode_alt": "0037-20e3" + }, + ":sewing_needle:": { + "category": "people", + "name": "sewing needle", + "unicode": "1faa1" + }, + ":shaking_face:": { + "category": "people", + "name": "shaking face", + "unicode": "1fae8" + }, + ":shallow_pan_of_food:": { + "category": "food", + "name": "shallow pan of food", + "unicode": "1f958" + }, + ":shamrock:": { + "category": "nature", + "name": "shamrock", + "unicode": "2618" + }, + ":shark:": { + "category": "nature", + "name": "shark", + "unicode": "1f988" + }, + ":shaved_ice:": { + "category": "food", + "name": "shaved ice", + "unicode": "1f367" + }, + ":sheep:": { + "category": "nature", + "name": "ewe", + "unicode": "1f411" + }, + ":shell:": { + "category": "nature", + "name": "spiral shell", + "unicode": "1f41a" + }, + ":shibuya:": { + "category": "travel", + "name": "Shibuya 109", + "unicode": "e50a" + }, + ":shield:": { + "category": "objects", + "name": "shield", + "unicode": "1f6e1" + }, + ":shinto_shrine:": { + "category": "travel", + "name": "shinto shrine", + "unicode": "26e9" + }, + ":ship:": { + "category": "travel", + "name": "ship", + "unicode": "1f6a2" + }, + ":shirt:": { + "category": "people", + "name": "t-shirt", + "unicode": "1f455" + }, + ":shopping_bags:": { + "category": "objects", + "name": "shopping bags", + "unicode": "1f6cd" + }, + ":shopping_cart:": { + "category": "objects", + "name": "shopping cart", + "unicode": "1f6d2" + }, + ":shorts:": { + "category": "people", + "name": "shorts", + "unicode": "1fa73" + }, + ":shovel:": { + "category": "objects", + "name": "shovel", + "unicode": "1fa8f" + }, + ":shower:": { + "category": "objects", + "name": "shower", + "unicode": "1f6bf" + }, + ":shrimp:": { + "category": "nature", + "name": "shrimp", + "unicode": "1f990" + }, + ":shushing_face:": { + "category": "people", + "name": "shushing face", + "unicode": "1f92b" + }, + ":signal_strength:": { + "category": "symbols", + "name": "antenna bars", + "unicode": "1f4f6" + }, + ":singer:": { + "category": "people", + "name": "singer", + "unicode": "1f9d1-200d-1f3a4" + }, + ":singer_tone1:": { + "category": "people", + "name": "singer: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f3a4" + }, + ":singer_tone2:": { + "category": "people", + "name": "singer: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f3a4" + }, + ":singer_tone3:": { + "category": "people", + "name": "singer: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f3a4" + }, + ":singer_tone4:": { + "category": "people", + "name": "singer: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f3a4" + }, + ":singer_tone5:": { + "category": "people", + "name": "singer: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f3a4" + }, + ":six:": { + "category": "symbols", + "name": "keycap: 6", + "unicode": "36-20e3", + "unicode_alt": "0036-20e3" + }, + ":six_pointed_star:": { + "category": "symbols", + "name": "dotted six-pointed star", + "unicode": "1f52f" + }, + ":skateboard:": { + "category": "activity", + "name": "skateboard", + "unicode": "1f6f9" + }, + ":ski:": { + "category": "activity", + "name": "skis", + "unicode": "1f3bf" + }, + ":skier:": { + "category": "activity", + "name": "skier", + "unicode": "26f7" + }, + ":skier_tone1:": { + "category": "activity", + "name": "skier: light skin tone", + "unicode": "26f7-1f3fb" + }, + ":skier_tone2:": { + "category": "activity", + "name": "skier: medium-light skin tone", + "unicode": "26f7-1f3fc" + }, + ":skier_tone3:": { + "category": "activity", + "name": "skier: medium skin tone", + "unicode": "26f7-1f3fd" + }, + ":skier_tone4:": { + "category": "activity", + "name": "skier: medium-dark skin tone", + "unicode": "26f7-1f3fe" + }, + ":skier_tone5:": { + "category": "activity", + "name": "skier: dark skin tone", + "unicode": "26f7-1f3ff" + }, + ":skull:": { + "category": "people", + "name": "skull", + "unicode": "1f480" + }, + ":skull_crossbones:": { + "category": "people", + "name": "skull and crossbones", + "unicode": "2620" + }, + ":skunk:": { + "category": "nature", + "name": "skunk", + "unicode": "1f9a8" + }, + ":sled:": { + "category": "activity", + "name": "sled", + "unicode": "1f6f7" + }, + ":sleeping:": { + "category": "people", + "name": "sleeping face", + "unicode": "1f634" + }, + ":sleeping_accommodation:": { + "category": "objects", + "name": "person in bed", + "unicode": "1f6cc" + }, + ":sleepy:": { + "category": "people", + "name": "sleepy face", + "unicode": "1f62a" + }, + ":slight_frown:": { + "category": "people", + "name": "slightly frowning face", + "unicode": "1f641" + }, + ":slight_smile:": { + "category": "people", + "name": "slightly smiling face", + "unicode": "1f642" + }, + ":slot_machine:": { + "category": "activity", + "name": "slot machine", + "unicode": "1f3b0" + }, + ":sloth:": { + "category": "nature", + "name": "sloth", + "unicode": "1f9a5" + }, + ":small_blue_diamond:": { + "category": "symbols", + "name": "small blue diamond", + "unicode": "1f539" + }, + ":small_orange_diamond:": { + "category": "symbols", + "name": "small orange diamond", + "unicode": "1f538" + }, + ":small_red_triangle:": { + "category": "symbols", + "name": "red triangle pointed up", + "unicode": "1f53a" + }, + ":small_red_triangle_down:": { + "category": "symbols", + "name": "red triangle pointed down", + "unicode": "1f53b" + }, + ":smile:": { + "category": "people", + "name": "grinning face with smiling eyes", + "unicode": "1f604" + }, + ":smile_cat:": { + "category": "people", + "name": "grinning cat with smiling eyes", + "unicode": "1f638" + }, + ":smiley:": { + "category": "people", + "name": "grinning face with big eyes", + "unicode": "1f603" + }, + ":smiley_cat:": { + "category": "people", + "name": "grinning cat", + "unicode": "1f63a" + }, + ":smiling_face_with_3_hearts:": { + "category": "people", + "name": "smiling face with hearts", + "unicode": "1f970" + }, + ":smiling_face_with_tear:": { + "category": "people", + "name": "smiling face with tear", + "unicode": "1f972" + }, + ":smiling_imp:": { + "category": "people", + "name": "smiling face with horns", + "unicode": "1f608" + }, + ":smirk:": { + "category": "people", + "name": "smirking face", + "unicode": "1f60f" + }, + ":smirk_cat:": { + "category": "people", + "name": "cat with wry smile", + "unicode": "1f63c" + }, + ":smoking:": { + "category": "objects", + "name": "cigarette", + "unicode": "1f6ac" + }, + ":snail:": { + "category": "nature", + "name": "snail", + "unicode": "1f40c" + }, + ":snake:": { + "category": "nature", + "name": "snake", + "unicode": "1f40d" + }, + ":sneezing_face:": { + "category": "people", + "name": "sneezing face", + "unicode": "1f927" + }, + ":snowboarder:": { + "category": "activity", + "name": "snowboarder", + "unicode": "1f3c2" + }, + ":snowboarder_tone1:": { + "category": "activity", + "name": "snowboarder: light skin tone", + "unicode": "1f3c2-1f3fb" + }, + ":snowboarder_tone2:": { + "category": "activity", + "name": "snowboarder: medium-light skin tone", + "unicode": "1f3c2-1f3fc" + }, + ":snowboarder_tone3:": { + "category": "activity", + "name": "snowboarder: medium skin tone", + "unicode": "1f3c2-1f3fd" + }, + ":snowboarder_tone4:": { + "category": "activity", + "name": "snowboarder: medium-dark skin tone", + "unicode": "1f3c2-1f3fe" + }, + ":snowboarder_tone5:": { + "category": "activity", + "name": "snowboarder: dark skin tone", + "unicode": "1f3c2-1f3ff" + }, + ":snowflake:": { + "category": "nature", + "name": "snowflake", + "unicode": "2744" + }, + ":snowman2:": { + "category": "nature", + "name": "snowman", + "unicode": "2603" + }, + ":snowman:": { + "category": "nature", + "name": "snowman without snow", + "unicode": "26c4" + }, + ":soap:": { + "category": "objects", + "name": "soap", + "unicode": "1f9fc" + }, + ":sob:": { + "category": "people", + "name": "loudly crying face", + "unicode": "1f62d" + }, + ":soccer:": { + "category": "activity", + "name": "soccer ball", + "unicode": "26bd" + }, + ":socks:": { + "category": "people", + "name": "socks", + "unicode": "1f9e6" + }, + ":softball:": { + "category": "activity", + "name": "softball", + "unicode": "1f94e" + }, + ":soon:": { + "category": "symbols", + "name": "SOON arrow", + "unicode": "1f51c" + }, + ":sos:": { + "category": "symbols", + "name": "SOS button", + "unicode": "1f198" + }, + ":sound:": { + "category": "symbols", + "name": "speaker medium volume", + "unicode": "1f509" + }, + ":space_invader:": { + "category": "people", + "name": "alien monster", + "unicode": "1f47e" + }, + ":spades:": { + "category": "symbols", + "name": "spade suit", + "unicode": "2660" + }, + ":spaghetti:": { + "category": "food", + "name": "spaghetti", + "unicode": "1f35d" + }, + ":sparkle:": { + "category": "symbols", + "name": "sparkle", + "unicode": "2747" + }, + ":sparkler:": { + "category": "travel", + "name": "sparkler", + "unicode": "1f387" + }, + ":sparkles:": { + "category": "nature", + "name": "sparkles", + "unicode": "2728" + }, + ":sparkling_heart:": { + "category": "symbols", + "name": "sparkling heart", + "unicode": "1f496" + }, + ":speak_no_evil:": { + "category": "nature", + "name": "speak-no-evil monkey", + "unicode": "1f64a" + }, + ":speaker:": { + "category": "symbols", + "name": "speaker low volume", + "unicode": "1f508" + }, + ":speaking_head:": { + "category": "people", + "name": "speaking head", + "unicode": "1f5e3" + }, + ":speech_balloon:": { + "category": "symbols", + "name": "speech balloon", + "unicode": "1f4ac" + }, + ":speech_left:": { + "category": "symbols", + "name": "left speech bubble", + "unicode": "1f5e8" + }, + ":speedboat:": { + "category": "travel", + "name": "speedboat", + "unicode": "1f6a4" + }, + ":spider:": { + "category": "nature", + "name": "spider", + "unicode": "1f577" + }, + ":spider_web:": { + "category": "nature", + "name": "spider web", + "unicode": "1f578" + }, + ":splatter:": { + "category": "activity", + "name": "splatter", + "unicode": "1fadf" + }, + ":sponge:": { + "category": "objects", + "name": "sponge", + "unicode": "1f9fd" + }, + ":spoon:": { + "category": "food", + "name": "spoon", + "unicode": "1f944" + }, + ":squeeze_bottle:": { + "category": "objects", + "name": "lotion bottle", + "unicode": "1f9f4" + }, + ":squid:": { + "category": "nature", + "name": "squid", + "unicode": "1f991" + }, + ":stadium:": { + "category": "travel", + "name": "stadium", + "unicode": "1f3df" + }, + ":star2:": { + "category": "nature", + "name": "glowing star", + "unicode": "1f31f" + }, + ":star:": { + "category": "nature", + "name": "star", + "unicode": "2b50" + }, + ":star_and_crescent:": { + "category": "symbols", + "name": "star and crescent", + "unicode": "262a" + }, + ":star_of_david:": { + "category": "symbols", + "name": "star of David", + "unicode": "2721" + }, + ":star_struck:": { + "category": "people", + "name": "star-struck", + "unicode": "1f929" + }, + ":stars:": { + "category": "travel", + "name": "shooting star", + "unicode": "1f320" + }, + ":station:": { + "category": "travel", + "name": "station", + "unicode": "1f689" + }, + ":statue_of_liberty:": { + "category": "travel", + "name": "Statue of Liberty", + "unicode": "1f5fd" + }, + ":steam_locomotive:": { + "category": "travel", + "name": "locomotive", + "unicode": "1f682" + }, + ":stethoscope:": { + "category": "objects", + "name": "stethoscope", + "unicode": "1fa7a" + }, + ":stew:": { + "category": "food", + "name": "pot of food", + "unicode": "1f372" + }, + ":stop_button:": { + "category": "symbols", + "name": "stop button", + "unicode": "23f9" + }, + ":stopwatch:": { + "category": "objects", + "name": "stopwatch", + "unicode": "23f1" + }, + ":straight_ruler:": { + "category": "objects", + "name": "straight ruler", + "unicode": "1f4cf" + }, + ":strawberry:": { + "category": "food", + "name": "strawberry", + "unicode": "1f353" + }, + ":stuck_out_tongue:": { + "category": "people", + "name": "face with tongue", + "unicode": "1f61b" + }, + ":stuck_out_tongue_closed_eyes:": { + "category": "people", + "name": "squinting face with tongue", + "unicode": "1f61d" + }, + ":stuck_out_tongue_winking_eye:": { + "category": "people", + "name": "winking face with tongue", + "unicode": "1f61c" + }, + ":student:": { + "category": "people", + "name": "student", + "unicode": "1f9d1-200d-1f393" + }, + ":student_tone1:": { + "category": "people", + "name": "student: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f393" + }, + ":student_tone2:": { + "category": "people", + "name": "student: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f393" + }, + ":student_tone3:": { + "category": "people", + "name": "student: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f393" + }, + ":student_tone4:": { + "category": "people", + "name": "student: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f393" + }, + ":student_tone5:": { + "category": "people", + "name": "student: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f393" + }, + ":stuffed_flatbread:": { + "category": "food", + "name": "stuffed flatbread", + "unicode": "1f959" + }, + ":sun_with_face:": { + "category": "nature", + "name": "sun with face", + "unicode": "1f31e" + }, + ":sunflower:": { + "category": "nature", + "name": "sunflower", + "unicode": "1f33b" + }, + ":sunglasses:": { + "category": "people", + "name": "smiling face with sunglasses", + "unicode": "1f60e" + }, + ":sunny:": { + "category": "nature", + "name": "sun", + "unicode": "2600" + }, + ":sunrise:": { + "category": "travel", + "name": "sunrise", + "unicode": "1f305" + }, + ":sunrise_over_mountains:": { + "category": "travel", + "name": "sunrise over mountains", + "unicode": "1f304" + }, + ":superhero:": { + "category": "people", + "name": "superhero", + "unicode": "1f9b8" + }, + ":superhero_tone1:": { + "category": "people", + "name": "superhero: light skin tone", + "unicode": "1f9b8-1f3fb" + }, + ":superhero_tone2:": { + "category": "people", + "name": "superhero: medium-light skin tone", + "unicode": "1f9b8-1f3fc" + }, + ":superhero_tone3:": { + "category": "people", + "name": "superhero: medium skin tone", + "unicode": "1f9b8-1f3fd" + }, + ":superhero_tone4:": { + "category": "people", + "name": "superhero: medium-dark skin tone", + "unicode": "1f9b8-1f3fe" + }, + ":superhero_tone5:": { + "category": "people", + "name": "superhero: dark skin tone", + "unicode": "1f9b8-1f3ff" + }, + ":supervillain:": { + "category": "people", + "name": "supervillain", + "unicode": "1f9b9" + }, + ":supervillain_tone1:": { + "category": "people", + "name": "supervillain: light skin tone", + "unicode": "1f9b9-1f3fb" + }, + ":supervillain_tone2:": { + "category": "people", + "name": "supervillain: medium-light skin tone", + "unicode": "1f9b9-1f3fc" + }, + ":supervillain_tone3:": { + "category": "people", + "name": "supervillain: medium skin tone", + "unicode": "1f9b9-1f3fd" + }, + ":supervillain_tone4:": { + "category": "people", + "name": "supervillain: medium-dark skin tone", + "unicode": "1f9b9-1f3fe" + }, + ":supervillain_tone5:": { + "category": "people", + "name": "supervillain: dark skin tone", + "unicode": "1f9b9-1f3ff" + }, + ":sushi:": { + "category": "food", + "name": "sushi", + "unicode": "1f363" + }, + ":suspension_railway:": { + "category": "travel", + "name": "suspension railway", + "unicode": "1f69f" + }, + ":swan:": { + "category": "nature", + "name": "swan", + "unicode": "1f9a2" + }, + ":sweat:": { + "category": "people", + "name": "downcast face with sweat", + "unicode": "1f613" + }, + ":sweat_drops:": { + "category": "nature", + "name": "sweat droplets", + "unicode": "1f4a6" + }, + ":sweat_smile:": { + "category": "people", + "name": "grinning face with sweat", + "unicode": "1f605" + }, + ":sweet_potato:": { + "category": "food", + "name": "roasted sweet potato", + "unicode": "1f360" + }, + ":symbols:": { + "category": "symbols", + "name": "input symbols", + "unicode": "1f523" + }, + ":synagogue:": { + "category": "travel", + "name": "synagogue", + "unicode": "1f54d" + }, + ":syringe:": { + "category": "objects", + "name": "syringe", + "unicode": "1f489" + }, + ":t_rex:": { + "category": "nature", + "name": "T-Rex", + "unicode": "1f996" + }, + ":taco:": { + "category": "food", + "name": "taco", + "unicode": "1f32e" + }, + ":tada:": { + "category": "objects", + "name": "party popper", + "unicode": "1f389" + }, + ":takeout_box:": { + "category": "food", + "name": "takeout box", + "unicode": "1f961" + }, + ":tamale:": { + "category": "food", + "name": "tamale", + "unicode": "1fad4" + }, + ":tanabata_tree:": { + "category": "nature", + "name": "tanabata tree", + "unicode": "1f38b" + }, + ":tangerine:": { + "category": "food", + "name": "tangerine", + "unicode": "1f34a" + }, + ":taurus:": { + "category": "symbols", + "name": "Taurus", + "unicode": "2649" + }, + ":taxi:": { + "category": "travel", + "name": "taxi", + "unicode": "1f695" + }, + ":tea:": { + "category": "food", + "name": "teacup without handle", + "unicode": "1f375" + }, + ":teacher:": { + "category": "people", + "name": "teacher", + "unicode": "1f9d1-200d-1f3eb" + }, + ":teacher_tone1:": { + "category": "people", + "name": "teacher: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f3eb" + }, + ":teacher_tone2:": { + "category": "people", + "name": "teacher: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f3eb" + }, + ":teacher_tone3:": { + "category": "people", + "name": "teacher: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f3eb" + }, + ":teacher_tone4:": { + "category": "people", + "name": "teacher: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f3eb" + }, + ":teacher_tone5:": { + "category": "people", + "name": "teacher: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f3eb" + }, + ":teapot:": { + "category": "food", + "name": "teapot", + "unicode": "1fad6" + }, + ":technologist:": { + "category": "people", + "name": "technologist", + "unicode": "1f9d1-200d-1f4bb" + }, + ":technologist_tone1:": { + "category": "people", + "name": "technologist: light skin tone", + "unicode": "1f9d1-1f3fb-200d-1f4bb" + }, + ":technologist_tone2:": { + "category": "people", + "name": "technologist: medium-light skin tone", + "unicode": "1f9d1-1f3fc-200d-1f4bb" + }, + ":technologist_tone3:": { + "category": "people", + "name": "technologist: medium skin tone", + "unicode": "1f9d1-1f3fd-200d-1f4bb" + }, + ":technologist_tone4:": { + "category": "people", + "name": "technologist: medium-dark skin tone", + "unicode": "1f9d1-1f3fe-200d-1f4bb" + }, + ":technologist_tone5:": { + "category": "people", + "name": "technologist: dark skin tone", + "unicode": "1f9d1-1f3ff-200d-1f4bb" + }, + ":teddy_bear:": { + "category": "objects", + "name": "teddy bear", + "unicode": "1f9f8" + }, + ":telephone:": { + "category": "objects", + "name": "telephone", + "unicode": "260e" + }, + ":telephone_receiver:": { + "category": "objects", + "name": "telephone receiver", + "unicode": "1f4de" + }, + ":telescope:": { + "category": "objects", + "name": "telescope", + "unicode": "1f52d" + }, + ":tennis:": { + "category": "activity", + "name": "tennis", + "unicode": "1f3be" + }, + ":tent:": { + "category": "travel", + "name": "tent", + "unicode": "26fa" + }, + ":test_tube:": { + "category": "objects", + "name": "test tube", + "unicode": "1f9ea" + }, + ":thermometer:": { + "category": "objects", + "name": "thermometer", + "unicode": "1f321" + }, + ":thermometer_face:": { + "category": "people", + "name": "face with thermometer", + "unicode": "1f912" + }, + ":thinking:": { + "category": "people", + "name": "thinking face", + "unicode": "1f914" + }, + ":third_place:": { + "category": "activity", + "name": "3rd place medal", + "unicode": "1f949" + }, + ":thong_sandal:": { + "category": "people", + "name": "thong sandal", + "unicode": "1fa74" + }, + ":thought_balloon:": { + "category": "symbols", + "name": "thought balloon", + "unicode": "1f4ad" + }, + ":thread:": { + "category": "people", + "name": "thread", + "unicode": "1f9f5" + }, + ":three:": { + "category": "symbols", + "name": "keycap: 3", + "unicode": "33-20e3", + "unicode_alt": "0033-20e3" + }, + ":thumbsdown:": { + "category": "people", + "name": "thumbs down", + "unicode": "1f44e" + }, + ":thumbsdown_tone1:": { + "category": "people", + "name": "thumbs down: light skin tone", + "unicode": "1f44e-1f3fb" + }, + ":thumbsdown_tone2:": { + "category": "people", + "name": "thumbs down: medium-light skin tone", + "unicode": "1f44e-1f3fc" + }, + ":thumbsdown_tone3:": { + "category": "people", + "name": "thumbs down: medium skin tone", + "unicode": "1f44e-1f3fd" + }, + ":thumbsdown_tone4:": { + "category": "people", + "name": "thumbs down: medium-dark skin tone", + "unicode": "1f44e-1f3fe" + }, + ":thumbsdown_tone5:": { + "category": "people", + "name": "thumbs down: dark skin tone", + "unicode": "1f44e-1f3ff" + }, + ":thumbsup:": { + "category": "people", + "name": "thumbs up", + "unicode": "1f44d" + }, + ":thumbsup_tone1:": { + "category": "people", + "name": "thumbs up: light skin tone", + "unicode": "1f44d-1f3fb" + }, + ":thumbsup_tone2:": { + "category": "people", + "name": "thumbs up: medium-light skin tone", + "unicode": "1f44d-1f3fc" + }, + ":thumbsup_tone3:": { + "category": "people", + "name": "thumbs up: medium skin tone", + "unicode": "1f44d-1f3fd" + }, + ":thumbsup_tone4:": { + "category": "people", + "name": "thumbs up: medium-dark skin tone", + "unicode": "1f44d-1f3fe" + }, + ":thumbsup_tone5:": { + "category": "people", + "name": "thumbs up: dark skin tone", + "unicode": "1f44d-1f3ff" + }, + ":thunder_cloud_rain:": { + "category": "nature", + "name": "cloud with lightning and rain", + "unicode": "26c8" + }, + ":ticket:": { + "category": "activity", + "name": "ticket", + "unicode": "1f3ab" + }, + ":tickets:": { + "category": "activity", + "name": "admission tickets", + "unicode": "1f39f" + }, + ":tiger2:": { + "category": "nature", + "name": "tiger", + "unicode": "1f405" + }, + ":tiger:": { + "category": "nature", + "name": "tiger face", + "unicode": "1f42f" + }, + ":timer:": { + "category": "objects", + "name": "timer clock", + "unicode": "23f2" + }, + ":tired_face:": { + "category": "people", + "name": "tired face", + "unicode": "1f62b" + }, + ":tm:": { + "category": "symbols", + "name": "trade mark", + "unicode": "2122" + }, + ":toilet:": { + "category": "objects", + "name": "toilet", + "unicode": "1f6bd" + }, + ":tokyo_tower:": { + "category": "travel", + "name": "Tokyo tower", + "unicode": "1f5fc" + }, + ":tomato:": { + "category": "food", + "name": "tomato", + "unicode": "1f345" + }, + ":tone1:": { + "category": "modifier", + "name": "light skin tone", + "unicode": "1f3fb" + }, + ":tone2:": { + "category": "modifier", + "name": "medium-light skin tone", + "unicode": "1f3fc" + }, + ":tone3:": { + "category": "modifier", + "name": "medium skin tone", + "unicode": "1f3fd" + }, + ":tone4:": { + "category": "modifier", + "name": "medium-dark skin tone", + "unicode": "1f3fe" + }, + ":tone5:": { + "category": "modifier", + "name": "dark skin tone", + "unicode": "1f3ff" + }, + ":tongue:": { + "category": "people", + "name": "tongue", + "unicode": "1f445" + }, + ":toolbox:": { + "category": "objects", + "name": "toolbox", + "unicode": "1f9f0" + }, + ":tools:": { + "category": "objects", + "name": "hammer and wrench", + "unicode": "1f6e0" + }, + ":tooth:": { + "category": "people", + "name": "tooth", + "unicode": "1f9b7" + }, + ":toothbrush:": { + "category": "objects", + "name": "toothbrush", + "unicode": "1faa5" + }, + ":top:": { + "category": "symbols", + "name": "TOP arrow", + "unicode": "1f51d" + }, + ":tophat:": { + "category": "people", + "name": "top hat", + "unicode": "1f3a9" + }, + ":track_next:": { + "category": "symbols", + "name": "next track button", + "unicode": "23ed" + }, + ":track_previous:": { + "category": "symbols", + "name": "last track button", + "unicode": "23ee" + }, + ":trackball:": { + "category": "objects", + "name": "trackball", + "unicode": "1f5b2" + }, + ":tractor:": { + "category": "travel", + "name": "tractor", + "unicode": "1f69c" + }, + ":traffic_light:": { + "category": "travel", + "name": "horizontal traffic light", + "unicode": "1f6a5" + }, + ":train2:": { + "category": "travel", + "name": "train", + "unicode": "1f686" + }, + ":train:": { + "category": "travel", + "name": "tram car", + "unicode": "1f68b" + }, + ":tram:": { + "category": "travel", + "name": "tram", + "unicode": "1f68a" + }, + ":transgender_flag:": { + "category": "flags", + "name": "transgender flag", + "unicode": "1f3f3-fe0f-200d-26a7-fe0f" + }, + ":transgender_symbol:": { + "category": "symbols", + "name": "transgender symbol", + "unicode": "26a7" + }, + ":triangular_flag_on_post:": { + "category": "flags", + "name": "triangular flag", + "unicode": "1f6a9" + }, + ":triangular_ruler:": { + "category": "objects", + "name": "triangular ruler", + "unicode": "1f4d0" + }, + ":trident:": { + "category": "symbols", + "name": "trident emblem", + "unicode": "1f531" + }, + ":triumph:": { + "category": "people", + "name": "face with steam from nose", + "unicode": "1f624" + }, + ":troll:": { + "category": "people", + "name": "troll", + "unicode": "1f9cc" + }, + ":trolleybus:": { + "category": "travel", + "name": "trolleybus", + "unicode": "1f68e" + }, + ":trophy:": { + "category": "activity", + "name": "trophy", + "unicode": "1f3c6" + }, + ":tropical_drink:": { + "category": "food", + "name": "tropical drink", + "unicode": "1f379" + }, + ":tropical_fish:": { + "category": "nature", + "name": "tropical fish", + "unicode": "1f420" + }, + ":truck:": { + "category": "travel", + "name": "delivery truck", + "unicode": "1f69a" + }, + ":trumpet:": { + "category": "activity", + "name": "trumpet", + "unicode": "1f3ba" + }, + ":tulip:": { + "category": "nature", + "name": "tulip", + "unicode": "1f337" + }, + ":tumbler_glass:": { + "category": "food", + "name": "tumbler glass", + "unicode": "1f943" + }, + ":turkey:": { + "category": "nature", + "name": "turkey", + "unicode": "1f983" + }, + ":turtle:": { + "category": "nature", + "name": "turtle", + "unicode": "1f422" + }, + ":tv:": { + "category": "objects", + "name": "television", + "unicode": "1f4fa" + }, + ":twisted_rightwards_arrows:": { + "category": "symbols", + "name": "shuffle tracks button", + "unicode": "1f500" + }, + ":two:": { + "category": "symbols", + "name": "keycap: 2", + "unicode": "32-20e3", + "unicode_alt": "0032-20e3" + }, + ":two_hearts:": { + "category": "symbols", + "name": "two hearts", + "unicode": "1f495" + }, + ":two_men_holding_hands:": { + "category": "people", + "name": "men holding hands", + "unicode": "1f46c" + }, + ":two_women_holding_hands:": { + "category": "people", + "name": "women holding hands", + "unicode": "1f46d" + }, + ":u5272:": { + "category": "symbols", + "name": "Japanese \u201cdiscount\u201d button", + "unicode": "1f239" + }, + ":u5408:": { + "category": "symbols", + "name": "Japanese \u201cpassing grade\u201d button", + "unicode": "1f234" + }, + ":u55b6:": { + "category": "symbols", + "name": "Japanese \u201copen for business\u201d button", + "unicode": "1f23a" + }, + ":u6307:": { + "category": "symbols", + "name": "Japanese \u201creserved\u201d button", + "unicode": "1f22f" + }, + ":u6708:": { + "category": "symbols", + "name": "Japanese \u201cmonthly amount\u201d button", + "unicode": "1f237" + }, + ":u6709:": { + "category": "symbols", + "name": "Japanese \u201cnot free of charge\u201d button", + "unicode": "1f236" + }, + ":u6e80:": { + "category": "symbols", + "name": "Japanese \u201cno vacancy\u201d button", + "unicode": "1f235" + }, + ":u7121:": { + "category": "symbols", + "name": "Japanese \u201cfree of charge\u201d button", + "unicode": "1f21a" + }, + ":u7533:": { + "category": "symbols", + "name": "Japanese \u201capplication\u201d button", + "unicode": "1f238" + }, + ":u7981:": { + "category": "symbols", + "name": "Japanese \u201cprohibited\u201d button", + "unicode": "1f232" + }, + ":u7a7a:": { + "category": "symbols", + "name": "Japanese \u201cvacancy\u201d button", + "unicode": "1f233" + }, + ":umbrella2:": { + "category": "nature", + "name": "umbrella", + "unicode": "2602" + }, + ":umbrella:": { + "category": "nature", + "name": "umbrella with rain drops", + "unicode": "2614" + }, + ":unamused:": { + "category": "people", + "name": "unamused face", + "unicode": "1f612" + }, + ":underage:": { + "category": "symbols", + "name": "no one under eighteen", + "unicode": "1f51e" + }, + ":unicorn:": { + "category": "nature", + "name": "unicorn", + "unicode": "1f984" + }, + ":united_nations:": { + "category": "flags", + "name": "flag: United Nations", + "unicode": "1f1fa-1f1f3" + }, + ":unlock:": { + "category": "objects", + "name": "unlocked", + "unicode": "1f513" + }, + ":up:": { + "category": "symbols", + "name": "UP! button", + "unicode": "1f199" + }, + ":upside_down:": { + "category": "people", + "name": "upside-down face", + "unicode": "1f643" + }, + ":urn:": { + "category": "objects", + "name": "funeral urn", + "unicode": "26b1" + }, + ":v:": { + "category": "people", + "name": "victory hand", + "unicode": "270c" + }, + ":v_tone1:": { + "category": "people", + "name": "victory hand: light skin tone", + "unicode": "270c-1f3fb" + }, + ":v_tone2:": { + "category": "people", + "name": "victory hand: medium-light skin tone", + "unicode": "270c-1f3fc" + }, + ":v_tone3:": { + "category": "people", + "name": "victory hand: medium skin tone", + "unicode": "270c-1f3fd" + }, + ":v_tone4:": { + "category": "people", + "name": "victory hand: medium-dark skin tone", + "unicode": "270c-1f3fe" + }, + ":v_tone5:": { + "category": "people", + "name": "victory hand: dark skin tone", + "unicode": "270c-1f3ff" + }, + ":vampire:": { + "category": "people", + "name": "vampire", + "unicode": "1f9db" + }, + ":vampire_tone1:": { + "category": "people", + "name": "vampire: light skin tone", + "unicode": "1f9db-1f3fb" + }, + ":vampire_tone2:": { + "category": "people", + "name": "vampire: medium-light skin tone", + "unicode": "1f9db-1f3fc" + }, + ":vampire_tone3:": { + "category": "people", + "name": "vampire: medium skin tone", + "unicode": "1f9db-1f3fd" + }, + ":vampire_tone4:": { + "category": "people", + "name": "vampire: medium-dark skin tone", + "unicode": "1f9db-1f3fe" + }, + ":vampire_tone5:": { + "category": "people", + "name": "vampire: dark skin tone", + "unicode": "1f9db-1f3ff" + }, + ":vertical_traffic_light:": { + "category": "travel", + "name": "vertical traffic light", + "unicode": "1f6a6" + }, + ":vhs:": { + "category": "objects", + "name": "videocassette", + "unicode": "1f4fc" + }, + ":vibration_mode:": { + "category": "symbols", + "name": "vibration mode", + "unicode": "1f4f3" + }, + ":video_camera:": { + "category": "objects", + "name": "video camera", + "unicode": "1f4f9" + }, + ":video_game:": { + "category": "activity", + "name": "video game", + "unicode": "1f3ae" + }, + ":violin:": { + "category": "activity", + "name": "violin", + "unicode": "1f3bb" + }, + ":virgo:": { + "category": "symbols", + "name": "Virgo", + "unicode": "264d" + }, + ":volcano:": { + "category": "travel", + "name": "volcano", + "unicode": "1f30b" + }, + ":volleyball:": { + "category": "activity", + "name": "volleyball", + "unicode": "1f3d0" + }, + ":vs:": { + "category": "symbols", + "name": "VS button", + "unicode": "1f19a" + }, + ":vulcan:": { + "category": "people", + "name": "vulcan salute", + "unicode": "1f596" + }, + ":vulcan_tone1:": { + "category": "people", + "name": "vulcan salute: light skin tone", + "unicode": "1f596-1f3fb" + }, + ":vulcan_tone2:": { + "category": "people", + "name": "vulcan salute: medium-light skin tone", + "unicode": "1f596-1f3fc" + }, + ":vulcan_tone3:": { + "category": "people", + "name": "vulcan salute: medium skin tone", + "unicode": "1f596-1f3fd" + }, + ":vulcan_tone4:": { + "category": "people", + "name": "vulcan salute: medium-dark skin tone", + "unicode": "1f596-1f3fe" + }, + ":vulcan_tone5:": { + "category": "people", + "name": "vulcan salute: dark skin tone", + "unicode": "1f596-1f3ff" + }, + ":waffle:": { + "category": "food", + "name": "waffle", + "unicode": "1f9c7" + }, + ":wales:": { + "category": "flags", + "name": "flag: Wales", + "unicode": "1f3f4-e0067-e0062-e0077-e006c-e0073-e007f" + }, + ":waning_crescent_moon:": { + "category": "nature", + "name": "waning crescent moon", + "unicode": "1f318" + }, + ":waning_gibbous_moon:": { + "category": "nature", + "name": "waning gibbous moon", + "unicode": "1f316" + }, + ":warning:": { + "category": "symbols", + "name": "warning", + "unicode": "26a0" + }, + ":wastebasket:": { + "category": "objects", + "name": "wastebasket", + "unicode": "1f5d1" + }, + ":watch:": { + "category": "objects", + "name": "watch", + "unicode": "231a" + }, + ":water_buffalo:": { + "category": "nature", + "name": "water buffalo", + "unicode": "1f403" + }, + ":watermelon:": { + "category": "food", + "name": "watermelon", + "unicode": "1f349" + }, + ":wave:": { + "category": "people", + "name": "waving hand", + "unicode": "1f44b" + }, + ":wave_tone1:": { + "category": "people", + "name": "waving hand: light skin tone", + "unicode": "1f44b-1f3fb" + }, + ":wave_tone2:": { + "category": "people", + "name": "waving hand: medium-light skin tone", + "unicode": "1f44b-1f3fc" + }, + ":wave_tone3:": { + "category": "people", + "name": "waving hand: medium skin tone", + "unicode": "1f44b-1f3fd" + }, + ":wave_tone4:": { + "category": "people", + "name": "waving hand: medium-dark skin tone", + "unicode": "1f44b-1f3fe" + }, + ":wave_tone5:": { + "category": "people", + "name": "waving hand: dark skin tone", + "unicode": "1f44b-1f3ff" + }, + ":wavy_dash:": { + "category": "symbols", + "name": "wavy dash", + "unicode": "3030" + }, + ":waxing_crescent_moon:": { + "category": "nature", + "name": "waxing crescent moon", + "unicode": "1f312" + }, + ":waxing_gibbous_moon:": { + "category": "nature", + "name": "waxing gibbous moon", + "unicode": "1f314" + }, + ":wc:": { + "category": "symbols", + "name": "water closet", + "unicode": "1f6be" + }, + ":weary:": { + "category": "people", + "name": "weary face", + "unicode": "1f629" + }, + ":wedding:": { + "category": "travel", + "name": "wedding", + "unicode": "1f492" + }, + ":whale2:": { + "category": "nature", + "name": "whale", + "unicode": "1f40b" + }, + ":whale:": { + "category": "nature", + "name": "spouting whale", + "unicode": "1f433" + }, + ":wheel:": { + "category": "travel", + "name": "wheel", + "unicode": "1f6de" + }, + ":wheel_of_dharma:": { + "category": "symbols", + "name": "wheel of dharma", + "unicode": "2638" + }, + ":wheelchair:": { + "category": "symbols", + "name": "wheelchair symbol", + "unicode": "267f" + }, + ":white_check_mark:": { + "category": "symbols", + "name": "check mark button", + "unicode": "2705" + }, + ":white_circle:": { + "category": "symbols", + "name": "white circle", + "unicode": "26aa" + }, + ":white_flower:": { + "category": "symbols", + "name": "white flower", + "unicode": "1f4ae" + }, + ":white_haired:": { + "category": "people", + "name": "white hair", + "unicode": "1f9b3" + }, + ":white_heart:": { + "category": "symbols", + "name": "white heart", + "unicode": "1f90d" + }, + ":white_large_square:": { + "category": "symbols", + "name": "white large square", + "unicode": "2b1c" + }, + ":white_medium_small_square:": { + "category": "symbols", + "name": "white medium-small square", + "unicode": "25fd" + }, + ":white_medium_square:": { + "category": "symbols", + "name": "white medium square", + "unicode": "25fb" + }, + ":white_small_square:": { + "category": "symbols", + "name": "white small square", + "unicode": "25ab" + }, + ":white_square_button:": { + "category": "symbols", + "name": "white square button", + "unicode": "1f533" + }, + ":white_sun_cloud:": { + "category": "nature", + "name": "sun behind large cloud", + "unicode": "1f325" + }, + ":white_sun_rain_cloud:": { + "category": "nature", + "name": "sun behind rain cloud", + "unicode": "1f326" + }, + ":white_sun_small_cloud:": { + "category": "nature", + "name": "sun behind small cloud", + "unicode": "1f324" + }, + ":wilted_rose:": { + "category": "nature", + "name": "wilted flower", + "unicode": "1f940" + }, + ":wind_blowing_face:": { + "category": "nature", + "name": "wind face", + "unicode": "1f32c" + }, + ":wind_chime:": { + "category": "objects", + "name": "wind chime", + "unicode": "1f390" + }, + ":window:": { + "category": "objects", + "name": "window", + "unicode": "1fa9f" + }, + ":wine_glass:": { + "category": "food", + "name": "wine glass", + "unicode": "1f377" + }, + ":wing:": { + "category": "nature", + "name": "wing", + "unicode": "1fabd" + }, + ":wink:": { + "category": "people", + "name": "winking face", + "unicode": "1f609" + }, + ":wireless:": { + "category": "symbols", + "name": "wireless", + "unicode": "1f6dc" + }, + ":wolf:": { + "category": "nature", + "name": "wolf", + "unicode": "1f43a" + }, + ":woman:": { + "category": "people", + "name": "woman", + "unicode": "1f469" + }, + ":woman_and_man_holding_hands_tone1:": { + "category": "people", + "name": "woman and man holding hands: light skin tone", + "unicode": "1f46b-1f3fb" + }, + ":woman_and_man_holding_hands_tone1_tone2:": { + "category": "people", + "name": "woman and man holding hands: light skin tone, medium light skin tone", + "unicode": "1f469-1f3fb-200d-1f91d-200d-1f468-1f3fc" + }, + ":woman_and_man_holding_hands_tone1_tone3:": { + "category": "people", + "name": "woman and man holding hands: light skin tone, medium skin tone", + "unicode": "1f469-1f3fb-200d-1f91d-200d-1f468-1f3fd" + }, + ":woman_and_man_holding_hands_tone1_tone4:": { + "category": "people", + "name": "woman and man holding hands: light skin tone, medium dark skin tone", + "unicode": "1f469-1f3fb-200d-1f91d-200d-1f468-1f3fe" + }, + ":woman_and_man_holding_hands_tone1_tone5:": { + "category": "people", + "name": "woman and man holding hands: light skin tone, dark skin tone", + "unicode": "1f469-1f3fb-200d-1f91d-200d-1f468-1f3ff" + }, + ":woman_and_man_holding_hands_tone2:": { + "category": "people", + "name": "woman and man holding hands: medium-light skin tone", + "unicode": "1f46b-1f3fc" + }, + ":woman_and_man_holding_hands_tone2_tone1:": { + "category": "people", + "name": "woman and man holding hands: medium light skin tone, light skin tone", + "unicode": "1f469-1f3fc-200d-1f91d-200d-1f468-1f3fb" + }, + ":woman_and_man_holding_hands_tone2_tone3:": { + "category": "people", + "name": "woman and man holding hands: medium light skin tone, medium skin tone", + "unicode": "1f469-1f3fc-200d-1f91d-200d-1f468-1f3fd" + }, + ":woman_and_man_holding_hands_tone2_tone4:": { + "category": "people", + "name": "woman and man holding hands: medium light skin tone, medium dark skin tone", + "unicode": "1f469-1f3fc-200d-1f91d-200d-1f468-1f3fe" + }, + ":woman_and_man_holding_hands_tone2_tone5:": { + "category": "people", + "name": "woman and man holding hands: medium light skin tone, dark skin tone", + "unicode": "1f469-1f3fc-200d-1f91d-200d-1f468-1f3ff" + }, + ":woman_and_man_holding_hands_tone3:": { + "category": "people", + "name": "woman and man holding hands: medium skin tone", + "unicode": "1f46b-1f3fd" + }, + ":woman_and_man_holding_hands_tone3_tone1:": { + "category": "people", + "name": "woman and man holding hands: medium skin tone, light skin tone", + "unicode": "1f469-1f3fd-200d-1f91d-200d-1f468-1f3fb" + }, + ":woman_and_man_holding_hands_tone3_tone2:": { + "category": "people", + "name": "woman and man holding hands: medium skin tone, medium light skin tone", + "unicode": "1f469-1f3fd-200d-1f91d-200d-1f468-1f3fc" + }, + ":woman_and_man_holding_hands_tone3_tone4:": { + "category": "people", + "name": "woman and man holding hands: medium skin tone, medium dark skin tone", + "unicode": "1f469-1f3fd-200d-1f91d-200d-1f468-1f3fe" + }, + ":woman_and_man_holding_hands_tone3_tone5:": { + "category": "people", + "name": "woman and man holding hands: medium skin tone, dark skin tone", + "unicode": "1f469-1f3fd-200d-1f91d-200d-1f468-1f3ff" + }, + ":woman_and_man_holding_hands_tone4:": { + "category": "people", + "name": "woman and man holding hands: medium-dark skin tone", + "unicode": "1f46b-1f3fe" + }, + ":woman_and_man_holding_hands_tone4_tone1:": { + "category": "people", + "name": "woman and man holding hands: medium dark skin tone, light skin tone", + "unicode": "1f469-1f3fe-200d-1f91d-200d-1f468-1f3fb" + }, + ":woman_and_man_holding_hands_tone4_tone2:": { + "category": "people", + "name": "woman and man holding hands: medium dark skin tone, medium light skin tone", + "unicode": "1f469-1f3fe-200d-1f91d-200d-1f468-1f3fc" + }, + ":woman_and_man_holding_hands_tone4_tone3:": { + "category": "people", + "name": "woman and man holding hands: medium dark skin tone, medium skin tone", + "unicode": "1f469-1f3fe-200d-1f91d-200d-1f468-1f3fd" + }, + ":woman_and_man_holding_hands_tone4_tone5:": { + "category": "people", + "name": "woman and man holding hands: medium dark skin tone, dark skin tone", + "unicode": "1f469-1f3fe-200d-1f91d-200d-1f468-1f3ff" + }, + ":woman_and_man_holding_hands_tone5:": { + "category": "people", + "name": "woman and man holding hands: dark skin tone", + "unicode": "1f46b-1f3ff" + }, + ":woman_and_man_holding_hands_tone5_tone1:": { + "category": "people", + "name": "woman and man holding hands: dark skin tone, light skin tone", + "unicode": "1f469-1f3ff-200d-1f91d-200d-1f468-1f3fb" + }, + ":woman_and_man_holding_hands_tone5_tone2:": { + "category": "people", + "name": "woman and man holding hands: dark skin tone, medium light skin tone", + "unicode": "1f469-1f3ff-200d-1f91d-200d-1f468-1f3fc" + }, + ":woman_and_man_holding_hands_tone5_tone3:": { + "category": "people", + "name": "woman and man holding hands: dark skin tone, medium skin tone", + "unicode": "1f469-1f3ff-200d-1f91d-200d-1f468-1f3fd" + }, + ":woman_and_man_holding_hands_tone5_tone4:": { + "category": "people", + "name": "woman and man holding hands: dark skin tone, medium dark skin tone", + "unicode": "1f469-1f3ff-200d-1f91d-200d-1f468-1f3fe" + }, + ":woman_artist:": { + "category": "people", + "name": "woman artist", + "unicode": "1f469-200d-1f3a8" + }, + ":woman_artist_tone1:": { + "category": "people", + "name": "woman artist: light skin tone", + "unicode": "1f469-1f3fb-200d-1f3a8" + }, + ":woman_artist_tone2:": { + "category": "people", + "name": "woman artist: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f3a8" + }, + ":woman_artist_tone3:": { + "category": "people", + "name": "woman artist: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f3a8" + }, + ":woman_artist_tone4:": { + "category": "people", + "name": "woman artist: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f3a8" + }, + ":woman_artist_tone5:": { + "category": "people", + "name": "woman artist: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f3a8" + }, + ":woman_astronaut:": { + "category": "people", + "name": "woman astronaut", + "unicode": "1f469-200d-1f680" + }, + ":woman_astronaut_tone1:": { + "category": "people", + "name": "woman astronaut: light skin tone", + "unicode": "1f469-1f3fb-200d-1f680" + }, + ":woman_astronaut_tone2:": { + "category": "people", + "name": "woman astronaut: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f680" + }, + ":woman_astronaut_tone3:": { + "category": "people", + "name": "woman astronaut: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f680" + }, + ":woman_astronaut_tone4:": { + "category": "people", + "name": "woman astronaut: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f680" + }, + ":woman_astronaut_tone5:": { + "category": "people", + "name": "woman astronaut: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f680" + }, + ":woman_bald:": { + "category": "people", + "name": "woman: bald", + "unicode": "1f469-200d-1f9b2" + }, + ":woman_bald_tone1:": { + "category": "people", + "name": "woman, bald: light skin tone", + "unicode": "1f469-1f3fb-200d-1f9b2" + }, + ":woman_bald_tone2:": { + "category": "people", + "name": "woman, bald: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f9b2" + }, + ":woman_bald_tone3:": { + "category": "people", + "name": "woman, bald: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f9b2" + }, + ":woman_bald_tone4:": { + "category": "people", + "name": "woman, bald: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f9b2" + }, + ":woman_bald_tone5:": { + "category": "people", + "name": "woman, bald: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f9b2" + }, + ":woman_beard:": { + "category": "people", + "name": "woman: beard", + "unicode": "1f9d4-200d-2640-fe0f" + }, + ":woman_biking:": { + "category": "activity", + "name": "woman biking", + "unicode": "1f6b4-200d-2640-fe0f" + }, + ":woman_biking_tone1:": { + "category": "activity", + "name": "woman biking: light skin tone", + "unicode": "1f6b4-1f3fb-200d-2640-fe0f" + }, + ":woman_biking_tone2:": { + "category": "activity", + "name": "woman biking: medium-light skin tone", + "unicode": "1f6b4-1f3fc-200d-2640-fe0f" + }, + ":woman_biking_tone3:": { + "category": "activity", + "name": "woman biking: medium skin tone", + "unicode": "1f6b4-1f3fd-200d-2640-fe0f" + }, + ":woman_biking_tone4:": { + "category": "activity", + "name": "woman biking: medium-dark skin tone", + "unicode": "1f6b4-1f3fe-200d-2640-fe0f" + }, + ":woman_biking_tone5:": { + "category": "activity", + "name": "woman biking: dark skin tone", + "unicode": "1f6b4-1f3ff-200d-2640-fe0f" + }, + ":woman_bouncing_ball:": { + "category": "activity", + "name": "woman bouncing ball", + "unicode": "26f9-fe0f-200d-2640-fe0f" + }, + ":woman_bouncing_ball_tone1:": { + "category": "activity", + "name": "woman bouncing ball: light skin tone", + "unicode": "26f9-1f3fb-200d-2640-fe0f" + }, + ":woman_bouncing_ball_tone2:": { + "category": "activity", + "name": "woman bouncing ball: medium-light skin tone", + "unicode": "26f9-1f3fc-200d-2640-fe0f" + }, + ":woman_bouncing_ball_tone3:": { + "category": "activity", + "name": "woman bouncing ball: medium skin tone", + "unicode": "26f9-1f3fd-200d-2640-fe0f" + }, + ":woman_bouncing_ball_tone4:": { + "category": "activity", + "name": "woman bouncing ball: medium-dark skin tone", + "unicode": "26f9-1f3fe-200d-2640-fe0f" + }, + ":woman_bouncing_ball_tone5:": { + "category": "activity", + "name": "woman bouncing ball: dark skin tone", + "unicode": "26f9-1f3ff-200d-2640-fe0f" + }, + ":woman_bowing:": { + "category": "people", + "name": "woman bowing", + "unicode": "1f647-200d-2640-fe0f" + }, + ":woman_bowing_tone1:": { + "category": "people", + "name": "woman bowing: light skin tone", + "unicode": "1f647-1f3fb-200d-2640-fe0f" + }, + ":woman_bowing_tone2:": { + "category": "people", + "name": "woman bowing: medium-light skin tone", + "unicode": "1f647-1f3fc-200d-2640-fe0f" + }, + ":woman_bowing_tone3:": { + "category": "people", + "name": "woman bowing: medium skin tone", + "unicode": "1f647-1f3fd-200d-2640-fe0f" + }, + ":woman_bowing_tone4:": { + "category": "people", + "name": "woman bowing: medium-dark skin tone", + "unicode": "1f647-1f3fe-200d-2640-fe0f" + }, + ":woman_bowing_tone5:": { + "category": "people", + "name": "woman bowing: dark skin tone", + "unicode": "1f647-1f3ff-200d-2640-fe0f" + }, + ":woman_cartwheeling:": { + "category": "activity", + "name": "woman cartwheeling", + "unicode": "1f938-200d-2640-fe0f" + }, + ":woman_cartwheeling_tone1:": { + "category": "activity", + "name": "woman cartwheeling: light skin tone", + "unicode": "1f938-1f3fb-200d-2640-fe0f" + }, + ":woman_cartwheeling_tone2:": { + "category": "activity", + "name": "woman cartwheeling: medium-light skin tone", + "unicode": "1f938-1f3fc-200d-2640-fe0f" + }, + ":woman_cartwheeling_tone3:": { + "category": "activity", + "name": "woman cartwheeling: medium skin tone", + "unicode": "1f938-1f3fd-200d-2640-fe0f" + }, + ":woman_cartwheeling_tone4:": { + "category": "activity", + "name": "woman cartwheeling: medium-dark skin tone", + "unicode": "1f938-1f3fe-200d-2640-fe0f" + }, + ":woman_cartwheeling_tone5:": { + "category": "activity", + "name": "woman cartwheeling: dark skin tone", + "unicode": "1f938-1f3ff-200d-2640-fe0f" + }, + ":woman_climbing:": { + "category": "activity", + "name": "woman climbing", + "unicode": "1f9d7-200d-2640-fe0f" + }, + ":woman_climbing_tone1:": { + "category": "activity", + "name": "woman climbing: light skin tone", + "unicode": "1f9d7-1f3fb-200d-2640-fe0f" + }, + ":woman_climbing_tone2:": { + "category": "activity", + "name": "woman climbing: medium-light skin tone", + "unicode": "1f9d7-1f3fc-200d-2640-fe0f" + }, + ":woman_climbing_tone3:": { + "category": "activity", + "name": "woman climbing: medium skin tone", + "unicode": "1f9d7-1f3fd-200d-2640-fe0f" + }, + ":woman_climbing_tone4:": { + "category": "activity", + "name": "woman climbing: medium-dark skin tone", + "unicode": "1f9d7-1f3fe-200d-2640-fe0f" + }, + ":woman_climbing_tone5:": { + "category": "activity", + "name": "woman climbing: dark skin tone", + "unicode": "1f9d7-1f3ff-200d-2640-fe0f" + }, + ":woman_construction_worker:": { + "category": "people", + "name": "woman construction worker", + "unicode": "1f477-200d-2640-fe0f" + }, + ":woman_construction_worker_tone1:": { + "category": "people", + "name": "woman construction worker: light skin tone", + "unicode": "1f477-1f3fb-200d-2640-fe0f" + }, + ":woman_construction_worker_tone2:": { + "category": "people", + "name": "woman construction worker: medium-light skin tone", + "unicode": "1f477-1f3fc-200d-2640-fe0f" + }, + ":woman_construction_worker_tone3:": { + "category": "people", + "name": "woman construction worker: medium skin tone", + "unicode": "1f477-1f3fd-200d-2640-fe0f" + }, + ":woman_construction_worker_tone4:": { + "category": "people", + "name": "woman construction worker: medium-dark skin tone", + "unicode": "1f477-1f3fe-200d-2640-fe0f" + }, + ":woman_construction_worker_tone5:": { + "category": "people", + "name": "woman construction worker: dark skin tone", + "unicode": "1f477-1f3ff-200d-2640-fe0f" + }, + ":woman_cook:": { + "category": "people", + "name": "woman cook", + "unicode": "1f469-200d-1f373" + }, + ":woman_cook_tone1:": { + "category": "people", + "name": "woman cook: light skin tone", + "unicode": "1f469-1f3fb-200d-1f373" + }, + ":woman_cook_tone2:": { + "category": "people", + "name": "woman cook: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f373" + }, + ":woman_cook_tone3:": { + "category": "people", + "name": "woman cook: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f373" + }, + ":woman_cook_tone4:": { + "category": "people", + "name": "woman cook: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f373" + }, + ":woman_cook_tone5:": { + "category": "people", + "name": "woman cook: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f373" + }, + ":woman_curly_haired:": { + "category": "people", + "name": "woman: curly hair", + "unicode": "1f469-200d-1f9b1" + }, + ":woman_curly_haired_tone1:": { + "category": "people", + "name": "woman, curly haired: light skin tone", + "unicode": "1f469-1f3fb-200d-1f9b1" + }, + ":woman_curly_haired_tone2:": { + "category": "people", + "name": "woman, curly haired: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f9b1" + }, + ":woman_curly_haired_tone3:": { + "category": "people", + "name": "woman, curly haired: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f9b1" + }, + ":woman_curly_haired_tone4:": { + "category": "people", + "name": "woman, curly haired: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f9b1" + }, + ":woman_curly_haired_tone5:": { + "category": "people", + "name": "woman, curly haired: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f9b1" + }, + ":woman_detective:": { + "category": "people", + "name": "woman detective", + "unicode": "1f575-fe0f-200d-2640-fe0f" + }, + ":woman_detective_tone1:": { + "category": "people", + "name": "woman detective: light skin tone", + "unicode": "1f575-1f3fb-200d-2640-fe0f" + }, + ":woman_detective_tone2:": { + "category": "people", + "name": "woman detective: medium-light skin tone", + "unicode": "1f575-1f3fc-200d-2640-fe0f" + }, + ":woman_detective_tone3:": { + "category": "people", + "name": "woman detective: medium skin tone", + "unicode": "1f575-1f3fd-200d-2640-fe0f" + }, + ":woman_detective_tone4:": { + "category": "people", + "name": "woman detective: medium-dark skin tone", + "unicode": "1f575-1f3fe-200d-2640-fe0f" + }, + ":woman_detective_tone5:": { + "category": "people", + "name": "woman detective: dark skin tone", + "unicode": "1f575-1f3ff-200d-2640-fe0f" + }, + ":woman_elf:": { + "category": "people", + "name": "woman elf", + "unicode": "1f9dd-200d-2640-fe0f" + }, + ":woman_elf_tone1:": { + "category": "people", + "name": "woman elf: light skin tone", + "unicode": "1f9dd-1f3fb-200d-2640-fe0f" + }, + ":woman_elf_tone2:": { + "category": "people", + "name": "woman elf: medium-light skin tone", + "unicode": "1f9dd-1f3fc-200d-2640-fe0f" + }, + ":woman_elf_tone3:": { + "category": "people", + "name": "woman elf: medium skin tone", + "unicode": "1f9dd-1f3fd-200d-2640-fe0f" + }, + ":woman_elf_tone4:": { + "category": "people", + "name": "woman elf: medium-dark skin tone", + "unicode": "1f9dd-1f3fe-200d-2640-fe0f" + }, + ":woman_elf_tone5:": { + "category": "people", + "name": "woman elf: dark skin tone", + "unicode": "1f9dd-1f3ff-200d-2640-fe0f" + }, + ":woman_facepalming:": { + "category": "people", + "name": "woman facepalming", + "unicode": "1f926-200d-2640-fe0f" + }, + ":woman_facepalming_tone1:": { + "category": "people", + "name": "woman facepalming: light skin tone", + "unicode": "1f926-1f3fb-200d-2640-fe0f" + }, + ":woman_facepalming_tone2:": { + "category": "people", + "name": "woman facepalming: medium-light skin tone", + "unicode": "1f926-1f3fc-200d-2640-fe0f" + }, + ":woman_facepalming_tone3:": { + "category": "people", + "name": "woman facepalming: medium skin tone", + "unicode": "1f926-1f3fd-200d-2640-fe0f" + }, + ":woman_facepalming_tone4:": { + "category": "people", + "name": "woman facepalming: medium-dark skin tone", + "unicode": "1f926-1f3fe-200d-2640-fe0f" + }, + ":woman_facepalming_tone5:": { + "category": "people", + "name": "woman facepalming: dark skin tone", + "unicode": "1f926-1f3ff-200d-2640-fe0f" + }, + ":woman_factory_worker:": { + "category": "people", + "name": "woman factory worker", + "unicode": "1f469-200d-1f3ed" + }, + ":woman_factory_worker_tone1:": { + "category": "people", + "name": "woman factory worker: light skin tone", + "unicode": "1f469-1f3fb-200d-1f3ed" + }, + ":woman_factory_worker_tone2:": { + "category": "people", + "name": "woman factory worker: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f3ed" + }, + ":woman_factory_worker_tone3:": { + "category": "people", + "name": "woman factory worker: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f3ed" + }, + ":woman_factory_worker_tone4:": { + "category": "people", + "name": "woman factory worker: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f3ed" + }, + ":woman_factory_worker_tone5:": { + "category": "people", + "name": "woman factory worker: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f3ed" + }, + ":woman_fairy:": { + "category": "people", + "name": "woman fairy", + "unicode": "1f9da-200d-2640-fe0f" + }, + ":woman_fairy_tone1:": { + "category": "people", + "name": "woman fairy: light skin tone", + "unicode": "1f9da-1f3fb-200d-2640-fe0f" + }, + ":woman_fairy_tone2:": { + "category": "people", + "name": "woman fairy: medium-light skin tone", + "unicode": "1f9da-1f3fc-200d-2640-fe0f" + }, + ":woman_fairy_tone3:": { + "category": "people", + "name": "woman fairy: medium skin tone", + "unicode": "1f9da-1f3fd-200d-2640-fe0f" + }, + ":woman_fairy_tone4:": { + "category": "people", + "name": "woman fairy: medium-dark skin tone", + "unicode": "1f9da-1f3fe-200d-2640-fe0f" + }, + ":woman_fairy_tone5:": { + "category": "people", + "name": "woman fairy: dark skin tone", + "unicode": "1f9da-1f3ff-200d-2640-fe0f" + }, + ":woman_farmer:": { + "category": "people", + "name": "woman farmer", + "unicode": "1f469-200d-1f33e" + }, + ":woman_farmer_tone1:": { + "category": "people", + "name": "woman farmer: light skin tone", + "unicode": "1f469-1f3fb-200d-1f33e" + }, + ":woman_farmer_tone2:": { + "category": "people", + "name": "woman farmer: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f33e" + }, + ":woman_farmer_tone3:": { + "category": "people", + "name": "woman farmer: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f33e" + }, + ":woman_farmer_tone4:": { + "category": "people", + "name": "woman farmer: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f33e" + }, + ":woman_farmer_tone5:": { + "category": "people", + "name": "woman farmer: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f33e" + }, + ":woman_feeding_baby:": { + "category": "people", + "name": "woman feeding baby", + "unicode": "1f469-200d-1f37c" + }, + ":woman_feeding_baby_tone1:": { + "category": "people", + "name": "woman feeding baby: light skin tone", + "unicode": "1f469-1f3fb-200d-1f37c" + }, + ":woman_feeding_baby_tone2:": { + "category": "people", + "name": "woman feeding baby: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f37c" + }, + ":woman_feeding_baby_tone3:": { + "category": "people", + "name": "woman feeding baby: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f37c" + }, + ":woman_feeding_baby_tone4:": { + "category": "people", + "name": "woman feeding baby: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f37c" + }, + ":woman_feeding_baby_tone5:": { + "category": "people", + "name": "woman feeding baby: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f37c" + }, + ":woman_firefighter:": { + "category": "people", + "name": "woman firefighter", + "unicode": "1f469-200d-1f692" + }, + ":woman_firefighter_tone1:": { + "category": "people", + "name": "woman firefighter: light skin tone", + "unicode": "1f469-1f3fb-200d-1f692" + }, + ":woman_firefighter_tone2:": { + "category": "people", + "name": "woman firefighter: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f692" + }, + ":woman_firefighter_tone3:": { + "category": "people", + "name": "woman firefighter: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f692" + }, + ":woman_firefighter_tone4:": { + "category": "people", + "name": "woman firefighter: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f692" + }, + ":woman_firefighter_tone5:": { + "category": "people", + "name": "woman firefighter: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f692" + }, + ":woman_frowning:": { + "category": "people", + "name": "woman frowning", + "unicode": "1f64d-200d-2640-fe0f" + }, + ":woman_frowning_tone1:": { + "category": "people", + "name": "woman frowning: light skin tone", + "unicode": "1f64d-1f3fb-200d-2640-fe0f" + }, + ":woman_frowning_tone2:": { + "category": "people", + "name": "woman frowning: medium-light skin tone", + "unicode": "1f64d-1f3fc-200d-2640-fe0f" + }, + ":woman_frowning_tone3:": { + "category": "people", + "name": "woman frowning: medium skin tone", + "unicode": "1f64d-1f3fd-200d-2640-fe0f" + }, + ":woman_frowning_tone4:": { + "category": "people", + "name": "woman frowning: medium-dark skin tone", + "unicode": "1f64d-1f3fe-200d-2640-fe0f" + }, + ":woman_frowning_tone5:": { + "category": "people", + "name": "woman frowning: dark skin tone", + "unicode": "1f64d-1f3ff-200d-2640-fe0f" + }, + ":woman_genie:": { + "category": "people", + "name": "woman genie", + "unicode": "1f9de-200d-2640-fe0f" + }, + ":woman_gesturing_no:": { + "category": "people", + "name": "woman gesturing NO", + "unicode": "1f645-200d-2640-fe0f" + }, + ":woman_gesturing_no_tone1:": { + "category": "people", + "name": "woman gesturing NO: light skin tone", + "unicode": "1f645-1f3fb-200d-2640-fe0f" + }, + ":woman_gesturing_no_tone2:": { + "category": "people", + "name": "woman gesturing NO: medium-light skin tone", + "unicode": "1f645-1f3fc-200d-2640-fe0f" + }, + ":woman_gesturing_no_tone3:": { + "category": "people", + "name": "woman gesturing NO: medium skin tone", + "unicode": "1f645-1f3fd-200d-2640-fe0f" + }, + ":woman_gesturing_no_tone4:": { + "category": "people", + "name": "woman gesturing NO: medium-dark skin tone", + "unicode": "1f645-1f3fe-200d-2640-fe0f" + }, + ":woman_gesturing_no_tone5:": { + "category": "people", + "name": "woman gesturing NO: dark skin tone", + "unicode": "1f645-1f3ff-200d-2640-fe0f" + }, + ":woman_gesturing_ok:": { + "category": "people", + "name": "woman gesturing OK", + "unicode": "1f646-200d-2640-fe0f" + }, + ":woman_gesturing_ok_tone1:": { + "category": "people", + "name": "woman gesturing OK: light skin tone", + "unicode": "1f646-1f3fb-200d-2640-fe0f" + }, + ":woman_gesturing_ok_tone2:": { + "category": "people", + "name": "woman gesturing OK: medium-light skin tone", + "unicode": "1f646-1f3fc-200d-2640-fe0f" + }, + ":woman_gesturing_ok_tone3:": { + "category": "people", + "name": "woman gesturing OK: medium skin tone", + "unicode": "1f646-1f3fd-200d-2640-fe0f" + }, + ":woman_gesturing_ok_tone4:": { + "category": "people", + "name": "woman gesturing OK: medium-dark skin tone", + "unicode": "1f646-1f3fe-200d-2640-fe0f" + }, + ":woman_gesturing_ok_tone5:": { + "category": "people", + "name": "woman gesturing OK: dark skin tone", + "unicode": "1f646-1f3ff-200d-2640-fe0f" + }, + ":woman_getting_face_massage:": { + "category": "people", + "name": "woman getting massage", + "unicode": "1f486-200d-2640-fe0f" + }, + ":woman_getting_face_massage_tone1:": { + "category": "people", + "name": "woman getting massage: light skin tone", + "unicode": "1f486-1f3fb-200d-2640-fe0f" + }, + ":woman_getting_face_massage_tone2:": { + "category": "people", + "name": "woman getting massage: medium-light skin tone", + "unicode": "1f486-1f3fc-200d-2640-fe0f" + }, + ":woman_getting_face_massage_tone3:": { + "category": "people", + "name": "woman getting massage: medium skin tone", + "unicode": "1f486-1f3fd-200d-2640-fe0f" + }, + ":woman_getting_face_massage_tone4:": { + "category": "people", + "name": "woman getting massage: medium-dark skin tone", + "unicode": "1f486-1f3fe-200d-2640-fe0f" + }, + ":woman_getting_face_massage_tone5:": { + "category": "people", + "name": "woman getting massage: dark skin tone", + "unicode": "1f486-1f3ff-200d-2640-fe0f" + }, + ":woman_getting_haircut:": { + "category": "people", + "name": "woman getting haircut", + "unicode": "1f487-200d-2640-fe0f" + }, + ":woman_getting_haircut_tone1:": { + "category": "people", + "name": "woman getting haircut: light skin tone", + "unicode": "1f487-1f3fb-200d-2640-fe0f" + }, + ":woman_getting_haircut_tone2:": { + "category": "people", + "name": "woman getting haircut: medium-light skin tone", + "unicode": "1f487-1f3fc-200d-2640-fe0f" + }, + ":woman_getting_haircut_tone3:": { + "category": "people", + "name": "woman getting haircut: medium skin tone", + "unicode": "1f487-1f3fd-200d-2640-fe0f" + }, + ":woman_getting_haircut_tone4:": { + "category": "people", + "name": "woman getting haircut: medium-dark skin tone", + "unicode": "1f487-1f3fe-200d-2640-fe0f" + }, + ":woman_getting_haircut_tone5:": { + "category": "people", + "name": "woman getting haircut: dark skin tone", + "unicode": "1f487-1f3ff-200d-2640-fe0f" + }, + ":woman_golfing:": { + "category": "activity", + "name": "woman golfing", + "unicode": "1f3cc-fe0f-200d-2640-fe0f" + }, + ":woman_golfing_tone1:": { + "category": "activity", + "name": "woman golfing: light skin tone", + "unicode": "1f3cc-1f3fb-200d-2640-fe0f" + }, + ":woman_golfing_tone2:": { + "category": "activity", + "name": "woman golfing: medium-light skin tone", + "unicode": "1f3cc-1f3fc-200d-2640-fe0f" + }, + ":woman_golfing_tone3:": { + "category": "activity", + "name": "woman golfing: medium skin tone", + "unicode": "1f3cc-1f3fd-200d-2640-fe0f" + }, + ":woman_golfing_tone4:": { + "category": "activity", + "name": "woman golfing: medium-dark skin tone", + "unicode": "1f3cc-1f3fe-200d-2640-fe0f" + }, + ":woman_golfing_tone5:": { + "category": "activity", + "name": "woman golfing: dark skin tone", + "unicode": "1f3cc-1f3ff-200d-2640-fe0f" + }, + ":woman_guard:": { + "category": "people", + "name": "woman guard", + "unicode": "1f482-200d-2640-fe0f" + }, + ":woman_guard_tone1:": { + "category": "people", + "name": "woman guard: light skin tone", + "unicode": "1f482-1f3fb-200d-2640-fe0f" + }, + ":woman_guard_tone2:": { + "category": "people", + "name": "woman guard: medium-light skin tone", + "unicode": "1f482-1f3fc-200d-2640-fe0f" + }, + ":woman_guard_tone3:": { + "category": "people", + "name": "woman guard: medium skin tone", + "unicode": "1f482-1f3fd-200d-2640-fe0f" + }, + ":woman_guard_tone4:": { + "category": "people", + "name": "woman guard: medium-dark skin tone", + "unicode": "1f482-1f3fe-200d-2640-fe0f" + }, + ":woman_guard_tone5:": { + "category": "people", + "name": "woman guard: dark skin tone", + "unicode": "1f482-1f3ff-200d-2640-fe0f" + }, + ":woman_health_worker:": { + "category": "people", + "name": "woman health worker", + "unicode": "1f469-200d-2695-fe0f" + }, + ":woman_health_worker_tone1:": { + "category": "people", + "name": "woman health worker: light skin tone", + "unicode": "1f469-1f3fb-200d-2695-fe0f" + }, + ":woman_health_worker_tone2:": { + "category": "people", + "name": "woman health worker: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-2695-fe0f" + }, + ":woman_health_worker_tone3:": { + "category": "people", + "name": "woman health worker: medium skin tone", + "unicode": "1f469-1f3fd-200d-2695-fe0f" + }, + ":woman_health_worker_tone4:": { + "category": "people", + "name": "woman health worker: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-2695-fe0f" + }, + ":woman_health_worker_tone5:": { + "category": "people", + "name": "woman health worker: dark skin tone", + "unicode": "1f469-1f3ff-200d-2695-fe0f" + }, + ":woman_in_lotus_position:": { + "category": "activity", + "name": "woman in lotus position", + "unicode": "1f9d8-200d-2640-fe0f" + }, + ":woman_in_lotus_position_tone1:": { + "category": "activity", + "name": "woman in lotus position: light skin tone", + "unicode": "1f9d8-1f3fb-200d-2640-fe0f" + }, + ":woman_in_lotus_position_tone2:": { + "category": "activity", + "name": "woman in lotus position: medium-light skin tone", + "unicode": "1f9d8-1f3fc-200d-2640-fe0f" + }, + ":woman_in_lotus_position_tone3:": { + "category": "activity", + "name": "woman in lotus position: medium skin tone", + "unicode": "1f9d8-1f3fd-200d-2640-fe0f" + }, + ":woman_in_lotus_position_tone4:": { + "category": "activity", + "name": "woman in lotus position: medium-dark skin tone", + "unicode": "1f9d8-1f3fe-200d-2640-fe0f" + }, + ":woman_in_lotus_position_tone5:": { + "category": "activity", + "name": "woman in lotus position: dark skin tone", + "unicode": "1f9d8-1f3ff-200d-2640-fe0f" + }, + ":woman_in_manual_wheelchair:": { + "category": "people", + "name": "woman in manual wheelchair", + "unicode": "1f469-200d-1f9bd" + }, + ":woman_in_manual_wheelchair_facing_right:": { + "category": "people", + "name": "woman in manual wheelchair facing right", + "unicode": "1f469-200d-1f9bd-200d-27a1-fe0f" + }, + ":woman_in_manual_wheelchair_facing_right_tone1:": { + "category": "people", + "name": "woman in manual wheelchair facing right: light skin tone", + "unicode": "1f469-1f3fb-200d-1f9bd-200d-27a1-fe0f" + }, + ":woman_in_manual_wheelchair_facing_right_tone2:": { + "category": "people", + "name": "woman in manual wheelchair facing right: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f9bd-200d-27a1-fe0f" + }, + ":woman_in_manual_wheelchair_facing_right_tone3:": { + "category": "people", + "name": "woman in manual wheelchair facing right: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f9bd-200d-27a1-fe0f" + }, + ":woman_in_manual_wheelchair_facing_right_tone4:": { + "category": "people", + "name": "woman in manual wheelchair facing right: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f9bd-200d-27a1-fe0f" + }, + ":woman_in_manual_wheelchair_facing_right_tone5:": { + "category": "people", + "name": "woman in manual wheelchair facing right: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f9bd-200d-27a1-fe0f" + }, + ":woman_in_manual_wheelchair_tone1:": { + "category": "people", + "name": "woman in manual wheelchair: light skin tone", + "unicode": "1f469-1f3fb-200d-1f9bd" + }, + ":woman_in_manual_wheelchair_tone2:": { + "category": "people", + "name": "woman in manual wheelchair: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f9bd" + }, + ":woman_in_manual_wheelchair_tone3:": { + "category": "people", + "name": "woman in manual wheelchair: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f9bd" + }, + ":woman_in_manual_wheelchair_tone4:": { + "category": "people", + "name": "woman in manual wheelchair: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f9bd" + }, + ":woman_in_manual_wheelchair_tone5:": { + "category": "people", + "name": "woman in manual wheelchair: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f9bd" + }, + ":woman_in_motorized_wheelchair:": { + "category": "people", + "name": "woman in motorized wheelchair", + "unicode": "1f469-200d-1f9bc" + }, + ":woman_in_motorized_wheelchair_facing_right:": { + "category": "people", + "name": "woman in motorized wheelchair facing right", + "unicode": "1f469-200d-1f9bc-200d-27a1-fe0f" + }, + ":woman_in_motorized_wheelchair_facing_right_tone1:": { + "category": "people", + "name": "woman in motorized wheelchair facing right: light skin tone", + "unicode": "1f469-1f3fb-200d-1f9bc-200d-27a1-fe0f" + }, + ":woman_in_motorized_wheelchair_facing_right_tone2:": { + "category": "people", + "name": "woman in motorized wheelchair facing right: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f9bc-200d-27a1-fe0f" + }, + ":woman_in_motorized_wheelchair_facing_right_tone3:": { + "category": "people", + "name": "woman in motorized wheelchair facing right: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f9bc-200d-27a1-fe0f" + }, + ":woman_in_motorized_wheelchair_facing_right_tone4:": { + "category": "people", + "name": "woman in motorized wheelchair facing right: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f9bc-200d-27a1-fe0f" + }, + ":woman_in_motorized_wheelchair_facing_right_tone5:": { + "category": "people", + "name": "woman in motorized wheelchair facing right: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f9bc-200d-27a1-fe0f" + }, + ":woman_in_motorized_wheelchair_tone1:": { + "category": "people", + "name": "woman in motorized wheelchair: light skin tone", + "unicode": "1f469-1f3fb-200d-1f9bc" + }, + ":woman_in_motorized_wheelchair_tone2:": { + "category": "people", + "name": "woman in motorized wheelchair: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f9bc" + }, + ":woman_in_motorized_wheelchair_tone3:": { + "category": "people", + "name": "woman in motorized wheelchair: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f9bc" + }, + ":woman_in_motorized_wheelchair_tone4:": { + "category": "people", + "name": "woman in motorized wheelchair: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f9bc" + }, + ":woman_in_motorized_wheelchair_tone5:": { + "category": "people", + "name": "woman in motorized wheelchair: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f9bc" + }, + ":woman_in_santa_hat:": { + "category": "people", + "name": "woman in santa hat", + "unicode": "1f469-200d-1f384" + }, + ":woman_in_santa_hat_tone1:": { + "category": "people", + "name": "woman in santa hat: light skin tone", + "unicode": "1f469-1f3fb-200d-1f384" + }, + ":woman_in_santa_hat_tone2:": { + "category": "people", + "name": "woman in santa hat: medium-light skin tone", + "unicode": "1f468-1f3ff-200d-1f384" + }, + ":woman_in_santa_hat_tone3:": { + "category": "people", + "name": "woman in santa hat: medium skin tone", + "unicode": "1f469-1f3fe-200d-1f384" + }, + ":woman_in_santa_hat_tone4:": { + "category": "people", + "name": "woman in santa hat: medium-dark skin tone", + "unicode": "1f469-1f3fd-200d-1f384" + }, + ":woman_in_santa_hat_tone5:": { + "category": "people", + "name": "woman in santa hat: dark skin tone", + "unicode": "1f469-1f3fc-200d-1f384" + }, + ":woman_in_steamy_room:": { + "category": "people", + "name": "woman in steamy room", + "unicode": "1f9d6-200d-2640-fe0f" + }, + ":woman_in_steamy_room_tone1:": { + "category": "people", + "name": "woman in steamy room: light skin tone", + "unicode": "1f9d6-1f3fb-200d-2640-fe0f" + }, + ":woman_in_steamy_room_tone2:": { + "category": "people", + "name": "woman in steamy room: medium-light skin tone", + "unicode": "1f9d6-1f3fc-200d-2640-fe0f" + }, + ":woman_in_steamy_room_tone3:": { + "category": "people", + "name": "woman in steamy room: medium skin tone", + "unicode": "1f9d6-1f3fd-200d-2640-fe0f" + }, + ":woman_in_steamy_room_tone4:": { + "category": "people", + "name": "woman in steamy room: medium-dark skin tone", + "unicode": "1f9d6-1f3fe-200d-2640-fe0f" + }, + ":woman_in_steamy_room_tone5:": { + "category": "people", + "name": "woman in steamy room: dark skin tone", + "unicode": "1f9d6-1f3ff-200d-2640-fe0f" + }, + ":woman_in_tuxedo:": { + "category": "people", + "name": "woman in tuxedo", + "unicode": "1f935-200d-2640-fe0f" + }, + ":woman_in_tuxedo_tone1:": { + "category": "people", + "name": "woman in tuxedo: light skin tone", + "unicode": "1f935-1f3fb-200d-2640-fe0f" + }, + ":woman_in_tuxedo_tone2:": { + "category": "people", + "name": "woman in tuxedo: medium-light skin tone", + "unicode": "1f935-1f3fc-200d-2640-fe0f" + }, + ":woman_in_tuxedo_tone3:": { + "category": "people", + "name": "woman in tuxedo: medium skin tone", + "unicode": "1f935-1f3fd-200d-2640-fe0f" + }, + ":woman_in_tuxedo_tone4:": { + "category": "people", + "name": "woman in tuxedo: medium-dark skin tone", + "unicode": "1f935-1f3fe-200d-2640-fe0f" + }, + ":woman_in_tuxedo_tone5:": { + "category": "people", + "name": "woman in tuxedo: dark skin tone", + "unicode": "1f935-1f3ff-200d-2640-fe0f" + }, + ":woman_judge:": { + "category": "people", + "name": "woman judge", + "unicode": "1f469-200d-2696-fe0f" + }, + ":woman_judge_tone1:": { + "category": "people", + "name": "woman judge: light skin tone", + "unicode": "1f469-1f3fb-200d-2696-fe0f" + }, + ":woman_judge_tone2:": { + "category": "people", + "name": "woman judge: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-2696-fe0f" + }, + ":woman_judge_tone3:": { + "category": "people", + "name": "woman judge: medium skin tone", + "unicode": "1f469-1f3fd-200d-2696-fe0f" + }, + ":woman_judge_tone4:": { + "category": "people", + "name": "woman judge: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-2696-fe0f" + }, + ":woman_judge_tone5:": { + "category": "people", + "name": "woman judge: dark skin tone", + "unicode": "1f469-1f3ff-200d-2696-fe0f" + }, + ":woman_juggling:": { + "category": "activity", + "name": "woman juggling", + "unicode": "1f939-200d-2640-fe0f" + }, + ":woman_juggling_tone1:": { + "category": "activity", + "name": "woman juggling: light skin tone", + "unicode": "1f939-1f3fb-200d-2640-fe0f" + }, + ":woman_juggling_tone2:": { + "category": "activity", + "name": "woman juggling: medium-light skin tone", + "unicode": "1f939-1f3fc-200d-2640-fe0f" + }, + ":woman_juggling_tone3:": { + "category": "activity", + "name": "woman juggling: medium skin tone", + "unicode": "1f939-1f3fd-200d-2640-fe0f" + }, + ":woman_juggling_tone4:": { + "category": "activity", + "name": "woman juggling: medium-dark skin tone", + "unicode": "1f939-1f3fe-200d-2640-fe0f" + }, + ":woman_juggling_tone5:": { + "category": "activity", + "name": "woman juggling: dark skin tone", + "unicode": "1f939-1f3ff-200d-2640-fe0f" + }, + ":woman_kneeling:": { + "category": "people", + "name": "woman kneeling", + "unicode": "1f9ce-200d-2640-fe0f" + }, + ":woman_kneeling_facing_right:": { + "category": "people", + "name": "woman kneeling facing right", + "unicode": "1f9ce-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_kneeling_facing_right_tone1:": { + "category": "people", + "name": "woman kneeling facing right: light skin tone", + "unicode": "1f9ce-1f3fb-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_kneeling_facing_right_tone2:": { + "category": "people", + "name": "woman kneeling facing right: medium-light skin tone", + "unicode": "1f9ce-1f3fc-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_kneeling_facing_right_tone3:": { + "category": "people", + "name": "woman kneeling facing right: medium skin tone", + "unicode": "1f9ce-1f3fd-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_kneeling_facing_right_tone4:": { + "category": "people", + "name": "woman kneeling facing right: medium-dark skin tone", + "unicode": "1f9ce-1f3fe-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_kneeling_facing_right_tone5:": { + "category": "people", + "name": "woman kneeling facing right: dark skin tone", + "unicode": "1f9ce-1f3ff-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_kneeling_tone1:": { + "category": "people", + "name": "woman kneeling: light skin tone", + "unicode": "1f9ce-1f3fb-200d-2640-fe0f" + }, + ":woman_kneeling_tone2:": { + "category": "people", + "name": "woman kneeling: medium-light skin tone", + "unicode": "1f9ce-1f3fc-200d-2640-fe0f" + }, + ":woman_kneeling_tone3:": { + "category": "people", + "name": "woman kneeling: medium skin tone", + "unicode": "1f9ce-1f3fd-200d-2640-fe0f" + }, + ":woman_kneeling_tone4:": { + "category": "people", + "name": "woman kneeling: medium-dark skin tone", + "unicode": "1f9ce-1f3fe-200d-2640-fe0f" + }, + ":woman_kneeling_tone5:": { + "category": "people", + "name": "woman kneeling: dark skin tone", + "unicode": "1f9ce-1f3ff-200d-2640-fe0f" + }, + ":woman_leviate_tone2:": { + "category": "people", + "name": "woman in business suit levitating: medium-light skin tone", + "unicode": "1f574-1f3fc-200d-2640-fe0f" + }, + ":woman_leviate_tone3:": { + "category": "people", + "name": "woman in business suit levitating: medium skin tone", + "unicode": "1f574-1f3fd-200d-2640-fe0f" + }, + ":woman_leviate_tone4:": { + "category": "people", + "name": "woman in business suit levitating: medium-dark skin tone", + "unicode": "1f574-1f3fe-200d-2640-fe0f" + }, + ":woman_leviate_tone5:": { + "category": "people", + "name": "woman in business suit levitating: dark skin tone", + "unicode": "1f574-1f3ff-200d-2640-fe0f" + }, + ":woman_levitate:": { + "category": "people", + "name": "woman in business suit levitating", + "unicode": "1f574-fe0f-200d-2640-fe0f" + }, + ":woman_levitate_tone1:": { + "category": "people", + "name": "woman in business suit levitating: light skin tone", + "unicode": "1f574-1f3fb-200d-2640-fe0f" + }, + ":woman_lifting_weights:": { + "category": "activity", + "name": "woman lifting weights", + "unicode": "1f3cb-fe0f-200d-2640-fe0f" + }, + ":woman_lifting_weights_tone1:": { + "category": "activity", + "name": "woman lifting weights: light skin tone", + "unicode": "1f3cb-1f3fb-200d-2640-fe0f" + }, + ":woman_lifting_weights_tone2:": { + "category": "activity", + "name": "woman lifting weights: medium-light skin tone", + "unicode": "1f3cb-1f3fc-200d-2640-fe0f" + }, + ":woman_lifting_weights_tone3:": { + "category": "activity", + "name": "woman lifting weights: medium skin tone", + "unicode": "1f3cb-1f3fd-200d-2640-fe0f" + }, + ":woman_lifting_weights_tone4:": { + "category": "activity", + "name": "woman lifting weights: medium-dark skin tone", + "unicode": "1f3cb-1f3fe-200d-2640-fe0f" + }, + ":woman_lifting_weights_tone5:": { + "category": "activity", + "name": "woman lifting weights: dark skin tone", + "unicode": "1f3cb-1f3ff-200d-2640-fe0f" + }, + ":woman_mage:": { + "category": "people", + "name": "woman mage", + "unicode": "1f9d9-200d-2640-fe0f" + }, + ":woman_mage_tone1:": { + "category": "people", + "name": "woman mage: light skin tone", + "unicode": "1f9d9-1f3fb-200d-2640-fe0f" + }, + ":woman_mage_tone2:": { + "category": "people", + "name": "woman mage: medium-light skin tone", + "unicode": "1f9d9-1f3fc-200d-2640-fe0f" + }, + ":woman_mage_tone3:": { + "category": "people", + "name": "woman mage: medium skin tone", + "unicode": "1f9d9-1f3fd-200d-2640-fe0f" + }, + ":woman_mage_tone4:": { + "category": "people", + "name": "woman mage: medium-dark skin tone", + "unicode": "1f9d9-1f3fe-200d-2640-fe0f" + }, + ":woman_mage_tone5:": { + "category": "people", + "name": "woman mage: dark skin tone", + "unicode": "1f9d9-1f3ff-200d-2640-fe0f" + }, + ":woman_mechanic:": { + "category": "people", + "name": "woman mechanic", + "unicode": "1f469-200d-1f527" + }, + ":woman_mechanic_tone1:": { + "category": "people", + "name": "woman mechanic: light skin tone", + "unicode": "1f469-1f3fb-200d-1f527" + }, + ":woman_mechanic_tone2:": { + "category": "people", + "name": "woman mechanic: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f527" + }, + ":woman_mechanic_tone3:": { + "category": "people", + "name": "woman mechanic: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f527" + }, + ":woman_mechanic_tone4:": { + "category": "people", + "name": "woman mechanic: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f527" + }, + ":woman_mechanic_tone5:": { + "category": "people", + "name": "woman mechanic: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f527" + }, + ":woman_mountain_biking:": { + "category": "activity", + "name": "woman mountain biking", + "unicode": "1f6b5-200d-2640-fe0f" + }, + ":woman_mountain_biking_tone1:": { + "category": "activity", + "name": "woman mountain biking: light skin tone", + "unicode": "1f6b5-1f3fb-200d-2640-fe0f" + }, + ":woman_mountain_biking_tone2:": { + "category": "activity", + "name": "woman mountain biking: medium-light skin tone", + "unicode": "1f6b5-1f3fc-200d-2640-fe0f" + }, + ":woman_mountain_biking_tone3:": { + "category": "activity", + "name": "woman mountain biking: medium skin tone", + "unicode": "1f6b5-1f3fd-200d-2640-fe0f" + }, + ":woman_mountain_biking_tone4:": { + "category": "activity", + "name": "woman mountain biking: medium-dark skin tone", + "unicode": "1f6b5-1f3fe-200d-2640-fe0f" + }, + ":woman_mountain_biking_tone5:": { + "category": "activity", + "name": "woman mountain biking: dark skin tone", + "unicode": "1f6b5-1f3ff-200d-2640-fe0f" + }, + ":woman_office_worker:": { + "category": "people", + "name": "woman office worker", + "unicode": "1f469-200d-1f4bc" + }, + ":woman_office_worker_tone1:": { + "category": "people", + "name": "woman office worker: light skin tone", + "unicode": "1f469-1f3fb-200d-1f4bc" + }, + ":woman_office_worker_tone2:": { + "category": "people", + "name": "woman office worker: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f4bc" + }, + ":woman_office_worker_tone3:": { + "category": "people", + "name": "woman office worker: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f4bc" + }, + ":woman_office_worker_tone4:": { + "category": "people", + "name": "woman office worker: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f4bc" + }, + ":woman_office_worker_tone5:": { + "category": "people", + "name": "woman office worker: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f4bc" + }, + ":woman_pilot:": { + "category": "people", + "name": "woman pilot", + "unicode": "1f469-200d-2708-fe0f" + }, + ":woman_pilot_tone1:": { + "category": "people", + "name": "woman pilot: light skin tone", + "unicode": "1f469-1f3fb-200d-2708-fe0f" + }, + ":woman_pilot_tone2:": { + "category": "people", + "name": "woman pilot: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-2708-fe0f" + }, + ":woman_pilot_tone3:": { + "category": "people", + "name": "woman pilot: medium skin tone", + "unicode": "1f469-1f3fd-200d-2708-fe0f" + }, + ":woman_pilot_tone4:": { + "category": "people", + "name": "woman pilot: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-2708-fe0f" + }, + ":woman_pilot_tone5:": { + "category": "people", + "name": "woman pilot: dark skin tone", + "unicode": "1f469-1f3ff-200d-2708-fe0f" + }, + ":woman_playing_handball:": { + "category": "activity", + "name": "woman playing handball", + "unicode": "1f93e-200d-2640-fe0f" + }, + ":woman_playing_handball_tone1:": { + "category": "activity", + "name": "woman playing handball: light skin tone", + "unicode": "1f93e-1f3fb-200d-2640-fe0f" + }, + ":woman_playing_handball_tone2:": { + "category": "activity", + "name": "woman playing handball: medium-light skin tone", + "unicode": "1f93e-1f3fc-200d-2640-fe0f" + }, + ":woman_playing_handball_tone3:": { + "category": "activity", + "name": "woman playing handball: medium skin tone", + "unicode": "1f93e-1f3fd-200d-2640-fe0f" + }, + ":woman_playing_handball_tone4:": { + "category": "activity", + "name": "woman playing handball: medium-dark skin tone", + "unicode": "1f93e-1f3fe-200d-2640-fe0f" + }, + ":woman_playing_handball_tone5:": { + "category": "activity", + "name": "woman playing handball: dark skin tone", + "unicode": "1f93e-1f3ff-200d-2640-fe0f" + }, + ":woman_playing_water_polo:": { + "category": "activity", + "name": "woman playing water polo", + "unicode": "1f93d-200d-2640-fe0f" + }, + ":woman_playing_water_polo_tone1:": { + "category": "activity", + "name": "woman playing water polo: light skin tone", + "unicode": "1f93d-1f3fb-200d-2640-fe0f" + }, + ":woman_playing_water_polo_tone2:": { + "category": "activity", + "name": "woman playing water polo: medium-light skin tone", + "unicode": "1f93d-1f3fc-200d-2640-fe0f" + }, + ":woman_playing_water_polo_tone3:": { + "category": "activity", + "name": "woman playing water polo: medium skin tone", + "unicode": "1f93d-1f3fd-200d-2640-fe0f" + }, + ":woman_playing_water_polo_tone4:": { + "category": "activity", + "name": "woman playing water polo: medium-dark skin tone", + "unicode": "1f93d-1f3fe-200d-2640-fe0f" + }, + ":woman_playing_water_polo_tone5:": { + "category": "activity", + "name": "woman playing water polo: dark skin tone", + "unicode": "1f93d-1f3ff-200d-2640-fe0f" + }, + ":woman_police_officer:": { + "category": "people", + "name": "woman police officer", + "unicode": "1f46e-200d-2640-fe0f" + }, + ":woman_police_officer_tone1:": { + "category": "people", + "name": "woman police officer: light skin tone", + "unicode": "1f46e-1f3fb-200d-2640-fe0f" + }, + ":woman_police_officer_tone2:": { + "category": "people", + "name": "woman police officer: medium-light skin tone", + "unicode": "1f46e-1f3fc-200d-2640-fe0f" + }, + ":woman_police_officer_tone3:": { + "category": "people", + "name": "woman police officer: medium skin tone", + "unicode": "1f46e-1f3fd-200d-2640-fe0f" + }, + ":woman_police_officer_tone4:": { + "category": "people", + "name": "woman police officer: medium-dark skin tone", + "unicode": "1f46e-1f3fe-200d-2640-fe0f" + }, + ":woman_police_officer_tone5:": { + "category": "people", + "name": "woman police officer: dark skin tone", + "unicode": "1f46e-1f3ff-200d-2640-fe0f" + }, + ":woman_pouting:": { + "category": "people", + "name": "woman pouting", + "unicode": "1f64e-200d-2640-fe0f" + }, + ":woman_pouting_tone1:": { + "category": "people", + "name": "woman pouting: light skin tone", + "unicode": "1f64e-1f3fb-200d-2640-fe0f" + }, + ":woman_pouting_tone2:": { + "category": "people", + "name": "woman pouting: medium-light skin tone", + "unicode": "1f64e-1f3fc-200d-2640-fe0f" + }, + ":woman_pouting_tone3:": { + "category": "people", + "name": "woman pouting: medium skin tone", + "unicode": "1f64e-1f3fd-200d-2640-fe0f" + }, + ":woman_pouting_tone4:": { + "category": "people", + "name": "woman pouting: medium-dark skin tone", + "unicode": "1f64e-1f3fe-200d-2640-fe0f" + }, + ":woman_pouting_tone5:": { + "category": "people", + "name": "woman pouting: dark skin tone", + "unicode": "1f64e-1f3ff-200d-2640-fe0f" + }, + ":woman_raising_hand:": { + "category": "people", + "name": "woman raising hand", + "unicode": "1f64b-200d-2640-fe0f" + }, + ":woman_raising_hand_tone1:": { + "category": "people", + "name": "woman raising hand: light skin tone", + "unicode": "1f64b-1f3fb-200d-2640-fe0f" + }, + ":woman_raising_hand_tone2:": { + "category": "people", + "name": "woman raising hand: medium-light skin tone", + "unicode": "1f64b-1f3fc-200d-2640-fe0f" + }, + ":woman_raising_hand_tone3:": { + "category": "people", + "name": "woman raising hand: medium skin tone", + "unicode": "1f64b-1f3fd-200d-2640-fe0f" + }, + ":woman_raising_hand_tone4:": { + "category": "people", + "name": "woman raising hand: medium-dark skin tone", + "unicode": "1f64b-1f3fe-200d-2640-fe0f" + }, + ":woman_raising_hand_tone5:": { + "category": "people", + "name": "woman raising hand: dark skin tone", + "unicode": "1f64b-1f3ff-200d-2640-fe0f" + }, + ":woman_red_haired:": { + "category": "people", + "name": "woman: red hair", + "unicode": "1f469-200d-1f9b0" + }, + ":woman_red_haired_tone1:": { + "category": "people", + "name": "woman, red haired: light skin tone", + "unicode": "1f469-1f3fb-200d-1f9b0" + }, + ":woman_red_haired_tone2:": { + "category": "people", + "name": "woman, red haired: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f9b0" + }, + ":woman_red_haired_tone3:": { + "category": "people", + "name": "woman, red haired: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f9b0" + }, + ":woman_red_haired_tone4:": { + "category": "people", + "name": "woman, red haired: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f9b0" + }, + ":woman_red_haired_tone5:": { + "category": "people", + "name": "woman, red haired: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f9b0" + }, + ":woman_rowing_boat:": { + "category": "activity", + "name": "woman rowing boat", + "unicode": "1f6a3-200d-2640-fe0f" + }, + ":woman_rowing_boat_tone1:": { + "category": "activity", + "name": "woman rowing boat: light skin tone", + "unicode": "1f6a3-1f3fb-200d-2640-fe0f" + }, + ":woman_rowing_boat_tone2:": { + "category": "activity", + "name": "woman rowing boat: medium-light skin tone", + "unicode": "1f6a3-1f3fc-200d-2640-fe0f" + }, + ":woman_rowing_boat_tone3:": { + "category": "activity", + "name": "woman rowing boat: medium skin tone", + "unicode": "1f6a3-1f3fd-200d-2640-fe0f" + }, + ":woman_rowing_boat_tone4:": { + "category": "activity", + "name": "woman rowing boat: medium-dark skin tone", + "unicode": "1f6a3-1f3fe-200d-2640-fe0f" + }, + ":woman_rowing_boat_tone5:": { + "category": "activity", + "name": "woman rowing boat: dark skin tone", + "unicode": "1f6a3-1f3ff-200d-2640-fe0f" + }, + ":woman_running:": { + "category": "people", + "name": "woman running", + "unicode": "1f3c3-200d-2640-fe0f" + }, + ":woman_running_facing_right:": { + "category": "people", + "name": "woman running facing right", + "unicode": "1f3c3-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_running_facing_right_tone1:": { + "category": "people", + "name": "woman running facing right: light skin tone", + "unicode": "1f3c3-1f3fb-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_running_facing_right_tone2:": { + "category": "people", + "name": "woman running facing right: medium-light skin tone", + "unicode": "1f3c3-1f3fc-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_running_facing_right_tone3:": { + "category": "people", + "name": "woman running facing right: medium skin tone", + "unicode": "1f3c3-1f3fd-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_running_facing_right_tone4:": { + "category": "people", + "name": "woman running facing right: medium-dark skin tone", + "unicode": "1f3c3-1f3fe-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_running_facing_right_tone5:": { + "category": "people", + "name": "woman running facing right: dark skin tone", + "unicode": "1f3c3-1f3ff-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_running_tone1:": { + "category": "people", + "name": "woman running: light skin tone", + "unicode": "1f3c3-1f3fb-200d-2640-fe0f" + }, + ":woman_running_tone2:": { + "category": "people", + "name": "woman running: medium-light skin tone", + "unicode": "1f3c3-1f3fc-200d-2640-fe0f" + }, + ":woman_running_tone3:": { + "category": "people", + "name": "woman running: medium skin tone", + "unicode": "1f3c3-1f3fd-200d-2640-fe0f" + }, + ":woman_running_tone4:": { + "category": "people", + "name": "woman running: medium-dark skin tone", + "unicode": "1f3c3-1f3fe-200d-2640-fe0f" + }, + ":woman_running_tone5:": { + "category": "people", + "name": "woman running: dark skin tone", + "unicode": "1f3c3-1f3ff-200d-2640-fe0f" + }, + ":woman_scientist:": { + "category": "people", + "name": "woman scientist", + "unicode": "1f469-200d-1f52c" + }, + ":woman_scientist_tone1:": { + "category": "people", + "name": "woman scientist: light skin tone", + "unicode": "1f469-1f3fb-200d-1f52c" + }, + ":woman_scientist_tone2:": { + "category": "people", + "name": "woman scientist: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f52c" + }, + ":woman_scientist_tone3:": { + "category": "people", + "name": "woman scientist: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f52c" + }, + ":woman_scientist_tone4:": { + "category": "people", + "name": "woman scientist: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f52c" + }, + ":woman_scientist_tone5:": { + "category": "people", + "name": "woman scientist: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f52c" + }, + ":woman_shrugging:": { + "category": "people", + "name": "woman shrugging", + "unicode": "1f937-200d-2640-fe0f" + }, + ":woman_shrugging_tone1:": { + "category": "people", + "name": "woman shrugging: light skin tone", + "unicode": "1f937-1f3fb-200d-2640-fe0f" + }, + ":woman_shrugging_tone2:": { + "category": "people", + "name": "woman shrugging: medium-light skin tone", + "unicode": "1f937-1f3fc-200d-2640-fe0f" + }, + ":woman_shrugging_tone3:": { + "category": "people", + "name": "woman shrugging: medium skin tone", + "unicode": "1f937-1f3fd-200d-2640-fe0f" + }, + ":woman_shrugging_tone4:": { + "category": "people", + "name": "woman shrugging: medium-dark skin tone", + "unicode": "1f937-1f3fe-200d-2640-fe0f" + }, + ":woman_shrugging_tone5:": { + "category": "people", + "name": "woman shrugging: dark skin tone", + "unicode": "1f937-1f3ff-200d-2640-fe0f" + }, + ":woman_singer:": { + "category": "people", + "name": "woman singer", + "unicode": "1f469-200d-1f3a4" + }, + ":woman_singer_tone1:": { + "category": "people", + "name": "woman singer: light skin tone", + "unicode": "1f469-1f3fb-200d-1f3a4" + }, + ":woman_singer_tone2:": { + "category": "people", + "name": "woman singer: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f3a4" + }, + ":woman_singer_tone3:": { + "category": "people", + "name": "woman singer: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f3a4" + }, + ":woman_singer_tone4:": { + "category": "people", + "name": "woman singer: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f3a4" + }, + ":woman_singer_tone5:": { + "category": "people", + "name": "woman singer: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f3a4" + }, + ":woman_standing:": { + "category": "people", + "name": "woman standing", + "unicode": "1f9cd-200d-2640-fe0f" + }, + ":woman_standing_tone1:": { + "category": "people", + "name": "woman standing: light skin tone", + "unicode": "1f9cd-1f3fb-200d-2640-fe0f" + }, + ":woman_standing_tone2:": { + "category": "people", + "name": "woman standing: medium-light skin tone", + "unicode": "1f9cd-1f3fc-200d-2640-fe0f" + }, + ":woman_standing_tone3:": { + "category": "people", + "name": "woman standing: medium skin tone", + "unicode": "1f9cd-1f3fd-200d-2640-fe0f" + }, + ":woman_standing_tone4:": { + "category": "people", + "name": "woman standing: medium-dark skin tone", + "unicode": "1f9cd-1f3fe-200d-2640-fe0f" + }, + ":woman_standing_tone5:": { + "category": "people", + "name": "woman standing: dark skin tone", + "unicode": "1f9cd-1f3ff-200d-2640-fe0f" + }, + ":woman_student:": { + "category": "people", + "name": "woman student", + "unicode": "1f469-200d-1f393" + }, + ":woman_student_tone1:": { + "category": "people", + "name": "woman student: light skin tone", + "unicode": "1f469-1f3fb-200d-1f393" + }, + ":woman_student_tone2:": { + "category": "people", + "name": "woman student: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f393" + }, + ":woman_student_tone3:": { + "category": "people", + "name": "woman student: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f393" + }, + ":woman_student_tone4:": { + "category": "people", + "name": "woman student: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f393" + }, + ":woman_student_tone5:": { + "category": "people", + "name": "woman student: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f393" + }, + ":woman_superhero:": { + "category": "people", + "name": "woman superhero", + "unicode": "1f9b8-200d-2640-fe0f" + }, + ":woman_superhero_tone1:": { + "category": "people", + "name": "woman superhero: light skin tone", + "unicode": "1f9b8-1f3fb-200d-2640-fe0f" + }, + ":woman_superhero_tone2:": { + "category": "people", + "name": "woman superhero: medium-light skin tone", + "unicode": "1f9b8-1f3fc-200d-2640-fe0f" + }, + ":woman_superhero_tone3:": { + "category": "people", + "name": "woman superhero: medium skin tone", + "unicode": "1f9b8-1f3fd-200d-2640-fe0f" + }, + ":woman_superhero_tone4:": { + "category": "people", + "name": "woman superhero: medium-dark skin tone", + "unicode": "1f9b8-1f3fe-200d-2640-fe0f" + }, + ":woman_superhero_tone5:": { + "category": "people", + "name": "woman superhero: dark skin tone", + "unicode": "1f9b8-1f3ff-200d-2640-fe0f" + }, + ":woman_supervillain:": { + "category": "people", + "name": "woman supervillain", + "unicode": "1f9b9-200d-2640-fe0f" + }, + ":woman_supervillain_tone1:": { + "category": "people", + "name": "woman supervillain: light skin tone", + "unicode": "1f9b9-1f3fb-200d-2640-fe0f" + }, + ":woman_supervillain_tone2:": { + "category": "people", + "name": "woman supervillain: medium-light skin tone", + "unicode": "1f9b9-1f3fc-200d-2640-fe0f" + }, + ":woman_supervillain_tone3:": { + "category": "people", + "name": "woman supervillain: medium skin tone", + "unicode": "1f9b9-1f3fd-200d-2640-fe0f" + }, + ":woman_supervillain_tone4:": { + "category": "people", + "name": "woman supervillain: medium-dark skin tone", + "unicode": "1f9b9-1f3fe-200d-2640-fe0f" + }, + ":woman_supervillain_tone5:": { + "category": "people", + "name": "woman supervillain: dark skin tone", + "unicode": "1f9b9-1f3ff-200d-2640-fe0f" + }, + ":woman_surfing:": { + "category": "activity", + "name": "woman surfing", + "unicode": "1f3c4-200d-2640-fe0f" + }, + ":woman_surfing_tone1:": { + "category": "activity", + "name": "woman surfing: light skin tone", + "unicode": "1f3c4-1f3fb-200d-2640-fe0f" + }, + ":woman_surfing_tone2:": { + "category": "activity", + "name": "woman surfing: medium-light skin tone", + "unicode": "1f3c4-1f3fc-200d-2640-fe0f" + }, + ":woman_surfing_tone3:": { + "category": "activity", + "name": "woman surfing: medium skin tone", + "unicode": "1f3c4-1f3fd-200d-2640-fe0f" + }, + ":woman_surfing_tone4:": { + "category": "activity", + "name": "woman surfing: medium-dark skin tone", + "unicode": "1f3c4-1f3fe-200d-2640-fe0f" + }, + ":woman_surfing_tone5:": { + "category": "activity", + "name": "woman surfing: dark skin tone", + "unicode": "1f3c4-1f3ff-200d-2640-fe0f" + }, + ":woman_swimming:": { + "category": "activity", + "name": "woman swimming", + "unicode": "1f3ca-200d-2640-fe0f" + }, + ":woman_swimming_tone1:": { + "category": "activity", + "name": "woman swimming: light skin tone", + "unicode": "1f3ca-1f3fb-200d-2640-fe0f" + }, + ":woman_swimming_tone2:": { + "category": "activity", + "name": "woman swimming: medium-light skin tone", + "unicode": "1f3ca-1f3fc-200d-2640-fe0f" + }, + ":woman_swimming_tone3:": { + "category": "activity", + "name": "woman swimming: medium skin tone", + "unicode": "1f3ca-1f3fd-200d-2640-fe0f" + }, + ":woman_swimming_tone4:": { + "category": "activity", + "name": "woman swimming: medium-dark skin tone", + "unicode": "1f3ca-1f3fe-200d-2640-fe0f" + }, + ":woman_swimming_tone5:": { + "category": "activity", + "name": "woman swimming: dark skin tone", + "unicode": "1f3ca-1f3ff-200d-2640-fe0f" + }, + ":woman_teacher:": { + "category": "people", + "name": "woman teacher", + "unicode": "1f469-200d-1f3eb" + }, + ":woman_teacher_tone1:": { + "category": "people", + "name": "woman teacher: light skin tone", + "unicode": "1f469-1f3fb-200d-1f3eb" + }, + ":woman_teacher_tone2:": { + "category": "people", + "name": "woman teacher: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f3eb" + }, + ":woman_teacher_tone3:": { + "category": "people", + "name": "woman teacher: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f3eb" + }, + ":woman_teacher_tone4:": { + "category": "people", + "name": "woman teacher: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f3eb" + }, + ":woman_teacher_tone5:": { + "category": "people", + "name": "woman teacher: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f3eb" + }, + ":woman_technologist:": { + "category": "people", + "name": "woman technologist", + "unicode": "1f469-200d-1f4bb" + }, + ":woman_technologist_tone1:": { + "category": "people", + "name": "woman technologist: light skin tone", + "unicode": "1f469-1f3fb-200d-1f4bb" + }, + ":woman_technologist_tone2:": { + "category": "people", + "name": "woman technologist: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f4bb" + }, + ":woman_technologist_tone3:": { + "category": "people", + "name": "woman technologist: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f4bb" + }, + ":woman_technologist_tone4:": { + "category": "people", + "name": "woman technologist: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f4bb" + }, + ":woman_technologist_tone5:": { + "category": "people", + "name": "woman technologist: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f4bb" + }, + ":woman_tipping_hand:": { + "category": "people", + "name": "woman tipping hand", + "unicode": "1f481-200d-2640-fe0f" + }, + ":woman_tipping_hand_tone1:": { + "category": "people", + "name": "woman tipping hand: light skin tone", + "unicode": "1f481-1f3fb-200d-2640-fe0f" + }, + ":woman_tipping_hand_tone2:": { + "category": "people", + "name": "woman tipping hand: medium-light skin tone", + "unicode": "1f481-1f3fc-200d-2640-fe0f" + }, + ":woman_tipping_hand_tone3:": { + "category": "people", + "name": "woman tipping hand: medium skin tone", + "unicode": "1f481-1f3fd-200d-2640-fe0f" + }, + ":woman_tipping_hand_tone4:": { + "category": "people", + "name": "woman tipping hand: medium-dark skin tone", + "unicode": "1f481-1f3fe-200d-2640-fe0f" + }, + ":woman_tipping_hand_tone5:": { + "category": "people", + "name": "woman tipping hand: dark skin tone", + "unicode": "1f481-1f3ff-200d-2640-fe0f" + }, + ":woman_tone1:": { + "category": "people", + "name": "woman: light skin tone", + "unicode": "1f469-1f3fb" + }, + ":woman_tone1_beard:": { + "category": "people", + "name": "woman: light skin tone, beard", + "unicode": "1f9d4-1f3fb-200d-2640-fe0f" + }, + ":woman_tone2:": { + "category": "people", + "name": "woman: medium-light skin tone", + "unicode": "1f469-1f3fc" + }, + ":woman_tone2_beard:": { + "category": "people", + "name": "woman: medium-light skin tone, beard", + "unicode": "1f9d4-1f3fc-200d-2640-fe0f" + }, + ":woman_tone3:": { + "category": "people", + "name": "woman: medium skin tone", + "unicode": "1f469-1f3fd" + }, + ":woman_tone3_beard:": { + "category": "people", + "name": "woman: medium skin tone, beard", + "unicode": "1f9d4-1f3fd-200d-2640-fe0f" + }, + ":woman_tone4:": { + "category": "people", + "name": "woman: medium-dark skin tone", + "unicode": "1f469-1f3fe" + }, + ":woman_tone4_beard:": { + "category": "people", + "name": "woman: medium-dark skin tone, beard", + "unicode": "1f9d4-1f3fe-200d-2640-fe0f" + }, + ":woman_tone5:": { + "category": "people", + "name": "woman: dark skin tone", + "unicode": "1f469-1f3ff" + }, + ":woman_tone5_beard:": { + "category": "people", + "name": "woman: dark skin tone, beard", + "unicode": "1f9d4-1f3ff-200d-2640-fe0f" + }, + ":woman_vampire:": { + "category": "people", + "name": "woman vampire", + "unicode": "1f9db-200d-2640-fe0f" + }, + ":woman_vampire_tone1:": { + "category": "people", + "name": "woman vampire: light skin tone", + "unicode": "1f9db-1f3fb-200d-2640-fe0f" + }, + ":woman_vampire_tone2:": { + "category": "people", + "name": "woman vampire: medium-light skin tone", + "unicode": "1f9db-1f3fc-200d-2640-fe0f" + }, + ":woman_vampire_tone3:": { + "category": "people", + "name": "woman vampire: medium skin tone", + "unicode": "1f9db-1f3fd-200d-2640-fe0f" + }, + ":woman_vampire_tone4:": { + "category": "people", + "name": "woman vampire: medium-dark skin tone", + "unicode": "1f9db-1f3fe-200d-2640-fe0f" + }, + ":woman_vampire_tone5:": { + "category": "people", + "name": "woman vampire: dark skin tone", + "unicode": "1f9db-1f3ff-200d-2640-fe0f" + }, + ":woman_walking:": { + "category": "people", + "name": "woman walking", + "unicode": "1f6b6-200d-2640-fe0f" + }, + ":woman_walking_facing_right:": { + "category": "people", + "name": "woman walking facing right", + "unicode": "1f6b6-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_walking_facing_right_tone1:": { + "category": "people", + "name": "woman walking facing right: light skin tone", + "unicode": "1f6b6-1f3fb-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_walking_facing_right_tone2:": { + "category": "people", + "name": "woman walking facing right: medium-light skin tone", + "unicode": "1f6b6-1f3fc-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_walking_facing_right_tone3:": { + "category": "people", + "name": "woman walking facing right: medium skin tone", + "unicode": "1f6b6-1f3fd-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_walking_facing_right_tone4:": { + "category": "people", + "name": "woman walking facing right: medium-dark skin tone", + "unicode": "1f6b6-1f3fe-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_walking_facing_right_tone5:": { + "category": "people", + "name": "woman walking facing right: dark skin tone", + "unicode": "1f6b6-1f3ff-200d-2640-fe0f-200d-27a1-fe0f" + }, + ":woman_walking_tone1:": { + "category": "people", + "name": "woman walking: light skin tone", + "unicode": "1f6b6-1f3fb-200d-2640-fe0f" + }, + ":woman_walking_tone2:": { + "category": "people", + "name": "woman walking: medium-light skin tone", + "unicode": "1f6b6-1f3fc-200d-2640-fe0f" + }, + ":woman_walking_tone3:": { + "category": "people", + "name": "woman walking: medium skin tone", + "unicode": "1f6b6-1f3fd-200d-2640-fe0f" + }, + ":woman_walking_tone4:": { + "category": "people", + "name": "woman walking: medium-dark skin tone", + "unicode": "1f6b6-1f3fe-200d-2640-fe0f" + }, + ":woman_walking_tone5:": { + "category": "people", + "name": "woman walking: dark skin tone", + "unicode": "1f6b6-1f3ff-200d-2640-fe0f" + }, + ":woman_wearing_turban:": { + "category": "people", + "name": "woman wearing turban", + "unicode": "1f473-200d-2640-fe0f" + }, + ":woman_wearing_turban_tone1:": { + "category": "people", + "name": "woman wearing turban: light skin tone", + "unicode": "1f473-1f3fb-200d-2640-fe0f" + }, + ":woman_wearing_turban_tone2:": { + "category": "people", + "name": "woman wearing turban: medium-light skin tone", + "unicode": "1f473-1f3fc-200d-2640-fe0f" + }, + ":woman_wearing_turban_tone3:": { + "category": "people", + "name": "woman wearing turban: medium skin tone", + "unicode": "1f473-1f3fd-200d-2640-fe0f" + }, + ":woman_wearing_turban_tone4:": { + "category": "people", + "name": "woman wearing turban: medium-dark skin tone", + "unicode": "1f473-1f3fe-200d-2640-fe0f" + }, + ":woman_wearing_turban_tone5:": { + "category": "people", + "name": "woman wearing turban: dark skin tone", + "unicode": "1f473-1f3ff-200d-2640-fe0f" + }, + ":woman_white_haired:": { + "category": "people", + "name": "woman: white hair", + "unicode": "1f469-200d-1f9b3" + }, + ":woman_white_haired_tone1:": { + "category": "people", + "name": "woman, white haired: light skin tone", + "unicode": "1f469-1f3fb-200d-1f9b3" + }, + ":woman_white_haired_tone2:": { + "category": "people", + "name": "woman, white haired: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f9b3" + }, + ":woman_white_haired_tone3:": { + "category": "people", + "name": "woman, white haired: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f9b3" + }, + ":woman_white_haired_tone4:": { + "category": "people", + "name": "woman, white haired: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f9b3" + }, + ":woman_white_haired_tone5:": { + "category": "people", + "name": "woman, white haired: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f9b3" + }, + ":woman_with_headscarf:": { + "category": "people", + "name": "woman with headscarf", + "unicode": "1f9d5" + }, + ":woman_with_headscarf_tone1:": { + "category": "people", + "name": "woman with headscarf: light skin tone", + "unicode": "1f9d5-1f3fb" + }, + ":woman_with_headscarf_tone2:": { + "category": "people", + "name": "woman with headscarf: medium-light skin tone", + "unicode": "1f9d5-1f3fc" + }, + ":woman_with_headscarf_tone3:": { + "category": "people", + "name": "woman with headscarf: medium skin tone", + "unicode": "1f9d5-1f3fd" + }, + ":woman_with_headscarf_tone4:": { + "category": "people", + "name": "woman with headscarf: medium-dark skin tone", + "unicode": "1f9d5-1f3fe" + }, + ":woman_with_headscarf_tone5:": { + "category": "people", + "name": "woman with headscarf: dark skin tone", + "unicode": "1f9d5-1f3ff" + }, + ":woman_with_probing_cane:": { + "category": "people", + "name": "woman with probing cane", + "unicode": "1f469-200d-1f9af" + }, + ":woman_with_probing_cane_tone1:": { + "category": "people", + "name": "woman with probing cane: light skin tone", + "unicode": "1f469-1f3fb-200d-1f9af" + }, + ":woman_with_probing_cane_tone2:": { + "category": "people", + "name": "woman with probing cane: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f9af" + }, + ":woman_with_probing_cane_tone3:": { + "category": "people", + "name": "woman with probing cane: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f9af" + }, + ":woman_with_probing_cane_tone4:": { + "category": "people", + "name": "woman with probing cane: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f9af" + }, + ":woman_with_probing_cane_tone5:": { + "category": "people", + "name": "woman with probing cane: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f9af" + }, + ":woman_with_veil:": { + "category": "people", + "name": "woman with veil", + "unicode": "1f470-200d-2640-fe0f" + }, + ":woman_with_veil_tone1:": { + "category": "people", + "name": "woman with veil: light skin tone", + "unicode": "1f470-1f3fb-200d-2640-fe0f" + }, + ":woman_with_veil_tone2:": { + "category": "people", + "name": "woman with veil: medium-light skin tone", + "unicode": "1f470-1f3fc-200d-2640-fe0f" + }, + ":woman_with_veil_tone3:": { + "category": "people", + "name": "woman with veil: medium skin tone", + "unicode": "1f470-1f3fd-200d-2640-fe0f" + }, + ":woman_with_veil_tone4:": { + "category": "people", + "name": "woman with veil: medium-dark skin tone", + "unicode": "1f470-1f3fe-200d-2640-fe0f" + }, + ":woman_with_veil_tone5:": { + "category": "people", + "name": "woman with veil: dark skin tone", + "unicode": "1f470-1f3ff-200d-2640-fe0f" + }, + ":woman_with_white_cane_facing_right:": { + "category": "people", + "name": "woman with white cane facing right", + "unicode": "1f469-200d-1f9af-200d-27a1-fe0f" + }, + ":woman_with_white_cane_facing_right_tone1:": { + "category": "people", + "name": "woman with white cane facing right: light skin tone", + "unicode": "1f469-1f3fb-200d-1f9af-200d-27a1-fe0f" + }, + ":woman_with_white_cane_facing_right_tone2:": { + "category": "people", + "name": "woman with white cane facing right: medium-light skin tone", + "unicode": "1f469-1f3fc-200d-1f9af-200d-27a1-fe0f" + }, + ":woman_with_white_cane_facing_right_tone3:": { + "category": "people", + "name": "woman with white cane facing right: medium skin tone", + "unicode": "1f469-1f3fd-200d-1f9af-200d-27a1-fe0f" + }, + ":woman_with_white_cane_facing_right_tone4:": { + "category": "people", + "name": "woman with white cane facing right: medium-dark skin tone", + "unicode": "1f469-1f3fe-200d-1f9af-200d-27a1-fe0f" + }, + ":woman_with_white_cane_facing_right_tone5:": { + "category": "people", + "name": "woman with white cane facing right: dark skin tone", + "unicode": "1f469-1f3ff-200d-1f9af-200d-27a1-fe0f" + }, + ":woman_zombie:": { + "category": "people", + "name": "woman zombie", + "unicode": "1f9df-200d-2640-fe0f" + }, + ":womans_clothes:": { + "category": "people", + "name": "woman\u2019s clothes", + "unicode": "1f45a" + }, + ":womans_flat_shoe:": { + "category": "people", + "name": "flat shoe", + "unicode": "1f97f" + }, + ":womans_hat:": { + "category": "people", + "name": "woman\u2019s hat", + "unicode": "1f452" + }, + ":women_holding_hands_tone1:": { + "category": "people", + "name": "women holding hands: light skin tone", + "unicode": "1f46d-1f3fb" + }, + ":women_holding_hands_tone1_tone2:": { + "category": "people", + "name": "women holding hands: light skin tone, medium-light skin tone", + "unicode": "1f469-1f3fb-200d-1f91d-200d-1f469-1f3fc" + }, + ":women_holding_hands_tone1_tone3:": { + "category": "people", + "name": "women holding hands: light skin tone, medium skin tone", + "unicode": "1f469-1f3fb-200d-1f91d-200d-1f469-1f3fd" + }, + ":women_holding_hands_tone1_tone4:": { + "category": "people", + "name": "women holding hands: light skin tone, medium-dark skin tone", + "unicode": "1f469-1f3fb-200d-1f91d-200d-1f469-1f3fe" + }, + ":women_holding_hands_tone1_tone5:": { + "category": "people", + "name": "women holding hands: light skin tone, dark skin tone", + "unicode": "1f469-1f3fb-200d-1f91d-200d-1f469-1f3ff" + }, + ":women_holding_hands_tone2:": { + "category": "people", + "name": "women holding hands: medium-light skin tone", + "unicode": "1f46d-1f3fc" + }, + ":women_holding_hands_tone2_tone1:": { + "category": "people", + "name": "women holding hands: medium-light skin tone, light skin tone", + "unicode": "1f469-1f3fc-200d-1f91d-200d-1f469-1f3fb" + }, + ":women_holding_hands_tone2_tone3:": { + "category": "people", + "name": "women holding hands: medium-light skin tone, medium skin tone", + "unicode": "1f469-1f3fc-200d-1f91d-200d-1f469-1f3fd" + }, + ":women_holding_hands_tone2_tone4:": { + "category": "people", + "name": "women holding hands: medium-light skin tone, medium-dark skin tone", + "unicode": "1f469-1f3fc-200d-1f91d-200d-1f469-1f3fe" + }, + ":women_holding_hands_tone2_tone5:": { + "category": "people", + "name": "women holding hands: medium-light skin tone, dark skin tone", + "unicode": "1f469-1f3fc-200d-1f91d-200d-1f469-1f3ff" + }, + ":women_holding_hands_tone3:": { + "category": "people", + "name": "women holding hands: medium skin tone", + "unicode": "1f46d-1f3fd" + }, + ":women_holding_hands_tone3_tone1:": { + "category": "people", + "name": "women holding hands: medium skin tone, light skin tone", + "unicode": "1f469-1f3fd-200d-1f91d-200d-1f469-1f3fb" + }, + ":women_holding_hands_tone3_tone2:": { + "category": "people", + "name": "women holding hands: medium skin tone, medium-light skin tone", + "unicode": "1f469-1f3fd-200d-1f91d-200d-1f469-1f3fc" + }, + ":women_holding_hands_tone3_tone4:": { + "category": "people", + "name": "women holding hands: medium skin tone, medium-dark skin tone", + "unicode": "1f469-1f3fd-200d-1f91d-200d-1f469-1f3fe" + }, + ":women_holding_hands_tone3_tone5:": { + "category": "people", + "name": "women holding hands: medium skin tone, dark skin tone", + "unicode": "1f469-1f3fd-200d-1f91d-200d-1f469-1f3ff" + }, + ":women_holding_hands_tone4:": { + "category": "people", + "name": "women holding hands: medium-dark skin tone", + "unicode": "1f46d-1f3fe" + }, + ":women_holding_hands_tone4_tone1:": { + "category": "people", + "name": "women holding hands: medium-dark skin tone, light skin tone", + "unicode": "1f469-1f3fe-200d-1f91d-200d-1f469-1f3fb" + }, + ":women_holding_hands_tone4_tone2:": { + "category": "people", + "name": "women holding hands: medium dark skin tone, medium light skin tone", + "unicode": "1f469-1f3fe-200d-1f91d-200d-1f469-1f3fc" + }, + ":women_holding_hands_tone4_tone3:": { + "category": "people", + "name": "women holding hands: medium-dark skin tone, medium skin tone", + "unicode": "1f469-1f3fe-200d-1f91d-200d-1f469-1f3fd" + }, + ":women_holding_hands_tone4_tone5:": { + "category": "people", + "name": "women holding hands: medium-dark skin tone, dark skin tone", + "unicode": "1f469-1f3fe-200d-1f91d-200d-1f469-1f3ff" + }, + ":women_holding_hands_tone5:": { + "category": "people", + "name": "women holding hands: dark skin tone", + "unicode": "1f46d-1f3ff" + }, + ":women_holding_hands_tone5_tone1:": { + "category": "people", + "name": "women holding hands: dark skin tone, light skin tone", + "unicode": "1f469-1f3ff-200d-1f91d-200d-1f469-1f3fb" + }, + ":women_holding_hands_tone5_tone2:": { + "category": "people", + "name": "women holding hands: dark skin tone, medium-light skin tone", + "unicode": "1f469-1f3ff-200d-1f91d-200d-1f469-1f3fc" + }, + ":women_holding_hands_tone5_tone3:": { + "category": "people", + "name": "women holding hands: dark skin tone, medium skin tone", + "unicode": "1f469-1f3ff-200d-1f91d-200d-1f469-1f3fd" + }, + ":women_holding_hands_tone5_tone4:": { + "category": "people", + "name": "women holding hands: dark skin tone, medium-dark skin tone", + "unicode": "1f469-1f3ff-200d-1f91d-200d-1f469-1f3fe" + }, + ":women_with_bunny_ears_partying:": { + "category": "people", + "name": "women with bunny ears", + "unicode": "1f46f-200d-2640-fe0f" + }, + ":women_wrestling:": { + "category": "activity", + "name": "women wrestling", + "unicode": "1f93c-200d-2640-fe0f" + }, + ":womens:": { + "category": "symbols", + "name": "women\u2019s room", + "unicode": "1f6ba" + }, + ":wood:": { + "category": "nature", + "name": "wood", + "unicode": "1fab5" + }, + ":woozy_face:": { + "category": "people", + "name": "woozy face", + "unicode": "1f974" + }, + ":worm:": { + "category": "nature", + "name": "worm", + "unicode": "1fab1" + }, + ":worried:": { + "category": "people", + "name": "worried face", + "unicode": "1f61f" + }, + ":wrench:": { + "category": "objects", + "name": "wrench", + "unicode": "1f527" + }, + ":writing_hand:": { + "category": "people", + "name": "writing hand", + "unicode": "270d" + }, + ":writing_hand_tone1:": { + "category": "people", + "name": "writing hand: light skin tone", + "unicode": "270d-1f3fb" + }, + ":writing_hand_tone2:": { + "category": "people", + "name": "writing hand: medium-light skin tone", + "unicode": "270d-1f3fc" + }, + ":writing_hand_tone3:": { + "category": "people", + "name": "writing hand: medium skin tone", + "unicode": "270d-1f3fd" + }, + ":writing_hand_tone4:": { + "category": "people", + "name": "writing hand: medium-dark skin tone", + "unicode": "270d-1f3fe" + }, + ":writing_hand_tone5:": { + "category": "people", + "name": "writing hand: dark skin tone", + "unicode": "270d-1f3ff" + }, + ":x:": { + "category": "symbols", + "name": "cross mark", + "unicode": "274c" + }, + ":x_ray:": { + "category": "objects", + "name": "x-ray", + "unicode": "1fa7b" + }, + ":yarn:": { + "category": "people", + "name": "yarn", + "unicode": "1f9f6" + }, + ":yawning_face:": { + "category": "people", + "name": "yawning face", + "unicode": "1f971" + }, + ":yellow_circle:": { + "category": "symbols", + "name": "yellow circle", + "unicode": "1f7e1" + }, + ":yellow_heart:": { + "category": "symbols", + "name": "yellow heart", + "unicode": "1f49b" + }, + ":yellow_square:": { + "category": "symbols", + "name": "yellow square", + "unicode": "1f7e8" + }, + ":yen:": { + "category": "objects", + "name": "yen banknote", + "unicode": "1f4b4" + }, + ":yin_yang:": { + "category": "symbols", + "name": "yin yang", + "unicode": "262f" + }, + ":yo_yo:": { + "category": "activity", + "name": "yo-yo", + "unicode": "1fa80" + }, + ":yum:": { + "category": "people", + "name": "face savoring food", + "unicode": "1f60b" + }, + ":zany_face:": { + "category": "people", + "name": "zany face", + "unicode": "1f92a" + }, + ":zap:": { + "category": "nature", + "name": "high voltage", + "unicode": "26a1" + }, + ":zebra:": { + "category": "nature", + "name": "zebra", + "unicode": "1f993" + }, + ":zero:": { + "category": "symbols", + "name": "keycap: 0", + "unicode": "30-20e3", + "unicode_alt": "0030-20e3" + }, + ":zipper_mouth:": { + "category": "people", + "name": "zipper-mouth face", + "unicode": "1f910" + }, + ":zombie:": { + "category": "people", + "name": "zombie", + "unicode": "1f9df" + }, + ":zzz:": { + "category": "symbols", + "name": "zzz", + "unicode": "1f4a4" + } +} +aliases = { + ":+1:": ":thumbsup:", + ":+1_tone1:": ":thumbsup_tone1:", + ":+1_tone2:": ":thumbsup_tone2:", + ":+1_tone3:": ":thumbsup_tone3:", + ":+1_tone4:": ":thumbsup_tone4:", + ":+1_tone5:": ":thumbsup_tone5:", + ":-1:": ":thumbsdown:", + ":-1_tone1:": ":thumbsdown_tone1:", + ":-1_tone2:": ":thumbsdown_tone2:", + ":-1_tone3:": ":thumbsdown_tone3:", + ":-1_tone4:": ":thumbsdown_tone4:", + ":-1_tone5:": ":thumbsdown_tone5:", + ":ac:": ":flag_ac:", + ":ad:": ":flag_ad:", + ":admission_tickets:": ":tickets:", + ":adult_dark_skin_tone:": ":adult_tone5:", + ":adult_light_skin_tone:": ":adult_tone1:", + ":adult_medium_dark_skin_tone:": ":adult_tone4:", + ":adult_medium_light_skin_tone:": ":adult_tone2:", + ":adult_medium_skin_tone:": ":adult_tone3:", + ":ae:": ":flag_ae:", + ":af:": ":flag_af:", + ":ag:": ":flag_ag:", + ":ai:": ":flag_ai:", + ":al:": ":flag_al:", + ":alien_monster:": ":space_invader:", + ":am:": ":flag_am:", + ":angry_face:": ":angry:", + ":antenna_bars:": ":signal_strength:", + ":ao:": ":flag_ao:", + ":aq:": ":flag_aq:", + ":ar:": ":flag_ar:", + ":archery:": ":bow_and_arrow:", + ":artist_dark_skin_tone:": ":artist_tone5:", + ":artist_light_skin_tone:": ":artist_tone1:", + ":artist_medium_dark_skin_tone:": ":artist_tone4:", + ":artist_medium_light_skin_tone:": ":artist_tone2:", + ":artist_medium_skin_tone:": ":artist_tone3:", + ":as:": ":flag_as:", + ":astronaut_dark_skin_tone:": ":astronaut_tone5:", + ":astronaut_light_skin_tone:": ":astronaut_tone1:", + ":astronaut_medium_dark_skin_tone:": ":astronaut_tone4:", + ":astronaut_medium_light_skin_tone:": ":astronaut_tone2:", + ":astronaut_medium_skin_tone:": ":astronaut_tone3:", + ":at:": ":flag_at:", + ":atom_symbol:": ":atom:", + ":au:": ":flag_au:", + ":automobile:": ":red_car:", + ":aw:": ":flag_aw:", + ":ax:": ":flag_ax:", + ":az:": ":flag_az:", + ":ba:": ":flag_ba:", + ":baby_angel:": ":angel:", + ":back_arrow:": ":back:", + ":back_of_hand:": ":raised_back_of_hand:", + ":back_of_hand_tone1:": ":raised_back_of_hand_tone1:", + ":back_of_hand_tone2:": ":raised_back_of_hand_tone2:", + ":back_of_hand_tone3:": ":raised_back_of_hand_tone3:", + ":back_of_hand_tone4:": ":raised_back_of_hand_tone4:", + ":back_of_hand_tone5:": ":raised_back_of_hand_tone5:", + ":backpack:": ":school_satchel:", + ":baguette_bread:": ":french_bread:", + ":balance_scale:": ":scales:", + ":ballot_box_with_ballot:": ":ballot_box:", + ":barber_pole:": ":barber:", + ":basketball_player:": ":person_bouncing_ball:", + ":basketball_player_tone1:": ":person_bouncing_ball_tone1:", + ":basketball_player_tone2:": ":person_bouncing_ball_tone2:", + ":basketball_player_tone3:": ":person_bouncing_ball_tone3:", + ":basketball_player_tone4:": ":person_bouncing_ball_tone4:", + ":basketball_player_tone5:": ":person_bouncing_ball_tone5:", + ":bb:": ":flag_bb:", + ":bd:": ":flag_bd:", + ":be:": ":flag_be:", + ":beach_with_umbrella:": ":beach:", + ":bearded_person_dark_skin_tone:": ":bearded_person_tone5:", + ":bearded_person_light_skin_tone:": ":bearded_person_tone1:", + ":bearded_person_medium_dark_skin_tone:": ":bearded_person_tone4:", + ":bearded_person_medium_light_skin_tone:": ":bearded_person_tone2:", + ":bearded_person_medium_skin_tone:": ":bearded_person_tone3:", + ":beating_heart:": ":heartbeat:", + ":beer_mug:": ":beer:", + ":bellhop_bell:": ":bellhop:", + ":bento_box:": ":bento:", + ":bf:": ":flag_bf:", + ":bg:": ":flag_bg:", + ":bh:": ":flag_bh:", + ":bi:": ":flag_bi:", + ":bicycle:": ":bike:", + ":bicyclist:": ":person_biking:", + ":bicyclist_tone1:": ":person_biking_tone1:", + ":bicyclist_tone2:": ":person_biking_tone2:", + ":bicyclist_tone3:": ":person_biking_tone3:", + ":bicyclist_tone4:": ":person_biking_tone4:", + ":bicyclist_tone5:": ":person_biking_tone5:", + ":biohazard_sign:": ":biohazard:", + ":birthday_cake:": ":birthday:", + ":bj:": ":flag_bj:", + ":bl:": ":flag_bl:", + ":black_flag:": ":flag_black:", + ":blond-haired_man_dark_skin_tone:": ":blond-haired_man_tone5:", + ":blond-haired_man_light_skin_tone:": ":blond-haired_man_tone1:", + ":blond-haired_man_medium_dark_skin_tone:": ":blond-haired_man_tone4:", + ":blond-haired_man_medium_light_skin_tone:": ":blond-haired_man_tone2:", + ":blond-haired_man_medium_skin_tone:": ":blond-haired_man_tone3:", + ":blond-haired_woman_dark_skin_tone:": ":blond-haired_woman_tone5:", + ":blond-haired_woman_light_skin_tone:": ":blond-haired_woman_tone1:", + ":blond-haired_woman_medium_dark_skin_tone:": ":blond-haired_woman_tone4:", + ":blond-haired_woman_medium_light_skin_tone:": ":blond-haired_woman_tone2:", + ":blond-haired_woman_medium_skin_tone:": ":blond-haired_woman_tone3:", + ":bm:": ":flag_bm:", + ":bn:": ":flag_bn:", + ":bo:": ":flag_bo:", + ":bottle_with_popping_cork:": ":champagne:", + ":bow:": ":person_bowing:", + ":bow_tone1:": ":person_bowing_tone1:", + ":bow_tone2:": ":person_bowing_tone2:", + ":bow_tone3:": ":person_bowing_tone3:", + ":bow_tone4:": ":person_bowing_tone4:", + ":bow_tone5:": ":person_bowing_tone5:", + ":boxing_gloves:": ":boxing_glove:", + ":bq:": ":flag_bq:", + ":br:": ":flag_br:", + ":breast_feeding_dark_skin_tone:": ":breast_feeding_tone5:", + ":breast_feeding_light_skin_tone:": ":breast_feeding_tone1:", + ":breast_feeding_medium_dark_skin_tone:": ":breast_feeding_tone4:", + ":breast_feeding_medium_light_skin_tone:": ":breast_feeding_tone2:", + ":breast_feeding_medium_skin_tone:": ":breast_feeding_tone3:", + ":brick:": ":bricks:", + ":bs:": ":flag_bs:", + ":bt:": ":flag_bt:", + ":building_construction:": ":construction_site:", + ":bullet_train:": ":bullettrain_front:", + ":bus_stop:": ":busstop:", + ":bv:": ":flag_bv:", + ":bw:": ":flag_bw:", + ":by:": ":flag_by:", + ":bz:": ":flag_bz:", + ":ca:": ":flag_ca:", + ":call_me_hand:": ":call_me:", + ":call_me_hand_tone1:": ":call_me_tone1:", + ":call_me_hand_tone2:": ":call_me_tone2:", + ":call_me_hand_tone3:": ":call_me_tone3:", + ":call_me_hand_tone4:": ":call_me_tone4:", + ":call_me_hand_tone5:": ":call_me_tone5:", + ":card_file_box:": ":card_box:", + ":card_index_dividers:": ":dividers:", + ":carp_streamer:": ":flags:", + ":cartwheel:": ":person_doing_cartwheel:", + ":cartwheel_tone1:": ":person_doing_cartwheel_tone1:", + ":cartwheel_tone2:": ":person_doing_cartwheel_tone2:", + ":cartwheel_tone3:": ":person_doing_cartwheel_tone3:", + ":cartwheel_tone4:": ":person_doing_cartwheel_tone4:", + ":cartwheel_tone5:": ":person_doing_cartwheel_tone5:", + ":castle:": ":european_castle:", + ":cat_face:": ":cat:", + ":cc:": ":flag_cc:", + ":cf:": ":flag_cf:", + ":cg:": ":flag_cg:", + ":ch:": ":flag_ch:", + ":check_mark:": ":heavy_check_mark:", + ":cheese_wedge:": ":cheese:", + ":child_dark_skin_tone:": ":child_tone5:", + ":child_light_skin_tone:": ":child_tone1:", + ":child_medium_dark_skin_tone:": ":child_tone4:", + ":child_medium_light_skin_tone:": ":child_tone2:", + ":child_medium_skin_tone:": ":child_tone3:", + ":chile:": ":flag_cl:", + ":ci:": ":flag_ci:", + ":cigarette:": ":smoking:", + ":circled_m:": ":m:", + ":city_sunrise:": ":city_sunset:", + ":ck:": ":flag_ck:", + ":clamp:": ":compression:", + ":clapper_board:": ":clapper:", + ":clinking_glass:": ":champagne_glass:", + ":cloud_with_lightning:": ":cloud_lightning:", + ":cloud_with_rain:": ":cloud_rain:", + ":cloud_with_snow:": ":cloud_snow:", + ":cloud_with_tornado:": ":cloud_tornado:", + ":clown_face:": ":clown:", + ":club_suit:": ":clubs:", + ":clutch_bag:": ":pouch:", + ":cm:": ":flag_cm:", + ":cn:": ":flag_cn:", + ":co:": ":flag_co:", + ":collision:": ":boom:", + ":computer_disk:": ":minidisc:", + ":confused_face:": ":confused:", + ":congo:": ":flag_cd:", + ":cook_dark_skin_tone:": ":cook_tone5:", + ":cook_light_skin_tone:": ":cook_tone1:", + ":cook_medium_dark_skin_tone:": ":cook_tone4:", + ":cook_medium_light_skin_tone:": ":cook_tone2:", + ":cook_medium_skin_tone:": ":cook_tone3:", + ":cooked_rice:": ":rice:", + ":cop:": ":police_officer:", + ":cop_tone1:": ":police_officer_tone1:", + ":cop_tone2:": ":police_officer_tone2:", + ":cop_tone3:": ":police_officer_tone3:", + ":cop_tone4:": ":police_officer_tone4:", + ":cop_tone5:": ":police_officer_tone5:", + ":couch_and_lamp:": ":couch:", + ":couple_with_heart_dark_skin_tone:": ":couple_with_heart_tone5:", + ":couple_with_heart_light_skin_tone:": ":couple_with_heart_tone1:", + ":couple_with_heart_man_man_dark_skin_tone:": ":couple_with_heart_man_man_tone5:", + ":couple_with_heart_man_man_dark_skin_tone_light_skin_tone:": ":couple_with_heart_man_man_tone5_tone1:", + ":couple_with_heart_man_man_dark_skin_tone_medium_dark_skin_tone:": ":couple_with_heart_man_man_tone5_tone4:", + ":couple_with_heart_man_man_dark_skin_tone_medium_light_skin_tone:": ":couple_with_heart_man_man_tone5_tone2:", + ":couple_with_heart_man_man_dark_skin_tone_medium_skin_tone:": ":couple_with_heart_man_man_tone5_tone3:", + ":couple_with_heart_man_man_light_skin_tone:": ":couple_with_heart_man_man_tone1:", + ":couple_with_heart_man_man_light_skin_tone_dark_skin_tone:": ":couple_with_heart_man_man_tone1_tone5:", + ":couple_with_heart_man_man_light_skin_tone_medium_dark_skin_tone:": ":couple_with_heart_man_man_tone1_tone4:", + ":couple_with_heart_man_man_light_skin_tone_medium_light_skin_tone:": ":couple_with_heart_man_man_tone1_tone2:", + ":couple_with_heart_man_man_light_skin_tone_medium_skin_tone:": ":couple_with_heart_man_man_tone1_tone3:", + ":couple_with_heart_man_man_medium_dark_skin_tone:": ":couple_with_heart_man_man_tone4:", + ":couple_with_heart_man_man_medium_dark_skin_tone_dark_skin_tone:": ":couple_with_heart_man_man_tone4_tone5:", + ":couple_with_heart_man_man_medium_dark_skin_tone_light_skin_tone:": ":couple_with_heart_man_man_tone4_tone1:", + ":couple_with_heart_man_man_medium_dark_skin_tone_medium_light_skin_tone:": ":couple_with_heart_man_man_tone4_tone2:", + ":couple_with_heart_man_man_medium_dark_skin_tone_medium_skin_tone:": ":couple_with_heart_man_man_tone4_tone3:", + ":couple_with_heart_man_man_medium_light_skin_tone:": ":couple_with_heart_man_man_tone2:", + ":couple_with_heart_man_man_medium_light_skin_tone_dark_skin_tone:": ":couple_with_heart_man_man_tone2_tone5:", + ":couple_with_heart_man_man_medium_light_skin_tone_light_skin_tone:": ":couple_with_heart_man_man_tone2_tone1:", + ":couple_with_heart_man_man_medium_light_skin_tone_medium_dark_skin_tone:": ":couple_with_heart_man_man_tone2_tone4:", + ":couple_with_heart_man_man_medium_light_skin_tone_medium_skin_tone:": ":couple_with_heart_man_man_tone2_tone3:", + ":couple_with_heart_man_man_medium_skin_tone:": ":couple_with_heart_man_man_tone3:", + ":couple_with_heart_man_man_medium_skin_tone_dark_skin_tone:": ":couple_with_heart_man_man_tone3_tone5:", + ":couple_with_heart_man_man_medium_skin_tone_light_skin_tone:": ":couple_with_heart_man_man_tone3_tone1:", + ":couple_with_heart_man_man_medium_skin_tone_medium_dark_skin_tone:": ":couple_with_heart_man_man_tone3_tone4:", + ":couple_with_heart_man_man_medium_skin_tone_medium_light_skin_tone:": ":couple_with_heart_man_man_tone3_tone2:", + ":couple_with_heart_medium_dark_skin_tone:": ":couple_with_heart_tone4:", + ":couple_with_heart_medium_light_skin_tone:": ":couple_with_heart_tone2:", + ":couple_with_heart_medium_skin_tone:": ":couple_with_heart_tone3:", + ":couple_with_heart_mm:": ":couple_mm:", + ":couple_with_heart_person_person_dark_skin_tone_light_skin_tone:": ":couple_with_heart_person_person_tone5_tone1:", + ":couple_with_heart_person_person_dark_skin_tone_medium_dark_skin_tone:": ":couple_with_heart_person_person_tone5_tone4:", + ":couple_with_heart_person_person_dark_skin_tone_medium_light_skin_tone:": ":couple_with_heart_person_person_tone5_tone2:", + ":couple_with_heart_person_person_dark_skin_tone_medium_skin_tone:": ":couple_with_heart_person_person_tone5_tone3:", + ":couple_with_heart_person_person_light_skin_tone_dark_skin_tone:": ":couple_with_heart_person_person_tone1_tone5:", + ":couple_with_heart_person_person_light_skin_tone_medium_dark_skin_tone:": ":couple_with_heart_person_person_tone1_tone4:", + ":couple_with_heart_person_person_light_skin_tone_medium_light_skin_tone:": ":couple_with_heart_person_person_tone1_tone2:", + ":couple_with_heart_person_person_light_skin_tone_medium_skin_tone:": ":couple_with_heart_person_person_tone1_tone3:", + ":couple_with_heart_person_person_medium_dark_skin_tone_dark_skin_tone:": ":couple_with_heart_person_person_tone4_tone5:", + ":couple_with_heart_person_person_medium_dark_skin_tone_light_skin_tone:": ":couple_with_heart_person_person_tone4_tone1:", + ":couple_with_heart_person_person_medium_dark_skin_tone_medium_light_skin_tone:": ":couple_with_heart_person_person_tone4_tone2:", + ":couple_with_heart_person_person_medium_dark_skin_tone_medium_skin_tone:": ":couple_with_heart_person_person_tone4_tone3:", + ":couple_with_heart_person_person_medium_light_skin_tone_dark_skin_tone:": ":couple_with_heart_person_person_tone2_tone5:", + ":couple_with_heart_person_person_medium_light_skin_tone_light_skin_tone:": ":couple_with_heart_person_person_tone2_tone1:", + ":couple_with_heart_person_person_medium_light_skin_tone_medium_dark_skin_tone:": ":couple_with_heart_person_person_tone2_tone4:", + ":couple_with_heart_person_person_medium_light_skin_tone_medium_skin_tone:": ":couple_with_heart_person_person_tone2_tone3:", + ":couple_with_heart_person_person_medium_skin_tone_dark_skin_tone:": ":couple_with_heart_person_person_tone3_tone5:", + ":couple_with_heart_person_person_medium_skin_tone_light_skin_tone:": ":couple_with_heart_person_person_tone3_tone1:", + ":couple_with_heart_person_person_medium_skin_tone_medium_dark_skin_tone:": ":couple_with_heart_person_person_tone3_tone4:", + ":couple_with_heart_person_person_medium_skin_tone_medium_light_skin_tone:": ":couple_with_heart_person_person_tone3_tone2:", + ":couple_with_heart_woman_man_dark_skin_tone:": ":couple_with_heart_woman_man_tone5:", + ":couple_with_heart_woman_man_dark_skin_tone_light_skin_tone:": ":couple_with_heart_woman_man_tone5_tone1:", + ":couple_with_heart_woman_man_dark_skin_tone_medium_dark_skin_tone:": ":couple_with_heart_woman_man_tone5_tone4:", + ":couple_with_heart_woman_man_dark_skin_tone_medium_light_skin_tone:": ":couple_with_heart_woman_man_tone5_tone2:", + ":couple_with_heart_woman_man_dark_skin_tone_medium_skin_tone:": ":couple_with_heart_woman_man_tone5_tone3:", + ":couple_with_heart_woman_man_light_skin_tone:": ":couple_with_heart_woman_man_tone1:", + ":couple_with_heart_woman_man_light_skin_tone_dark_skin_tone:": ":couple_with_heart_woman_man_tone1_tone5:", + ":couple_with_heart_woman_man_light_skin_tone_medium_dark_skin_tone:": ":couple_with_heart_woman_man_tone1_tone4:", + ":couple_with_heart_woman_man_light_skin_tone_medium_light_skin_tone:": ":couple_with_heart_woman_man_tone1_tone2:", + ":couple_with_heart_woman_man_light_skin_tone_medium_skin_tone:": ":couple_with_heart_woman_man_tone1_tone3:", + ":couple_with_heart_woman_man_medium_dark_skin_tone:": ":couple_with_heart_woman_man_tone4:", + ":couple_with_heart_woman_man_medium_dark_skin_tone_dark_skin_tone:": ":couple_with_heart_woman_man_tone4_tone5:", + ":couple_with_heart_woman_man_medium_dark_skin_tone_light_skin_tone:": ":couple_with_heart_woman_man_tone4_tone1:", + ":couple_with_heart_woman_man_medium_dark_skin_tone_medium_light_skin_tone:": ":couple_with_heart_woman_man_tone4_tone2:", + ":couple_with_heart_woman_man_medium_dark_skin_tone_medium_skin_tone:": ":couple_with_heart_woman_man_tone4_tone3:", + ":couple_with_heart_woman_man_medium_light_skin_tone:": ":couple_with_heart_woman_man_tone2:", + ":couple_with_heart_woman_man_medium_light_skin_tone_dark_skin_tone:": ":couple_with_heart_woman_man_tone2_tone5:", + ":couple_with_heart_woman_man_medium_light_skin_tone_light_skin_tone:": ":couple_with_heart_woman_man_tone2_tone1:", + ":couple_with_heart_woman_man_medium_light_skin_tone_medium_dark_skin_tone:": ":couple_with_heart_woman_man_tone2_tone4:", + ":couple_with_heart_woman_man_medium_light_skin_tone_medium_skin_tone:": ":couple_with_heart_woman_man_tone2_tone3:", + ":couple_with_heart_woman_man_medium_skin_tone:": ":couple_with_heart_woman_man_tone3:", + ":couple_with_heart_woman_man_medium_skin_tone_dark_skin_tone:": ":couple_with_heart_woman_man_tone3_tone5:", + ":couple_with_heart_woman_man_medium_skin_tone_light_skin_tone:": ":couple_with_heart_woman_man_tone3_tone1:", + ":couple_with_heart_woman_man_medium_skin_tone_medium_dark_skin_tone:": ":couple_with_heart_woman_man_tone3_tone4:", + ":couple_with_heart_woman_man_medium_skin_tone_medium_light_skin_tone:": ":couple_with_heart_woman_man_tone3_tone2:", + ":couple_with_heart_woman_woman_dark_skin_tone:": ":couple_with_heart_woman_woman_tone5:", + ":couple_with_heart_woman_woman_dark_skin_tone_light_skin_tone:": ":couple_with_heart_woman_woman_tone5_tone1:", + ":couple_with_heart_woman_woman_dark_skin_tone_medium_dark_skin_tone:": ":couple_with_heart_woman_woman_tone5_tone4:", + ":couple_with_heart_woman_woman_dark_skin_tone_medium_light_skin_tone:": ":couple_with_heart_woman_woman_tone5_tone2:", + ":couple_with_heart_woman_woman_dark_skin_tone_medium_skin_tone:": ":couple_with_heart_woman_woman_tone5_tone3:", + ":couple_with_heart_woman_woman_light_skin_tone:": ":couple_with_heart_woman_woman_tone1:", + ":couple_with_heart_woman_woman_light_skin_tone_dark_skin_tone:": ":couple_with_heart_woman_woman_tone1_tone5:", + ":couple_with_heart_woman_woman_light_skin_tone_medium_dark_skin_tone:": ":couple_with_heart_woman_woman_tone1_tone4:", + ":couple_with_heart_woman_woman_light_skin_tone_medium_light_skin_tone:": ":couple_with_heart_woman_woman_tone1_tone2:", + ":couple_with_heart_woman_woman_light_skin_tone_medium_skin_tone:": ":couple_with_heart_woman_woman_tone1_tone3:", + ":couple_with_heart_woman_woman_medium_dark_skin_tone:": ":couple_with_heart_woman_woman_tone4:", + ":couple_with_heart_woman_woman_medium_dark_skin_tone_dark_skin_tone:": ":couple_with_heart_woman_woman_tone4_tone5:", + ":couple_with_heart_woman_woman_medium_dark_skin_tone_light_skin_tone:": ":couple_with_heart_woman_woman_tone4_tone1:", + ":couple_with_heart_woman_woman_medium_dark_skin_tone_medium_light_skin_tone:": ":couple_with_heart_woman_woman_tone4_tone2:", + ":couple_with_heart_woman_woman_medium_dark_skin_tone_medium_skin_tone:": ":couple_with_heart_woman_woman_tone4_tone3:", + ":couple_with_heart_woman_woman_medium_light_skin_tone:": ":couple_with_heart_woman_woman_tone2:", + ":couple_with_heart_woman_woman_medium_light_skin_tone_dark_skin_tone:": ":couple_with_heart_woman_woman_tone2_tone5:", + ":couple_with_heart_woman_woman_medium_light_skin_tone_light_skin_tone:": ":couple_with_heart_woman_woman_tone2_tone1:", + ":couple_with_heart_woman_woman_medium_light_skin_tone_medium_dark_skin_tone:": ":couple_with_heart_woman_woman_tone2_tone4:", + ":couple_with_heart_woman_woman_medium_light_skin_tone_medium_skin_tone:": ":couple_with_heart_woman_woman_tone2_tone3:", + ":couple_with_heart_woman_woman_medium_skin_tone:": ":couple_with_heart_woman_woman_tone3:", + ":couple_with_heart_woman_woman_medium_skin_tone_dark_skin_tone:": ":couple_with_heart_woman_woman_tone3_tone5:", + ":couple_with_heart_woman_woman_medium_skin_tone_light_skin_tone:": ":couple_with_heart_woman_woman_tone3_tone1:", + ":couple_with_heart_woman_woman_medium_skin_tone_medium_dark_skin_tone:": ":couple_with_heart_woman_woman_tone3_tone4:", + ":couple_with_heart_woman_woman_medium_skin_tone_medium_light_skin_tone:": ":couple_with_heart_woman_woman_tone3_tone2:", + ":couple_with_heart_ww:": ":couple_ww:", + ":couplekiss_mm:": ":kiss_mm:", + ":couplekiss_ww:": ":kiss_ww:", + ":cow_face:": ":cow:", + ":cp:": ":flag_cp:", + ":cr:": ":flag_cr:", + ":cricket_bat_ball:": ":cricket_game:", + ":cross_mark:": ":x:", + ":crying_cat:": ":crying_cat_face:", + ":crying_face:": ":cry:", + ":cu:": ":flag_cu:", + ":curly_hair:": ":curly_haired:", + ":curry_rice:": ":curry:", + ":cv:": ":flag_cv:", + ":cw:": ":flag_cw:", + ":cx:": ":flag_cx:", + ":cy:": ":flag_cy:", + ":cz:": ":flag_cz:", + ":dagger_knife:": ":dagger:", + ":dancers:": ":people_with_bunny_ears_partying:", + ":dashing_away:": ":dash:", + ":de:": ":flag_de:", + ":deaf_man_dark_skin_tone:": ":deaf_man_tone5:", + ":deaf_man_light_skin_tone:": ":deaf_man_tone1:", + ":deaf_man_medium_dark_skin_tone:": ":deaf_man_tone4:", + ":deaf_man_medium_light_skin_tone:": ":deaf_man_tone2:", + ":deaf_man_medium_skin_tone:": ":deaf_man_tone3:", + ":deaf_person_dark_skin_tone:": ":deaf_person_tone5:", + ":deaf_person_light_skin_tone:": ":deaf_person_tone1:", + ":deaf_person_medium_dark_skin_tone:": ":deaf_person_tone4:", + ":deaf_person_medium_light_skin_tone:": ":deaf_person_tone2:", + ":deaf_person_medium_skin_tone:": ":deaf_person_tone3:", + ":deaf_woman_dark_skin_tone:": ":deaf_woman_tone5:", + ":deaf_woman_light_skin_tone:": ":deaf_woman_tone1:", + ":deaf_woman_medium_dark_skin_tone:": ":deaf_woman_tone4:", + ":deaf_woman_medium_light_skin_tone:": ":deaf_woman_tone2:", + ":deaf_woman_medium_skin_tone:": ":deaf_woman_tone3:", + ":derelict_house_building:": ":house_abandoned:", + ":desert_island:": ":island:", + ":desktop_computer:": ":desktop:", + ":dg:": ":flag_dg:", + ":diamond_suit:": ":diamonds:", + ":direct_hit:": ":dart:", + ":dj:": ":flag_dj:", + ":dk:": ":flag_dk:", + ":dm:": ":flag_dm:", + ":do:": ":flag_do:", + ":dog_face:": ":dog:", + ":double_vertical_bar:": ":pause_button:", + ":dove_of_peace:": ":dove:", + ":down_arrow:": ":arrow_down:", + ":drool:": ":drooling_face:", + ":drum_with_drumsticks:": ":drum:", + ":dz:": ":flag_dz:", + ":e_mail:": ":e-mail:", + ":ea:": ":flag_ea:", + ":ear_of_corn:": ":corn:", + ":ear_with_hearing_aid_dark_skin_tone:": ":ear_with_hearing_aid_tone5:", + ":ear_with_hearing_aid_light_skin_tone:": ":ear_with_hearing_aid_tone1:", + ":ear_with_hearing_aid_medium_dark_skin_tone:": ":ear_with_hearing_aid_tone4:", + ":ear_with_hearing_aid_medium_light_skin_tone:": ":ear_with_hearing_aid_tone2:", + ":ear_with_hearing_aid_medium_skin_tone:": ":ear_with_hearing_aid_tone3:", + ":ec:": ":flag_ec:", + ":ee:": ":flag_ee:", + ":eg:": ":flag_eg:", + ":eh:": ":flag_eh:", + ":eight_oclock:": ":clock8:", + ":eight_thirty:": ":clock830:", + ":eject_symbol:": ":eject:", + ":eleven_oclock:": ":clock11:", + ":eleven_thirty:": ":clock1130:", + ":elf_dark_skin_tone:": ":elf_tone5:", + ":elf_light_skin_tone:": ":elf_tone1:", + ":elf_medium_dark_skin_tone:": ":elf_tone4:", + ":elf_medium_light_skin_tone:": ":elf_tone2:", + ":elf_medium_skin_tone:": ":elf_tone3:", + ":email:": ":e-mail:", + ":end_arrow:": ":end:", + ":er:": ":flag_er:", + ":es:": ":flag_es:", + ":et:": ":flag_et:", + ":eu:": ":flag_eu:", + ":euro_banknote:": ":euro:", + ":ewe:": ":sheep:", + ":expecting_woman:": ":pregnant_woman:", + ":expecting_woman_tone1:": ":pregnant_woman_tone1:", + ":expecting_woman_tone2:": ":pregnant_woman_tone2:", + ":expecting_woman_tone3:": ":pregnant_woman_tone3:", + ":expecting_woman_tone4:": ":pregnant_woman_tone4:", + ":expecting_woman_tone5:": ":pregnant_woman_tone5:", + ":face_palm:": ":person_facepalming:", + ":face_palm_tone1:": ":person_facepalming_tone1:", + ":face_palm_tone2:": ":person_facepalming_tone2:", + ":face_palm_tone3:": ":person_facepalming_tone3:", + ":face_palm_tone4:": ":person_facepalming_tone4:", + ":face_palm_tone5:": ":person_facepalming_tone5:", + ":face_with_cowboy_hat:": ":cowboy:", + ":face_with_head_bandage:": ":head_bandage:", + ":face_with_rolling_eyes:": ":rolling_eyes:", + ":face_with_thermometer:": ":thermometer_face:", + ":facepalm:": ":person_facepalming:", + ":facepalm_tone1:": ":person_facepalming_tone1:", + ":facepalm_tone2:": ":person_facepalming_tone2:", + ":facepalm_tone3:": ":person_facepalming_tone3:", + ":facepalm_tone4:": ":person_facepalming_tone4:", + ":facepalm_tone5:": ":person_facepalming_tone5:", + ":factory_worker_dark_skin_tone:": ":factory_worker_tone5:", + ":factory_worker_light_skin_tone:": ":factory_worker_tone1:", + ":factory_worker_medium_dark_skin_tone:": ":factory_worker_tone4:", + ":factory_worker_medium_light_skin_tone:": ":factory_worker_tone2:", + ":factory_worker_medium_skin_tone:": ":factory_worker_tone3:", + ":fairy_dark_skin_tone:": ":fairy_tone5:", + ":fairy_light_skin_tone:": ":fairy_tone1:", + ":fairy_medium_dark_skin_tone:": ":fairy_tone4:", + ":fairy_medium_light_skin_tone:": ":fairy_tone2:", + ":fairy_medium_skin_tone:": ":fairy_tone3:", + ":farmer_dark_skin_tone:": ":farmer_tone5:", + ":farmer_light_skin_tone:": ":farmer_tone1:", + ":farmer_medium_dark_skin_tone:": ":farmer_tone4:", + ":farmer_medium_light_skin_tone:": ":farmer_tone2:", + ":farmer_medium_skin_tone:": ":farmer_tone3:", + ":fax_machine:": ":fax:", + ":fearful_face:": ":fearful:", + ":fencer:": ":person_fencing:", + ":fencing:": ":person_fencing:", + ":fi:": ":flag_fi:", + ":film_projector:": ":projector:", + ":firefighter_dark_skin_tone:": ":firefighter_tone5:", + ":firefighter_light_skin_tone:": ":firefighter_tone1:", + ":firefighter_medium_dark_skin_tone:": ":firefighter_tone4:", + ":firefighter_medium_light_skin_tone:": ":firefighter_tone2:", + ":firefighter_medium_skin_tone:": ":firefighter_tone3:", + ":first_place_medal:": ":first_place:", + ":fishing_pole:": ":fishing_pole_and_fish:", + ":five_oclock:": ":clock5:", + ":five_thirty:": ":clock530:", + ":fj:": ":flag_fj:", + ":fk:": ":flag_fk:", + ":flag_in_hole:": ":golf:", + ":flame:": ":fire:", + ":flan:": ":custard:", + ":flat_shoe:": ":womans_flat_shoe:", + ":fleur_de_lis:": ":fleur-de-lis:", + ":flexed_biceps:": ":muscle:", + ":flushed_face:": ":flushed:", + ":fm:": ":flag_fm:", + ":fo:": ":flag_fo:", + ":folded_hands:": ":pray:", + ":foot_dark_skin_tone:": ":foot_tone5:", + ":foot_light_skin_tone:": ":foot_tone1:", + ":foot_medium_dark_skin_tone:": ":foot_tone4:", + ":foot_medium_light_skin_tone:": ":foot_tone2:", + ":foot_medium_skin_tone:": ":foot_tone3:", + ":fork_and_knife_with_plate:": ":fork_knife_plate:", + ":fountain_pen:": ":pen_fountain:", + ":four_oclock:": ":clock4:", + ":four_thirty:": ":clock430:", + ":fox_face:": ":fox:", + ":fr:": ":flag_fr:", + ":frame_with_picture:": ":frame_photo:", + ":french_fries:": ":fries:", + ":frowning_face:": ":frowning2:", + ":fuel_pump:": ":fuelpump:", + ":funeral_urn:": ":urn:", + ":ga:": ":flag_ga:", + ":gay_pride_flag:": ":rainbow_flag:", + ":gb:": ":flag_gb:", + ":gd:": ":flag_gd:", + ":ge:": ":flag_ge:", + ":gem_stone:": ":gem:", + ":gf:": ":flag_gf:", + ":gg:": ":flag_gg:", + ":gh:": ":flag_gh:", + ":gi:": ":flag_gi:", + ":gl:": ":flag_gl:", + ":glass_of_milk:": ":milk:", + ":glasses:": ":eyeglasses:", + ":glowing_star:": ":star2:", + ":gm:": ":flag_gm:", + ":gn:": ":flag_gn:", + ":goal_net:": ":goal:", + ":goblin:": ":japanese_goblin:", + ":golfer:": ":person_golfing:", + ":gp:": ":flag_gp:", + ":gq:": ":flag_gq:", + ":gr:": ":flag_gr:", + ":grandma:": ":older_woman:", + ":grandma_tone1:": ":older_woman_tone1:", + ":grandma_tone2:": ":older_woman_tone2:", + ":grandma_tone3:": ":older_woman_tone3:", + ":grandma_tone4:": ":older_woman_tone4:", + ":grandma_tone5:": ":older_woman_tone5:", + ":green_salad:": ":salad:", + ":grinning_cat:": ":smiley_cat:", + ":grinning_face:": ":grinning:", + ":growing_heart:": ":heartpulse:", + ":gs:": ":flag_gs:", + ":gt:": ":flag_gt:", + ":gu:": ":flag_gu:", + ":guardsman:": ":guard:", + ":guardsman_tone1:": ":guard_tone1:", + ":guardsman_tone2:": ":guard_tone2:", + ":guardsman_tone3:": ":guard_tone3:", + ":guardsman_tone4:": ":guard_tone4:", + ":guardsman_tone5:": ":guard_tone5:", + ":gw:": ":flag_gw:", + ":gy:": ":flag_gy:", + ":haircut:": ":person_getting_haircut:", + ":haircut_tone1:": ":person_getting_haircut_tone1:", + ":haircut_tone2:": ":person_getting_haircut_tone2:", + ":haircut_tone3:": ":person_getting_haircut_tone3:", + ":haircut_tone4:": ":person_getting_haircut_tone4:", + ":haircut_tone5:": ":person_getting_haircut_tone5:", + ":hammer_and_pick:": ":hammer_pick:", + ":hammer_and_wrench:": ":tools:", + ":hand_with_index_and_middle_finger_crossed:": ":fingers_crossed:", + ":hand_with_index_and_middle_fingers_crossed_tone1:": ":fingers_crossed_tone1:", + ":hand_with_index_and_middle_fingers_crossed_tone2:": ":fingers_crossed_tone2:", + ":hand_with_index_and_middle_fingers_crossed_tone3:": ":fingers_crossed_tone3:", + ":hand_with_index_and_middle_fingers_crossed_tone4:": ":fingers_crossed_tone4:", + ":hand_with_index_and_middle_fingers_crossed_tone5:": ":fingers_crossed_tone5:", + ":hand_with_index_finger_and_thumb_crossed_dark_skin_tone:": ":hand_with_index_finger_and_thumb_crossed_tone5:", + ":hand_with_index_finger_and_thumb_crossed_light_skin_tone:": ":hand_with_index_finger_and_thumb_crossed_tone1:", + ":hand_with_index_finger_and_thumb_crossed_medium_dark_skin_tone:": ":hand_with_index_finger_and_thumb_crossed_tone4:", + ":hand_with_index_finger_and_thumb_crossed_medium_light_skin_tone:": ":hand_with_index_finger_and_thumb_crossed_tone2:", + ":hand_with_index_finger_and_thumb_crossed_medium_skin_tone:": ":hand_with_index_finger_and_thumb_crossed_tone3:", + ":handball:": ":person_playing_handball:", + ":handball_tone1:": ":person_playing_handball_tone1:", + ":handball_tone2:": ":person_playing_handball_tone2:", + ":handball_tone3:": ":person_playing_handball_tone3:", + ":handball_tone4:": ":person_playing_handball_tone4:", + ":handball_tone5:": ":person_playing_handball_tone5:", + ":handshake_dark_skin_tone:": ":handshake_tone5:", + ":handshake_dark_skin_tone_light_skin_tone:": ":handshake_tone5_tone1:", + ":handshake_dark_skin_tone_medium_dark_skin_tone:": ":handshake_tone5_tone4:", + ":handshake_dark_skin_tone_medium_light_skin_tone:": ":handshake_tone5_tone2:", + ":handshake_dark_skin_tone_medium_skin_tone:": ":handshake_tone5_tone3:", + ":handshake_light_skin_tone:": ":handshake_tone1:", + ":handshake_light_skin_tone_dark_skin_tone:": ":handshake_tone1_tone5:", + ":handshake_light_skin_tone_medium_dark_skin_tone:": ":handshake_tone1_tone4:", + ":handshake_light_skin_tone_medium_light_skin_tone:": ":handshake_tone1_tone2:", + ":handshake_light_skin_tone_medium_skin_tone:": ":handshake_tone1_tone3:", + ":handshake_medium_dark_skin_tone:": ":handshake_tone4:", + ":handshake_medium_dark_skin_tone_dark_skin_tone:": ":handshake_tone4_tone5:", + ":handshake_medium_dark_skin_tone_light_skin_tone:": ":handshake_tone4_tone1:", + ":handshake_medium_dark_skin_tone_medium_light_skin_tone:": ":handshake_tone4_tone2:", + ":handshake_medium_dark_skin_tone_medium_skin_tone:": ":handshake_tone4_tone3:", + ":handshake_medium_light_skin_tone:": ":handshake_tone2:", + ":handshake_medium_light_skin_tone_dark_skin_tone:": ":handshake_tone2_tone5:", + ":handshake_medium_light_skin_tone_light_skin_tone:": ":handshake_tone2_tone1:", + ":handshake_medium_light_skin_tone_medium_dark_skin_tone:": ":handshake_tone2_tone4:", + ":handshake_medium_light_skin_tone_medium_skin_tone:": ":handshake_tone2_tone3:", + ":handshake_medium_skin_tone:": ":handshake_tone3:", + ":handshake_medium_skin_tone_dark_skin_tone:": ":handshake_tone3_tone5:", + ":handshake_medium_skin_tone_light_skin_tone:": ":handshake_tone3_tone1:", + ":handshake_medium_skin_tone_medium_dark_skin_tone:": ":handshake_tone3_tone4:", + ":handshake_medium_skin_tone_medium_light_skin_tone:": ":handshake_tone3_tone2:", + ":hankey:": ":poop:", + ":headphone:": ":headphones:", + ":health_worker_dark_skin_tone:": ":health_worker_tone5:", + ":health_worker_light_skin_tone:": ":health_worker_tone1:", + ":health_worker_medium_dark_skin_tone:": ":health_worker_tone4:", + ":health_worker_medium_light_skin_tone:": ":health_worker_tone2:", + ":health_worker_medium_skin_tone:": ":health_worker_tone3:", + ":heart_hands_dark_skin_tone:": ":heart_hands_tone5:", + ":heart_hands_light_skin_tone:": ":heart_hands_tone1:", + ":heart_hands_medium_dark_skin_tone:": ":heart_hands_tone4:", + ":heart_hands_medium_light_skin_tone:": ":heart_hands_tone2:", + ":heart_hands_medium_skin_tone:": ":heart_hands_tone3:", + ":heart_suit:": ":hearts:", + ":heavy_heart_exclamation_mark_ornament:": ":heart_exclamation:", + ":helmet_with_white_cross:": ":helmet_with_cross:", + ":high_voltage:": ":zap:", + ":hk:": ":flag_hk:", + ":hm:": ":flag_hm:", + ":hn:": ":flag_hn:", + ":honeybee:": ":bee:", + ":horse_face:": ":horse:", + ":hot_beverage:": ":coffee:", + ":hot_dog:": ":hotdog:", + ":hot_springs:": ":hotsprings:", + ":house_buildings:": ":homes:", + ":houses:": ":homes:", + ":hr:": ":flag_hr:", + ":ht:": ":flag_ht:", + ":hu:": ":flag_hu:", + ":hugging_face:": ":hugging:", + ":hushed_face:": ":hushed:", + ":ic:": ":flag_ic:", + ":ice_hockey:": ":hockey:", + ":ie:": ":flag_ie:", + ":il:": ":flag_il:", + ":im:": ":flag_im:", + ":in:": ":flag_in:", + ":index_pointing_at_the_viewer_dark_skin_tone:": ":index_pointing_at_the_viewer_tone5:", + ":index_pointing_at_the_viewer_light_skin_tone:": ":index_pointing_at_the_viewer_tone1:", + ":index_pointing_at_the_viewer_medium_dark_skin_tone:": ":index_pointing_at_the_viewer_tone4:", + ":index_pointing_at_the_viewer_medium_light_skin_tone:": ":index_pointing_at_the_viewer_tone2:", + ":index_pointing_at_the_viewer_medium_skin_tone:": ":index_pointing_at_the_viewer_tone3:", + ":indonesia:": ":flag_id:", + ":information:": ":information_source:", + ":information_desk_person:": ":person_tipping_hand:", + ":information_desk_person_tone1:": ":person_tipping_hand_tone1:", + ":information_desk_person_tone2:": ":person_tipping_hand_tone2:", + ":information_desk_person_tone3:": ":person_tipping_hand_tone3:", + ":information_desk_person_tone4:": ":person_tipping_hand_tone4:", + ":information_desk_person_tone5:": ":person_tipping_hand_tone5:", + ":input_numbers:": ":1234:", + ":input_symbols:": ":symbols:", + ":io:": ":flag_io:", + ":iq:": ":flag_iq:", + ":ir:": ":flag_ir:", + ":is:": ":flag_is:", + ":it:": ":flag_it:", + ":je:": ":flag_je:", + ":jm:": ":flag_jm:", + ":jo:": ":flag_jo:", + ":joker:": ":black_joker:", + ":jp:": ":flag_jp:", + ":judge_dark_skin_tone:": ":judge_tone5:", + ":judge_light_skin_tone:": ":judge_tone1:", + ":judge_medium_dark_skin_tone:": ":judge_tone4:", + ":judge_medium_light_skin_tone:": ":judge_tone2:", + ":judge_medium_skin_tone:": ":judge_tone3:", + ":juggler:": ":person_juggling:", + ":juggler_tone1:": ":person_juggling_tone1:", + ":juggler_tone2:": ":person_juggling_tone2:", + ":juggler_tone3:": ":person_juggling_tone3:", + ":juggler_tone4:": ":person_juggling_tone4:", + ":juggler_tone5:": ":person_juggling_tone5:", + ":juggling:": ":person_juggling:", + ":juggling_tone1:": ":person_juggling_tone1:", + ":juggling_tone2:": ":person_juggling_tone2:", + ":juggling_tone3:": ":person_juggling_tone3:", + ":juggling_tone4:": ":person_juggling_tone4:", + ":juggling_tone5:": ":person_juggling_tone5:", + ":karate_uniform:": ":martial_arts_uniform:", + ":kayak:": ":canoe:", + ":ke:": ":flag_ke:", + ":keycap_asterisk:": ":asterisk:", + ":kg:": ":flag_kg:", + ":kh:": ":flag_kh:", + ":ki:": ":flag_ki:", + ":kick_scooter:": ":scooter:", + ":kiss_dark_skin_tone:": ":kiss_tone5:", + ":kiss_light_skin_tone:": ":kiss_tone1:", + ":kiss_man_man:": ":kiss_mm:", + ":kiss_man_man_dark_skin_tone:": ":kiss_man_man_tone5:", + ":kiss_man_man_dark_skin_tone_light_skin_tone:": ":kiss_man_man_tone5_tone1:", + ":kiss_man_man_dark_skin_tone_medium_dark_skin_tone:": ":kiss_man_man_tone5_tone4:", + ":kiss_man_man_dark_skin_tone_medium_light_skin_tone:": ":kiss_man_man_tone5_tone2:", + ":kiss_man_man_dark_skin_tone_medium_skin_tone:": ":kiss_man_man_tone5_tone3:", + ":kiss_man_man_light_skin_tone:": ":kiss_man_man_tone1:", + ":kiss_man_man_light_skin_tone_dark_skin_tone:": ":kiss_man_man_tone1_tone5:", + ":kiss_man_man_light_skin_tone_medium_dark_skin_tone:": ":kiss_man_man_tone1_tone4:", + ":kiss_man_man_light_skin_tone_medium_light_skin_tone:": ":kiss_man_man_tone1_tone2:", + ":kiss_man_man_light_skin_tone_medium_skin_tone:": ":kiss_man_man_tone1_tone3:", + ":kiss_man_man_medium_dark_skin_tone:": ":kiss_man_man_tone4:", + ":kiss_man_man_medium_dark_skin_tone_dark_skin_tone:": ":kiss_man_man_tone4_tone5:", + ":kiss_man_man_medium_dark_skin_tone_light_skin_tone:": ":kiss_man_man_tone4_tone1:", + ":kiss_man_man_medium_dark_skin_tone_medium_light_skin_tone:": ":kiss_man_man_tone4_tone2:", + ":kiss_man_man_medium_dark_skin_tone_medium_skin_tone:": ":kiss_man_man_tone4_tone3:", + ":kiss_man_man_medium_light_skin_tone:": ":kiss_man_man_tone2:", + ":kiss_man_man_medium_light_skin_tone_dark_skin_tone:": ":kiss_man_man_tone2_tone5:", + ":kiss_man_man_medium_light_skin_tone_light_skin_tone:": ":kiss_man_man_tone2_tone1:", + ":kiss_man_man_medium_light_skin_tone_medium_dark_skin_tone:": ":kiss_man_man_tone2_tone4:", + ":kiss_man_man_medium_light_skin_tone_medium_skin_tone:": ":kiss_man_man_tone2_tone3:", + ":kiss_man_man_medium_skin_tone:": ":kiss_man_man_tone3:", + ":kiss_man_man_medium_skin_tone_dark_skin_tone:": ":kiss_man_man_tone3_tone5:", + ":kiss_man_man_medium_skin_tone_light_skin_tone:": ":kiss_man_man_tone3_tone1:", + ":kiss_man_man_medium_skin_tone_medium_dark_skin_tone:": ":kiss_man_man_tone3_tone4:", + ":kiss_man_man_medium_skin_tone_medium_light_skin_tone:": ":kiss_man_man_tone3_tone2:", + ":kiss_mark:": ":kiss:", + ":kiss_medium_dark_skin_tone:": ":kiss_tone4:", + ":kiss_medium_light_skin_tone:": ":kiss_tone2:", + ":kiss_medium_skin_tone:": ":kiss_tone3:", + ":kiss_person_person_dark_skin_tone_light_skin_tone:": ":kiss_person_person_tone5_tone1:", + ":kiss_person_person_dark_skin_tone_medium_dark_skin_tone:": ":kiss_person_person_tone5_tone4:", + ":kiss_person_person_dark_skin_tone_medium_light_skin_tone:": ":kiss_person_person_tone5_tone2:", + ":kiss_person_person_dark_skin_tone_medium_skin_tone:": ":kiss_person_person_tone5_tone3:", + ":kiss_person_person_light_skin_tone_dark_skin_tone:": ":kiss_person_person_tone1_tone5:", + ":kiss_person_person_light_skin_tone_medium_dark_skin_tone:": ":kiss_person_person_tone1_tone4:", + ":kiss_person_person_light_skin_tone_medium_light_skin_tone:": ":kiss_person_person_tone1_tone2:", + ":kiss_person_person_light_skin_tone_medium_skin_tone:": ":kiss_person_person_tone1_tone3:", + ":kiss_person_person_medium_dark_skin_tone_dark_skin_tone:": ":kiss_person_person_tone4_tone5:", + ":kiss_person_person_medium_dark_skin_tone_light_skin_tone:": ":kiss_person_person_tone4_tone1:", + ":kiss_person_person_medium_dark_skin_tone_medium_light_skin_tone:": ":kiss_person_person_tone4_tone2:", + ":kiss_person_person_medium_dark_skin_tone_medium_skin_tone:": ":kiss_person_person_tone4_tone3:", + ":kiss_person_person_medium_light_skin_tone_dark_skin_tone:": ":kiss_person_person_tone2_tone5:", + ":kiss_person_person_medium_light_skin_tone_light_skin_tone:": ":kiss_person_person_tone2_tone1:", + ":kiss_person_person_medium_light_skin_tone_medium_dark_skin_tone:": ":kiss_person_person_tone2_tone4:", + ":kiss_person_person_medium_light_skin_tone_medium_skin_tone:": ":kiss_person_person_tone2_tone3:", + ":kiss_person_person_medium_skin_tone_dark_skin_tone:": ":kiss_person_person_tone3_tone5:", + ":kiss_person_person_medium_skin_tone_light_skin_tone:": ":kiss_person_person_tone3_tone1:", + ":kiss_person_person_medium_skin_tone_medium_dark_skin_tone:": ":kiss_person_person_tone3_tone4:", + ":kiss_person_person_medium_skin_tone_medium_light_skin_tone:": ":kiss_person_person_tone3_tone2:", + ":kiss_woman_man_dark_skin_tone:": ":kiss_woman_man_tone5:", + ":kiss_woman_man_dark_skin_tone_light_skin_tone:": ":kiss_woman_man_tone5_tone1:", + ":kiss_woman_man_dark_skin_tone_medium_dark_skin_tone:": ":kiss_woman_man_tone5_tone4:", + ":kiss_woman_man_dark_skin_tone_medium_light_skin_tone:": ":kiss_woman_man_tone5_tone2:", + ":kiss_woman_man_dark_skin_tone_medium_skin_tone:": ":kiss_woman_man_tone5_tone3:", + ":kiss_woman_man_light_skin_tone:": ":kiss_woman_man_tone1:", + ":kiss_woman_man_light_skin_tone_dark_skin_tone:": ":kiss_woman_man_tone1_tone5:", + ":kiss_woman_man_light_skin_tone_medium_dark_skin_tone:": ":kiss_woman_man_tone1_tone4:", + ":kiss_woman_man_light_skin_tone_medium_light_skin_tone:": ":kiss_woman_man_tone1_tone2:", + ":kiss_woman_man_light_skin_tone_medium_skin_tone:": ":kiss_woman_man_tone1_tone3:", + ":kiss_woman_man_medium_dark_skin_tone:": ":kiss_woman_man_tone4:", + ":kiss_woman_man_medium_dark_skin_tone_dark_skin_tone:": ":kiss_woman_man_tone4_tone5:", + ":kiss_woman_man_medium_dark_skin_tone_light_skin_tone:": ":kiss_woman_man_tone4_tone1:", + ":kiss_woman_man_medium_dark_skin_tone_medium_light_skin_tone:": ":kiss_woman_man_tone4_tone2:", + ":kiss_woman_man_medium_dark_skin_tone_medium_skin_tone:": ":kiss_woman_man_tone4_tone3:", + ":kiss_woman_man_medium_light_skin_tone:": ":kiss_woman_man_tone2:", + ":kiss_woman_man_medium_light_skin_tone_dark_skin_tone:": ":kiss_woman_man_tone2_tone5:", + ":kiss_woman_man_medium_light_skin_tone_light_skin_tone:": ":kiss_woman_man_tone2_tone1:", + ":kiss_woman_man_medium_light_skin_tone_medium_dark_skin_tone:": ":kiss_woman_man_tone2_tone4:", + ":kiss_woman_man_medium_light_skin_tone_medium_skin_tone:": ":kiss_woman_man_tone2_tone3:", + ":kiss_woman_man_medium_skin_tone:": ":kiss_woman_man_tone3:", + ":kiss_woman_man_medium_skin_tone_dark_skin_tone:": ":kiss_woman_man_tone3_tone5:", + ":kiss_woman_man_medium_skin_tone_light_skin_tone:": ":kiss_woman_man_tone3_tone1:", + ":kiss_woman_man_medium_skin_tone_medium_dark_skin_tone:": ":kiss_woman_man_tone3_tone4:", + ":kiss_woman_man_medium_skin_tone_medium_light_skin_tone:": ":kiss_woman_man_tone3_tone2:", + ":kiss_woman_woman_dark_skin_tone:": ":kiss_woman_woman_tone5:", + ":kiss_woman_woman_dark_skin_tone_light_skin_tone:": ":kiss_woman_woman_tone5_tone1:", + ":kiss_woman_woman_dark_skin_tone_medium_dark_skin_tone:": ":kiss_woman_woman_tone5_tone4:", + ":kiss_woman_woman_dark_skin_tone_medium_light_skin_tone:": ":kiss_woman_woman_tone5_tone2:", + ":kiss_woman_woman_dark_skin_tone_medium_skin_tone:": ":kiss_woman_woman_tone5_tone3:", + ":kiss_woman_woman_light_skin_tone:": ":kiss_woman_woman_tone1:", + ":kiss_woman_woman_light_skin_tone_dark_skin_tone:": ":kiss_woman_woman_tone1_tone5:", + ":kiss_woman_woman_light_skin_tone_medium_dark_skin_tone:": ":kiss_woman_woman_tone1_tone4:", + ":kiss_woman_woman_light_skin_tone_medium_light_skin_tone:": ":kiss_woman_woman_tone1_tone2:", + ":kiss_woman_woman_light_skin_tone_medium_skin_tone:": ":kiss_woman_woman_tone1_tone3:", + ":kiss_woman_woman_medium_dark_skin_tone:": ":kiss_woman_woman_tone4:", + ":kiss_woman_woman_medium_dark_skin_tone_dark_skin_tone:": ":kiss_woman_woman_tone4_tone5:", + ":kiss_woman_woman_medium_dark_skin_tone_light_skin_tone:": ":kiss_woman_woman_tone4_tone1:", + ":kiss_woman_woman_medium_dark_skin_tone_medium_light_skin_tone:": ":kiss_woman_woman_tone4_tone2:", + ":kiss_woman_woman_medium_dark_skin_tone_medium_skin_tone:": ":kiss_woman_woman_tone4_tone3:", + ":kiss_woman_woman_medium_light_skin_tone:": ":kiss_woman_woman_tone2:", + ":kiss_woman_woman_medium_light_skin_tone_dark_skin_tone:": ":kiss_woman_woman_tone2_tone5:", + ":kiss_woman_woman_medium_light_skin_tone_light_skin_tone:": ":kiss_woman_woman_tone2_tone1:", + ":kiss_woman_woman_medium_light_skin_tone_medium_dark_skin_tone:": ":kiss_woman_woman_tone2_tone4:", + ":kiss_woman_woman_medium_light_skin_tone_medium_skin_tone:": ":kiss_woman_woman_tone2_tone3:", + ":kiss_woman_woman_medium_skin_tone:": ":kiss_woman_woman_tone3:", + ":kiss_woman_woman_medium_skin_tone_dark_skin_tone:": ":kiss_woman_woman_tone3_tone5:", + ":kiss_woman_woman_medium_skin_tone_light_skin_tone:": ":kiss_woman_woman_tone3_tone1:", + ":kiss_woman_woman_medium_skin_tone_medium_dark_skin_tone:": ":kiss_woman_woman_tone3_tone4:", + ":kiss_woman_woman_medium_skin_tone_medium_light_skin_tone:": ":kiss_woman_woman_tone3_tone2:", + ":kissing_face:": ":kissing:", + ":kitchen_knife:": ":knife:", + ":kiwi_fruit:": ":kiwi:", + ":kiwifruit:": ":kiwi:", + ":km:": ":flag_km:", + ":kn:": ":flag_kn:", + ":kp:": ":flag_kp:", + ":kr:": ":flag_kr:", + ":kw:": ":flag_kw:", + ":ky:": ":flag_ky:", + ":kz:": ":flag_kz:", + ":la:": ":flag_la:", + ":latin_cross:": ":cross:", + ":lb:": ":flag_lb:", + ":lc:": ":flag_lc:", + ":left_arrow:": ":arrow_left:", + ":left_fist:": ":left_facing_fist:", + ":left_fist_tone1:": ":left_facing_fist_tone1:", + ":left_fist_tone2:": ":left_facing_fist_tone2:", + ":left_fist_tone3:": ":left_facing_fist_tone3:", + ":left_fist_tone4:": ":left_facing_fist_tone4:", + ":left_fist_tone5:": ":left_facing_fist_tone5:", + ":left_speech_bubble:": ":speech_left:", + ":leftwards_hand_dark_skin_tone:": ":leftwards_hand_tone5:", + ":leftwards_hand_light_skin_tone:": ":leftwards_hand_tone1:", + ":leftwards_hand_medium_dark_skin_tone:": ":leftwards_hand_tone4:", + ":leftwards_hand_medium_light_skin_tone:": ":leftwards_hand_tone2:", + ":leftwards_hand_medium_skin_tone:": ":leftwards_hand_tone3:", + ":leftwards_pushing_hand_dark_skin_tone:": ":leftwards_pushing_hand_tone5:", + ":leftwards_pushing_hand_light_skin_tone:": ":leftwards_pushing_hand_tone1:", + ":leftwards_pushing_hand_medium_dark_skin_tone:": ":leftwards_pushing_hand_tone4:", + ":leftwards_pushing_hand_medium_light_skin_tone:": ":leftwards_pushing_hand_tone2:", + ":leftwards_pushing_hand_medium_skin_tone:": ":leftwards_pushing_hand_tone3:", + ":leg_dark_skin_tone:": ":leg_tone5:", + ":leg_light_skin_tone:": ":leg_tone1:", + ":leg_medium_dark_skin_tone:": ":leg_tone4:", + ":leg_medium_light_skin_tone:": ":leg_tone2:", + ":leg_medium_skin_tone:": ":leg_tone3:", + ":li:": ":flag_li:", + ":liar:": ":lying_face:", + ":lifter:": ":person_lifting_weights:", + ":lifter_tone1:": ":person_lifting_weights_tone1:", + ":lifter_tone2:": ":person_lifting_weights_tone2:", + ":lifter_tone3:": ":person_lifting_weights_tone3:", + ":lifter_tone4:": ":person_lifting_weights_tone4:", + ":lifter_tone5:": ":person_lifting_weights_tone5:", + ":light_bulb:": ":bulb:", + ":linked_paperclips:": ":paperclips:", + ":lion:": ":lion_face:", + ":lk:": ":flag_lk:", + ":locked:": ":lock:", + ":locomotive:": ":steam_locomotive:", + ":lotion_bottle:": ":squeeze_bottle:", + ":love_you_gesture_dark_skin_tone:": ":love_you_gesture_tone5:", + ":love_you_gesture_light_skin_tone:": ":love_you_gesture_tone1:", + ":love_you_gesture_medium_dark_skin_tone:": ":love_you_gesture_tone4:", + ":love_you_gesture_medium_light_skin_tone:": ":love_you_gesture_tone2:", + ":love_you_gesture_medium_skin_tone:": ":love_you_gesture_tone3:", + ":lower_left_ballpoint_pen:": ":pen_ballpoint:", + ":lower_left_crayon:": ":crayon:", + ":lower_left_fountain_pen:": ":pen_fountain:", + ":lower_left_paintbrush:": ":paintbrush:", + ":lr:": ":flag_lr:", + ":ls:": ":flag_ls:", + ":lt:": ":flag_lt:", + ":lu:": ":flag_lu:", + ":lv:": ":flag_lv:", + ":ly:": ":flag_ly:", + ":ma:": ":flag_ma:", + ":mage_dark_skin_tone:": ":mage_tone5:", + ":mage_light_skin_tone:": ":mage_tone1:", + ":mage_medium_dark_skin_tone:": ":mage_tone4:", + ":mage_medium_light_skin_tone:": ":mage_tone2:", + ":mage_medium_skin_tone:": ":mage_tone3:", + ":male_dancer:": ":man_dancing:", + ":male_dancer_tone1:": ":man_dancing_tone1:", + ":male_dancer_tone2:": ":man_dancing_tone2:", + ":male_dancer_tone3:": ":man_dancing_tone3:", + ":male_dancer_tone4:": ":man_dancing_tone4:", + ":male_dancer_tone5:": ":man_dancing_tone5:", + ":man_artist_dark_skin_tone:": ":man_artist_tone5:", + ":man_artist_light_skin_tone:": ":man_artist_tone1:", + ":man_artist_medium_dark_skin_tone:": ":man_artist_tone4:", + ":man_artist_medium_light_skin_tone:": ":man_artist_tone2:", + ":man_artist_medium_skin_tone:": ":man_artist_tone3:", + ":man_astronaut_dark_skin_tone:": ":man_astronaut_tone5:", + ":man_astronaut_light_skin_tone:": ":man_astronaut_tone1:", + ":man_astronaut_medium_dark_skin_tone:": ":man_astronaut_tone4:", + ":man_astronaut_medium_light_skin_tone:": ":man_astronaut_tone2:", + ":man_astronaut_medium_skin_tone:": ":man_astronaut_tone3:", + ":man_bald_dark_skin_tone:": ":man_bald_tone5:", + ":man_bald_light_skin_tone:": ":man_bald_tone1:", + ":man_bald_medium_dark_skin_tone:": ":man_bald_tone4:", + ":man_bald_medium_light_skin_tone:": ":man_bald_tone2:", + ":man_bald_medium_skin_tone:": ":man_bald_tone3:", + ":man_biking_dark_skin_tone:": ":man_biking_tone5:", + ":man_biking_light_skin_tone:": ":man_biking_tone1:", + ":man_biking_medium_dark_skin_tone:": ":man_biking_tone4:", + ":man_biking_medium_light_skin_tone:": ":man_biking_tone2:", + ":man_biking_medium_skin_tone:": ":man_biking_tone3:", + ":man_bouncing_ball_dark_skin_tone:": ":man_bouncing_ball_tone5:", + ":man_bouncing_ball_light_skin_tone:": ":man_bouncing_ball_tone1:", + ":man_bouncing_ball_medium_dark_skin_tone:": ":man_bouncing_ball_tone4:", + ":man_bouncing_ball_medium_light_skin_tone:": ":man_bouncing_ball_tone2:", + ":man_bouncing_ball_medium_skin_tone:": ":man_bouncing_ball_tone3:", + ":man_bowing_dark_skin_tone:": ":man_bowing_tone5:", + ":man_bowing_light_skin_tone:": ":man_bowing_tone1:", + ":man_bowing_medium_dark_skin_tone:": ":man_bowing_tone4:", + ":man_bowing_medium_light_skin_tone:": ":man_bowing_tone2:", + ":man_bowing_medium_skin_tone:": ":man_bowing_tone3:", + ":man_cartwheeling_dark_skin_tone:": ":man_cartwheeling_tone5:", + ":man_cartwheeling_light_skin_tone:": ":man_cartwheeling_tone1:", + ":man_cartwheeling_medium_dark_skin_tone:": ":man_cartwheeling_tone4:", + ":man_cartwheeling_medium_light_skin_tone:": ":man_cartwheeling_tone2:", + ":man_cartwheeling_medium_skin_tone:": ":man_cartwheeling_tone3:", + ":man_climbing_dark_skin_tone:": ":man_climbing_tone5:", + ":man_climbing_light_skin_tone:": ":man_climbing_tone1:", + ":man_climbing_medium_dark_skin_tone:": ":man_climbing_tone4:", + ":man_climbing_medium_light_skin_tone:": ":man_climbing_tone2:", + ":man_climbing_medium_skin_tone:": ":man_climbing_tone3:", + ":man_construction_worker_dark_skin_tone:": ":man_construction_worker_tone5:", + ":man_construction_worker_light_skin_tone:": ":man_construction_worker_tone1:", + ":man_construction_worker_medium_dark_skin_tone:": ":man_construction_worker_tone4:", + ":man_construction_worker_medium_light_skin_tone:": ":man_construction_worker_tone2:", + ":man_construction_worker_medium_skin_tone:": ":man_construction_worker_tone3:", + ":man_cook_dark_skin_tone:": ":man_cook_tone5:", + ":man_cook_light_skin_tone:": ":man_cook_tone1:", + ":man_cook_medium_dark_skin_tone:": ":man_cook_tone4:", + ":man_cook_medium_light_skin_tone:": ":man_cook_tone2:", + ":man_cook_medium_skin_tone:": ":man_cook_tone3:", + ":man_curly_haired_dark_skin_tone:": ":man_curly_haired_tone5:", + ":man_curly_haired_light_skin_tone:": ":man_curly_haired_tone1:", + ":man_curly_haired_medium_dark_skin_tone:": ":man_curly_haired_tone4:", + ":man_curly_haired_medium_light_skin_tone:": ":man_curly_haired_tone2:", + ":man_curly_haired_medium_skin_tone:": ":man_curly_haired_tone3:", + ":man_dark_skin_tone_beard:": ":man_tone5_beard:", + ":man_detective_dark_skin_tone:": ":man_detective_tone5:", + ":man_detective_light_skin_tone:": ":man_detective_tone1:", + ":man_detective_medium_dark_skin_tone:": ":man_detective_tone4:", + ":man_detective_medium_light_skin_tone:": ":man_detective_tone2:", + ":man_detective_medium_skin_tone:": ":man_detective_tone3:", + ":man_elf_dark_skin_tone:": ":man_elf_tone5:", + ":man_elf_light_skin_tone:": ":man_elf_tone1:", + ":man_elf_medium_dark_skin_tone:": ":man_elf_tone4:", + ":man_elf_medium_light_skin_tone:": ":man_elf_tone2:", + ":man_elf_medium_skin_tone:": ":man_elf_tone3:", + ":man_facepalming_dark_skin_tone:": ":man_facepalming_tone5:", + ":man_facepalming_light_skin_tone:": ":man_facepalming_tone1:", + ":man_facepalming_medium_dark_skin_tone:": ":man_facepalming_tone4:", + ":man_facepalming_medium_light_skin_tone:": ":man_facepalming_tone2:", + ":man_facepalming_medium_skin_tone:": ":man_facepalming_tone3:", + ":man_factory_worker_dark_skin_tone:": ":man_factory_worker_tone5:", + ":man_factory_worker_light_skin_tone:": ":man_factory_worker_tone1:", + ":man_factory_worker_medium_dark_skin_tone:": ":man_factory_worker_tone4:", + ":man_factory_worker_medium_light_skin_tone:": ":man_factory_worker_tone2:", + ":man_factory_worker_medium_skin_tone:": ":man_factory_worker_tone3:", + ":man_fairy_dark_skin_tone:": ":man_fairy_tone5:", + ":man_fairy_light_skin_tone:": ":man_fairy_tone1:", + ":man_fairy_medium_dark_skin_tone:": ":man_fairy_tone4:", + ":man_fairy_medium_light_skin_tone:": ":man_fairy_tone2:", + ":man_fairy_medium_skin_tone:": ":man_fairy_tone3:", + ":man_farmer_dark_skin_tone:": ":man_farmer_tone5:", + ":man_farmer_light_skin_tone:": ":man_farmer_tone1:", + ":man_farmer_medium_dark_skin_tone:": ":man_farmer_tone4:", + ":man_farmer_medium_light_skin_tone:": ":man_farmer_tone2:", + ":man_farmer_medium_skin_tone:": ":man_farmer_tone3:", + ":man_feeding_baby_dark_skin_tone:": ":man_feeding_baby_tone5:", + ":man_feeding_baby_light_skin_tone:": ":man_feeding_baby_tone1:", + ":man_feeding_baby_medium_dark_skin_tone:": ":man_feeding_baby_tone4:", + ":man_feeding_baby_medium_light_skin_tone:": ":man_feeding_baby_tone2:", + ":man_feeding_baby_medium_skin_tone:": ":man_feeding_baby_tone3:", + ":man_firefighter_dark_skin_tone:": ":man_firefighter_tone5:", + ":man_firefighter_light_skin_tone:": ":man_firefighter_tone1:", + ":man_firefighter_medium_dark_skin_tone:": ":man_firefighter_tone4:", + ":man_firefighter_medium_light_skin_tone:": ":man_firefighter_tone2:", + ":man_firefighter_medium_skin_tone:": ":man_firefighter_tone3:", + ":man_frowning_dark_skin_tone:": ":man_frowning_tone5:", + ":man_frowning_light_skin_tone:": ":man_frowning_tone1:", + ":man_frowning_medium_dark_skin_tone:": ":man_frowning_tone4:", + ":man_frowning_medium_light_skin_tone:": ":man_frowning_tone2:", + ":man_frowning_medium_skin_tone:": ":man_frowning_tone3:", + ":man_gesturing_no_dark_skin_tone:": ":man_gesturing_no_tone5:", + ":man_gesturing_no_light_skin_tone:": ":man_gesturing_no_tone1:", + ":man_gesturing_no_medium_dark_skin_tone:": ":man_gesturing_no_tone4:", + ":man_gesturing_no_medium_light_skin_tone:": ":man_gesturing_no_tone2:", + ":man_gesturing_no_medium_skin_tone:": ":man_gesturing_no_tone3:", + ":man_gesturing_ok_dark_skin_tone:": ":man_gesturing_ok_tone5:", + ":man_gesturing_ok_light_skin_tone:": ":man_gesturing_ok_tone1:", + ":man_gesturing_ok_medium_dark_skin_tone:": ":man_gesturing_ok_tone4:", + ":man_gesturing_ok_medium_light_skin_tone:": ":man_gesturing_ok_tone2:", + ":man_gesturing_ok_medium_skin_tone:": ":man_gesturing_ok_tone3:", + ":man_getting_face_massage_dark_skin_tone:": ":man_getting_face_massage_tone5:", + ":man_getting_face_massage_light_skin_tone:": ":man_getting_face_massage_tone1:", + ":man_getting_face_massage_medium_dark_skin_tone:": ":man_getting_face_massage_tone4:", + ":man_getting_face_massage_medium_light_skin_tone:": ":man_getting_face_massage_tone2:", + ":man_getting_face_massage_medium_skin_tone:": ":man_getting_face_massage_tone3:", + ":man_getting_haircut_dark_skin_tone:": ":man_getting_haircut_tone5:", + ":man_getting_haircut_light_skin_tone:": ":man_getting_haircut_tone1:", + ":man_getting_haircut_medium_dark_skin_tone:": ":man_getting_haircut_tone4:", + ":man_getting_haircut_medium_light_skin_tone:": ":man_getting_haircut_tone2:", + ":man_getting_haircut_medium_skin_tone:": ":man_getting_haircut_tone3:", + ":man_golfing_dark_skin_tone:": ":man_golfing_tone5:", + ":man_golfing_light_skin_tone:": ":man_golfing_tone1:", + ":man_golfing_medium_dark_skin_tone:": ":man_golfing_tone4:", + ":man_golfing_medium_light_skin_tone:": ":man_golfing_tone2:", + ":man_golfing_medium_skin_tone:": ":man_golfing_tone3:", + ":man_guard_dark_skin_tone:": ":man_guard_tone5:", + ":man_guard_light_skin_tone:": ":man_guard_tone1:", + ":man_guard_medium_dark_skin_tone:": ":man_guard_tone4:", + ":man_guard_medium_light_skin_tone:": ":man_guard_tone2:", + ":man_guard_medium_skin_tone:": ":man_guard_tone3:", + ":man_health_worker_dark_skin_tone:": ":man_health_worker_tone5:", + ":man_health_worker_light_skin_tone:": ":man_health_worker_tone1:", + ":man_health_worker_medium_dark_skin_tone:": ":man_health_worker_tone4:", + ":man_health_worker_medium_light_skin_tone:": ":man_health_worker_tone2:", + ":man_health_worker_medium_skin_tone:": ":man_health_worker_tone3:", + ":man_in_business_suit_levitating:": ":levitate:", + ":man_in_business_suit_levitating_dark_skin_tone:": ":levitate_tone5:", + ":man_in_business_suit_levitating_light_skin_tone:": ":levitate_tone1:", + ":man_in_business_suit_levitating_medium_dark_skin_tone:": ":levitate_tone4:", + ":man_in_business_suit_levitating_medium_light_skin_tone:": ":levitate_tone2:", + ":man_in_business_suit_levitating_medium_skin_tone:": ":levitate_tone3:", + ":man_in_business_suit_levitating_tone1:": ":levitate_tone1:", + ":man_in_business_suit_levitating_tone2:": ":levitate_tone2:", + ":man_in_business_suit_levitating_tone3:": ":levitate_tone3:", + ":man_in_business_suit_levitating_tone4:": ":levitate_tone4:", + ":man_in_business_suit_levitating_tone5:": ":levitate_tone5:", + ":man_in_lotus_position_dark_skin_tone:": ":man_in_lotus_position_tone5:", + ":man_in_lotus_position_light_skin_tone:": ":man_in_lotus_position_tone1:", + ":man_in_lotus_position_medium_dark_skin_tone:": ":man_in_lotus_position_tone4:", + ":man_in_lotus_position_medium_light_skin_tone:": ":man_in_lotus_position_tone2:", + ":man_in_lotus_position_medium_skin_tone:": ":man_in_lotus_position_tone3:", + ":man_in_manual_wheelchair_dark_skin_tone:": ":man_in_manual_wheelchair_tone5:", + ":man_in_manual_wheelchair_facing_right_dark_skin_tone:": ":man_in_manual_wheelchair_facing_right_tone5:", + ":man_in_manual_wheelchair_facing_right_light_skin_tone:": ":man_in_manual_wheelchair_facing_right_tone1:", + ":man_in_manual_wheelchair_facing_right_medium_dark_skin_tone:": ":man_in_manual_wheelchair_facing_right_tone4:", + ":man_in_manual_wheelchair_facing_right_medium_light_skin_tone:": ":man_in_manual_wheelchair_facing_right_tone2:", + ":man_in_manual_wheelchair_facing_right_medium_skin_tone:": ":man_in_manual_wheelchair_facing_right_tone3:", + ":man_in_manual_wheelchair_light_skin_tone:": ":man_in_manual_wheelchair_tone1:", + ":man_in_manual_wheelchair_medium_dark_skin_tone:": ":man_in_manual_wheelchair_tone4:", + ":man_in_manual_wheelchair_medium_light_skin_tone:": ":man_in_manual_wheelchair_tone2:", + ":man_in_manual_wheelchair_medium_skin_tone:": ":man_in_manual_wheelchair_tone3:", + ":man_in_motorized_wheelchair_dark_skin_tone:": ":man_in_motorized_wheelchair_tone5:", + ":man_in_motorized_wheelchair_facing_right_dark_skin_tone:": ":man_in_motorized_wheelchair_facing_right_tone5:", + ":man_in_motorized_wheelchair_facing_right_light_skin_tone:": ":man_in_motorized_wheelchair_facing_right_tone1:", + ":man_in_motorized_wheelchair_facing_right_medium_dark_skin_tone:": ":man_in_motorized_wheelchair_facing_right_tone4:", + ":man_in_motorized_wheelchair_facing_right_medium_light_skin_tone:": ":man_in_motorized_wheelchair_facing_right_tone2:", + ":man_in_motorized_wheelchair_facing_right_medium_skin_tone:": ":man_in_motorized_wheelchair_facing_right_tone3:", + ":man_in_motorized_wheelchair_light_skin_tone:": ":man_in_motorized_wheelchair_tone1:", + ":man_in_motorized_wheelchair_medium_dark_skin_tone:": ":man_in_motorized_wheelchair_tone4:", + ":man_in_motorized_wheelchair_medium_light_skin_tone:": ":man_in_motorized_wheelchair_tone2:", + ":man_in_motorized_wheelchair_medium_skin_tone:": ":man_in_motorized_wheelchair_tone3:", + ":man_in_steamy_room_dark_skin_tone:": ":man_in_steamy_room_tone5:", + ":man_in_steamy_room_light_skin_tone:": ":man_in_steamy_room_tone1:", + ":man_in_steamy_room_medium_dark_skin_tone:": ":man_in_steamy_room_tone4:", + ":man_in_steamy_room_medium_light_skin_tone:": ":man_in_steamy_room_tone2:", + ":man_in_steamy_room_medium_skin_tone:": ":man_in_steamy_room_tone3:", + ":man_in_tuxedo_dark_skin_tone:": ":man_in_tuxedo_tone5:", + ":man_in_tuxedo_light_skin_tone:": ":man_in_tuxedo_tone1:", + ":man_in_tuxedo_medium_dark_skin_tone:": ":man_in_tuxedo_tone4:", + ":man_in_tuxedo_medium_light_skin_tone:": ":man_in_tuxedo_tone2:", + ":man_in_tuxedo_medium_skin_tone:": ":man_in_tuxedo_tone3:", + ":man_judge_dark_skin_tone:": ":man_judge_tone5:", + ":man_judge_light_skin_tone:": ":man_judge_tone1:", + ":man_judge_medium_dark_skin_tone:": ":man_judge_tone4:", + ":man_judge_medium_light_skin_tone:": ":man_judge_tone2:", + ":man_judge_medium_skin_tone:": ":man_judge_tone3:", + ":man_juggling_dark_skin_tone:": ":man_juggling_tone5:", + ":man_juggling_light_skin_tone:": ":man_juggling_tone1:", + ":man_juggling_medium_dark_skin_tone:": ":man_juggling_tone4:", + ":man_juggling_medium_light_skin_tone:": ":man_juggling_tone2:", + ":man_juggling_medium_skin_tone:": ":man_juggling_tone3:", + ":man_kneeling_dark_skin_tone:": ":man_kneeling_tone5:", + ":man_kneeling_facing_right_dark_skin_tone:": ":man_kneeling_facing_right_tone5:", + ":man_kneeling_facing_right_light_skin_tone:": ":man_kneeling_facing_right_tone1:", + ":man_kneeling_facing_right_medium_dark_skin_tone:": ":man_kneeling_facing_right_tone4:", + ":man_kneeling_facing_right_medium_light_skin_tone:": ":man_kneeling_facing_right_tone2:", + ":man_kneeling_facing_right_medium_skin_tone:": ":man_kneeling_facing_right_tone3:", + ":man_kneeling_light_skin_tone:": ":man_kneeling_tone1:", + ":man_kneeling_medium_dark_skin_tone:": ":man_kneeling_tone4:", + ":man_kneeling_medium_light_skin_tone:": ":man_kneeling_tone2:", + ":man_kneeling_medium_skin_tone:": ":man_kneeling_tone3:", + ":man_lifting_weights_dark_skin_tone:": ":man_lifting_weights_tone5:", + ":man_lifting_weights_light_skin_tone:": ":man_lifting_weights_tone1:", + ":man_lifting_weights_medium_dark_skin_tone:": ":man_lifting_weights_tone4:", + ":man_lifting_weights_medium_light_skin_tone:": ":man_lifting_weights_tone2:", + ":man_lifting_weights_medium_skin_tone:": ":man_lifting_weights_tone3:", + ":man_light_skin_tone_beard:": ":man_tone1_beard:", + ":man_mage_dark_skin_tone:": ":man_mage_tone5:", + ":man_mage_light_skin_tone:": ":man_mage_tone1:", + ":man_mage_medium_dark_skin_tone:": ":man_mage_tone4:", + ":man_mage_medium_light_skin_tone:": ":man_mage_tone2:", + ":man_mage_medium_skin_tone:": ":man_mage_tone3:", + ":man_mechanic_dark_skin_tone:": ":man_mechanic_tone5:", + ":man_mechanic_light_skin_tone:": ":man_mechanic_tone1:", + ":man_mechanic_medium_dark_skin_tone:": ":man_mechanic_tone4:", + ":man_mechanic_medium_light_skin_tone:": ":man_mechanic_tone2:", + ":man_mechanic_medium_skin_tone:": ":man_mechanic_tone3:", + ":man_medium_dark_skin_tone_beard:": ":man_tone4_beard:", + ":man_medium_light_skin_tone_beard:": ":man_tone2_beard:", + ":man_medium_skin_tone_beard:": ":man_tone3_beard:", + ":man_mountain_biking_dark_skin_tone:": ":man_mountain_biking_tone5:", + ":man_mountain_biking_light_skin_tone:": ":man_mountain_biking_tone1:", + ":man_mountain_biking_medium_dark_skin_tone:": ":man_mountain_biking_tone4:", + ":man_mountain_biking_medium_light_skin_tone:": ":man_mountain_biking_tone2:", + ":man_mountain_biking_medium_skin_tone:": ":man_mountain_biking_tone3:", + ":man_office_worker_dark_skin_tone:": ":man_office_worker_tone5:", + ":man_office_worker_light_skin_tone:": ":man_office_worker_tone1:", + ":man_office_worker_medium_dark_skin_tone:": ":man_office_worker_tone4:", + ":man_office_worker_medium_light_skin_tone:": ":man_office_worker_tone2:", + ":man_office_worker_medium_skin_tone:": ":man_office_worker_tone3:", + ":man_pilot_dark_skin_tone:": ":man_pilot_tone5:", + ":man_pilot_light_skin_tone:": ":man_pilot_tone1:", + ":man_pilot_medium_dark_skin_tone:": ":man_pilot_tone4:", + ":man_pilot_medium_light_skin_tone:": ":man_pilot_tone2:", + ":man_pilot_medium_skin_tone:": ":man_pilot_tone3:", + ":man_playing_handball_dark_skin_tone:": ":man_playing_handball_tone5:", + ":man_playing_handball_light_skin_tone:": ":man_playing_handball_tone1:", + ":man_playing_handball_medium_dark_skin_tone:": ":man_playing_handball_tone4:", + ":man_playing_handball_medium_light_skin_tone:": ":man_playing_handball_tone2:", + ":man_playing_handball_medium_skin_tone:": ":man_playing_handball_tone3:", + ":man_playing_water_polo_dark_skin_tone:": ":man_playing_water_polo_tone5:", + ":man_playing_water_polo_light_skin_tone:": ":man_playing_water_polo_tone1:", + ":man_playing_water_polo_medium_dark_skin_tone:": ":man_playing_water_polo_tone4:", + ":man_playing_water_polo_medium_light_skin_tone:": ":man_playing_water_polo_tone2:", + ":man_playing_water_polo_medium_skin_tone:": ":man_playing_water_polo_tone3:", + ":man_police_officer_dark_skin_tone:": ":man_police_officer_tone5:", + ":man_police_officer_light_skin_tone:": ":man_police_officer_tone1:", + ":man_police_officer_medium_dark_skin_tone:": ":man_police_officer_tone4:", + ":man_police_officer_medium_light_skin_tone:": ":man_police_officer_tone2:", + ":man_police_officer_medium_skin_tone:": ":man_police_officer_tone3:", + ":man_pouting_dark_skin_tone:": ":man_pouting_tone5:", + ":man_pouting_light_skin_tone:": ":man_pouting_tone1:", + ":man_pouting_medium_dark_skin_tone:": ":man_pouting_tone4:", + ":man_pouting_medium_light_skin_tone:": ":man_pouting_tone2:", + ":man_pouting_medium_skin_tone:": ":man_pouting_tone3:", + ":man_raising_hand_dark_skin_tone:": ":man_raising_hand_tone5:", + ":man_raising_hand_light_skin_tone:": ":man_raising_hand_tone1:", + ":man_raising_hand_medium_dark_skin_tone:": ":man_raising_hand_tone4:", + ":man_raising_hand_medium_light_skin_tone:": ":man_raising_hand_tone2:", + ":man_raising_hand_medium_skin_tone:": ":man_raising_hand_tone3:", + ":man_red_hair:": ":man_red_haired:", + ":man_red_haired_dark_skin_tone:": ":man_red_haired_tone5:", + ":man_red_haired_light_skin_tone:": ":man_red_haired_tone1:", + ":man_red_haired_medium_dark_skin_tone:": ":man_red_haired_tone4:", + ":man_red_haired_medium_light_skin_tone:": ":man_red_haired_tone2:", + ":man_red_haired_medium_skin_tone:": ":man_red_haired_tone3:", + ":man_rowing_boat_dark_skin_tone:": ":man_rowing_boat_tone5:", + ":man_rowing_boat_light_skin_tone:": ":man_rowing_boat_tone1:", + ":man_rowing_boat_medium_dark_skin_tone:": ":man_rowing_boat_tone4:", + ":man_rowing_boat_medium_light_skin_tone:": ":man_rowing_boat_tone2:", + ":man_rowing_boat_medium_skin_tone:": ":man_rowing_boat_tone3:", + ":man_running_dark_skin_tone:": ":man_running_tone5:", + ":man_running_facing_right_dark_skin_tone:": ":man_running_facing_right_tone5:", + ":man_running_facing_right_light_skin_tone:": ":man_running_facing_right_tone1:", + ":man_running_facing_right_medium_dark_skin_tone:": ":man_running_facing_right_tone4:", + ":man_running_facing_right_medium_light_skin_tone:": ":man_running_facing_right_tone2:", + ":man_running_facing_right_medium_skin_tone:": ":man_running_facing_right_tone3:", + ":man_running_light_skin_tone:": ":man_running_tone1:", + ":man_running_medium_dark_skin_tone:": ":man_running_tone4:", + ":man_running_medium_light_skin_tone:": ":man_running_tone2:", + ":man_running_medium_skin_tone:": ":man_running_tone3:", + ":man_scientist_dark_skin_tone:": ":man_scientist_tone5:", + ":man_scientist_light_skin_tone:": ":man_scientist_tone1:", + ":man_scientist_medium_dark_skin_tone:": ":man_scientist_tone4:", + ":man_scientist_medium_light_skin_tone:": ":man_scientist_tone2:", + ":man_scientist_medium_skin_tone:": ":man_scientist_tone3:", + ":man_shrugging_dark_skin_tone:": ":man_shrugging_tone5:", + ":man_shrugging_light_skin_tone:": ":man_shrugging_tone1:", + ":man_shrugging_medium_dark_skin_tone:": ":man_shrugging_tone4:", + ":man_shrugging_medium_light_skin_tone:": ":man_shrugging_tone2:", + ":man_shrugging_medium_skin_tone:": ":man_shrugging_tone3:", + ":man_singer_dark_skin_tone:": ":man_singer_tone5:", + ":man_singer_light_skin_tone:": ":man_singer_tone1:", + ":man_singer_medium_dark_skin_tone:": ":man_singer_tone4:", + ":man_singer_medium_light_skin_tone:": ":man_singer_tone2:", + ":man_singer_medium_skin_tone:": ":man_singer_tone3:", + ":man_standing_dark_skin_tone:": ":man_standing_tone5:", + ":man_standing_light_skin_tone:": ":man_standing_tone1:", + ":man_standing_medium_dark_skin_tone:": ":man_standing_tone4:", + ":man_standing_medium_light_skin_tone:": ":man_standing_tone2:", + ":man_standing_medium_skin_tone:": ":man_standing_tone3:", + ":man_student_dark_skin_tone:": ":man_student_tone5:", + ":man_student_light_skin_tone:": ":man_student_tone1:", + ":man_student_medium_dark_skin_tone:": ":man_student_tone4:", + ":man_student_medium_light_skin_tone:": ":man_student_tone2:", + ":man_student_medium_skin_tone:": ":man_student_tone3:", + ":man_superhero_dark_skin_tone:": ":man_superhero_tone5:", + ":man_superhero_light_skin_tone:": ":man_superhero_tone1:", + ":man_superhero_medium_dark_skin_tone:": ":man_superhero_tone4:", + ":man_superhero_medium_light_skin_tone:": ":man_superhero_tone2:", + ":man_superhero_medium_skin_tone:": ":man_superhero_tone3:", + ":man_supervillain_dark_skin_tone:": ":man_supervillain_tone5:", + ":man_supervillain_light_skin_tone:": ":man_supervillain_tone1:", + ":man_supervillain_medium_dark_skin_tone:": ":man_supervillain_tone4:", + ":man_supervillain_medium_light_skin_tone:": ":man_supervillain_tone2:", + ":man_supervillain_medium_skin_tone:": ":man_supervillain_tone3:", + ":man_surfing_dark_skin_tone:": ":man_surfing_tone5:", + ":man_surfing_light_skin_tone:": ":man_surfing_tone1:", + ":man_surfing_medium_dark_skin_tone:": ":man_surfing_tone4:", + ":man_surfing_medium_light_skin_tone:": ":man_surfing_tone2:", + ":man_surfing_medium_skin_tone:": ":man_surfing_tone3:", + ":man_swimming_dark_skin_tone:": ":man_swimming_tone5:", + ":man_swimming_light_skin_tone:": ":man_swimming_tone1:", + ":man_swimming_medium_dark_skin_tone:": ":man_swimming_tone4:", + ":man_swimming_medium_light_skin_tone:": ":man_swimming_tone2:", + ":man_swimming_medium_skin_tone:": ":man_swimming_tone3:", + ":man_teacher_dark_skin_tone:": ":man_teacher_tone5:", + ":man_teacher_light_skin_tone:": ":man_teacher_tone1:", + ":man_teacher_medium_dark_skin_tone:": ":man_teacher_tone4:", + ":man_teacher_medium_light_skin_tone:": ":man_teacher_tone2:", + ":man_teacher_medium_skin_tone:": ":man_teacher_tone3:", + ":man_technologist_dark_skin_tone:": ":man_technologist_tone5:", + ":man_technologist_light_skin_tone:": ":man_technologist_tone1:", + ":man_technologist_medium_dark_skin_tone:": ":man_technologist_tone4:", + ":man_technologist_medium_light_skin_tone:": ":man_technologist_tone2:", + ":man_technologist_medium_skin_tone:": ":man_technologist_tone3:", + ":man_tipping_hand_dark_skin_tone:": ":man_tipping_hand_tone5:", + ":man_tipping_hand_light_skin_tone:": ":man_tipping_hand_tone1:", + ":man_tipping_hand_medium_dark_skin_tone:": ":man_tipping_hand_tone4:", + ":man_tipping_hand_medium_light_skin_tone:": ":man_tipping_hand_tone2:", + ":man_tipping_hand_medium_skin_tone:": ":man_tipping_hand_tone3:", + ":man_vampire_dark_skin_tone:": ":man_vampire_tone5:", + ":man_vampire_light_skin_tone:": ":man_vampire_tone1:", + ":man_vampire_medium_dark_skin_tone:": ":man_vampire_tone4:", + ":man_vampire_medium_light_skin_tone:": ":man_vampire_tone2:", + ":man_vampire_medium_skin_tone:": ":man_vampire_tone3:", + ":man_walking_dark_skin_tone:": ":man_walking_tone5:", + ":man_walking_facing_right_dark_skin_tone:": ":man_walking_facing_right_tone5:", + ":man_walking_facing_right_light_skin_tone:": ":man_walking_facing_right_tone1:", + ":man_walking_facing_right_medium_dark_skin_tone:": ":man_walking_facing_right_tone4:", + ":man_walking_facing_right_medium_light_skin_tone:": ":man_walking_facing_right_tone2:", + ":man_walking_facing_right_medium_skin_tone:": ":man_walking_facing_right_tone3:", + ":man_walking_light_skin_tone:": ":man_walking_tone1:", + ":man_walking_medium_dark_skin_tone:": ":man_walking_tone4:", + ":man_walking_medium_light_skin_tone:": ":man_walking_tone2:", + ":man_walking_medium_skin_tone:": ":man_walking_tone3:", + ":man_wearing_turban_dark_skin_tone:": ":man_wearing_turban_tone5:", + ":man_wearing_turban_light_skin_tone:": ":man_wearing_turban_tone1:", + ":man_wearing_turban_medium_dark_skin_tone:": ":man_wearing_turban_tone4:", + ":man_wearing_turban_medium_light_skin_tone:": ":man_wearing_turban_tone2:", + ":man_wearing_turban_medium_skin_tone:": ":man_wearing_turban_tone3:", + ":man_white_haired_dark_skin_tone:": ":man_white_haired_tone5:", + ":man_white_haired_light_skin_tone:": ":man_white_haired_tone1:", + ":man_white_haired_medium_dark_skin_tone:": ":man_white_haired_tone4:", + ":man_white_haired_medium_light_skin_tone:": ":man_white_haired_tone2:", + ":man_white_haired_medium_skin_tone:": ":man_white_haired_tone3:", + ":man_with_gua_pi_mao:": ":man_with_chinese_cap:", + ":man_with_gua_pi_mao_tone1:": ":man_with_chinese_cap_tone1:", + ":man_with_gua_pi_mao_tone2:": ":man_with_chinese_cap_tone2:", + ":man_with_gua_pi_mao_tone3:": ":man_with_chinese_cap_tone3:", + ":man_with_gua_pi_mao_tone4:": ":man_with_chinese_cap_tone4:", + ":man_with_gua_pi_mao_tone5:": ":man_with_chinese_cap_tone5:", + ":man_with_probing_cane_dark_skin_tone:": ":man_with_probing_cane_tone5:", + ":man_with_probing_cane_light_skin_tone:": ":man_with_probing_cane_tone1:", + ":man_with_probing_cane_medium_dark_skin_tone:": ":man_with_probing_cane_tone4:", + ":man_with_probing_cane_medium_light_skin_tone:": ":man_with_probing_cane_tone2:", + ":man_with_probing_cane_medium_skin_tone:": ":man_with_probing_cane_tone3:", + ":man_with_turban:": ":person_wearing_turban:", + ":man_with_turban_tone1:": ":person_wearing_turban_tone1:", + ":man_with_turban_tone2:": ":person_wearing_turban_tone2:", + ":man_with_turban_tone3:": ":person_wearing_turban_tone3:", + ":man_with_turban_tone4:": ":person_wearing_turban_tone4:", + ":man_with_turban_tone5:": ":person_wearing_turban_tone5:", + ":man_with_veil_dark_skin_tone:": ":man_with_veil_tone5:", + ":man_with_veil_light_skin_tone:": ":man_with_veil_tone1:", + ":man_with_veil_medium_dark_skin_tone:": ":man_with_veil_tone4:", + ":man_with_veil_medium_light_skin_tone:": ":man_with_veil_tone2:", + ":man_with_veil_medium_skin_tone:": ":man_with_veil_tone3:", + ":man_with_white_cane_facing_right_dark_skin_tone:": ":man_with_white_cane_facing_right_tone5:", + ":man_with_white_cane_facing_right_light_skin_tone:": ":man_with_white_cane_facing_right_tone1:", + ":man_with_white_cane_facing_right_medium_dark_skin_tone:": ":man_with_white_cane_facing_right_tone4:", + ":man_with_white_cane_facing_right_medium_light_skin_tone:": ":man_with_white_cane_facing_right_tone2:", + ":man_with_white_cane_facing_right_medium_skin_tone:": ":man_with_white_cane_facing_right_tone3:", + ":mantlepiece_clock:": ":clock:", + ":map_of_japan:": ":japan:", + ":massage:": ":person_getting_massage:", + ":massage_tone1:": ":person_getting_massage_tone1:", + ":massage_tone2:": ":person_getting_massage_tone2:", + ":massage_tone3:": ":person_getting_massage_tone3:", + ":massage_tone4:": ":person_getting_massage_tone4:", + ":massage_tone5:": ":person_getting_massage_tone5:", + ":mc:": ":flag_mc:", + ":md:": ":flag_md:", + ":me:": ":flag_me:", + ":mechanic_dark_skin_tone:": ":mechanic_tone5:", + ":mechanic_light_skin_tone:": ":mechanic_tone1:", + ":mechanic_medium_dark_skin_tone:": ":mechanic_tone4:", + ":mechanic_medium_light_skin_tone:": ":mechanic_tone2:", + ":mechanic_medium_skin_tone:": ":mechanic_tone3:", + ":megaphone:": ":mega:", + ":memo:": ":pencil:", + ":men_holding_hands_dark_skin_tone:": ":men_holding_hands_tone5:", + ":men_holding_hands_dark_skin_tone_light_skin_tone:": ":men_holding_hands_tone5_tone1:", + ":men_holding_hands_dark_skin_tone_medium_dark_skin_tone:": ":men_holding_hands_tone5_tone4:", + ":men_holding_hands_dark_skin_tone_medium_light_skin_tone:": ":men_holding_hands_tone5_tone2:", + ":men_holding_hands_dark_skin_tone_medium_skin_tone:": ":men_holding_hands_tone5_tone3:", + ":men_holding_hands_light_skin_tone:": ":men_holding_hands_tone1:", + ":men_holding_hands_light_skin_tone_dark_skin_tone:": ":men_holding_hands_tone1_tone5:", + ":men_holding_hands_light_skin_tone_medium_dark_skin_tone:": ":men_holding_hands_tone1_tone4:", + ":men_holding_hands_light_skin_tone_medium_light_skin_tone:": ":men_holding_hands_tone1_tone2:", + ":men_holding_hands_light_skin_tone_medium_skin_tone:": ":men_holding_hands_tone1_tone3:", + ":men_holding_hands_medium_dark_skin_tone:": ":men_holding_hands_tone4:", + ":men_holding_hands_medium_dark_skin_tone_dark_skin_tone:": ":men_holding_hands_tone4_tone5:", + ":men_holding_hands_medium_dark_skin_tone_light_skin_tone:": ":men_holding_hands_tone4_tone1:", + ":men_holding_hands_medium_dark_skin_tone_medium_light_skin_tone:": ":men_holding_hands_tone4_tone2:", + ":men_holding_hands_medium_dark_skin_tone_medium_skin_tone:": ":men_holding_hands_tone4_tone3:", + ":men_holding_hands_medium_light_skin_tone:": ":men_holding_hands_tone2:", + ":men_holding_hands_medium_light_skin_tone_dark_skin_tone:": ":men_holding_hands_tone2_tone5:", + ":men_holding_hands_medium_light_skin_tone_light_skin_tone:": ":men_holding_hands_tone2_tone1:", + ":men_holding_hands_medium_light_skin_tone_medium_dark_skin_tone:": ":men_holding_hands_tone2_tone4:", + ":men_holding_hands_medium_light_skin_tone_medium_skin_tone:": ":men_holding_hands_tone2_tone3:", + ":men_holding_hands_medium_skin_tone:": ":men_holding_hands_tone3:", + ":men_holding_hands_medium_skin_tone_dark_skin_tone:": ":men_holding_hands_tone3_tone5:", + ":men_holding_hands_medium_skin_tone_light_skin_tone:": ":men_holding_hands_tone3_tone1:", + ":men_holding_hands_medium_skin_tone_medium_dark_skin_tone:": ":men_holding_hands_tone3_tone4:", + ":men_holding_hands_medium_skin_tone_medium_light_skin_tone:": ":men_holding_hands_tone3_tone2:", + ":mens_room:": ":mens:", + ":mermaid_dark_skin_tone:": ":mermaid_tone5:", + ":mermaid_light_skin_tone:": ":mermaid_tone1:", + ":mermaid_medium_dark_skin_tone:": ":mermaid_tone4:", + ":mermaid_medium_light_skin_tone:": ":mermaid_tone2:", + ":mermaid_medium_skin_tone:": ":mermaid_tone3:", + ":merman_dark_skin_tone:": ":merman_tone5:", + ":merman_light_skin_tone:": ":merman_tone1:", + ":merman_medium_dark_skin_tone:": ":merman_tone4:", + ":merman_medium_light_skin_tone:": ":merman_tone2:", + ":merman_medium_skin_tone:": ":merman_tone3:", + ":merperson_dark_skin_tone:": ":merperson_tone5:", + ":merperson_light_skin_tone:": ":merperson_tone1:", + ":merperson_medium_dark_skin_tone:": ":merperson_tone4:", + ":merperson_medium_light_skin_tone:": ":merperson_tone2:", + ":merperson_medium_skin_tone:": ":merperson_tone3:", + ":mf:": ":flag_mf:", + ":mg:": ":flag_mg:", + ":mh:": ":flag_mh:", + ":mk:": ":flag_mk:", + ":ml:": ":flag_ml:", + ":mm:": ":flag_mm:", + ":mn:": ":flag_mn:", + ":mo:": ":flag_mo:", + ":moai:": ":moyai:", + ":money_bag:": ":moneybag:", + ":money_mouth_face:": ":money_mouth:", + ":mother_christmas:": ":mrs_claus:", + ":mother_christmas_tone1:": ":mrs_claus_tone1:", + ":mother_christmas_tone2:": ":mrs_claus_tone2:", + ":mother_christmas_tone3:": ":mrs_claus_tone3:", + ":mother_christmas_tone4:": ":mrs_claus_tone4:", + ":mother_christmas_tone5:": ":mrs_claus_tone5:", + ":motor_boat:": ":motorboat:", + ":motorbike:": ":motor_scooter:", + ":mountain_bicyclist:": ":person_mountain_biking:", + ":mountain_bicyclist_tone1:": ":person_mountain_biking_tone1:", + ":mountain_bicyclist_tone2:": ":person_mountain_biking_tone2:", + ":mountain_bicyclist_tone3:": ":person_mountain_biking_tone3:", + ":mountain_bicyclist_tone4:": ":person_mountain_biking_tone4:", + ":mountain_bicyclist_tone5:": ":person_mountain_biking_tone5:", + ":mouse_face:": ":mouse:", + ":mouth:": ":lips:", + ":mp:": ":flag_mp:", + ":mq:": ":flag_mq:", + ":mr:": ":flag_mr:", + ":ms:": ":flag_ms:", + ":mt:": ":flag_mt:", + ":mu:": ":flag_mu:", + ":musical_notes:": ":notes:", + ":muted_speaker:": ":mute:", + ":mv:": ":flag_mv:", + ":mw:": ":flag_mw:", + ":mx:": ":flag_mx:", + ":mx_claus_dark_skin_tone:": ":mx_claus_tone5:", + ":mx_claus_light_skin_tone:": ":mx_claus_tone1:", + ":mx_claus_medium_dark_skin_tone:": ":mx_claus_tone4:", + ":mx_claus_medium_light_skin_tone:": ":mx_claus_tone2:", + ":mx_claus_medium_skin_tone:": ":mx_claus_tone3:", + ":my:": ":flag_my:", + ":mz:": ":flag_mz:", + ":na:": ":flag_na:", + ":nail_polish:": ":nail_care:", + ":national_park:": ":park:", + ":nc:": ":flag_nc:", + ":ne:": ":flag_ne:", + ":nerd_face:": ":nerd:", + ":new_moon_face:": ":new_moon_with_face:", + ":next_track:": ":track_next:", + ":nf:": ":flag_nf:", + ":ni:": ":flag_ni:", + ":nigeria:": ":flag_ng:", + ":nine_oclock:": ":clock9:", + ":nine_thirty:": ":clock930:", + ":ninja_dark_skin_tone:": ":ninja_tone5:", + ":ninja_light_skin_tone:": ":ninja_tone1:", + ":ninja_medium_dark_skin_tone:": ":ninja_tone4:", + ":ninja_medium_light_skin_tone:": ":ninja_tone2:", + ":ninja_medium_skin_tone:": ":ninja_tone3:", + ":nl:": ":flag_nl:", + ":no:": ":flag_no:", + ":no_good:": ":person_gesturing_no:", + ":no_good_tone1:": ":person_gesturing_no_tone1:", + ":no_good_tone2:": ":person_gesturing_no_tone2:", + ":no_good_tone3:": ":person_gesturing_no_tone3:", + ":no_good_tone4:": ":person_gesturing_no_tone4:", + ":no_good_tone5:": ":person_gesturing_no_tone5:", + ":no_littering:": ":do_not_litter:", + ":np:": ":flag_np:", + ":nr:": ":flag_nr:", + ":nu:": ":flag_nu:", + ":nz:": ":flag_nz:", + ":office_worker_dark_skin_tone:": ":office_worker_tone5:", + ":office_worker_light_skin_tone:": ":office_worker_tone1:", + ":office_worker_medium_dark_skin_tone:": ":office_worker_tone4:", + ":office_worker_medium_light_skin_tone:": ":office_worker_tone2:", + ":office_worker_medium_skin_tone:": ":office_worker_tone3:", + ":ogre:": ":japanese_ogre:", + ":oil_drum:": ":oil:", + ":ok_woman:": ":person_gesturing_ok:", + ":ok_woman_tone1:": ":person_gesturing_ok_tone1:", + ":ok_woman_tone2:": ":person_gesturing_ok_tone2:", + ":ok_woman_tone3:": ":person_gesturing_ok_tone3:", + ":ok_woman_tone4:": ":person_gesturing_ok_tone4:", + ":ok_woman_tone5:": ":person_gesturing_ok_tone5:", + ":old_key:": ":key2:", + ":old_man:": ":older_man:", + ":old_woman:": ":older_woman:", + ":older_adult_dark_skin_tone:": ":older_adult_tone5:", + ":older_adult_light_skin_tone:": ":older_adult_tone1:", + ":older_adult_medium_dark_skin_tone:": ":older_adult_tone4:", + ":older_adult_medium_light_skin_tone:": ":older_adult_tone2:", + ":older_adult_medium_skin_tone:": ":older_adult_tone3:", + ":older_person:": ":older_adult:", + ":om:": ":flag_om:", + ":on_arrow:": ":on:", + ":oncoming_fist:": ":punch:", + ":one_oclock:": ":clock1:", + ":one_thirty:": ":clock130:", + ":open_book:": ":book:", + ":optical_disk:": ":cd:", + ":pa:": ":flag_pa:", + ":paella:": ":shallow_pan_of_food:", + ":palm_down_hand_dark_skin_tone:": ":palm_down_hand_tone5:", + ":palm_down_hand_light_skin_tone:": ":palm_down_hand_tone1:", + ":palm_down_hand_medium_dark_skin_tone:": ":palm_down_hand_tone4:", + ":palm_down_hand_medium_light_skin_tone:": ":palm_down_hand_tone2:", + ":palm_down_hand_medium_skin_tone:": ":palm_down_hand_tone3:", + ":palm_up_hand_dark_skin_tone:": ":palm_up_hand_tone5:", + ":palm_up_hand_light_skin_tone:": ":palm_up_hand_tone1:", + ":palm_up_hand_medium_dark_skin_tone:": ":palm_up_hand_tone4:", + ":palm_up_hand_medium_light_skin_tone:": ":palm_up_hand_tone2:", + ":palm_up_hand_medium_skin_tone:": ":palm_up_hand_tone3:", + ":palms_up_together_dark_skin_tone:": ":palms_up_together_tone5:", + ":palms_up_together_light_skin_tone:": ":palms_up_together_tone1:", + ":palms_up_together_medium_dark_skin_tone:": ":palms_up_together_tone4:", + ":palms_up_together_medium_light_skin_tone:": ":palms_up_together_tone2:", + ":palms_up_together_medium_skin_tone:": ":palms_up_together_tone3:", + ":panda:": ":panda_face:", + ":party_popper:": ":tada:", + ":passenger_ship:": ":cruise_ship:", + ":paw_prints:": ":feet:", + ":pe:": ":flag_pe:", + ":peace_symbol:": ":peace:", + ":pen:": ":pen_ballpoint:", + ":pensive_face:": ":pensive:", + ":people_holding_hands_dark_skin_tone:": ":people_holding_hands_tone5:", + ":people_holding_hands_dark_skin_tone_light_skin_tone:": ":people_holding_hands_tone5_tone1:", + ":people_holding_hands_dark_skin_tone_medium_dark_skin_tone:": ":people_holding_hands_tone5_tone4:", + ":people_holding_hands_dark_skin_tone_medium_light_skin_tone:": ":people_holding_hands_tone5_tone2:", + ":people_holding_hands_dark_skin_tone_medium_skin_tone:": ":people_holding_hands_tone5_tone3:", + ":people_holding_hands_light_skin_tone:": ":people_holding_hands_tone1:", + ":people_holding_hands_light_skin_tone_dark_skin_tone:": ":people_holding_hands_tone1_tone5:", + ":people_holding_hands_light_skin_tone_medium_dark_skin_tone:": ":people_holding_hands_tone1_tone4:", + ":people_holding_hands_light_skin_tone_medium_light_skin_tone:": ":people_holding_hands_tone1_tone2:", + ":people_holding_hands_light_skin_tone_medium_skin_tone:": ":people_holding_hands_tone1_tone3:", + ":people_holding_hands_medium_dark_skin_tone:": ":people_holding_hands_tone4:", + ":people_holding_hands_medium_dark_skin_tone_dark_skin_tone:": ":people_holding_hands_tone4_tone5:", + ":people_holding_hands_medium_dark_skin_tone_light_skin_tone:": ":people_holding_hands_tone4_tone1:", + ":people_holding_hands_medium_dark_skin_tone_medium_light_skin_tone:": ":people_holding_hands_tone4_tone2:", + ":people_holding_hands_medium_dark_skin_tone_medium_skin_tone:": ":people_holding_hands_tone4_tone3:", + ":people_holding_hands_medium_light_skin_tone:": ":people_holding_hands_tone2:", + ":people_holding_hands_medium_light_skin_tone_dark_skin_tone:": ":people_holding_hands_tone2_tone5:", + ":people_holding_hands_medium_light_skin_tone_light_skin_tone:": ":people_holding_hands_tone2_tone1:", + ":people_holding_hands_medium_light_skin_tone_medium_dark_skin_tone:": ":people_holding_hands_tone2_tone4:", + ":people_holding_hands_medium_light_skin_tone_medium_skin_tone:": ":people_holding_hands_tone2_tone3:", + ":people_holding_hands_medium_skin_tone:": ":people_holding_hands_tone3:", + ":people_holding_hands_medium_skin_tone_dark_skin_tone:": ":people_holding_hands_tone3_tone5:", + ":people_holding_hands_medium_skin_tone_light_skin_tone:": ":people_holding_hands_tone3_tone1:", + ":people_holding_hands_medium_skin_tone_medium_dark_skin_tone:": ":people_holding_hands_tone3_tone4:", + ":people_holding_hands_medium_skin_tone_medium_light_skin_tone:": ":people_holding_hands_tone3_tone2:", + ":person:": ":adult:", + ":person_beard:": ":bearded_person:", + ":person_climbing_dark_skin_tone:": ":person_climbing_tone5:", + ":person_climbing_light_skin_tone:": ":person_climbing_tone1:", + ":person_climbing_medium_dark_skin_tone:": ":person_climbing_tone4:", + ":person_climbing_medium_light_skin_tone:": ":person_climbing_tone2:", + ":person_climbing_medium_skin_tone:": ":person_climbing_tone3:", + ":person_dark_skin_tone_bald:": ":person_tone5_bald:", + ":person_dark_skin_tone_curly_hair:": ":person_tone5_curly_hair:", + ":person_dark_skin_tone_red_hair:": ":person_tone5_red_hair:", + ":person_dark_skin_tone_white_hair:": ":person_tone5_white_hair:", + ":person_feeding_baby_dark_skin_tone:": ":person_feeding_baby_tone5:", + ":person_feeding_baby_light_skin_tone:": ":person_feeding_baby_tone1:", + ":person_feeding_baby_medium_dark_skin_tone:": ":person_feeding_baby_tone4:", + ":person_feeding_baby_medium_light_skin_tone:": ":person_feeding_baby_tone2:", + ":person_feeding_baby_medium_skin_tone:": ":person_feeding_baby_tone3:", + ":person_golfing_dark_skin_tone:": ":person_golfing_tone5:", + ":person_golfing_light_skin_tone:": ":person_golfing_tone1:", + ":person_golfing_medium_dark_skin_tone:": ":person_golfing_tone4:", + ":person_golfing_medium_light_skin_tone:": ":person_golfing_tone2:", + ":person_golfing_medium_skin_tone:": ":person_golfing_tone3:", + ":person_in_bed:": ":sleeping_accommodation:", + ":person_in_bed_dark_skin_tone:": ":person_in_bed_tone5:", + ":person_in_bed_light_skin_tone:": ":person_in_bed_tone1:", + ":person_in_bed_medium_dark_skin_tone:": ":person_in_bed_tone4:", + ":person_in_bed_medium_light_skin_tone:": ":person_in_bed_tone2:", + ":person_in_bed_medium_skin_tone:": ":person_in_bed_tone3:", + ":person_in_lotus_position_dark_skin_tone:": ":person_in_lotus_position_tone5:", + ":person_in_lotus_position_light_skin_tone:": ":person_in_lotus_position_tone1:", + ":person_in_lotus_position_medium_dark_skin_tone:": ":person_in_lotus_position_tone4:", + ":person_in_lotus_position_medium_light_skin_tone:": ":person_in_lotus_position_tone2:", + ":person_in_lotus_position_medium_skin_tone:": ":person_in_lotus_position_tone3:", + ":person_in_manual_wheelchair_dark_skin_tone:": ":person_in_manual_wheelchair_tone5:", + ":person_in_manual_wheelchair_facing_right_dark_skin_tone:": ":person_in_manual_wheelchair_facing_right_tone5:", + ":person_in_manual_wheelchair_facing_right_light_skin_tone:": ":person_in_manual_wheelchair_facing_right_tone1:", + ":person_in_manual_wheelchair_facing_right_medium_dark_skin_tone:": ":person_in_manual_wheelchair_facing_right_tone4:", + ":person_in_manual_wheelchair_facing_right_medium_light_skin_tone:": ":person_in_manual_wheelchair_facing_right_tone2:", + ":person_in_manual_wheelchair_facing_right_medium_skin_tone:": ":person_in_manual_wheelchair_facing_right_tone3:", + ":person_in_manual_wheelchair_light_skin_tone:": ":person_in_manual_wheelchair_tone1:", + ":person_in_manual_wheelchair_medium_dark_skin_tone:": ":person_in_manual_wheelchair_tone4:", + ":person_in_manual_wheelchair_medium_light_skin_tone:": ":person_in_manual_wheelchair_tone2:", + ":person_in_manual_wheelchair_medium_skin_tone:": ":person_in_manual_wheelchair_tone3:", + ":person_in_motorized_wheelchair_dark_skin_tone:": ":person_in_motorized_wheelchair_tone5:", + ":person_in_motorized_wheelchair_facing_right_dark_skin_tone:": ":person_in_motorized_wheelchair_facing_right_tone5:", + ":person_in_motorized_wheelchair_facing_right_light_skin_tone:": ":person_in_motorized_wheelchair_facing_right_tone1:", + ":person_in_motorized_wheelchair_facing_right_medium_dark_skin_tone:": ":person_in_motorized_wheelchair_facing_right_tone4:", + ":person_in_motorized_wheelchair_facing_right_medium_light_skin_tone:": ":person_in_motorized_wheelchair_facing_right_tone2:", + ":person_in_motorized_wheelchair_facing_right_medium_skin_tone:": ":person_in_motorized_wheelchair_facing_right_tone3:", + ":person_in_motorized_wheelchair_light_skin_tone:": ":person_in_motorized_wheelchair_tone1:", + ":person_in_motorized_wheelchair_medium_dark_skin_tone:": ":person_in_motorized_wheelchair_tone4:", + ":person_in_motorized_wheelchair_medium_light_skin_tone:": ":person_in_motorized_wheelchair_tone2:", + ":person_in_motorized_wheelchair_medium_skin_tone:": ":person_in_motorized_wheelchair_tone3:", + ":person_in_steamy_room_dark_skin_tone:": ":person_in_steamy_room_tone5:", + ":person_in_steamy_room_light_skin_tone:": ":person_in_steamy_room_tone1:", + ":person_in_steamy_room_medium_dark_skin_tone:": ":person_in_steamy_room_tone4:", + ":person_in_steamy_room_medium_light_skin_tone:": ":person_in_steamy_room_tone2:", + ":person_in_steamy_room_medium_skin_tone:": ":person_in_steamy_room_tone3:", + ":person_kneeling_dark_skin_tone:": ":person_kneeling_tone5:", + ":person_kneeling_facing_right_dark_skin_tone:": ":person_kneeling_facing_right_tone5:", + ":person_kneeling_facing_right_light_skin_tone:": ":person_kneeling_facing_right_tone1:", + ":person_kneeling_facing_right_medium_dark_skin_tone:": ":person_kneeling_facing_right_tone4:", + ":person_kneeling_facing_right_medium_light_skin_tone:": ":person_kneeling_facing_right_tone2:", + ":person_kneeling_facing_right_medium_skin_tone:": ":person_kneeling_facing_right_tone3:", + ":person_kneeling_light_skin_tone:": ":person_kneeling_tone1:", + ":person_kneeling_medium_dark_skin_tone:": ":person_kneeling_tone4:", + ":person_kneeling_medium_light_skin_tone:": ":person_kneeling_tone2:", + ":person_kneeling_medium_skin_tone:": ":person_kneeling_tone3:", + ":person_light_skin_tone_bald:": ":person_tone1_bald:", + ":person_light_skin_tone_curly_hair:": ":person_tone1_curly_hair:", + ":person_light_skin_tone_red_hair:": ":person_tone1_red_hair:", + ":person_light_skin_tone_white_hair:": ":person_tone1_white_hair:", + ":person_medium_dark_skin_tone_bald:": ":person_tone4_bald:", + ":person_medium_dark_skin_tone_curly_hair:": ":person_tone4_curly_hair:", + ":person_medium_dark_skin_tone_red_hair:": ":person_tone4_red_hair:", + ":person_medium_dark_skin_tone_white_hair:": ":person_tone4_white_hair:", + ":person_medium_light_skin_tone_bald:": ":person_tone2_bald:", + ":person_medium_light_skin_tone_curly_hair:": ":person_tone2_curly_hair:", + ":person_medium_light_skin_tone_red_hair:": ":person_tone2_red_hair:", + ":person_medium_light_skin_tone_white_hair:": ":person_tone2_white_hair:", + ":person_medium_skin_tone_bald:": ":person_tone3_bald:", + ":person_medium_skin_tone_curly_hair:": ":person_tone3_curly_hair:", + ":person_medium_skin_tone_red_hair:": ":person_tone3_red_hair:", + ":person_medium_skin_tone_white_hair:": ":person_tone3_white_hair:", + ":person_running_facing_right_dark_skin_tone:": ":person_running_facing_right_tone5:", + ":person_running_facing_right_light_skin_tone:": ":person_running_facing_right_tone1:", + ":person_running_facing_right_medium_dark_skin_tone:": ":person_running_facing_right_tone4:", + ":person_running_facing_right_medium_light_skin_tone:": ":person_running_facing_right_tone2:", + ":person_running_facing_right_medium_skin_tone:": ":person_running_facing_right_tone3:", + ":person_standing_dark_skin_tone:": ":person_standing_tone5:", + ":person_standing_light_skin_tone:": ":person_standing_tone1:", + ":person_standing_medium_dark_skin_tone:": ":person_standing_tone4:", + ":person_standing_medium_light_skin_tone:": ":person_standing_tone2:", + ":person_standing_medium_skin_tone:": ":person_standing_tone3:", + ":person_walking_facing_right_dark_skin_tone:": ":person_walking_facing_right_tone5:", + ":person_walking_facing_right_light_skin_tone:": ":person_walking_facing_right_tone1:", + ":person_walking_facing_right_medium_dark_skin_tone:": ":person_walking_facing_right_tone4:", + ":person_walking_facing_right_medium_light_skin_tone:": ":person_walking_facing_right_tone2:", + ":person_walking_facing_right_medium_skin_tone:": ":person_walking_facing_right_tone3:", + ":person_with_ball:": ":person_bouncing_ball:", + ":person_with_ball_tone1:": ":person_bouncing_ball_tone1:", + ":person_with_ball_tone2:": ":person_bouncing_ball_tone2:", + ":person_with_ball_tone3:": ":person_bouncing_ball_tone3:", + ":person_with_ball_tone4:": ":person_bouncing_ball_tone4:", + ":person_with_ball_tone5:": ":person_bouncing_ball_tone5:", + ":person_with_blond_hair:": ":blond_haired_person:", + ":person_with_blond_hair_tone1:": ":blond_haired_person_tone1:", + ":person_with_blond_hair_tone2:": ":blond_haired_person_tone2:", + ":person_with_blond_hair_tone3:": ":blond_haired_person_tone3:", + ":person_with_blond_hair_tone4:": ":blond_haired_person_tone4:", + ":person_with_blond_hair_tone5:": ":blond_haired_person_tone5:", + ":person_with_crown_dark_skin_tone:": ":person_with_crown_tone5:", + ":person_with_crown_light_skin_tone:": ":person_with_crown_tone1:", + ":person_with_crown_medium_dark_skin_tone:": ":person_with_crown_tone4:", + ":person_with_crown_medium_light_skin_tone:": ":person_with_crown_tone2:", + ":person_with_crown_medium_skin_tone:": ":person_with_crown_tone3:", + ":person_with_pouting_face:": ":person_pouting:", + ":person_with_pouting_face_tone1:": ":person_pouting_tone1:", + ":person_with_pouting_face_tone2:": ":person_pouting_tone2:", + ":person_with_pouting_face_tone3:": ":person_pouting_tone3:", + ":person_with_pouting_face_tone4:": ":person_pouting_tone4:", + ":person_with_pouting_face_tone5:": ":person_pouting_tone5:", + ":person_with_probing_cane_dark_skin_tone:": ":person_with_probing_cane_tone5:", + ":person_with_probing_cane_light_skin_tone:": ":person_with_probing_cane_tone1:", + ":person_with_probing_cane_medium_dark_skin_tone:": ":person_with_probing_cane_tone4:", + ":person_with_probing_cane_medium_light_skin_tone:": ":person_with_probing_cane_tone2:", + ":person_with_probing_cane_medium_skin_tone:": ":person_with_probing_cane_tone3:", + ":person_with_white_cane_facing_right_dark_skin_tone:": ":person_with_white_cane_facing_right_tone5:", + ":person_with_white_cane_facing_right_light_skin_tone:": ":person_with_white_cane_facing_right_tone1:", + ":person_with_white_cane_facing_right_medium_dark_skin_tone:": ":person_with_white_cane_facing_right_tone4:", + ":person_with_white_cane_facing_right_medium_light_skin_tone:": ":person_with_white_cane_facing_right_tone2:", + ":person_with_white_cane_facing_right_medium_skin_tone:": ":person_with_white_cane_facing_right_tone3:", + ":pf:": ":flag_pf:", + ":pg:": ":flag_pg:", + ":ph:": ":flag_ph:", + ":pig_face:": ":pig:", + ":pile_of_poo:": ":poop:", + ":pilot_dark_skin_tone:": ":pilot_tone5:", + ":pilot_light_skin_tone:": ":pilot_tone1:", + ":pilot_medium_dark_skin_tone:": ":pilot_tone4:", + ":pilot_medium_light_skin_tone:": ":pilot_tone2:", + ":pilot_medium_skin_tone:": ":pilot_tone3:", + ":pinched_fingers_dark_skin_tone:": ":pinched_fingers_tone5:", + ":pinched_fingers_light_skin_tone:": ":pinched_fingers_tone1:", + ":pinched_fingers_medium_dark_skin_tone:": ":pinched_fingers_tone4:", + ":pinched_fingers_medium_light_skin_tone:": ":pinched_fingers_tone2:", + ":pinched_fingers_medium_skin_tone:": ":pinched_fingers_tone3:", + ":pinching_hand_dark_skin_tone:": ":pinching_hand_tone5:", + ":pinching_hand_light_skin_tone:": ":pinching_hand_tone1:", + ":pinching_hand_medium_dark_skin_tone:": ":pinching_hand_tone4:", + ":pinching_hand_medium_light_skin_tone:": ":pinching_hand_tone2:", + ":pinching_hand_medium_skin_tone:": ":pinching_hand_tone3:", + ":pistol:": ":gun:", + ":pk:": ":flag_pk:", + ":pl:": ":flag_pl:", + ":pm:": ":flag_pm:", + ":pn:": ":flag_pn:", + ":poo:": ":poop:", + ":pot_of_food:": ":stew:", + ":pouting_face:": ":rage:", + ":pr:": ":flag_pr:", + ":pregnant_man_dark_skin_tone:": ":pregnant_man_tone5:", + ":pregnant_man_light_skin_tone:": ":pregnant_man_tone1:", + ":pregnant_man_medium_dark_skin_tone:": ":pregnant_man_tone4:", + ":pregnant_man_medium_light_skin_tone:": ":pregnant_man_tone2:", + ":pregnant_man_medium_skin_tone:": ":pregnant_man_tone3:", + ":pregnant_person_dark_skin_tone:": ":pregnant_person_tone5:", + ":pregnant_person_light_skin_tone:": ":pregnant_person_tone1:", + ":pregnant_person_medium_dark_skin_tone:": ":pregnant_person_tone4:", + ":pregnant_person_medium_light_skin_tone:": ":pregnant_person_tone2:", + ":pregnant_person_medium_skin_tone:": ":pregnant_person_tone3:", + ":previous_track:": ":track_previous:", + ":prohibited:": ":no_entry_sign:", + ":ps:": ":flag_ps:", + ":pt:": ":flag_pt:", + ":pudding:": ":custard:", + ":puzzle_piece:": ":jigsaw:", + ":pw:": ":flag_pw:", + ":py:": ":flag_py:", + ":qa:": ":flag_qa:", + ":question_mark:": ":question:", + ":rabbit_face:": ":rabbit:", + ":racing_car:": ":race_car:", + ":racing_motorcycle:": ":motorcycle:", + ":radioactive_sign:": ":radioactive:", + ":railroad_track:": ":railway_track:", + ":raised_fist:": ":fist:", + ":raised_hand_with_fingers_splayed:": ":hand_splayed:", + ":raised_hand_with_fingers_splayed_tone1:": ":hand_splayed_tone1:", + ":raised_hand_with_fingers_splayed_tone2:": ":hand_splayed_tone2:", + ":raised_hand_with_fingers_splayed_tone3:": ":hand_splayed_tone3:", + ":raised_hand_with_fingers_splayed_tone4:": ":hand_splayed_tone4:", + ":raised_hand_with_fingers_splayed_tone5:": ":hand_splayed_tone5:", + ":raised_hand_with_part_between_middle_and_ring_fingers:": ":vulcan:", + ":raised_hand_with_part_between_middle_and_ring_fingers_tone1:": ":vulcan_tone1:", + ":raised_hand_with_part_between_middle_and_ring_fingers_tone2:": ":vulcan_tone2:", + ":raised_hand_with_part_between_middle_and_ring_fingers_tone3:": ":vulcan_tone3:", + ":raised_hand_with_part_between_middle_and_ring_fingers_tone4:": ":vulcan_tone4:", + ":raised_hand_with_part_between_middle_and_ring_fingers_tone5:": ":vulcan_tone5:", + ":raising_hand:": ":person_raising_hand:", + ":raising_hand_tone1:": ":person_raising_hand_tone1:", + ":raising_hand_tone2:": ":person_raising_hand_tone2:", + ":raising_hand_tone3:": ":person_raising_hand_tone3:", + ":raising_hand_tone4:": ":person_raising_hand_tone4:", + ":raising_hand_tone5:": ":person_raising_hand_tone5:", + ":raising_hands:": ":raised_hands:", + ":re:": ":flag_re:", + ":red_apple:": ":apple:", + ":red_hair:": ":red_haired:", + ":red_heart:": ":heart:", + ":relieved_face:": ":relieved:", + ":reversed_hand_with_middle_finger_extended:": ":middle_finger:", + ":reversed_hand_with_middle_finger_extended_tone1:": ":middle_finger_tone1:", + ":reversed_hand_with_middle_finger_extended_tone2:": ":middle_finger_tone2:", + ":reversed_hand_with_middle_finger_extended_tone3:": ":middle_finger_tone3:", + ":reversed_hand_with_middle_finger_extended_tone4:": ":middle_finger_tone4:", + ":reversed_hand_with_middle_finger_extended_tone5:": ":middle_finger_tone5:", + ":rhinoceros:": ":rhino:", + ":right_anger_bubble:": ":anger_right:", + ":right_arrow:": ":arrow_right:", + ":right_fist:": ":right_facing_fist:", + ":right_fist_tone1:": ":right_facing_fist_tone1:", + ":right_fist_tone2:": ":right_facing_fist_tone2:", + ":right_fist_tone3:": ":right_facing_fist_tone3:", + ":right_fist_tone4:": ":right_facing_fist_tone4:", + ":right_fist_tone5:": ":right_facing_fist_tone5:", + ":rightwards_hand_dark_skin_tone:": ":rightwards_hand_tone5:", + ":rightwards_hand_light_skin_tone:": ":rightwards_hand_tone1:", + ":rightwards_hand_medium_dark_skin_tone:": ":rightwards_hand_tone4:", + ":rightwards_hand_medium_light_skin_tone:": ":rightwards_hand_tone2:", + ":rightwards_hand_medium_skin_tone:": ":rightwards_hand_tone3:", + ":rightwards_pushing_hand_dark_skin_tone:": ":rightwards_pushing_hand_tone5:", + ":rightwards_pushing_hand_light_skin_tone:": ":rightwards_pushing_hand_tone1:", + ":rightwards_pushing_hand_medium_dark_skin_tone:": ":rightwards_pushing_hand_tone4:", + ":rightwards_pushing_hand_medium_light_skin_tone:": ":rightwards_pushing_hand_tone2:", + ":rightwards_pushing_hand_medium_skin_tone:": ":rightwards_pushing_hand_tone3:", + ":ro:": ":flag_ro:", + ":robot_face:": ":robot:", + ":rolled_up_newspaper:": ":newspaper2:", + ":rolling_on_the_floor_laughing:": ":rofl:", + ":rowboat:": ":person_rowing_boat:", + ":rowboat_tone1:": ":person_rowing_boat_tone1:", + ":rowboat_tone2:": ":person_rowing_boat_tone2:", + ":rowboat_tone3:": ":person_rowing_boat_tone3:", + ":rowboat_tone4:": ":person_rowing_boat_tone4:", + ":rowboat_tone5:": ":person_rowing_boat_tone5:", + ":rs:": ":flag_rs:", + ":ru:": ":flag_ru:", + ":runner:": ":person_running:", + ":runner_tone1:": ":person_running_tone1:", + ":runner_tone2:": ":person_running_tone2:", + ":runner_tone3:": ":person_running_tone3:", + ":runner_tone4:": ":person_running_tone4:", + ":runner_tone5:": ":person_running_tone5:", + ":running_shirt:": ":running_shirt_with_sash:", + ":running_shoe:": ":athletic_shoe:", + ":rw:": ":flag_rw:", + ":santa_claus:": ":santa:", + ":satisfied:": ":laughing:", + ":saudi:": ":flag_sa:", + ":saudiarabia:": ":flag_sa:", + ":sb:": ":flag_sb:", + ":sc:": ":flag_sc:", + ":scientist_dark_skin_tone:": ":scientist_tone5:", + ":scientist_light_skin_tone:": ":scientist_tone1:", + ":scientist_medium_dark_skin_tone:": ":scientist_tone4:", + ":scientist_medium_light_skin_tone:": ":scientist_tone2:", + ":scientist_medium_skin_tone:": ":scientist_tone3:", + ":scorpio:": ":scorpius:", + ":sd:": ":flag_sd:", + ":se:": ":flag_se:", + ":second_place_medal:": ":second_place:", + ":seven_oclock:": ":clock7:", + ":seven_thirty:": ":clock730:", + ":sg:": ":flag_sg:", + ":sh:": ":flag_sh:", + ":shaking_hands:": ":handshake:", + ":sheaf_of_rice:": ":ear_of_rice:", + ":shelled_peanut:": ":peanuts:", + ":shit:": ":poop:", + ":shooting_star:": ":stars:", + ":shopping_trolley:": ":shopping_cart:", + ":shortcake:": ":cake:", + ":shrug:": ":person_shrugging:", + ":shrug_tone1:": ":person_shrugging_tone1:", + ":shrug_tone2:": ":person_shrugging_tone2:", + ":shrug_tone3:": ":person_shrugging_tone3:", + ":shrug_tone4:": ":person_shrugging_tone4:", + ":shrug_tone5:": ":person_shrugging_tone5:", + ":si:": ":flag_si:", + ":sick:": ":nauseated_face:", + ":sign_of_the_horns:": ":metal:", + ":sign_of_the_horns_tone1:": ":metal_tone1:", + ":sign_of_the_horns_tone2:": ":metal_tone2:", + ":sign_of_the_horns_tone3:": ":metal_tone3:", + ":sign_of_the_horns_tone4:": ":metal_tone4:", + ":sign_of_the_horns_tone5:": ":metal_tone5:", + ":singer_dark_skin_tone:": ":singer_tone5:", + ":singer_light_skin_tone:": ":singer_tone1:", + ":singer_medium_dark_skin_tone:": ":singer_tone4:", + ":singer_medium_light_skin_tone:": ":singer_tone2:", + ":singer_medium_skin_tone:": ":singer_tone3:", + ":six_oclock:": ":clock6:", + ":six_thirty:": ":clock630:", + ":sj:": ":flag_sj:", + ":sk:": ":flag_sk:", + ":skeleton:": ":skull:", + ":skis:": ":ski:", + ":skull_and_crossbones:": ":skull_crossbones:", + ":sl:": ":flag_sl:", + ":sleeping_face:": ":sleeping:", + ":sleepy_face:": ":sleepy:", + ":sleuth_or_spy:": ":detective:", + ":sleuth_or_spy_tone1:": ":detective_tone1:", + ":sleuth_or_spy_tone2:": ":detective_tone2:", + ":sleuth_or_spy_tone3:": ":detective_tone3:", + ":sleuth_or_spy_tone4:": ":detective_tone4:", + ":sleuth_or_spy_tone5:": ":detective_tone5:", + ":slightly_frowning_face:": ":slight_frown:", + ":slightly_smiling_face:": ":slight_smile:", + ":sm:": ":flag_sm:", + ":small_airplane:": ":airplane_small:", + ":smiling_face:": ":relaxed:", + ":smirking_face:": ":smirk:", + ":sn:": ":flag_sn:", + ":sneeze:": ":sneezing_face:", + ":snow_capped_mountain:": ":mountain_snow:", + ":snowboarder_dark_skin_tone:": ":snowboarder_tone5:", + ":snowboarder_light_skin_tone:": ":snowboarder_tone1:", + ":snowboarder_medium_dark_skin_tone:": ":snowboarder_tone4:", + ":snowboarder_medium_light_skin_tone:": ":snowboarder_tone2:", + ":snowboarder_medium_skin_tone:": ":snowboarder_tone3:", + ":so:": ":flag_so:", + ":soccer_ball:": ":soccer:", + ":soon_arrow:": ":soon:", + ":spade_suit:": ":spades:", + ":speaking_head_in_silhouette:": ":speaking_head:", + ":spiral_calendar_pad:": ":calendar_spiral:", + ":spiral_note_pad:": ":notepad_spiral:", + ":spiral_shell:": ":shell:", + ":sports_medal:": ":medal:", + ":spy:": ":detective:", + ":spy_tone1:": ":detective_tone1:", + ":spy_tone2:": ":detective_tone2:", + ":spy_tone3:": ":detective_tone3:", + ":spy_tone4:": ":detective_tone4:", + ":spy_tone5:": ":detective_tone5:", + ":sr:": ":flag_sr:", + ":ss:": ":flag_ss:", + ":st:": ":flag_st:", + ":steaming_bowl:": ":ramen:", + ":stop_sign:": ":octagonal_sign:", + ":student_dark_skin_tone:": ":student_tone5:", + ":student_light_skin_tone:": ":student_tone1:", + ":student_medium_dark_skin_tone:": ":student_tone4:", + ":student_medium_light_skin_tone:": ":student_tone2:", + ":student_medium_skin_tone:": ":student_tone3:", + ":studio_microphone:": ":microphone2:", + ":stuffed_pita:": ":stuffed_flatbread:", + ":sun:": ":sunny:", + ":sunset:": ":city_sunset:", + ":superhero_dark_skin_tone:": ":superhero_tone5:", + ":superhero_light_skin_tone:": ":superhero_tone1:", + ":superhero_medium_dark_skin_tone:": ":superhero_tone4:", + ":superhero_medium_light_skin_tone:": ":superhero_tone2:", + ":superhero_medium_skin_tone:": ":superhero_tone3:", + ":supervillain_dark_skin_tone:": ":supervillain_tone5:", + ":supervillain_light_skin_tone:": ":supervillain_tone1:", + ":supervillain_medium_dark_skin_tone:": ":supervillain_tone4:", + ":supervillain_medium_light_skin_tone:": ":supervillain_tone2:", + ":supervillain_medium_skin_tone:": ":supervillain_tone3:", + ":surfer:": ":person_surfing:", + ":surfer_tone1:": ":person_surfing_tone1:", + ":surfer_tone2:": ":person_surfing_tone2:", + ":surfer_tone3:": ":person_surfing_tone3:", + ":surfer_tone4:": ":person_surfing_tone4:", + ":surfer_tone5:": ":person_surfing_tone5:", + ":sv:": ":flag_sv:", + ":swimmer:": ":person_swimming:", + ":swimmer_tone1:": ":person_swimming_tone1:", + ":swimmer_tone2:": ":person_swimming_tone2:", + ":swimmer_tone3:": ":person_swimming_tone3:", + ":swimmer_tone4:": ":person_swimming_tone4:", + ":swimmer_tone5:": ":person_swimming_tone5:", + ":sx:": ":flag_sx:", + ":sy:": ":flag_sy:", + ":sz:": ":flag_sz:", + ":t_shirt:": ":shirt:", + ":ta:": ":flag_ta:", + ":table_tennis:": ":ping_pong:", + ":tc:": ":flag_tc:", + ":td:": ":flag_td:", + ":teacher_dark_skin_tone:": ":teacher_tone5:", + ":teacher_light_skin_tone:": ":teacher_tone1:", + ":teacher_medium_dark_skin_tone:": ":teacher_tone4:", + ":teacher_medium_light_skin_tone:": ":teacher_tone2:", + ":teacher_medium_skin_tone:": ":teacher_tone3:", + ":technologist_dark_skin_tone:": ":technologist_tone5:", + ":technologist_light_skin_tone:": ":technologist_tone1:", + ":technologist_medium_dark_skin_tone:": ":technologist_tone4:", + ":technologist_medium_light_skin_tone:": ":technologist_tone2:", + ":technologist_medium_skin_tone:": ":technologist_tone3:", + ":television:": ":tv:", + ":ten_oclock:": ":clock10:", + ":ten_thirty:": ":clock1030:", + ":tf:": ":flag_tf:", + ":tg:": ":flag_tg:", + ":th:": ":flag_th:", + ":thinking_face:": ":thinking:", + ":third_place_medal:": ":third_place:", + ":three_button_mouse:": ":mouse_three_button:", + ":three_oclock:": ":clock3:", + ":three_thirty:": ":clock330:", + ":thumbdown:": ":thumbsdown:", + ":thumbdown_tone1:": ":thumbsdown_tone1:", + ":thumbdown_tone2:": ":thumbsdown_tone2:", + ":thumbdown_tone3:": ":thumbsdown_tone3:", + ":thumbdown_tone4:": ":thumbsdown_tone4:", + ":thumbdown_tone5:": ":thumbsdown_tone5:", + ":thumbs_down:": ":thumbsdown:", + ":thumbs_up:": ":thumbsup:", + ":thumbup:": ":thumbsup:", + ":thumbup_tone1:": ":thumbsup_tone1:", + ":thumbup_tone2:": ":thumbsup_tone2:", + ":thumbup_tone3:": ":thumbsup_tone3:", + ":thumbup_tone4:": ":thumbsup_tone4:", + ":thumbup_tone5:": ":thumbsup_tone5:", + ":thunder_cloud_and_rain:": ":thunder_cloud_rain:", + ":tiger_face:": ":tiger:", + ":timer_clock:": ":timer:", + ":tj:": ":flag_tj:", + ":tk:": ":flag_tk:", + ":tl:": ":flag_tl:", + ":tn:": ":flag_tn:", + ":to:": ":flag_to:", + ":top_arrow:": ":top:", + ":top_hat:": ":tophat:", + ":tornado:": ":cloud_tornado:", + ":tr:": ":flag_tr:", + ":trade_mark:": ":tm:", + ":tram_car:": ":train:", + ":tt:": ":flag_tt:", + ":turkmenistan:": ":flag_tm:", + ":tuvalu:": ":flag_tv:", + ":tuxedo_tone1:": ":person_in_tuxedo_tone1:", + ":tuxedo_tone2:": ":person_in_tuxedo_tone2:", + ":tuxedo_tone3:": ":person_in_tuxedo_tone3:", + ":tuxedo_tone4:": ":person_in_tuxedo_tone4:", + ":tuxedo_tone5:": ":person_in_tuxedo_tone5:", + ":tw:": ":flag_tw:", + ":twelve_oclock:": ":clock12:", + ":twelve_thirty:": ":clock1230:", + ":two_oclock:": ":clock2:", + ":two_thirty:": ":clock230:", + ":tz:": ":flag_tz:", + ":ua:": ":flag_ua:", + ":ug:": ":flag_ug:", + ":um:": ":flag_um:", + ":umbrella_on_ground:": ":beach_umbrella:", + ":unamused_face:": ":unamused:", + ":unicorn_face:": ":unicorn:", + ":unlocked:": ":unlock:", + ":up_arrow:": ":arrow_up:", + ":up_down_arrow:": ":arrow_up_down:", + ":up_left_arrow:": ":arrow_upper_left:", + ":upside_down_face:": ":upside_down:", + ":us:": ":flag_us:", + ":uy:": ":flag_uy:", + ":uz:": ":flag_uz:", + ":va:": ":flag_va:", + ":vampire_dark_skin_tone:": ":vampire_tone5:", + ":vampire_light_skin_tone:": ":vampire_tone1:", + ":vampire_medium_dark_skin_tone:": ":vampire_tone4:", + ":vampire_medium_light_skin_tone:": ":vampire_tone2:", + ":vampire_medium_skin_tone:": ":vampire_tone3:", + ":vc:": ":flag_vc:", + ":ve:": ":flag_ve:", + ":vg:": ":flag_vg:", + ":vi:": ":flag_vi:", + ":victory_hand:": ":v:", + ":videocassette:": ":vhs:", + ":vn:": ":flag_vn:", + ":vu:": ":flag_vu:", + ":vulcan_salute:": ":vulcan:", + ":walking:": ":person_walking:", + ":walking_tone1:": ":person_walking_tone1:", + ":walking_tone2:": ":person_walking_tone2:", + ":walking_tone3:": ":person_walking_tone3:", + ":walking_tone4:": ":person_walking_tone4:", + ":walking_tone5:": ":person_walking_tone5:", + ":water_closet:": ":wc:", + ":water_polo:": ":person_playing_water_polo:", + ":water_polo_tone1:": ":person_playing_water_polo_tone1:", + ":water_polo_tone2:": ":person_playing_water_polo_tone2:", + ":water_polo_tone3:": ":person_playing_water_polo_tone3:", + ":water_polo_tone4:": ":person_playing_water_polo_tone4:", + ":water_polo_tone5:": ":person_playing_water_polo_tone5:", + ":water_wave:": ":ocean:", + ":waving_black_flag:": ":flag_black:", + ":waving_hand:": ":wave:", + ":waving_white_flag:": ":flag_white:", + ":weary_cat:": ":scream_cat:", + ":weary_face:": ":weary:", + ":weight_lifter:": ":person_lifting_weights:", + ":weight_lifter_tone1:": ":person_lifting_weights_tone1:", + ":weight_lifter_tone2:": ":person_lifting_weights_tone2:", + ":weight_lifter_tone3:": ":person_lifting_weights_tone3:", + ":weight_lifter_tone4:": ":person_lifting_weights_tone4:", + ":weight_lifter_tone5:": ":person_lifting_weights_tone5:", + ":wf:": ":flag_wf:", + ":whisky:": ":tumbler_glass:", + ":white_flag:": ":flag_white:", + ":white_frowning_face:": ":frowning2:", + ":white_hair:": ":white_haired:", + ":white_sun_behind_cloud:": ":white_sun_cloud:", + ":white_sun_behind_cloud_with_rain:": ":white_sun_rain_cloud:", + ":white_sun_with_small_cloud:": ":white_sun_small_cloud:", + ":wilted_flower:": ":wilted_rose:", + ":wind_face:": ":wind_blowing_face:", + ":winking_face:": ":wink:", + ":woman_and_man_holding_hands_dark_skin_tone:": ":woman_and_man_holding_hands_tone5:", + ":woman_and_man_holding_hands_dark_skin_tone_light_skin_tone:": ":woman_and_man_holding_hands_tone5_tone1:", + ":woman_and_man_holding_hands_dark_skin_tone_medium_dark_skin_tone:": ":woman_and_man_holding_hands_tone5_tone4:", + ":woman_and_man_holding_hands_dark_skin_tone_medium_light_skin_tone:": ":woman_and_man_holding_hands_tone5_tone2:", + ":woman_and_man_holding_hands_dark_skin_tone_medium_skin_tone:": ":woman_and_man_holding_hands_tone5_tone3:", + ":woman_and_man_holding_hands_light_skin_tone:": ":woman_and_man_holding_hands_tone1:", + ":woman_and_man_holding_hands_light_skin_tone_dark_skin_tone:": ":woman_and_man_holding_hands_tone1_tone5:", + ":woman_and_man_holding_hands_light_skin_tone_medium_dark_skin_tone:": ":woman_and_man_holding_hands_tone1_tone4:", + ":woman_and_man_holding_hands_light_skin_tone_medium_light_skin_tone:": ":woman_and_man_holding_hands_tone1_tone2:", + ":woman_and_man_holding_hands_light_skin_tone_medium_skin_tone:": ":woman_and_man_holding_hands_tone1_tone3:", + ":woman_and_man_holding_hands_medium_dark_skin_tone:": ":woman_and_man_holding_hands_tone4:", + ":woman_and_man_holding_hands_medium_dark_skin_tone_dark_skin_tone:": ":woman_and_man_holding_hands_tone4_tone5:", + ":woman_and_man_holding_hands_medium_dark_skin_tone_light_skin_tone:": ":woman_and_man_holding_hands_tone4_tone1:", + ":woman_and_man_holding_hands_medium_dark_skin_tone_medium_light_skin_tone:": ":woman_and_man_holding_hands_tone4_tone2:", + ":woman_and_man_holding_hands_medium_dark_skin_tone_medium_skin_tone:": ":woman_and_man_holding_hands_tone4_tone3:", + ":woman_and_man_holding_hands_medium_light_skin_tone:": ":woman_and_man_holding_hands_tone2:", + ":woman_and_man_holding_hands_medium_light_skin_tone_dark_skin_tone:": ":woman_and_man_holding_hands_tone2_tone5:", + ":woman_and_man_holding_hands_medium_light_skin_tone_light_skin_tone:": ":woman_and_man_holding_hands_tone2_tone1:", + ":woman_and_man_holding_hands_medium_light_skin_tone_medium_dark_skin_tone:": ":woman_and_man_holding_hands_tone2_tone4:", + ":woman_and_man_holding_hands_medium_light_skin_tone_medium_skin_tone:": ":woman_and_man_holding_hands_tone2_tone3:", + ":woman_and_man_holding_hands_medium_skin_tone:": ":woman_and_man_holding_hands_tone3:", + ":woman_and_man_holding_hands_medium_skin_tone_dark_skin_tone:": ":woman_and_man_holding_hands_tone3_tone5:", + ":woman_and_man_holding_hands_medium_skin_tone_light_skin_tone:": ":woman_and_man_holding_hands_tone3_tone1:", + ":woman_and_man_holding_hands_medium_skin_tone_medium_dark_skin_tone:": ":woman_and_man_holding_hands_tone3_tone4:", + ":woman_and_man_holding_hands_medium_skin_tone_medium_light_skin_tone:": ":woman_and_man_holding_hands_tone3_tone2:", + ":woman_artist_dark_skin_tone:": ":woman_artist_tone5:", + ":woman_artist_light_skin_tone:": ":woman_artist_tone1:", + ":woman_artist_medium_dark_skin_tone:": ":woman_artist_tone4:", + ":woman_artist_medium_light_skin_tone:": ":woman_artist_tone2:", + ":woman_artist_medium_skin_tone:": ":woman_artist_tone3:", + ":woman_astronaut_dark_skin_tone:": ":woman_astronaut_tone5:", + ":woman_astronaut_light_skin_tone:": ":woman_astronaut_tone1:", + ":woman_astronaut_medium_dark_skin_tone:": ":woman_astronaut_tone4:", + ":woman_astronaut_medium_light_skin_tone:": ":woman_astronaut_tone2:", + ":woman_astronaut_medium_skin_tone:": ":woman_astronaut_tone3:", + ":woman_bald_dark_skin_tone:": ":woman_bald_tone5:", + ":woman_bald_light_skin_tone:": ":woman_bald_tone1:", + ":woman_bald_medium_dark_skin_tone:": ":woman_bald_tone4:", + ":woman_bald_medium_light_skin_tone:": ":woman_bald_tone2:", + ":woman_bald_medium_skin_tone:": ":woman_bald_tone3:", + ":woman_biking_dark_skin_tone:": ":woman_biking_tone5:", + ":woman_biking_light_skin_tone:": ":woman_biking_tone1:", + ":woman_biking_medium_dark_skin_tone:": ":woman_biking_tone4:", + ":woman_biking_medium_light_skin_tone:": ":woman_biking_tone2:", + ":woman_biking_medium_skin_tone:": ":woman_biking_tone3:", + ":woman_bouncing_ball_dark_skin_tone:": ":woman_bouncing_ball_tone5:", + ":woman_bouncing_ball_light_skin_tone:": ":woman_bouncing_ball_tone1:", + ":woman_bouncing_ball_medium_dark_skin_tone:": ":woman_bouncing_ball_tone4:", + ":woman_bouncing_ball_medium_light_skin_tone:": ":woman_bouncing_ball_tone2:", + ":woman_bouncing_ball_medium_skin_tone:": ":woman_bouncing_ball_tone3:", + ":woman_bowing_dark_skin_tone:": ":woman_bowing_tone5:", + ":woman_bowing_light_skin_tone:": ":woman_bowing_tone1:", + ":woman_bowing_medium_dark_skin_tone:": ":woman_bowing_tone4:", + ":woman_bowing_medium_light_skin_tone:": ":woman_bowing_tone2:", + ":woman_bowing_medium_skin_tone:": ":woman_bowing_tone3:", + ":woman_cartwheeling_dark_skin_tone:": ":woman_cartwheeling_tone5:", + ":woman_cartwheeling_light_skin_tone:": ":woman_cartwheeling_tone1:", + ":woman_cartwheeling_medium_dark_skin_tone:": ":woman_cartwheeling_tone4:", + ":woman_cartwheeling_medium_light_skin_tone:": ":woman_cartwheeling_tone2:", + ":woman_cartwheeling_medium_skin_tone:": ":woman_cartwheeling_tone3:", + ":woman_climbing_dark_skin_tone:": ":woman_climbing_tone5:", + ":woman_climbing_light_skin_tone:": ":woman_climbing_tone1:", + ":woman_climbing_medium_dark_skin_tone:": ":woman_climbing_tone4:", + ":woman_climbing_medium_light_skin_tone:": ":woman_climbing_tone2:", + ":woman_climbing_medium_skin_tone:": ":woman_climbing_tone3:", + ":woman_construction_worker_dark_skin_tone:": ":woman_construction_worker_tone5:", + ":woman_construction_worker_light_skin_tone:": ":woman_construction_worker_tone1:", + ":woman_construction_worker_medium_dark_skin_tone:": ":woman_construction_worker_tone4:", + ":woman_construction_worker_medium_light_skin_tone:": ":woman_construction_worker_tone2:", + ":woman_construction_worker_medium_skin_tone:": ":woman_construction_worker_tone3:", + ":woman_cook_dark_skin_tone:": ":woman_cook_tone5:", + ":woman_cook_light_skin_tone:": ":woman_cook_tone1:", + ":woman_cook_medium_dark_skin_tone:": ":woman_cook_tone4:", + ":woman_cook_medium_light_skin_tone:": ":woman_cook_tone2:", + ":woman_cook_medium_skin_tone:": ":woman_cook_tone3:", + ":woman_curly_haired_dark_skin_tone:": ":woman_curly_haired_tone5:", + ":woman_curly_haired_light_skin_tone:": ":woman_curly_haired_tone1:", + ":woman_curly_haired_medium_dark_skin_tone:": ":woman_curly_haired_tone4:", + ":woman_curly_haired_medium_light_skin_tone:": ":woman_curly_haired_tone2:", + ":woman_curly_haired_medium_skin_tone:": ":woman_curly_haired_tone3:", + ":woman_dancing:": ":dancer:", + ":woman_dark_skin_tone_beard:": ":woman_tone5_beard:", + ":woman_detective_dark_skin_tone:": ":woman_detective_tone5:", + ":woman_detective_light_skin_tone:": ":woman_detective_tone1:", + ":woman_detective_medium_dark_skin_tone:": ":woman_detective_tone4:", + ":woman_detective_medium_light_skin_tone:": ":woman_detective_tone2:", + ":woman_detective_medium_skin_tone:": ":woman_detective_tone3:", + ":woman_elf_dark_skin_tone:": ":woman_elf_tone5:", + ":woman_elf_light_skin_tone:": ":woman_elf_tone1:", + ":woman_elf_medium_dark_skin_tone:": ":woman_elf_tone4:", + ":woman_elf_medium_light_skin_tone:": ":woman_elf_tone2:", + ":woman_elf_medium_skin_tone:": ":woman_elf_tone3:", + ":woman_facepalming_dark_skin_tone:": ":woman_facepalming_tone5:", + ":woman_facepalming_light_skin_tone:": ":woman_facepalming_tone1:", + ":woman_facepalming_medium_dark_skin_tone:": ":woman_facepalming_tone4:", + ":woman_facepalming_medium_light_skin_tone:": ":woman_facepalming_tone2:", + ":woman_facepalming_medium_skin_tone:": ":woman_facepalming_tone3:", + ":woman_factory_worker_dark_skin_tone:": ":woman_factory_worker_tone5:", + ":woman_factory_worker_light_skin_tone:": ":woman_factory_worker_tone1:", + ":woman_factory_worker_medium_dark_skin_tone:": ":woman_factory_worker_tone4:", + ":woman_factory_worker_medium_light_skin_tone:": ":woman_factory_worker_tone2:", + ":woman_factory_worker_medium_skin_tone:": ":woman_factory_worker_tone3:", + ":woman_fairy_dark_skin_tone:": ":woman_fairy_tone5:", + ":woman_fairy_light_skin_tone:": ":woman_fairy_tone1:", + ":woman_fairy_medium_dark_skin_tone:": ":woman_fairy_tone4:", + ":woman_fairy_medium_light_skin_tone:": ":woman_fairy_tone2:", + ":woman_fairy_medium_skin_tone:": ":woman_fairy_tone3:", + ":woman_farmer_dark_skin_tone:": ":woman_farmer_tone5:", + ":woman_farmer_light_skin_tone:": ":woman_farmer_tone1:", + ":woman_farmer_medium_dark_skin_tone:": ":woman_farmer_tone4:", + ":woman_farmer_medium_light_skin_tone:": ":woman_farmer_tone2:", + ":woman_farmer_medium_skin_tone:": ":woman_farmer_tone3:", + ":woman_feeding_baby_dark_skin_tone:": ":woman_feeding_baby_tone5:", + ":woman_feeding_baby_light_skin_tone:": ":woman_feeding_baby_tone1:", + ":woman_feeding_baby_medium_dark_skin_tone:": ":woman_feeding_baby_tone4:", + ":woman_feeding_baby_medium_light_skin_tone:": ":woman_feeding_baby_tone2:", + ":woman_feeding_baby_medium_skin_tone:": ":woman_feeding_baby_tone3:", + ":woman_firefighter_dark_skin_tone:": ":woman_firefighter_tone5:", + ":woman_firefighter_light_skin_tone:": ":woman_firefighter_tone1:", + ":woman_firefighter_medium_dark_skin_tone:": ":woman_firefighter_tone4:", + ":woman_firefighter_medium_light_skin_tone:": ":woman_firefighter_tone2:", + ":woman_firefighter_medium_skin_tone:": ":woman_firefighter_tone3:", + ":woman_frowning_dark_skin_tone:": ":woman_frowning_tone5:", + ":woman_frowning_light_skin_tone:": ":woman_frowning_tone1:", + ":woman_frowning_medium_dark_skin_tone:": ":woman_frowning_tone4:", + ":woman_frowning_medium_light_skin_tone:": ":woman_frowning_tone2:", + ":woman_frowning_medium_skin_tone:": ":woman_frowning_tone3:", + ":woman_gesturing_no_dark_skin_tone:": ":woman_gesturing_no_tone5:", + ":woman_gesturing_no_light_skin_tone:": ":woman_gesturing_no_tone1:", + ":woman_gesturing_no_medium_dark_skin_tone:": ":woman_gesturing_no_tone4:", + ":woman_gesturing_no_medium_light_skin_tone:": ":woman_gesturing_no_tone2:", + ":woman_gesturing_no_medium_skin_tone:": ":woman_gesturing_no_tone3:", + ":woman_gesturing_ok_dark_skin_tone:": ":woman_gesturing_ok_tone5:", + ":woman_gesturing_ok_light_skin_tone:": ":woman_gesturing_ok_tone1:", + ":woman_gesturing_ok_medium_dark_skin_tone:": ":woman_gesturing_ok_tone4:", + ":woman_gesturing_ok_medium_light_skin_tone:": ":woman_gesturing_ok_tone2:", + ":woman_gesturing_ok_medium_skin_tone:": ":woman_gesturing_ok_tone3:", + ":woman_getting_face_massage_dark_skin_tone:": ":woman_getting_face_massage_tone5:", + ":woman_getting_face_massage_light_skin_tone:": ":woman_getting_face_massage_tone1:", + ":woman_getting_face_massage_medium_dark_skin_tone:": ":woman_getting_face_massage_tone4:", + ":woman_getting_face_massage_medium_light_skin_tone:": ":woman_getting_face_massage_tone2:", + ":woman_getting_face_massage_medium_skin_tone:": ":woman_getting_face_massage_tone3:", + ":woman_getting_haircut_dark_skin_tone:": ":woman_getting_haircut_tone5:", + ":woman_getting_haircut_light_skin_tone:": ":woman_getting_haircut_tone1:", + ":woman_getting_haircut_medium_dark_skin_tone:": ":woman_getting_haircut_tone4:", + ":woman_getting_haircut_medium_light_skin_tone:": ":woman_getting_haircut_tone2:", + ":woman_getting_haircut_medium_skin_tone:": ":woman_getting_haircut_tone3:", + ":woman_golfing_dark_skin_tone:": ":woman_golfing_tone5:", + ":woman_golfing_light_skin_tone:": ":woman_golfing_tone1:", + ":woman_golfing_medium_dark_skin_tone:": ":woman_golfing_tone4:", + ":woman_golfing_medium_light_skin_tone:": ":woman_golfing_tone2:", + ":woman_golfing_medium_skin_tone:": ":woman_golfing_tone3:", + ":woman_guard_dark_skin_tone:": ":woman_guard_tone5:", + ":woman_guard_light_skin_tone:": ":woman_guard_tone1:", + ":woman_guard_medium_dark_skin_tone:": ":woman_guard_tone4:", + ":woman_guard_medium_light_skin_tone:": ":woman_guard_tone2:", + ":woman_guard_medium_skin_tone:": ":woman_guard_tone3:", + ":woman_health_worker_dark_skin_tone:": ":woman_health_worker_tone5:", + ":woman_health_worker_light_skin_tone:": ":woman_health_worker_tone1:", + ":woman_health_worker_medium_dark_skin_tone:": ":woman_health_worker_tone4:", + ":woman_health_worker_medium_light_skin_tone:": ":woman_health_worker_tone2:", + ":woman_health_worker_medium_skin_tone:": ":woman_health_worker_tone3:", + ":woman_in_lotus_position_dark_skin_tone:": ":woman_in_lotus_position_tone5:", + ":woman_in_lotus_position_light_skin_tone:": ":woman_in_lotus_position_tone1:", + ":woman_in_lotus_position_medium_dark_skin_tone:": ":woman_in_lotus_position_tone4:", + ":woman_in_lotus_position_medium_light_skin_tone:": ":woman_in_lotus_position_tone2:", + ":woman_in_lotus_position_medium_skin_tone:": ":woman_in_lotus_position_tone3:", + ":woman_in_manual_wheelchair_dark_skin_tone:": ":woman_in_manual_wheelchair_tone5:", + ":woman_in_manual_wheelchair_facing_right_dark_skin_tone:": ":woman_in_manual_wheelchair_facing_right_tone5:", + ":woman_in_manual_wheelchair_facing_right_light_skin_tone:": ":woman_in_manual_wheelchair_facing_right_tone1:", + ":woman_in_manual_wheelchair_facing_right_medium_dark_skin_tone:": ":woman_in_manual_wheelchair_facing_right_tone4:", + ":woman_in_manual_wheelchair_facing_right_medium_light_skin_tone:": ":woman_in_manual_wheelchair_facing_right_tone2:", + ":woman_in_manual_wheelchair_facing_right_medium_skin_tone:": ":woman_in_manual_wheelchair_facing_right_tone3:", + ":woman_in_manual_wheelchair_light_skin_tone:": ":woman_in_manual_wheelchair_tone1:", + ":woman_in_manual_wheelchair_medium_dark_skin_tone:": ":woman_in_manual_wheelchair_tone4:", + ":woman_in_manual_wheelchair_medium_light_skin_tone:": ":woman_in_manual_wheelchair_tone2:", + ":woman_in_manual_wheelchair_medium_skin_tone:": ":woman_in_manual_wheelchair_tone3:", + ":woman_in_motorized_wheelchair_dark_skin_tone:": ":woman_in_motorized_wheelchair_tone5:", + ":woman_in_motorized_wheelchair_facing_right_dark_skin_tone:": ":woman_in_motorized_wheelchair_facing_right_tone5:", + ":woman_in_motorized_wheelchair_facing_right_light_skin_tone:": ":woman_in_motorized_wheelchair_facing_right_tone1:", + ":woman_in_motorized_wheelchair_facing_right_medium_dark_skin_tone:": ":woman_in_motorized_wheelchair_facing_right_tone4:", + ":woman_in_motorized_wheelchair_facing_right_medium_light_skin_tone:": ":woman_in_motorized_wheelchair_facing_right_tone2:", + ":woman_in_motorized_wheelchair_facing_right_medium_skin_tone:": ":woman_in_motorized_wheelchair_facing_right_tone3:", + ":woman_in_motorized_wheelchair_light_skin_tone:": ":woman_in_motorized_wheelchair_tone1:", + ":woman_in_motorized_wheelchair_medium_dark_skin_tone:": ":woman_in_motorized_wheelchair_tone4:", + ":woman_in_motorized_wheelchair_medium_light_skin_tone:": ":woman_in_motorized_wheelchair_tone2:", + ":woman_in_motorized_wheelchair_medium_skin_tone:": ":woman_in_motorized_wheelchair_tone3:", + ":woman_in_steamy_room_dark_skin_tone:": ":woman_in_steamy_room_tone5:", + ":woman_in_steamy_room_light_skin_tone:": ":woman_in_steamy_room_tone1:", + ":woman_in_steamy_room_medium_dark_skin_tone:": ":woman_in_steamy_room_tone4:", + ":woman_in_steamy_room_medium_light_skin_tone:": ":woman_in_steamy_room_tone2:", + ":woman_in_steamy_room_medium_skin_tone:": ":woman_in_steamy_room_tone3:", + ":woman_in_tuxedo_dark_skin_tone:": ":woman_in_tuxedo_tone5:", + ":woman_in_tuxedo_light_skin_tone:": ":woman_in_tuxedo_tone1:", + ":woman_in_tuxedo_medium_dark_skin_tone:": ":woman_in_tuxedo_tone4:", + ":woman_in_tuxedo_medium_light_skin_tone:": ":woman_in_tuxedo_tone2:", + ":woman_in_tuxedo_medium_skin_tone:": ":woman_in_tuxedo_tone3:", + ":woman_judge_dark_skin_tone:": ":woman_judge_tone5:", + ":woman_judge_light_skin_tone:": ":woman_judge_tone1:", + ":woman_judge_medium_dark_skin_tone:": ":woman_judge_tone4:", + ":woman_judge_medium_light_skin_tone:": ":woman_judge_tone2:", + ":woman_judge_medium_skin_tone:": ":woman_judge_tone3:", + ":woman_juggling_dark_skin_tone:": ":woman_juggling_tone5:", + ":woman_juggling_light_skin_tone:": ":woman_juggling_tone1:", + ":woman_juggling_medium_dark_skin_tone:": ":woman_juggling_tone4:", + ":woman_juggling_medium_light_skin_tone:": ":woman_juggling_tone2:", + ":woman_juggling_medium_skin_tone:": ":woman_juggling_tone3:", + ":woman_kneeling_dark_skin_tone:": ":woman_kneeling_tone5:", + ":woman_kneeling_facing_right_dark_skin_tone:": ":woman_kneeling_facing_right_tone5:", + ":woman_kneeling_facing_right_light_skin_tone:": ":woman_kneeling_facing_right_tone1:", + ":woman_kneeling_facing_right_medium_dark_skin_tone:": ":woman_kneeling_facing_right_tone4:", + ":woman_kneeling_facing_right_medium_light_skin_tone:": ":woman_kneeling_facing_right_tone2:", + ":woman_kneeling_facing_right_medium_skin_tone:": ":woman_kneeling_facing_right_tone3:", + ":woman_kneeling_light_skin_tone:": ":woman_kneeling_tone1:", + ":woman_kneeling_medium_dark_skin_tone:": ":woman_kneeling_tone4:", + ":woman_kneeling_medium_light_skin_tone:": ":woman_kneeling_tone2:", + ":woman_kneeling_medium_skin_tone:": ":woman_kneeling_tone3:", + ":woman_lifting_weights_dark_skin_tone:": ":woman_lifting_weights_tone5:", + ":woman_lifting_weights_light_skin_tone:": ":woman_lifting_weights_tone1:", + ":woman_lifting_weights_medium_dark_skin_tone:": ":woman_lifting_weights_tone4:", + ":woman_lifting_weights_medium_light_skin_tone:": ":woman_lifting_weights_tone2:", + ":woman_lifting_weights_medium_skin_tone:": ":woman_lifting_weights_tone3:", + ":woman_light_skin_tone_beard:": ":woman_tone1_beard:", + ":woman_mage_dark_skin_tone:": ":woman_mage_tone5:", + ":woman_mage_light_skin_tone:": ":woman_mage_tone1:", + ":woman_mage_medium_dark_skin_tone:": ":woman_mage_tone4:", + ":woman_mage_medium_light_skin_tone:": ":woman_mage_tone2:", + ":woman_mage_medium_skin_tone:": ":woman_mage_tone3:", + ":woman_mechanic_dark_skin_tone:": ":woman_mechanic_tone5:", + ":woman_mechanic_light_skin_tone:": ":woman_mechanic_tone1:", + ":woman_mechanic_medium_dark_skin_tone:": ":woman_mechanic_tone4:", + ":woman_mechanic_medium_light_skin_tone:": ":woman_mechanic_tone2:", + ":woman_mechanic_medium_skin_tone:": ":woman_mechanic_tone3:", + ":woman_medium_dark_skin_tone_beard:": ":woman_tone4_beard:", + ":woman_medium_light_skin_tone_beard:": ":woman_tone2_beard:", + ":woman_medium_skin_tone_beard:": ":woman_tone3_beard:", + ":woman_mountain_biking_dark_skin_tone:": ":woman_mountain_biking_tone5:", + ":woman_mountain_biking_light_skin_tone:": ":woman_mountain_biking_tone1:", + ":woman_mountain_biking_medium_dark_skin_tone:": ":woman_mountain_biking_tone4:", + ":woman_mountain_biking_medium_light_skin_tone:": ":woman_mountain_biking_tone2:", + ":woman_mountain_biking_medium_skin_tone:": ":woman_mountain_biking_tone3:", + ":woman_office_worker_dark_skin_tone:": ":woman_office_worker_tone5:", + ":woman_office_worker_light_skin_tone:": ":woman_office_worker_tone1:", + ":woman_office_worker_medium_dark_skin_tone:": ":woman_office_worker_tone4:", + ":woman_office_worker_medium_light_skin_tone:": ":woman_office_worker_tone2:", + ":woman_office_worker_medium_skin_tone:": ":woman_office_worker_tone3:", + ":woman_pilot_dark_skin_tone:": ":woman_pilot_tone5:", + ":woman_pilot_light_skin_tone:": ":woman_pilot_tone1:", + ":woman_pilot_medium_dark_skin_tone:": ":woman_pilot_tone4:", + ":woman_pilot_medium_light_skin_tone:": ":woman_pilot_tone2:", + ":woman_pilot_medium_skin_tone:": ":woman_pilot_tone3:", + ":woman_playing_handball_dark_skin_tone:": ":woman_playing_handball_tone5:", + ":woman_playing_handball_light_skin_tone:": ":woman_playing_handball_tone1:", + ":woman_playing_handball_medium_dark_skin_tone:": ":woman_playing_handball_tone4:", + ":woman_playing_handball_medium_light_skin_tone:": ":woman_playing_handball_tone2:", + ":woman_playing_handball_medium_skin_tone:": ":woman_playing_handball_tone3:", + ":woman_playing_water_polo_dark_skin_tone:": ":woman_playing_water_polo_tone5:", + ":woman_playing_water_polo_light_skin_tone:": ":woman_playing_water_polo_tone1:", + ":woman_playing_water_polo_medium_dark_skin_tone:": ":woman_playing_water_polo_tone4:", + ":woman_playing_water_polo_medium_light_skin_tone:": ":woman_playing_water_polo_tone2:", + ":woman_playing_water_polo_medium_skin_tone:": ":woman_playing_water_polo_tone3:", + ":woman_police_officer_dark_skin_tone:": ":woman_police_officer_tone5:", + ":woman_police_officer_light_skin_tone:": ":woman_police_officer_tone1:", + ":woman_police_officer_medium_dark_skin_tone:": ":woman_police_officer_tone4:", + ":woman_police_officer_medium_light_skin_tone:": ":woman_police_officer_tone2:", + ":woman_police_officer_medium_skin_tone:": ":woman_police_officer_tone3:", + ":woman_pouting_dark_skin_tone:": ":woman_pouting_tone5:", + ":woman_pouting_light_skin_tone:": ":woman_pouting_tone1:", + ":woman_pouting_medium_dark_skin_tone:": ":woman_pouting_tone4:", + ":woman_pouting_medium_light_skin_tone:": ":woman_pouting_tone2:", + ":woman_pouting_medium_skin_tone:": ":woman_pouting_tone3:", + ":woman_raising_hand_dark_skin_tone:": ":woman_raising_hand_tone5:", + ":woman_raising_hand_light_skin_tone:": ":woman_raising_hand_tone1:", + ":woman_raising_hand_medium_dark_skin_tone:": ":woman_raising_hand_tone4:", + ":woman_raising_hand_medium_light_skin_tone:": ":woman_raising_hand_tone2:", + ":woman_raising_hand_medium_skin_tone:": ":woman_raising_hand_tone3:", + ":woman_red_haired_dark_skin_tone:": ":woman_red_haired_tone5:", + ":woman_red_haired_light_skin_tone:": ":woman_red_haired_tone1:", + ":woman_red_haired_medium_dark_skin_tone:": ":woman_red_haired_tone4:", + ":woman_red_haired_medium_light_skin_tone:": ":woman_red_haired_tone2:", + ":woman_red_haired_medium_skin_tone:": ":woman_red_haired_tone3:", + ":woman_rowing_boat_dark_skin_tone:": ":woman_rowing_boat_tone5:", + ":woman_rowing_boat_light_skin_tone:": ":woman_rowing_boat_tone1:", + ":woman_rowing_boat_medium_dark_skin_tone:": ":woman_rowing_boat_tone4:", + ":woman_rowing_boat_medium_light_skin_tone:": ":woman_rowing_boat_tone2:", + ":woman_rowing_boat_medium_skin_tone:": ":woman_rowing_boat_tone3:", + ":woman_running_dark_skin_tone:": ":woman_running_tone5:", + ":woman_running_facing_right_dark_skin_tone:": ":woman_running_facing_right_tone5:", + ":woman_running_facing_right_light_skin_tone:": ":woman_running_facing_right_tone1:", + ":woman_running_facing_right_medium_dark_skin_tone:": ":woman_running_facing_right_tone4:", + ":woman_running_facing_right_medium_light_skin_tone:": ":woman_running_facing_right_tone2:", + ":woman_running_facing_right_medium_skin_tone:": ":woman_running_facing_right_tone3:", + ":woman_running_light_skin_tone:": ":woman_running_tone1:", + ":woman_running_medium_dark_skin_tone:": ":woman_running_tone4:", + ":woman_running_medium_light_skin_tone:": ":woman_running_tone2:", + ":woman_running_medium_skin_tone:": ":woman_running_tone3:", + ":woman_scientist_dark_skin_tone:": ":woman_scientist_tone5:", + ":woman_scientist_light_skin_tone:": ":woman_scientist_tone1:", + ":woman_scientist_medium_dark_skin_tone:": ":woman_scientist_tone4:", + ":woman_scientist_medium_light_skin_tone:": ":woman_scientist_tone2:", + ":woman_scientist_medium_skin_tone:": ":woman_scientist_tone3:", + ":woman_shrugging_dark_skin_tone:": ":woman_shrugging_tone5:", + ":woman_shrugging_light_skin_tone:": ":woman_shrugging_tone1:", + ":woman_shrugging_medium_dark_skin_tone:": ":woman_shrugging_tone4:", + ":woman_shrugging_medium_light_skin_tone:": ":woman_shrugging_tone2:", + ":woman_shrugging_medium_skin_tone:": ":woman_shrugging_tone3:", + ":woman_singer_dark_skin_tone:": ":woman_singer_tone5:", + ":woman_singer_light_skin_tone:": ":woman_singer_tone1:", + ":woman_singer_medium_dark_skin_tone:": ":woman_singer_tone4:", + ":woman_singer_medium_light_skin_tone:": ":woman_singer_tone2:", + ":woman_singer_medium_skin_tone:": ":woman_singer_tone3:", + ":woman_standing_dark_skin_tone:": ":woman_standing_tone5:", + ":woman_standing_light_skin_tone:": ":woman_standing_tone1:", + ":woman_standing_medium_dark_skin_tone:": ":woman_standing_tone4:", + ":woman_standing_medium_light_skin_tone:": ":woman_standing_tone2:", + ":woman_standing_medium_skin_tone:": ":woman_standing_tone3:", + ":woman_student_dark_skin_tone:": ":woman_student_tone5:", + ":woman_student_light_skin_tone:": ":woman_student_tone1:", + ":woman_student_medium_dark_skin_tone:": ":woman_student_tone4:", + ":woman_student_medium_light_skin_tone:": ":woman_student_tone2:", + ":woman_student_medium_skin_tone:": ":woman_student_tone3:", + ":woman_superhero_dark_skin_tone:": ":woman_superhero_tone5:", + ":woman_superhero_light_skin_tone:": ":woman_superhero_tone1:", + ":woman_superhero_medium_dark_skin_tone:": ":woman_superhero_tone4:", + ":woman_superhero_medium_light_skin_tone:": ":woman_superhero_tone2:", + ":woman_superhero_medium_skin_tone:": ":woman_superhero_tone3:", + ":woman_supervillain_dark_skin_tone:": ":woman_supervillain_tone5:", + ":woman_supervillain_light_skin_tone:": ":woman_supervillain_tone1:", + ":woman_supervillain_medium_dark_skin_tone:": ":woman_supervillain_tone4:", + ":woman_supervillain_medium_light_skin_tone:": ":woman_supervillain_tone2:", + ":woman_supervillain_medium_skin_tone:": ":woman_supervillain_tone3:", + ":woman_surfing_dark_skin_tone:": ":woman_surfing_tone5:", + ":woman_surfing_light_skin_tone:": ":woman_surfing_tone1:", + ":woman_surfing_medium_dark_skin_tone:": ":woman_surfing_tone4:", + ":woman_surfing_medium_light_skin_tone:": ":woman_surfing_tone2:", + ":woman_surfing_medium_skin_tone:": ":woman_surfing_tone3:", + ":woman_swimming_dark_skin_tone:": ":woman_swimming_tone5:", + ":woman_swimming_light_skin_tone:": ":woman_swimming_tone1:", + ":woman_swimming_medium_dark_skin_tone:": ":woman_swimming_tone4:", + ":woman_swimming_medium_light_skin_tone:": ":woman_swimming_tone2:", + ":woman_swimming_medium_skin_tone:": ":woman_swimming_tone3:", + ":woman_teacher_dark_skin_tone:": ":woman_teacher_tone5:", + ":woman_teacher_light_skin_tone:": ":woman_teacher_tone1:", + ":woman_teacher_medium_dark_skin_tone:": ":woman_teacher_tone4:", + ":woman_teacher_medium_light_skin_tone:": ":woman_teacher_tone2:", + ":woman_teacher_medium_skin_tone:": ":woman_teacher_tone3:", + ":woman_technologist_dark_skin_tone:": ":woman_technologist_tone5:", + ":woman_technologist_light_skin_tone:": ":woman_technologist_tone1:", + ":woman_technologist_medium_dark_skin_tone:": ":woman_technologist_tone4:", + ":woman_technologist_medium_light_skin_tone:": ":woman_technologist_tone2:", + ":woman_technologist_medium_skin_tone:": ":woman_technologist_tone3:", + ":woman_tipping_hand_dark_skin_tone:": ":woman_tipping_hand_tone5:", + ":woman_tipping_hand_light_skin_tone:": ":woman_tipping_hand_tone1:", + ":woman_tipping_hand_medium_dark_skin_tone:": ":woman_tipping_hand_tone4:", + ":woman_tipping_hand_medium_light_skin_tone:": ":woman_tipping_hand_tone2:", + ":woman_tipping_hand_medium_skin_tone:": ":woman_tipping_hand_tone3:", + ":woman_vampire_dark_skin_tone:": ":woman_vampire_tone5:", + ":woman_vampire_light_skin_tone:": ":woman_vampire_tone1:", + ":woman_vampire_medium_dark_skin_tone:": ":woman_vampire_tone4:", + ":woman_vampire_medium_light_skin_tone:": ":woman_vampire_tone2:", + ":woman_vampire_medium_skin_tone:": ":woman_vampire_tone3:", + ":woman_walking_dark_skin_tone:": ":woman_walking_tone5:", + ":woman_walking_facing_right_dark_skin_tone:": ":woman_walking_facing_right_tone5:", + ":woman_walking_facing_right_light_skin_tone:": ":woman_walking_facing_right_tone1:", + ":woman_walking_facing_right_medium_dark_skin_tone:": ":woman_walking_facing_right_tone4:", + ":woman_walking_facing_right_medium_light_skin_tone:": ":woman_walking_facing_right_tone2:", + ":woman_walking_facing_right_medium_skin_tone:": ":woman_walking_facing_right_tone3:", + ":woman_walking_light_skin_tone:": ":woman_walking_tone1:", + ":woman_walking_medium_dark_skin_tone:": ":woman_walking_tone4:", + ":woman_walking_medium_light_skin_tone:": ":woman_walking_tone2:", + ":woman_walking_medium_skin_tone:": ":woman_walking_tone3:", + ":woman_wearing_turban_dark_skin_tone:": ":woman_wearing_turban_tone5:", + ":woman_wearing_turban_light_skin_tone:": ":woman_wearing_turban_tone1:", + ":woman_wearing_turban_medium_dark_skin_tone:": ":woman_wearing_turban_tone4:", + ":woman_wearing_turban_medium_light_skin_tone:": ":woman_wearing_turban_tone2:", + ":woman_wearing_turban_medium_skin_tone:": ":woman_wearing_turban_tone3:", + ":woman_white_haired_dark_skin_tone:": ":woman_white_haired_tone5:", + ":woman_white_haired_light_skin_tone:": ":woman_white_haired_tone1:", + ":woman_white_haired_medium_dark_skin_tone:": ":woman_white_haired_tone4:", + ":woman_white_haired_medium_light_skin_tone:": ":woman_white_haired_tone2:", + ":woman_white_haired_medium_skin_tone:": ":woman_white_haired_tone3:", + ":woman_with_headscarf_dark_skin_tone:": ":woman_with_headscarf_tone5:", + ":woman_with_headscarf_light_skin_tone:": ":woman_with_headscarf_tone1:", + ":woman_with_headscarf_medium_dark_skin_tone:": ":woman_with_headscarf_tone4:", + ":woman_with_headscarf_medium_light_skin_tone:": ":woman_with_headscarf_tone2:", + ":woman_with_headscarf_medium_skin_tone:": ":woman_with_headscarf_tone3:", + ":woman_with_probing_cane_dark_skin_tone:": ":woman_with_probing_cane_tone5:", + ":woman_with_probing_cane_light_skin_tone:": ":woman_with_probing_cane_tone1:", + ":woman_with_probing_cane_medium_dark_skin_tone:": ":woman_with_probing_cane_tone4:", + ":woman_with_probing_cane_medium_light_skin_tone:": ":woman_with_probing_cane_tone2:", + ":woman_with_probing_cane_medium_skin_tone:": ":woman_with_probing_cane_tone3:", + ":woman_with_veil_dark_skin_tone:": ":woman_with_veil_tone5:", + ":woman_with_veil_light_skin_tone:": ":woman_with_veil_tone1:", + ":woman_with_veil_medium_dark_skin_tone:": ":woman_with_veil_tone4:", + ":woman_with_veil_medium_light_skin_tone:": ":woman_with_veil_tone2:", + ":woman_with_veil_medium_skin_tone:": ":woman_with_veil_tone3:", + ":woman_with_white_cane_facing_right_dark_skin_tone:": ":woman_with_white_cane_facing_right_tone5:", + ":woman_with_white_cane_facing_right_light_skin_tone:": ":woman_with_white_cane_facing_right_tone1:", + ":woman_with_white_cane_facing_right_medium_dark_skin_tone:": ":woman_with_white_cane_facing_right_tone4:", + ":woman_with_white_cane_facing_right_medium_light_skin_tone:": ":woman_with_white_cane_facing_right_tone2:", + ":woman_with_white_cane_facing_right_medium_skin_tone:": ":woman_with_white_cane_facing_right_tone3:", + ":womans_boot:": ":boot:", + ":womans_sandal:": ":sandal:", + ":women_holding_hands_dark_skin_tone:": ":women_holding_hands_tone5:", + ":women_holding_hands_dark_skin_tone_light_skin_tone:": ":women_holding_hands_tone5_tone1:", + ":women_holding_hands_dark_skin_tone_medium_dark_skin_tone:": ":women_holding_hands_tone5_tone4:", + ":women_holding_hands_dark_skin_tone_medium_light_skin_tone:": ":women_holding_hands_tone5_tone2:", + ":women_holding_hands_dark_skin_tone_medium_skin_tone:": ":women_holding_hands_tone5_tone3:", + ":women_holding_hands_light_skin_tone:": ":women_holding_hands_tone1:", + ":women_holding_hands_light_skin_tone_dark_skin_tone:": ":women_holding_hands_tone1_tone5:", + ":women_holding_hands_light_skin_tone_medium_dark_skin_tone:": ":women_holding_hands_tone1_tone4:", + ":women_holding_hands_light_skin_tone_medium_light_skin_tone:": ":women_holding_hands_tone1_tone2:", + ":women_holding_hands_light_skin_tone_medium_skin_tone:": ":women_holding_hands_tone1_tone3:", + ":women_holding_hands_medium_dark_skin_tone:": ":women_holding_hands_tone4:", + ":women_holding_hands_medium_dark_skin_tone_dark_skin_tone:": ":women_holding_hands_tone4_tone5:", + ":women_holding_hands_medium_dark_skin_tone_light_skin_tone:": ":women_holding_hands_tone4_tone1:", + ":women_holding_hands_medium_dark_skin_tone_medium_light_skin_tone:": ":women_holding_hands_tone4_tone2:", + ":women_holding_hands_medium_dark_skin_tone_medium_skin_tone:": ":women_holding_hands_tone4_tone3:", + ":women_holding_hands_medium_light_skin_tone:": ":women_holding_hands_tone2:", + ":women_holding_hands_medium_light_skin_tone_dark_skin_tone:": ":women_holding_hands_tone2_tone5:", + ":women_holding_hands_medium_light_skin_tone_light_skin_tone:": ":women_holding_hands_tone2_tone1:", + ":women_holding_hands_medium_light_skin_tone_medium_dark_skin_tone:": ":women_holding_hands_tone2_tone4:", + ":women_holding_hands_medium_light_skin_tone_medium_skin_tone:": ":women_holding_hands_tone2_tone3:", + ":women_holding_hands_medium_skin_tone:": ":women_holding_hands_tone3:", + ":women_holding_hands_medium_skin_tone_dark_skin_tone:": ":women_holding_hands_tone3_tone5:", + ":women_holding_hands_medium_skin_tone_light_skin_tone:": ":women_holding_hands_tone3_tone1:", + ":women_holding_hands_medium_skin_tone_medium_dark_skin_tone:": ":women_holding_hands_tone3_tone4:", + ":women_holding_hands_medium_skin_tone_medium_light_skin_tone:": ":women_holding_hands_tone3_tone2:", + ":womens_room:": ":womens:", + ":world_map:": ":map:", + ":worried_face:": ":worried:", + ":worship_symbol:": ":place_of_worship:", + ":wrapped_gift:": ":gift:", + ":wrestlers:": ":people_wrestling:", + ":wrestling:": ":people_wrestling:", + ":ws:": ":flag_ws:", + ":xk:": ":flag_xk:", + ":ye:": ":flag_ye:", + ":yen_banknote:": ":yen:", + ":yt:": ":flag_yt:", + ":za:": ":flag_za:", + ":zipper_mouth_face:": ":zipper_mouth:", + ":zm:": ":flag_zm:", + ":zw:": ":flag_zw:", + "woman_in_business_suit_levitating": ":woman_levitate:", + "woman_in_business_suit_levitating_dark_skin_tone": ":woman_leviate_tone5:", + "woman_in_business_suit_levitating_light_skin_tone": ":woman_levitate_tone1:", + "woman_in_business_suit_levitating_medium_dark_skin_tone": ":woman_leviate_tone4:", + "woman_in_business_suit_levitating_medium_light_skin_tone": ":woman_leviate_tone2:", + "woman_in_business_suit_levitating_medium_skin_tone": ":woman_leviate_tone3:", + "woman_in_business_suit_levitating_tone1": ":woman_levitate_tone1:", + "woman_in_business_suit_levitating_tone2": ":woman_leviate_tone2:", + "woman_in_business_suit_levitating_tone3": ":woman_leviate_tone3:", + "woman_in_business_suit_levitating_tone4": ":woman_leviate_tone4:", + "woman_in_business_suit_levitating_tone5": ":woman_leviate_tone5:" +} diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/util.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/util.py new file mode 100644 index 0000000000000000000000000000000000000000..ddca6806b21b9798cceb299f02212986b1b18977 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pymdown-extensions-10.21.2-pyhd8ed1ab_0/site-packages/pymdownx/util.py @@ -0,0 +1,369 @@ +""" +General utilities. + +MIT license. + +Copyright (c) 2017 Isaac Muse <isaacmuse@gmail.com> +""" +from __future__ import annotations +from markdown import Markdown +from markdown.inlinepatterns import InlineProcessor +import xml.etree.ElementTree as etree +from collections import namedtuple +import sys +import copy +import re +import html +from urllib.request import pathname2url, url2pathname +from urllib.parse import urlparse +from functools import wraps +import warnings +from typing import Sequence, Callable, Any + +RE_WIN_DRIVE_LETTER = re.compile(r"^[A-Za-z]$") +RE_WIN_DRIVE_PATH = re.compile(r"^[A-Za-z]:(?:\\.*)?$") +RE_URL = re.compile('(http|ftp)s?|data|mailto|tel|news') +RE_WIN_DEFAULT_PROTOCOL = re.compile(r"^///[A-Za-z]:(?:/.*)?$") + +if sys.platform.startswith('win'): + _PLATFORM = "windows" +elif sys.platform == "darwin": # pragma: no cover + _PLATFORM = "osx" +else: + _PLATFORM = "linux" + +PY39 = (3, 9) <= sys.version_info +PY314 = (3, 14) <= sys.version_info + + +def clamp(value: float, mn: float, mx: float) -> float: + """Clamp the value to the given minimum and maximum.""" + + if mn is not None and mx is not None: + return max(min(value, mx), mn) + elif mn is not None: + return max(value, mn) + elif mx is not None: + return min(value, mx) + else: + return value + + +def is_win() -> bool: # pragma: no cover + """Is Windows.""" + + return _PLATFORM == "windows" + + +def is_linux() -> bool: # pragma: no cover + """Is Linux.""" + + return _PLATFORM == "linux" + + +def is_mac() -> bool: # pragma: no cover + """Is macOS.""" + + return _PLATFORM == "osx" + + +def url2path(path: str) -> str: + """Path to URL.""" + + return url2pathname(path) + + +def path2url(url: str) -> str: + """URL to path.""" + + path = pathname2url(url) + # If on windows, replace the notation to use a default protocol `///` with nothing. + if is_win() and RE_WIN_DEFAULT_PROTOCOL.match(path): + path = path.replace('///', '', 1) + if PY314: + path = path.replace('///', '/') + return path + + +def get_code_points(s: str) -> list[str]: + """Get the Unicode code points.""" + + return list(s) + + +def get_ord(c: str) -> int: + """Get Unicode ord.""" + + return ord(c) + + +def get_char(value: int) -> str: + """Get the Unicode char.""" + + return chr(value) + + +def escape_chars(md: Markdown, echrs: Sequence[str]) -> None: + """ + Add chars to the escape list. + + Don't just append as it modifies the global list permanently. + Make a copy and extend **that** copy so that only this Markdown + instance gets modified. + """ + + escaped = copy.copy(md.ESCAPED_CHARS) + for ec in echrs: + if ec not in escaped: + escaped.append(ec) + md.ESCAPED_CHARS = escaped + + +def parse_url(url: str) -> tuple[str, str, str, str, str, str, bool, bool]: + """ + Parse the URL. + + Try to determine if the following is a file path or + (as we will call anything else) a URL. + + We return it slightly modified and combine the path parts. + + We also assume if we see something like c:/ it is a Windows path. + We don't bother checking if this **is** a Windows system, but + 'nix users really shouldn't be creating weird names like c: for their folder. + """ + + is_url = False + is_absolute = False + scheme, netloc, path, params, query, fragment = urlparse(html.unescape(url)) + + if RE_URL.match(scheme): + # Clearly a URL + is_url = True + elif scheme == '' and netloc == '' and path == '': + # Maybe just a URL fragment + is_url = True + elif scheme == 'file' and (RE_WIN_DRIVE_PATH.match(netloc)): + # file://c:/path or file://c:\path + path = '/' + (netloc + path).replace('\\', '/') + netloc = '' + is_absolute = True + elif scheme == 'file' and netloc.startswith('\\'): + # file://\c:\path or file://\\path + path = (netloc + path).replace('\\', '/') + netloc = '' + is_absolute = True + elif scheme == 'file': + # file:///path + is_absolute = True + elif RE_WIN_DRIVE_LETTER.match(scheme): + # c:/path + path = '/{}:{}'.format(scheme, path.replace('\\', '/')) + scheme = 'file' + netloc = '' + is_absolute = True + elif scheme == '' and netloc != '' and url.startswith('//'): + # //file/path + path = '//' + netloc + path + scheme = 'file' + netloc = '' + is_absolute = True + elif scheme != '' and netloc != '': + # A non-file path or strange URL + is_url = True + elif path.startswith(('/', '\\')): + # /root path + is_absolute = True + + return (scheme, netloc, path, params, query, fragment, is_url, is_absolute) + + +class PatSeqItem(namedtuple('PatSeqItem', ['pattern', 'builder', 'tags', 'full_recursion'])): + """Pattern sequence item item.""" + + def __new__(cls, pattern: re.Pattern[str], builder: str, tags: str, full_recursion: bool = False) -> PatSeqItem: + """Create object.""" + + return super().__new__(cls, pattern, builder, tags, full_recursion) + + +class PatternSequenceProcessor(InlineProcessor): + """Processor for handling complex nested patterns such as strong and em matches.""" + + PATTERNS = [] # type: list[PatSeqItem] + + def build_single(self, m: re.Match[str], tag: str, full_recursion: bool, idx: int) -> etree.Element: + """Return single tag.""" + el1 = etree.Element(tag) + text = m.group(2) + self.parse_sub_patterns(text, el1, None, full_recursion, idx) + return el1 + + def build_double(self, m: re.Match[str], tags: str, full_recursion: bool, idx: int) -> etree.Element: + """Return double tag.""" + + tag1, tag2 = tags.split(",") + el1 = etree.Element(tag1) + el2 = etree.Element(tag2) + text = m.group(2) + self.parse_sub_patterns(text, el2, None, full_recursion, idx) + el1.append(el2) + if len(m.groups()) == 3: + text = m.group(3) + self.parse_sub_patterns(text, el1, el2, full_recursion, idx) + return el1 + + def build_double2(self, m: re.Match[str], tags: str, full_recursion: bool, idx: int) -> etree.Element: + """Return double tags (variant 2): `<strong>text <em>text</em></strong>`.""" + + tag1, tag2 = tags.split(",") + el1 = etree.Element(tag1) + el2 = etree.Element(tag2) + text = m.group(2) + self.parse_sub_patterns(text, el1, None, full_recursion, idx) + text = m.group(3) + el1.append(el2) + self.parse_sub_patterns(text, el2, None, full_recursion, idx) + return el1 + + def parse_sub_patterns( + self, + data: str, + parent: etree.Element, + last: None | etree.Element, + full_recursion: bool, + idx: int + ) -> None: + """ + Parses sub patterns. + + `data` (`str`): + text to evaluate. + + `parent` (`etree.Element`): + Parent to attach text and sub elements to. + + `last` (`etree.Element`): + Last appended child to parent. Can also be None if parent has no children. + + `idx` (`int`): + Current pattern index that was used to evaluate the parent. + + """ + + offset = 0 + pos = 0 + + length = len(data) + while pos < length: + # Find the start of potential emphasis or strong tokens + if self.compiled_re.match(data, pos): + matched = False + # See if the we can match an emphasis/strong pattern + for index, item in enumerate(self.PATTERNS): + # Only evaluate patterns that are after what was used on the parent + if not full_recursion and index <= idx: + continue + m = item.pattern.match(data, pos) + if m: + # Append child nodes to parent + # Text nodes should be appended to the last + # child if present, and if not, it should + # be added as the parent's text node. + text = data[offset:m.start(0)] + if text: + if last is not None: + last.tail = text + else: + parent.text = text + el = self.build_element(m, item.builder, item.tags, item.full_recursion, index) + parent.append(el) + last = el + # Move our position past the matched hunk + offset = pos = m.end(0) + matched = True + if not matched: + # We matched nothing, move on to the next character + pos += 1 + else: + # Increment position as no potential emphasis start was found. + pos += 1 + + # Append any leftover text as a text node. + text = data[offset:] + if text: + if last is not None: + last.tail = text + else: + parent.text = text + + def build_element( + self, + m: re.Match[str], + builder: str, + tags: str, + full_recursion: bool, + index: int + ) -> etree.Element: + """Element builder.""" + + if builder == 'double2': + return self.build_double2(m, tags, full_recursion, index) + elif builder == 'double': + return self.build_double(m, tags, full_recursion, index) + else: + return self.build_single(m, tags, full_recursion, index) + + def handleMatch( # type: ignore[override] + self, + m: re.Match[str], + data: str + ) -> tuple[etree.Element | None, int | None, int | None]: + """Parse patterns.""" + + el = None + start = None + end = None + + for index, item in enumerate(self.PATTERNS): + m1 = item.pattern.match(data, m.start(0)) + if m1: + start = m1.start(0) + end = m1.end(0) + el = self.build_element(m1, item.builder, item.tags, item.full_recursion, index) + break + return el, start, end + + +def deprecated(message: str, stacklevel: int = 2) -> Callable[..., Any]: # pragma: no cover + """ + Raise a `DeprecationWarning` when wrapped function/method is called. + + Usage: + + @deprecated("This method will be removed in version X; use Y instead.") + def some_method()" + pass + """ + + def _wrapper(func: Callable[..., Any]) -> Callable[..., Any]: + @wraps(func) + def _deprecated_func(*args: Any, **kwargs: Any) -> Any: + warnings.warn( + f"'{func.__name__}' is deprecated. {message}", + category=DeprecationWarning, + stacklevel=stacklevel + ) + return func(*args, **kwargs) + return _deprecated_func + return _wrapper + + +def warn_deprecated(message: str, stacklevel: int = 2) -> None: # pragma: no cover + """Warn deprecated.""" + + warnings.warn( + message, + category=DeprecationWarning, + stacklevel=stacklevel + ) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/about.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/about.json new file mode 100644 index 0000000000000000000000000000000000000000..5b35fc7fd4b509aa89c4d7b787b875e3ecce492d --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/about.json @@ -0,0 +1,250 @@ +{ + "channels": [ + "https://conda.anaconda.org/conda-forge" + ], + "conda_build_version": "24.11.2", + "conda_version": "24.11.0", + "dev_url": "https://github.com/Anorov/PySocks", + "doc_url": "https://github.com/Anorov/PySocks/blob/master/README.md", + "env_vars": { + "CIO_TEST": "<not set>" + }, + "extra": { + "copy_test_source_files": true, + "final": true, + "flow_run_id": "azure_20241203.2.1", + "recipe-maintainers": [ + "pmlandwehr", + "ocefpaf" + ], + "remote_url": "https://github.com/conda-forge/pysocks-feedstock", + "sha": "fd6a51b950188ecf552835f561c5de5f77b0ef53" + }, + "home": "https://github.com/Anorov/PySocks", + "identifiers": [], + "keywords": [], + "license": "BSD-3-Clause", + "license_family": "BSD", + "license_file": "LICENSE", + "root_pkgs": [ + "anaconda-client 1.12.3 pyhd8ed1ab_1", + "archspec 0.2.3 pyhd8ed1ab_0", + "attrs 24.2.0 pyh71513ae_0", + "beautifulsoup4 4.12.3 pyha770c72_0", + "boltons 24.0.0 pyhd8ed1ab_0", + "brotli-python 1.1.0 py312h275cf98_2", + "bzip2 1.0.8 h2466b09_7", + "ca-certificates 2024.8.30 h56e8100_0", + "certifi 2024.8.30 pyhd8ed1ab_0", + "cffi 1.17.1 py312h4389bb4_0", + "chardet 5.2.0 py312h2e8e312_2", + "charset-normalizer 3.4.0 pyhd8ed1ab_0", + "click 8.1.7 win_pyh7428d3b_0", + "colorama 0.4.6 pyhd8ed1ab_0", + "conda 24.11.0 py312h2e8e312_0", + "conda-build 24.11.2 py312h2e8e312_0", + "conda-env 2.6.0 1", + "conda-forge-ci-setup 4.13.0 py312h5eb20be_100", + "conda-forge-metadata 0.11.0 pyhd8ed1ab_0", + "conda-index 0.5.0 pyhd8ed1ab_0", + "conda-libmamba-solver 24.11.0 pyhd8ed1ab_0", + "conda-oci-mirror 0.2.1 pyhd8ed1ab_0", + "conda-package-handling 2.4.0 pyh7900ff3_0", + "conda-package-streaming 0.11.0 pyhd8ed1ab_0", + "cpp-expected 1.1.0 h91493d7_0", + "cpython 3.12.7 py312hd8ed1ab_0", + "defusedxml 0.7.1 pyhd8ed1ab_0", + "deprecated 1.2.15 pyhff2d567_0", + "distro 1.9.0 pyhd8ed1ab_0", + "filelock 3.16.1 pyhd8ed1ab_0", + "fmt 11.0.2 h7f575de_0", + "frozendict 2.4.6 py312h4389bb4_0", + "h2 4.1.0 pyhd8ed1ab_0", + "hpack 4.0.0 pyh9f0ad1d_0", + "hyperframe 6.0.1 pyhd8ed1ab_0", + "idna 3.10 pyhd8ed1ab_1", + "importlib_resources 6.4.5 pyhd8ed1ab_0", + "jinja2 3.1.4 pyhd8ed1ab_0", + "joblib 1.4.2 pyhd8ed1ab_0", + "jsonpatch 1.33 pyhd8ed1ab_0", + "jsonpointer 3.0.0 py312h2e8e312_1", + "jsonschema 4.23.0 pyhd8ed1ab_0", + "jsonschema-specifications 2024.10.1 pyhd8ed1ab_0", + "jupyter_core 5.7.2 pyh5737063_1", + "krb5 1.21.3 hdf4eb48_0", + "libarchive 3.7.7 h88ece9c_0", + "libcurl 8.10.1 h1ee3ff0_0", + "libexpat 2.6.4 he0c23c2_0", + "libffi 3.4.2 h8ffe710_5", + "libiconv 1.17 hcfcfb64_2", + "liblief 0.14.1 he0c23c2_2", + "libmamba 2.0.4 h81425b0_0", + "libmambapy 2.0.4 py312h643a1bd_0", + "libsolv 0.7.30 hbb528cf_0", + "libsqlite 3.47.0 h2466b09_1", + "libssh2 1.11.1 he619c9f_0", + "libxml2 2.13.5 h442d1da_0", + "libzlib 1.3.1 h2466b09_2", + "lz4-c 1.9.4 hcfcfb64_0", + "lzo 2.10 hcfcfb64_1001", + "m2-bash 5.2.015.1 hd8ed1ab_4", + "m2-brotli 1.1.0.1 hd8ed1ab_4", + "m2-ca-certificates 20230311.1 hd8ed1ab_4", + "m2-conda-epoch 20230914 0_x86_64", + "m2-coreutils 8.32.5 hd8ed1ab_4", + "m2-curl 8.2.1.1 hd8ed1ab_4", + "m2-db 5.3.28.4 hd8ed1ab_4", + "m2-file 5.45.1 hd8ed1ab_4", + "m2-filesystem 2023.02.07.1 hd8ed1ab_4", + "m2-findutils 4.9.0.3 hd8ed1ab_4", + "m2-gcc-libs 11.3.0.4 hd8ed1ab_4", + "m2-gdbm 1.23.1 hd8ed1ab_4", + "m2-gettext 0.22.1 hd8ed1ab_4", + "m2-git 2.42.0.2 hd8ed1ab_4", + "m2-gmp 6.3.0.1 hd8ed1ab_4", + "m2-gzip 1.13.1 hd8ed1ab_4", + "m2-heimdal 7.8.0.4 hd8ed1ab_4", + "m2-heimdal-libs 7.8.0.4 hd8ed1ab_4", + "m2-info 7.0.3.3 hd8ed1ab_4", + "m2-less 643.1 hd8ed1ab_4", + "m2-libasprintf 0.22.1 hd8ed1ab_4", + "m2-libbz2 1.0.8.4 hd8ed1ab_4", + "m2-libcbor 0.9.0.1 hd8ed1ab_4", + "m2-libcurl 8.2.1.1 hd8ed1ab_4", + "m2-libdb 5.3.28.4 hd8ed1ab_4", + "m2-libedit 20221030_3.1.1 hd8ed1ab_4", + "m2-libexpat 2.5.0.1 hd8ed1ab_4", + "m2-libffi 3.4.4.1 hd8ed1ab_4", + "m2-libfido2 1.13.0.1 hd8ed1ab_4", + "m2-libgcrypt 1.9.4.1 hd8ed1ab_4", + "m2-libgdbm 1.23.1 hd8ed1ab_4", + "m2-libgettextpo 0.22.1 hd8ed1ab_4", + "m2-libgpg-error 1.47.1 hd8ed1ab_4", + "m2-libiconv 1.17.1 hd8ed1ab_4", + "m2-libidn2 2.3.4.2 hd8ed1ab_4", + "m2-libintl 0.22.1 hd8ed1ab_4", + "m2-liblzma 5.4.4.1 hd8ed1ab_4", + "m2-libnghttp2 1.56.0.1 hd8ed1ab_4", + "m2-libopenssl 3.1.2.1 hd8ed1ab_4", + "m2-libp11-kit 0.25.0.1 hd8ed1ab_4", + "m2-libpcre2_8 10.42.1 hd8ed1ab_4", + "m2-libpsl 0.21.2.1 hd8ed1ab_4", + "m2-libreadline 8.2.001.3 hd8ed1ab_4", + "m2-libsqlite 3.42.0.2 hd8ed1ab_4", + "m2-libssh2 1.11.0.1 hd8ed1ab_4", + "m2-libtasn1 4.19.0.1 hd8ed1ab_4", + "m2-libunistring 1.1.2 hd8ed1ab_4", + "m2-libxcrypt 4.4.36.1 hd8ed1ab_4", + "m2-libxml2 2.9.14.5 hd8ed1ab_4", + "m2-libxslt 1.1.38.1 hd8ed1ab_4", + "m2-libzstd 1.5.5.1 hd8ed1ab_4", + "m2-msys2-runtime 3.4.9.1 hd8ed1ab_4", + "m2-nano 7.2.1 hd8ed1ab_4", + "m2-ncurses 6.4.1 hd8ed1ab_4", + "m2-openssh 9.4p1.1 hd8ed1ab_4", + "m2-openssl 3.1.2.1 hd8ed1ab_4", + "m2-p11-kit 0.25.0.1 hd8ed1ab_4", + "m2-patch 2.7.6.2 hd8ed1ab_4", + "m2-perl 5.36.1.2 hd8ed1ab_4", + "m2-perl-authen-sasl 2.16.3 hd8ed1ab_4", + "m2-perl-clone 0.46.1 hd8ed1ab_4", + "m2-perl-convert-binhex 1.125.2 hd8ed1ab_4", + "m2-perl-encode-locale 1.05.2 hd8ed1ab_4", + "m2-perl-error 0.17029.1 hd8ed1ab_4", + "m2-perl-file-listing 6.16.1 hd8ed1ab_4", + "m2-perl-html-parser 3.81.1 hd8ed1ab_4", + "m2-perl-html-tagset 3.20.3 hd8ed1ab_4", + "m2-perl-http-cookies 6.10.2 hd8ed1ab_4", + "m2-perl-http-daemon 6.16.1 hd8ed1ab_4", + "m2-perl-http-date 6.06.1 hd8ed1ab_4", + "m2-perl-http-message 6.44.1 hd8ed1ab_4", + "m2-perl-http-negotiate 6.01.3 hd8ed1ab_4", + "m2-perl-io-html 1.004.2 hd8ed1ab_4", + "m2-perl-io-socket-ip 0.41.2 hd8ed1ab_4", + "m2-perl-io-socket-ssl 2.083.1 hd8ed1ab_4", + "m2-perl-io-stringy 2.113.1 hd8ed1ab_4", + "m2-perl-libwww 6.67.1 hd8ed1ab_4", + "m2-perl-lwp-mediatypes 6.04.1 hd8ed1ab_4", + "m2-perl-mailtools 2.21.1 hd8ed1ab_4", + "m2-perl-mime-tools 5.510.1 hd8ed1ab_4", + "m2-perl-net-http 6.23.1 hd8ed1ab_4", + "m2-perl-net-smtp-ssl 1.04.2 hd8ed1ab_4", + "m2-perl-net-ssleay 1.92.5 hd8ed1ab_4", + "m2-perl-termreadkey 2.38.5 hd8ed1ab_4", + "m2-perl-timedate 2.33.2 hd8ed1ab_4", + "m2-perl-try-tiny 0.31.1 hd8ed1ab_4", + "m2-perl-uri 5.21.1 hd8ed1ab_4", + "m2-perl-www-robotrules 6.02.2 hd8ed1ab_4", + "m2-sed 4.9.1 hd8ed1ab_4", + "m2-zlib 1.3.1 hd8ed1ab_4", + "mamba 2.0.4 hde45397_0", + "markupsafe 3.0.2 py312h31fea79_0", + "menuinst 2.2.0 py312h275cf98_0", + "more-itertools 10.5.0 pyhd8ed1ab_0", + "nbformat 5.10.4 pyhd8ed1ab_0", + "nlohmann_json 3.11.3 he0c23c2_1", + "openssl 3.4.0 h2466b09_0", + "oras-py 0.1.14 pyhd8ed1ab_0", + "packaging 24.2 pyhd8ed1ab_2", + "pip 24.3.1 pyh8b19718_0", + "pkginfo 1.12.0 pyhd8ed1ab_0", + "pkgutil-resolve-name 1.3.10 pyhd8ed1ab_1", + "platformdirs 4.3.6 pyhd8ed1ab_0", + "pluggy 1.5.0 pyhd8ed1ab_0", + "psutil 6.1.0 py312h4389bb4_0", + "py-lief 0.14.1 py312h275cf98_2", + "pybind11-abi 4 hd8ed1ab_3", + "pycosat 0.6.6 py312h4389bb4_2", + "pycparser 2.22 pyh29332c3_1", + "pysocks 1.7.1 pyh0701188_6", + "python 3.12.7 hce54a09_0_cpython", + "python-dateutil 2.9.0.post0 pyhff2d567_1", + "python-fastjsonschema 2.21.0 pyhd8ed1ab_0", + "python-libarchive-c 5.1 py312h2e8e312_1", + "python_abi 3.12 5_cp312", + "pytz 2024.2 pyhd8ed1ab_1", + "pywin32 307 py312h275cf98_3", + "pyyaml 6.0.2 py312h4389bb4_1", + "rattler-build 0.31.1 h49672d7_0", + "rattler-build-conda-compat 1.2.2 pyhd8ed1ab_0", + "referencing 0.35.1 pyhd8ed1ab_0", + "reproc 14.2.5.post0 h2466b09_0", + "reproc-cpp 14.2.5.post0 he0c23c2_0", + "requests 2.32.3 pyhd8ed1ab_0", + "requests-toolbelt 1.0.0 pyhd8ed1ab_0", + "ripgrep 14.1.1 ha073cba_0", + "rpds-py 0.21.0 py312h2615798_0", + "ruamel.yaml 0.18.6 py312h4389bb4_1", + "ruamel.yaml.clib 0.2.8 py312h4389bb4_1", + "setuptools 75.6.0 pyhff2d567_1", + "shyaml 0.6.2 pyhd3deb0d_0", + "simdjson 3.10.1 hc790b64_0", + "six 1.16.0 pyh6c4a22f_0", + "soupsieve 2.5 pyhd8ed1ab_1", + "spdlog 1.14.1 h9f2357e_1", + "tk 8.6.13 h5226925_1", + "tomli 2.2.1 pyhd8ed1ab_0", + "tqdm 4.67.1 pyhd8ed1ab_0", + "traitlets 5.14.3 pyhd8ed1ab_0", + "truststore 0.10.0 pyhd8ed1ab_0", + "typing-extensions 4.12.2 hd8ed1ab_1", + "typing_extensions 4.12.2 pyha770c72_1", + "tzdata 2024b hc8b5060_0", + "ucrt 10.0.22621.0 h57928b3_1", + "urllib3 2.2.3 pyhd8ed1ab_1", + "vc 14.3 ha32ba9b_23", + "vc14_runtime 14.42.34433 he29a5d6_23", + "vs2015_runtime 14.42.34433 hdffcdeb_23", + "wheel 0.45.1 pyhd8ed1ab_1", + "win_inet_pton 1.1.0 pyh7428d3b_8", + "wrapt 1.17.0 py312h4389bb4_0", + "xz 5.2.6 h8d14728_0", + "yaml 0.2.5 h8ffe710_2", + "yaml-cpp 0.8.0 h63175ca_0", + "zipp 3.21.0 pyhd8ed1ab_1", + "zstandard 0.23.0 py312h7606c53_1", + "zstd 1.5.6 h0ea2cb4_0" + ], + "summary": "A Python SOCKS client module. See https://github.com/Anorov/PySocks for more information.", + "tags": [] +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/files b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/files new file mode 100644 index 0000000000000000000000000000000000000000..f1c55219829fa9b4591c12b7f37c85f5efc68573 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/files @@ -0,0 +1,10 @@ +site-packages/PySocks-1.7.1.dist-info/INSTALLER +site-packages/PySocks-1.7.1.dist-info/LICENSE +site-packages/PySocks-1.7.1.dist-info/METADATA +site-packages/PySocks-1.7.1.dist-info/RECORD +site-packages/PySocks-1.7.1.dist-info/REQUESTED +site-packages/PySocks-1.7.1.dist-info/WHEEL +site-packages/PySocks-1.7.1.dist-info/direct_url.json +site-packages/PySocks-1.7.1.dist-info/top_level.txt +site-packages/socks.py +site-packages/sockshandler.py diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/git b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/git new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/hash_input.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/hash_input.json new file mode 100644 index 0000000000000000000000000000000000000000..4bfaecd76a6208c940b5f453616fe42f66779ff9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/hash_input.json @@ -0,0 +1,5 @@ +{ + "virtual_pkg": "__win", + "channel_targets": "conda-forge main", + "__win": "__win" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/index.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/index.json new file mode 100644 index 0000000000000000000000000000000000000000..c1ba93ad2c73b5e1db4a349463c027b3075e87a2 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/index.json @@ -0,0 +1,18 @@ +{ + "arch": null, + "build": "pyh09c184e_7", + "build_number": 7, + "depends": [ + "__win", + "python >=3.9", + "win_inet_pton" + ], + "license": "BSD-3-Clause", + "license_family": "BSD", + "name": "pysocks", + "noarch": "python", + "platform": null, + "subdir": "noarch", + "timestamp": 1733217448189, + "version": "1.7.1" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..04b6b1f37c4dffb82942cdcc2b77092798ca4aa2 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/licenses/LICENSE @@ -0,0 +1,22 @@ +Copyright 2006 Dan-Haim. All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, +are permitted provided that the following conditions are met: +1. Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. +2. Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. +3. Neither the name of Dan Haim nor the names of his contributors may be used + to endorse or promote products derived from this software without specific + prior written permission. + +THIS SOFTWARE IS PROVIDED BY DAN HAIM "AS IS" AND ANY EXPRESS OR IMPLIED +WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +EVENT SHALL DAN HAIM OR HIS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA +OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMANGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/link.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/link.json new file mode 100644 index 0000000000000000000000000000000000000000..32bb6c422a257d7802fba7e2bdb9e80eebf31957 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/link.json @@ -0,0 +1,6 @@ +{ + "noarch": { + "type": "python" + }, + "package_metadata_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/paths.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/paths.json new file mode 100644 index 0000000000000000000000000000000000000000..d2c5d1ef79164200728e31c88f574c0eb65575d8 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/paths.json @@ -0,0 +1,65 @@ +{ + "paths": [ + { + "_path": "site-packages/PySocks-1.7.1.dist-info/INSTALLER", + "path_type": "hardlink", + "sha256": "d0edee15f91b406f3f99726e44eb990be6e34fd0345b52b910c568e0eef6a2a8", + "size_in_bytes": 5 + }, + { + "_path": "site-packages/PySocks-1.7.1.dist-info/LICENSE", + "path_type": "hardlink", + "sha256": "7027e214e014eb78b7adcc1ceda5aca713a79fc4f6a0c52c9da5b3e707e6ffe9", + "size_in_bytes": 1401 + }, + { + "_path": "site-packages/PySocks-1.7.1.dist-info/METADATA", + "path_type": "hardlink", + "sha256": "b27b89e3d44b7211119ff38456094675b69063eb2b82aefca3ce1a6b0dcec322", + "size_in_bytes": 13556 + }, + { + "_path": "site-packages/PySocks-1.7.1.dist-info/RECORD", + "path_type": "hardlink", + "sha256": "f173f371a9f3b581cd6afa789e5458a1bcad21b2a28876490cae2870599bc034", + "size_in_bytes": 882 + }, + { + "_path": "site-packages/PySocks-1.7.1.dist-info/REQUESTED", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/PySocks-1.7.1.dist-info/WHEEL", + "path_type": "hardlink", + "sha256": "3d9504c5d7fbd548bfb28ebb417a724ae1ed0a2dfe277c2f1783912ba93f4bc5", + "size_in_bytes": 91 + }, + { + "_path": "site-packages/PySocks-1.7.1.dist-info/direct_url.json", + "path_type": "hardlink", + "sha256": "4cf7505cb8215c2e9336fdeebf051bb96d22c4fb089fa1711c0a4104dbc4c862", + "size_in_bytes": 68 + }, + { + "_path": "site-packages/PySocks-1.7.1.dist-info/top_level.txt", + "path_type": "hardlink", + "sha256": "4ca48e21f0850682bd118f050586d8a82dcf59ddfef86d79a61f67f3e4073c39", + "size_in_bytes": 19 + }, + { + "_path": "site-packages/socks.py", + "path_type": "hardlink", + "sha256": "c4e627dbbb7d206adb4c1cd6b1452e3dad1806ea6582253293390e0795798856", + "size_in_bytes": 31086 + }, + { + "_path": "site-packages/sockshandler.py", + "path_type": "hardlink", + "sha256": "d926068fea70b7592380ba19026c9e6845c27990d64667d54bf406ea412b1ad6", + "size_in_bytes": 3966 + } + ], + "paths_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/recipe/conda_build_config.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/recipe/conda_build_config.yaml new file mode 100644 index 0000000000000000000000000000000000000000..c6eeac988cdae90479d45f7e1c669f5c9ec44583 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/recipe/conda_build_config.yaml @@ -0,0 +1,32 @@ +CI: azure +c_compiler: vs2017 +channel_sources: conda-forge +channel_targets: conda-forge main +cpu_optimization_target: nocona +cran_mirror: https://cran.r-project.org +cxx_compiler: vs2017 +extend_keys: +- ignore_build_only_deps +- ignore_version +- extend_keys +- pin_run_as_build +fortran_compiler: gfortran +ignore_build_only_deps: +- numpy +- python +lua: '5' +numpy: '1.26' +perl: 5.26.2 +pin_run_as_build: + python: + max_pin: x.x + min_pin: x.x + r-base: + max_pin: x.x + min_pin: x.x +python: '3.12' +python_min: '3.9' +r_base: '3.4' +target_platform: win-64 +vc: '14' +virtual_pkg: __win diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/recipe/meta.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/recipe/meta.yaml new file mode 100644 index 0000000000000000000000000000000000000000..a5e82cdd4f64c109085ec15fd009f0e1b88adb38 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/recipe/meta.yaml @@ -0,0 +1,63 @@ +# This file created by conda-build 24.11.2 +# meta.yaml template originally from: +# D:\a\1\s\recipe, last modified Tue Dec 3 09:13:14 2024 +# ------------------------------------------------ + +package: + name: pysocks + version: 1.7.1 +source: + sha256: 3f8804571ebe159c380ac6de37643bb4685970655d3bba243530d6558b799aa0 + url: https://pypi.org/packages/source/P/PySocks/PySocks-1.7.1.tar.gz +build: + noarch: python + number: '7' + script: D:\\bld\\pysocks_1733217287171\\_h_env\\python.exe -m pip install . -vv + --no-deps --no-build-isolation + string: pyh09c184e_7 +requirements: + host: + - bzip2 1.0.8 h2466b09_7 + - ca-certificates 2024.8.30 h56e8100_0 + - libffi 3.4.2 h8ffe710_5 + - libsqlite 3.47.0 h2466b09_1 + - libzlib 1.3.1 h2466b09_2 + - openssl 3.4.0 h2466b09_0 + - pip 24.3.1 pyh8b19718_0 + - python 3.9.20 hfaddaf0_1_cpython + - setuptools 75.6.0 pyhff2d567_1 + - tk 8.6.13 h5226925_1 + - tzdata 2024b hc8b5060_0 + - ucrt 10.0.22621.0 h57928b3_1 + - vc 14.3 ha32ba9b_23 + - vc14_runtime 14.42.34433 he29a5d6_23 + - vs2015_runtime 14.42.34433 hdffcdeb_23 + - wheel 0.45.1 pyhd8ed1ab_1 + - xz 5.2.6 h8d14728_0 + run: + - __win + - python >=3.9 + - win_inet_pton +test: + imports: + - socks + requires: + - python 3.9.* +about: + dev_url: https://github.com/Anorov/PySocks + doc_url: https://github.com/Anorov/PySocks/blob/master/README.md + home: https://github.com/Anorov/PySocks + license: BSD-3-Clause + license_family: BSD + license_file: LICENSE + summary: A Python SOCKS client module. See https://github.com/Anorov/PySocks for + more information. +extra: + copy_test_source_files: true + final: true + flow_run_id: azure_20241203.2.1 + recipe-maintainers: + - ocefpaf + - pmlandwehr + remote_url: https://github.com/conda-forge/pysocks-feedstock + sha: fd6a51b950188ecf552835f561c5de5f77b0ef53 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/recipe/meta.yaml.template b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/recipe/meta.yaml.template new file mode 100644 index 0000000000000000000000000000000000000000..fd350991631b115f7545c39c44b4bb21d8a27732 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/recipe/meta.yaml.template @@ -0,0 +1,46 @@ +{% set version = "1.7.1" %} + +package: + name: pysocks + version: {{ version }} + +source: + url: https://pypi.org/packages/source/P/PySocks/PySocks-{{ version }}.tar.gz + sha256: 3f8804571ebe159c380ac6de37643bb4685970655d3bba243530d6558b799aa0 + +build: + number: 7 + script: {{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation + noarch: python + +requirements: + host: + - python {{ python_min }} + - setuptools + - pip + run: + - python >={{ python_min }} + - {{ virtual_pkg|default("__unix") }} + {% if virtual_pkg == "__win" %} + - win_inet_pton + {% endif %} + +test: + requires: + - python {{ python_min }} + imports: + - socks + +about: + home: https://github.com/Anorov/PySocks + license_file: LICENSE + license: BSD-3-Clause + summary: 'A Python SOCKS client module. See https://github.com/Anorov/PySocks for more information.' + license_family: BSD + doc_url: https://github.com/Anorov/PySocks/blob/master/README.md + dev_url: https://github.com/Anorov/PySocks + +extra: + recipe-maintainers: + - pmlandwehr + - ocefpaf diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/recipe/recipe-scripts-license.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/recipe/recipe-scripts-license.txt new file mode 100644 index 0000000000000000000000000000000000000000..f093e06198e8f9997e31fe9bf3cedf8d12a5c6dd --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/recipe/recipe-scripts-license.txt @@ -0,0 +1,27 @@ +BSD-3-Clause license +Copyright (c) 2015-2022, conda-forge contributors +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + 3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/repodata_record.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/repodata_record.json new file mode 100644 index 0000000000000000000000000000000000000000..a269690e54df65f928a8fad8ed8bd6158005e81b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/repodata_record.json @@ -0,0 +1,26 @@ +{ + "arch": null, + "build": "pyh09c184e_7", + "build_number": 7, + "build_string": "pyh09c184e_7", + "channel": "conda-forge", + "constrains": [], + "depends": [ + "__win", + "python >=3.9", + "win_inet_pton" + ], + "fn": "pysocks-1.7.1-pyh09c184e_7.conda", + "license": "BSD-3-Clause", + "license_family": "BSD", + "md5": "e2fd202833c4a981ce8a65974fe4abd1", + "name": "pysocks", + "noarch": "python", + "platform": null, + "sha256": "d016e04b0e12063fbee4a2d5fbb9b39a8d191b5a0042f0b8459188aedeabb0ca", + "size": 21784, + "subdir": "noarch", + "timestamp": 1733217448, + "url": "https://conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7.conda", + "version": "1.7.1" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/test/run_test.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/test/run_test.py new file mode 100644 index 0000000000000000000000000000000000000000..75549845fdbfe650f8d8e50b56c68ceb6191af8c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/test/run_test.py @@ -0,0 +1,3 @@ +print("import: 'socks'") +import socks + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/test/test_time_dependencies.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/test/test_time_dependencies.json new file mode 100644 index 0000000000000000000000000000000000000000..4cfa002f5ecf817db2efa22e84c29546cc3cb3b3 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/info/test/test_time_dependencies.json @@ -0,0 +1 @@ +["python 3.9.*"] \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/INSTALLER b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/INSTALLER new file mode 100644 index 0000000000000000000000000000000000000000..f79e4cb9aaf0b2d9e8ba78861e2071317b2384b3 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/INSTALLER @@ -0,0 +1 @@ +conda \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..04b6b1f37c4dffb82942cdcc2b77092798ca4aa2 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/LICENSE @@ -0,0 +1,22 @@ +Copyright 2006 Dan-Haim. All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, +are permitted provided that the following conditions are met: +1. Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. +2. Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. +3. Neither the name of Dan Haim nor the names of his contributors may be used + to endorse or promote products derived from this software without specific + prior written permission. + +THIS SOFTWARE IS PROVIDED BY DAN HAIM "AS IS" AND ANY EXPRESS OR IMPLIED +WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +EVENT SHALL DAN HAIM OR HIS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA +OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMANGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/METADATA b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/METADATA new file mode 100644 index 0000000000000000000000000000000000000000..79a2ee5db96b01c23842c2b01b25435ccd732871 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/METADATA @@ -0,0 +1,319 @@ +Metadata-Version: 2.1 +Name: PySocks +Version: 1.7.1 +Summary: A Python SOCKS client module. See https://github.com/Anorov/PySocks for more information. +Home-page: https://github.com/Anorov/PySocks +Author: Anorov +Author-email: anorov.vorona@gmail.com +License: BSD +Keywords: socks,proxy +Classifier: Programming Language :: Python :: 2 +Classifier: Programming Language :: Python :: 2.7 +Classifier: Programming Language :: Python :: 3 +Classifier: Programming Language :: Python :: 3.4 +Classifier: Programming Language :: Python :: 3.5 +Classifier: Programming Language :: Python :: 3.6 +Requires-Python: >=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.* +Description-Content-Type: text/markdown +License-File: LICENSE + +PySocks +======= + +PySocks lets you send traffic through SOCKS and HTTP proxy servers. It is a modern fork of [SocksiPy](http://socksipy.sourceforge.net/) with bug fixes and extra features. + +Acts as a drop-in replacement to the socket module. Seamlessly configure SOCKS proxies for any socket object by calling `socket_object.set_proxy()`. + +---------------- + +Features +======== + +* SOCKS proxy client for Python 2.7 and 3.4+ +* TCP supported +* UDP mostly supported (issues may occur in some edge cases) +* HTTP proxy client included but not supported or recommended (you should use urllib2's or requests' own HTTP proxy interface) +* urllib2 handler included. `pip install` / `setup.py install` will automatically install the `sockshandler` module. + +Installation +============ + + pip install PySocks + +Or download the tarball / `git clone` and... + + python setup.py install + +These will install both the `socks` and `sockshandler` modules. + +Alternatively, include just `socks.py` in your project. + +-------------------------------------------- + +*Warning:* PySocks/SocksiPy only supports HTTP proxies that use CONNECT tunneling. Certain HTTP proxies may not work with this library. If you wish to use HTTP (not SOCKS) proxies, it is recommended that you rely on your HTTP client's native proxy support (`proxies` dict for `requests`, or `urllib2.ProxyHandler` for `urllib2`) instead. + +-------------------------------------------- + +Usage +===== + +## socks.socksocket ## + + import socks + + s = socks.socksocket() # Same API as socket.socket in the standard lib + + s.set_proxy(socks.SOCKS5, "localhost") # SOCKS4 and SOCKS5 use port 1080 by default + # Or + s.set_proxy(socks.SOCKS4, "localhost", 4444) + # Or + s.set_proxy(socks.HTTP, "5.5.5.5", 8888) + + # Can be treated identical to a regular socket object + s.connect(("www.somesite.com", 80)) + s.sendall("GET / HTTP/1.1 ...") + print s.recv(4096) + +## Monkeypatching ## + +To monkeypatch the entire standard library with a single default proxy: + + import urllib2 + import socket + import socks + + socks.set_default_proxy(socks.SOCKS5, "localhost") + socket.socket = socks.socksocket + + urllib2.urlopen("http://www.somesite.com/") # All requests will pass through the SOCKS proxy + +Note that monkeypatching may not work for all standard modules or for all third party modules, and generally isn't recommended. Monkeypatching is usually an anti-pattern in Python. + +## urllib2 Handler ## + +Example use case with the `sockshandler` urllib2 handler. Note that you must import both `socks` and `sockshandler`, as the handler is its own module separate from PySocks. The module is included in the PyPI package. + + import urllib2 + import socks + from sockshandler import SocksiPyHandler + + opener = urllib2.build_opener(SocksiPyHandler(socks.SOCKS5, "127.0.0.1", 9050)) + print opener.open("http://www.somesite.com/") # All requests made by the opener will pass through the SOCKS proxy + +-------------------------------------------- + +Original SocksiPy README attached below, amended to reflect API changes. + +-------------------------------------------- + +SocksiPy + +A Python SOCKS module. + +(C) 2006 Dan-Haim. All rights reserved. + +See LICENSE file for details. + + +*WHAT IS A SOCKS PROXY?* + +A SOCKS proxy is a proxy server at the TCP level. In other words, it acts as +a tunnel, relaying all traffic going through it without modifying it. +SOCKS proxies can be used to relay traffic using any network protocol that +uses TCP. + +*WHAT IS SOCKSIPY?* + +This Python module allows you to create TCP connections through a SOCKS +proxy without any special effort. +It also supports relaying UDP packets with a SOCKS5 proxy. + +*PROXY COMPATIBILITY* + +SocksiPy is compatible with three different types of proxies: + +1. SOCKS Version 4 (SOCKS4), including the SOCKS4a extension. +2. SOCKS Version 5 (SOCKS5). +3. HTTP Proxies which support tunneling using the CONNECT method. + +*SYSTEM REQUIREMENTS* + +Being written in Python, SocksiPy can run on any platform that has a Python +interpreter and TCP/IP support. +This module has been tested with Python 2.3 and should work with greater versions +just as well. + + +INSTALLATION +------------- + +Simply copy the file "socks.py" to your Python's `lib/site-packages` directory, +and you're ready to go. [Editor's note: it is better to use `python setup.py install` for PySocks] + + +USAGE +------ + +First load the socks module with the command: + + >>> import socks + >>> + +The socks module provides a class called `socksocket`, which is the base to all of the module's functionality. + +The `socksocket` object has the same initialization parameters as the normal socket +object to ensure maximal compatibility, however it should be noted that `socksocket` will only function with family being `AF_INET` and +type being either `SOCK_STREAM` or `SOCK_DGRAM`. +Generally, it is best to initialize the `socksocket` object with no parameters + + >>> s = socks.socksocket() + >>> + +The `socksocket` object has an interface which is very similiar to socket's (in fact +the `socksocket` class is derived from socket) with a few extra methods. +To select the proxy server you would like to use, use the `set_proxy` method, whose +syntax is: + + set_proxy(proxy_type, addr[, port[, rdns[, username[, password]]]]) + +Explanation of the parameters: + +`proxy_type` - The type of the proxy server. This can be one of three possible +choices: `PROXY_TYPE_SOCKS4`, `PROXY_TYPE_SOCKS5` and `PROXY_TYPE_HTTP` for SOCKS4, +SOCKS5 and HTTP servers respectively. `SOCKS4`, `SOCKS5`, and `HTTP` are all aliases, respectively. + +`addr` - The IP address or DNS name of the proxy server. + +`port` - The port of the proxy server. Defaults to 1080 for socks and 8080 for http. + +`rdns` - This is a boolean flag than modifies the behavior regarding DNS resolving. +If it is set to True, DNS resolving will be preformed remotely, on the server. +If it is set to False, DNS resolving will be preformed locally. Please note that +setting this to True with SOCKS4 servers actually use an extension to the protocol, +called SOCKS4a, which may not be supported on all servers (SOCKS5 and http servers +always support DNS). The default is True. + +`username` - For SOCKS5 servers, this allows simple username / password authentication +with the server. For SOCKS4 servers, this parameter will be sent as the userid. +This parameter is ignored if an HTTP server is being used. If it is not provided, +authentication will not be used (servers may accept unauthenticated requests). + +`password` - This parameter is valid only for SOCKS5 servers and specifies the +respective password for the username provided. + +Example of usage: + + >>> s.set_proxy(socks.SOCKS5, "socks.example.com") # uses default port 1080 + >>> s.set_proxy(socks.SOCKS4, "socks.test.com", 1081) + +After the set_proxy method has been called, simply call the connect method with the +traditional parameters to establish a connection through the proxy: + + >>> s.connect(("www.sourceforge.net", 80)) + >>> + +Connection will take a bit longer to allow negotiation with the proxy server. +Please note that calling connect without calling `set_proxy` earlier will connect +without a proxy (just like a regular socket). + +Errors: Any errors in the connection process will trigger exceptions. The exception +may either be generated by the underlying socket layer or may be custom module +exceptions, whose details follow: + +class `ProxyError` - This is a base exception class. It is not raised directly but +rather all other exception classes raised by this module are derived from it. +This allows an easy way to catch all proxy-related errors. It descends from `IOError`. + +All `ProxyError` exceptions have an attribute `socket_err`, which will contain either a +caught `socket.error` exception, or `None` if there wasn't any. + +class `GeneralProxyError` - When thrown, it indicates a problem which does not fall +into another category. + +* `Sent invalid data` - This error means that unexpected data has been received from +the server. The most common reason is that the server specified as the proxy is +not really a SOCKS4/SOCKS5/HTTP proxy, or maybe the proxy type specified is wrong. + +* `Connection closed unexpectedly` - The proxy server unexpectedly closed the connection. +This may indicate that the proxy server is experiencing network or software problems. + +* `Bad proxy type` - This will be raised if the type of the proxy supplied to the +set_proxy function was not one of `SOCKS4`/`SOCKS5`/`HTTP`. + +* `Bad input` - This will be raised if the `connect()` method is called with bad input +parameters. + +class `SOCKS5AuthError` - This indicates that the connection through a SOCKS5 server +failed due to an authentication problem. + +* `Authentication is required` - This will happen if you use a SOCKS5 server which +requires authentication without providing a username / password at all. + +* `All offered authentication methods were rejected` - This will happen if the proxy +requires a special authentication method which is not supported by this module. + +* `Unknown username or invalid password` - Self descriptive. + +class `SOCKS5Error` - This will be raised for SOCKS5 errors which are not related to +authentication. +The parameter is a tuple containing a code, as given by the server, +and a description of the +error. The possible errors, according to the RFC, are: + +* `0x01` - General SOCKS server failure - If for any reason the proxy server is unable to +fulfill your request (internal server error). +* `0x02` - connection not allowed by ruleset - If the address you're trying to connect to +is blacklisted on the server or requires authentication. +* `0x03` - Network unreachable - The target could not be contacted. A router on the network +had replied with a destination net unreachable error. +* `0x04` - Host unreachable - The target could not be contacted. A router on the network +had replied with a destination host unreachable error. +* `0x05` - Connection refused - The target server has actively refused the connection +(the requested port is closed). +* `0x06` - TTL expired - The TTL value of the SYN packet from the proxy to the target server +has expired. This usually means that there are network problems causing the packet +to be caught in a router-to-router "ping-pong". +* `0x07` - Command not supported - For instance if the server does not support UDP. +* `0x08` - Address type not supported - The client has provided an invalid address type. +When using this module, this error should not occur. + +class `SOCKS4Error` - This will be raised for SOCKS4 errors. The parameter is a tuple +containing a code and a description of the error, as given by the server. The +possible error, according to the specification are: + +* `0x5B` - Request rejected or failed - Will be raised in the event of an failure for any +reason other then the two mentioned next. +* `0x5C` - request rejected because SOCKS server cannot connect to identd on the client - +The Socks server had tried an ident lookup on your computer and has failed. In this +case you should run an identd server and/or configure your firewall to allow incoming +connections to local port 113 from the remote server. +* `0x5D` - request rejected because the client program and identd report different user-ids - +The Socks server had performed an ident lookup on your computer and has received a +different userid than the one you have provided. Change your userid (through the +username parameter of the set_proxy method) to match and try again. + +class `HTTPError` - This will be raised for HTTP errors. The message will contain +the HTTP status code and provided error message. + +After establishing the connection, the object behaves like a standard socket. + +Methods like `makefile()` and `settimeout()` should behave just like regular sockets. +Call the `close()` method to close the connection. + +In addition to the `socksocket` class, an additional function worth mentioning is the +`set_default_proxy` function. The parameters are the same as the `set_proxy` method. +This function will set default proxy settings for newly created `socksocket` objects, +in which the proxy settings haven't been changed via the `set_proxy` method. +This is quite useful if you wish to force 3rd party modules to use a SOCKS proxy, +by overriding the socket object. +For example: + + >>> socks.set_default_proxy(socks.SOCKS5, "socks.example.com") + >>> socket.socket = socks.socksocket + >>> urllib.urlopen("http://www.sourceforge.net/") + + +PROBLEMS +--------- + +Please open a GitHub issue at https://github.com/Anorov/PySocks diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/RECORD b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/RECORD new file mode 100644 index 0000000000000000000000000000000000000000..3e907013bc7ad29010dbc1ce85e86339b97a8abd --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/RECORD @@ -0,0 +1,12 @@ +PySocks-1.7.1.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +PySocks-1.7.1.dist-info/LICENSE,sha256=cCfiFOAU63i3rcwc7aWspxOnn8T2oMUsnaWz5wfm_-k,1401 +PySocks-1.7.1.dist-info/METADATA,sha256=snuJ49RLchERn_OEVglGdbaQY-srgq78o84aaw3OwyI,13556 +PySocks-1.7.1.dist-info/RECORD,, +PySocks-1.7.1.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +PySocks-1.7.1.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91 +PySocks-1.7.1.dist-info/direct_url.json,sha256=TPdQXLghXC6TNv3uvwUbuW0ixPsIn6FxHApBBNvEyGI,68 +PySocks-1.7.1.dist-info/top_level.txt,sha256=TKSOIfCFBoK9EY8FBYbYqC3PWd3--G15ph9n8-QHPDk,19 +__pycache__/socks.cpython-39.pyc,, +__pycache__/sockshandler.cpython-39.pyc,, +socks.py,sha256=xOYn27t9IGrbTBzWsUUuPa0YBuplgiUykzkOB5V5iFY,31086 +sockshandler.py,sha256=2SYGj-pwt1kjgLoZAmyeaEXCeZDWRmfVS_QG6kErGtY,3966 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/REQUESTED b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/REQUESTED new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/WHEEL b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/WHEEL new file mode 100644 index 0000000000000000000000000000000000000000..ae527e7d64811439e61b93aa375defb30e06edfe --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/WHEEL @@ -0,0 +1,5 @@ +Wheel-Version: 1.0 +Generator: setuptools (75.6.0) +Root-Is-Purelib: true +Tag: py3-none-any + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/direct_url.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/direct_url.json new file mode 100644 index 0000000000000000000000000000000000000000..edd8bbcd4d93a200abe5c7e2eb3856a5942b4601 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/direct_url.json @@ -0,0 +1 @@ +{"dir_info": {}, "url": "file:///D:/bld/pysocks_1733217287171/work"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/top_level.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/top_level.txt new file mode 100644 index 0000000000000000000000000000000000000000..9476163ae51c2dba237187f3b76d5ff46e40892f --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/PySocks-1.7.1.dist-info/top_level.txt @@ -0,0 +1,2 @@ +socks +sockshandler diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/socks.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/socks.py new file mode 100644 index 0000000000000000000000000000000000000000..83b1435dfaa53bcc0806053bc2436ee7773262b8 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/socks.py @@ -0,0 +1,847 @@ +from base64 import b64encode +try: + from collections.abc import Callable +except ImportError: + from collections import Callable +from errno import EOPNOTSUPP, EINVAL, EAGAIN +import functools +from io import BytesIO +import logging +import os +from os import SEEK_CUR +import socket +import struct +import sys + +__version__ = "1.7.1" + + +if os.name == "nt" and sys.version_info < (3, 0): + try: + import win_inet_pton + except ImportError: + raise ImportError( + "To run PySocks on Windows you must install win_inet_pton") + +log = logging.getLogger(__name__) + +PROXY_TYPE_SOCKS4 = SOCKS4 = 1 +PROXY_TYPE_SOCKS5 = SOCKS5 = 2 +PROXY_TYPE_HTTP = HTTP = 3 + +PROXY_TYPES = {"SOCKS4": SOCKS4, "SOCKS5": SOCKS5, "HTTP": HTTP} +PRINTABLE_PROXY_TYPES = dict(zip(PROXY_TYPES.values(), PROXY_TYPES.keys())) + +_orgsocket = _orig_socket = socket.socket + + +def set_self_blocking(function): + + @functools.wraps(function) + def wrapper(*args, **kwargs): + self = args[0] + try: + _is_blocking = self.gettimeout() + if _is_blocking == 0: + self.setblocking(True) + return function(*args, **kwargs) + except Exception as e: + raise + finally: + # set orgin blocking + if _is_blocking == 0: + self.setblocking(False) + return wrapper + + +class ProxyError(IOError): + """Socket_err contains original socket.error exception.""" + def __init__(self, msg, socket_err=None): + self.msg = msg + self.socket_err = socket_err + + if socket_err: + self.msg += ": {}".format(socket_err) + + def __str__(self): + return self.msg + + +class GeneralProxyError(ProxyError): + pass + + +class ProxyConnectionError(ProxyError): + pass + + +class SOCKS5AuthError(ProxyError): + pass + + +class SOCKS5Error(ProxyError): + pass + + +class SOCKS4Error(ProxyError): + pass + + +class HTTPError(ProxyError): + pass + +SOCKS4_ERRORS = { + 0x5B: "Request rejected or failed", + 0x5C: ("Request rejected because SOCKS server cannot connect to identd on" + " the client"), + 0x5D: ("Request rejected because the client program and identd report" + " different user-ids") +} + +SOCKS5_ERRORS = { + 0x01: "General SOCKS server failure", + 0x02: "Connection not allowed by ruleset", + 0x03: "Network unreachable", + 0x04: "Host unreachable", + 0x05: "Connection refused", + 0x06: "TTL expired", + 0x07: "Command not supported, or protocol error", + 0x08: "Address type not supported" +} + +DEFAULT_PORTS = {SOCKS4: 1080, SOCKS5: 1080, HTTP: 8080} + + +def set_default_proxy(proxy_type=None, addr=None, port=None, rdns=True, + username=None, password=None): + """Sets a default proxy. + + All further socksocket objects will use the default unless explicitly + changed. All parameters are as for socket.set_proxy().""" + socksocket.default_proxy = (proxy_type, addr, port, rdns, + username.encode() if username else None, + password.encode() if password else None) + + +def setdefaultproxy(*args, **kwargs): + if "proxytype" in kwargs: + kwargs["proxy_type"] = kwargs.pop("proxytype") + return set_default_proxy(*args, **kwargs) + + +def get_default_proxy(): + """Returns the default proxy, set by set_default_proxy.""" + return socksocket.default_proxy + +getdefaultproxy = get_default_proxy + + +def wrap_module(module): + """Attempts to replace a module's socket library with a SOCKS socket. + + Must set a default proxy using set_default_proxy(...) first. This will + only work on modules that import socket directly into the namespace; + most of the Python Standard Library falls into this category.""" + if socksocket.default_proxy: + module.socket.socket = socksocket + else: + raise GeneralProxyError("No default proxy specified") + +wrapmodule = wrap_module + + +def create_connection(dest_pair, + timeout=None, source_address=None, + proxy_type=None, proxy_addr=None, + proxy_port=None, proxy_rdns=True, + proxy_username=None, proxy_password=None, + socket_options=None): + """create_connection(dest_pair, *[, timeout], **proxy_args) -> socket object + + Like socket.create_connection(), but connects to proxy + before returning the socket object. + + dest_pair - 2-tuple of (IP/hostname, port). + **proxy_args - Same args passed to socksocket.set_proxy() if present. + timeout - Optional socket timeout value, in seconds. + source_address - tuple (host, port) for the socket to bind to as its source + address before connecting (only for compatibility) + """ + # Remove IPv6 brackets on the remote address and proxy address. + remote_host, remote_port = dest_pair + if remote_host.startswith("["): + remote_host = remote_host.strip("[]") + if proxy_addr and proxy_addr.startswith("["): + proxy_addr = proxy_addr.strip("[]") + + err = None + + # Allow the SOCKS proxy to be on IPv4 or IPv6 addresses. + for r in socket.getaddrinfo(proxy_addr, proxy_port, 0, socket.SOCK_STREAM): + family, socket_type, proto, canonname, sa = r + sock = None + try: + sock = socksocket(family, socket_type, proto) + + if socket_options: + for opt in socket_options: + sock.setsockopt(*opt) + + if isinstance(timeout, (int, float)): + sock.settimeout(timeout) + + if proxy_type: + sock.set_proxy(proxy_type, proxy_addr, proxy_port, proxy_rdns, + proxy_username, proxy_password) + if source_address: + sock.bind(source_address) + + sock.connect((remote_host, remote_port)) + return sock + + except (socket.error, ProxyError) as e: + err = e + if sock: + sock.close() + sock = None + + if err: + raise err + + raise socket.error("gai returned empty list.") + + +class _BaseSocket(socket.socket): + """Allows Python 2 delegated methods such as send() to be overridden.""" + def __init__(self, *pos, **kw): + _orig_socket.__init__(self, *pos, **kw) + + self._savedmethods = dict() + for name in self._savenames: + self._savedmethods[name] = getattr(self, name) + delattr(self, name) # Allows normal overriding mechanism to work + + _savenames = list() + + +def _makemethod(name): + return lambda self, *pos, **kw: self._savedmethods[name](*pos, **kw) +for name in ("sendto", "send", "recvfrom", "recv"): + method = getattr(_BaseSocket, name, None) + + # Determine if the method is not defined the usual way + # as a function in the class. + # Python 2 uses __slots__, so there are descriptors for each method, + # but they are not functions. + if not isinstance(method, Callable): + _BaseSocket._savenames.append(name) + setattr(_BaseSocket, name, _makemethod(name)) + + +class socksocket(_BaseSocket): + """socksocket([family[, type[, proto]]]) -> socket object + + Open a SOCKS enabled socket. The parameters are the same as + those of the standard socket init. In order for SOCKS to work, + you must specify family=AF_INET and proto=0. + The "type" argument must be either SOCK_STREAM or SOCK_DGRAM. + """ + + default_proxy = None + + def __init__(self, family=socket.AF_INET, type=socket.SOCK_STREAM, + proto=0, *args, **kwargs): + if type not in (socket.SOCK_STREAM, socket.SOCK_DGRAM): + msg = "Socket type must be stream or datagram, not {!r}" + raise ValueError(msg.format(type)) + + super(socksocket, self).__init__(family, type, proto, *args, **kwargs) + self._proxyconn = None # TCP connection to keep UDP relay alive + + if self.default_proxy: + self.proxy = self.default_proxy + else: + self.proxy = (None, None, None, None, None, None) + self.proxy_sockname = None + self.proxy_peername = None + + self._timeout = None + + def _readall(self, file, count): + """Receive EXACTLY the number of bytes requested from the file object. + + Blocks until the required number of bytes have been received.""" + data = b"" + while len(data) < count: + d = file.read(count - len(data)) + if not d: + raise GeneralProxyError("Connection closed unexpectedly") + data += d + return data + + def settimeout(self, timeout): + self._timeout = timeout + try: + # test if we're connected, if so apply timeout + peer = self.get_proxy_peername() + super(socksocket, self).settimeout(self._timeout) + except socket.error: + pass + + def gettimeout(self): + return self._timeout + + def setblocking(self, v): + if v: + self.settimeout(None) + else: + self.settimeout(0.0) + + def set_proxy(self, proxy_type=None, addr=None, port=None, rdns=True, + username=None, password=None): + """ Sets the proxy to be used. + + proxy_type - The type of the proxy to be used. Three types + are supported: PROXY_TYPE_SOCKS4 (including socks4a), + PROXY_TYPE_SOCKS5 and PROXY_TYPE_HTTP + addr - The address of the server (IP or DNS). + port - The port of the server. Defaults to 1080 for SOCKS + servers and 8080 for HTTP proxy servers. + rdns - Should DNS queries be performed on the remote side + (rather than the local side). The default is True. + Note: This has no effect with SOCKS4 servers. + username - Username to authenticate with to the server. + The default is no authentication. + password - Password to authenticate with to the server. + Only relevant when username is also provided.""" + self.proxy = (proxy_type, addr, port, rdns, + username.encode() if username else None, + password.encode() if password else None) + + def setproxy(self, *args, **kwargs): + if "proxytype" in kwargs: + kwargs["proxy_type"] = kwargs.pop("proxytype") + return self.set_proxy(*args, **kwargs) + + def bind(self, *pos, **kw): + """Implements proxy connection for UDP sockets. + + Happens during the bind() phase.""" + (proxy_type, proxy_addr, proxy_port, rdns, username, + password) = self.proxy + if not proxy_type or self.type != socket.SOCK_DGRAM: + return _orig_socket.bind(self, *pos, **kw) + + if self._proxyconn: + raise socket.error(EINVAL, "Socket already bound to an address") + if proxy_type != SOCKS5: + msg = "UDP only supported by SOCKS5 proxy type" + raise socket.error(EOPNOTSUPP, msg) + super(socksocket, self).bind(*pos, **kw) + + # Need to specify actual local port because + # some relays drop packets if a port of zero is specified. + # Avoid specifying host address in case of NAT though. + _, port = self.getsockname() + dst = ("0", port) + + self._proxyconn = _orig_socket() + proxy = self._proxy_addr() + self._proxyconn.connect(proxy) + + UDP_ASSOCIATE = b"\x03" + _, relay = self._SOCKS5_request(self._proxyconn, UDP_ASSOCIATE, dst) + + # The relay is most likely on the same host as the SOCKS proxy, + # but some proxies return a private IP address (10.x.y.z) + host, _ = proxy + _, port = relay + super(socksocket, self).connect((host, port)) + super(socksocket, self).settimeout(self._timeout) + self.proxy_sockname = ("0.0.0.0", 0) # Unknown + + def sendto(self, bytes, *args, **kwargs): + if self.type != socket.SOCK_DGRAM: + return super(socksocket, self).sendto(bytes, *args, **kwargs) + if not self._proxyconn: + self.bind(("", 0)) + + address = args[-1] + flags = args[:-1] + + header = BytesIO() + RSV = b"\x00\x00" + header.write(RSV) + STANDALONE = b"\x00" + header.write(STANDALONE) + self._write_SOCKS5_address(address, header) + + sent = super(socksocket, self).send(header.getvalue() + bytes, *flags, + **kwargs) + return sent - header.tell() + + def send(self, bytes, flags=0, **kwargs): + if self.type == socket.SOCK_DGRAM: + return self.sendto(bytes, flags, self.proxy_peername, **kwargs) + else: + return super(socksocket, self).send(bytes, flags, **kwargs) + + def recvfrom(self, bufsize, flags=0): + if self.type != socket.SOCK_DGRAM: + return super(socksocket, self).recvfrom(bufsize, flags) + if not self._proxyconn: + self.bind(("", 0)) + + buf = BytesIO(super(socksocket, self).recv(bufsize + 1024, flags)) + buf.seek(2, SEEK_CUR) + frag = buf.read(1) + if ord(frag): + raise NotImplementedError("Received UDP packet fragment") + fromhost, fromport = self._read_SOCKS5_address(buf) + + if self.proxy_peername: + peerhost, peerport = self.proxy_peername + if fromhost != peerhost or peerport not in (0, fromport): + raise socket.error(EAGAIN, "Packet filtered") + + return (buf.read(bufsize), (fromhost, fromport)) + + def recv(self, *pos, **kw): + bytes, _ = self.recvfrom(*pos, **kw) + return bytes + + def close(self): + if self._proxyconn: + self._proxyconn.close() + return super(socksocket, self).close() + + def get_proxy_sockname(self): + """Returns the bound IP address and port number at the proxy.""" + return self.proxy_sockname + + getproxysockname = get_proxy_sockname + + def get_proxy_peername(self): + """ + Returns the IP and port number of the proxy. + """ + return self.getpeername() + + getproxypeername = get_proxy_peername + + def get_peername(self): + """Returns the IP address and port number of the destination machine. + + Note: get_proxy_peername returns the proxy.""" + return self.proxy_peername + + getpeername = get_peername + + def _negotiate_SOCKS5(self, *dest_addr): + """Negotiates a stream connection through a SOCKS5 server.""" + CONNECT = b"\x01" + self.proxy_peername, self.proxy_sockname = self._SOCKS5_request( + self, CONNECT, dest_addr) + + def _SOCKS5_request(self, conn, cmd, dst): + """ + Send SOCKS5 request with given command (CMD field) and + address (DST field). Returns resolved DST address that was used. + """ + proxy_type, addr, port, rdns, username, password = self.proxy + + writer = conn.makefile("wb") + reader = conn.makefile("rb", 0) # buffering=0 renamed in Python 3 + try: + # First we'll send the authentication packages we support. + if username and password: + # The username/password details were supplied to the + # set_proxy method so we support the USERNAME/PASSWORD + # authentication (in addition to the standard none). + writer.write(b"\x05\x02\x00\x02") + else: + # No username/password were entered, therefore we + # only support connections with no authentication. + writer.write(b"\x05\x01\x00") + + # We'll receive the server's response to determine which + # method was selected + writer.flush() + chosen_auth = self._readall(reader, 2) + + if chosen_auth[0:1] != b"\x05": + # Note: string[i:i+1] is used because indexing of a bytestring + # via bytestring[i] yields an integer in Python 3 + raise GeneralProxyError( + "SOCKS5 proxy server sent invalid data") + + # Check the chosen authentication method + + if chosen_auth[1:2] == b"\x02": + # Okay, we need to perform a basic username/password + # authentication. + if not (username and password): + # Although we said we don't support authentication, the + # server may still request basic username/password + # authentication + raise SOCKS5AuthError("No username/password supplied. " + "Server requested username/password" + " authentication") + + writer.write(b"\x01" + chr(len(username)).encode() + + username + + chr(len(password)).encode() + + password) + writer.flush() + auth_status = self._readall(reader, 2) + if auth_status[0:1] != b"\x01": + # Bad response + raise GeneralProxyError( + "SOCKS5 proxy server sent invalid data") + if auth_status[1:2] != b"\x00": + # Authentication failed + raise SOCKS5AuthError("SOCKS5 authentication failed") + + # Otherwise, authentication succeeded + + # No authentication is required if 0x00 + elif chosen_auth[1:2] != b"\x00": + # Reaching here is always bad + if chosen_auth[1:2] == b"\xFF": + raise SOCKS5AuthError( + "All offered SOCKS5 authentication methods were" + " rejected") + else: + raise GeneralProxyError( + "SOCKS5 proxy server sent invalid data") + + # Now we can request the actual connection + writer.write(b"\x05" + cmd + b"\x00") + resolved = self._write_SOCKS5_address(dst, writer) + writer.flush() + + # Get the response + resp = self._readall(reader, 3) + if resp[0:1] != b"\x05": + raise GeneralProxyError( + "SOCKS5 proxy server sent invalid data") + + status = ord(resp[1:2]) + if status != 0x00: + # Connection failed: server returned an error + error = SOCKS5_ERRORS.get(status, "Unknown error") + raise SOCKS5Error("{:#04x}: {}".format(status, error)) + + # Get the bound address/port + bnd = self._read_SOCKS5_address(reader) + + super(socksocket, self).settimeout(self._timeout) + return (resolved, bnd) + finally: + reader.close() + writer.close() + + def _write_SOCKS5_address(self, addr, file): + """ + Return the host and port packed for the SOCKS5 protocol, + and the resolved address as a tuple object. + """ + host, port = addr + proxy_type, _, _, rdns, username, password = self.proxy + family_to_byte = {socket.AF_INET: b"\x01", socket.AF_INET6: b"\x04"} + + # If the given destination address is an IP address, we'll + # use the IP address request even if remote resolving was specified. + # Detect whether the address is IPv4/6 directly. + for family in (socket.AF_INET, socket.AF_INET6): + try: + addr_bytes = socket.inet_pton(family, host) + file.write(family_to_byte[family] + addr_bytes) + host = socket.inet_ntop(family, addr_bytes) + file.write(struct.pack(">H", port)) + return host, port + except socket.error: + continue + + # Well it's not an IP number, so it's probably a DNS name. + if rdns: + # Resolve remotely + host_bytes = host.encode("idna") + file.write(b"\x03" + chr(len(host_bytes)).encode() + host_bytes) + else: + # Resolve locally + addresses = socket.getaddrinfo(host, port, socket.AF_UNSPEC, + socket.SOCK_STREAM, + socket.IPPROTO_TCP, + socket.AI_ADDRCONFIG) + # We can't really work out what IP is reachable, so just pick the + # first. + target_addr = addresses[0] + family = target_addr[0] + host = target_addr[4][0] + + addr_bytes = socket.inet_pton(family, host) + file.write(family_to_byte[family] + addr_bytes) + host = socket.inet_ntop(family, addr_bytes) + file.write(struct.pack(">H", port)) + return host, port + + def _read_SOCKS5_address(self, file): + atyp = self._readall(file, 1) + if atyp == b"\x01": + addr = socket.inet_ntoa(self._readall(file, 4)) + elif atyp == b"\x03": + length = self._readall(file, 1) + addr = self._readall(file, ord(length)) + elif atyp == b"\x04": + addr = socket.inet_ntop(socket.AF_INET6, self._readall(file, 16)) + else: + raise GeneralProxyError("SOCKS5 proxy server sent invalid data") + + port = struct.unpack(">H", self._readall(file, 2))[0] + return addr, port + + def _negotiate_SOCKS4(self, dest_addr, dest_port): + """Negotiates a connection through a SOCKS4 server.""" + proxy_type, addr, port, rdns, username, password = self.proxy + + writer = self.makefile("wb") + reader = self.makefile("rb", 0) # buffering=0 renamed in Python 3 + try: + # Check if the destination address provided is an IP address + remote_resolve = False + try: + addr_bytes = socket.inet_aton(dest_addr) + except socket.error: + # It's a DNS name. Check where it should be resolved. + if rdns: + addr_bytes = b"\x00\x00\x00\x01" + remote_resolve = True + else: + addr_bytes = socket.inet_aton( + socket.gethostbyname(dest_addr)) + + # Construct the request packet + writer.write(struct.pack(">BBH", 0x04, 0x01, dest_port)) + writer.write(addr_bytes) + + # The username parameter is considered userid for SOCKS4 + if username: + writer.write(username) + writer.write(b"\x00") + + # DNS name if remote resolving is required + # NOTE: This is actually an extension to the SOCKS4 protocol + # called SOCKS4A and may not be supported in all cases. + if remote_resolve: + writer.write(dest_addr.encode("idna") + b"\x00") + writer.flush() + + # Get the response from the server + resp = self._readall(reader, 8) + if resp[0:1] != b"\x00": + # Bad data + raise GeneralProxyError( + "SOCKS4 proxy server sent invalid data") + + status = ord(resp[1:2]) + if status != 0x5A: + # Connection failed: server returned an error + error = SOCKS4_ERRORS.get(status, "Unknown error") + raise SOCKS4Error("{:#04x}: {}".format(status, error)) + + # Get the bound address/port + self.proxy_sockname = (socket.inet_ntoa(resp[4:]), + struct.unpack(">H", resp[2:4])[0]) + if remote_resolve: + self.proxy_peername = socket.inet_ntoa(addr_bytes), dest_port + else: + self.proxy_peername = dest_addr, dest_port + finally: + reader.close() + writer.close() + + def _negotiate_HTTP(self, dest_addr, dest_port): + """Negotiates a connection through an HTTP server. + + NOTE: This currently only supports HTTP CONNECT-style proxies.""" + proxy_type, addr, port, rdns, username, password = self.proxy + + # If we need to resolve locally, we do this now + addr = dest_addr if rdns else socket.gethostbyname(dest_addr) + + http_headers = [ + (b"CONNECT " + addr.encode("idna") + b":" + + str(dest_port).encode() + b" HTTP/1.1"), + b"Host: " + dest_addr.encode("idna") + ] + + if username and password: + http_headers.append(b"Proxy-Authorization: basic " + + b64encode(username + b":" + password)) + + http_headers.append(b"\r\n") + + self.sendall(b"\r\n".join(http_headers)) + + # We just need the first line to check if the connection was successful + fobj = self.makefile() + status_line = fobj.readline() + fobj.close() + + if not status_line: + raise GeneralProxyError("Connection closed unexpectedly") + + try: + proto, status_code, status_msg = status_line.split(" ", 2) + except ValueError: + raise GeneralProxyError("HTTP proxy server sent invalid response") + + if not proto.startswith("HTTP/"): + raise GeneralProxyError( + "Proxy server does not appear to be an HTTP proxy") + + try: + status_code = int(status_code) + except ValueError: + raise HTTPError( + "HTTP proxy server did not return a valid HTTP status") + + if status_code != 200: + error = "{}: {}".format(status_code, status_msg) + if status_code in (400, 403, 405): + # It's likely that the HTTP proxy server does not support the + # CONNECT tunneling method + error += ("\n[*] Note: The HTTP proxy server may not be" + " supported by PySocks (must be a CONNECT tunnel" + " proxy)") + raise HTTPError(error) + + self.proxy_sockname = (b"0.0.0.0", 0) + self.proxy_peername = addr, dest_port + + _proxy_negotiators = { + SOCKS4: _negotiate_SOCKS4, + SOCKS5: _negotiate_SOCKS5, + HTTP: _negotiate_HTTP + } + + @set_self_blocking + def connect(self, dest_pair, catch_errors=None): + """ + Connects to the specified destination through a proxy. + Uses the same API as socket's connect(). + To select the proxy server, use set_proxy(). + + dest_pair - 2-tuple of (IP/hostname, port). + """ + if len(dest_pair) != 2 or dest_pair[0].startswith("["): + # Probably IPv6, not supported -- raise an error, and hope + # Happy Eyeballs (RFC6555) makes sure at least the IPv4 + # connection works... + raise socket.error("PySocks doesn't support IPv6: %s" + % str(dest_pair)) + + dest_addr, dest_port = dest_pair + + if self.type == socket.SOCK_DGRAM: + if not self._proxyconn: + self.bind(("", 0)) + dest_addr = socket.gethostbyname(dest_addr) + + # If the host address is INADDR_ANY or similar, reset the peer + # address so that packets are received from any peer + if dest_addr == "0.0.0.0" and not dest_port: + self.proxy_peername = None + else: + self.proxy_peername = (dest_addr, dest_port) + return + + (proxy_type, proxy_addr, proxy_port, rdns, username, + password) = self.proxy + + # Do a minimal input check first + if (not isinstance(dest_pair, (list, tuple)) + or len(dest_pair) != 2 + or not dest_addr + or not isinstance(dest_port, int)): + # Inputs failed, raise an error + raise GeneralProxyError( + "Invalid destination-connection (host, port) pair") + + # We set the timeout here so that we don't hang in connection or during + # negotiation. + super(socksocket, self).settimeout(self._timeout) + + if proxy_type is None: + # Treat like regular socket object + self.proxy_peername = dest_pair + super(socksocket, self).settimeout(self._timeout) + super(socksocket, self).connect((dest_addr, dest_port)) + return + + proxy_addr = self._proxy_addr() + + try: + # Initial connection to proxy server. + super(socksocket, self).connect(proxy_addr) + + except socket.error as error: + # Error while connecting to proxy + self.close() + if not catch_errors: + proxy_addr, proxy_port = proxy_addr + proxy_server = "{}:{}".format(proxy_addr, proxy_port) + printable_type = PRINTABLE_PROXY_TYPES[proxy_type] + + msg = "Error connecting to {} proxy {}".format(printable_type, + proxy_server) + log.debug("%s due to: %s", msg, error) + raise ProxyConnectionError(msg, error) + else: + raise error + + else: + # Connected to proxy server, now negotiate + try: + # Calls negotiate_{SOCKS4, SOCKS5, HTTP} + negotiate = self._proxy_negotiators[proxy_type] + negotiate(self, dest_addr, dest_port) + except socket.error as error: + if not catch_errors: + # Wrap socket errors + self.close() + raise GeneralProxyError("Socket error", error) + else: + raise error + except ProxyError: + # Protocol error while negotiating with proxy + self.close() + raise + + @set_self_blocking + def connect_ex(self, dest_pair): + """ https://docs.python.org/3/library/socket.html#socket.socket.connect_ex + Like connect(address), but return an error indicator instead of raising an exception for errors returned by the C-level connect() call (other problems, such as "host not found" can still raise exceptions). + """ + try: + self.connect(dest_pair, catch_errors=True) + return 0 + except OSError as e: + # If the error is numeric (socket errors are numeric), then return number as + # connect_ex expects. Otherwise raise the error again (socket timeout for example) + if e.errno: + return e.errno + else: + raise + + def _proxy_addr(self): + """ + Return proxy address to connect to as tuple object + """ + (proxy_type, proxy_addr, proxy_port, rdns, username, + password) = self.proxy + proxy_port = proxy_port or DEFAULT_PORTS.get(proxy_type) + if not proxy_port: + raise GeneralProxyError("Invalid proxy type") + return proxy_addr, proxy_port diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/sockshandler.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/sockshandler.py new file mode 100644 index 0000000000000000000000000000000000000000..6a2ed81ceef43bae49f256824374bd8ae2576795 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pysocks-1.7.1-pyh09c184e_7/site-packages/sockshandler.py @@ -0,0 +1,111 @@ +#!/usr/bin/env python +""" +SocksiPy + urllib2 handler + +version: 0.3 +author: e<e@tr0ll.in> + +This module provides a Handler which you can use with urllib2 to allow it to tunnel your connection through a socks.sockssocket socket, with out monkey patching the original socket... +""" +import socket +import ssl + +try: + import urllib2 + import httplib +except ImportError: # Python 3 + import urllib.request as urllib2 + import http.client as httplib + +import socks # $ pip install PySocks + +def merge_dict(a, b): + d = a.copy() + d.update(b) + return d + +def is_ip(s): + try: + if ':' in s: + socket.inet_pton(socket.AF_INET6, s) + elif '.' in s: + socket.inet_aton(s) + else: + return False + except: + return False + else: + return True + +socks4_no_rdns = set() + +class SocksiPyConnection(httplib.HTTPConnection): + def __init__(self, proxytype, proxyaddr, proxyport=None, rdns=True, username=None, password=None, *args, **kwargs): + self.proxyargs = (proxytype, proxyaddr, proxyport, rdns, username, password) + httplib.HTTPConnection.__init__(self, *args, **kwargs) + + def connect(self): + (proxytype, proxyaddr, proxyport, rdns, username, password) = self.proxyargs + rdns = rdns and proxyaddr not in socks4_no_rdns + while True: + try: + sock = socks.create_connection( + (self.host, self.port), self.timeout, None, + proxytype, proxyaddr, proxyport, rdns, username, password, + ((socket.IPPROTO_TCP, socket.TCP_NODELAY, 1),)) + break + except socks.SOCKS4Error as e: + if rdns and "0x5b" in str(e) and not is_ip(self.host): + # Maybe a SOCKS4 server that doesn't support remote resolving + # Let's try again + rdns = False + socks4_no_rdns.add(proxyaddr) + else: + raise + self.sock = sock + +class SocksiPyConnectionS(httplib.HTTPSConnection): + def __init__(self, proxytype, proxyaddr, proxyport=None, rdns=True, username=None, password=None, *args, **kwargs): + self.proxyargs = (proxytype, proxyaddr, proxyport, rdns, username, password) + httplib.HTTPSConnection.__init__(self, *args, **kwargs) + + def connect(self): + SocksiPyConnection.connect(self) + self.sock = self._context.wrap_socket(self.sock, server_hostname=self.host) + if not self._context.check_hostname and self._check_hostname: + try: + ssl.match_hostname(self.sock.getpeercert(), self.host) + except Exception: + self.sock.shutdown(socket.SHUT_RDWR) + self.sock.close() + raise + +class SocksiPyHandler(urllib2.HTTPHandler, urllib2.HTTPSHandler): + def __init__(self, *args, **kwargs): + self.args = args + self.kw = kwargs + urllib2.HTTPHandler.__init__(self) + + def http_open(self, req): + def build(host, port=None, timeout=0, **kwargs): + kw = merge_dict(self.kw, kwargs) + conn = SocksiPyConnection(*self.args, host=host, port=port, timeout=timeout, **kw) + return conn + return self.do_open(build, req) + + def https_open(self, req): + def build(host, port=None, timeout=0, **kwargs): + kw = merge_dict(self.kw, kwargs) + conn = SocksiPyConnectionS(*self.args, host=host, port=port, timeout=timeout, **kw) + return conn + return self.do_open(build, req) + +if __name__ == "__main__": + import sys + try: + port = int(sys.argv[1]) + except (ValueError, IndexError): + port = 9050 + opener = urllib2.build_opener(SocksiPyHandler(socks.PROXY_TYPE_SOCKS5, "localhost", port)) + print("HTTP: " + opener.open("http://httpbin.org/ip").read().decode()) + print("HTTPS: " + opener.open("https://httpbin.org/ip").read().decode()) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/about.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/about.json new file mode 100644 index 0000000000000000000000000000000000000000..31ebc54bc8331b2a5269e3fe3579cbcd52268092 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/about.json @@ -0,0 +1,23 @@ +{ + "channels": [ + "https://conda.anaconda.org/conda-forge/" + ], + "description": "The pytest framework makes it easy to write small tests, yet scales to\nsupport complex functional testing for applications and libraries.", + "dev_url": "https://github.com/pytest-dev/pytest/", + "doc_url": "https://docs.pytest.org/en/latest/", + "extra": { + "flow_run_id": "azure_20260408.1.1", + "recipe-maintainers": [ + "flub", + "goanpeca", + "nicoddemus", + "ocefpaf", + "mingwandroid" + ], + "remote_url": "https://github.com/conda-forge/pytest-feedstock", + "sha": "2f4728238a1c1cc0aaba7d2513a1f1b8dbfc9657" + }, + "home": "https://docs.pytest.org/en/latest/", + "license": "MIT", + "summary": "Simple and powerful testing with Python." +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/hash_input.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/hash_input.json new file mode 100644 index 0000000000000000000000000000000000000000..230594052169c491a16901e8bd0ffb6f55ef111e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/hash_input.json @@ -0,0 +1 @@ +{"channel_sources": "conda-forge", "channel_targets": "conda-forge main", "target_platform": "noarch"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/index.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/index.json new file mode 100644 index 0000000000000000000000000000000000000000..ab4b819d937dbcc6f9119550815117dc62cf8534 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/index.json @@ -0,0 +1,24 @@ +{ + "build": "pyhc364b38_1", + "build_number": 1, + "constrains": [ + "pytest-faulthandler >=2" + ], + "depends": [ + "colorama >=0.4", + "pygments >=2.7.2", + "python >=3.10", + "iniconfig >=1.0.1", + "packaging >=22", + "pluggy >=1.5,<2", + "tomli >=1", + "exceptiongroup >=1", + "python" + ], + "license": "MIT", + "name": "pytest", + "noarch": "python", + "subdir": "noarch", + "timestamp": 1775644472530, + "version": "9.0.3" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..c3f1657fce94589bd1ec7cead810639047f3d359 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/licenses/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2004 Holger Krekel and others + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/link.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/link.json new file mode 100644 index 0000000000000000000000000000000000000000..2b588aaba9505920df725ffc11851a4c1df9ae44 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/link.json @@ -0,0 +1,10 @@ +{ + "noarch": { + "type": "python", + "entry_points": [ + "pytest = pytest:console_main", + "py.test = pytest:console_main" + ] + }, + "package_metadata_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/paths.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/paths.json new file mode 100644 index 0000000000000000000000000000000000000000..20644cc148cbbc95d2b8ea2d38aad170a1197928 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/paths.json @@ -0,0 +1,515 @@ +{ + "paths": [ + { + "_path": "site-packages/_pytest/__init__.py", + "path_type": "hardlink", + "sha256": "e087512619d6e571b62a568990ec67e7f4c2f56790e6d5c3485eed6dbe2f12ca", + "size_in_bytes": 391 + }, + { + "_path": "site-packages/_pytest/_argcomplete.py", + "path_type": "hardlink", + "sha256": "821d299daebaa782d56f60fc493e39ebc586c6f7489c64f8de6eac95886a36a5", + "size_in_bytes": 3776 + }, + { + "_path": "site-packages/_pytest/_code/__init__.py", + "path_type": "hardlink", + "sha256": "04a6e8c286100032a300999359d43c49240b6c106c874f9d663dd31a3b67eb23", + "size_in_bytes": 521 + }, + { + "_path": "site-packages/_pytest/_code/code.py", + "path_type": "hardlink", + "sha256": "2968ebe99705f2206bc8e1c0d5dc9183206b7c34a94cbc713af8cdd47dc49f1e", + "size_in_bytes": 56126 + }, + { + "_path": "site-packages/_pytest/_code/source.py", + "path_type": "hardlink", + "sha256": "56f37358761f4fde923b5dbc9bbb5f21d6a0677e72ba0e3a6d67e05c7ff9569f", + "size_in_bytes": 7772 + }, + { + "_path": "site-packages/_pytest/_io/__init__.py", + "path_type": "hardlink", + "sha256": "a642c5dbd54416be8396bdde3ad24bf2c7f8ed12c5b7525fe17d436413e56267", + "size_in_bytes": 190 + }, + { + "_path": "site-packages/_pytest/_io/pprint.py", + "path_type": "hardlink", + "sha256": "18b04a2fa7669d1afdd869d53243733242aac74f0ea7bb5d2527a1dc07b0a276", + "size_in_bytes": 19622 + }, + { + "_path": "site-packages/_pytest/_io/saferepr.py", + "path_type": "hardlink", + "sha256": "1e1c7917eef98b3d3785d93e58ef3a066cbd441b911ecb898fe614ce8cdfae0a", + "size_in_bytes": 4082 + }, + { + "_path": "site-packages/_pytest/_io/terminalwriter.py", + "path_type": "hardlink", + "sha256": "2b4a41d697c0beb281585011292a1b438c168b4a5d9a205a19bddafeffc00234", + "size_in_bytes": 8994 + }, + { + "_path": "site-packages/_pytest/_io/wcwidth.py", + "path_type": "hardlink", + "sha256": "714109ef8521c1e202c1b2af536aba9e865c3600f442504407d09f6a41986aa0", + "size_in_bytes": 1289 + }, + { + "_path": "site-packages/_pytest/_py/__init__.py", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/_pytest/_py/error.py", + "path_type": "hardlink", + "sha256": "90643b17cfdf67a615061031faef669134014f1d2a231c6754c0b40a088e77bd", + "size_in_bytes": 3475 + }, + { + "_path": "site-packages/_pytest/_py/path.py", + "path_type": "hardlink", + "sha256": "72a0a7d1a9b32a1a92aa25b55b3b782aabc52369dc281cc69f011152c5a90bfd", + "size_in_bytes": 49229 + }, + { + "_path": "site-packages/_pytest/_version.py", + "path_type": "hardlink", + "sha256": "936fbf99e6c3f48dd0aca88763398d96477085ce2fcbba41cd8cbe768e72394e", + "size_in_bytes": 704 + }, + { + "_path": "site-packages/_pytest/assertion/__init__.py", + "path_type": "hardlink", + "sha256": "3a39c99b88fa5478306232af5bc77e28579f8c474e48e345178cf5d28f6bede8", + "size_in_bytes": 7120 + }, + { + "_path": "site-packages/_pytest/assertion/rewrite.py", + "path_type": "hardlink", + "sha256": "376adab93672026552858ffaca009cbef553f082f2e4dee87ace75e7966d4b10", + "size_in_bytes": 48206 + }, + { + "_path": "site-packages/_pytest/assertion/truncate.py", + "path_type": "hardlink", + "sha256": "daf394de44b88546610c32f45dacf5a4cee85bfd74c0c7342776ff9446d2cd02", + "size_in_bytes": 5438 + }, + { + "_path": "site-packages/_pytest/assertion/util.py", + "path_type": "hardlink", + "sha256": "6102f243b9d81d0bb4ba2e52781eb6281d0a8eeb9e1721f0821193fe9d5d7e63", + "size_in_bytes": 20561 + }, + { + "_path": "site-packages/_pytest/cacheprovider.py", + "path_type": "hardlink", + "sha256": "40229d89ea544a4b8f344c790e58484076c0e35dccc0d5257782c8a55d7a156f", + "size_in_bytes": 23149 + }, + { + "_path": "site-packages/_pytest/capture.py", + "path_type": "hardlink", + "sha256": "92e96e989751747bbbce8a2c3abe257c747471ee8bb0eb616aef41cabc3cc55e", + "size_in_bytes": 36829 + }, + { + "_path": "site-packages/_pytest/compat.py", + "path_type": "hardlink", + "sha256": "a9c1dc647432100e933b70b4a861203b46ff63136edb7a24d264d9d2c6a1ea49", + "size_in_bytes": 10254 + }, + { + "_path": "site-packages/_pytest/config/__init__.py", + "path_type": "hardlink", + "sha256": "2ea44f1539ed6b72eb61402d4633b92e9fef99895c41ac6347860690516e46cf", + "size_in_bytes": 79300 + }, + { + "_path": "site-packages/_pytest/config/argparsing.py", + "path_type": "hardlink", + "sha256": "7438f0b58f6785343d435e196dd53e106c2840a645b95641d4fb34c1c960e7fa", + "size_in_bytes": 20439 + }, + { + "_path": "site-packages/_pytest/config/compat.py", + "path_type": "hardlink", + "sha256": "7630edfd74cfc170c88279e8a6d8b6655aeab70ccee6115688c86053976020ce", + "size_in_bytes": 2947 + }, + { + "_path": "site-packages/_pytest/config/exceptions.py", + "path_type": "hardlink", + "sha256": "e959bdcb3c143b12469b5ed93066f0ebdbff8b4ee64f52a607010d336b1c2a19", + "size_in_bytes": 315 + }, + { + "_path": "site-packages/_pytest/config/findpaths.py", + "path_type": "hardlink", + "sha256": "d22abddac47a73a81504569cc0c356fa0145ce57ef58d3b8e9d5fdc77f609c88", + "size_in_bytes": 12878 + }, + { + "_path": "site-packages/_pytest/debugging.py", + "path_type": "hardlink", + "sha256": "26457b39bef0439dd3146910d136bdea300c606b9b81d5e212cdfd4fb14fcc74", + "size_in_bytes": 13947 + }, + { + "_path": "site-packages/_pytest/deprecated.py", + "path_type": "hardlink", + "sha256": "122928623a9d94b4d981b04d4e615d3ea88fe43759a730322b045b3b6840d151", + "size_in_bytes": 3611 + }, + { + "_path": "site-packages/_pytest/doctest.py", + "path_type": "hardlink", + "sha256": "1a08dd58ec47f9f57d790a1643ba6e29e8dc15d0351cfb46f98eea6e9fb92fc7", + "size_in_bytes": 25478 + }, + { + "_path": "site-packages/_pytest/faulthandler.py", + "path_type": "hardlink", + "sha256": "d5cec3a51b4fd3f0b7ce91544b0d41391a401bc1ac883b49f730ae59d1222dcd", + "size_in_bytes": 4250 + }, + { + "_path": "site-packages/_pytest/fixtures.py", + "path_type": "hardlink", + "sha256": "eff80aa15502a5fa38b022f2dd3d3ba760efff16b9c761e7283299bbcf380de6", + "size_in_bytes": 78681 + }, + { + "_path": "site-packages/_pytest/freeze_support.py", + "path_type": "hardlink", + "sha256": "5fde08c62a6a79b780fc7833261f1d6e3a869ebb44405b8c202e612bb486597c", + "size_in_bytes": 1300 + }, + { + "_path": "site-packages/_pytest/helpconfig.py", + "path_type": "hardlink", + "sha256": "ea2cb6d6850351119e759a41dde992cda142c5e353fc44529122192c8c4c26f5", + "size_in_bytes": 10019 + }, + { + "_path": "site-packages/_pytest/hookspec.py", + "path_type": "hardlink", + "sha256": "10492386fded5ac217ccf4be2f2bd7b05c7999aaf700c9b83ce04278f20708c4", + "size_in_bytes": 43019 + }, + { + "_path": "site-packages/_pytest/junitxml.py", + "path_type": "hardlink", + "sha256": "d71198950cf33bd1c7dc782167986ee130427fc57e221046e6455dc7a5b63d5a", + "size_in_bytes": 25522 + }, + { + "_path": "site-packages/_pytest/legacypath.py", + "path_type": "hardlink", + "sha256": "fe5eaff1a90d31f4dce53023bdb73a33efedd79ee9f5013afb5d7c58cd0346df", + "size_in_bytes": 16588 + }, + { + "_path": "site-packages/_pytest/logging.py", + "path_type": "hardlink", + "sha256": "4d9ebb2503ffdd896dd29d750f627af0bfe8b3d825b2e82032f79cd07963b5bf", + "size_in_bytes": 35234 + }, + { + "_path": "site-packages/_pytest/main.py", + "path_type": "hardlink", + "sha256": "7ca2b20cc41fbfc2761bcb231eecb26967d553651035c40000f44d70e174b693", + "size_in_bytes": 42435 + }, + { + "_path": "site-packages/_pytest/mark/__init__.py", + "path_type": "hardlink", + "sha256": "dfc1fbc21da4dd264c64d6700213db1c1c693f161b9fec33995b465188a0bf37", + "size_in_bytes": 9870 + }, + { + "_path": "site-packages/_pytest/mark/expression.py", + "path_type": "hardlink", + "sha256": "df4ad2eb9c8c09d7e7d545a208fff88a67f349e584b4ffeacf8ff6255dd8d7e5", + "size_in_bytes": 11244 + }, + { + "_path": "site-packages/_pytest/mark/structures.py", + "path_type": "hardlink", + "sha256": "92b950eec1145149858f2df28e85c0d017224e052992532d2ea4e528eb04c1a7", + "size_in_bytes": 23073 + }, + { + "_path": "site-packages/_pytest/monkeypatch.py", + "path_type": "hardlink", + "sha256": "597dffe9ccd42e1bdcdf0485fb437c55eb1bbfdc0637777096261c0ef4fc11fb", + "size_in_bytes": 15500 + }, + { + "_path": "site-packages/_pytest/nodes.py", + "path_type": "hardlink", + "sha256": "693b0385b2c45646767200bc517416e776c10c3e58ee5ed937007491be4d868e", + "size_in_bytes": 26540 + }, + { + "_path": "site-packages/_pytest/outcomes.py", + "path_type": "hardlink", + "sha256": "a9b8074421110d12bc5bc6407da9d07f80e9e3f5bbbcda1cdafbf7a66dc7b4aa", + "size_in_bytes": 10108 + }, + { + "_path": "site-packages/_pytest/pastebin.py", + "path_type": "hardlink", + "sha256": "a7ddb326d48dcfdfb10c4173a90df37a662081745a0e7c43e97e08ca2b5ebdb0", + "size_in_bytes": 4155 + }, + { + "_path": "site-packages/_pytest/pathlib.py", + "path_type": "hardlink", + "sha256": "c483986bc125cb2a43d814ee4b6ffc6e1e8ec83e038cf7c13ae9641714396f54", + "size_in_bytes": 37879 + }, + { + "_path": "site-packages/_pytest/py.typed", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/_pytest/pytester.py", + "path_type": "hardlink", + "sha256": "c746a6f5b5c7cf740f0533d73f295c6267cff2c1a1562e510bf28f8fa8371e7e", + "size_in_bytes": 62389 + }, + { + "_path": "site-packages/_pytest/pytester_assertions.py", + "path_type": "hardlink", + "sha256": "c57fc76c53c1f91cff34d0edb53637f5fb7bff064bbcf81040155ebd209e5660", + "size_in_bytes": 2253 + }, + { + "_path": "site-packages/_pytest/python.py", + "path_type": "hardlink", + "sha256": "fd28318a23e7afb8cf81794ab3cb028ddb0148df80a14666cc8bc9320324561e", + "size_in_bytes": 68754 + }, + { + "_path": "site-packages/_pytest/python_api.py", + "path_type": "hardlink", + "sha256": "2f34e38783f3db967bc085450ddc5343aba6a98482e41ffc1ad2b1bb80af91ac", + "size_in_bytes": 31707 + }, + { + "_path": "site-packages/_pytest/raises.py", + "path_type": "hardlink", + "sha256": "f3a57e8686398586daebd9e9cab1fbaf891035bf108e8b986fc4b27462e68d57", + "size_in_bytes": 60082 + }, + { + "_path": "site-packages/_pytest/recwarn.py", + "path_type": "hardlink", + "sha256": "e1aeacf165aa9fec82087caa82707f7df73fce4c170463c2baf0bed372fae5ce", + "size_in_bytes": 13386 + }, + { + "_path": "site-packages/_pytest/reports.py", + "path_type": "hardlink", + "sha256": "2e9272a67cde38b925eba24a288b2ef77f741c0daa22da6fbce53ee6e58fa41d", + "size_in_bytes": 23230 + }, + { + "_path": "site-packages/_pytest/runner.py", + "path_type": "hardlink", + "sha256": "8d784b2b3e23b05f4c4edd3f5263eb11964e86b6e16d2c814c5fcb2125dc4ea4", + "size_in_bytes": 19785 + }, + { + "_path": "site-packages/_pytest/scope.py", + "path_type": "hardlink", + "sha256": "a41ee3b228acb61d7a3c115a715d58c5ddcf8f7600c767669529866c6e26c3a0", + "size_in_bytes": 2738 + }, + { + "_path": "site-packages/_pytest/setuponly.py", + "path_type": "hardlink", + "sha256": "06c46b0b81110d5af8dbed86fcbd00c61354e175706ccb32e52d253af2abf300", + "size_in_bytes": 3167 + }, + { + "_path": "site-packages/_pytest/setupplan.py", + "path_type": "hardlink", + "sha256": "97ec9c14dc4364fc98e76c21e1fef26aa87367b496d628d22a740b9aacc36560", + "size_in_bytes": 1184 + }, + { + "_path": "site-packages/_pytest/skipping.py", + "path_type": "hardlink", + "sha256": "5824731d5a311780f418eac9a094e7cf1fd63a82d3b0cd5e9e5498cc6ecd127c", + "size_in_bytes": 10810 + }, + { + "_path": "site-packages/_pytest/stash.py", + "path_type": "hardlink", + "sha256": "e69137903c78abce794d6f5a56f61376b9242a530353afb1897e25b8aa491202", + "size_in_bytes": 3090 + }, + { + "_path": "site-packages/_pytest/stepwise.py", + "path_type": "hardlink", + "sha256": "903f350eb9e19dc94a06631f6aec1099b78c6d852fbb0d3bc395a73649887444", + "size_in_bytes": 7689 + }, + { + "_path": "site-packages/_pytest/subtests.py", + "path_type": "hardlink", + "sha256": "f8eccea44d23f7cbc358c02c23ec4c27415c61bea29cbaba60f1ffd2d132538e", + "size_in_bytes": 13241 + }, + { + "_path": "site-packages/_pytest/terminal.py", + "path_type": "hardlink", + "sha256": "e2fe406f930e795d09026746e8209a9a7142ac704fc0a0200af9e4f74d2104d0", + "size_in_bytes": 64444 + }, + { + "_path": "site-packages/_pytest/terminalprogress.py", + "path_type": "hardlink", + "sha256": "fc83b7bd1195013cf746491a72a200682502e3e46ada94c400d50063ae9d1304", + "size_in_bytes": 1153 + }, + { + "_path": "site-packages/_pytest/threadexception.py", + "path_type": "hardlink", + "sha256": "85371ca73654aeb4240d1395140a87817c00538f3571ae0cab8080e1807b9b2e", + "size_in_bytes": 4953 + }, + { + "_path": "site-packages/_pytest/timing.py", + "path_type": "hardlink", + "sha256": "94f70a1da33578a1efd7fd9981468f2bd877161b6a1af64062e731fcb49d670d", + "size_in_bytes": 3108 + }, + { + "_path": "site-packages/_pytest/tmpdir.py", + "path_type": "hardlink", + "sha256": "b25a80db25476cfd9d58e7c80e8962ac9e39ca628369a1db789a9c81a2261dd9", + "size_in_bytes": 12526 + }, + { + "_path": "site-packages/_pytest/tracemalloc.py", + "path_type": "hardlink", + "sha256": "942501fd85006fa475beaabf6fe2d26125f2f9389d6e7da6eed7f3996014ae39", + "size_in_bytes": 778 + }, + { + "_path": "site-packages/_pytest/unittest.py", + "path_type": "hardlink", + "sha256": "945e76cdc3ea6fddf5168582582ed88bbf240160010d192a6fad156692351e5e", + "size_in_bytes": 24485 + }, + { + "_path": "site-packages/_pytest/unraisableexception.py", + "path_type": "hardlink", + "sha256": "74d681a411e4381e293884a868c75abb6a23ac6a1cfe2e2ec7be835572cb4fec", + "size_in_bytes": 5179 + }, + { + "_path": "site-packages/_pytest/warning_types.py", + "path_type": "hardlink", + "sha256": "566ea71b4b0f502c82dcc06a1c7ae86570e5914f95be2d104c941a68caf21890", + "size_in_bytes": 4398 + }, + { + "_path": "site-packages/_pytest/warnings.py", + "path_type": "hardlink", + "sha256": "c89303afbbd27a28fe9f24ee95d13bc0bdb964bfcbba640663a3c96695e243e2", + "size_in_bytes": 5194 + }, + { + "_path": "site-packages/py.py", + "path_type": "hardlink", + "sha256": "b71675b5d9845ba0814e9e88767f88dac3b3cc0d3128da028bd45edbb523e871", + "size_in_bytes": 329 + }, + { + "_path": "site-packages/pytest/__init__.py", + "path_type": "hardlink", + "sha256": "7be7a1e2218dc59a19d1ad131e4abe21172a295087efc72898938248782e8766", + "size_in_bytes": 5582 + }, + { + "_path": "site-packages/pytest/__main__.py", + "path_type": "hardlink", + "sha256": "a150eb186a3b3744cdcb35e7b546e57204ca6e11c65ad8af717e530bbb4470aa", + "size_in_bytes": 154 + }, + { + "_path": "site-packages/pytest/py.typed", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pytest-9.0.3.dist-info/INSTALLER", + "path_type": "hardlink", + "sha256": "bc33022edcb7639ff53355b4e91dade50a0bbf0299efeb6171d1ec0ba5029cfc", + "size_in_bytes": 6 + }, + { + "_path": "site-packages/pytest-9.0.3.dist-info/METADATA", + "path_type": "hardlink", + "sha256": "c3966f28791686477bae35e518736d4cbea5b626d3a79011215854e2bc670207", + "size_in_bytes": 7556 + }, + { + "_path": "site-packages/pytest-9.0.3.dist-info/RECORD", + "path_type": "hardlink", + "sha256": "494a5965d7eae15990cac1d995432e0c1a15ba5e739e9ac5dba801eaa48a948a", + "size_in_bytes": 10656 + }, + { + "_path": "site-packages/pytest-9.0.3.dist-info/REQUESTED", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pytest-9.0.3.dist-info/WHEEL", + "path_type": "hardlink", + "sha256": "69e6228a0d35958183cc1812f07c565ce837b95eb51bd8a33acba9fa4f68d6c9", + "size_in_bytes": 91 + }, + { + "_path": "site-packages/pytest-9.0.3.dist-info/direct_url.json", + "path_type": "hardlink", + "sha256": "0e7fe97a4201c38c659a35ac28955d1b3baf51183405054e4bc0572102263b27", + "size_in_bytes": 117 + }, + { + "_path": "site-packages/pytest-9.0.3.dist-info/entry_points.txt", + "path_type": "hardlink", + "sha256": "f083eb1cf1f72cd650eefe6d34439c35365893f4a178d83ae23b1333d7aba8be", + "size_in_bytes": 77 + }, + { + "_path": "site-packages/pytest-9.0.3.dist-info/licenses/LICENSE", + "path_type": "hardlink", + "sha256": "ca836a5f9ecca3b2f350230faa20a48fb8b145653b5568d784862df864706b9b", + "size_in_bytes": 1091 + }, + { + "_path": "site-packages/pytest-9.0.3.dist-info/top_level.txt", + "path_type": "hardlink", + "sha256": "cb2863be65c7efe24e6a84087663501cfba8042c4ec974b78c8b61b3fe82f00e", + "size_in_bytes": 18 + } + ], + "paths_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/recipe/recipe-scripts-license.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/recipe/recipe-scripts-license.txt new file mode 100644 index 0000000000000000000000000000000000000000..c5aa738f1bd246658c9da9e1bbe2502df6d0e173 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/recipe/recipe-scripts-license.txt @@ -0,0 +1,26 @@ +BSD-3-Clause license +Copyright (c) 2015-2026, conda-forge contributors + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + 3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/recipe/recipe.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/recipe/recipe.yaml new file mode 100644 index 0000000000000000000000000000000000000000..87b1a98361848054bb6ae525170906da038b069c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/recipe/recipe.yaml @@ -0,0 +1,71 @@ +schema_version: 1 + +context: + version: 9.0.3 + python_min: '3.10' + +package: + name: pytest + version: ${{ version }} + +source: + url: https://pypi.org/packages/source/p/pytest/pytest-${{ version }}.tar.gz + sha256: b86ada508af81d19edeb213c681b1d48246c1a91d304c6c81a427674c17eb91c + +build: + number: 1 + noarch: python + script: ${{ PYTHON }} -m pip install . -vv + python: + entry_points: + - pytest = pytest:console_main + - py.test = pytest:console_main + +requirements: + host: + - pip + - python ${{ python_min }}.* + - setuptools >=77 + - setuptools_scm >=6.2.3 + run: + - colorama >=0.4 + - pygments >=2.7.2 + - python >=${{ python_min }} + - iniconfig >=1.0.1 + - packaging >=22 + - pluggy >=1.5,<2 + - tomli >=1 + - exceptiongroup >=1 + run_constraints: + - pytest-faulthandler >=2 + +tests: + - python: + imports: + - pytest + python_version: + - ${{ python_min }}.* + - requirements: + run: + - python ${{ python_min }}.* + script: + - pytest -h + +about: + license: MIT + license_file: LICENSE + summary: Simple and powerful testing with Python. + description: | + The pytest framework makes it easy to write small tests, yet scales to + support complex functional testing for applications and libraries. + homepage: https://docs.pytest.org/en/latest/ + repository: https://github.com/pytest-dev/pytest/ + documentation: https://docs.pytest.org/en/latest/ + +extra: + recipe-maintainers: + - flub + - goanpeca + - nicoddemus + - ocefpaf + - mingwandroid diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/recipe/rendered_recipe.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/recipe/rendered_recipe.yaml new file mode 100644 index 0000000000000000000000000000000000000000..1092d282648d7f9e588e90b246849b757a9c267f --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/recipe/rendered_recipe.yaml @@ -0,0 +1,849 @@ +recipe: + schema_version: 1 + context: + version: 9.0.3 + python_min: '3.10' + package: + name: pytest + version: 9.0.3 + source: + - url: https://pypi.org/packages/source/p/pytest/pytest-9.0.3.tar.gz + sha256: b86ada508af81d19edeb213c681b1d48246c1a91d304c6c81a427674c17eb91c + build: + number: 1 + string: pyhc364b38_1 + script: ${{ PYTHON }} -m pip install . -vv + noarch: python + python: + entry_points: + - pytest = pytest:console_main + - py.test = pytest:console_main + requirements: + host: + - pip + - python 3.10.* + - setuptools >=77 + - setuptools_scm >=6.2.3 + run: + - colorama >=0.4 + - pygments >=2.7.2 + - python >=3.10 + - iniconfig >=1.0.1 + - packaging >=22 + - pluggy >=1.5,<2 + - tomli >=1 + - exceptiongroup >=1 + run_constraints: + - pytest-faulthandler >=2 + tests: + - python: + imports: + - pytest + python_version: + - 3.10.* + - script: pytest -h + requirements: + run: + - python 3.10.* + about: + homepage: https://docs.pytest.org/en/latest/ + repository: https://github.com/pytest-dev/pytest/ + documentation: https://docs.pytest.org/en/latest/ + license: MIT + license_file: + - LICENSE + summary: Simple and powerful testing with Python. + description: |- + The pytest framework makes it easy to write small tests, yet scales to + support complex functional testing for applications and libraries. + extra: + recipe-maintainers: + - flub + - goanpeca + - nicoddemus + - ocefpaf + - mingwandroid +build_configuration: + target_platform: noarch + host_platform: + platform: linux-64 + virtual_packages: + - __unix=0=0 + - __linux=6.17.0=0 + - __glibc=2.34=0 + - __archspec=1=zen2 + build_platform: + platform: linux-64 + virtual_packages: + - __unix=0=0 + - __linux=6.17.0=0 + - __glibc=2.34=0 + - __archspec=1=zen2 + variant: + channel_sources: conda-forge + channel_targets: conda-forge main + target_platform: noarch + hash: + hash: c364b38 + prefix: py + directories: + host_prefix: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_pytest_1775644472/host_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placeho + build_prefix: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_pytest_1775644472/build_env + work_dir: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_pytest_1775644472/work + build_dir: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_pytest_1775644472 + channels: + - https://conda.anaconda.org/conda-forge + channel_priority: strict + solve_strategy: highest + timestamp: 2026-04-08T10:34:32.530657143Z + subpackages: + pytest: + name: pytest + version: 9.0.3 + build_string: pyhc364b38_1 + packaging_settings: + archive_type: conda + compression_level: 15 +finalized_dependencies: + build: null + host: + specs: + - source: pip + - source: python 3.10.* + - source: setuptools >=77 + - source: setuptools_scm >=6.2.3 + resolved: + - build: pyh8b19718_0 + build_number: 0 + depends: + - python >=3.10,<3.13.0a0 + - setuptools + - wheel + license: MIT + license_family: MIT + md5: 67bdec43082fd8a9cffb9484420b39a2 + name: pip + noarch: python + run_exports: {} + sha256: 8e1497814a9997654ed7990a79c054ea5a42545679407acbc6f7e809c73c9120 + size: 1181790 + subdir: noarch + timestamp: 1770270305795 + version: 26.0.1 + fn: pip-26.0.1-pyh8b19718_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/pip-26.0.1-pyh8b19718_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h3c07f61_0_cpython + build_number: 0 + constrains: + - python_abi 3.10.* *_cp310 + depends: + - __glibc >=2.17,<3.0.a0 + - bzip2 >=1.0.8,<2.0a0 + - ld_impl_linux-64 >=2.36.1 + - libexpat >=2.7.4,<3.0a0 + - libffi >=3.4,<4.0a0 + - libgcc >=14 + - liblzma >=5.8.2,<6.0a0 + - libnsl >=2.0.1,<2.1.0a0 + - libsqlite >=3.51.2,<4.0a0 + - libuuid >=2.41.3,<3.0a0 + - libxcrypt >=4.4.36 + - libzlib >=1.3.1,<2.0a0 + - ncurses >=6.5,<7.0a0 + - openssl >=3.5.5,<4.0a0 + - readline >=8.3,<9.0a0 + - tk >=8.6.13,<8.7.0a0 + - tzdata + license: Python-2.0 + md5: 5d4e2b00d99feacd026859b7fa239dc0 + name: python + run_exports: + weak: + - python_abi 3.10.* *_cp310 + noarch: + - python + sha256: 8ff2ce308faf2588b69c65b120293f59a8f2577b772b34df4e817d220b09e081 + size: 25455342 + subdir: linux-64 + timestamp: 1772729810280 + version: 3.10.20 + fn: python-3.10.20-h3c07f61_0_cpython.conda + url: https://conda.anaconda.org/conda-forge/linux-64/python-3.10.20-h3c07f61_0_cpython.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h853b02a_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + - ncurses >=6.5,<7.0a0 + license: GPL-3.0-only + license_family: GPL + md5: d7d95fc8287ea7bf33e0e7116d2b95ec + name: readline + run_exports: + weak: + - readline >=8.3,<9.0a0 + sha256: 12ffde5a6f958e285aa22c191ca01bbd3d6e710aa852e00618fa6ddc59149002 + size: 345073 + subdir: linux-64 + timestamp: 1765813471974 + version: '8.3' + fn: readline-8.3-h853b02a_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/readline-8.3-h853b02a_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb03c661_0 + build_number: 0 + constrains: + - xz 5.8.2.* + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: 0BSD + md5: c7c83eecbb72d88b940c249af56c8b17 + name: liblzma + run_exports: + weak: + - liblzma >=5.8.2,<6.0a0 + sha256: 755c55ebab181d678c12e49cced893598f2bab22d582fbbf4d8b83c18be207eb + size: 113207 + subdir: linux-64 + timestamp: 1768752626120 + version: 5.8.2 + fn: liblzma-5.8.2-hb03c661_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/liblzma-5.8.2-hb03c661_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyh332efcf_0 + build_number: 0 + depends: + - python >=3.10 + license: MIT + license_family: MIT + md5: 8e194e7b992f99a5015edbd4ebd38efd + name: setuptools + noarch: python + run_exports: {} + sha256: 82088a6e4daa33329a30bc26dc19a98c7c1d3f05c0f73ce9845d4eab4924e9e1 + size: 639697 + subdir: noarch + timestamp: 1773074868565 + version: 82.0.1 + fn: setuptools-82.0.1-pyh332efcf_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hd8ed1ab_0 + build_number: 0 + depends: + - setuptools-scm >=9.2.2,<9.2.3.0a0 + license: MIT + license_family: MIT + md5: 7537abc2590073ffde5545c648ad6974 + name: setuptools_scm + noarch: generic + run_exports: {} + sha256: 60eec92bd931bbcba700b9a70b1446dccbf62d3298e408d3a28e09b8ecd96d98 + size: 6653 + subdir: noarch + timestamp: 1760965126461 + version: 9.2.2 + fn: setuptools_scm-9.2.2-hd8ed1ab_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/setuptools_scm-9.2.2-hd8ed1ab_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_0 + build_number: 0 + depends: + - importlib-metadata + - packaging >=20.0 + - python >=3.10 + - setuptools >=45 + - tomli >=1.0.0 + - typing-extensions + license: MIT + license_family: MIT + md5: e2e4d7094d0580ccd62e2a41947444f3 + name: setuptools-scm + noarch: python + run_exports: {} + sha256: 2161ac35fc22770b248bab0be2cc3b5bd765f528a9e60e7f3be784fd8d0d605a + size: 52539 + subdir: noarch + timestamp: 1760965125925 + version: 9.2.2 + fn: setuptools-scm-9.2.2-pyhd8ed1ab_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/setuptools-scm-9.2.2-pyhd8ed1ab_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_0 + build_number: 0 + depends: + - packaging >=24.0 + - python >=3.10 + license: MIT + license_family: MIT + md5: bdbd7385b4a67025ac2dba4ef8cb6a8f + name: wheel + noarch: python + run_exports: {} + sha256: d6cf2f0ebd5e09120c28ecba450556ce553752652d91795442f0e70f837126ae + size: 31858 + subdir: noarch + timestamp: 1769139207397 + version: 0.46.3 + fn: wheel-0.46.3-pyhd8ed1ab_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/wheel-0.46.3-pyhd8ed1ab_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hda65f42_9 + build_number: 9 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: bzip2-1.0.6 + license_family: BSD + md5: d2ffd7602c02f2b316fd921d39876885 + name: bzip2 + run_exports: + weak: + - bzip2 >=1.0.8,<2.0a0 + sha256: 0b75d45f0bba3e95dc693336fa51f40ea28c980131fec438afb7ce6118ed05f6 + size: 260182 + subdir: linux-64 + timestamp: 1771350215188 + version: 1.0.8 + fn: bzip2-1.0.8-hda65f42_9.conda + url: https://conda.anaconda.org/conda-forge/linux-64/bzip2-1.0.8-hda65f42_9.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: default_hbd61a6d_102 + build_number: 102 + constrains: + - binutils_impl_linux-64 2.45.1 + depends: + - __glibc >=2.17,<3.0.a0 + - zstd >=1.5.7,<1.6.0a0 + license: GPL-3.0-only + license_family: GPL + md5: 18335a698559cdbcd86150a48bf54ba6 + name: ld_impl_linux-64 + run_exports: {} + sha256: 3d584956604909ff5df353767f3a2a2f60e07d070b328d109f30ac40cd62df6c + size: 728002 + subdir: linux-64 + timestamp: 1774197446916 + version: 2.45.1 + fn: ld_impl_linux-64-2.45.1-default_hbd61a6d_102.conda + url: https://conda.anaconda.org/conda-forge/linux-64/ld_impl_linux-64-2.45.1-default_hbd61a6d_102.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hecca717_0 + build_number: 0 + constrains: + - expat 2.7.5.* + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: MIT + license_family: MIT + md5: 49f570f3bc4c874a06ea69b7225753af + name: libexpat + run_exports: {} + sha256: e8c2b57f6aacabdf2f1b0924bd4831ce5071ba080baa4a9e8c0d720588b6794c + size: 76624 + subdir: linux-64 + timestamp: 1774719175983 + version: 2.7.5 + fn: libexpat-2.7.5-hecca717_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libexpat-2.7.5-hecca717_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h3435931_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: MIT + license_family: MIT + md5: a360c33a5abe61c07959e449fa1453eb + name: libffi + run_exports: + weak: + - libffi >=3.5.2,<3.6.0a0 + sha256: 31f19b6a88ce40ebc0d5a992c131f57d919f73c0b92cd1617a5bec83f6e961e6 + size: 58592 + subdir: linux-64 + timestamp: 1769456073053 + version: 3.5.2 + fn: libffi-3.5.2-h3435931_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libffi-3.5.2-h3435931_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: he0feb66_18 + build_number: 18 + constrains: + - libgcc-ng ==15.2.0=*_18 + - libgomp 15.2.0 he0feb66_18 + depends: + - __glibc >=2.17,<3.0.a0 + - _openmp_mutex >=4.5 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + md5: 0aa00f03f9e39fb9876085dee11a85d4 + name: libgcc + run_exports: {} + sha256: faf7d2017b4d718951e3a59d081eb09759152f93038479b768e3d612688f83f5 + size: 1041788 + subdir: linux-64 + timestamp: 1771378212382 + version: 15.2.0 + fn: libgcc-15.2.0-he0feb66_18.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgcc-15.2.0-he0feb66_18.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb9d3cd8_1 + build_number: 1 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: LGPL-2.1-only + license_family: GPL + md5: d864d34357c3b65a4b731f78c0801dc4 + name: libnsl + run_exports: + weak: + - libnsl >=2.0.1,<2.1.0a0 + sha256: 927fe72b054277cde6cb82597d0fcf6baf127dcbce2e0a9d8925a68f1265eef5 + size: 33731 + subdir: linux-64 + timestamp: 1750274110928 + version: 2.0.1 + fn: libnsl-2.0.1-hb9d3cd8_1.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libnsl-2.0.1-hb9d3cd8_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hf4e2dac_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - icu >=78.2,<79.0a0 + - libgcc >=14 + - libzlib >=1.3.1,<2.0a0 + license: blessing + md5: fd893f6a3002a635b5e50ceb9dd2c0f4 + name: libsqlite + run_exports: + weak: + - libsqlite >=3.52.0,<4.0a0 + sha256: d716847b7deca293d2e49ed1c8ab9e4b9e04b9d780aea49a97c26925b28a7993 + size: 951405 + subdir: linux-64 + timestamp: 1772818874251 + version: 3.52.0 + fn: libsqlite-3.52.0-hf4e2dac_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libsqlite-3.52.0-hf4e2dac_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h5347b49_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: BSD-3-Clause + license_family: BSD + md5: 38ffe67b78c9d4de527be8315e5ada2c + name: libuuid + run_exports: + weak: + - libuuid >=2.42,<3.0a0 + sha256: bc1b08c92626c91500fd9f26f2c797f3eb153b627d53e9c13cd167f1e12b2829 + size: 40297 + subdir: linux-64 + timestamp: 1775052476770 + version: '2.42' + fn: libuuid-2.42-h5347b49_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libuuid-2.42-h5347b49_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hd590300_1 + build_number: 1 + depends: + - libgcc-ng >=12 + license: LGPL-2.1-or-later + md5: 5aa797f8787fe7a17d1b0821485b5adc + name: libxcrypt + run_exports: + weak: + - libxcrypt >=4.4.36 + sha256: 6ae68e0b86423ef188196fff6207ed0c8195dd84273cb5623b85aa08033a410c + size: 100393 + subdir: linux-64 + timestamp: 1702724383534 + version: 4.4.36 + fn: libxcrypt-4.4.36-hd590300_1.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libxcrypt-4.4.36-hd590300_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h69a702a_18 + build_number: 18 + depends: + - libgcc 15.2.0 he0feb66_18 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + md5: d5e96b1ed75ca01906b3d2469b4ce493 + name: libgcc-ng + run_exports: + strong: + - libgcc + sha256: e318a711400f536c81123e753d4c797a821021fb38970cebfb3f454126016893 + size: 27526 + subdir: linux-64 + timestamp: 1771378224552 + version: 15.2.0 + fn: libgcc-ng-15.2.0-h69a702a_18.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgcc-ng-15.2.0-h69a702a_18.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h25fd6f3_2 + build_number: 2 + constrains: + - zlib 1.3.2 *_2 + depends: + - __glibc >=2.17,<3.0.a0 + license: Zlib + license_family: Other + md5: d87ff7921124eccd67248aa483c23fec + name: libzlib + run_exports: + weak: + - libzlib >=1.3.2,<2.0a0 + sha256: 55044c403570f0dc26e6364de4dc5368e5f3fc7ff103e867c487e2b5ab2bcda9 + size: 63629 + subdir: linux-64 + timestamp: 1774072609062 + version: 1.3.2 + fn: libzlib-1.3.2-h25fd6f3_2.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libzlib-1.3.2-h25fd6f3_2.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h2d0b736_3 + build_number: 3 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: X11 AND BSD-3-Clause + md5: 47e340acb35de30501a76c7c799c41d7 + name: ncurses + run_exports: + weak: + - ncurses >=6.5,<7.0a0 + sha256: 3fde293232fa3fca98635e1167de6b7c7fda83caf24b9d6c91ec9eefb4f4d586 + size: 891641 + subdir: linux-64 + timestamp: 1738195959188 + version: '6.5' + fn: ncurses-6.5-h2d0b736_3.conda + url: https://conda.anaconda.org/conda-forge/linux-64/ncurses-6.5-h2d0b736_3.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h35e630c_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - ca-certificates + - libgcc >=14 + license: Apache-2.0 + license_family: Apache + md5: da1b85b6a87e141f5140bb9924cecab0 + name: openssl + run_exports: + weak: + - openssl >=3.6.2,<4.0a0 + sha256: c0ef482280e38c71a08ad6d71448194b719630345b0c9c60744a2010e8a8e0cb + size: 3167099 + subdir: linux-64 + timestamp: 1775587756857 + version: 3.6.2 + fn: openssl-3.6.2-h35e630c_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/openssl-3.6.2-h35e630c_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: noxft_h366c992_103 + build_number: 103 + constrains: + - xorg-libx11 >=1.8.12,<2.0a0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + - libzlib >=1.3.1,<2.0a0 + license: TCL + license_family: BSD + md5: cffd3bdd58090148f4cfcd831f4b26ab + name: tk + run_exports: + weak: + - tk >=8.6.13,<8.7.0a0 + sha256: cafeec44494f842ffeca27e9c8b0c27ed714f93ac77ddadc6aaf726b5554ebac + size: 3301196 + subdir: linux-64 + timestamp: 1769460227866 + version: 8.6.13 + fn: tk-8.6.13-noxft_h366c992_103.conda + url: https://conda.anaconda.org/conda-forge/linux-64/tk-8.6.13-noxft_h366c992_103.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hc9c84f9_1 + build_number: 1 + depends: [] + license: LicenseRef-Public-Domain + md5: ad659d0a2b3e47e38d829aa8cad2d610 + name: tzdata + noarch: generic + run_exports: {} + sha256: 1d30098909076af33a35017eed6f2953af1c769e273a0626a04722ac4acaba3c + size: 119135 + subdir: noarch + timestamp: 1767016325805 + version: 2025c + fn: tzdata-2025c-hc9c84f9_1.conda + url: https://conda.anaconda.org/conda-forge/noarch/tzdata-2025c-hc9c84f9_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhcf101f3_0 + build_number: 0 + depends: + - python >=3.8 + - python + license: Apache-2.0 + license_family: APACHE + md5: b76541e68fea4d511b1ac46a28dcd2c6 + name: packaging + noarch: python + run_exports: {} + sha256: c1fc0f953048f743385d31c468b4a678b3ad20caffdeaa94bed85ba63049fd58 + size: 72010 + subdir: noarch + timestamp: 1769093650580 + version: '26.0' + fn: packaging-26.0-pyhcf101f3_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/packaging-26.0-pyhcf101f3_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb78ec9c_6 + build_number: 6 + depends: + - __glibc >=2.17,<3.0.a0 + - libzlib >=1.3.1,<2.0a0 + license: BSD-3-Clause + license_family: BSD + md5: 4a13eeac0b5c8e5b8ab496e6c4ddd829 + name: zstd + run_exports: + weak: + - zstd >=1.5.7,<1.6.0a0 + sha256: 68f0206ca6e98fea941e5717cec780ed2873ffabc0e1ed34428c061e2c6268c7 + size: 601375 + subdir: linux-64 + timestamp: 1764777111296 + version: 1.5.7 + fn: zstd-1.5.7-hb78ec9c_6.conda + url: https://conda.anaconda.org/conda-forge/linux-64/zstd-1.5.7-hb78ec9c_6.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: 20_gnu + build_number: 20 + constrains: + - openmp_impl <0.0a0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgomp >=7.5.0 + license: BSD-3-Clause + license_family: BSD + md5: a9f577daf3de00bca7c3c76c0ecbd1de + name: _openmp_mutex + run_exports: + strong: + - _openmp_mutex >=4.5 + sha256: 1dd3fffd892081df9726d7eb7e0dea6198962ba775bd88842135a4ddb4deb3c9 + size: 28948 + subdir: linux-64 + timestamp: 1770939786096 + version: '4.5' + fn: _openmp_mutex-4.5-20_gnu.conda + url: https://conda.anaconda.org/conda-forge/linux-64/_openmp_mutex-4.5-20_gnu.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: he0feb66_18 + build_number: 18 + depends: + - __glibc >=2.17,<3.0.a0 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + md5: 239c5e9546c38a1e884d69effcf4c882 + name: libgomp + run_exports: + strong: + - _openmp_mutex >=4.5 + sha256: 21337ab58e5e0649d869ab168d4e609b033509de22521de1bfed0c031bfc5110 + size: 603262 + subdir: linux-64 + timestamp: 1771378117851 + version: 15.2.0 + fn: libgomp-15.2.0-he0feb66_18.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgomp-15.2.0-he0feb66_18.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h33c6efd_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + - libstdcxx >=14 + license: MIT + license_family: MIT + md5: c80d8a3b84358cb967fa81e7075fbc8a + name: icu + run_exports: + weak: + - icu >=78.3,<79.0a0 + sha256: fbf86c4a59c2ed05bbffb2ba25c7ed94f6185ec30ecb691615d42342baa1a16a + size: 12723451 + subdir: linux-64 + timestamp: 1773822285671 + version: '78.3' + fn: icu-78.3-h33c6efd_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/icu-78.3-h33c6efd_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h934c35e_18 + build_number: 18 + constrains: + - libstdcxx-ng ==15.2.0=*_18 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc 15.2.0 he0feb66_18 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + md5: 1b08cd684f34175e4514474793d44bcb + name: libstdcxx + run_exports: {} + sha256: 78668020064fdaa27e9ab65cd2997e2c837b564ab26ce3bf0e58a2ce1a525c6e + size: 5852330 + subdir: linux-64 + timestamp: 1771378262446 + version: 15.2.0 + fn: libstdcxx-15.2.0-h934c35e_18.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libstdcxx-15.2.0-h934c35e_18.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hbd8a1cb_0 + build_number: 0 + depends: + - __unix + license: ISC + md5: 4492fd26db29495f0ba23f146cd5638d + name: ca-certificates + noarch: generic + run_exports: {} + sha256: 67cc7101b36421c5913a1687ef1b99f85b5d6868da3abbf6ec1a4181e79782fc + size: 147413 + subdir: noarch + timestamp: 1772006283803 + version: 2026.2.25 + fn: ca-certificates-2026.2.25-hbd8a1cb_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/ca-certificates-2026.2.25-hbd8a1cb_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhcf101f3_0 + build_number: 0 + depends: + - python >=3.10 + - zipp >=3.20 + - python + license: Apache-2.0 + license_family: APACHE + md5: 080594bf4493e6bae2607e65390c520a + name: importlib-metadata + noarch: python + run_exports: {} + sha256: 82ab2a0d91ca1e7e63ab6a4939356667ef683905dea631bc2121aa534d347b16 + size: 34387 + subdir: noarch + timestamp: 1773931568510 + version: 8.8.0 + fn: importlib-metadata-8.8.0-pyhcf101f3_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/importlib-metadata-8.8.0-pyhcf101f3_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhcf101f3_0 + build_number: 0 + depends: + - python >=3.10 + - python + license: MIT + license_family: MIT + md5: b5325cf06a000c5b14970462ff5e4d58 + name: tomli + noarch: python + run_exports: {} + sha256: 91cafdb64268e43e0e10d30bd1bef5af392e69f00edd34dfaf909f69ab2da6bd + size: 21561 + subdir: noarch + timestamp: 1774492402955 + version: 2.4.1 + fn: tomli-2.4.1-pyhcf101f3_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/tomli-2.4.1-pyhcf101f3_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h396c80c_0 + build_number: 0 + depends: + - typing_extensions ==4.15.0 pyhcf101f3_0 + license: PSF-2.0 + license_family: PSF + md5: edd329d7d3a4ab45dcf905899a7a6115 + name: typing-extensions + noarch: generic + run_exports: {} + sha256: 7c2df5721c742c2a47b2c8f960e718c930031663ac1174da67c1ed5999f7938c + size: 91383 + subdir: noarch + timestamp: 1756220668932 + version: 4.15.0 + fn: typing-extensions-4.15.0-h396c80c_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/typing-extensions-4.15.0-h396c80c_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhcf101f3_0 + build_number: 0 + depends: + - python >=3.10 + - python + license: PSF-2.0 + license_family: PSF + md5: 0caa1af407ecff61170c9437a808404d + name: typing_extensions + noarch: python + run_exports: {} + sha256: 032271135bca55aeb156cee361c81350c6f3fb203f57d024d7e5a1fc9ef18731 + size: 51692 + subdir: noarch + timestamp: 1756220668932 + version: 4.15.0 + fn: typing_extensions-4.15.0-pyhcf101f3_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/typing_extensions-4.15.0-pyhcf101f3_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhcf101f3_1 + build_number: 1 + depends: + - python >=3.10 + - python + license: MIT + license_family: MIT + md5: 30cd29cb87d819caead4d55184c1d115 + name: zipp + noarch: python + run_exports: {} + sha256: b4533f7d9efc976511a73ef7d4a2473406d7f4c750884be8e8620b0ce70f4dae + size: 24194 + subdir: noarch + timestamp: 1764460141901 + version: 3.23.0 + fn: zipp-3.23.0-pyhcf101f3_1.conda + url: https://conda.anaconda.org/conda-forge/noarch/zipp-3.23.0-pyhcf101f3_1.conda + channel: https://conda.anaconda.org/conda-forge/ + run: + depends: + - source: colorama >=0.4 + - source: pygments >=2.7.2 + - source: python >=3.10 + - source: iniconfig >=1.0.1 + - source: packaging >=22 + - source: pluggy >=1.5,<2 + - source: tomli >=1 + - source: exceptiongroup >=1 + - spec: python + from: host + run_export: python + constraints: + - source: pytest-faulthandler >=2 +finalized_sources: +- url: https://pypi.org/packages/source/p/pytest/pytest-9.0.3.tar.gz + sha256: b86ada508af81d19edeb213c681b1d48246c1a91d304c6c81a427674c17eb91c +system_tools: + rattler-build: 0.61.4 +extra_meta: + flow_run_id: azure_20260408.1.1 + remote_url: https://github.com/conda-forge/pytest-feedstock + sha: 2f4728238a1c1cc0aaba7d2513a1f1b8dbfc9657 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/recipe/variant_config.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/recipe/variant_config.yaml new file mode 100644 index 0000000000000000000000000000000000000000..2e7bfe008ef1704e087e5094182e4570e1a2ad17 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/recipe/variant_config.yaml @@ -0,0 +1,3 @@ +channel_sources: conda-forge +channel_targets: conda-forge main +target_platform: noarch diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/repodata_record.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/repodata_record.json new file mode 100644 index 0000000000000000000000000000000000000000..b834b38df8c98acc3748f33189b12f4f270e3bb6 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/repodata_record.json @@ -0,0 +1,31 @@ +{ + "build": "pyhc364b38_1", + "build_number": 1, + "build_string": "pyhc364b38_1", + "channel": "conda-forge", + "constrains": [ + "pytest-faulthandler >=2" + ], + "depends": [ + "colorama >=0.4", + "pygments >=2.7.2", + "python >=3.10", + "iniconfig >=1.0.1", + "packaging >=22", + "pluggy >=1.5,<2", + "tomli >=1", + "exceptiongroup >=1", + "python" + ], + "fn": "pytest-9.0.3-pyhc364b38_1.conda", + "license": "MIT", + "md5": "6a991452eadf2771952f39d43615bb3e", + "name": "pytest", + "noarch": "python", + "sha256": "960f59442173eee0731906a9077bd5ccf60f4b4226f05a22d1728ab9a21a879c", + "size": 299984, + "subdir": "noarch", + "timestamp": 1775644472, + "url": "https://conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1.conda", + "version": "9.0.3" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/tests/tests.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/tests/tests.yaml new file mode 100644 index 0000000000000000000000000000000000000000..e9e0c286667d0a55f01d8ccd700811d165e9c9e2 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/info/tests/tests.yaml @@ -0,0 +1,10 @@ +- python: + imports: + - pytest + python_version: + - 3.10.* +- script: + content: pytest -h + requirements: + run: + - python 3.10.* diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..8eb8ec9605c73aeba33b5a2031d59a84d6841225 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/__init__.py @@ -0,0 +1,13 @@ +from __future__ import annotations + + +__all__ = ["__version__", "version_tuple"] + +try: + from ._version import version as __version__ + from ._version import version_tuple +except ImportError: # pragma: no cover + # broken installation, we don't even try + # unknown only works because we do poor mans version compare + __version__ = "unknown" + version_tuple = (0, 0, "unknown") diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_argcomplete.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_argcomplete.py new file mode 100644 index 0000000000000000000000000000000000000000..59426ef949ed9276b5708f9f44e6893f2333f2e1 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_argcomplete.py @@ -0,0 +1,117 @@ +"""Allow bash-completion for argparse with argcomplete if installed. + +Needs argcomplete>=0.5.6 for python 3.2/3.3 (older versions fail +to find the magic string, so _ARGCOMPLETE env. var is never set, and +this does not need special code). + +Function try_argcomplete(parser) should be called directly before +the call to ArgumentParser.parse_args(). + +The filescompleter is what you normally would use on the positional +arguments specification, in order to get "dirname/" after "dirn<TAB>" +instead of the default "dirname ": + + optparser.add_argument(Config._file_or_dir, nargs='*').completer=filescompleter + +Other, application specific, completers should go in the file +doing the add_argument calls as they need to be specified as .completer +attributes as well. (If argcomplete is not installed, the function the +attribute points to will not be used). + +SPEEDUP +======= + +The generic argcomplete script for bash-completion +(/etc/bash_completion.d/python-argcomplete.sh) +uses a python program to determine startup script generated by pip. +You can speed up completion somewhat by changing this script to include + # PYTHON_ARGCOMPLETE_OK +so the python-argcomplete-check-easy-install-script does not +need to be called to find the entry point of the code and see if that is +marked with PYTHON_ARGCOMPLETE_OK. + +INSTALL/DEBUGGING +================= + +To include this support in another application that has setup.py generated +scripts: + +- Add the line: + # PYTHON_ARGCOMPLETE_OK + near the top of the main python entry point. + +- Include in the file calling parse_args(): + from _argcomplete import try_argcomplete, filescompleter + Call try_argcomplete just before parse_args(), and optionally add + filescompleter to the positional arguments' add_argument(). + +If things do not work right away: + +- Switch on argcomplete debugging with (also helpful when doing custom + completers): + export _ARC_DEBUG=1 + +- Run: + python-argcomplete-check-easy-install-script $(which appname) + echo $? + will echo 0 if the magic line has been found, 1 if not. + +- Sometimes it helps to find early on errors using: + _ARGCOMPLETE=1 _ARC_DEBUG=1 appname + which should throw a KeyError: 'COMPLINE' (which is properly set by the + global argcomplete script). +""" + +from __future__ import annotations + +import argparse +from glob import glob +import os +import sys +from typing import Any + + +class FastFilesCompleter: + """Fast file completer class.""" + + def __init__(self, directories: bool = True) -> None: + self.directories = directories + + def __call__(self, prefix: str, **kwargs: Any) -> list[str]: + # Only called on non option completions. + if os.sep in prefix[1:]: + prefix_dir = len(os.path.dirname(prefix) + os.sep) + else: + prefix_dir = 0 + completion = [] + globbed = [] + if "*" not in prefix and "?" not in prefix: + # We are on unix, otherwise no bash. + if not prefix or prefix[-1] == os.sep: + globbed.extend(glob(prefix + ".*")) + prefix += "*" + globbed.extend(glob(prefix)) + for x in sorted(globbed): + if os.path.isdir(x): + x += "/" + # Append stripping the prefix (like bash, not like compgen). + completion.append(x[prefix_dir:]) + return completion + + +if os.environ.get("_ARGCOMPLETE"): + try: + import argcomplete.completers + except ImportError: + sys.exit(-1) + filescompleter: FastFilesCompleter | None = FastFilesCompleter() + + def try_argcomplete(parser: argparse.ArgumentParser) -> None: + argcomplete.autocomplete(parser, always_complete_options=False) + +else: + + def try_argcomplete(parser: argparse.ArgumentParser) -> None: + pass + + filescompleter = None diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_code/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_code/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..7f67a2e3e0a6f34e04444d9410f517d59d21c422 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_code/__init__.py @@ -0,0 +1,26 @@ +"""Python inspection/code generation API.""" + +from __future__ import annotations + +from .code import Code +from .code import ExceptionInfo +from .code import filter_traceback +from .code import Frame +from .code import getfslineno +from .code import Traceback +from .code import TracebackEntry +from .source import getrawcode +from .source import Source + + +__all__ = [ + "Code", + "ExceptionInfo", + "Frame", + "Source", + "Traceback", + "TracebackEntry", + "filter_traceback", + "getfslineno", + "getrawcode", +] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_code/code.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_code/code.py new file mode 100644 index 0000000000000000000000000000000000000000..4cf99a77340f13b0b57937b7cbfea325233c8702 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_code/code.py @@ -0,0 +1,1571 @@ +# mypy: allow-untyped-defs +from __future__ import annotations + +import ast +from collections.abc import Callable +from collections.abc import Iterable +from collections.abc import Mapping +from collections.abc import Sequence +import dataclasses +import inspect +from inspect import CO_VARARGS +from inspect import CO_VARKEYWORDS +from io import StringIO +import os +from pathlib import Path +import re +import sys +from traceback import extract_tb +from traceback import format_exception +from traceback import format_exception_only +from traceback import FrameSummary +from types import CodeType +from types import FrameType +from types import TracebackType +from typing import Any +from typing import ClassVar +from typing import Final +from typing import final +from typing import Generic +from typing import Literal +from typing import overload +from typing import SupportsIndex +from typing import TypeAlias +from typing import TypeVar + +import pluggy + +import _pytest +from _pytest._code.source import findsource +from _pytest._code.source import getrawcode +from _pytest._code.source import getstatementrange_ast +from _pytest._code.source import Source +from _pytest._io import TerminalWriter +from _pytest._io.saferepr import safeformat +from _pytest._io.saferepr import saferepr +from _pytest.compat import get_real_func +from _pytest.deprecated import check_ispytest +from _pytest.pathlib import absolutepath +from _pytest.pathlib import bestrelpath + + +if sys.version_info < (3, 11): + from exceptiongroup import BaseExceptionGroup + +TracebackStyle = Literal["long", "short", "line", "no", "native", "value", "auto"] + +EXCEPTION_OR_MORE = type[BaseException] | tuple[type[BaseException], ...] + + +class Code: + """Wrapper around Python code objects.""" + + __slots__ = ("raw",) + + def __init__(self, obj: CodeType) -> None: + self.raw = obj + + @classmethod + def from_function(cls, obj: object) -> Code: + return cls(getrawcode(obj)) + + def __eq__(self, other): + return self.raw == other.raw + + # Ignore type because of https://github.com/python/mypy/issues/4266. + __hash__ = None # type: ignore + + @property + def firstlineno(self) -> int: + return self.raw.co_firstlineno - 1 + + @property + def name(self) -> str: + return self.raw.co_name + + @property + def path(self) -> Path | str: + """Return a path object pointing to source code, or an ``str`` in + case of ``OSError`` / non-existing file.""" + if not self.raw.co_filename: + return "" + try: + p = absolutepath(self.raw.co_filename) + # maybe don't try this checking + if not p.exists(): + raise OSError("path check failed.") + return p + except OSError: + # XXX maybe try harder like the weird logic + # in the standard lib [linecache.updatecache] does? + return self.raw.co_filename + + @property + def fullsource(self) -> Source | None: + """Return a _pytest._code.Source object for the full source file of the code.""" + full, _ = findsource(self.raw) + return full + + def source(self) -> Source: + """Return a _pytest._code.Source object for the code object's source only.""" + # return source only for that part of code + return Source(self.raw) + + def getargs(self, var: bool = False) -> tuple[str, ...]: + """Return a tuple with the argument names for the code object. + + If 'var' is set True also return the names of the variable and + keyword arguments when present. + """ + # Handy shortcut for getting args. + raw = self.raw + argcount = raw.co_argcount + if var: + argcount += raw.co_flags & CO_VARARGS + argcount += raw.co_flags & CO_VARKEYWORDS + return raw.co_varnames[:argcount] + + +class Frame: + """Wrapper around a Python frame holding f_locals and f_globals + in which expressions can be evaluated.""" + + __slots__ = ("raw",) + + def __init__(self, frame: FrameType) -> None: + self.raw = frame + + @property + def lineno(self) -> int: + return self.raw.f_lineno - 1 + + @property + def f_globals(self) -> dict[str, Any]: + return self.raw.f_globals + + @property + def f_locals(self) -> dict[str, Any]: + return self.raw.f_locals + + @property + def code(self) -> Code: + return Code(self.raw.f_code) + + @property + def statement(self) -> Source: + """Statement this frame is at.""" + if self.code.fullsource is None: + return Source("") + return self.code.fullsource.getstatement(self.lineno) + + def eval(self, code, **vars): + """Evaluate 'code' in the frame. + + 'vars' are optional additional local variables. + + Returns the result of the evaluation. + """ + f_locals = self.f_locals.copy() + f_locals.update(vars) + return eval(code, self.f_globals, f_locals) + + def repr(self, object: object) -> str: + """Return a 'safe' (non-recursive, one-line) string repr for 'object'.""" + return saferepr(object) + + def getargs(self, var: bool = False): + """Return a list of tuples (name, value) for all arguments. + + If 'var' is set True, also include the variable and keyword arguments + when present. + """ + retval = [] + for arg in self.code.getargs(var): + try: + retval.append((arg, self.f_locals[arg])) + except KeyError: + pass # this can occur when using Psyco + return retval + + +class TracebackEntry: + """A single entry in a Traceback.""" + + __slots__ = ("_rawentry", "_repr_style") + + def __init__( + self, + rawentry: TracebackType, + repr_style: Literal["short", "long"] | None = None, + ) -> None: + self._rawentry: Final = rawentry + self._repr_style: Final = repr_style + + def with_repr_style( + self, repr_style: Literal["short", "long"] | None + ) -> TracebackEntry: + return TracebackEntry(self._rawentry, repr_style) + + @property + def lineno(self) -> int: + return self._rawentry.tb_lineno - 1 + + def get_python_framesummary(self) -> FrameSummary: + # Python's built-in traceback module implements all the nitty gritty + # details to get column numbers of out frames. + stack_summary = extract_tb(self._rawentry, limit=1) + return stack_summary[0] + + # Column and end line numbers introduced in python 3.11 + if sys.version_info < (3, 11): + + @property + def end_lineno_relative(self) -> int | None: + return None + + @property + def colno(self) -> int | None: + return None + + @property + def end_colno(self) -> int | None: + return None + else: + + @property + def end_lineno_relative(self) -> int | None: + frame_summary = self.get_python_framesummary() + if frame_summary.end_lineno is None: # pragma: no cover + return None + return frame_summary.end_lineno - 1 - self.frame.code.firstlineno + + @property + def colno(self) -> int | None: + """Starting byte offset of the expression in the traceback entry.""" + return self.get_python_framesummary().colno + + @property + def end_colno(self) -> int | None: + """Ending byte offset of the expression in the traceback entry.""" + return self.get_python_framesummary().end_colno + + @property + def frame(self) -> Frame: + return Frame(self._rawentry.tb_frame) + + @property + def relline(self) -> int: + return self.lineno - self.frame.code.firstlineno + + def __repr__(self) -> str: + return f"<TracebackEntry {self.frame.code.path}:{self.lineno + 1}>" + + @property + def statement(self) -> Source: + """_pytest._code.Source object for the current statement.""" + source = self.frame.code.fullsource + assert source is not None + return source.getstatement(self.lineno) + + @property + def path(self) -> Path | str: + """Path to the source code.""" + return self.frame.code.path + + @property + def locals(self) -> dict[str, Any]: + """Locals of underlying frame.""" + return self.frame.f_locals + + def getfirstlinesource(self) -> int: + return self.frame.code.firstlineno + + def getsource( + self, astcache: dict[str | Path, ast.AST] | None = None + ) -> Source | None: + """Return failing source code.""" + # we use the passed in astcache to not reparse asttrees + # within exception info printing + source = self.frame.code.fullsource + if source is None: + return None + key = astnode = None + if astcache is not None: + key = self.frame.code.path + if key is not None: + astnode = astcache.get(key, None) + start = self.getfirstlinesource() + try: + astnode, _, end = getstatementrange_ast( + self.lineno, source, astnode=astnode + ) + except SyntaxError: + end = self.lineno + 1 + else: + if key is not None and astcache is not None: + astcache[key] = astnode + return source[start:end] + + source = property(getsource) + + def ishidden(self, excinfo: ExceptionInfo[BaseException] | None) -> bool: + """Return True if the current frame has a var __tracebackhide__ + resolving to True. + + If __tracebackhide__ is a callable, it gets called with the + ExceptionInfo instance and can decide whether to hide the traceback. + + Mostly for internal use. + """ + tbh: bool | Callable[[ExceptionInfo[BaseException] | None], bool] = False + for maybe_ns_dct in (self.frame.f_locals, self.frame.f_globals): + # in normal cases, f_locals and f_globals are dictionaries + # however via `exec(...)` / `eval(...)` they can be other types + # (even incorrect types!). + # as such, we suppress all exceptions while accessing __tracebackhide__ + try: + tbh = maybe_ns_dct["__tracebackhide__"] + except Exception: + pass + else: + break + if tbh and callable(tbh): + return tbh(excinfo) + return tbh + + def __str__(self) -> str: + name = self.frame.code.name + try: + line = str(self.statement).lstrip() + except KeyboardInterrupt: + raise + except BaseException: + line = "???" + # This output does not quite match Python's repr for traceback entries, + # but changing it to do so would break certain plugins. See + # https://github.com/pytest-dev/pytest/pull/7535/ for details. + return f" File '{self.path}':{self.lineno + 1} in {name}\n {line}\n" + + @property + def name(self) -> str: + """co_name of underlying code.""" + return self.frame.code.raw.co_name + + +class Traceback(list[TracebackEntry]): + """Traceback objects encapsulate and offer higher level access to Traceback entries.""" + + def __init__( + self, + tb: TracebackType | Iterable[TracebackEntry], + ) -> None: + """Initialize from given python traceback object and ExceptionInfo.""" + if isinstance(tb, TracebackType): + + def f(cur: TracebackType) -> Iterable[TracebackEntry]: + cur_: TracebackType | None = cur + while cur_ is not None: + yield TracebackEntry(cur_) + cur_ = cur_.tb_next + + super().__init__(f(tb)) + else: + super().__init__(tb) + + def cut( + self, + path: os.PathLike[str] | str | None = None, + lineno: int | None = None, + firstlineno: int | None = None, + excludepath: os.PathLike[str] | None = None, + ) -> Traceback: + """Return a Traceback instance wrapping part of this Traceback. + + By providing any combination of path, lineno and firstlineno, the + first frame to start the to-be-returned traceback is determined. + + This allows cutting the first part of a Traceback instance e.g. + for formatting reasons (removing some uninteresting bits that deal + with handling of the exception/traceback). + """ + path_ = None if path is None else os.fspath(path) + excludepath_ = None if excludepath is None else os.fspath(excludepath) + for x in self: + code = x.frame.code + codepath = code.path + if path is not None and str(codepath) != path_: + continue + if ( + excludepath is not None + and isinstance(codepath, Path) + and excludepath_ in (str(p) for p in codepath.parents) # type: ignore[operator] + ): + continue + if lineno is not None and x.lineno != lineno: + continue + if firstlineno is not None and x.frame.code.firstlineno != firstlineno: + continue + return Traceback(x._rawentry) + return self + + @overload + def __getitem__(self, key: SupportsIndex) -> TracebackEntry: ... + + @overload + def __getitem__(self, key: slice) -> Traceback: ... + + def __getitem__(self, key: SupportsIndex | slice) -> TracebackEntry | Traceback: + if isinstance(key, slice): + return self.__class__(super().__getitem__(key)) + else: + return super().__getitem__(key) + + def filter( + self, + excinfo_or_fn: ExceptionInfo[BaseException] | Callable[[TracebackEntry], bool], + /, + ) -> Traceback: + """Return a Traceback instance with certain items removed. + + If the filter is an `ExceptionInfo`, removes all the ``TracebackEntry``s + which are hidden (see ishidden() above). + + Otherwise, the filter is a function that gets a single argument, a + ``TracebackEntry`` instance, and should return True when the item should + be added to the ``Traceback``, False when not. + """ + if isinstance(excinfo_or_fn, ExceptionInfo): + fn = lambda x: not x.ishidden(excinfo_or_fn) # noqa: E731 + else: + fn = excinfo_or_fn + return Traceback(filter(fn, self)) + + def recursionindex(self) -> int | None: + """Return the index of the frame/TracebackEntry where recursion originates if + appropriate, None if no recursion occurred.""" + cache: dict[tuple[Any, int, int], list[dict[str, Any]]] = {} + for i, entry in enumerate(self): + # id for the code.raw is needed to work around + # the strange metaprogramming in the decorator lib from pypi + # which generates code objects that have hash/value equality + # XXX needs a test + key = entry.frame.code.path, id(entry.frame.code.raw), entry.lineno + values = cache.setdefault(key, []) + # Since Python 3.13 f_locals is a proxy, freeze it. + loc = dict(entry.frame.f_locals) + if values: + for otherloc in values: + if otherloc == loc: + return i + values.append(loc) + return None + + +def stringify_exception( + exc: BaseException, include_subexception_msg: bool = True +) -> str: + try: + notes = getattr(exc, "__notes__", []) + except KeyError: + # Workaround for https://github.com/python/cpython/issues/98778 on + # some 3.10 and 3.11 patch versions. + HTTPError = getattr(sys.modules.get("urllib.error", None), "HTTPError", ()) + if sys.version_info < (3, 12) and isinstance(exc, HTTPError): + notes = [] + else: # pragma: no cover + # exception not related to above bug, reraise + raise + if not include_subexception_msg and isinstance(exc, BaseExceptionGroup): + message = exc.message + else: + message = str(exc) + + return "\n".join( + [ + message, + *notes, + ] + ) + + +E = TypeVar("E", bound=BaseException, covariant=True) + + +@final +@dataclasses.dataclass +class ExceptionInfo(Generic[E]): + """Wraps sys.exc_info() objects and offers help for navigating the traceback.""" + + _assert_start_repr: ClassVar = "AssertionError('assert " + + _excinfo: tuple[type[E], E, TracebackType] | None + _striptext: str + _traceback: Traceback | None + + def __init__( + self, + excinfo: tuple[type[E], E, TracebackType] | None, + striptext: str = "", + traceback: Traceback | None = None, + *, + _ispytest: bool = False, + ) -> None: + check_ispytest(_ispytest) + self._excinfo = excinfo + self._striptext = striptext + self._traceback = traceback + + @classmethod + def from_exception( + cls, + # Ignoring error: "Cannot use a covariant type variable as a parameter". + # This is OK to ignore because this class is (conceptually) readonly. + # See https://github.com/python/mypy/issues/7049. + exception: E, # type: ignore[misc] + exprinfo: str | None = None, + ) -> ExceptionInfo[E]: + """Return an ExceptionInfo for an existing exception. + + The exception must have a non-``None`` ``__traceback__`` attribute, + otherwise this function fails with an assertion error. This means that + the exception must have been raised, or added a traceback with the + :py:meth:`~BaseException.with_traceback()` method. + + :param exprinfo: + A text string helping to determine if we should strip + ``AssertionError`` from the output. Defaults to the exception + message/``__str__()``. + + .. versionadded:: 7.4 + """ + assert exception.__traceback__, ( + "Exceptions passed to ExcInfo.from_exception(...)" + " must have a non-None __traceback__." + ) + exc_info = (type(exception), exception, exception.__traceback__) + return cls.from_exc_info(exc_info, exprinfo) + + @classmethod + def from_exc_info( + cls, + exc_info: tuple[type[E], E, TracebackType], + exprinfo: str | None = None, + ) -> ExceptionInfo[E]: + """Like :func:`from_exception`, but using old-style exc_info tuple.""" + _striptext = "" + if exprinfo is None and isinstance(exc_info[1], AssertionError): + exprinfo = getattr(exc_info[1], "msg", None) + if exprinfo is None: + exprinfo = saferepr(exc_info[1]) + if exprinfo and exprinfo.startswith(cls._assert_start_repr): + _striptext = "AssertionError: " + + return cls(exc_info, _striptext, _ispytest=True) + + @classmethod + def from_current(cls, exprinfo: str | None = None) -> ExceptionInfo[BaseException]: + """Return an ExceptionInfo matching the current traceback. + + .. warning:: + + Experimental API + + :param exprinfo: + A text string helping to determine if we should strip + ``AssertionError`` from the output. Defaults to the exception + message/``__str__()``. + """ + tup = sys.exc_info() + assert tup[0] is not None, "no current exception" + assert tup[1] is not None, "no current exception" + assert tup[2] is not None, "no current exception" + exc_info = (tup[0], tup[1], tup[2]) + return ExceptionInfo.from_exc_info(exc_info, exprinfo) + + @classmethod + def for_later(cls) -> ExceptionInfo[E]: + """Return an unfilled ExceptionInfo.""" + return cls(None, _ispytest=True) + + def fill_unfilled(self, exc_info: tuple[type[E], E, TracebackType]) -> None: + """Fill an unfilled ExceptionInfo created with ``for_later()``.""" + assert self._excinfo is None, "ExceptionInfo was already filled" + self._excinfo = exc_info + + @property + def type(self) -> type[E]: + """The exception class.""" + assert self._excinfo is not None, ( + ".type can only be used after the context manager exits" + ) + return self._excinfo[0] + + @property + def value(self) -> E: + """The exception value.""" + assert self._excinfo is not None, ( + ".value can only be used after the context manager exits" + ) + return self._excinfo[1] + + @property + def tb(self) -> TracebackType: + """The exception raw traceback.""" + assert self._excinfo is not None, ( + ".tb can only be used after the context manager exits" + ) + return self._excinfo[2] + + @property + def typename(self) -> str: + """The type name of the exception.""" + assert self._excinfo is not None, ( + ".typename can only be used after the context manager exits" + ) + return self.type.__name__ + + @property + def traceback(self) -> Traceback: + """The traceback.""" + if self._traceback is None: + self._traceback = Traceback(self.tb) + return self._traceback + + @traceback.setter + def traceback(self, value: Traceback) -> None: + self._traceback = value + + def __repr__(self) -> str: + if self._excinfo is None: + return "<ExceptionInfo for raises contextmanager>" + return f"<{self.__class__.__name__} {saferepr(self._excinfo[1])} tblen={len(self.traceback)}>" + + def exconly(self, tryshort: bool = False) -> str: + """Return the exception as a string. + + When 'tryshort' resolves to True, and the exception is an + AssertionError, only the actual exception part of the exception + representation is returned (so 'AssertionError: ' is removed from + the beginning). + """ + + def _get_single_subexc( + eg: BaseExceptionGroup[BaseException], + ) -> BaseException | None: + if len(eg.exceptions) != 1: + return None + if isinstance(e := eg.exceptions[0], BaseExceptionGroup): + return _get_single_subexc(e) + return e + + if ( + tryshort + and isinstance(self.value, BaseExceptionGroup) + and (subexc := _get_single_subexc(self.value)) is not None + ): + return f"{subexc!r} [single exception in {type(self.value).__name__}]" + + lines = format_exception_only(self.type, self.value) + text = "".join(lines) + text = text.rstrip() + if tryshort: + if text.startswith(self._striptext): + text = text[len(self._striptext) :] + return text + + def errisinstance(self, exc: EXCEPTION_OR_MORE) -> bool: + """Return True if the exception is an instance of exc. + + Consider using ``isinstance(excinfo.value, exc)`` instead. + """ + return isinstance(self.value, exc) + + def _getreprcrash(self) -> ReprFileLocation | None: + # Find last non-hidden traceback entry that led to the exception of the + # traceback, or None if all hidden. + for i in range(-1, -len(self.traceback) - 1, -1): + entry = self.traceback[i] + if not entry.ishidden(self): + path, lineno = entry.frame.code.raw.co_filename, entry.lineno + exconly = self.exconly(tryshort=True) + return ReprFileLocation(path, lineno + 1, exconly) + return None + + def getrepr( + self, + showlocals: bool = False, + style: TracebackStyle = "long", + abspath: bool = False, + tbfilter: bool | Callable[[ExceptionInfo[BaseException]], Traceback] = True, + funcargs: bool = False, + truncate_locals: bool = True, + truncate_args: bool = True, + chain: bool = True, + ) -> ReprExceptionInfo | ExceptionChainRepr: + """Return str()able representation of this exception info. + + :param bool showlocals: + Show locals per traceback entry. + Ignored if ``style=="native"``. + + :param str style: + long|short|line|no|native|value traceback style. + + :param bool abspath: + If paths should be changed to absolute or left unchanged. + + :param tbfilter: + A filter for traceback entries. + + * If false, don't hide any entries. + * If true, hide internal entries and entries that contain a local + variable ``__tracebackhide__ = True``. + * If a callable, delegates the filtering to the callable. + + Ignored if ``style`` is ``"native"``. + + :param bool funcargs: + Show fixtures ("funcargs" for legacy purposes) per traceback entry. + + :param bool truncate_locals: + With ``showlocals==True``, make sure locals can be safely represented as strings. + + :param bool truncate_args: + With ``showargs==True``, make sure args can be safely represented as strings. + + :param bool chain: + If chained exceptions in Python 3 should be shown. + + .. versionchanged:: 3.9 + + Added the ``chain`` parameter. + """ + if style == "native": + return ReprExceptionInfo( + reprtraceback=ReprTracebackNative( + format_exception( + self.type, + self.value, + self.traceback[0]._rawentry if self.traceback else None, + ) + ), + reprcrash=self._getreprcrash(), + ) + + fmt = FormattedExcinfo( + showlocals=showlocals, + style=style, + abspath=abspath, + tbfilter=tbfilter, + funcargs=funcargs, + truncate_locals=truncate_locals, + truncate_args=truncate_args, + chain=chain, + ) + return fmt.repr_excinfo(self) + + def match(self, regexp: str | re.Pattern[str]) -> Literal[True]: + """Check whether the regular expression `regexp` matches the string + representation of the exception using :func:`python:re.search`. + + If it matches `True` is returned, otherwise an `AssertionError` is raised. + """ + __tracebackhide__ = True + value = stringify_exception(self.value) + msg = ( + f"Regex pattern did not match.\n" + f" Expected regex: {regexp!r}\n" + f" Actual message: {value!r}" + ) + if regexp == value: + msg += "\n Did you mean to `re.escape()` the regex?" + assert re.search(regexp, value), msg + # Return True to allow for "assert excinfo.match()". + return True + + def _group_contains( + self, + exc_group: BaseExceptionGroup[BaseException], + expected_exception: EXCEPTION_OR_MORE, + match: str | re.Pattern[str] | None, + target_depth: int | None = None, + current_depth: int = 1, + ) -> bool: + """Return `True` if a `BaseExceptionGroup` contains a matching exception.""" + if (target_depth is not None) and (current_depth > target_depth): + # already descended past the target depth + return False + for exc in exc_group.exceptions: + if isinstance(exc, BaseExceptionGroup): + if self._group_contains( + exc, expected_exception, match, target_depth, current_depth + 1 + ): + return True + if (target_depth is not None) and (current_depth != target_depth): + # not at the target depth, no match + continue + if not isinstance(exc, expected_exception): + continue + if match is not None: + value = stringify_exception(exc) + if not re.search(match, value): + continue + return True + return False + + def group_contains( + self, + expected_exception: EXCEPTION_OR_MORE, + *, + match: str | re.Pattern[str] | None = None, + depth: int | None = None, + ) -> bool: + """Check whether a captured exception group contains a matching exception. + + :param Type[BaseException] | Tuple[Type[BaseException]] expected_exception: + The expected exception type, or a tuple if one of multiple possible + exception types are expected. + + :param str | re.Pattern[str] | None match: + If specified, a string containing a regular expression, + or a regular expression object, that is tested against the string + representation of the exception and its `PEP-678 <https://peps.python.org/pep-0678/>` `__notes__` + using :func:`re.search`. + + To match a literal string that may contain :ref:`special characters + <re-syntax>`, the pattern can first be escaped with :func:`re.escape`. + + :param Optional[int] depth: + If `None`, will search for a matching exception at any nesting depth. + If >= 1, will only match an exception if it's at the specified depth (depth = 1 being + the exceptions contained within the topmost exception group). + + .. versionadded:: 8.0 + + .. warning:: + This helper makes it easy to check for the presence of specific exceptions, + but it is very bad for checking that the group does *not* contain + *any other exceptions*. + You should instead consider using :class:`pytest.RaisesGroup` + + """ + msg = "Captured exception is not an instance of `BaseExceptionGroup`" + assert isinstance(self.value, BaseExceptionGroup), msg + msg = "`depth` must be >= 1 if specified" + assert (depth is None) or (depth >= 1), msg + return self._group_contains(self.value, expected_exception, match, depth) + + +# Type alias for the `tbfilter` setting: +# bool: If True, it should be filtered using Traceback.filter() +# callable: A callable that takes an ExceptionInfo and returns the filtered traceback. +TracebackFilter: TypeAlias = bool | Callable[[ExceptionInfo[BaseException]], Traceback] + + +@dataclasses.dataclass +class FormattedExcinfo: + """Presenting information about failing Functions and Generators.""" + + # for traceback entries + flow_marker: ClassVar = ">" + fail_marker: ClassVar = "E" + + showlocals: bool = False + style: TracebackStyle = "long" + abspath: bool = True + tbfilter: TracebackFilter = True + funcargs: bool = False + truncate_locals: bool = True + truncate_args: bool = True + chain: bool = True + astcache: dict[str | Path, ast.AST] = dataclasses.field( + default_factory=dict, init=False, repr=False + ) + + def _getindent(self, source: Source) -> int: + # Figure out indent for the given source. + try: + s = str(source.getstatement(len(source) - 1)) + except KeyboardInterrupt: + raise + except BaseException: + try: + s = str(source[-1]) + except KeyboardInterrupt: + raise + except BaseException: + return 0 + return 4 + (len(s) - len(s.lstrip())) + + def _getentrysource(self, entry: TracebackEntry) -> Source | None: + source = entry.getsource(self.astcache) + if source is not None: + source = source.deindent() + return source + + def repr_args(self, entry: TracebackEntry) -> ReprFuncArgs | None: + if self.funcargs: + args = [] + for argname, argvalue in entry.frame.getargs(var=True): + if self.truncate_args: + str_repr = saferepr(argvalue) + else: + str_repr = saferepr(argvalue, maxsize=None) + args.append((argname, str_repr)) + return ReprFuncArgs(args) + return None + + def get_source( + self, + source: Source | None, + line_index: int = -1, + excinfo: ExceptionInfo[BaseException] | None = None, + short: bool = False, + end_line_index: int | None = None, + colno: int | None = None, + end_colno: int | None = None, + ) -> list[str]: + """Return formatted and marked up source lines.""" + lines = [] + if source is not None and line_index < 0: + line_index += len(source) + if source is None or line_index >= len(source.lines) or line_index < 0: + # `line_index` could still be outside `range(len(source.lines))` if + # we're processing AST with pathological position attributes. + source = Source("???") + line_index = 0 + space_prefix = " " + if short: + lines.append(space_prefix + source.lines[line_index].strip()) + lines.extend( + self.get_highlight_arrows_for_line( + raw_line=source.raw_lines[line_index], + line=source.lines[line_index].strip(), + lineno=line_index, + end_lineno=end_line_index, + colno=colno, + end_colno=end_colno, + ) + ) + else: + for line in source.lines[:line_index]: + lines.append(space_prefix + line) + lines.append(self.flow_marker + " " + source.lines[line_index]) + lines.extend( + self.get_highlight_arrows_for_line( + raw_line=source.raw_lines[line_index], + line=source.lines[line_index], + lineno=line_index, + end_lineno=end_line_index, + colno=colno, + end_colno=end_colno, + ) + ) + for line in source.lines[line_index + 1 :]: + lines.append(space_prefix + line) + if excinfo is not None: + indent = 4 if short else self._getindent(source) + lines.extend(self.get_exconly(excinfo, indent=indent, markall=True)) + return lines + + def get_highlight_arrows_for_line( + self, + line: str, + raw_line: str, + lineno: int | None, + end_lineno: int | None, + colno: int | None, + end_colno: int | None, + ) -> list[str]: + """Return characters highlighting a source line. + + Example with colno and end_colno pointing to the bar expression: + "foo() + bar()" + returns " ^^^^^" + """ + if lineno != end_lineno: + # Don't handle expressions that span multiple lines. + return [] + if colno is None or end_colno is None: + # Can't do anything without column information. + return [] + + num_stripped_chars = len(raw_line) - len(line) + + start_char_offset = _byte_offset_to_character_offset(raw_line, colno) + end_char_offset = _byte_offset_to_character_offset(raw_line, end_colno) + num_carets = end_char_offset - start_char_offset + # If the highlight would span the whole line, it is redundant, don't + # show it. + if num_carets >= len(line.strip()): + return [] + + highlights = " " + highlights += " " * (start_char_offset - num_stripped_chars + 1) + highlights += "^" * num_carets + return [highlights] + + def get_exconly( + self, + excinfo: ExceptionInfo[BaseException], + indent: int = 4, + markall: bool = False, + ) -> list[str]: + lines = [] + indentstr = " " * indent + # Get the real exception information out. + exlines = excinfo.exconly(tryshort=True).split("\n") + failindent = self.fail_marker + indentstr[1:] + for line in exlines: + lines.append(failindent + line) + if not markall: + failindent = indentstr + return lines + + def repr_locals(self, locals: Mapping[str, object]) -> ReprLocals | None: + if self.showlocals: + lines = [] + keys = [loc for loc in locals if loc[0] != "@"] + keys.sort() + for name in keys: + value = locals[name] + if name == "__builtins__": + lines.append("__builtins__ = <builtins>") + else: + # This formatting could all be handled by the + # _repr() function, which is only reprlib.Repr in + # disguise, so is very configurable. + if self.truncate_locals: + str_repr = saferepr(value) + else: + str_repr = safeformat(value) + # if len(str_repr) < 70 or not isinstance(value, (list, tuple, dict)): + lines.append(f"{name:<10} = {str_repr}") + # else: + # self._line("%-10s =\\" % (name,)) + # # XXX + # pprint.pprint(value, stream=self.excinfowriter) + return ReprLocals(lines) + return None + + def repr_traceback_entry( + self, + entry: TracebackEntry | None, + excinfo: ExceptionInfo[BaseException] | None = None, + ) -> ReprEntry: + lines: list[str] = [] + style = ( + entry._repr_style + if entry is not None and entry._repr_style is not None + else self.style + ) + if style in ("short", "long") and entry is not None: + source = self._getentrysource(entry) + if source is None: + source = Source("???") + line_index = 0 + end_line_index, colno, end_colno = None, None, None + else: + line_index = entry.relline + end_line_index = entry.end_lineno_relative + colno = entry.colno + end_colno = entry.end_colno + short = style == "short" + reprargs = self.repr_args(entry) if not short else None + s = self.get_source( + source=source, + line_index=line_index, + excinfo=excinfo, + short=short, + end_line_index=end_line_index, + colno=colno, + end_colno=end_colno, + ) + lines.extend(s) + if short: + message = f"in {entry.name}" + else: + message = (excinfo and excinfo.typename) or "" + entry_path = entry.path + path = self._makepath(entry_path) + reprfileloc = ReprFileLocation(path, entry.lineno + 1, message) + localsrepr = self.repr_locals(entry.locals) + return ReprEntry(lines, reprargs, localsrepr, reprfileloc, style) + elif style == "value": + if excinfo: + lines.extend(str(excinfo.value).split("\n")) + return ReprEntry(lines, None, None, None, style) + else: + if excinfo: + lines.extend(self.get_exconly(excinfo, indent=4)) + return ReprEntry(lines, None, None, None, style) + + def _makepath(self, path: Path | str) -> str: + if not self.abspath and isinstance(path, Path): + try: + np = bestrelpath(Path.cwd(), path) + except OSError: + return str(path) + if len(np) < len(str(path)): + return np + return str(path) + + def repr_traceback(self, excinfo: ExceptionInfo[BaseException]) -> ReprTraceback: + traceback = filter_excinfo_traceback(self.tbfilter, excinfo) + + if isinstance(excinfo.value, RecursionError): + traceback, extraline = self._truncate_recursive_traceback(traceback) + else: + extraline = None + + if not traceback: + if extraline is None: + extraline = "All traceback entries are hidden. Pass `--full-trace` to see hidden and internal frames." + entries = [self.repr_traceback_entry(None, excinfo)] + return ReprTraceback(entries, extraline, style=self.style) + + last = traceback[-1] + if self.style == "value": + entries = [self.repr_traceback_entry(last, excinfo)] + return ReprTraceback(entries, None, style=self.style) + + entries = [ + self.repr_traceback_entry(entry, excinfo if last == entry else None) + for entry in traceback + ] + return ReprTraceback(entries, extraline, style=self.style) + + def _truncate_recursive_traceback( + self, traceback: Traceback + ) -> tuple[Traceback, str | None]: + """Truncate the given recursive traceback trying to find the starting + point of the recursion. + + The detection is done by going through each traceback entry and + finding the point in which the locals of the frame are equal to the + locals of a previous frame (see ``recursionindex()``). + + Handle the situation where the recursion process might raise an + exception (for example comparing numpy arrays using equality raises a + TypeError), in which case we do our best to warn the user of the + error and show a limited traceback. + """ + try: + recursionindex = traceback.recursionindex() + except Exception as e: + max_frames = 10 + extraline: str | None = ( + "!!! Recursion error detected, but an error occurred locating the origin of recursion.\n" + " The following exception happened when comparing locals in the stack frame:\n" + f" {type(e).__name__}: {e!s}\n" + f" Displaying first and last {max_frames} stack frames out of {len(traceback)}." + ) + # Type ignored because adding two instances of a List subtype + # currently incorrectly has type List instead of the subtype. + traceback = traceback[:max_frames] + traceback[-max_frames:] # type: ignore + else: + if recursionindex is not None: + extraline = "!!! Recursion detected (same locals & position)" + traceback = traceback[: recursionindex + 1] + else: + extraline = None + + return traceback, extraline + + def repr_excinfo(self, excinfo: ExceptionInfo[BaseException]) -> ExceptionChainRepr: + repr_chain: list[tuple[ReprTraceback, ReprFileLocation | None, str | None]] = [] + e: BaseException | None = excinfo.value + excinfo_: ExceptionInfo[BaseException] | None = excinfo + descr = None + seen: set[int] = set() + while e is not None and id(e) not in seen: + seen.add(id(e)) + + if excinfo_: + # Fall back to native traceback as a temporary workaround until + # full support for exception groups added to ExceptionInfo. + # See https://github.com/pytest-dev/pytest/issues/9159 + reprtraceback: ReprTraceback | ReprTracebackNative + if isinstance(e, BaseExceptionGroup): + # don't filter any sub-exceptions since they shouldn't have any internal frames + traceback = filter_excinfo_traceback(self.tbfilter, excinfo) + reprtraceback = ReprTracebackNative( + format_exception( + type(excinfo.value), + excinfo.value, + traceback[0]._rawentry if traceback else None, + ) + ) + if not traceback: + reprtraceback.extraline = ( + "All traceback entries are hidden. " + "Pass `--full-trace` to see hidden and internal frames." + ) + + else: + reprtraceback = self.repr_traceback(excinfo_) + reprcrash = excinfo_._getreprcrash() + else: + # Fallback to native repr if the exception doesn't have a traceback: + # ExceptionInfo objects require a full traceback to work. + reprtraceback = ReprTracebackNative(format_exception(type(e), e, None)) + reprcrash = None + repr_chain += [(reprtraceback, reprcrash, descr)] + + if e.__cause__ is not None and self.chain: + e = e.__cause__ + excinfo_ = ExceptionInfo.from_exception(e) if e.__traceback__ else None + descr = "The above exception was the direct cause of the following exception:" + elif ( + e.__context__ is not None and not e.__suppress_context__ and self.chain + ): + e = e.__context__ + excinfo_ = ExceptionInfo.from_exception(e) if e.__traceback__ else None + descr = "During handling of the above exception, another exception occurred:" + else: + e = None + repr_chain.reverse() + return ExceptionChainRepr(repr_chain) + + +@dataclasses.dataclass(eq=False) +class TerminalRepr: + def __str__(self) -> str: + # FYI this is called from pytest-xdist's serialization of exception + # information. + io = StringIO() + tw = TerminalWriter(file=io) + self.toterminal(tw) + return io.getvalue().strip() + + def __repr__(self) -> str: + return f"<{self.__class__} instance at {id(self):0x}>" + + def toterminal(self, tw: TerminalWriter) -> None: + raise NotImplementedError() + + +# This class is abstract -- only subclasses are instantiated. +@dataclasses.dataclass(eq=False) +class ExceptionRepr(TerminalRepr): + # Provided by subclasses. + reprtraceback: ReprTraceback + reprcrash: ReprFileLocation | None + sections: list[tuple[str, str, str]] = dataclasses.field( + init=False, default_factory=list + ) + + def addsection(self, name: str, content: str, sep: str = "-") -> None: + self.sections.append((name, content, sep)) + + def toterminal(self, tw: TerminalWriter) -> None: + for name, content, sep in self.sections: + tw.sep(sep, name) + tw.line(content) + + +@dataclasses.dataclass(eq=False) +class ExceptionChainRepr(ExceptionRepr): + chain: Sequence[tuple[ReprTraceback, ReprFileLocation | None, str | None]] + + def __init__( + self, + chain: Sequence[tuple[ReprTraceback, ReprFileLocation | None, str | None]], + ) -> None: + # reprcrash and reprtraceback of the outermost (the newest) exception + # in the chain. + super().__init__( + reprtraceback=chain[-1][0], + reprcrash=chain[-1][1], + ) + self.chain = chain + + def toterminal(self, tw: TerminalWriter) -> None: + for element in self.chain: + element[0].toterminal(tw) + if element[2] is not None: + tw.line("") + tw.line(element[2], yellow=True) + super().toterminal(tw) + + +@dataclasses.dataclass(eq=False) +class ReprExceptionInfo(ExceptionRepr): + reprtraceback: ReprTraceback + reprcrash: ReprFileLocation | None + + def toterminal(self, tw: TerminalWriter) -> None: + self.reprtraceback.toterminal(tw) + super().toterminal(tw) + + +@dataclasses.dataclass(eq=False) +class ReprTraceback(TerminalRepr): + reprentries: Sequence[ReprEntry | ReprEntryNative] + extraline: str | None + style: TracebackStyle + + entrysep: ClassVar = "_ " + + def toterminal(self, tw: TerminalWriter) -> None: + # The entries might have different styles. + for i, entry in enumerate(self.reprentries): + if entry.style == "long": + tw.line("") + entry.toterminal(tw) + if i < len(self.reprentries) - 1: + next_entry = self.reprentries[i + 1] + if entry.style == "long" or ( + entry.style == "short" and next_entry.style == "long" + ): + tw.sep(self.entrysep) + + if self.extraline: + tw.line(self.extraline) + + +class ReprTracebackNative(ReprTraceback): + def __init__(self, tblines: Sequence[str]) -> None: + self.reprentries = [ReprEntryNative(tblines)] + self.extraline = None + self.style = "native" + + +@dataclasses.dataclass(eq=False) +class ReprEntryNative(TerminalRepr): + lines: Sequence[str] + + style: ClassVar[TracebackStyle] = "native" + + def toterminal(self, tw: TerminalWriter) -> None: + tw.write("".join(self.lines)) + + +@dataclasses.dataclass(eq=False) +class ReprEntry(TerminalRepr): + lines: Sequence[str] + reprfuncargs: ReprFuncArgs | None + reprlocals: ReprLocals | None + reprfileloc: ReprFileLocation | None + style: TracebackStyle + + def _write_entry_lines(self, tw: TerminalWriter) -> None: + """Write the source code portions of a list of traceback entries with syntax highlighting. + + Usually entries are lines like these: + + " x = 1" + "> assert x == 2" + "E assert 1 == 2" + + This function takes care of rendering the "source" portions of it (the lines without + the "E" prefix) using syntax highlighting, taking care to not highlighting the ">" + character, as doing so might break line continuations. + """ + if not self.lines: + return + + if self.style == "value": + # Using tw.write instead of tw.line for testing purposes due to TWMock implementation; + # lines written with TWMock.line and TWMock._write_source cannot be distinguished + # from each other, whereas lines written with TWMock.write are marked with TWMock.WRITE + for line in self.lines: + tw.write(line) + tw.write("\n") + return + + # separate indents and source lines that are not failures: we want to + # highlight the code but not the indentation, which may contain markers + # such as "> assert 0" + fail_marker = f"{FormattedExcinfo.fail_marker} " + indent_size = len(fail_marker) + indents: list[str] = [] + source_lines: list[str] = [] + failure_lines: list[str] = [] + for index, line in enumerate(self.lines): + is_failure_line = line.startswith(fail_marker) + if is_failure_line: + # from this point on all lines are considered part of the failure + failure_lines.extend(self.lines[index:]) + break + else: + indents.append(line[:indent_size]) + source_lines.append(line[indent_size:]) + + tw._write_source(source_lines, indents) + + # failure lines are always completely red and bold + for line in failure_lines: + tw.line(line, bold=True, red=True) + + def toterminal(self, tw: TerminalWriter) -> None: + if self.style == "short": + if self.reprfileloc: + self.reprfileloc.toterminal(tw) + self._write_entry_lines(tw) + if self.reprlocals: + self.reprlocals.toterminal(tw, indent=" " * 8) + return + + if self.reprfuncargs: + self.reprfuncargs.toterminal(tw) + + self._write_entry_lines(tw) + + if self.reprlocals: + tw.line("") + self.reprlocals.toterminal(tw) + if self.reprfileloc: + if self.lines: + tw.line("") + self.reprfileloc.toterminal(tw) + + def __str__(self) -> str: + return "{}\n{}\n{}".format( + "\n".join(self.lines), self.reprlocals, self.reprfileloc + ) + + +@dataclasses.dataclass(eq=False) +class ReprFileLocation(TerminalRepr): + path: str + lineno: int + message: str + + def __post_init__(self) -> None: + self.path = str(self.path) + + def toterminal(self, tw: TerminalWriter) -> None: + # Filename and lineno output for each entry, using an output format + # that most editors understand. + msg = self.message + i = msg.find("\n") + if i != -1: + msg = msg[:i] + tw.write(self.path, bold=True, red=True) + tw.line(f":{self.lineno}: {msg}") + + +@dataclasses.dataclass(eq=False) +class ReprLocals(TerminalRepr): + lines: Sequence[str] + + def toterminal(self, tw: TerminalWriter, indent="") -> None: + for line in self.lines: + tw.line(indent + line) + + +@dataclasses.dataclass(eq=False) +class ReprFuncArgs(TerminalRepr): + args: Sequence[tuple[str, object]] + + def toterminal(self, tw: TerminalWriter) -> None: + if self.args: + linesofar = "" + for name, value in self.args: + ns = f"{name} = {value}" + if len(ns) + len(linesofar) + 2 > tw.fullwidth: + if linesofar: + tw.line(linesofar) + linesofar = ns + else: + if linesofar: + linesofar += ", " + ns + else: + linesofar = ns + if linesofar: + tw.line(linesofar) + tw.line("") + + +def getfslineno(obj: object) -> tuple[str | Path, int]: + """Return source location (path, lineno) for the given object. + + If the source cannot be determined return ("", -1). + + The line number is 0-based. + """ + # xxx let decorators etc specify a sane ordering + # NOTE: this used to be done in _pytest.compat.getfslineno, initially added + # in 6ec13a2b9. It ("place_as") appears to be something very custom. + obj = get_real_func(obj) + if hasattr(obj, "place_as"): + obj = obj.place_as + + try: + code = Code.from_function(obj) + except TypeError: + try: + fn = inspect.getsourcefile(obj) or inspect.getfile(obj) # type: ignore[arg-type] + except TypeError: + return "", -1 + + fspath = (fn and absolutepath(fn)) or "" + lineno = -1 + if fspath: + try: + _, lineno = findsource(obj) + except OSError: + pass + return fspath, lineno + + return code.path, code.firstlineno + + +def _byte_offset_to_character_offset(str, offset): + """Converts a byte based offset in a string to a code-point.""" + as_utf8 = str.encode("utf-8") + return len(as_utf8[:offset].decode("utf-8", errors="replace")) + + +# Relative paths that we use to filter traceback entries from appearing to the user; +# see filter_traceback. +# note: if we need to add more paths than what we have now we should probably use a list +# for better maintenance. + +_PLUGGY_DIR = Path(pluggy.__file__.rstrip("oc")) +# pluggy is either a package or a single module depending on the version +if _PLUGGY_DIR.name == "__init__.py": + _PLUGGY_DIR = _PLUGGY_DIR.parent +_PYTEST_DIR = Path(_pytest.__file__).parent + + +def filter_traceback(entry: TracebackEntry) -> bool: + """Return True if a TracebackEntry instance should be included in tracebacks. + + We hide traceback entries of: + + * dynamically generated code (no code to show up for it); + * internal traceback from pytest or its internal libraries, py and pluggy. + """ + # entry.path might sometimes return a str object when the entry + # points to dynamically generated code. + # See https://bitbucket.org/pytest-dev/py/issues/71. + raw_filename = entry.frame.code.raw.co_filename + is_generated = "<" in raw_filename and ">" in raw_filename + if is_generated: + return False + + # entry.path might point to a non-existing file, in which case it will + # also return a str object. See #1133. + p = Path(entry.path) + + parents = p.parents + if _PLUGGY_DIR in parents: + return False + if _PYTEST_DIR in parents: + return False + + return True + + +def filter_excinfo_traceback( + tbfilter: TracebackFilter, excinfo: ExceptionInfo[BaseException] +) -> Traceback: + """Filter the exception traceback in ``excinfo`` according to ``tbfilter``.""" + if callable(tbfilter): + return tbfilter(excinfo) + elif tbfilter: + return excinfo.traceback.filter(excinfo) + else: + return excinfo.traceback diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_code/source.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_code/source.py new file mode 100644 index 0000000000000000000000000000000000000000..99c242dd98e27ad6dcdf25a2c7e68e6fad209dd6 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_code/source.py @@ -0,0 +1,225 @@ +# mypy: allow-untyped-defs +from __future__ import annotations + +import ast +from bisect import bisect_right +from collections.abc import Iterable +from collections.abc import Iterator +import inspect +import textwrap +import tokenize +import types +from typing import overload +import warnings + + +class Source: + """An immutable object holding a source code fragment. + + When using Source(...), the source lines are deindented. + """ + + def __init__(self, obj: object = None) -> None: + if not obj: + self.lines: list[str] = [] + self.raw_lines: list[str] = [] + elif isinstance(obj, Source): + self.lines = obj.lines + self.raw_lines = obj.raw_lines + elif isinstance(obj, tuple | list): + self.lines = deindent(x.rstrip("\n") for x in obj) + self.raw_lines = list(x.rstrip("\n") for x in obj) + elif isinstance(obj, str): + self.lines = deindent(obj.split("\n")) + self.raw_lines = obj.split("\n") + else: + try: + rawcode = getrawcode(obj) + src = inspect.getsource(rawcode) + except TypeError: + src = inspect.getsource(obj) # type: ignore[arg-type] + self.lines = deindent(src.split("\n")) + self.raw_lines = src.split("\n") + + def __eq__(self, other: object) -> bool: + if not isinstance(other, Source): + return NotImplemented + return self.lines == other.lines + + # Ignore type because of https://github.com/python/mypy/issues/4266. + __hash__ = None # type: ignore + + @overload + def __getitem__(self, key: int) -> str: ... + + @overload + def __getitem__(self, key: slice) -> Source: ... + + def __getitem__(self, key: int | slice) -> str | Source: + if isinstance(key, int): + return self.lines[key] + else: + if key.step not in (None, 1): + raise IndexError("cannot slice a Source with a step") + newsource = Source() + newsource.lines = self.lines[key.start : key.stop] + newsource.raw_lines = self.raw_lines[key.start : key.stop] + return newsource + + def __iter__(self) -> Iterator[str]: + return iter(self.lines) + + def __len__(self) -> int: + return len(self.lines) + + def strip(self) -> Source: + """Return new Source object with trailing and leading blank lines removed.""" + start, end = 0, len(self) + while start < end and not self.lines[start].strip(): + start += 1 + while end > start and not self.lines[end - 1].strip(): + end -= 1 + source = Source() + source.raw_lines = self.raw_lines + source.lines[:] = self.lines[start:end] + return source + + def indent(self, indent: str = " " * 4) -> Source: + """Return a copy of the source object with all lines indented by the + given indent-string.""" + newsource = Source() + newsource.raw_lines = self.raw_lines + newsource.lines = [(indent + line) for line in self.lines] + return newsource + + def getstatement(self, lineno: int) -> Source: + """Return Source statement which contains the given linenumber + (counted from 0).""" + start, end = self.getstatementrange(lineno) + return self[start:end] + + def getstatementrange(self, lineno: int) -> tuple[int, int]: + """Return (start, end) tuple which spans the minimal statement region + which containing the given lineno.""" + if not (0 <= lineno < len(self)): + raise IndexError("lineno out of range") + _ast, start, end = getstatementrange_ast(lineno, self) + return start, end + + def deindent(self) -> Source: + """Return a new Source object deindented.""" + newsource = Source() + newsource.lines[:] = deindent(self.lines) + newsource.raw_lines = self.raw_lines + return newsource + + def __str__(self) -> str: + return "\n".join(self.lines) + + +# +# helper functions +# + + +def findsource(obj) -> tuple[Source | None, int]: + try: + sourcelines, lineno = inspect.findsource(obj) + except Exception: + return None, -1 + source = Source() + source.lines = [line.rstrip() for line in sourcelines] + source.raw_lines = sourcelines + return source, lineno + + +def getrawcode(obj: object, trycall: bool = True) -> types.CodeType: + """Return code object for given function.""" + try: + return obj.__code__ # type: ignore[attr-defined,no-any-return] + except AttributeError: + pass + if trycall: + call = getattr(obj, "__call__", None) + if call and not isinstance(obj, type): + return getrawcode(call, trycall=False) + raise TypeError(f"could not get code object for {obj!r}") + + +def deindent(lines: Iterable[str]) -> list[str]: + return textwrap.dedent("\n".join(lines)).splitlines() + + +def get_statement_startend2(lineno: int, node: ast.AST) -> tuple[int, int | None]: + # Flatten all statements and except handlers into one lineno-list. + # AST's line numbers start indexing at 1. + values: list[int] = [] + for x in ast.walk(node): + if isinstance(x, ast.stmt | ast.ExceptHandler): + # The lineno points to the class/def, so need to include the decorators. + if isinstance(x, ast.ClassDef | ast.FunctionDef | ast.AsyncFunctionDef): + for d in x.decorator_list: + values.append(d.lineno - 1) + values.append(x.lineno - 1) + for name in ("finalbody", "orelse"): + val: list[ast.stmt] | None = getattr(x, name, None) + if val: + # Treat the finally/orelse part as its own statement. + values.append(val[0].lineno - 1 - 1) + values.sort() + insert_index = bisect_right(values, lineno) + start = values[insert_index - 1] + if insert_index >= len(values): + end = None + else: + end = values[insert_index] + return start, end + + +def getstatementrange_ast( + lineno: int, + source: Source, + assertion: bool = False, + astnode: ast.AST | None = None, +) -> tuple[ast.AST, int, int]: + if astnode is None: + content = str(source) + # See #4260: + # Don't produce duplicate warnings when compiling source to find AST. + with warnings.catch_warnings(): + warnings.simplefilter("ignore") + astnode = ast.parse(content, "source", "exec") + + start, end = get_statement_startend2(lineno, astnode) + # We need to correct the end: + # - ast-parsing strips comments + # - there might be empty lines + # - we might have lesser indented code blocks at the end + if end is None: + end = len(source.lines) + + if end > start + 1: + # Make sure we don't span differently indented code blocks + # by using the BlockFinder helper used which inspect.getsource() uses itself. + block_finder = inspect.BlockFinder() + # If we start with an indented line, put blockfinder to "started" mode. + block_finder.started = ( + bool(source.lines[start]) and source.lines[start][0].isspace() + ) + it = ((x + "\n") for x in source.lines[start:end]) + try: + for tok in tokenize.generate_tokens(lambda: next(it)): + block_finder.tokeneater(*tok) + except (inspect.EndOfBlock, IndentationError): + end = block_finder.last + start + except Exception: + pass + + # The end might still point to a comment or empty line, correct it. + while end: + line = source.lines[end - 1].lstrip() + if line.startswith("#") or not line: + end -= 1 + else: + break + return astnode, start, end diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_io/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_io/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..b0155b18b605326ba0a3104deaefde938b7d651a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_io/__init__.py @@ -0,0 +1,10 @@ +from __future__ import annotations + +from .terminalwriter import get_terminal_width +from .terminalwriter import TerminalWriter + + +__all__ = [ + "TerminalWriter", + "get_terminal_width", +] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_io/pprint.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_io/pprint.py new file mode 100644 index 0000000000000000000000000000000000000000..28f069092061928a1c06aaba94b6e8ba4f03075f --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_io/pprint.py @@ -0,0 +1,673 @@ +# mypy: allow-untyped-defs +# This module was imported from the cpython standard library +# (https://github.com/python/cpython/) at commit +# c5140945c723ae6c4b7ee81ff720ac8ea4b52cfd (python3.12). +# +# +# Original Author: Fred L. Drake, Jr. +# fdrake@acm.org +# +# This is a simple little module I wrote to make life easier. I didn't +# see anything quite like it in the library, though I may have overlooked +# something. I wrote this when I was trying to read some heavily nested +# tuples with fairly non-descriptive content. This is modeled very much +# after Lisp/Scheme - style pretty-printing of lists. If you find it +# useful, thank small children who sleep at night. +from __future__ import annotations + +import collections as _collections +from collections.abc import Callable +from collections.abc import Iterator +import dataclasses as _dataclasses +from io import StringIO as _StringIO +import re +import types as _types +from typing import Any +from typing import IO + + +class _safe_key: + """Helper function for key functions when sorting unorderable objects. + + The wrapped-object will fallback to a Py2.x style comparison for + unorderable types (sorting first comparing the type name and then by + the obj ids). Does not work recursively, so dict.items() must have + _safe_key applied to both the key and the value. + + """ + + __slots__ = ["obj"] + + def __init__(self, obj): + self.obj = obj + + def __lt__(self, other): + try: + return self.obj < other.obj + except TypeError: + return (str(type(self.obj)), id(self.obj)) < ( + str(type(other.obj)), + id(other.obj), + ) + + +def _safe_tuple(t): + """Helper function for comparing 2-tuples""" + return _safe_key(t[0]), _safe_key(t[1]) + + +class PrettyPrinter: + def __init__( + self, + indent: int = 4, + width: int = 80, + depth: int | None = None, + ) -> None: + """Handle pretty printing operations onto a stream using a set of + configured parameters. + + indent + Number of spaces to indent for each level of nesting. + + width + Attempted maximum number of columns in the output. + + depth + The maximum depth to print out nested structures. + + """ + if indent < 0: + raise ValueError("indent must be >= 0") + if depth is not None and depth <= 0: + raise ValueError("depth must be > 0") + if not width: + raise ValueError("width must be != 0") + self._depth = depth + self._indent_per_level = indent + self._width = width + + def pformat(self, object: Any) -> str: + sio = _StringIO() + self._format(object, sio, 0, 0, set(), 0) + return sio.getvalue() + + def _format( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + objid = id(object) + if objid in context: + stream.write(_recursion(object)) + return + + p = self._dispatch.get(type(object).__repr__, None) + if p is not None: + context.add(objid) + p(self, object, stream, indent, allowance, context, level + 1) + context.remove(objid) + elif ( + _dataclasses.is_dataclass(object) + and not isinstance(object, type) + and object.__dataclass_params__.repr # type:ignore[attr-defined] + and + # Check dataclass has generated repr method. + hasattr(object.__repr__, "__wrapped__") + and "__create_fn__" in object.__repr__.__wrapped__.__qualname__ + ): + context.add(objid) + self._pprint_dataclass( + object, stream, indent, allowance, context, level + 1 + ) + context.remove(objid) + else: + stream.write(self._repr(object, context, level)) + + def _pprint_dataclass( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + cls_name = object.__class__.__name__ + items = [ + (f.name, getattr(object, f.name)) + for f in _dataclasses.fields(object) + if f.repr + ] + stream.write(cls_name + "(") + self._format_namespace_items(items, stream, indent, allowance, context, level) + stream.write(")") + + _dispatch: dict[ + Callable[..., str], + Callable[[PrettyPrinter, Any, IO[str], int, int, set[int], int], None], + ] = {} + + def _pprint_dict( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + write = stream.write + write("{") + items = sorted(object.items(), key=_safe_tuple) + self._format_dict_items(items, stream, indent, allowance, context, level) + write("}") + + _dispatch[dict.__repr__] = _pprint_dict + + def _pprint_ordered_dict( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + if not len(object): + stream.write(repr(object)) + return + cls = object.__class__ + stream.write(cls.__name__ + "(") + self._pprint_dict(object, stream, indent, allowance, context, level) + stream.write(")") + + _dispatch[_collections.OrderedDict.__repr__] = _pprint_ordered_dict + + def _pprint_list( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + stream.write("[") + self._format_items(object, stream, indent, allowance, context, level) + stream.write("]") + + _dispatch[list.__repr__] = _pprint_list + + def _pprint_tuple( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + stream.write("(") + self._format_items(object, stream, indent, allowance, context, level) + stream.write(")") + + _dispatch[tuple.__repr__] = _pprint_tuple + + def _pprint_set( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + if not len(object): + stream.write(repr(object)) + return + typ = object.__class__ + if typ is set: + stream.write("{") + endchar = "}" + else: + stream.write(typ.__name__ + "({") + endchar = "})" + object = sorted(object, key=_safe_key) + self._format_items(object, stream, indent, allowance, context, level) + stream.write(endchar) + + _dispatch[set.__repr__] = _pprint_set + _dispatch[frozenset.__repr__] = _pprint_set + + def _pprint_str( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + write = stream.write + if not len(object): + write(repr(object)) + return + chunks = [] + lines = object.splitlines(True) + if level == 1: + indent += 1 + allowance += 1 + max_width1 = max_width = self._width - indent + for i, line in enumerate(lines): + rep = repr(line) + if i == len(lines) - 1: + max_width1 -= allowance + if len(rep) <= max_width1: + chunks.append(rep) + else: + # A list of alternating (non-space, space) strings + parts = re.findall(r"\S*\s*", line) + assert parts + assert not parts[-1] + parts.pop() # drop empty last part + max_width2 = max_width + current = "" + for j, part in enumerate(parts): + candidate = current + part + if j == len(parts) - 1 and i == len(lines) - 1: + max_width2 -= allowance + if len(repr(candidate)) > max_width2: + if current: + chunks.append(repr(current)) + current = part + else: + current = candidate + if current: + chunks.append(repr(current)) + if len(chunks) == 1: + write(rep) + return + if level == 1: + write("(") + for i, rep in enumerate(chunks): + if i > 0: + write("\n" + " " * indent) + write(rep) + if level == 1: + write(")") + + _dispatch[str.__repr__] = _pprint_str + + def _pprint_bytes( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + write = stream.write + if len(object) <= 4: + write(repr(object)) + return + parens = level == 1 + if parens: + indent += 1 + allowance += 1 + write("(") + delim = "" + for rep in _wrap_bytes_repr(object, self._width - indent, allowance): + write(delim) + write(rep) + if not delim: + delim = "\n" + " " * indent + if parens: + write(")") + + _dispatch[bytes.__repr__] = _pprint_bytes + + def _pprint_bytearray( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + write = stream.write + write("bytearray(") + self._pprint_bytes( + bytes(object), stream, indent + 10, allowance + 1, context, level + 1 + ) + write(")") + + _dispatch[bytearray.__repr__] = _pprint_bytearray + + def _pprint_mappingproxy( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + stream.write("mappingproxy(") + self._format(object.copy(), stream, indent, allowance, context, level) + stream.write(")") + + _dispatch[_types.MappingProxyType.__repr__] = _pprint_mappingproxy + + def _pprint_simplenamespace( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + if type(object) is _types.SimpleNamespace: + # The SimpleNamespace repr is "namespace" instead of the class + # name, so we do the same here. For subclasses; use the class name. + cls_name = "namespace" + else: + cls_name = object.__class__.__name__ + items = object.__dict__.items() + stream.write(cls_name + "(") + self._format_namespace_items(items, stream, indent, allowance, context, level) + stream.write(")") + + _dispatch[_types.SimpleNamespace.__repr__] = _pprint_simplenamespace + + def _format_dict_items( + self, + items: list[tuple[Any, Any]], + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + if not items: + return + + write = stream.write + item_indent = indent + self._indent_per_level + delimnl = "\n" + " " * item_indent + for key, ent in items: + write(delimnl) + write(self._repr(key, context, level)) + write(": ") + self._format(ent, stream, item_indent, 1, context, level) + write(",") + + write("\n" + " " * indent) + + def _format_namespace_items( + self, + items: list[tuple[Any, Any]], + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + if not items: + return + + write = stream.write + item_indent = indent + self._indent_per_level + delimnl = "\n" + " " * item_indent + for key, ent in items: + write(delimnl) + write(key) + write("=") + if id(ent) in context: + # Special-case representation of recursion to match standard + # recursive dataclass repr. + write("...") + else: + self._format( + ent, + stream, + item_indent + len(key) + 1, + 1, + context, + level, + ) + + write(",") + + write("\n" + " " * indent) + + def _format_items( + self, + items: list[Any], + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + if not items: + return + + write = stream.write + item_indent = indent + self._indent_per_level + delimnl = "\n" + " " * item_indent + + for item in items: + write(delimnl) + self._format(item, stream, item_indent, 1, context, level) + write(",") + + write("\n" + " " * indent) + + def _repr(self, object: Any, context: set[int], level: int) -> str: + return self._safe_repr(object, context.copy(), self._depth, level) + + def _pprint_default_dict( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + rdf = self._repr(object.default_factory, context, level) + stream.write(f"{object.__class__.__name__}({rdf}, ") + self._pprint_dict(object, stream, indent, allowance, context, level) + stream.write(")") + + _dispatch[_collections.defaultdict.__repr__] = _pprint_default_dict + + def _pprint_counter( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + stream.write(object.__class__.__name__ + "(") + + if object: + stream.write("{") + items = object.most_common() + self._format_dict_items(items, stream, indent, allowance, context, level) + stream.write("}") + + stream.write(")") + + _dispatch[_collections.Counter.__repr__] = _pprint_counter + + def _pprint_chain_map( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + if not len(object.maps) or (len(object.maps) == 1 and not len(object.maps[0])): + stream.write(repr(object)) + return + + stream.write(object.__class__.__name__ + "(") + self._format_items(object.maps, stream, indent, allowance, context, level) + stream.write(")") + + _dispatch[_collections.ChainMap.__repr__] = _pprint_chain_map + + def _pprint_deque( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + stream.write(object.__class__.__name__ + "(") + if object.maxlen is not None: + stream.write(f"maxlen={object.maxlen}, ") + stream.write("[") + + self._format_items(object, stream, indent, allowance + 1, context, level) + stream.write("])") + + _dispatch[_collections.deque.__repr__] = _pprint_deque + + def _pprint_user_dict( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + self._format(object.data, stream, indent, allowance, context, level - 1) + + _dispatch[_collections.UserDict.__repr__] = _pprint_user_dict + + def _pprint_user_list( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + self._format(object.data, stream, indent, allowance, context, level - 1) + + _dispatch[_collections.UserList.__repr__] = _pprint_user_list + + def _pprint_user_string( + self, + object: Any, + stream: IO[str], + indent: int, + allowance: int, + context: set[int], + level: int, + ) -> None: + self._format(object.data, stream, indent, allowance, context, level - 1) + + _dispatch[_collections.UserString.__repr__] = _pprint_user_string + + def _safe_repr( + self, object: Any, context: set[int], maxlevels: int | None, level: int + ) -> str: + typ = type(object) + if typ in _builtin_scalars: + return repr(object) + + r = getattr(typ, "__repr__", None) + + if issubclass(typ, dict) and r is dict.__repr__: + if not object: + return "{}" + objid = id(object) + if maxlevels and level >= maxlevels: + return "{...}" + if objid in context: + return _recursion(object) + context.add(objid) + components: list[str] = [] + append = components.append + level += 1 + for k, v in sorted(object.items(), key=_safe_tuple): + krepr = self._safe_repr(k, context, maxlevels, level) + vrepr = self._safe_repr(v, context, maxlevels, level) + append(f"{krepr}: {vrepr}") + context.remove(objid) + return "{{{}}}".format(", ".join(components)) + + if (issubclass(typ, list) and r is list.__repr__) or ( + issubclass(typ, tuple) and r is tuple.__repr__ + ): + if issubclass(typ, list): + if not object: + return "[]" + format = "[%s]" + elif len(object) == 1: + format = "(%s,)" + else: + if not object: + return "()" + format = "(%s)" + objid = id(object) + if maxlevels and level >= maxlevels: + return format % "..." + if objid in context: + return _recursion(object) + context.add(objid) + components = [] + append = components.append + level += 1 + for o in object: + orepr = self._safe_repr(o, context, maxlevels, level) + append(orepr) + context.remove(objid) + return format % ", ".join(components) + + return repr(object) + + +_builtin_scalars = frozenset( + {str, bytes, bytearray, float, complex, bool, type(None), int} +) + + +def _recursion(object: Any) -> str: + return f"<Recursion on {type(object).__name__} with id={id(object)}>" + + +def _wrap_bytes_repr(object: Any, width: int, allowance: int) -> Iterator[str]: + current = b"" + last = len(object) // 4 * 4 + for i in range(0, len(object), 4): + part = object[i : i + 4] + candidate = current + part + if i == last: + width -= allowance + if len(repr(candidate)) > width: + if current: + yield repr(current) + current = part + else: + current = candidate + if current: + yield repr(current) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_io/saferepr.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_io/saferepr.py new file mode 100644 index 0000000000000000000000000000000000000000..cee70e332f9802a5963bfed8149ac997e5b30de2 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_io/saferepr.py @@ -0,0 +1,130 @@ +from __future__ import annotations + +import pprint +import reprlib + + +def _try_repr_or_str(obj: object) -> str: + try: + return repr(obj) + except (KeyboardInterrupt, SystemExit): + raise + except BaseException: + return f'{type(obj).__name__}("{obj}")' + + +def _format_repr_exception(exc: BaseException, obj: object) -> str: + try: + exc_info = _try_repr_or_str(exc) + except (KeyboardInterrupt, SystemExit): + raise + except BaseException as inner_exc: + exc_info = f"unpresentable exception ({_try_repr_or_str(inner_exc)})" + return ( + f"<[{exc_info} raised in repr()] {type(obj).__name__} object at 0x{id(obj):x}>" + ) + + +def _ellipsize(s: str, maxsize: int) -> str: + if len(s) > maxsize: + i = max(0, (maxsize - 3) // 2) + j = max(0, maxsize - 3 - i) + return s[:i] + "..." + s[len(s) - j :] + return s + + +class SafeRepr(reprlib.Repr): + """ + repr.Repr that limits the resulting size of repr() and includes + information on exceptions raised during the call. + """ + + def __init__(self, maxsize: int | None, use_ascii: bool = False) -> None: + """ + :param maxsize: + If not None, will truncate the resulting repr to that specific size, using ellipsis + somewhere in the middle to hide the extra text. + If None, will not impose any size limits on the returning repr. + """ + super().__init__() + # ``maxstring`` is used by the superclass, and needs to be an int; using a + # very large number in case maxsize is None, meaning we want to disable + # truncation. + self.maxstring = maxsize if maxsize is not None else 1_000_000_000 + self.maxsize = maxsize + self.use_ascii = use_ascii + + def repr(self, x: object) -> str: + try: + if self.use_ascii: + s = ascii(x) + else: + s = super().repr(x) + except (KeyboardInterrupt, SystemExit): + raise + except BaseException as exc: + s = _format_repr_exception(exc, x) + if self.maxsize is not None: + s = _ellipsize(s, self.maxsize) + return s + + def repr_instance(self, x: object, level: int) -> str: + try: + s = repr(x) + except (KeyboardInterrupt, SystemExit): + raise + except BaseException as exc: + s = _format_repr_exception(exc, x) + if self.maxsize is not None: + s = _ellipsize(s, self.maxsize) + return s + + +def safeformat(obj: object) -> str: + """Return a pretty printed string for the given object. + + Failing __repr__ functions of user instances will be represented + with a short exception info. + """ + try: + return pprint.pformat(obj) + except Exception as exc: + return _format_repr_exception(exc, obj) + + +# Maximum size of overall repr of objects to display during assertion errors. +DEFAULT_REPR_MAX_SIZE = 240 + + +def saferepr( + obj: object, maxsize: int | None = DEFAULT_REPR_MAX_SIZE, use_ascii: bool = False +) -> str: + """Return a size-limited safe repr-string for the given object. + + Failing __repr__ functions of user instances will be represented + with a short exception info and 'saferepr' generally takes + care to never raise exceptions itself. + + This function is a wrapper around the Repr/reprlib functionality of the + stdlib. + """ + return SafeRepr(maxsize, use_ascii).repr(obj) + + +def saferepr_unlimited(obj: object, use_ascii: bool = True) -> str: + """Return an unlimited-size safe repr-string for the given object. + + As with saferepr, failing __repr__ functions of user instances + will be represented with a short exception info. + + This function is a wrapper around simple repr. + + Note: a cleaner solution would be to alter ``saferepr``this way + when maxsize=None, but that might affect some other code. + """ + try: + if use_ascii: + return ascii(obj) + return repr(obj) + except Exception as exc: + return _format_repr_exception(exc, obj) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_io/terminalwriter.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_io/terminalwriter.py new file mode 100644 index 0000000000000000000000000000000000000000..9191b4edace06d673febe36b708fdefd53bae9be --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_io/terminalwriter.py @@ -0,0 +1,258 @@ +"""Helper functions for writing to terminals and files.""" + +from __future__ import annotations + +from collections.abc import Sequence +import os +import shutil +import sys +from typing import final +from typing import Literal +from typing import TextIO + +import pygments +from pygments.formatters.terminal import TerminalFormatter +from pygments.lexer import Lexer +from pygments.lexers.diff import DiffLexer +from pygments.lexers.python import PythonLexer + +from ..compat import assert_never +from .wcwidth import wcswidth + + +# This code was initially copied from py 1.8.1, file _io/terminalwriter.py. + + +def get_terminal_width() -> int: + width, _ = shutil.get_terminal_size(fallback=(80, 24)) + + # The Windows get_terminal_size may be bogus, let's sanify a bit. + if width < 40: + width = 80 + + return width + + +def should_do_markup(file: TextIO) -> bool: + if os.environ.get("PY_COLORS") == "1": + return True + if os.environ.get("PY_COLORS") == "0": + return False + if os.environ.get("NO_COLOR"): + return False + if os.environ.get("FORCE_COLOR"): + return True + return ( + hasattr(file, "isatty") and file.isatty() and os.environ.get("TERM") != "dumb" + ) + + +@final +class TerminalWriter: + _esctable = dict( + black=30, + red=31, + green=32, + yellow=33, + blue=34, + purple=35, + cyan=36, + white=37, + Black=40, + Red=41, + Green=42, + Yellow=43, + Blue=44, + Purple=45, + Cyan=46, + White=47, + bold=1, + light=2, + blink=5, + invert=7, + ) + + def __init__(self, file: TextIO | None = None) -> None: + if file is None: + file = sys.stdout + if hasattr(file, "isatty") and file.isatty() and sys.platform == "win32": + try: + import colorama + except ImportError: + pass + else: + file = colorama.AnsiToWin32(file).stream + assert file is not None + self._file = file + self.hasmarkup = should_do_markup(file) + self._current_line = "" + self._terminal_width: int | None = None + self.code_highlight = True + + @property + def fullwidth(self) -> int: + if self._terminal_width is not None: + return self._terminal_width + return get_terminal_width() + + @fullwidth.setter + def fullwidth(self, value: int) -> None: + self._terminal_width = value + + @property + def width_of_current_line(self) -> int: + """Return an estimate of the width so far in the current line.""" + return wcswidth(self._current_line) + + def markup(self, text: str, **markup: bool) -> str: + for name in markup: + if name not in self._esctable: + raise ValueError(f"unknown markup: {name!r}") + if self.hasmarkup: + esc = [self._esctable[name] for name, on in markup.items() if on] + if esc: + text = "".join(f"\x1b[{cod}m" for cod in esc) + text + "\x1b[0m" + return text + + def sep( + self, + sepchar: str, + title: str | None = None, + fullwidth: int | None = None, + **markup: bool, + ) -> None: + if fullwidth is None: + fullwidth = self.fullwidth + # The goal is to have the line be as long as possible + # under the condition that len(line) <= fullwidth. + if sys.platform == "win32": + # If we print in the last column on windows we are on a + # new line but there is no way to verify/neutralize this + # (we may not know the exact line width). + # So let's be defensive to avoid empty lines in the output. + fullwidth -= 1 + if title is not None: + # we want 2 + 2*len(fill) + len(title) <= fullwidth + # i.e. 2 + 2*len(sepchar)*N + len(title) <= fullwidth + # 2*len(sepchar)*N <= fullwidth - len(title) - 2 + # N <= (fullwidth - len(title) - 2) // (2*len(sepchar)) + N = max((fullwidth - len(title) - 2) // (2 * len(sepchar)), 1) + fill = sepchar * N + line = f"{fill} {title} {fill}" + else: + # we want len(sepchar)*N <= fullwidth + # i.e. N <= fullwidth // len(sepchar) + line = sepchar * (fullwidth // len(sepchar)) + # In some situations there is room for an extra sepchar at the right, + # in particular if we consider that with a sepchar like "_ " the + # trailing space is not important at the end of the line. + if len(line) + len(sepchar.rstrip()) <= fullwidth: + line += sepchar.rstrip() + + self.line(line, **markup) + + def write(self, msg: str, *, flush: bool = False, **markup: bool) -> None: + if msg: + current_line = msg.rsplit("\n", 1)[-1] + if "\n" in msg: + self._current_line = current_line + else: + self._current_line += current_line + + msg = self.markup(msg, **markup) + + self.write_raw(msg, flush=flush) + + def write_raw(self, msg: str, *, flush: bool = False) -> None: + try: + self._file.write(msg) + except UnicodeEncodeError: + # Some environments don't support printing general Unicode + # strings, due to misconfiguration or otherwise; in that case, + # print the string escaped to ASCII. + # When the Unicode situation improves we should consider + # letting the error propagate instead of masking it (see #7475 + # for one brief attempt). + msg = msg.encode("unicode-escape").decode("ascii") + self._file.write(msg) + + if flush: + self.flush() + + def line(self, s: str = "", **markup: bool) -> None: + self.write(s, **markup) + self.write("\n") + + def flush(self) -> None: + self._file.flush() + + def _write_source(self, lines: Sequence[str], indents: Sequence[str] = ()) -> None: + """Write lines of source code possibly highlighted. + + Keeping this private for now because the API is clunky. We should discuss how + to evolve the terminal writer so we can have more precise color support, for example + being able to write part of a line in one color and the rest in another, and so on. + """ + if indents and len(indents) != len(lines): + raise ValueError( + f"indents size ({len(indents)}) should have same size as lines ({len(lines)})" + ) + if not indents: + indents = [""] * len(lines) + source = "\n".join(lines) + new_lines = self._highlight(source).splitlines() + # Would be better to strict=True but that fails some CI jobs. + for indent, new_line in zip(indents, new_lines, strict=False): + self.line(indent + new_line) + + def _get_pygments_lexer(self, lexer: Literal["python", "diff"]) -> Lexer: + if lexer == "python": + return PythonLexer() + elif lexer == "diff": + return DiffLexer() + else: + assert_never(lexer) + + def _get_pygments_formatter(self) -> TerminalFormatter: + from _pytest.config.exceptions import UsageError + + theme = os.getenv("PYTEST_THEME") + theme_mode = os.getenv("PYTEST_THEME_MODE", "dark") + + try: + return TerminalFormatter(bg=theme_mode, style=theme) + except pygments.util.ClassNotFound as e: + raise UsageError( + f"PYTEST_THEME environment variable has an invalid value: '{theme}'. " + "Hint: See available pygments styles with `pygmentize -L styles`." + ) from e + except pygments.util.OptionError as e: + raise UsageError( + f"PYTEST_THEME_MODE environment variable has an invalid value: '{theme_mode}'. " + "The allowed values are 'dark' (default) and 'light'." + ) from e + + def _highlight( + self, source: str, lexer: Literal["diff", "python"] = "python" + ) -> str: + """Highlight the given source if we have markup support.""" + if not source or not self.hasmarkup or not self.code_highlight: + return source + + pygments_lexer = self._get_pygments_lexer(lexer) + pygments_formatter = self._get_pygments_formatter() + + highlighted: str = pygments.highlight( + source, pygments_lexer, pygments_formatter + ) + # pygments terminal formatter may add a newline when there wasn't one. + # We don't want this, remove. + if highlighted[-1] == "\n" and source[-1] != "\n": + highlighted = highlighted[:-1] + + # Some lexers will not set the initial color explicitly + # which may lead to the previous color being propagated to the + # start of the expression, so reset first. + highlighted = "\x1b[0m" + highlighted + + return highlighted diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_io/wcwidth.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_io/wcwidth.py new file mode 100644 index 0000000000000000000000000000000000000000..23886ff1581a16aa97e5c375e62261622e24c169 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_io/wcwidth.py @@ -0,0 +1,57 @@ +from __future__ import annotations + +from functools import lru_cache +import unicodedata + + +@lru_cache(100) +def wcwidth(c: str) -> int: + """Determine how many columns are needed to display a character in a terminal. + + Returns -1 if the character is not printable. + Returns 0, 1 or 2 for other characters. + """ + o = ord(c) + + # ASCII fast path. + if 0x20 <= o < 0x07F: + return 1 + + # Some Cf/Zp/Zl characters which should be zero-width. + if ( + o == 0x0000 + or 0x200B <= o <= 0x200F + or 0x2028 <= o <= 0x202E + or 0x2060 <= o <= 0x2063 + ): + return 0 + + category = unicodedata.category(c) + + # Control characters. + if category == "Cc": + return -1 + + # Combining characters with zero width. + if category in ("Me", "Mn"): + return 0 + + # Full/Wide east asian characters. + if unicodedata.east_asian_width(c) in ("F", "W"): + return 2 + + return 1 + + +def wcswidth(s: str) -> int: + """Determine how many columns are needed to display a string in a terminal. + + Returns -1 if the string contains non-printable characters. + """ + width = 0 + for c in unicodedata.normalize("NFC", s): + wc = wcwidth(c) + if wc < 0: + return -1 + width += wc + return width diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_py/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_py/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_py/error.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_py/error.py new file mode 100644 index 0000000000000000000000000000000000000000..dace23764ffb4da9744cf23b668c9e7011674c67 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_py/error.py @@ -0,0 +1,119 @@ +"""create errno-specific classes for IO or os calls.""" + +from __future__ import annotations + +from collections.abc import Callable +import errno +import os +import sys +from typing import TYPE_CHECKING +from typing import TypeVar + + +if TYPE_CHECKING: + from typing_extensions import ParamSpec + + P = ParamSpec("P") + +R = TypeVar("R") + + +class Error(EnvironmentError): + def __repr__(self) -> str: + return "{}.{} {!r}: {} ".format( + self.__class__.__module__, + self.__class__.__name__, + self.__class__.__doc__, + " ".join(map(str, self.args)), + # repr(self.args) + ) + + def __str__(self) -> str: + s = "[{}]: {}".format( + self.__class__.__doc__, + " ".join(map(str, self.args)), + ) + return s + + +_winerrnomap = { + 2: errno.ENOENT, + 3: errno.ENOENT, + 17: errno.EEXIST, + 18: errno.EXDEV, + 13: errno.EBUSY, # empty cd drive, but ENOMEDIUM seems unavailable + 22: errno.ENOTDIR, + 20: errno.ENOTDIR, + 267: errno.ENOTDIR, + 5: errno.EACCES, # anything better? +} + + +class ErrorMaker: + """lazily provides Exception classes for each possible POSIX errno + (as defined per the 'errno' module). All such instances + subclass EnvironmentError. + """ + + _errno2class: dict[int, type[Error]] = {} + + def __getattr__(self, name: str) -> type[Error]: + if name[0] == "_": + raise AttributeError(name) + eno = getattr(errno, name) + cls = self._geterrnoclass(eno) + setattr(self, name, cls) + return cls + + def _geterrnoclass(self, eno: int) -> type[Error]: + try: + return self._errno2class[eno] + except KeyError: + clsname = errno.errorcode.get(eno, f"UnknownErrno{eno}") + errorcls = type( + clsname, + (Error,), + {"__module__": "py.error", "__doc__": os.strerror(eno)}, + ) + self._errno2class[eno] = errorcls + return errorcls + + def checked_call( + self, func: Callable[P, R], *args: P.args, **kwargs: P.kwargs + ) -> R: + """Call a function and raise an errno-exception if applicable.""" + __tracebackhide__ = True + try: + return func(*args, **kwargs) + except Error: + raise + except OSError as value: + if not hasattr(value, "errno"): + raise + if sys.platform == "win32": + try: + # error: Invalid index type "Optional[int]" for "dict[int, int]"; expected type "int" [index] + # OK to ignore because we catch the KeyError below. + cls = self._geterrnoclass(_winerrnomap[value.errno]) # type:ignore[index] + except KeyError: + raise value + else: + # we are not on Windows, or we got a proper OSError + if value.errno is None: + cls = type( + "UnknownErrnoNone", + (Error,), + {"__module__": "py.error", "__doc__": None}, + ) + else: + cls = self._geterrnoclass(value.errno) + + raise cls(f"{func.__name__}{args!r}") + + +_error_maker = ErrorMaker() +checked_call = _error_maker.checked_call + + +def __getattr__(attr: str) -> type[Error]: + return getattr(_error_maker, attr) # type: ignore[no-any-return] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_py/path.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_py/path.py new file mode 100644 index 0000000000000000000000000000000000000000..998a7819972ac010a535887ab8f2a4c6560621af --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_py/path.py @@ -0,0 +1,1475 @@ +# mypy: allow-untyped-defs +"""local path implementation.""" + +from __future__ import annotations + +import atexit +from collections.abc import Callable +from contextlib import contextmanager +import fnmatch +import importlib.util +import io +import os +from os.path import abspath +from os.path import dirname +from os.path import exists +from os.path import isabs +from os.path import isdir +from os.path import isfile +from os.path import islink +from os.path import normpath +import posixpath +from stat import S_ISDIR +from stat import S_ISLNK +from stat import S_ISREG +import sys +from typing import Any +from typing import cast +from typing import Literal +from typing import overload +from typing import TYPE_CHECKING +import uuid +import warnings + +from . import error + + +# Moved from local.py. +iswin32 = sys.platform == "win32" or (getattr(os, "_name", False) == "nt") + + +class Checkers: + _depend_on_existence = "exists", "link", "dir", "file" + + def __init__(self, path): + self.path = path + + def dotfile(self): + return self.path.basename.startswith(".") + + def ext(self, arg): + if not arg.startswith("."): + arg = "." + arg + return self.path.ext == arg + + def basename(self, arg): + return self.path.basename == arg + + def basestarts(self, arg): + return self.path.basename.startswith(arg) + + def relto(self, arg): + return self.path.relto(arg) + + def fnmatch(self, arg): + return self.path.fnmatch(arg) + + def endswith(self, arg): + return str(self.path).endswith(arg) + + def _evaluate(self, kw): + from .._code.source import getrawcode + + for name, value in kw.items(): + invert = False + meth = None + try: + meth = getattr(self, name) + except AttributeError: + if name[:3] == "not": + invert = True + try: + meth = getattr(self, name[3:]) + except AttributeError: + pass + if meth is None: + raise TypeError(f"no {name!r} checker available for {self.path!r}") + try: + if getrawcode(meth).co_argcount > 1: + if (not meth(value)) ^ invert: + return False + else: + if bool(value) ^ bool(meth()) ^ invert: + return False + except (error.ENOENT, error.ENOTDIR, error.EBUSY): + # EBUSY feels not entirely correct, + # but its kind of necessary since ENOMEDIUM + # is not accessible in python + for name in self._depend_on_existence: + if name in kw: + if kw.get(name): + return False + name = "not" + name + if name in kw: + if not kw.get(name): + return False + return True + + _statcache: Stat + + def _stat(self) -> Stat: + try: + return self._statcache + except AttributeError: + try: + self._statcache = self.path.stat() + except error.ELOOP: + self._statcache = self.path.lstat() + return self._statcache + + def dir(self): + return S_ISDIR(self._stat().mode) + + def file(self): + return S_ISREG(self._stat().mode) + + def exists(self): + return self._stat() + + def link(self): + st = self.path.lstat() + return S_ISLNK(st.mode) + + +class NeverRaised(Exception): + pass + + +class Visitor: + def __init__(self, fil, rec, ignore, bf, sort): + if isinstance(fil, (str, bytes)): + fil = FNMatcher(fil) + if isinstance(rec, str): + self.rec: Callable[[LocalPath], bool] = FNMatcher(rec) + elif not hasattr(rec, "__call__") and rec: + self.rec = lambda path: True + else: + self.rec = rec + self.fil = fil + self.ignore = ignore + self.breadthfirst = bf + self.optsort = cast(Callable[[Any], Any], sorted) if sort else (lambda x: x) + + def gen(self, path): + try: + entries = path.listdir() + except self.ignore: + return + rec = self.rec + dirs = self.optsort( + [p for p in entries if p.check(dir=1) and (rec is None or rec(p))] + ) + if not self.breadthfirst: + for subdir in dirs: + yield from self.gen(subdir) + for p in self.optsort(entries): + if self.fil is None or self.fil(p): + yield p + if self.breadthfirst: + for subdir in dirs: + yield from self.gen(subdir) + + +class FNMatcher: + def __init__(self, pattern): + self.pattern = pattern + + def __call__(self, path): + pattern = self.pattern + + if ( + pattern.find(path.sep) == -1 + and iswin32 + and pattern.find(posixpath.sep) != -1 + ): + # Running on Windows, the pattern has no Windows path separators, + # and the pattern has one or more Posix path separators. Replace + # the Posix path separators with the Windows path separator. + pattern = pattern.replace(posixpath.sep, path.sep) + + if pattern.find(path.sep) == -1: + name = path.basename + else: + name = str(path) # path.strpath # XXX svn? + if not os.path.isabs(pattern): + pattern = "*" + path.sep + pattern + return fnmatch.fnmatch(name, pattern) + + +def map_as_list(func, iter): + return list(map(func, iter)) + + +class Stat: + if TYPE_CHECKING: + + @property + def size(self) -> int: ... + + @property + def mtime(self) -> float: ... + + def __getattr__(self, name: str) -> Any: + return getattr(self._osstatresult, "st_" + name) + + def __init__(self, path, osstatresult): + self.path = path + self._osstatresult = osstatresult + + @property + def owner(self): + if iswin32: + raise NotImplementedError("XXX win32") + import pwd + + entry = error.checked_call(pwd.getpwuid, self.uid) # type:ignore[attr-defined,unused-ignore] + return entry[0] + + @property + def group(self): + """Return group name of file.""" + if iswin32: + raise NotImplementedError("XXX win32") + import grp + + entry = error.checked_call(grp.getgrgid, self.gid) # type:ignore[attr-defined,unused-ignore] + return entry[0] + + def isdir(self): + return S_ISDIR(self._osstatresult.st_mode) + + def isfile(self): + return S_ISREG(self._osstatresult.st_mode) + + def islink(self): + self.path.lstat() + return S_ISLNK(self._osstatresult.st_mode) + + +def getuserid(user): + import pwd + + if not isinstance(user, int): + user = pwd.getpwnam(user)[2] # type:ignore[attr-defined,unused-ignore] + return user + + +def getgroupid(group): + import grp + + if not isinstance(group, int): + group = grp.getgrnam(group)[2] # type:ignore[attr-defined,unused-ignore] + return group + + +class LocalPath: + """Object oriented interface to os.path and other local filesystem + related information. + """ + + class ImportMismatchError(ImportError): + """raised on pyimport() if there is a mismatch of __file__'s""" + + sep = os.sep + + def __init__(self, path=None, expanduser=False): + """Initialize and return a local Path instance. + + Path can be relative to the current directory. + If path is None it defaults to the current working directory. + If expanduser is True, tilde-expansion is performed. + Note that Path instances always carry an absolute path. + Note also that passing in a local path object will simply return + the exact same path object. Use new() to get a new copy. + """ + if path is None: + self.strpath = error.checked_call(os.getcwd) + else: + try: + path = os.fspath(path) + except TypeError: + raise ValueError( + "can only pass None, Path instances " + "or non-empty strings to LocalPath" + ) + if expanduser: + path = os.path.expanduser(path) + self.strpath = abspath(path) + + if sys.platform != "win32": + + def chown(self, user, group, rec=0): + """Change ownership to the given user and group. + user and group may be specified by a number or + by a name. if rec is True change ownership + recursively. + """ + uid = getuserid(user) + gid = getgroupid(group) + if rec: + for x in self.visit(rec=lambda x: x.check(link=0)): + if x.check(link=0): + error.checked_call(os.chown, str(x), uid, gid) + error.checked_call(os.chown, str(self), uid, gid) + + def readlink(self) -> str: + """Return value of a symbolic link.""" + # https://github.com/python/mypy/issues/12278 + return error.checked_call(os.readlink, self.strpath) # type: ignore[arg-type,return-value,unused-ignore] + + def mklinkto(self, oldname): + """Posix style hard link to another name.""" + error.checked_call(os.link, str(oldname), str(self)) + + def mksymlinkto(self, value, absolute=1): + """Create a symbolic link with the given value (pointing to another name).""" + if absolute: + error.checked_call(os.symlink, str(value), self.strpath) + else: + base = self.common(value) + # with posix local paths '/' is always a common base + relsource = self.__class__(value).relto(base) + reldest = self.relto(base) + n = reldest.count(self.sep) + target = self.sep.join(("..",) * n + (relsource,)) + error.checked_call(os.symlink, target, self.strpath) + + def __div__(self, other): + return self.join(os.fspath(other)) + + __truediv__ = __div__ # py3k + + @property + def basename(self): + """Basename part of path.""" + return self._getbyspec("basename")[0] + + @property + def dirname(self): + """Dirname part of path.""" + return self._getbyspec("dirname")[0] + + @property + def purebasename(self): + """Pure base name of the path.""" + return self._getbyspec("purebasename")[0] + + @property + def ext(self): + """Extension of the path (including the '.').""" + return self._getbyspec("ext")[0] + + def read_binary(self): + """Read and return a bytestring from reading the path.""" + with self.open("rb") as f: + return f.read() + + def read_text(self, encoding): + """Read and return a Unicode string from reading the path.""" + with self.open("r", encoding=encoding) as f: + return f.read() + + def read(self, mode="r"): + """Read and return a bytestring from reading the path.""" + with self.open(mode) as f: + return f.read() + + def readlines(self, cr=1): + """Read and return a list of lines from the path. if cr is False, the + newline will be removed from the end of each line.""" + mode = "r" + + if not cr: + content = self.read(mode) + return content.split("\n") + else: + f = self.open(mode) + try: + return f.readlines() + finally: + f.close() + + def load(self): + """(deprecated) return object unpickled from self.read()""" + f = self.open("rb") + try: + import pickle + + return error.checked_call(pickle.load, f) + finally: + f.close() + + def move(self, target): + """Move this path to target.""" + if target.relto(self): + raise error.EINVAL(target, "cannot move path into a subdirectory of itself") + try: + self.rename(target) + except error.EXDEV: # invalid cross-device link + self.copy(target) + self.remove() + + def fnmatch(self, pattern): + """Return true if the basename/fullname matches the glob-'pattern'. + + valid pattern characters:: + + * matches everything + ? matches any single character + [seq] matches any character in seq + [!seq] matches any char not in seq + + If the pattern contains a path-separator then the full path + is used for pattern matching and a '*' is prepended to the + pattern. + + if the pattern doesn't contain a path-separator the pattern + is only matched against the basename. + """ + return FNMatcher(pattern)(self) + + def relto(self, relpath): + """Return a string which is the relative part of the path + to the given 'relpath'. + """ + if not isinstance(relpath, str | LocalPath): + raise TypeError(f"{relpath!r}: not a string or path object") + strrelpath = str(relpath) + if strrelpath and strrelpath[-1] != self.sep: + strrelpath += self.sep + # assert strrelpath[-1] == self.sep + # assert strrelpath[-2] != self.sep + strself = self.strpath + if sys.platform == "win32" or getattr(os, "_name", None) == "nt": + if os.path.normcase(strself).startswith(os.path.normcase(strrelpath)): + return strself[len(strrelpath) :] + elif strself.startswith(strrelpath): + return strself[len(strrelpath) :] + return "" + + def ensure_dir(self, *args): + """Ensure the path joined with args is a directory.""" + return self.ensure(*args, dir=True) + + def bestrelpath(self, dest): + """Return a string which is a relative path from self + (assumed to be a directory) to dest such that + self.join(bestrelpath) == dest and if not such + path can be determined return dest. + """ + try: + if self == dest: + return os.curdir + base = self.common(dest) + if not base: # can be the case on windows + return str(dest) + self2base = self.relto(base) + reldest = dest.relto(base) + if self2base: + n = self2base.count(self.sep) + 1 + else: + n = 0 + lst = [os.pardir] * n + if reldest: + lst.append(reldest) + target = dest.sep.join(lst) + return target + except AttributeError: + return str(dest) + + def exists(self): + return self.check() + + def isdir(self): + return self.check(dir=1) + + def isfile(self): + return self.check(file=1) + + def parts(self, reverse=False): + """Return a root-first list of all ancestor directories + plus the path itself. + """ + current = self + lst = [self] + while 1: + last = current + current = current.dirpath() + if last == current: + break + lst.append(current) + if not reverse: + lst.reverse() + return lst + + def common(self, other): + """Return the common part shared with the other path + or None if there is no common part. + """ + last = None + for x, y in zip(self.parts(), other.parts()): + if x != y: + return last + last = x + return last + + def __add__(self, other): + """Return new path object with 'other' added to the basename""" + return self.new(basename=self.basename + str(other)) + + def visit(self, fil=None, rec=None, ignore=NeverRaised, bf=False, sort=False): + """Yields all paths below the current one + + fil is a filter (glob pattern or callable), if not matching the + path will not be yielded, defaulting to None (everything is + returned) + + rec is a filter (glob pattern or callable) that controls whether + a node is descended, defaulting to None + + ignore is an Exception class that is ignoredwhen calling dirlist() + on any of the paths (by default, all exceptions are reported) + + bf if True will cause a breadthfirst search instead of the + default depthfirst. Default: False + + sort if True will sort entries within each directory level. + """ + yield from Visitor(fil, rec, ignore, bf, sort).gen(self) + + def _sortlist(self, res, sort): + if sort: + if hasattr(sort, "__call__"): + warnings.warn( + DeprecationWarning( + "listdir(sort=callable) is deprecated and breaks on python3" + ), + stacklevel=3, + ) + res.sort(sort) + else: + res.sort() + + def __fspath__(self): + return self.strpath + + def __hash__(self): + s = self.strpath + if iswin32: + s = s.lower() + return hash(s) + + def __eq__(self, other): + s1 = os.fspath(self) + try: + s2 = os.fspath(other) + except TypeError: + return False + if iswin32: + s1 = s1.lower() + try: + s2 = s2.lower() + except AttributeError: + return False + return s1 == s2 + + def __ne__(self, other): + return not (self == other) + + def __lt__(self, other): + return os.fspath(self) < os.fspath(other) + + def __gt__(self, other): + return os.fspath(self) > os.fspath(other) + + def samefile(self, other): + """Return True if 'other' references the same file as 'self'.""" + other = os.fspath(other) + if not isabs(other): + other = abspath(other) + if self == other: + return True + if not hasattr(os.path, "samefile"): + return False + return error.checked_call(os.path.samefile, self.strpath, other) + + def remove(self, rec=1, ignore_errors=False): + """Remove a file or directory (or a directory tree if rec=1). + if ignore_errors is True, errors while removing directories will + be ignored. + """ + if self.check(dir=1, link=0): + if rec: + # force remove of readonly files on windows + if iswin32: + self.chmod(0o700, rec=1) + import shutil + + error.checked_call( + shutil.rmtree, self.strpath, ignore_errors=ignore_errors + ) + else: + error.checked_call(os.rmdir, self.strpath) + else: + if iswin32: + self.chmod(0o700) + error.checked_call(os.remove, self.strpath) + + def computehash(self, hashtype="md5", chunksize=524288): + """Return hexdigest of hashvalue for this file.""" + try: + try: + import hashlib as mod + except ImportError: + if hashtype == "sha1": + hashtype = "sha" + mod = __import__(hashtype) + hash = getattr(mod, hashtype)() + except (AttributeError, ImportError): + raise ValueError(f"Don't know how to compute {hashtype!r} hash") + f = self.open("rb") + try: + while 1: + buf = f.read(chunksize) + if not buf: + return hash.hexdigest() + hash.update(buf) + finally: + f.close() + + def new(self, **kw): + """Create a modified version of this path. + the following keyword arguments modify various path parts:: + + a:/some/path/to/a/file.ext + xx drive + xxxxxxxxxxxxxxxxx dirname + xxxxxxxx basename + xxxx purebasename + xxx ext + """ + obj = object.__new__(self.__class__) + if not kw: + obj.strpath = self.strpath + return obj + drive, dirname, _basename, purebasename, ext = self._getbyspec( + "drive,dirname,basename,purebasename,ext" + ) + if "basename" in kw: + if "purebasename" in kw or "ext" in kw: + raise ValueError(f"invalid specification {kw!r}") + else: + pb = kw.setdefault("purebasename", purebasename) + try: + ext = kw["ext"] + except KeyError: + pass + else: + if ext and not ext.startswith("."): + ext = "." + ext + kw["basename"] = pb + ext + + if "dirname" in kw and not kw["dirname"]: + kw["dirname"] = drive + else: + kw.setdefault("dirname", dirname) + kw.setdefault("sep", self.sep) + obj.strpath = normpath("{dirname}{sep}{basename}".format(**kw)) + return obj + + def _getbyspec(self, spec: str) -> list[str]: + """See new for what 'spec' can be.""" + res = [] + parts = self.strpath.split(self.sep) + + args = filter(None, spec.split(",")) + for name in args: + if name == "drive": + res.append(parts[0]) + elif name == "dirname": + res.append(self.sep.join(parts[:-1])) + else: + basename = parts[-1] + if name == "basename": + res.append(basename) + else: + i = basename.rfind(".") + if i == -1: + purebasename, ext = basename, "" + else: + purebasename, ext = basename[:i], basename[i:] + if name == "purebasename": + res.append(purebasename) + elif name == "ext": + res.append(ext) + else: + raise ValueError(f"invalid part specification {name!r}") + return res + + def dirpath(self, *args, **kwargs): + """Return the directory path joined with any given path arguments.""" + if not kwargs: + path = object.__new__(self.__class__) + path.strpath = dirname(self.strpath) + if args: + path = path.join(*args) + return path + return self.new(basename="").join(*args, **kwargs) + + def join(self, *args: os.PathLike[str], abs: bool = False) -> LocalPath: + """Return a new path by appending all 'args' as path + components. if abs=1 is used restart from root if any + of the args is an absolute path. + """ + sep = self.sep + strargs = [os.fspath(arg) for arg in args] + strpath = self.strpath + if abs: + newargs: list[str] = [] + for arg in reversed(strargs): + if isabs(arg): + strpath = arg + strargs = newargs + break + newargs.insert(0, arg) + # special case for when we have e.g. strpath == "/" + actual_sep = "" if strpath.endswith(sep) else sep + for arg in strargs: + arg = arg.strip(sep) + if iswin32: + # allow unix style paths even on windows. + arg = arg.strip("/") + arg = arg.replace("/", sep) + strpath = strpath + actual_sep + arg + actual_sep = sep + obj = object.__new__(self.__class__) + obj.strpath = normpath(strpath) + return obj + + def open(self, mode="r", ensure=False, encoding=None): + """Return an opened file with the given mode. + + If ensure is True, create parent directories if needed. + """ + if ensure: + self.dirpath().ensure(dir=1) + if encoding: + return error.checked_call( + io.open, + self.strpath, + mode, + encoding=encoding, + ) + return error.checked_call(open, self.strpath, mode) + + def _fastjoin(self, name): + child = object.__new__(self.__class__) + child.strpath = self.strpath + self.sep + name + return child + + def islink(self): + return islink(self.strpath) + + def check(self, **kw): + """Check a path for existence and properties. + + Without arguments, return True if the path exists, otherwise False. + + valid checkers:: + + file = 1 # is a file + file = 0 # is not a file (may not even exist) + dir = 1 # is a dir + link = 1 # is a link + exists = 1 # exists + + You can specify multiple checker definitions, for example:: + + path.check(file=1, link=1) # a link pointing to a file + """ + if not kw: + return exists(self.strpath) + if len(kw) == 1: + if "dir" in kw: + return not kw["dir"] ^ isdir(self.strpath) + if "file" in kw: + return not kw["file"] ^ isfile(self.strpath) + if not kw: + kw = {"exists": 1} + return Checkers(self)._evaluate(kw) + + _patternchars = set("*?[" + os.sep) + + def listdir(self, fil=None, sort=None): + """List directory contents, possibly filter by the given fil func + and possibly sorted. + """ + if fil is None and sort is None: + names = error.checked_call(os.listdir, self.strpath) + return map_as_list(self._fastjoin, names) + if isinstance(fil, str): + if not self._patternchars.intersection(fil): + child = self._fastjoin(fil) + if exists(child.strpath): + return [child] + return [] + fil = FNMatcher(fil) + names = error.checked_call(os.listdir, self.strpath) + res = [] + for name in names: + child = self._fastjoin(name) + if fil is None or fil(child): + res.append(child) + self._sortlist(res, sort) + return res + + def size(self) -> int: + """Return size of the underlying file object""" + return self.stat().size + + def mtime(self) -> float: + """Return last modification time of the path.""" + return self.stat().mtime + + def copy(self, target, mode=False, stat=False): + """Copy path to target. + + If mode is True, will copy permission from path to target. + If stat is True, copy permission, last modification + time, last access time, and flags from path to target. + """ + if self.check(file=1): + if target.check(dir=1): + target = target.join(self.basename) + assert self != target + copychunked(self, target) + if mode: + copymode(self.strpath, target.strpath) + if stat: + copystat(self, target) + else: + + def rec(p): + return p.check(link=0) + + for x in self.visit(rec=rec): + relpath = x.relto(self) + newx = target.join(relpath) + newx.dirpath().ensure(dir=1) + if x.check(link=1): + newx.mksymlinkto(x.readlink()) + continue + elif x.check(file=1): + copychunked(x, newx) + elif x.check(dir=1): + newx.ensure(dir=1) + if mode: + copymode(x.strpath, newx.strpath) + if stat: + copystat(x, newx) + + def rename(self, target): + """Rename this path to target.""" + target = os.fspath(target) + return error.checked_call(os.rename, self.strpath, target) + + def dump(self, obj, bin=1): + """Pickle object into path location""" + f = self.open("wb") + import pickle + + try: + error.checked_call(pickle.dump, obj, f, bin) + finally: + f.close() + + def mkdir(self, *args): + """Create & return the directory joined with args.""" + p = self.join(*args) + error.checked_call(os.mkdir, os.fspath(p)) + return p + + def write_binary(self, data, ensure=False): + """Write binary data into path. If ensure is True create + missing parent directories. + """ + if ensure: + self.dirpath().ensure(dir=1) + with self.open("wb") as f: + f.write(data) + + def write_text(self, data, encoding, ensure=False): + """Write text data into path using the specified encoding. + If ensure is True create missing parent directories. + """ + if ensure: + self.dirpath().ensure(dir=1) + with self.open("w", encoding=encoding) as f: + f.write(data) + + def write(self, data, mode="w", ensure=False): + """Write data into path. If ensure is True create + missing parent directories. + """ + if ensure: + self.dirpath().ensure(dir=1) + if "b" in mode: + if not isinstance(data, bytes): + raise ValueError("can only process bytes") + else: + if not isinstance(data, str): + if not isinstance(data, bytes): + data = str(data) + else: + data = data.decode(sys.getdefaultencoding()) + f = self.open(mode) + try: + f.write(data) + finally: + f.close() + + def _ensuredirs(self): + parent = self.dirpath() + if parent == self: + return self + if parent.check(dir=0): + parent._ensuredirs() + if self.check(dir=0): + try: + self.mkdir() + except error.EEXIST: + # race condition: file/dir created by another thread/process. + # complain if it is not a dir + if self.check(dir=0): + raise + return self + + def ensure(self, *args, **kwargs): + """Ensure that an args-joined path exists (by default as + a file). if you specify a keyword argument 'dir=True' + then the path is forced to be a directory path. + """ + p = self.join(*args) + if kwargs.get("dir", 0): + return p._ensuredirs() + else: + p.dirpath()._ensuredirs() + if not p.check(file=1): + p.open("wb").close() + return p + + @overload + def stat(self, raising: Literal[True] = ...) -> Stat: ... + + @overload + def stat(self, raising: Literal[False]) -> Stat | None: ... + + def stat(self, raising: bool = True) -> Stat | None: + """Return an os.stat() tuple.""" + if raising: + return Stat(self, error.checked_call(os.stat, self.strpath)) + try: + return Stat(self, os.stat(self.strpath)) + except KeyboardInterrupt: + raise + except Exception: + return None + + def lstat(self) -> Stat: + """Return an os.lstat() tuple.""" + return Stat(self, error.checked_call(os.lstat, self.strpath)) + + def setmtime(self, mtime=None): + """Set modification time for the given path. if 'mtime' is None + (the default) then the file's mtime is set to current time. + + Note that the resolution for 'mtime' is platform dependent. + """ + if mtime is None: + return error.checked_call(os.utime, self.strpath, mtime) + try: + return error.checked_call(os.utime, self.strpath, (-1, mtime)) + except error.EINVAL: + return error.checked_call(os.utime, self.strpath, (self.atime(), mtime)) + + def chdir(self): + """Change directory to self and return old current directory""" + try: + old = self.__class__() + except error.ENOENT: + old = None + error.checked_call(os.chdir, self.strpath) + return old + + @contextmanager + def as_cwd(self): + """ + Return a context manager, which changes to the path's dir during the + managed "with" context. + On __enter__ it returns the old dir, which might be ``None``. + """ + old = self.chdir() + try: + yield old + finally: + if old is not None: + old.chdir() + + def realpath(self): + """Return a new path which contains no symbolic links.""" + return self.__class__(os.path.realpath(self.strpath)) + + def atime(self): + """Return last access time of the path.""" + return self.stat().atime + + def __repr__(self): + return f"local({self.strpath!r})" + + def __str__(self): + """Return string representation of the Path.""" + return self.strpath + + def chmod(self, mode, rec=0): + """Change permissions to the given mode. If mode is an + integer it directly encodes the os-specific modes. + if rec is True perform recursively. + """ + if not isinstance(mode, int): + raise TypeError(f"mode {mode!r} must be an integer") + if rec: + for x in self.visit(rec=rec): + error.checked_call(os.chmod, str(x), mode) + error.checked_call(os.chmod, self.strpath, mode) + + def pypkgpath(self): + """Return the Python package path by looking for the last + directory upwards which still contains an __init__.py. + Return None if a pkgpath cannot be determined. + """ + pkgpath = None + for parent in self.parts(reverse=True): + if parent.isdir(): + if not parent.join("__init__.py").exists(): + break + if not isimportable(parent.basename): + break + pkgpath = parent + return pkgpath + + def _ensuresyspath(self, ensuremode, path): + if ensuremode: + s = str(path) + if ensuremode == "append": + if s not in sys.path: + sys.path.append(s) + else: + if s != sys.path[0]: + sys.path.insert(0, s) + + def pyimport(self, modname=None, ensuresyspath=True): + """Return path as an imported python module. + + If modname is None, look for the containing package + and construct an according module name. + The module will be put/looked up in sys.modules. + if ensuresyspath is True then the root dir for importing + the file (taking __init__.py files into account) will + be prepended to sys.path if it isn't there already. + If ensuresyspath=="append" the root dir will be appended + if it isn't already contained in sys.path. + if ensuresyspath is False no modification of syspath happens. + + Special value of ensuresyspath=="importlib" is intended + purely for using in pytest, it is capable only of importing + separate .py files outside packages, e.g. for test suite + without any __init__.py file. It effectively allows having + same-named test modules in different places and offers + mild opt-in via this option. Note that it works only in + recent versions of python. + """ + if not self.check(): + raise error.ENOENT(self) + + if ensuresyspath == "importlib": + if modname is None: + modname = self.purebasename + spec = importlib.util.spec_from_file_location(modname, str(self)) + if spec is None or spec.loader is None: + raise ImportError(f"Can't find module {modname} at location {self!s}") + mod = importlib.util.module_from_spec(spec) + spec.loader.exec_module(mod) + return mod + + pkgpath = None + if modname is None: + pkgpath = self.pypkgpath() + if pkgpath is not None: + pkgroot = pkgpath.dirpath() + names = self.new(ext="").relto(pkgroot).split(self.sep) + if names[-1] == "__init__": + names.pop() + modname = ".".join(names) + else: + pkgroot = self.dirpath() + modname = self.purebasename + + self._ensuresyspath(ensuresyspath, pkgroot) + __import__(modname) + mod = sys.modules[modname] + if self.basename == "__init__.py": + return mod # we don't check anything as we might + # be in a namespace package ... too icky to check + modfile = mod.__file__ + assert modfile is not None + if modfile[-4:] in (".pyc", ".pyo"): + modfile = modfile[:-1] + elif modfile.endswith("$py.class"): + modfile = modfile[:-9] + ".py" + if modfile.endswith(os.sep + "__init__.py"): + if self.basename != "__init__.py": + modfile = modfile[:-12] + try: + issame = self.samefile(modfile) + except error.ENOENT: + issame = False + if not issame: + ignore = os.getenv("PY_IGNORE_IMPORTMISMATCH") + if ignore != "1": + raise self.ImportMismatchError(modname, modfile, self) + return mod + else: + try: + return sys.modules[modname] + except KeyError: + # we have a custom modname, do a pseudo-import + import types + + mod = types.ModuleType(modname) + mod.__file__ = str(self) + sys.modules[modname] = mod + try: + with open(str(self), "rb") as f: + exec(f.read(), mod.__dict__) + except BaseException: + del sys.modules[modname] + raise + return mod + + def sysexec(self, *argv: os.PathLike[str], **popen_opts: Any) -> str: + """Return stdout text from executing a system child process, + where the 'self' path points to executable. + The process is directly invoked and not through a system shell. + """ + from subprocess import PIPE + from subprocess import Popen + + popen_opts.pop("stdout", None) + popen_opts.pop("stderr", None) + proc = Popen( + [str(self)] + [str(arg) for arg in argv], + **popen_opts, + stdout=PIPE, + stderr=PIPE, + ) + stdout: str | bytes + stdout, stderr = proc.communicate() + ret = proc.wait() + if isinstance(stdout, bytes): + stdout = stdout.decode(sys.getdefaultencoding()) + if ret != 0: + if isinstance(stderr, bytes): + stderr = stderr.decode(sys.getdefaultencoding()) + raise RuntimeError( + ret, + ret, + str(self), + stdout, + stderr, + ) + return stdout + + @classmethod + def sysfind(cls, name, checker=None, paths=None): + """Return a path object found by looking at the systems + underlying PATH specification. If the checker is not None + it will be invoked to filter matching paths. If a binary + cannot be found, None is returned + Note: This is probably not working on plain win32 systems + but may work on cygwin. + """ + if isabs(name): + p = local(name) + if p.check(file=1): + return p + else: + if paths is None: + if iswin32: + paths = os.environ["Path"].split(";") + if "" not in paths and "." not in paths: + paths.append(".") + try: + systemroot = os.environ["SYSTEMROOT"] + except KeyError: + pass + else: + paths = [ + path.replace("%SystemRoot%", systemroot) for path in paths + ] + else: + paths = os.environ["PATH"].split(":") + tryadd = [] + if iswin32: + tryadd += os.environ["PATHEXT"].split(os.pathsep) + tryadd.append("") + + for x in paths: + for addext in tryadd: + p = local(x).join(name, abs=True) + addext + try: + if p.check(file=1): + if checker: + if not checker(p): + continue + return p + except error.EACCES: + pass + return None + + @classmethod + def _gethomedir(cls): + try: + x = os.environ["HOME"] + except KeyError: + try: + x = os.environ["HOMEDRIVE"] + os.environ["HOMEPATH"] + except KeyError: + return None + return cls(x) + + # """ + # special class constructors for local filesystem paths + # """ + @classmethod + def get_temproot(cls): + """Return the system's temporary directory + (where tempfiles are usually created in) + """ + import tempfile + + return local(tempfile.gettempdir()) + + @classmethod + def mkdtemp(cls, rootdir=None): + """Return a Path object pointing to a fresh new temporary directory + (which we created ourselves). + """ + import tempfile + + if rootdir is None: + rootdir = cls.get_temproot() + path = error.checked_call(tempfile.mkdtemp, dir=str(rootdir)) + return cls(path) + + @classmethod + def make_numbered_dir( + cls, prefix="session-", rootdir=None, keep=3, lock_timeout=172800 + ): # two days + """Return unique directory with a number greater than the current + maximum one. The number is assumed to start directly after prefix. + if keep is true directories with a number less than (maxnum-keep) + will be removed. If .lock files are used (lock_timeout non-zero), + algorithm is multi-process safe. + """ + if rootdir is None: + rootdir = cls.get_temproot() + + nprefix = prefix.lower() + + def parse_num(path): + """Parse the number out of a path (if it matches the prefix)""" + nbasename = path.basename.lower() + if nbasename.startswith(nprefix): + try: + return int(nbasename[len(nprefix) :]) + except ValueError: + pass + + def create_lockfile(path): + """Exclusively create lockfile. Throws when failed""" + mypid = os.getpid() + lockfile = path.join(".lock") + if hasattr(lockfile, "mksymlinkto"): + lockfile.mksymlinkto(str(mypid)) + else: + fd = error.checked_call( + os.open, str(lockfile), os.O_WRONLY | os.O_CREAT | os.O_EXCL, 0o644 + ) + with os.fdopen(fd, "w") as f: + f.write(str(mypid)) + return lockfile + + def atexit_remove_lockfile(lockfile): + """Ensure lockfile is removed at process exit""" + mypid = os.getpid() + + def try_remove_lockfile(): + # in a fork() situation, only the last process should + # remove the .lock, otherwise the other processes run the + # risk of seeing their temporary dir disappear. For now + # we remove the .lock in the parent only (i.e. we assume + # that the children finish before the parent). + if os.getpid() != mypid: + return + try: + lockfile.remove() + except error.Error: + pass + + atexit.register(try_remove_lockfile) + + # compute the maximum number currently in use with the prefix + lastmax = None + while True: + maxnum = -1 + for path in rootdir.listdir(): + num = parse_num(path) + if num is not None: + maxnum = max(maxnum, num) + + # make the new directory + try: + udir = rootdir.mkdir(prefix + str(maxnum + 1)) + if lock_timeout: + lockfile = create_lockfile(udir) + atexit_remove_lockfile(lockfile) + except (error.EEXIST, error.ENOENT, error.EBUSY): + # race condition (1): another thread/process created the dir + # in the meantime - try again + # race condition (2): another thread/process spuriously acquired + # lock treating empty directory as candidate + # for removal - try again + # race condition (3): another thread/process tried to create the lock at + # the same time (happened in Python 3.3 on Windows) + # https://ci.appveyor.com/project/pytestbot/py/build/1.0.21/job/ffi85j4c0lqwsfwa + if lastmax == maxnum: + raise + lastmax = maxnum + continue + break + + def get_mtime(path): + """Read file modification time""" + try: + return path.lstat().mtime + except error.Error: + pass + + garbage_prefix = prefix + "garbage-" + + def is_garbage(path): + """Check if path denotes directory scheduled for removal""" + bn = path.basename + return bn.startswith(garbage_prefix) + + # prune old directories + udir_time = get_mtime(udir) + if keep and udir_time: + for path in rootdir.listdir(): + num = parse_num(path) + if num is not None and num <= (maxnum - keep): + try: + # try acquiring lock to remove directory as exclusive user + if lock_timeout: + create_lockfile(path) + except (error.EEXIST, error.ENOENT, error.EBUSY): + path_time = get_mtime(path) + if not path_time: + # assume directory doesn't exist now + continue + if abs(udir_time - path_time) < lock_timeout: + # assume directory with lockfile exists + # and lock timeout hasn't expired yet + continue + + # path dir locked for exclusive use + # and scheduled for removal to avoid another thread/process + # treating it as a new directory or removal candidate + garbage_path = rootdir.join(garbage_prefix + str(uuid.uuid4())) + try: + path.rename(garbage_path) + garbage_path.remove(rec=1) + except KeyboardInterrupt: + raise + except Exception: # this might be error.Error, WindowsError ... + pass + if is_garbage(path): + try: + path.remove(rec=1) + except KeyboardInterrupt: + raise + except Exception: # this might be error.Error, WindowsError ... + pass + + # make link... + try: + username = os.environ["USER"] # linux, et al + except KeyError: + try: + username = os.environ["USERNAME"] # windows + except KeyError: + username = "current" + + src = str(udir) + dest = src[: src.rfind("-")] + "-" + username + try: + os.unlink(dest) + except OSError: + pass + try: + os.symlink(src, dest) + except (OSError, AttributeError, NotImplementedError): + pass + + return udir + + +def copymode(src, dest): + """Copy permission from src to dst.""" + import shutil + + shutil.copymode(src, dest) + + +def copystat(src, dest): + """Copy permission, last modification time, + last access time, and flags from src to dst.""" + import shutil + + shutil.copystat(str(src), str(dest)) + + +def copychunked(src, dest): + chunksize = 524288 # half a meg of bytes + fsrc = src.open("rb") + try: + fdest = dest.open("wb") + try: + while 1: + buf = fsrc.read(chunksize) + if not buf: + break + fdest.write(buf) + finally: + fdest.close() + finally: + fsrc.close() + + +def isimportable(name): + if name and (name[0].isalpha() or name[0] == "_"): + name = name.replace("_", "") + return not name or name.isalnum() + + +local = LocalPath diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_version.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_version.py new file mode 100644 index 0000000000000000000000000000000000000000..0930b266b8883643205c8fdefc2af18ae936f19e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/_version.py @@ -0,0 +1,34 @@ +# file generated by setuptools-scm +# don't change, don't track in version control + +__all__ = [ + "__version__", + "__version_tuple__", + "version", + "version_tuple", + "__commit_id__", + "commit_id", +] + +TYPE_CHECKING = False +if TYPE_CHECKING: + from typing import Tuple + from typing import Union + + VERSION_TUPLE = Tuple[Union[int, str], ...] + COMMIT_ID = Union[str, None] +else: + VERSION_TUPLE = object + COMMIT_ID = object + +version: str +__version__: str +__version_tuple__: VERSION_TUPLE +version_tuple: VERSION_TUPLE +commit_id: COMMIT_ID +__commit_id__: COMMIT_ID + +__version__ = version = '9.0.3' +__version_tuple__ = version_tuple = (9, 0, 3) + +__commit_id__ = commit_id = None diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/assertion/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/assertion/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..22f3ca8e258cc48effeb34154821f8b1e5cf151b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/assertion/__init__.py @@ -0,0 +1,208 @@ +# mypy: allow-untyped-defs +"""Support for presenting detailed information in failing assertions.""" + +from __future__ import annotations + +from collections.abc import Generator +import sys +from typing import Any +from typing import Protocol +from typing import TYPE_CHECKING + +from _pytest.assertion import rewrite +from _pytest.assertion import truncate +from _pytest.assertion import util +from _pytest.assertion.rewrite import assertstate_key +from _pytest.config import Config +from _pytest.config import hookimpl +from _pytest.config.argparsing import Parser +from _pytest.nodes import Item + + +if TYPE_CHECKING: + from _pytest.main import Session + + +def pytest_addoption(parser: Parser) -> None: + group = parser.getgroup("debugconfig") + group.addoption( + "--assert", + action="store", + dest="assertmode", + choices=("rewrite", "plain"), + default="rewrite", + metavar="MODE", + help=( + "Control assertion debugging tools.\n" + "'plain' performs no assertion debugging.\n" + "'rewrite' (the default) rewrites assert statements in test modules" + " on import to provide assert expression information." + ), + ) + parser.addini( + "enable_assertion_pass_hook", + type="bool", + default=False, + help="Enables the pytest_assertion_pass hook. " + "Make sure to delete any previously generated pyc cache files.", + ) + + parser.addini( + "truncation_limit_lines", + default=None, + help="Set threshold of LINES after which truncation will take effect", + ) + parser.addini( + "truncation_limit_chars", + default=None, + help=("Set threshold of CHARS after which truncation will take effect"), + ) + + Config._add_verbosity_ini( + parser, + Config.VERBOSITY_ASSERTIONS, + help=( + "Specify a verbosity level for assertions, overriding the main level. " + "Higher levels will provide more detailed explanation when an assertion fails." + ), + ) + + +def register_assert_rewrite(*names: str) -> None: + """Register one or more module names to be rewritten on import. + + This function will make sure that this module or all modules inside + the package will get their assert statements rewritten. + Thus you should make sure to call this before the module is + actually imported, usually in your __init__.py if you are a plugin + using a package. + + :param names: The module names to register. + """ + for name in names: + if not isinstance(name, str): + msg = "expected module names as *args, got {0} instead" # type: ignore[unreachable] + raise TypeError(msg.format(repr(names))) + rewrite_hook: RewriteHook + for hook in sys.meta_path: + if isinstance(hook, rewrite.AssertionRewritingHook): + rewrite_hook = hook + break + else: + rewrite_hook = DummyRewriteHook() + rewrite_hook.mark_rewrite(*names) + + +class RewriteHook(Protocol): + def mark_rewrite(self, *names: str) -> None: ... + + +class DummyRewriteHook: + """A no-op import hook for when rewriting is disabled.""" + + def mark_rewrite(self, *names: str) -> None: + pass + + +class AssertionState: + """State for the assertion plugin.""" + + def __init__(self, config: Config, mode) -> None: + self.mode = mode + self.trace = config.trace.root.get("assertion") + self.hook: rewrite.AssertionRewritingHook | None = None + + +def install_importhook(config: Config) -> rewrite.AssertionRewritingHook: + """Try to install the rewrite hook, raise SystemError if it fails.""" + config.stash[assertstate_key] = AssertionState(config, "rewrite") + config.stash[assertstate_key].hook = hook = rewrite.AssertionRewritingHook(config) + sys.meta_path.insert(0, hook) + config.stash[assertstate_key].trace("installed rewrite import hook") + + def undo() -> None: + hook = config.stash[assertstate_key].hook + if hook is not None and hook in sys.meta_path: + sys.meta_path.remove(hook) + + config.add_cleanup(undo) + return hook + + +def pytest_collection(session: Session) -> None: + # This hook is only called when test modules are collected + # so for example not in the managing process of pytest-xdist + # (which does not collect test modules). + assertstate = session.config.stash.get(assertstate_key, None) + if assertstate: + if assertstate.hook is not None: + assertstate.hook.set_session(session) + + +@hookimpl(wrapper=True, tryfirst=True) +def pytest_runtest_protocol(item: Item) -> Generator[None, object, object]: + """Setup the pytest_assertrepr_compare and pytest_assertion_pass hooks. + + The rewrite module will use util._reprcompare if it exists to use custom + reporting via the pytest_assertrepr_compare hook. This sets up this custom + comparison for the test. + """ + ihook = item.ihook + + def callbinrepr(op, left: object, right: object) -> str | None: + """Call the pytest_assertrepr_compare hook and prepare the result. + + This uses the first result from the hook and then ensures the + following: + * Overly verbose explanations are truncated unless configured otherwise + (eg. if running in verbose mode). + * Embedded newlines are escaped to help util.format_explanation() + later. + * If the rewrite mode is used embedded %-characters are replaced + to protect later % formatting. + + The result can be formatted by util.format_explanation() for + pretty printing. + """ + hook_result = ihook.pytest_assertrepr_compare( + config=item.config, op=op, left=left, right=right + ) + for new_expl in hook_result: + if new_expl: + new_expl = truncate.truncate_if_required(new_expl, item) + new_expl = [line.replace("\n", "\\n") for line in new_expl] + res = "\n~".join(new_expl) + if item.config.getvalue("assertmode") == "rewrite": + res = res.replace("%", "%%") + return res + return None + + saved_assert_hooks = util._reprcompare, util._assertion_pass + util._reprcompare = callbinrepr + util._config = item.config + + if ihook.pytest_assertion_pass.get_hookimpls(): + + def call_assertion_pass_hook(lineno: int, orig: str, expl: str) -> None: + ihook.pytest_assertion_pass(item=item, lineno=lineno, orig=orig, expl=expl) + + util._assertion_pass = call_assertion_pass_hook + + try: + return (yield) + finally: + util._reprcompare, util._assertion_pass = saved_assert_hooks + util._config = None + + +def pytest_sessionfinish(session: Session) -> None: + assertstate = session.config.stash.get(assertstate_key, None) + if assertstate: + if assertstate.hook is not None: + assertstate.hook.set_session(None) + + +def pytest_assertrepr_compare( + config: Config, op: str, left: Any, right: Any +) -> list[str] | None: + return util.assertrepr_compare(config=config, op=op, left=left, right=right) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/assertion/rewrite.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/assertion/rewrite.py new file mode 100644 index 0000000000000000000000000000000000000000..566549d66f25dfe9f144cb451f370da2635c1072 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/assertion/rewrite.py @@ -0,0 +1,1202 @@ +"""Rewrite assertion AST to produce nice error messages.""" + +from __future__ import annotations + +import ast +from collections import defaultdict +from collections.abc import Callable +from collections.abc import Iterable +from collections.abc import Iterator +from collections.abc import Sequence +import errno +import functools +import importlib.abc +import importlib.machinery +import importlib.util +import io +import itertools +import marshal +import os +from pathlib import Path +from pathlib import PurePath +import struct +import sys +import tokenize +import types +from typing import IO +from typing import TYPE_CHECKING + + +if sys.version_info >= (3, 12): + from importlib.resources.abc import TraversableResources +else: + from importlib.abc import TraversableResources +if sys.version_info < (3, 11): + from importlib.readers import FileReader +else: + from importlib.resources.readers import FileReader + + +from _pytest._io.saferepr import DEFAULT_REPR_MAX_SIZE +from _pytest._io.saferepr import saferepr +from _pytest._io.saferepr import saferepr_unlimited +from _pytest._version import version +from _pytest.assertion import util +from _pytest.config import Config +from _pytest.fixtures import FixtureFunctionDefinition +from _pytest.main import Session +from _pytest.pathlib import absolutepath +from _pytest.pathlib import fnmatch_ex +from _pytest.stash import StashKey + + +# fmt: off +from _pytest.assertion.util import format_explanation as _format_explanation # noqa:F401, isort:skip +# fmt:on + +if TYPE_CHECKING: + from _pytest.assertion import AssertionState + + +class Sentinel: + pass + + +assertstate_key = StashKey["AssertionState"]() + +# pytest caches rewritten pycs in pycache dirs +PYTEST_TAG = f"{sys.implementation.cache_tag}-pytest-{version}" +PYC_EXT = ".py" + ((__debug__ and "c") or "o") +PYC_TAIL = "." + PYTEST_TAG + PYC_EXT + +# Special marker that denotes we have just left a scope definition +_SCOPE_END_MARKER = Sentinel() + + +class AssertionRewritingHook(importlib.abc.MetaPathFinder, importlib.abc.Loader): + """PEP302/PEP451 import hook which rewrites asserts.""" + + def __init__(self, config: Config) -> None: + self.config = config + try: + self.fnpats = config.getini("python_files") + except ValueError: + self.fnpats = ["test_*.py", "*_test.py"] + self.session: Session | None = None + self._rewritten_names: dict[str, Path] = {} + self._must_rewrite: set[str] = set() + # flag to guard against trying to rewrite a pyc file while we are already writing another pyc file, + # which might result in infinite recursion (#3506) + self._writing_pyc = False + self._basenames_to_check_rewrite = {"conftest"} + self._marked_for_rewrite_cache: dict[str, bool] = {} + self._session_paths_checked = False + + def set_session(self, session: Session | None) -> None: + self.session = session + self._session_paths_checked = False + + # Indirection so we can mock calls to find_spec originated from the hook during testing + _find_spec = importlib.machinery.PathFinder.find_spec + + def find_spec( + self, + name: str, + path: Sequence[str | bytes] | None = None, + target: types.ModuleType | None = None, + ) -> importlib.machinery.ModuleSpec | None: + if self._writing_pyc: + return None + state = self.config.stash[assertstate_key] + if self._early_rewrite_bailout(name, state): + return None + state.trace(f"find_module called for: {name}") + + # Type ignored because mypy is confused about the `self` binding here. + spec = self._find_spec(name, path) # type: ignore + + if spec is None and path is not None: + # With --import-mode=importlib, PathFinder cannot find spec without modifying `sys.path`, + # causing inability to assert rewriting (#12659). + # At this point, try using the file path to find the module spec. + for _path_str in path: + spec = importlib.util.spec_from_file_location(name, _path_str) + if spec is not None: + break + + if ( + # the import machinery could not find a file to import + spec is None + # this is a namespace package (without `__init__.py`) + # there's nothing to rewrite there + or spec.origin is None + # we can only rewrite source files + or not isinstance(spec.loader, importlib.machinery.SourceFileLoader) + # if the file doesn't exist, we can't rewrite it + or not os.path.exists(spec.origin) + ): + return None + else: + fn = spec.origin + + if not self._should_rewrite(name, fn, state): + return None + + return importlib.util.spec_from_file_location( + name, + fn, + loader=self, + submodule_search_locations=spec.submodule_search_locations, + ) + + def create_module( + self, spec: importlib.machinery.ModuleSpec + ) -> types.ModuleType | None: + return None # default behaviour is fine + + def exec_module(self, module: types.ModuleType) -> None: + assert module.__spec__ is not None + assert module.__spec__.origin is not None + fn = Path(module.__spec__.origin) + state = self.config.stash[assertstate_key] + + self._rewritten_names[module.__name__] = fn + + # The requested module looks like a test file, so rewrite it. This is + # the most magical part of the process: load the source, rewrite the + # asserts, and load the rewritten source. We also cache the rewritten + # module code in a special pyc. We must be aware of the possibility of + # concurrent pytest processes rewriting and loading pycs. To avoid + # tricky race conditions, we maintain the following invariant: The + # cached pyc is always a complete, valid pyc. Operations on it must be + # atomic. POSIX's atomic rename comes in handy. + write = not sys.dont_write_bytecode + cache_dir = get_cache_dir(fn) + if write: + ok = try_makedirs(cache_dir) + if not ok: + write = False + state.trace(f"read only directory: {cache_dir}") + + cache_name = fn.name[:-3] + PYC_TAIL + pyc = cache_dir / cache_name + # Notice that even if we're in a read-only directory, I'm going + # to check for a cached pyc. This may not be optimal... + co = _read_pyc(fn, pyc, state.trace) + if co is None: + state.trace(f"rewriting {fn!r}") + source_stat, co = _rewrite_test(fn, self.config) + if write: + self._writing_pyc = True + try: + _write_pyc(state, co, source_stat, pyc) + finally: + self._writing_pyc = False + else: + state.trace(f"found cached rewritten pyc for {fn}") + exec(co, module.__dict__) + + def _early_rewrite_bailout(self, name: str, state: AssertionState) -> bool: + """A fast way to get out of rewriting modules. + + Profiling has shown that the call to PathFinder.find_spec (inside of + the find_spec from this class) is a major slowdown, so, this method + tries to filter what we're sure won't be rewritten before getting to + it. + """ + if self.session is not None and not self._session_paths_checked: + self._session_paths_checked = True + for initial_path in self.session._initialpaths: + # Make something as c:/projects/my_project/path.py -> + # ['c:', 'projects', 'my_project', 'path.py'] + parts = str(initial_path).split(os.sep) + # add 'path' to basenames to be checked. + self._basenames_to_check_rewrite.add(os.path.splitext(parts[-1])[0]) + + # Note: conftest already by default in _basenames_to_check_rewrite. + parts = name.split(".") + if parts[-1] in self._basenames_to_check_rewrite: + return False + + # For matching the name it must be as if it was a filename. + path = PurePath(*parts).with_suffix(".py") + + for pat in self.fnpats: + # if the pattern contains subdirectories ("tests/**.py" for example) we can't bail out based + # on the name alone because we need to match against the full path + if os.path.dirname(pat): + return False + if fnmatch_ex(pat, path): + return False + + if self._is_marked_for_rewrite(name, state): + return False + + state.trace(f"early skip of rewriting module: {name}") + return True + + def _should_rewrite(self, name: str, fn: str, state: AssertionState) -> bool: + # always rewrite conftest files + if os.path.basename(fn) == "conftest.py": + state.trace(f"rewriting conftest file: {fn!r}") + return True + + if self.session is not None: + if self.session.isinitpath(absolutepath(fn)): + state.trace(f"matched test file (was specified on cmdline): {fn!r}") + return True + + # modules not passed explicitly on the command line are only + # rewritten if they match the naming convention for test files + fn_path = PurePath(fn) + for pat in self.fnpats: + if fnmatch_ex(pat, fn_path): + state.trace(f"matched test file {fn!r}") + return True + + return self._is_marked_for_rewrite(name, state) + + def _is_marked_for_rewrite(self, name: str, state: AssertionState) -> bool: + try: + return self._marked_for_rewrite_cache[name] + except KeyError: + for marked in self._must_rewrite: + if name == marked or name.startswith(marked + "."): + state.trace(f"matched marked file {name!r} (from {marked!r})") + self._marked_for_rewrite_cache[name] = True + return True + + self._marked_for_rewrite_cache[name] = False + return False + + def mark_rewrite(self, *names: str) -> None: + """Mark import names as needing to be rewritten. + + The named module or package as well as any nested modules will + be rewritten on import. + """ + already_imported = ( + set(names).intersection(sys.modules).difference(self._rewritten_names) + ) + for name in already_imported: + mod = sys.modules[name] + if not AssertionRewriter.is_rewrite_disabled( + mod.__doc__ or "" + ) and not isinstance(mod.__loader__, type(self)): + self._warn_already_imported(name) + self._must_rewrite.update(names) + self._marked_for_rewrite_cache.clear() + + def _warn_already_imported(self, name: str) -> None: + from _pytest.warning_types import PytestAssertRewriteWarning + + self.config.issue_config_time_warning( + PytestAssertRewriteWarning( + f"Module already imported so cannot be rewritten; {name}" + ), + stacklevel=5, + ) + + def get_data(self, pathname: str | bytes) -> bytes: + """Optional PEP302 get_data API.""" + with open(pathname, "rb") as f: + return f.read() + + def get_resource_reader(self, name: str) -> TraversableResources: + return FileReader(types.SimpleNamespace(path=self._rewritten_names[name])) # type: ignore[arg-type] + + +def _write_pyc_fp( + fp: IO[bytes], source_stat: os.stat_result, co: types.CodeType +) -> None: + # Technically, we don't have to have the same pyc format as + # (C)Python, since these "pycs" should never be seen by builtin + # import. However, there's little reason to deviate. + fp.write(importlib.util.MAGIC_NUMBER) + # https://www.python.org/dev/peps/pep-0552/ + flags = b"\x00\x00\x00\x00" + fp.write(flags) + # as of now, bytecode header expects 32-bit numbers for size and mtime (#4903) + mtime = int(source_stat.st_mtime) & 0xFFFFFFFF + size = source_stat.st_size & 0xFFFFFFFF + # "<LL" stands for 2 unsigned longs, little-endian. + fp.write(struct.pack("<LL", mtime, size)) + fp.write(marshal.dumps(co)) + + +def _write_pyc( + state: AssertionState, + co: types.CodeType, + source_stat: os.stat_result, + pyc: Path, +) -> bool: + proc_pyc = f"{pyc}.{os.getpid()}" + try: + with open(proc_pyc, "wb") as fp: + _write_pyc_fp(fp, source_stat, co) + except OSError as e: + state.trace(f"error writing pyc file at {proc_pyc}: errno={e.errno}") + return False + + try: + os.replace(proc_pyc, pyc) + except OSError as e: + state.trace(f"error writing pyc file at {pyc}: {e}") + # we ignore any failure to write the cache file + # there are many reasons, permission-denied, pycache dir being a + # file etc. + return False + return True + + +def _rewrite_test(fn: Path, config: Config) -> tuple[os.stat_result, types.CodeType]: + """Read and rewrite *fn* and return the code object.""" + stat = os.stat(fn) + source = fn.read_bytes() + strfn = str(fn) + tree = ast.parse(source, filename=strfn) + rewrite_asserts(tree, source, strfn, config) + co = compile(tree, strfn, "exec", dont_inherit=True) + return stat, co + + +def _read_pyc( + source: Path, pyc: Path, trace: Callable[[str], None] = lambda x: None +) -> types.CodeType | None: + """Possibly read a pytest pyc containing rewritten code. + + Return rewritten code if successful or None if not. + """ + try: + fp = open(pyc, "rb") + except OSError: + return None + with fp: + try: + stat_result = os.stat(source) + mtime = int(stat_result.st_mtime) + size = stat_result.st_size + data = fp.read(16) + except OSError as e: + trace(f"_read_pyc({source}): OSError {e}") + return None + # Check for invalid or out of date pyc file. + if len(data) != (16): + trace(f"_read_pyc({source}): invalid pyc (too short)") + return None + if data[:4] != importlib.util.MAGIC_NUMBER: + trace(f"_read_pyc({source}): invalid pyc (bad magic number)") + return None + if data[4:8] != b"\x00\x00\x00\x00": + trace(f"_read_pyc({source}): invalid pyc (unsupported flags)") + return None + mtime_data = data[8:12] + if int.from_bytes(mtime_data, "little") != mtime & 0xFFFFFFFF: + trace(f"_read_pyc({source}): out of date") + return None + size_data = data[12:16] + if int.from_bytes(size_data, "little") != size & 0xFFFFFFFF: + trace(f"_read_pyc({source}): invalid pyc (incorrect size)") + return None + try: + co = marshal.load(fp) + except Exception as e: + trace(f"_read_pyc({source}): marshal.load error {e}") + return None + if not isinstance(co, types.CodeType): + trace(f"_read_pyc({source}): not a code object") + return None + return co + + +def rewrite_asserts( + mod: ast.Module, + source: bytes, + module_path: str | None = None, + config: Config | None = None, +) -> None: + """Rewrite the assert statements in mod.""" + AssertionRewriter(module_path, config, source).run(mod) + + +def _saferepr(obj: object) -> str: + r"""Get a safe repr of an object for assertion error messages. + + The assertion formatting (util.format_explanation()) requires + newlines to be escaped since they are a special character for it. + Normally assertion.util.format_explanation() does this but for a + custom repr it is possible to contain one of the special escape + sequences, especially '\n{' and '\n}' are likely to be present in + JSON reprs. + """ + if isinstance(obj, types.MethodType): + # for bound methods, skip redundant <bound method ...> information + return obj.__name__ + + maxsize = _get_maxsize_for_saferepr(util._config) + if not maxsize: + return saferepr_unlimited(obj).replace("\n", "\\n") + return saferepr(obj, maxsize=maxsize).replace("\n", "\\n") + + +def _get_maxsize_for_saferepr(config: Config | None) -> int | None: + """Get `maxsize` configuration for saferepr based on the given config object.""" + if config is None: + verbosity = 0 + else: + verbosity = config.get_verbosity(Config.VERBOSITY_ASSERTIONS) + if verbosity >= 2: + return None + if verbosity >= 1: + return DEFAULT_REPR_MAX_SIZE * 10 + return DEFAULT_REPR_MAX_SIZE + + +def _format_assertmsg(obj: object) -> str: + r"""Format the custom assertion message given. + + For strings this simply replaces newlines with '\n~' so that + util.format_explanation() will preserve them instead of escaping + newlines. For other objects saferepr() is used first. + """ + # reprlib appears to have a bug which means that if a string + # contains a newline it gets escaped, however if an object has a + # .__repr__() which contains newlines it does not get escaped. + # However in either case we want to preserve the newline. + replaces = [("\n", "\n~"), ("%", "%%")] + if not isinstance(obj, str): + obj = saferepr(obj, _get_maxsize_for_saferepr(util._config)) + replaces.append(("\\n", "\n~")) + + for r1, r2 in replaces: + obj = obj.replace(r1, r2) + + return obj + + +def _should_repr_global_name(obj: object) -> bool: + if callable(obj): + # For pytest fixtures the __repr__ method provides more information than the function name. + return isinstance(obj, FixtureFunctionDefinition) + + try: + return not hasattr(obj, "__name__") + except Exception: + return True + + +def _format_boolop(explanations: Iterable[str], is_or: bool) -> str: + explanation = "(" + ((is_or and " or ") or " and ").join(explanations) + ")" + return explanation.replace("%", "%%") + + +def _call_reprcompare( + ops: Sequence[str], + results: Sequence[bool], + expls: Sequence[str], + each_obj: Sequence[object], +) -> str: + for i, res, expl in zip(range(len(ops)), results, expls, strict=True): + try: + done = not res + except Exception: + done = True + if done: + break + if util._reprcompare is not None: + custom = util._reprcompare(ops[i], each_obj[i], each_obj[i + 1]) + if custom is not None: + return custom + return expl + + +def _call_assertion_pass(lineno: int, orig: str, expl: str) -> None: + if util._assertion_pass is not None: + util._assertion_pass(lineno, orig, expl) + + +def _check_if_assertion_pass_impl() -> bool: + """Check if any plugins implement the pytest_assertion_pass hook + in order not to generate explanation unnecessarily (might be expensive).""" + return True if util._assertion_pass else False + + +UNARY_MAP = {ast.Not: "not %s", ast.Invert: "~%s", ast.USub: "-%s", ast.UAdd: "+%s"} + +BINOP_MAP = { + ast.BitOr: "|", + ast.BitXor: "^", + ast.BitAnd: "&", + ast.LShift: "<<", + ast.RShift: ">>", + ast.Add: "+", + ast.Sub: "-", + ast.Mult: "*", + ast.Div: "/", + ast.FloorDiv: "//", + ast.Mod: "%%", # escaped for string formatting + ast.Eq: "==", + ast.NotEq: "!=", + ast.Lt: "<", + ast.LtE: "<=", + ast.Gt: ">", + ast.GtE: ">=", + ast.Pow: "**", + ast.Is: "is", + ast.IsNot: "is not", + ast.In: "in", + ast.NotIn: "not in", + ast.MatMult: "@", +} + + +def traverse_node(node: ast.AST) -> Iterator[ast.AST]: + """Recursively yield node and all its children in depth-first order.""" + yield node + for child in ast.iter_child_nodes(node): + yield from traverse_node(child) + + +@functools.lru_cache(maxsize=1) +def _get_assertion_exprs(src: bytes) -> dict[int, str]: + """Return a mapping from {lineno: "assertion test expression"}.""" + ret: dict[int, str] = {} + + depth = 0 + lines: list[str] = [] + assert_lineno: int | None = None + seen_lines: set[int] = set() + + def _write_and_reset() -> None: + nonlocal depth, lines, assert_lineno, seen_lines + assert assert_lineno is not None + ret[assert_lineno] = "".join(lines).rstrip().rstrip("\\") + depth = 0 + lines = [] + assert_lineno = None + seen_lines = set() + + tokens = tokenize.tokenize(io.BytesIO(src).readline) + for tp, source, (lineno, offset), _, line in tokens: + if tp == tokenize.NAME and source == "assert": + assert_lineno = lineno + elif assert_lineno is not None: + # keep track of depth for the assert-message `,` lookup + if tp == tokenize.OP and source in "([{": + depth += 1 + elif tp == tokenize.OP and source in ")]}": + depth -= 1 + + if not lines: + lines.append(line[offset:]) + seen_lines.add(lineno) + # a non-nested comma separates the expression from the message + elif depth == 0 and tp == tokenize.OP and source == ",": + # one line assert with message + if lineno in seen_lines and len(lines) == 1: + offset_in_trimmed = offset + len(lines[-1]) - len(line) + lines[-1] = lines[-1][:offset_in_trimmed] + # multi-line assert with message + elif lineno in seen_lines: + lines[-1] = lines[-1][:offset] + # multi line assert with escaped newline before message + else: + lines.append(line[:offset]) + _write_and_reset() + elif tp in {tokenize.NEWLINE, tokenize.ENDMARKER}: + _write_and_reset() + elif lines and lineno not in seen_lines: + lines.append(line) + seen_lines.add(lineno) + + return ret + + +class AssertionRewriter(ast.NodeVisitor): + """Assertion rewriting implementation. + + The main entrypoint is to call .run() with an ast.Module instance, + this will then find all the assert statements and rewrite them to + provide intermediate values and a detailed assertion error. See + http://pybites.blogspot.be/2011/07/behind-scenes-of-pytests-new-assertion.html + for an overview of how this works. + + The entry point here is .run() which will iterate over all the + statements in an ast.Module and for each ast.Assert statement it + finds call .visit() with it. Then .visit_Assert() takes over and + is responsible for creating new ast statements to replace the + original assert statement: it rewrites the test of an assertion + to provide intermediate values and replace it with an if statement + which raises an assertion error with a detailed explanation in + case the expression is false and calls pytest_assertion_pass hook + if expression is true. + + For this .visit_Assert() uses the visitor pattern to visit all the + AST nodes of the ast.Assert.test field, each visit call returning + an AST node and the corresponding explanation string. During this + state is kept in several instance attributes: + + :statements: All the AST statements which will replace the assert + statement. + + :variables: This is populated by .variable() with each variable + used by the statements so that they can all be set to None at + the end of the statements. + + :variable_counter: Counter to create new unique variables needed + by statements. Variables are created using .variable() and + have the form of "@py_assert0". + + :expl_stmts: The AST statements which will be executed to get + data from the assertion. This is the code which will construct + the detailed assertion message that is used in the AssertionError + or for the pytest_assertion_pass hook. + + :explanation_specifiers: A dict filled by .explanation_param() + with %-formatting placeholders and their corresponding + expressions to use in the building of an assertion message. + This is used by .pop_format_context() to build a message. + + :stack: A stack of the explanation_specifiers dicts maintained by + .push_format_context() and .pop_format_context() which allows + to build another %-formatted string while already building one. + + :scope: A tuple containing the current scope used for variables_overwrite. + + :variables_overwrite: A dict filled with references to variables + that change value within an assert. This happens when a variable is + reassigned with the walrus operator + + This state, except the variables_overwrite, is reset on every new assert + statement visited and used by the other visitors. + """ + + def __init__( + self, module_path: str | None, config: Config | None, source: bytes + ) -> None: + super().__init__() + self.module_path = module_path + self.config = config + if config is not None: + self.enable_assertion_pass_hook = config.getini( + "enable_assertion_pass_hook" + ) + else: + self.enable_assertion_pass_hook = False + self.source = source + self.scope: tuple[ast.AST, ...] = () + self.variables_overwrite: defaultdict[tuple[ast.AST, ...], dict[str, str]] = ( + defaultdict(dict) + ) + + def run(self, mod: ast.Module) -> None: + """Find all assert statements in *mod* and rewrite them.""" + if not mod.body: + # Nothing to do. + return + + # We'll insert some special imports at the top of the module, but after any + # docstrings and __future__ imports, so first figure out where that is. + doc = getattr(mod, "docstring", None) + expect_docstring = doc is None + if doc is not None and self.is_rewrite_disabled(doc): + return + pos = 0 + for item in mod.body: + match item: + case ast.Expr(value=ast.Constant(value=str() as doc)) if ( + expect_docstring + ): + if self.is_rewrite_disabled(doc): + return + expect_docstring = False + case ast.ImportFrom(level=0, module="__future__"): + pass + case _: + break + pos += 1 + # Special case: for a decorated function, set the lineno to that of the + # first decorator, not the `def`. Issue #4984. + if isinstance(item, ast.FunctionDef) and item.decorator_list: + lineno = item.decorator_list[0].lineno + else: + lineno = item.lineno + # Now actually insert the special imports. + aliases = [ + ast.alias("builtins", "@py_builtins", lineno=lineno, col_offset=0), + ast.alias( + "_pytest.assertion.rewrite", + "@pytest_ar", + lineno=lineno, + col_offset=0, + ), + ] + imports = [ + ast.Import([alias], lineno=lineno, col_offset=0) for alias in aliases + ] + mod.body[pos:pos] = imports + + # Collect asserts. + self.scope = (mod,) + nodes: list[ast.AST | Sentinel] = [mod] + while nodes: + node = nodes.pop() + if isinstance(node, ast.FunctionDef | ast.AsyncFunctionDef | ast.ClassDef): + self.scope = tuple((*self.scope, node)) + nodes.append(_SCOPE_END_MARKER) + if node == _SCOPE_END_MARKER: + self.scope = self.scope[:-1] + continue + assert isinstance(node, ast.AST) + for name, field in ast.iter_fields(node): + if isinstance(field, list): + new: list[ast.AST] = [] + for i, child in enumerate(field): + if isinstance(child, ast.Assert): + # Transform assert. + new.extend(self.visit(child)) + else: + new.append(child) + if isinstance(child, ast.AST): + nodes.append(child) + setattr(node, name, new) + elif ( + isinstance(field, ast.AST) + # Don't recurse into expressions as they can't contain + # asserts. + and not isinstance(field, ast.expr) + ): + nodes.append(field) + + @staticmethod + def is_rewrite_disabled(docstring: str) -> bool: + return "PYTEST_DONT_REWRITE" in docstring + + def variable(self) -> str: + """Get a new variable.""" + # Use a character invalid in python identifiers to avoid clashing. + name = "@py_assert" + str(next(self.variable_counter)) + self.variables.append(name) + return name + + def assign(self, expr: ast.expr) -> ast.Name: + """Give *expr* a name.""" + name = self.variable() + self.statements.append(ast.Assign([ast.Name(name, ast.Store())], expr)) + return ast.copy_location(ast.Name(name, ast.Load()), expr) + + def display(self, expr: ast.expr) -> ast.expr: + """Call saferepr on the expression.""" + return self.helper("_saferepr", expr) + + def helper(self, name: str, *args: ast.expr) -> ast.expr: + """Call a helper in this module.""" + py_name = ast.Name("@pytest_ar", ast.Load()) + attr = ast.Attribute(py_name, name, ast.Load()) + return ast.Call(attr, list(args), []) + + def builtin(self, name: str) -> ast.Attribute: + """Return the builtin called *name*.""" + builtin_name = ast.Name("@py_builtins", ast.Load()) + return ast.Attribute(builtin_name, name, ast.Load()) + + def explanation_param(self, expr: ast.expr) -> str: + """Return a new named %-formatting placeholder for expr. + + This creates a %-formatting placeholder for expr in the + current formatting context, e.g. ``%(py0)s``. The placeholder + and expr are placed in the current format context so that it + can be used on the next call to .pop_format_context(). + """ + specifier = "py" + str(next(self.variable_counter)) + self.explanation_specifiers[specifier] = expr + return "%(" + specifier + ")s" + + def push_format_context(self) -> None: + """Create a new formatting context. + + The format context is used for when an explanation wants to + have a variable value formatted in the assertion message. In + this case the value required can be added using + .explanation_param(). Finally .pop_format_context() is used + to format a string of %-formatted values as added by + .explanation_param(). + """ + self.explanation_specifiers: dict[str, ast.expr] = {} + self.stack.append(self.explanation_specifiers) + + def pop_format_context(self, expl_expr: ast.expr) -> ast.Name: + """Format the %-formatted string with current format context. + + The expl_expr should be an str ast.expr instance constructed from + the %-placeholders created by .explanation_param(). This will + add the required code to format said string to .expl_stmts and + return the ast.Name instance of the formatted string. + """ + current = self.stack.pop() + if self.stack: + self.explanation_specifiers = self.stack[-1] + keys: list[ast.expr | None] = [ast.Constant(key) for key in current.keys()] + format_dict = ast.Dict(keys, list(current.values())) + form = ast.BinOp(expl_expr, ast.Mod(), format_dict) + name = "@py_format" + str(next(self.variable_counter)) + if self.enable_assertion_pass_hook: + self.format_variables.append(name) + self.expl_stmts.append(ast.Assign([ast.Name(name, ast.Store())], form)) + return ast.Name(name, ast.Load()) + + def generic_visit(self, node: ast.AST) -> tuple[ast.Name, str]: + """Handle expressions we don't have custom code for.""" + assert isinstance(node, ast.expr) + res = self.assign(node) + return res, self.explanation_param(self.display(res)) + + def visit_Assert(self, assert_: ast.Assert) -> list[ast.stmt]: + """Return the AST statements to replace the ast.Assert instance. + + This rewrites the test of an assertion to provide + intermediate values and replace it with an if statement which + raises an assertion error with a detailed explanation in case + the expression is false. + """ + if isinstance(assert_.test, ast.Tuple) and len(assert_.test.elts) >= 1: + import warnings + + from _pytest.warning_types import PytestAssertRewriteWarning + + # TODO: This assert should not be needed. + assert self.module_path is not None + warnings.warn_explicit( + PytestAssertRewriteWarning( + "assertion is always true, perhaps remove parentheses?" + ), + category=None, + filename=self.module_path, + lineno=assert_.lineno, + ) + + self.statements: list[ast.stmt] = [] + self.variables: list[str] = [] + self.variable_counter = itertools.count() + + if self.enable_assertion_pass_hook: + self.format_variables: list[str] = [] + + self.stack: list[dict[str, ast.expr]] = [] + self.expl_stmts: list[ast.stmt] = [] + self.push_format_context() + # Rewrite assert into a bunch of statements. + top_condition, explanation = self.visit(assert_.test) + + negation = ast.UnaryOp(ast.Not(), top_condition) + + if self.enable_assertion_pass_hook: # Experimental pytest_assertion_pass hook + msg = self.pop_format_context(ast.Constant(explanation)) + + # Failed + if assert_.msg: + assertmsg = self.helper("_format_assertmsg", assert_.msg) + gluestr = "\n>assert " + else: + assertmsg = ast.Constant("") + gluestr = "assert " + err_explanation = ast.BinOp(ast.Constant(gluestr), ast.Add(), msg) + err_msg = ast.BinOp(assertmsg, ast.Add(), err_explanation) + err_name = ast.Name("AssertionError", ast.Load()) + fmt = self.helper("_format_explanation", err_msg) + exc = ast.Call(err_name, [fmt], []) + raise_ = ast.Raise(exc, None) + statements_fail = [] + statements_fail.extend(self.expl_stmts) + statements_fail.append(raise_) + + # Passed + fmt_pass = self.helper("_format_explanation", msg) + orig = _get_assertion_exprs(self.source)[assert_.lineno] + hook_call_pass = ast.Expr( + self.helper( + "_call_assertion_pass", + ast.Constant(assert_.lineno), + ast.Constant(orig), + fmt_pass, + ) + ) + # If any hooks implement assert_pass hook + hook_impl_test = ast.If( + self.helper("_check_if_assertion_pass_impl"), + [*self.expl_stmts, hook_call_pass], + [], + ) + statements_pass: list[ast.stmt] = [hook_impl_test] + + # Test for assertion condition + main_test = ast.If(negation, statements_fail, statements_pass) + self.statements.append(main_test) + if self.format_variables: + variables: list[ast.expr] = [ + ast.Name(name, ast.Store()) for name in self.format_variables + ] + clear_format = ast.Assign(variables, ast.Constant(None)) + self.statements.append(clear_format) + + else: # Original assertion rewriting + # Create failure message. + body = self.expl_stmts + self.statements.append(ast.If(negation, body, [])) + if assert_.msg: + assertmsg = self.helper("_format_assertmsg", assert_.msg) + explanation = "\n>assert " + explanation + else: + assertmsg = ast.Constant("") + explanation = "assert " + explanation + template = ast.BinOp(assertmsg, ast.Add(), ast.Constant(explanation)) + msg = self.pop_format_context(template) + fmt = self.helper("_format_explanation", msg) + err_name = ast.Name("AssertionError", ast.Load()) + exc = ast.Call(err_name, [fmt], []) + raise_ = ast.Raise(exc, None) + + body.append(raise_) + + # Clear temporary variables by setting them to None. + if self.variables: + variables = [ast.Name(name, ast.Store()) for name in self.variables] + clear = ast.Assign(variables, ast.Constant(None)) + self.statements.append(clear) + # Fix locations (line numbers/column offsets). + for stmt in self.statements: + for node in traverse_node(stmt): + if getattr(node, "lineno", None) is None: + # apply the assertion location to all generated ast nodes without source location + # and preserve the location of existing nodes or generated nodes with an correct location. + ast.copy_location(node, assert_) + return self.statements + + def visit_NamedExpr(self, name: ast.NamedExpr) -> tuple[ast.NamedExpr, str]: + # This method handles the 'walrus operator' repr of the target + # name if it's a local variable or _should_repr_global_name() + # thinks it's acceptable. + locs = ast.Call(self.builtin("locals"), [], []) + target_id = name.target.id + inlocs = ast.Compare(ast.Constant(target_id), [ast.In()], [locs]) + dorepr = self.helper("_should_repr_global_name", name) + test = ast.BoolOp(ast.Or(), [inlocs, dorepr]) + expr = ast.IfExp(test, self.display(name), ast.Constant(target_id)) + return name, self.explanation_param(expr) + + def visit_Name(self, name: ast.Name) -> tuple[ast.Name, str]: + # Display the repr of the name if it's a local variable or + # _should_repr_global_name() thinks it's acceptable. + locs = ast.Call(self.builtin("locals"), [], []) + inlocs = ast.Compare(ast.Constant(name.id), [ast.In()], [locs]) + dorepr = self.helper("_should_repr_global_name", name) + test = ast.BoolOp(ast.Or(), [inlocs, dorepr]) + expr = ast.IfExp(test, self.display(name), ast.Constant(name.id)) + return name, self.explanation_param(expr) + + def visit_BoolOp(self, boolop: ast.BoolOp) -> tuple[ast.Name, str]: + res_var = self.variable() + expl_list = self.assign(ast.List([], ast.Load())) + app = ast.Attribute(expl_list, "append", ast.Load()) + is_or = int(isinstance(boolop.op, ast.Or)) + body = save = self.statements + fail_save = self.expl_stmts + levels = len(boolop.values) - 1 + self.push_format_context() + # Process each operand, short-circuiting if needed. + for i, v in enumerate(boolop.values): + if i: + fail_inner: list[ast.stmt] = [] + # cond is set in a prior loop iteration below + self.expl_stmts.append(ast.If(cond, fail_inner, [])) # noqa: F821 + self.expl_stmts = fail_inner + match v: + # Check if the left operand is an ast.NamedExpr and the value has already been visited + case ast.Compare( + left=ast.NamedExpr(target=ast.Name(id=target_id)) + ) if target_id in [ + e.id for e in boolop.values[:i] if hasattr(e, "id") + ]: + pytest_temp = self.variable() + self.variables_overwrite[self.scope][target_id] = v.left # type:ignore[assignment] + # mypy's false positive, we're checking that the 'target' attribute exists. + v.left.target.id = pytest_temp # type:ignore[attr-defined] + self.push_format_context() + res, expl = self.visit(v) + body.append(ast.Assign([ast.Name(res_var, ast.Store())], res)) + expl_format = self.pop_format_context(ast.Constant(expl)) + call = ast.Call(app, [expl_format], []) + self.expl_stmts.append(ast.Expr(call)) + if i < levels: + cond: ast.expr = res + if is_or: + cond = ast.UnaryOp(ast.Not(), cond) + inner: list[ast.stmt] = [] + self.statements.append(ast.If(cond, inner, [])) + self.statements = body = inner + self.statements = save + self.expl_stmts = fail_save + expl_template = self.helper("_format_boolop", expl_list, ast.Constant(is_or)) + expl = self.pop_format_context(expl_template) + return ast.Name(res_var, ast.Load()), self.explanation_param(expl) + + def visit_UnaryOp(self, unary: ast.UnaryOp) -> tuple[ast.Name, str]: + pattern = UNARY_MAP[unary.op.__class__] + operand_res, operand_expl = self.visit(unary.operand) + res = self.assign(ast.copy_location(ast.UnaryOp(unary.op, operand_res), unary)) + return res, pattern % (operand_expl,) + + def visit_BinOp(self, binop: ast.BinOp) -> tuple[ast.Name, str]: + symbol = BINOP_MAP[binop.op.__class__] + left_expr, left_expl = self.visit(binop.left) + right_expr, right_expl = self.visit(binop.right) + explanation = f"({left_expl} {symbol} {right_expl})" + res = self.assign( + ast.copy_location(ast.BinOp(left_expr, binop.op, right_expr), binop) + ) + return res, explanation + + def visit_Call(self, call: ast.Call) -> tuple[ast.Name, str]: + new_func, func_expl = self.visit(call.func) + arg_expls = [] + new_args = [] + new_kwargs = [] + for arg in call.args: + if isinstance(arg, ast.Name) and arg.id in self.variables_overwrite.get( + self.scope, {} + ): + arg = self.variables_overwrite[self.scope][arg.id] # type:ignore[assignment] + res, expl = self.visit(arg) + arg_expls.append(expl) + new_args.append(res) + for keyword in call.keywords: + match keyword.value: + case ast.Name(id=id) if id in self.variables_overwrite.get( + self.scope, {} + ): + keyword.value = self.variables_overwrite[self.scope][id] # type:ignore[assignment] + res, expl = self.visit(keyword.value) + new_kwargs.append(ast.keyword(keyword.arg, res)) + if keyword.arg: + arg_expls.append(keyword.arg + "=" + expl) + else: # **args have `arg` keywords with an .arg of None + arg_expls.append("**" + expl) + + expl = "{}({})".format(func_expl, ", ".join(arg_expls)) + new_call = ast.copy_location(ast.Call(new_func, new_args, new_kwargs), call) + res = self.assign(new_call) + res_expl = self.explanation_param(self.display(res)) + outer_expl = f"{res_expl}\n{{{res_expl} = {expl}\n}}" + return res, outer_expl + + def visit_Starred(self, starred: ast.Starred) -> tuple[ast.Starred, str]: + # A Starred node can appear in a function call. + res, expl = self.visit(starred.value) + new_starred = ast.Starred(res, starred.ctx) + return new_starred, "*" + expl + + def visit_Attribute(self, attr: ast.Attribute) -> tuple[ast.Name, str]: + if not isinstance(attr.ctx, ast.Load): + return self.generic_visit(attr) + value, value_expl = self.visit(attr.value) + res = self.assign( + ast.copy_location(ast.Attribute(value, attr.attr, ast.Load()), attr) + ) + res_expl = self.explanation_param(self.display(res)) + pat = "%s\n{%s = %s.%s\n}" + expl = pat % (res_expl, res_expl, value_expl, attr.attr) + return res, expl + + def visit_Compare(self, comp: ast.Compare) -> tuple[ast.expr, str]: + self.push_format_context() + # We first check if we have overwritten a variable in the previous assert + match comp.left: + case ast.Name(id=name_id) if name_id in self.variables_overwrite.get( + self.scope, {} + ): + comp.left = self.variables_overwrite[self.scope][name_id] # type: ignore[assignment] + case ast.NamedExpr(target=ast.Name(id=target_id)): + self.variables_overwrite[self.scope][target_id] = comp.left # type: ignore[assignment] + left_res, left_expl = self.visit(comp.left) + if isinstance(comp.left, ast.Compare | ast.BoolOp): + left_expl = f"({left_expl})" + res_variables = [self.variable() for i in range(len(comp.ops))] + load_names: list[ast.expr] = [ast.Name(v, ast.Load()) for v in res_variables] + store_names = [ast.Name(v, ast.Store()) for v in res_variables] + it = zip(range(len(comp.ops)), comp.ops, comp.comparators, strict=True) + expls: list[ast.expr] = [] + syms: list[ast.expr] = [] + results = [left_res] + for i, op, next_operand in it: + match (next_operand, left_res): + case ( + ast.NamedExpr(target=ast.Name(id=target_id)), + ast.Name(id=name_id), + ) if target_id == name_id: + next_operand.target.id = self.variable() + self.variables_overwrite[self.scope][name_id] = next_operand # type: ignore[assignment] + + next_res, next_expl = self.visit(next_operand) + if isinstance(next_operand, ast.Compare | ast.BoolOp): + next_expl = f"({next_expl})" + results.append(next_res) + sym = BINOP_MAP[op.__class__] + syms.append(ast.Constant(sym)) + expl = f"{left_expl} {sym} {next_expl}" + expls.append(ast.Constant(expl)) + res_expr = ast.copy_location(ast.Compare(left_res, [op], [next_res]), comp) + self.statements.append(ast.Assign([store_names[i]], res_expr)) + left_res, left_expl = next_res, next_expl + # Use pytest.assertion.util._reprcompare if that's available. + expl_call = self.helper( + "_call_reprcompare", + ast.Tuple(syms, ast.Load()), + ast.Tuple(load_names, ast.Load()), + ast.Tuple(expls, ast.Load()), + ast.Tuple(results, ast.Load()), + ) + if len(comp.ops) > 1: + res: ast.expr = ast.BoolOp(ast.And(), load_names) + else: + res = load_names[0] + + return res, self.explanation_param(self.pop_format_context(expl_call)) + + +def try_makedirs(cache_dir: Path) -> bool: + """Attempt to create the given directory and sub-directories exist. + + Returns True if successful or if it already exists. + """ + try: + os.makedirs(cache_dir, exist_ok=True) + except (FileNotFoundError, NotADirectoryError, FileExistsError): + # One of the path components was not a directory: + # - we're in a zip file + # - it is a file + return False + except PermissionError: + return False + except OSError as e: + # as of now, EROFS doesn't have an equivalent OSError-subclass + # + # squashfuse_ll returns ENOSYS "OSError: [Errno 38] Function not + # implemented" for a read-only error + if e.errno in {errno.EROFS, errno.ENOSYS}: + return False + raise + return True + + +def get_cache_dir(file_path: Path) -> Path: + """Return the cache directory to write .pyc files for the given .py file path.""" + if sys.pycache_prefix: + # given: + # prefix = '/tmp/pycs' + # path = '/home/user/proj/test_app.py' + # we want: + # '/tmp/pycs/home/user/proj' + return Path(sys.pycache_prefix) / Path(*file_path.parts[1:-1]) + else: + # classic pycache directory + return file_path.parent / "__pycache__" diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/assertion/truncate.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/assertion/truncate.py new file mode 100644 index 0000000000000000000000000000000000000000..5820e6e8a80e3ed2479fe54b018c85c5114dfbb4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/assertion/truncate.py @@ -0,0 +1,137 @@ +"""Utilities for truncating assertion output. + +Current default behaviour is to truncate assertion explanations at +terminal lines, unless running with an assertions verbosity level of at least 2 or running on CI. +""" + +from __future__ import annotations + +from _pytest.compat import running_on_ci +from _pytest.config import Config +from _pytest.nodes import Item + + +DEFAULT_MAX_LINES = 8 +DEFAULT_MAX_CHARS = DEFAULT_MAX_LINES * 80 +USAGE_MSG = "use '-vv' to show" + + +def truncate_if_required(explanation: list[str], item: Item) -> list[str]: + """Truncate this assertion explanation if the given test item is eligible.""" + should_truncate, max_lines, max_chars = _get_truncation_parameters(item) + if should_truncate: + return _truncate_explanation( + explanation, + max_lines=max_lines, + max_chars=max_chars, + ) + return explanation + + +def _get_truncation_parameters(item: Item) -> tuple[bool, int, int]: + """Return the truncation parameters related to the given item, as (should truncate, max lines, max chars).""" + # We do not need to truncate if one of conditions is met: + # 1. Verbosity level is 2 or more; + # 2. Test is being run in CI environment; + # 3. Both truncation_limit_lines and truncation_limit_chars + # .ini parameters are set to 0 explicitly. + max_lines = item.config.getini("truncation_limit_lines") + max_lines = int(max_lines if max_lines is not None else DEFAULT_MAX_LINES) + + max_chars = item.config.getini("truncation_limit_chars") + max_chars = int(max_chars if max_chars is not None else DEFAULT_MAX_CHARS) + + verbose = item.config.get_verbosity(Config.VERBOSITY_ASSERTIONS) + + should_truncate = verbose < 2 and not running_on_ci() + should_truncate = should_truncate and (max_lines > 0 or max_chars > 0) + + return should_truncate, max_lines, max_chars + + +def _truncate_explanation( + input_lines: list[str], + max_lines: int, + max_chars: int, +) -> list[str]: + """Truncate given list of strings that makes up the assertion explanation. + + Truncates to either max_lines, or max_chars - whichever the input reaches + first, taking the truncation explanation into account. The remaining lines + will be replaced by a usage message. + """ + # Check if truncation required + input_char_count = len("".join(input_lines)) + # The length of the truncation explanation depends on the number of lines + # removed but is at least 68 characters: + # The real value is + # 64 (for the base message: + # '...\n...Full output truncated (1 line hidden), use '-vv' to show")' + # ) + # + 1 (for plural) + # + int(math.log10(len(input_lines) - max_lines)) (number of hidden line, at least 1) + # + 3 for the '...' added to the truncated line + # But if there's more than 100 lines it's very likely that we're going to + # truncate, so we don't need the exact value using log10. + tolerable_max_chars = ( + max_chars + 70 # 64 + 1 (for plural) + 2 (for '99') + 3 for '...' + ) + # The truncation explanation add two lines to the output + tolerable_max_lines = max_lines + 2 + if ( + len(input_lines) <= tolerable_max_lines + and input_char_count <= tolerable_max_chars + ): + return input_lines + # Truncate first to max_lines, and then truncate to max_chars if necessary + if max_lines > 0: + truncated_explanation = input_lines[:max_lines] + else: + truncated_explanation = input_lines + truncated_char = True + # We reevaluate the need to truncate chars following removal of some lines + if len("".join(truncated_explanation)) > tolerable_max_chars and max_chars > 0: + truncated_explanation = _truncate_by_char_count( + truncated_explanation, max_chars + ) + else: + truncated_char = False + + if truncated_explanation == input_lines: + # No truncation happened, so we do not need to add any explanations + return truncated_explanation + + truncated_line_count = len(input_lines) - len(truncated_explanation) + if truncated_explanation[-1]: + # Add ellipsis and take into account part-truncated final line + truncated_explanation[-1] = truncated_explanation[-1] + "..." + if truncated_char: + # It's possible that we did not remove any char from this line + truncated_line_count += 1 + else: + # Add proper ellipsis when we were able to fit a full line exactly + truncated_explanation[-1] = "..." + return [ + *truncated_explanation, + "", + f"...Full output truncated ({truncated_line_count} line" + f"{'' if truncated_line_count == 1 else 's'} hidden), {USAGE_MSG}", + ] + + +def _truncate_by_char_count(input_lines: list[str], max_chars: int) -> list[str]: + # Find point at which input length exceeds total allowed length + iterated_char_count = 0 + for iterated_index, input_line in enumerate(input_lines): + if iterated_char_count + len(input_line) > max_chars: + break + iterated_char_count += len(input_line) + + # Create truncated explanation with modified final line + truncated_result = input_lines[:iterated_index] + final_line = input_lines[iterated_index] + if final_line: + final_line_truncate_point = max_chars - iterated_char_count + final_line = final_line[:final_line_truncate_point] + truncated_result.append(final_line) + return truncated_result diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/assertion/util.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/assertion/util.py new file mode 100644 index 0000000000000000000000000000000000000000..f35d83a6fe4aa38acc747ff5dbdaf96adab51178 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/assertion/util.py @@ -0,0 +1,615 @@ +# mypy: allow-untyped-defs +"""Utilities for assertion debugging.""" + +from __future__ import annotations + +import collections.abc +from collections.abc import Callable +from collections.abc import Iterable +from collections.abc import Mapping +from collections.abc import Sequence +from collections.abc import Set as AbstractSet +import pprint +from typing import Any +from typing import Literal +from typing import Protocol +from unicodedata import normalize + +from _pytest import outcomes +import _pytest._code +from _pytest._io.pprint import PrettyPrinter +from _pytest._io.saferepr import saferepr +from _pytest._io.saferepr import saferepr_unlimited +from _pytest.compat import running_on_ci +from _pytest.config import Config + + +# The _reprcompare attribute on the util module is used by the new assertion +# interpretation code and assertion rewriter to detect this plugin was +# loaded and in turn call the hooks defined here as part of the +# DebugInterpreter. +_reprcompare: Callable[[str, object, object], str | None] | None = None + +# Works similarly as _reprcompare attribute. Is populated with the hook call +# when pytest_runtest_setup is called. +_assertion_pass: Callable[[int, str, str], None] | None = None + +# Config object which is assigned during pytest_runtest_protocol. +_config: Config | None = None + + +class _HighlightFunc(Protocol): + def __call__(self, source: str, lexer: Literal["diff", "python"] = "python") -> str: + """Apply highlighting to the given source.""" + + +def dummy_highlighter(source: str, lexer: Literal["diff", "python"] = "python") -> str: + """Dummy highlighter that returns the text unprocessed. + + Needed for _notin_text, as the diff gets post-processed to only show the "+" part. + """ + return source + + +def format_explanation(explanation: str) -> str: + r"""Format an explanation. + + Normally all embedded newlines are escaped, however there are + three exceptions: \n{, \n} and \n~. The first two are intended + cover nested explanations, see function and attribute explanations + for examples (.visit_Call(), visit_Attribute()). The last one is + for when one explanation needs to span multiple lines, e.g. when + displaying diffs. + """ + lines = _split_explanation(explanation) + result = _format_lines(lines) + return "\n".join(result) + + +def _split_explanation(explanation: str) -> list[str]: + r"""Return a list of individual lines in the explanation. + + This will return a list of lines split on '\n{', '\n}' and '\n~'. + Any other newlines will be escaped and appear in the line as the + literal '\n' characters. + """ + raw_lines = (explanation or "").split("\n") + lines = [raw_lines[0]] + for values in raw_lines[1:]: + if values and values[0] in ["{", "}", "~", ">"]: + lines.append(values) + else: + lines[-1] += "\\n" + values + return lines + + +def _format_lines(lines: Sequence[str]) -> list[str]: + """Format the individual lines. + + This will replace the '{', '}' and '~' characters of our mini formatting + language with the proper 'where ...', 'and ...' and ' + ...' text, taking + care of indentation along the way. + + Return a list of formatted lines. + """ + result = list(lines[:1]) + stack = [0] + stackcnt = [0] + for line in lines[1:]: + if line.startswith("{"): + if stackcnt[-1]: + s = "and " + else: + s = "where " + stack.append(len(result)) + stackcnt[-1] += 1 + stackcnt.append(0) + result.append(" +" + " " * (len(stack) - 1) + s + line[1:]) + elif line.startswith("}"): + stack.pop() + stackcnt.pop() + result[stack[-1]] += line[1:] + else: + assert line[0] in ["~", ">"] + stack[-1] += 1 + indent = len(stack) if line.startswith("~") else len(stack) - 1 + result.append(" " * indent + line[1:]) + assert len(stack) == 1 + return result + + +def issequence(x: Any) -> bool: + return isinstance(x, collections.abc.Sequence) and not isinstance(x, str) + + +def istext(x: Any) -> bool: + return isinstance(x, str) + + +def isdict(x: Any) -> bool: + return isinstance(x, dict) + + +def isset(x: Any) -> bool: + return isinstance(x, set | frozenset) + + +def isnamedtuple(obj: Any) -> bool: + return isinstance(obj, tuple) and getattr(obj, "_fields", None) is not None + + +def isdatacls(obj: Any) -> bool: + return getattr(obj, "__dataclass_fields__", None) is not None + + +def isattrs(obj: Any) -> bool: + return getattr(obj, "__attrs_attrs__", None) is not None + + +def isiterable(obj: Any) -> bool: + try: + iter(obj) + return not istext(obj) + except Exception: + return False + + +def has_default_eq( + obj: object, +) -> bool: + """Check if an instance of an object contains the default eq + + First, we check if the object's __eq__ attribute has __code__, + if so, we check the equally of the method code filename (__code__.co_filename) + to the default one generated by the dataclass and attr module + for dataclasses the default co_filename is <string>, for attrs class, the __eq__ should contain "attrs eq generated" + """ + # inspired from https://github.com/willmcgugan/rich/blob/07d51ffc1aee6f16bd2e5a25b4e82850fb9ed778/rich/pretty.py#L68 + if hasattr(obj.__eq__, "__code__") and hasattr(obj.__eq__.__code__, "co_filename"): + code_filename = obj.__eq__.__code__.co_filename + + if isattrs(obj): + return "attrs generated " in code_filename + + return code_filename == "<string>" # data class + return True + + +def assertrepr_compare( + config, op: str, left: Any, right: Any, use_ascii: bool = False +) -> list[str] | None: + """Return specialised explanations for some operators/operands.""" + verbose = config.get_verbosity(Config.VERBOSITY_ASSERTIONS) + + # Strings which normalize equal are often hard to distinguish when printed; use ascii() to make this easier. + # See issue #3246. + use_ascii = ( + isinstance(left, str) + and isinstance(right, str) + and normalize("NFD", left) == normalize("NFD", right) + ) + + if verbose > 1: + left_repr = saferepr_unlimited(left, use_ascii=use_ascii) + right_repr = saferepr_unlimited(right, use_ascii=use_ascii) + else: + # XXX: "15 chars indentation" is wrong + # ("E AssertionError: assert "); should use term width. + maxsize = ( + 80 - 15 - len(op) - 2 + ) // 2 # 15 chars indentation, 1 space around op + + left_repr = saferepr(left, maxsize=maxsize, use_ascii=use_ascii) + right_repr = saferepr(right, maxsize=maxsize, use_ascii=use_ascii) + + summary = f"{left_repr} {op} {right_repr}" + highlighter = config.get_terminal_writer()._highlight + + explanation = None + try: + if op == "==": + explanation = _compare_eq_any(left, right, highlighter, verbose) + elif op == "not in": + if istext(left) and istext(right): + explanation = _notin_text(left, right, verbose) + elif op == "!=": + if isset(left) and isset(right): + explanation = ["Both sets are equal"] + elif op == ">=": + if isset(left) and isset(right): + explanation = _compare_gte_set(left, right, highlighter, verbose) + elif op == "<=": + if isset(left) and isset(right): + explanation = _compare_lte_set(left, right, highlighter, verbose) + elif op == ">": + if isset(left) and isset(right): + explanation = _compare_gt_set(left, right, highlighter, verbose) + elif op == "<": + if isset(left) and isset(right): + explanation = _compare_lt_set(left, right, highlighter, verbose) + + except outcomes.Exit: + raise + except Exception: + repr_crash = _pytest._code.ExceptionInfo.from_current()._getreprcrash() + explanation = [ + f"(pytest_assertion plugin: representation of details failed: {repr_crash}.", + " Probably an object has a faulty __repr__.)", + ] + + if not explanation: + return None + + if explanation[0] != "": + explanation = ["", *explanation] + return [summary, *explanation] + + +def _compare_eq_any( + left: Any, right: Any, highlighter: _HighlightFunc, verbose: int = 0 +) -> list[str]: + explanation = [] + if istext(left) and istext(right): + explanation = _diff_text(left, right, highlighter, verbose) + else: + from _pytest.python_api import ApproxBase + + if isinstance(left, ApproxBase) or isinstance(right, ApproxBase): + # Although the common order should be obtained == expected, this ensures both ways + approx_side = left if isinstance(left, ApproxBase) else right + other_side = right if isinstance(left, ApproxBase) else left + + explanation = approx_side._repr_compare(other_side) + elif type(left) is type(right) and ( + isdatacls(left) or isattrs(left) or isnamedtuple(left) + ): + # Note: unlike dataclasses/attrs, namedtuples compare only the + # field values, not the type or field names. But this branch + # intentionally only handles the same-type case, which was often + # used in older code bases before dataclasses/attrs were available. + explanation = _compare_eq_cls(left, right, highlighter, verbose) + elif issequence(left) and issequence(right): + explanation = _compare_eq_sequence(left, right, highlighter, verbose) + elif isset(left) and isset(right): + explanation = _compare_eq_set(left, right, highlighter, verbose) + elif isdict(left) and isdict(right): + explanation = _compare_eq_dict(left, right, highlighter, verbose) + + if isiterable(left) and isiterable(right): + expl = _compare_eq_iterable(left, right, highlighter, verbose) + explanation.extend(expl) + + return explanation + + +def _diff_text( + left: str, right: str, highlighter: _HighlightFunc, verbose: int = 0 +) -> list[str]: + """Return the explanation for the diff between text. + + Unless --verbose is used this will skip leading and trailing + characters which are identical to keep the diff minimal. + """ + from difflib import ndiff + + explanation: list[str] = [] + + if verbose < 1: + i = 0 # just in case left or right has zero length + for i in range(min(len(left), len(right))): + if left[i] != right[i]: + break + if i > 42: + i -= 10 # Provide some context + explanation = [ + f"Skipping {i} identical leading characters in diff, use -v to show" + ] + left = left[i:] + right = right[i:] + if len(left) == len(right): + for i in range(len(left)): + if left[-i] != right[-i]: + break + if i > 42: + i -= 10 # Provide some context + explanation += [ + f"Skipping {i} identical trailing " + "characters in diff, use -v to show" + ] + left = left[:-i] + right = right[:-i] + keepends = True + if left.isspace() or right.isspace(): + left = repr(str(left)) + right = repr(str(right)) + explanation += ["Strings contain only whitespace, escaping them using repr()"] + # "right" is the expected base against which we compare "left", + # see https://github.com/pytest-dev/pytest/issues/3333 + explanation.extend( + highlighter( + "\n".join( + line.strip("\n") + for line in ndiff(right.splitlines(keepends), left.splitlines(keepends)) + ), + lexer="diff", + ).splitlines() + ) + return explanation + + +def _compare_eq_iterable( + left: Iterable[Any], + right: Iterable[Any], + highlighter: _HighlightFunc, + verbose: int = 0, +) -> list[str]: + if verbose <= 0 and not running_on_ci(): + return ["Use -v to get more diff"] + # dynamic import to speedup pytest + import difflib + + left_formatting = PrettyPrinter().pformat(left).splitlines() + right_formatting = PrettyPrinter().pformat(right).splitlines() + + explanation = ["", "Full diff:"] + # "right" is the expected base against which we compare "left", + # see https://github.com/pytest-dev/pytest/issues/3333 + explanation.extend( + highlighter( + "\n".join( + line.rstrip() + for line in difflib.ndiff(right_formatting, left_formatting) + ), + lexer="diff", + ).splitlines() + ) + return explanation + + +def _compare_eq_sequence( + left: Sequence[Any], + right: Sequence[Any], + highlighter: _HighlightFunc, + verbose: int = 0, +) -> list[str]: + comparing_bytes = isinstance(left, bytes) and isinstance(right, bytes) + explanation: list[str] = [] + len_left = len(left) + len_right = len(right) + for i in range(min(len_left, len_right)): + if left[i] != right[i]: + if comparing_bytes: + # when comparing bytes, we want to see their ascii representation + # instead of their numeric values (#5260) + # using a slice gives us the ascii representation: + # >>> s = b'foo' + # >>> s[0] + # 102 + # >>> s[0:1] + # b'f' + left_value = left[i : i + 1] + right_value = right[i : i + 1] + else: + left_value = left[i] + right_value = right[i] + + explanation.append( + f"At index {i} diff:" + f" {highlighter(repr(left_value))} != {highlighter(repr(right_value))}" + ) + break + + if comparing_bytes: + # when comparing bytes, it doesn't help to show the "sides contain one or more + # items" longer explanation, so skip it + + return explanation + + len_diff = len_left - len_right + if len_diff: + if len_diff > 0: + dir_with_more = "Left" + extra = saferepr(left[len_right]) + else: + len_diff = 0 - len_diff + dir_with_more = "Right" + extra = saferepr(right[len_left]) + + if len_diff == 1: + explanation += [ + f"{dir_with_more} contains one more item: {highlighter(extra)}" + ] + else: + explanation += [ + f"{dir_with_more} contains {len_diff} more items, first extra item: {highlighter(extra)}" + ] + return explanation + + +def _compare_eq_set( + left: AbstractSet[Any], + right: AbstractSet[Any], + highlighter: _HighlightFunc, + verbose: int = 0, +) -> list[str]: + explanation = [] + explanation.extend(_set_one_sided_diff("left", left, right, highlighter)) + explanation.extend(_set_one_sided_diff("right", right, left, highlighter)) + return explanation + + +def _compare_gt_set( + left: AbstractSet[Any], + right: AbstractSet[Any], + highlighter: _HighlightFunc, + verbose: int = 0, +) -> list[str]: + explanation = _compare_gte_set(left, right, highlighter) + if not explanation: + return ["Both sets are equal"] + return explanation + + +def _compare_lt_set( + left: AbstractSet[Any], + right: AbstractSet[Any], + highlighter: _HighlightFunc, + verbose: int = 0, +) -> list[str]: + explanation = _compare_lte_set(left, right, highlighter) + if not explanation: + return ["Both sets are equal"] + return explanation + + +def _compare_gte_set( + left: AbstractSet[Any], + right: AbstractSet[Any], + highlighter: _HighlightFunc, + verbose: int = 0, +) -> list[str]: + return _set_one_sided_diff("right", right, left, highlighter) + + +def _compare_lte_set( + left: AbstractSet[Any], + right: AbstractSet[Any], + highlighter: _HighlightFunc, + verbose: int = 0, +) -> list[str]: + return _set_one_sided_diff("left", left, right, highlighter) + + +def _set_one_sided_diff( + posn: str, + set1: AbstractSet[Any], + set2: AbstractSet[Any], + highlighter: _HighlightFunc, +) -> list[str]: + explanation = [] + diff = set1 - set2 + if diff: + explanation.append(f"Extra items in the {posn} set:") + for item in diff: + explanation.append(highlighter(saferepr(item))) + return explanation + + +def _compare_eq_dict( + left: Mapping[Any, Any], + right: Mapping[Any, Any], + highlighter: _HighlightFunc, + verbose: int = 0, +) -> list[str]: + explanation: list[str] = [] + set_left = set(left) + set_right = set(right) + common = set_left.intersection(set_right) + same = {k: left[k] for k in common if left[k] == right[k]} + if same and verbose < 2: + explanation += [f"Omitting {len(same)} identical items, use -vv to show"] + elif same: + explanation += ["Common items:"] + explanation += highlighter(pprint.pformat(same)).splitlines() + diff = {k for k in common if left[k] != right[k]} + if diff: + explanation += ["Differing items:"] + for k in diff: + explanation += [ + highlighter(saferepr({k: left[k]})) + + " != " + + highlighter(saferepr({k: right[k]})) + ] + extra_left = set_left - set_right + len_extra_left = len(extra_left) + if len_extra_left: + explanation.append( + f"Left contains {len_extra_left} more item{'' if len_extra_left == 1 else 's'}:" + ) + explanation.extend( + highlighter(pprint.pformat({k: left[k] for k in extra_left})).splitlines() + ) + extra_right = set_right - set_left + len_extra_right = len(extra_right) + if len_extra_right: + explanation.append( + f"Right contains {len_extra_right} more item{'' if len_extra_right == 1 else 's'}:" + ) + explanation.extend( + highlighter(pprint.pformat({k: right[k] for k in extra_right})).splitlines() + ) + return explanation + + +def _compare_eq_cls( + left: Any, right: Any, highlighter: _HighlightFunc, verbose: int +) -> list[str]: + if not has_default_eq(left): + return [] + if isdatacls(left): + import dataclasses + + all_fields = dataclasses.fields(left) + fields_to_check = [info.name for info in all_fields if info.compare] + elif isattrs(left): + all_fields = left.__attrs_attrs__ + fields_to_check = [field.name for field in all_fields if getattr(field, "eq")] + elif isnamedtuple(left): + fields_to_check = left._fields + else: + assert False + + indent = " " + same = [] + diff = [] + for field in fields_to_check: + if getattr(left, field) == getattr(right, field): + same.append(field) + else: + diff.append(field) + + explanation = [] + if same or diff: + explanation += [""] + if same and verbose < 2: + explanation.append(f"Omitting {len(same)} identical items, use -vv to show") + elif same: + explanation += ["Matching attributes:"] + explanation += highlighter(pprint.pformat(same)).splitlines() + if diff: + explanation += ["Differing attributes:"] + explanation += highlighter(pprint.pformat(diff)).splitlines() + for field in diff: + field_left = getattr(left, field) + field_right = getattr(right, field) + explanation += [ + "", + f"Drill down into differing attribute {field}:", + f"{indent}{field}: {highlighter(repr(field_left))} != {highlighter(repr(field_right))}", + ] + explanation += [ + indent + line + for line in _compare_eq_any( + field_left, field_right, highlighter, verbose + ) + ] + return explanation + + +def _notin_text(term: str, text: str, verbose: int = 0) -> list[str]: + index = text.find(term) + head = text[:index] + tail = text[index + len(term) :] + correct_text = head + tail + diff = _diff_text(text, correct_text, dummy_highlighter, verbose) + newdiff = [f"{saferepr(term, maxsize=42)} is contained here:"] + for line in diff: + if line.startswith("Skipping"): + continue + if line.startswith("- "): + continue + if line.startswith("+ "): + newdiff.append(" " + line[2:]) + else: + newdiff.append(line) + return newdiff diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/cacheprovider.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/cacheprovider.py new file mode 100644 index 0000000000000000000000000000000000000000..4383f105af619b4c22ad486623cead4d79a44219 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/cacheprovider.py @@ -0,0 +1,646 @@ +# mypy: allow-untyped-defs +"""Implementation of the cache provider.""" + +# This plugin was not named "cache" to avoid conflicts with the external +# pytest-cache version. +from __future__ import annotations + +from collections.abc import Generator +from collections.abc import Iterable +import dataclasses +import errno +import json +import os +from pathlib import Path +import tempfile +from typing import final + +from .pathlib import resolve_from_str +from .pathlib import rm_rf +from .reports import CollectReport +from _pytest import nodes +from _pytest._io import TerminalWriter +from _pytest.config import Config +from _pytest.config import ExitCode +from _pytest.config import hookimpl +from _pytest.config.argparsing import Parser +from _pytest.deprecated import check_ispytest +from _pytest.fixtures import fixture +from _pytest.fixtures import FixtureRequest +from _pytest.main import Session +from _pytest.nodes import Directory +from _pytest.nodes import File +from _pytest.reports import TestReport + + +README_CONTENT = """\ +# pytest cache directory # + +This directory contains data from the pytest's cache plugin, +which provides the `--lf` and `--ff` options, as well as the `cache` fixture. + +**Do not** commit this to version control. + +See [the docs](https://docs.pytest.org/en/stable/how-to/cache.html) for more information. +""" + +CACHEDIR_TAG_CONTENT = b"""\ +Signature: 8a477f597d28d172789f06886806bc55 +# This file is a cache directory tag created by pytest. +# For information about cache directory tags, see: +# https://bford.info/cachedir/spec.html +""" + + +@final +@dataclasses.dataclass +class Cache: + """Instance of the `cache` fixture.""" + + _cachedir: Path = dataclasses.field(repr=False) + _config: Config = dataclasses.field(repr=False) + + # Sub-directory under cache-dir for directories created by `mkdir()`. + _CACHE_PREFIX_DIRS = "d" + + # Sub-directory under cache-dir for values created by `set()`. + _CACHE_PREFIX_VALUES = "v" + + def __init__( + self, cachedir: Path, config: Config, *, _ispytest: bool = False + ) -> None: + check_ispytest(_ispytest) + self._cachedir = cachedir + self._config = config + + @classmethod + def for_config(cls, config: Config, *, _ispytest: bool = False) -> Cache: + """Create the Cache instance for a Config. + + :meta private: + """ + check_ispytest(_ispytest) + cachedir = cls.cache_dir_from_config(config, _ispytest=True) + if config.getoption("cacheclear") and cachedir.is_dir(): + cls.clear_cache(cachedir, _ispytest=True) + return cls(cachedir, config, _ispytest=True) + + @classmethod + def clear_cache(cls, cachedir: Path, _ispytest: bool = False) -> None: + """Clear the sub-directories used to hold cached directories and values. + + :meta private: + """ + check_ispytest(_ispytest) + for prefix in (cls._CACHE_PREFIX_DIRS, cls._CACHE_PREFIX_VALUES): + d = cachedir / prefix + if d.is_dir(): + rm_rf(d) + + @staticmethod + def cache_dir_from_config(config: Config, *, _ispytest: bool = False) -> Path: + """Get the path to the cache directory for a Config. + + :meta private: + """ + check_ispytest(_ispytest) + return resolve_from_str(config.getini("cache_dir"), config.rootpath) + + def warn(self, fmt: str, *, _ispytest: bool = False, **args: object) -> None: + """Issue a cache warning. + + :meta private: + """ + check_ispytest(_ispytest) + import warnings + + from _pytest.warning_types import PytestCacheWarning + + warnings.warn( + PytestCacheWarning(fmt.format(**args) if args else fmt), + self._config.hook, + stacklevel=3, + ) + + def _mkdir(self, path: Path) -> None: + self._ensure_cache_dir_and_supporting_files() + path.mkdir(exist_ok=True, parents=True) + + def mkdir(self, name: str) -> Path: + """Return a directory path object with the given name. + + If the directory does not yet exist, it will be created. You can use + it to manage files to e.g. store/retrieve database dumps across test + sessions. + + .. versionadded:: 7.0 + + :param name: + Must be a string not containing a ``/`` separator. + Make sure the name contains your plugin or application + identifiers to prevent clashes with other cache users. + """ + path = Path(name) + if len(path.parts) > 1: + raise ValueError("name is not allowed to contain path separators") + res = self._cachedir.joinpath(self._CACHE_PREFIX_DIRS, path) + self._mkdir(res) + return res + + def _getvaluepath(self, key: str) -> Path: + return self._cachedir.joinpath(self._CACHE_PREFIX_VALUES, Path(key)) + + def get(self, key: str, default): + """Return the cached value for the given key. + + If no value was yet cached or the value cannot be read, the specified + default is returned. + + :param key: + Must be a ``/`` separated value. Usually the first + name is the name of your plugin or your application. + :param default: + The value to return in case of a cache-miss or invalid cache value. + """ + path = self._getvaluepath(key) + try: + with path.open("r", encoding="UTF-8") as f: + return json.load(f) + except (ValueError, OSError): + return default + + def set(self, key: str, value: object) -> None: + """Save value for the given key. + + :param key: + Must be a ``/`` separated value. Usually the first + name is the name of your plugin or your application. + :param value: + Must be of any combination of basic python types, + including nested types like lists of dictionaries. + """ + path = self._getvaluepath(key) + try: + self._mkdir(path.parent) + except OSError as exc: + self.warn( + f"could not create cache path {path}: {exc}", + _ispytest=True, + ) + return + data = json.dumps(value, ensure_ascii=False, indent=2) + try: + f = path.open("w", encoding="UTF-8") + except OSError as exc: + self.warn( + f"cache could not write path {path}: {exc}", + _ispytest=True, + ) + else: + with f: + f.write(data) + + def _ensure_cache_dir_and_supporting_files(self) -> None: + """Create the cache dir and its supporting files.""" + if self._cachedir.is_dir(): + return + + self._cachedir.parent.mkdir(parents=True, exist_ok=True) + with tempfile.TemporaryDirectory( + prefix="pytest-cache-files-", + dir=self._cachedir.parent, + ) as newpath: + path = Path(newpath) + + # Reset permissions to the default, see #12308. + # Note: there's no way to get the current umask atomically, eek. + umask = os.umask(0o022) + os.umask(umask) + path.chmod(0o777 - umask) + + with open(path.joinpath("README.md"), "x", encoding="UTF-8") as f: + f.write(README_CONTENT) + with open(path.joinpath(".gitignore"), "x", encoding="UTF-8") as f: + f.write("# Created by pytest automatically.\n*\n") + with open(path.joinpath("CACHEDIR.TAG"), "xb") as f: + f.write(CACHEDIR_TAG_CONTENT) + + try: + path.rename(self._cachedir) + except OSError as e: + # If 2 concurrent pytests both race to the rename, the loser + # gets "Directory not empty" from the rename. In this case, + # everything is handled so just continue (while letting the + # temporary directory be cleaned up). + # On Windows, the error is a FileExistsError which translates to EEXIST. + if e.errno not in (errno.ENOTEMPTY, errno.EEXIST): + raise + else: + # Create a directory in place of the one we just moved so that + # `TemporaryDirectory`'s cleanup doesn't complain. + # + # TODO: pass ignore_cleanup_errors=True when we no longer support python < 3.10. + # See https://github.com/python/cpython/issues/74168. Note that passing + # delete=False would do the wrong thing in case of errors and isn't supported + # until python 3.12. + path.mkdir() + + +class LFPluginCollWrapper: + def __init__(self, lfplugin: LFPlugin) -> None: + self.lfplugin = lfplugin + self._collected_at_least_one_failure = False + + @hookimpl(wrapper=True) + def pytest_make_collect_report( + self, collector: nodes.Collector + ) -> Generator[None, CollectReport, CollectReport]: + res = yield + if isinstance(collector, Session | Directory): + # Sort any lf-paths to the beginning. + lf_paths = self.lfplugin._last_failed_paths + + # Use stable sort to prioritize last failed. + def sort_key(node: nodes.Item | nodes.Collector) -> bool: + return node.path in lf_paths + + res.result = sorted( + res.result, + key=sort_key, + reverse=True, + ) + + elif isinstance(collector, File): + if collector.path in self.lfplugin._last_failed_paths: + result = res.result + lastfailed = self.lfplugin.lastfailed + + # Only filter with known failures. + if not self._collected_at_least_one_failure: + if not any(x.nodeid in lastfailed for x in result): + return res + self.lfplugin.config.pluginmanager.register( + LFPluginCollSkipfiles(self.lfplugin), "lfplugin-collskip" + ) + self._collected_at_least_one_failure = True + + session = collector.session + result[:] = [ + x + for x in result + if x.nodeid in lastfailed + # Include any passed arguments (not trivial to filter). + or session.isinitpath(x.path) + # Keep all sub-collectors. + or isinstance(x, nodes.Collector) + ] + + return res + + +class LFPluginCollSkipfiles: + def __init__(self, lfplugin: LFPlugin) -> None: + self.lfplugin = lfplugin + + @hookimpl + def pytest_make_collect_report( + self, collector: nodes.Collector + ) -> CollectReport | None: + if isinstance(collector, File): + if collector.path not in self.lfplugin._last_failed_paths: + self.lfplugin._skipped_files += 1 + + return CollectReport( + collector.nodeid, "passed", longrepr=None, result=[] + ) + return None + + +class LFPlugin: + """Plugin which implements the --lf (run last-failing) option.""" + + def __init__(self, config: Config) -> None: + self.config = config + active_keys = "lf", "failedfirst" + self.active = any(config.getoption(key) for key in active_keys) + assert config.cache + self.lastfailed: dict[str, bool] = config.cache.get("cache/lastfailed", {}) + self._previously_failed_count: int | None = None + self._report_status: str | None = None + self._skipped_files = 0 # count skipped files during collection due to --lf + + if config.getoption("lf"): + self._last_failed_paths = self.get_last_failed_paths() + config.pluginmanager.register( + LFPluginCollWrapper(self), "lfplugin-collwrapper" + ) + + def get_last_failed_paths(self) -> set[Path]: + """Return a set with all Paths of the previously failed nodeids and + their parents.""" + rootpath = self.config.rootpath + result = set() + for nodeid in self.lastfailed: + path = rootpath / nodeid.split("::")[0] + result.add(path) + result.update(path.parents) + return {x for x in result if x.exists()} + + def pytest_report_collectionfinish(self) -> str | None: + if self.active and self.config.get_verbosity() >= 0: + return f"run-last-failure: {self._report_status}" + return None + + def pytest_runtest_logreport(self, report: TestReport) -> None: + if (report.when == "call" and report.passed) or report.skipped: + self.lastfailed.pop(report.nodeid, None) + elif report.failed: + self.lastfailed[report.nodeid] = True + + def pytest_collectreport(self, report: CollectReport) -> None: + passed = report.outcome in ("passed", "skipped") + if passed: + if report.nodeid in self.lastfailed: + self.lastfailed.pop(report.nodeid) + self.lastfailed.update((item.nodeid, True) for item in report.result) + else: + self.lastfailed[report.nodeid] = True + + @hookimpl(wrapper=True, tryfirst=True) + def pytest_collection_modifyitems( + self, config: Config, items: list[nodes.Item] + ) -> Generator[None]: + res = yield + + if not self.active: + return res + + if self.lastfailed: + previously_failed = [] + previously_passed = [] + for item in items: + if item.nodeid in self.lastfailed: + previously_failed.append(item) + else: + previously_passed.append(item) + self._previously_failed_count = len(previously_failed) + + if not previously_failed: + # Running a subset of all tests with recorded failures + # only outside of it. + self._report_status = ( + f"{len(self.lastfailed)} known failures not in selected tests" + ) + else: + if self.config.getoption("lf"): + items[:] = previously_failed + config.hook.pytest_deselected(items=previously_passed) + else: # --failedfirst + items[:] = previously_failed + previously_passed + + noun = "failure" if self._previously_failed_count == 1 else "failures" + suffix = " first" if self.config.getoption("failedfirst") else "" + self._report_status = ( + f"rerun previous {self._previously_failed_count} {noun}{suffix}" + ) + + if self._skipped_files > 0: + files_noun = "file" if self._skipped_files == 1 else "files" + self._report_status += f" (skipped {self._skipped_files} {files_noun})" + else: + self._report_status = "no previously failed tests, " + if self.config.getoption("last_failed_no_failures") == "none": + self._report_status += "deselecting all items." + config.hook.pytest_deselected(items=items[:]) + items[:] = [] + else: + self._report_status += "not deselecting items." + + return res + + def pytest_sessionfinish(self, session: Session) -> None: + config = self.config + if config.getoption("cacheshow") or hasattr(config, "workerinput"): + return + + assert config.cache is not None + saved_lastfailed = config.cache.get("cache/lastfailed", {}) + if saved_lastfailed != self.lastfailed: + config.cache.set("cache/lastfailed", self.lastfailed) + + +class NFPlugin: + """Plugin which implements the --nf (run new-first) option.""" + + def __init__(self, config: Config) -> None: + self.config = config + self.active = config.option.newfirst + assert config.cache is not None + self.cached_nodeids = set(config.cache.get("cache/nodeids", [])) + + @hookimpl(wrapper=True, tryfirst=True) + def pytest_collection_modifyitems(self, items: list[nodes.Item]) -> Generator[None]: + res = yield + + if self.active: + new_items: dict[str, nodes.Item] = {} + other_items: dict[str, nodes.Item] = {} + for item in items: + if item.nodeid not in self.cached_nodeids: + new_items[item.nodeid] = item + else: + other_items[item.nodeid] = item + + items[:] = self._get_increasing_order( + new_items.values() + ) + self._get_increasing_order(other_items.values()) + self.cached_nodeids.update(new_items) + else: + self.cached_nodeids.update(item.nodeid for item in items) + + return res + + def _get_increasing_order(self, items: Iterable[nodes.Item]) -> list[nodes.Item]: + return sorted(items, key=lambda item: item.path.stat().st_mtime, reverse=True) + + def pytest_sessionfinish(self) -> None: + config = self.config + if config.getoption("cacheshow") or hasattr(config, "workerinput"): + return + + if config.getoption("collectonly"): + return + + assert config.cache is not None + config.cache.set("cache/nodeids", sorted(self.cached_nodeids)) + + +def pytest_addoption(parser: Parser) -> None: + """Add command-line options for cache functionality. + + :param parser: Parser object to add command-line options to. + """ + group = parser.getgroup("general") + group.addoption( + "--lf", + "--last-failed", + action="store_true", + dest="lf", + help="Rerun only the tests that failed at the last run (or all if none failed)", + ) + group.addoption( + "--ff", + "--failed-first", + action="store_true", + dest="failedfirst", + help="Run all tests, but run the last failures first. " + "This may re-order tests and thus lead to " + "repeated fixture setup/teardown.", + ) + group.addoption( + "--nf", + "--new-first", + action="store_true", + dest="newfirst", + help="Run tests from new files first, then the rest of the tests " + "sorted by file mtime", + ) + group.addoption( + "--cache-show", + action="append", + nargs="?", + dest="cacheshow", + help=( + "Show cache contents, don't perform collection or tests. " + "Optional argument: glob (default: '*')." + ), + ) + group.addoption( + "--cache-clear", + action="store_true", + dest="cacheclear", + help="Remove all cache contents at start of test run", + ) + cache_dir_default = ".pytest_cache" + if "TOX_ENV_DIR" in os.environ: + cache_dir_default = os.path.join(os.environ["TOX_ENV_DIR"], cache_dir_default) + parser.addini("cache_dir", default=cache_dir_default, help="Cache directory path") + group.addoption( + "--lfnf", + "--last-failed-no-failures", + action="store", + dest="last_failed_no_failures", + choices=("all", "none"), + default="all", + help="With ``--lf``, determines whether to execute tests when there " + "are no previously (known) failures or when no " + "cached ``lastfailed`` data was found. " + "``all`` (the default) runs the full test suite again. " + "``none`` just emits a message about no known failures and exits successfully.", + ) + + +def pytest_cmdline_main(config: Config) -> int | ExitCode | None: + if config.option.cacheshow and not config.option.help: + from _pytest.main import wrap_session + + return wrap_session(config, cacheshow) + return None + + +@hookimpl(tryfirst=True) +def pytest_configure(config: Config) -> None: + """Configure cache system and register related plugins. + + Creates the Cache instance and registers the last-failed (LFPlugin) + and new-first (NFPlugin) plugins with the plugin manager. + + :param config: pytest configuration object. + """ + config.cache = Cache.for_config(config, _ispytest=True) + config.pluginmanager.register(LFPlugin(config), "lfplugin") + config.pluginmanager.register(NFPlugin(config), "nfplugin") + + +@fixture +def cache(request: FixtureRequest) -> Cache: + """Return a cache object that can persist state between testing sessions. + + cache.get(key, default) + cache.set(key, value) + + Keys must be ``/`` separated strings, where the first part is usually the + name of your plugin or application to avoid clashes with other cache users. + + Values can be any object handled by the json stdlib module. + """ + assert request.config.cache is not None + return request.config.cache + + +def pytest_report_header(config: Config) -> str | None: + """Display cachedir with --cache-show and if non-default.""" + if config.option.verbose > 0 or config.getini("cache_dir") != ".pytest_cache": + assert config.cache is not None + cachedir = config.cache._cachedir + # TODO: evaluate generating upward relative paths + # starting with .., ../.. if sensible + + try: + displaypath = cachedir.relative_to(config.rootpath) + except ValueError: + displaypath = cachedir + return f"cachedir: {displaypath}" + return None + + +def cacheshow(config: Config, session: Session) -> int: + """Display cache contents when --cache-show is used. + + Shows cached values and directories matching the specified glob pattern + (default: '*'). Displays cache location, cached test results, and + any cached directories created by plugins. + + :param config: pytest configuration object. + :param session: pytest session object. + :returns: Exit code (0 for success). + """ + from pprint import pformat + + assert config.cache is not None + + tw = TerminalWriter() + tw.line("cachedir: " + str(config.cache._cachedir)) + if not config.cache._cachedir.is_dir(): + tw.line("cache is empty") + return 0 + + glob = config.option.cacheshow[0] + if glob is None: + glob = "*" + + dummy = object() + basedir = config.cache._cachedir + vdir = basedir / Cache._CACHE_PREFIX_VALUES + tw.sep("-", f"cache values for {glob!r}") + for valpath in sorted(x for x in vdir.rglob(glob) if x.is_file()): + key = str(valpath.relative_to(vdir)) + val = config.cache.get(key, dummy) + if val is dummy: + tw.line(f"{key} contains unreadable content, will be ignored") + else: + tw.line(f"{key} contains:") + for line in pformat(val).splitlines(): + tw.line(" " + line) + + ddir = basedir / Cache._CACHE_PREFIX_DIRS + if ddir.is_dir(): + contents = sorted(ddir.rglob(glob)) + tw.sep("-", f"cache directories for {glob!r}") + for p in contents: + # if p.is_dir(): + # print("%s/" % p.relative_to(basedir)) + if p.is_file(): + key = str(p.relative_to(basedir)) + tw.line(f"{key} is a file of length {p.stat().st_size}") + return 0 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/capture.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/capture.py new file mode 100644 index 0000000000000000000000000000000000000000..6d98676be5f20166929164e39fd0eeb17a24db20 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/capture.py @@ -0,0 +1,1144 @@ +# mypy: allow-untyped-defs +"""Per-test stdout/stderr capturing mechanism.""" + +from __future__ import annotations + +import abc +import collections +from collections.abc import Generator +from collections.abc import Iterable +from collections.abc import Iterator +import contextlib +import io +from io import UnsupportedOperation +import os +import sys +from tempfile import TemporaryFile +from types import TracebackType +from typing import Any +from typing import AnyStr +from typing import BinaryIO +from typing import cast +from typing import Final +from typing import final +from typing import Generic +from typing import Literal +from typing import NamedTuple +from typing import TextIO +from typing import TYPE_CHECKING + + +if TYPE_CHECKING: + from typing_extensions import Self + +from _pytest.config import Config +from _pytest.config import hookimpl +from _pytest.config.argparsing import Parser +from _pytest.deprecated import check_ispytest +from _pytest.fixtures import fixture +from _pytest.fixtures import SubRequest +from _pytest.nodes import Collector +from _pytest.nodes import File +from _pytest.nodes import Item +from _pytest.reports import CollectReport + + +_CaptureMethod = Literal["fd", "sys", "no", "tee-sys"] + + +def pytest_addoption(parser: Parser) -> None: + group = parser.getgroup("general") + group.addoption( + "--capture", + action="store", + default="fd", + metavar="method", + choices=["fd", "sys", "no", "tee-sys"], + help="Per-test capturing method: one of fd|sys|no|tee-sys", + ) + group._addoption( # private to use reserved lower-case short option + "-s", + action="store_const", + const="no", + dest="capture", + help="Shortcut for --capture=no", + ) + + +def _colorama_workaround() -> None: + """Ensure colorama is imported so that it attaches to the correct stdio + handles on Windows. + + colorama uses the terminal on import time. So if something does the + first import of colorama while I/O capture is active, colorama will + fail in various ways. + """ + if sys.platform.startswith("win32"): + try: + import colorama # noqa: F401 + except ImportError: + pass + + +def _readline_workaround() -> None: + """Ensure readline is imported early so it attaches to the correct stdio handles. + + This isn't a problem with the default GNU readline implementation, but in + some configurations, Python uses libedit instead (on macOS, and for prebuilt + binaries such as used by uv). + + In theory this is only needed if readline.backend == "libedit", but the + workaround consists of importing readline here, so we already worked around + the issue by the time we could check if we need to. + """ + try: + import readline # noqa: F401 + except ImportError: + pass + + +def _windowsconsoleio_workaround(stream: TextIO) -> None: + """Workaround for Windows Unicode console handling. + + Python 3.6 implemented Unicode console handling for Windows. This works + by reading/writing to the raw console handle using + ``{Read,Write}ConsoleW``. + + The problem is that we are going to ``dup2`` over the stdio file + descriptors when doing ``FDCapture`` and this will ``CloseHandle`` the + handles used by Python to write to the console. Though there is still some + weirdness and the console handle seems to only be closed randomly and not + on the first call to ``CloseHandle``, or maybe it gets reopened with the + same handle value when we suspend capturing. + + The workaround in this case will reopen stdio with a different fd which + also means a different handle by replicating the logic in + "Py_lifecycle.c:initstdio/create_stdio". + + :param stream: + In practice ``sys.stdout`` or ``sys.stderr``, but given + here as parameter for unittesting purposes. + + See https://github.com/pytest-dev/py/issues/103. + """ + if not sys.platform.startswith("win32") or hasattr(sys, "pypy_version_info"): + return + + # Bail out if ``stream`` doesn't seem like a proper ``io`` stream (#2666). + if not hasattr(stream, "buffer"): # type: ignore[unreachable,unused-ignore] + return + + raw_stdout = stream.buffer.raw if hasattr(stream.buffer, "raw") else stream.buffer + + if not isinstance(raw_stdout, io._WindowsConsoleIO): # type: ignore[attr-defined,unused-ignore] + return + + def _reopen_stdio(f, mode): + if not hasattr(stream.buffer, "raw") and mode[0] == "w": + buffering = 0 + else: + buffering = -1 + + return io.TextIOWrapper( + open(os.dup(f.fileno()), mode, buffering), + f.encoding, + f.errors, + f.newlines, + f.line_buffering, + ) + + sys.stdin = _reopen_stdio(sys.stdin, "rb") + sys.stdout = _reopen_stdio(sys.stdout, "wb") + sys.stderr = _reopen_stdio(sys.stderr, "wb") + + +@hookimpl(wrapper=True) +def pytest_load_initial_conftests(early_config: Config) -> Generator[None]: + ns = early_config.known_args_namespace + if ns.capture == "fd": + _windowsconsoleio_workaround(sys.stdout) + _colorama_workaround() + _readline_workaround() + pluginmanager = early_config.pluginmanager + capman = CaptureManager(ns.capture) + pluginmanager.register(capman, "capturemanager") + + # Make sure that capturemanager is properly reset at final shutdown. + early_config.add_cleanup(capman.stop_global_capturing) + + # Finally trigger conftest loading but while capturing (issue #93). + capman.start_global_capturing() + try: + try: + yield + finally: + capman.suspend_global_capture() + except BaseException: + out, err = capman.read_global_capture() + sys.stdout.write(out) + sys.stderr.write(err) + raise + + +# IO Helpers. + + +class EncodedFile(io.TextIOWrapper): + __slots__ = () + + @property + def name(self) -> str: + # Ensure that file.name is a string. Workaround for a Python bug + # fixed in >=3.7.4: https://bugs.python.org/issue36015 + return repr(self.buffer) + + @property + def mode(self) -> str: + # TextIOWrapper doesn't expose a mode, but at least some of our + # tests check it. + assert hasattr(self.buffer, "mode") + return cast(str, self.buffer.mode.replace("b", "")) + + +class CaptureIO(io.TextIOWrapper): + def __init__(self) -> None: + super().__init__(io.BytesIO(), encoding="UTF-8", newline="", write_through=True) + + def getvalue(self) -> str: + assert isinstance(self.buffer, io.BytesIO) + return self.buffer.getvalue().decode("UTF-8") + + +class TeeCaptureIO(CaptureIO): + def __init__(self, other: TextIO) -> None: + self._other = other + super().__init__() + + def write(self, s: str) -> int: + super().write(s) + return self._other.write(s) + + +class DontReadFromInput(TextIO): + @property + def encoding(self) -> str: + assert sys.__stdin__ is not None + return sys.__stdin__.encoding + + def read(self, size: int = -1) -> str: + raise OSError( + "pytest: reading from stdin while output is captured! Consider using `-s`." + ) + + readline = read + + def __next__(self) -> str: + return self.readline() + + def readlines(self, hint: int | None = -1) -> list[str]: + raise OSError( + "pytest: reading from stdin while output is captured! Consider using `-s`." + ) + + def __iter__(self) -> Iterator[str]: + return self + + def fileno(self) -> int: + raise UnsupportedOperation("redirected stdin is pseudofile, has no fileno()") + + def flush(self) -> None: + raise UnsupportedOperation("redirected stdin is pseudofile, has no flush()") + + def isatty(self) -> bool: + return False + + def close(self) -> None: + pass + + def readable(self) -> bool: + return False + + def seek(self, offset: int, whence: int = 0) -> int: + raise UnsupportedOperation("redirected stdin is pseudofile, has no seek(int)") + + def seekable(self) -> bool: + return False + + def tell(self) -> int: + raise UnsupportedOperation("redirected stdin is pseudofile, has no tell()") + + def truncate(self, size: int | None = None) -> int: + raise UnsupportedOperation("cannot truncate stdin") + + def write(self, data: str) -> int: + raise UnsupportedOperation("cannot write to stdin") + + def writelines(self, lines: Iterable[str]) -> None: + raise UnsupportedOperation("Cannot write to stdin") + + def writable(self) -> bool: + return False + + def __enter__(self) -> Self: + return self + + def __exit__( + self, + type: type[BaseException] | None, + value: BaseException | None, + traceback: TracebackType | None, + ) -> None: + pass + + @property + def buffer(self) -> BinaryIO: + # The str/bytes doesn't actually matter in this type, so OK to fake. + return self # type: ignore[return-value] + + +# Capture classes. + + +class CaptureBase(abc.ABC, Generic[AnyStr]): + EMPTY_BUFFER: AnyStr + + @abc.abstractmethod + def __init__(self, fd: int) -> None: + raise NotImplementedError() + + @abc.abstractmethod + def start(self) -> None: + raise NotImplementedError() + + @abc.abstractmethod + def done(self) -> None: + raise NotImplementedError() + + @abc.abstractmethod + def suspend(self) -> None: + raise NotImplementedError() + + @abc.abstractmethod + def resume(self) -> None: + raise NotImplementedError() + + @abc.abstractmethod + def writeorg(self, data: AnyStr) -> None: + raise NotImplementedError() + + @abc.abstractmethod + def snap(self) -> AnyStr: + raise NotImplementedError() + + +patchsysdict = {0: "stdin", 1: "stdout", 2: "stderr"} + + +class NoCapture(CaptureBase[str]): + EMPTY_BUFFER = "" + + def __init__(self, fd: int) -> None: + pass + + def start(self) -> None: + pass + + def done(self) -> None: + pass + + def suspend(self) -> None: + pass + + def resume(self) -> None: + pass + + def snap(self) -> str: + return "" + + def writeorg(self, data: str) -> None: + pass + + +class SysCaptureBase(CaptureBase[AnyStr]): + def __init__( + self, fd: int, tmpfile: TextIO | None = None, *, tee: bool = False + ) -> None: + name = patchsysdict[fd] + self._old: TextIO = getattr(sys, name) + self.name = name + if tmpfile is None: + if name == "stdin": + tmpfile = DontReadFromInput() + else: + tmpfile = CaptureIO() if not tee else TeeCaptureIO(self._old) + self.tmpfile = tmpfile + self._state = "initialized" + + def repr(self, class_name: str) -> str: + return "<{} {} _old={} _state={!r} tmpfile={!r}>".format( + class_name, + self.name, + (hasattr(self, "_old") and repr(self._old)) or "<UNSET>", + self._state, + self.tmpfile, + ) + + def __repr__(self) -> str: + return "<{} {} _old={} _state={!r} tmpfile={!r}>".format( + self.__class__.__name__, + self.name, + (hasattr(self, "_old") and repr(self._old)) or "<UNSET>", + self._state, + self.tmpfile, + ) + + def _assert_state(self, op: str, states: tuple[str, ...]) -> None: + assert self._state in states, ( + "cannot {} in state {!r}: expected one of {}".format( + op, self._state, ", ".join(states) + ) + ) + + def start(self) -> None: + self._assert_state("start", ("initialized",)) + setattr(sys, self.name, self.tmpfile) + self._state = "started" + + def done(self) -> None: + self._assert_state("done", ("initialized", "started", "suspended", "done")) + if self._state == "done": + return + setattr(sys, self.name, self._old) + del self._old + self.tmpfile.close() + self._state = "done" + + def suspend(self) -> None: + self._assert_state("suspend", ("started", "suspended")) + setattr(sys, self.name, self._old) + self._state = "suspended" + + def resume(self) -> None: + self._assert_state("resume", ("started", "suspended")) + if self._state == "started": + return + setattr(sys, self.name, self.tmpfile) + self._state = "started" + + +class SysCaptureBinary(SysCaptureBase[bytes]): + EMPTY_BUFFER = b"" + + def snap(self) -> bytes: + self._assert_state("snap", ("started", "suspended")) + self.tmpfile.seek(0) + res = self.tmpfile.buffer.read() + self.tmpfile.seek(0) + self.tmpfile.truncate() + return res + + def writeorg(self, data: bytes) -> None: + self._assert_state("writeorg", ("started", "suspended")) + self._old.flush() + self._old.buffer.write(data) + self._old.buffer.flush() + + +class SysCapture(SysCaptureBase[str]): + EMPTY_BUFFER = "" + + def snap(self) -> str: + self._assert_state("snap", ("started", "suspended")) + assert isinstance(self.tmpfile, CaptureIO) + res = self.tmpfile.getvalue() + self.tmpfile.seek(0) + self.tmpfile.truncate() + return res + + def writeorg(self, data: str) -> None: + self._assert_state("writeorg", ("started", "suspended")) + self._old.write(data) + self._old.flush() + + +class FDCaptureBase(CaptureBase[AnyStr]): + def __init__(self, targetfd: int) -> None: + self.targetfd = targetfd + + try: + os.fstat(targetfd) + except OSError: + # FD capturing is conceptually simple -- create a temporary file, + # redirect the FD to it, redirect back when done. But when the + # target FD is invalid it throws a wrench into this lovely scheme. + # + # Tests themselves shouldn't care if the FD is valid, FD capturing + # should work regardless of external circumstances. So falling back + # to just sys capturing is not a good option. + # + # Further complications are the need to support suspend() and the + # possibility of FD reuse (e.g. the tmpfile getting the very same + # target FD). The following approach is robust, I believe. + self.targetfd_invalid: int | None = os.open(os.devnull, os.O_RDWR) + os.dup2(self.targetfd_invalid, targetfd) + else: + self.targetfd_invalid = None + self.targetfd_save = os.dup(targetfd) + + if targetfd == 0: + self.tmpfile = open(os.devnull, encoding="utf-8") + self.syscapture: CaptureBase[str] = SysCapture(targetfd) + else: + self.tmpfile = EncodedFile( + TemporaryFile(buffering=0), + encoding="utf-8", + errors="replace", + newline="", + write_through=True, + ) + if targetfd in patchsysdict: + self.syscapture = SysCapture(targetfd, self.tmpfile) + else: + self.syscapture = NoCapture(targetfd) + + self._state = "initialized" + + def __repr__(self) -> str: + return ( + f"<{self.__class__.__name__} {self.targetfd} oldfd={self.targetfd_save} " + f"_state={self._state!r} tmpfile={self.tmpfile!r}>" + ) + + def _assert_state(self, op: str, states: tuple[str, ...]) -> None: + assert self._state in states, ( + "cannot {} in state {!r}: expected one of {}".format( + op, self._state, ", ".join(states) + ) + ) + + def start(self) -> None: + """Start capturing on targetfd using memorized tmpfile.""" + self._assert_state("start", ("initialized",)) + os.dup2(self.tmpfile.fileno(), self.targetfd) + self.syscapture.start() + self._state = "started" + + def done(self) -> None: + """Stop capturing, restore streams, return original capture file, + seeked to position zero.""" + self._assert_state("done", ("initialized", "started", "suspended", "done")) + if self._state == "done": + return + os.dup2(self.targetfd_save, self.targetfd) + os.close(self.targetfd_save) + if self.targetfd_invalid is not None: + if self.targetfd_invalid != self.targetfd: + os.close(self.targetfd) + os.close(self.targetfd_invalid) + self.syscapture.done() + self.tmpfile.close() + self._state = "done" + + def suspend(self) -> None: + self._assert_state("suspend", ("started", "suspended")) + if self._state == "suspended": + return + self.syscapture.suspend() + os.dup2(self.targetfd_save, self.targetfd) + self._state = "suspended" + + def resume(self) -> None: + self._assert_state("resume", ("started", "suspended")) + if self._state == "started": + return + self.syscapture.resume() + os.dup2(self.tmpfile.fileno(), self.targetfd) + self._state = "started" + + +class FDCaptureBinary(FDCaptureBase[bytes]): + """Capture IO to/from a given OS-level file descriptor. + + snap() produces `bytes`. + """ + + EMPTY_BUFFER = b"" + + def snap(self) -> bytes: + self._assert_state("snap", ("started", "suspended")) + self.tmpfile.seek(0) + res = self.tmpfile.buffer.read() + self.tmpfile.seek(0) + self.tmpfile.truncate() + return res # type: ignore[return-value] + + def writeorg(self, data: bytes) -> None: + """Write to original file descriptor.""" + self._assert_state("writeorg", ("started", "suspended")) + os.write(self.targetfd_save, data) + + +class FDCapture(FDCaptureBase[str]): + """Capture IO to/from a given OS-level file descriptor. + + snap() produces text. + """ + + EMPTY_BUFFER = "" + + def snap(self) -> str: + self._assert_state("snap", ("started", "suspended")) + self.tmpfile.seek(0) + res = self.tmpfile.read() + self.tmpfile.seek(0) + self.tmpfile.truncate() + return res + + def writeorg(self, data: str) -> None: + """Write to original file descriptor.""" + self._assert_state("writeorg", ("started", "suspended")) + # XXX use encoding of original stream + os.write(self.targetfd_save, data.encode("utf-8")) + + +# MultiCapture + + +# Generic NamedTuple only supported since Python 3.11. +if sys.version_info >= (3, 11) or TYPE_CHECKING: + + @final + class CaptureResult(NamedTuple, Generic[AnyStr]): + """The result of :method:`caplog.readouterr() <pytest.CaptureFixture.readouterr>`.""" + + out: AnyStr + err: AnyStr + +else: + + class CaptureResult( + collections.namedtuple("CaptureResult", ["out", "err"]), # noqa: PYI024 + Generic[AnyStr], + ): + """The result of :method:`caplog.readouterr() <pytest.CaptureFixture.readouterr>`.""" + + __slots__ = () + + +class MultiCapture(Generic[AnyStr]): + _state = None + _in_suspended = False + + def __init__( + self, + in_: CaptureBase[AnyStr] | None, + out: CaptureBase[AnyStr] | None, + err: CaptureBase[AnyStr] | None, + ) -> None: + self.in_: CaptureBase[AnyStr] | None = in_ + self.out: CaptureBase[AnyStr] | None = out + self.err: CaptureBase[AnyStr] | None = err + + def __repr__(self) -> str: + return ( + f"<MultiCapture out={self.out!r} err={self.err!r} in_={self.in_!r} " + f"_state={self._state!r} _in_suspended={self._in_suspended!r}>" + ) + + def start_capturing(self) -> None: + self._state = "started" + if self.in_: + self.in_.start() + if self.out: + self.out.start() + if self.err: + self.err.start() + + def pop_outerr_to_orig(self) -> tuple[AnyStr, AnyStr]: + """Pop current snapshot out/err capture and flush to orig streams.""" + out, err = self.readouterr() + if out: + assert self.out is not None + self.out.writeorg(out) + if err: + assert self.err is not None + self.err.writeorg(err) + return out, err + + def suspend_capturing(self, in_: bool = False) -> None: + self._state = "suspended" + if self.out: + self.out.suspend() + if self.err: + self.err.suspend() + if in_ and self.in_: + self.in_.suspend() + self._in_suspended = True + + def resume_capturing(self) -> None: + self._state = "started" + if self.out: + self.out.resume() + if self.err: + self.err.resume() + if self._in_suspended: + assert self.in_ is not None + self.in_.resume() + self._in_suspended = False + + def stop_capturing(self) -> None: + """Stop capturing and reset capturing streams.""" + if self._state == "stopped": + raise ValueError("was already stopped") + self._state = "stopped" + if self.out: + self.out.done() + if self.err: + self.err.done() + if self.in_: + self.in_.done() + + def is_started(self) -> bool: + """Whether actively capturing -- not suspended or stopped.""" + return self._state == "started" + + def readouterr(self) -> CaptureResult[AnyStr]: + out = self.out.snap() if self.out else "" + err = self.err.snap() if self.err else "" + # TODO: This type error is real, need to fix. + return CaptureResult(out, err) # type: ignore[arg-type] + + +def _get_multicapture(method: _CaptureMethod) -> MultiCapture[str]: + if method == "fd": + return MultiCapture(in_=FDCapture(0), out=FDCapture(1), err=FDCapture(2)) + elif method == "sys": + return MultiCapture(in_=SysCapture(0), out=SysCapture(1), err=SysCapture(2)) + elif method == "no": + return MultiCapture(in_=None, out=None, err=None) + elif method == "tee-sys": + return MultiCapture( + in_=None, out=SysCapture(1, tee=True), err=SysCapture(2, tee=True) + ) + raise ValueError(f"unknown capturing method: {method!r}") + + +# CaptureManager and CaptureFixture + + +class CaptureManager: + """The capture plugin. + + Manages that the appropriate capture method is enabled/disabled during + collection and each test phase (setup, call, teardown). After each of + those points, the captured output is obtained and attached to the + collection/runtest report. + + There are two levels of capture: + + * global: enabled by default and can be suppressed by the ``-s`` + option. This is always enabled/disabled during collection and each test + phase. + + * fixture: when a test function or one of its fixture depend on the + ``capsys`` or ``capfd`` fixtures. In this case special handling is + needed to ensure the fixtures take precedence over the global capture. + """ + + def __init__(self, method: _CaptureMethod) -> None: + self._method: Final = method + self._global_capturing: MultiCapture[str] | None = None + self._capture_fixture: CaptureFixture[Any] | None = None + + def __repr__(self) -> str: + return ( + f"<CaptureManager _method={self._method!r} _global_capturing={self._global_capturing!r} " + f"_capture_fixture={self._capture_fixture!r}>" + ) + + def is_capturing(self) -> str | bool: + if self.is_globally_capturing(): + return "global" + if self._capture_fixture: + return f"fixture {self._capture_fixture.request.fixturename}" + return False + + # Global capturing control + + def is_globally_capturing(self) -> bool: + return self._method != "no" + + def start_global_capturing(self) -> None: + assert self._global_capturing is None + self._global_capturing = _get_multicapture(self._method) + self._global_capturing.start_capturing() + + def stop_global_capturing(self) -> None: + if self._global_capturing is not None: + self._global_capturing.pop_outerr_to_orig() + self._global_capturing.stop_capturing() + self._global_capturing = None + + def resume_global_capture(self) -> None: + # During teardown of the python process, and on rare occasions, capture + # attributes can be `None` while trying to resume global capture. + if self._global_capturing is not None: + self._global_capturing.resume_capturing() + + def suspend_global_capture(self, in_: bool = False) -> None: + if self._global_capturing is not None: + self._global_capturing.suspend_capturing(in_=in_) + + def suspend(self, in_: bool = False) -> None: + # Need to undo local capsys-et-al if it exists before disabling global capture. + self.suspend_fixture() + self.suspend_global_capture(in_) + + def resume(self) -> None: + self.resume_global_capture() + self.resume_fixture() + + def read_global_capture(self) -> CaptureResult[str]: + assert self._global_capturing is not None + return self._global_capturing.readouterr() + + # Fixture Control + + def set_fixture(self, capture_fixture: CaptureFixture[Any]) -> None: + if self._capture_fixture: + current_fixture = self._capture_fixture.request.fixturename + requested_fixture = capture_fixture.request.fixturename + capture_fixture.request.raiseerror( + f"cannot use {requested_fixture} and {current_fixture} at the same time" + ) + self._capture_fixture = capture_fixture + + def unset_fixture(self) -> None: + self._capture_fixture = None + + def activate_fixture(self) -> None: + """If the current item is using ``capsys`` or ``capfd``, activate + them so they take precedence over the global capture.""" + if self._capture_fixture: + self._capture_fixture._start() + + def deactivate_fixture(self) -> None: + """Deactivate the ``capsys`` or ``capfd`` fixture of this item, if any.""" + if self._capture_fixture: + self._capture_fixture.close() + + def suspend_fixture(self) -> None: + if self._capture_fixture: + self._capture_fixture._suspend() + + def resume_fixture(self) -> None: + if self._capture_fixture: + self._capture_fixture._resume() + + # Helper context managers + + @contextlib.contextmanager + def global_and_fixture_disabled(self) -> Generator[None]: + """Context manager to temporarily disable global and current fixture capturing.""" + do_fixture = self._capture_fixture and self._capture_fixture._is_started() + if do_fixture: + self.suspend_fixture() + do_global = self._global_capturing and self._global_capturing.is_started() + if do_global: + self.suspend_global_capture() + try: + yield + finally: + if do_global: + self.resume_global_capture() + if do_fixture: + self.resume_fixture() + + @contextlib.contextmanager + def item_capture(self, when: str, item: Item) -> Generator[None]: + self.resume_global_capture() + self.activate_fixture() + try: + yield + finally: + self.deactivate_fixture() + self.suspend_global_capture(in_=False) + + out, err = self.read_global_capture() + item.add_report_section(when, "stdout", out) + item.add_report_section(when, "stderr", err) + + # Hooks + + @hookimpl(wrapper=True) + def pytest_make_collect_report( + self, collector: Collector + ) -> Generator[None, CollectReport, CollectReport]: + if isinstance(collector, File): + self.resume_global_capture() + try: + rep = yield + finally: + self.suspend_global_capture() + out, err = self.read_global_capture() + if out: + rep.sections.append(("Captured stdout", out)) + if err: + rep.sections.append(("Captured stderr", err)) + else: + rep = yield + return rep + + @hookimpl(wrapper=True) + def pytest_runtest_setup(self, item: Item) -> Generator[None]: + with self.item_capture("setup", item): + return (yield) + + @hookimpl(wrapper=True) + def pytest_runtest_call(self, item: Item) -> Generator[None]: + with self.item_capture("call", item): + return (yield) + + @hookimpl(wrapper=True) + def pytest_runtest_teardown(self, item: Item) -> Generator[None]: + with self.item_capture("teardown", item): + return (yield) + + @hookimpl(tryfirst=True) + def pytest_keyboard_interrupt(self) -> None: + self.stop_global_capturing() + + @hookimpl(tryfirst=True) + def pytest_internalerror(self) -> None: + self.stop_global_capturing() + + +class CaptureFixture(Generic[AnyStr]): + """Object returned by the :fixture:`capsys`, :fixture:`capsysbinary`, + :fixture:`capfd` and :fixture:`capfdbinary` fixtures.""" + + def __init__( + self, + captureclass: type[CaptureBase[AnyStr]], + request: SubRequest, + *, + config: dict[str, Any] | None = None, + _ispytest: bool = False, + ) -> None: + check_ispytest(_ispytest) + self.captureclass: type[CaptureBase[AnyStr]] = captureclass + self.request = request + self._config = config if config else {} + self._capture: MultiCapture[AnyStr] | None = None + self._captured_out: AnyStr = self.captureclass.EMPTY_BUFFER + self._captured_err: AnyStr = self.captureclass.EMPTY_BUFFER + + def _start(self) -> None: + if self._capture is None: + self._capture = MultiCapture( + in_=None, + out=self.captureclass(1, **self._config), + err=self.captureclass(2, **self._config), + ) + self._capture.start_capturing() + + def close(self) -> None: + if self._capture is not None: + out, err = self._capture.pop_outerr_to_orig() + self._captured_out += out + self._captured_err += err + self._capture.stop_capturing() + self._capture = None + + def readouterr(self) -> CaptureResult[AnyStr]: + """Read and return the captured output so far, resetting the internal + buffer. + + :returns: + The captured content as a namedtuple with ``out`` and ``err`` + string attributes. + """ + captured_out, captured_err = self._captured_out, self._captured_err + if self._capture is not None: + out, err = self._capture.readouterr() + captured_out += out + captured_err += err + self._captured_out = self.captureclass.EMPTY_BUFFER + self._captured_err = self.captureclass.EMPTY_BUFFER + return CaptureResult(captured_out, captured_err) + + def _suspend(self) -> None: + """Suspend this fixture's own capturing temporarily.""" + if self._capture is not None: + self._capture.suspend_capturing() + + def _resume(self) -> None: + """Resume this fixture's own capturing temporarily.""" + if self._capture is not None: + self._capture.resume_capturing() + + def _is_started(self) -> bool: + """Whether actively capturing -- not disabled or closed.""" + if self._capture is not None: + return self._capture.is_started() + return False + + @contextlib.contextmanager + def disabled(self) -> Generator[None]: + """Temporarily disable capturing while inside the ``with`` block.""" + capmanager: CaptureManager = self.request.config.pluginmanager.getplugin( + "capturemanager" + ) + with capmanager.global_and_fixture_disabled(): + yield + + +# The fixtures. + + +@fixture +def capsys(request: SubRequest) -> Generator[CaptureFixture[str]]: + r"""Enable text capturing of writes to ``sys.stdout`` and ``sys.stderr``. + + The captured output is made available via ``capsys.readouterr()`` method + calls, which return a ``(out, err)`` namedtuple. + ``out`` and ``err`` will be ``text`` objects. + + Returns an instance of :class:`CaptureFixture[str] <pytest.CaptureFixture>`. + + Example: + + .. code-block:: python + + def test_output(capsys): + print("hello") + captured = capsys.readouterr() + assert captured.out == "hello\n" + """ + capman: CaptureManager = request.config.pluginmanager.getplugin("capturemanager") + capture_fixture = CaptureFixture(SysCapture, request, _ispytest=True) + capman.set_fixture(capture_fixture) + capture_fixture._start() + yield capture_fixture + capture_fixture.close() + capman.unset_fixture() + + +@fixture +def capteesys(request: SubRequest) -> Generator[CaptureFixture[str]]: + r"""Enable simultaneous text capturing and pass-through of writes + to ``sys.stdout`` and ``sys.stderr`` as defined by ``--capture=``. + + + The captured output is made available via ``capteesys.readouterr()`` method + calls, which return a ``(out, err)`` namedtuple. + ``out`` and ``err`` will be ``text`` objects. + + The output is also passed-through, allowing it to be "live-printed", + reported, or both as defined by ``--capture=``. + + Returns an instance of :class:`CaptureFixture[str] <pytest.CaptureFixture>`. + + Example: + + .. code-block:: python + + def test_output(capteesys): + print("hello") + captured = capteesys.readouterr() + assert captured.out == "hello\n" + """ + capman: CaptureManager = request.config.pluginmanager.getplugin("capturemanager") + capture_fixture = CaptureFixture( + SysCapture, request, config=dict(tee=True), _ispytest=True + ) + capman.set_fixture(capture_fixture) + capture_fixture._start() + yield capture_fixture + capture_fixture.close() + capman.unset_fixture() + + +@fixture +def capsysbinary(request: SubRequest) -> Generator[CaptureFixture[bytes]]: + r"""Enable bytes capturing of writes to ``sys.stdout`` and ``sys.stderr``. + + The captured output is made available via ``capsysbinary.readouterr()`` + method calls, which return a ``(out, err)`` namedtuple. + ``out`` and ``err`` will be ``bytes`` objects. + + Returns an instance of :class:`CaptureFixture[bytes] <pytest.CaptureFixture>`. + + Example: + + .. code-block:: python + + def test_output(capsysbinary): + print("hello") + captured = capsysbinary.readouterr() + assert captured.out == b"hello\n" + """ + capman: CaptureManager = request.config.pluginmanager.getplugin("capturemanager") + capture_fixture = CaptureFixture(SysCaptureBinary, request, _ispytest=True) + capman.set_fixture(capture_fixture) + capture_fixture._start() + yield capture_fixture + capture_fixture.close() + capman.unset_fixture() + + +@fixture +def capfd(request: SubRequest) -> Generator[CaptureFixture[str]]: + r"""Enable text capturing of writes to file descriptors ``1`` and ``2``. + + The captured output is made available via ``capfd.readouterr()`` method + calls, which return a ``(out, err)`` namedtuple. + ``out`` and ``err`` will be ``text`` objects. + + Returns an instance of :class:`CaptureFixture[str] <pytest.CaptureFixture>`. + + Example: + + .. code-block:: python + + def test_system_echo(capfd): + os.system('echo "hello"') + captured = capfd.readouterr() + assert captured.out == "hello\n" + """ + capman: CaptureManager = request.config.pluginmanager.getplugin("capturemanager") + capture_fixture = CaptureFixture(FDCapture, request, _ispytest=True) + capman.set_fixture(capture_fixture) + capture_fixture._start() + yield capture_fixture + capture_fixture.close() + capman.unset_fixture() + + +@fixture +def capfdbinary(request: SubRequest) -> Generator[CaptureFixture[bytes]]: + r"""Enable bytes capturing of writes to file descriptors ``1`` and ``2``. + + The captured output is made available via ``capfd.readouterr()`` method + calls, which return a ``(out, err)`` namedtuple. + ``out`` and ``err`` will be ``byte`` objects. + + Returns an instance of :class:`CaptureFixture[bytes] <pytest.CaptureFixture>`. + + Example: + + .. code-block:: python + + def test_system_echo(capfdbinary): + os.system('echo "hello"') + captured = capfdbinary.readouterr() + assert captured.out == b"hello\n" + + """ + capman: CaptureManager = request.config.pluginmanager.getplugin("capturemanager") + capture_fixture = CaptureFixture(FDCaptureBinary, request, _ispytest=True) + capman.set_fixture(capture_fixture) + capture_fixture._start() + yield capture_fixture + capture_fixture.close() + capman.unset_fixture() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/compat.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/compat.py new file mode 100644 index 0000000000000000000000000000000000000000..72c3d0918fb1d18d7ab538e3e7309209730ece96 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/compat.py @@ -0,0 +1,314 @@ +# mypy: allow-untyped-defs +"""Python version compatibility code and random general utilities.""" + +from __future__ import annotations + +from collections.abc import Callable +import enum +import functools +import inspect +from inspect import Parameter +from inspect import Signature +import os +from pathlib import Path +import sys +from typing import Any +from typing import Final +from typing import NoReturn + +import py + + +if sys.version_info >= (3, 14): + from annotationlib import Format + + +#: constant to prepare valuing pylib path replacements/lazy proxies later on +# intended for removal in pytest 8.0 or 9.0 + +# fmt: off +# intentional space to create a fake difference for the verification +LEGACY_PATH = py.path. local +# fmt: on + + +def legacy_path(path: str | os.PathLike[str]) -> LEGACY_PATH: + """Internal wrapper to prepare lazy proxies for legacy_path instances""" + return LEGACY_PATH(path) + + +# fmt: off +# Singleton type for NOTSET, as described in: +# https://www.python.org/dev/peps/pep-0484/#support-for-singleton-types-in-unions +class NotSetType(enum.Enum): + token = 0 +NOTSET: Final = NotSetType.token +# fmt: on + + +def iscoroutinefunction(func: object) -> bool: + """Return True if func is a coroutine function (a function defined with async + def syntax, and doesn't contain yield), or a function decorated with + @asyncio.coroutine. + + Note: copied and modified from Python 3.5's builtin coroutines.py to avoid + importing asyncio directly, which in turns also initializes the "logging" + module as a side-effect (see issue #8). + """ + return inspect.iscoroutinefunction(func) or getattr(func, "_is_coroutine", False) + + +def is_async_function(func: object) -> bool: + """Return True if the given function seems to be an async function or + an async generator.""" + return iscoroutinefunction(func) or inspect.isasyncgenfunction(func) + + +def signature(obj: Callable[..., Any]) -> Signature: + """Return signature without evaluating annotations.""" + if sys.version_info >= (3, 14): + return inspect.signature(obj, annotation_format=Format.STRING) + return inspect.signature(obj) + + +def getlocation(function, curdir: str | os.PathLike[str] | None = None) -> str: + function = get_real_func(function) + fn = Path(inspect.getfile(function)) + lineno = function.__code__.co_firstlineno + if curdir is not None: + try: + relfn = fn.relative_to(curdir) + except ValueError: + pass + else: + return f"{relfn}:{lineno + 1}" + return f"{fn}:{lineno + 1}" + + +def num_mock_patch_args(function) -> int: + """Return number of arguments used up by mock arguments (if any).""" + patchings = getattr(function, "patchings", None) + if not patchings: + return 0 + + mock_sentinel = getattr(sys.modules.get("mock"), "DEFAULT", object()) + ut_mock_sentinel = getattr(sys.modules.get("unittest.mock"), "DEFAULT", object()) + + return len( + [ + p + for p in patchings + if not p.attribute_name + and (p.new is mock_sentinel or p.new is ut_mock_sentinel) + ] + ) + + +def getfuncargnames( + function: Callable[..., object], + *, + name: str = "", + cls: type | None = None, +) -> tuple[str, ...]: + """Return the names of a function's mandatory arguments. + + Should return the names of all function arguments that: + * Aren't bound to an instance or type as in instance or class methods. + * Don't have default values. + * Aren't bound with functools.partial. + * Aren't replaced with mocks. + + The cls arguments indicate that the function should be treated as a bound + method even though it's not unless the function is a static method. + + The name parameter should be the original name in which the function was collected. + """ + # TODO(RonnyPfannschmidt): This function should be refactored when we + # revisit fixtures. The fixture mechanism should ask the node for + # the fixture names, and not try to obtain directly from the + # function object well after collection has occurred. + + # The parameters attribute of a Signature object contains an + # ordered mapping of parameter names to Parameter instances. This + # creates a tuple of the names of the parameters that don't have + # defaults. + try: + parameters = signature(function).parameters.values() + except (ValueError, TypeError) as e: + from _pytest.outcomes import fail + + fail( + f"Could not determine arguments of {function!r}: {e}", + pytrace=False, + ) + + arg_names = tuple( + p.name + for p in parameters + if ( + p.kind is Parameter.POSITIONAL_OR_KEYWORD + or p.kind is Parameter.KEYWORD_ONLY + ) + and p.default is Parameter.empty + ) + if not name: + name = function.__name__ + + # If this function should be treated as a bound method even though + # it's passed as an unbound method or function, and its first parameter + # wasn't defined as positional only, remove the first parameter name. + if not any(p.kind is Parameter.POSITIONAL_ONLY for p in parameters) and ( + # Not using `getattr` because we don't want to resolve the staticmethod. + # Not using `cls.__dict__` because we want to check the entire MRO. + cls + and not isinstance( + inspect.getattr_static(cls, name, default=None), staticmethod + ) + ): + arg_names = arg_names[1:] + # Remove any names that will be replaced with mocks. + if hasattr(function, "__wrapped__"): + arg_names = arg_names[num_mock_patch_args(function) :] + return arg_names + + +def get_default_arg_names(function: Callable[..., Any]) -> tuple[str, ...]: + # Note: this code intentionally mirrors the code at the beginning of + # getfuncargnames, to get the arguments which were excluded from its result + # because they had default values. + return tuple( + p.name + for p in signature(function).parameters.values() + if p.kind in (Parameter.POSITIONAL_OR_KEYWORD, Parameter.KEYWORD_ONLY) + and p.default is not Parameter.empty + ) + + +_non_printable_ascii_translate_table = { + i: f"\\x{i:02x}" for i in range(128) if i not in range(32, 127) +} +_non_printable_ascii_translate_table.update( + {ord("\t"): "\\t", ord("\r"): "\\r", ord("\n"): "\\n"} +) + + +def ascii_escaped(val: bytes | str) -> str: + r"""If val is pure ASCII, return it as an str, otherwise, escape + bytes objects into a sequence of escaped bytes: + + b'\xc3\xb4\xc5\xd6' -> r'\xc3\xb4\xc5\xd6' + + and escapes strings into a sequence of escaped unicode ids, e.g.: + + r'4\nV\U00043efa\x0eMXWB\x1e\u3028\u15fd\xcd\U0007d944' + + Note: + The obvious "v.decode('unicode-escape')" will return + valid UTF-8 unicode if it finds them in bytes, but we + want to return escaped bytes for any byte, even if they match + a UTF-8 string. + """ + if isinstance(val, bytes): + ret = val.decode("ascii", "backslashreplace") + else: + ret = val.encode("unicode_escape").decode("ascii") + return ret.translate(_non_printable_ascii_translate_table) + + +def get_real_func(obj): + """Get the real function object of the (possibly) wrapped object by + :func:`functools.wraps`, or :func:`functools.partial`.""" + obj = inspect.unwrap(obj) + + if isinstance(obj, functools.partial): + obj = obj.func + return obj + + +def getimfunc(func): + try: + return func.__func__ + except AttributeError: + return func + + +def safe_getattr(object: Any, name: str, default: Any) -> Any: + """Like getattr but return default upon any Exception or any OutcomeException. + + Attribute access can potentially fail for 'evil' Python objects. + See issue #214. + It catches OutcomeException because of #2490 (issue #580), new outcomes + are derived from BaseException instead of Exception (for more details + check #2707). + """ + from _pytest.outcomes import TEST_OUTCOME + + try: + return getattr(object, name, default) + except TEST_OUTCOME: + return default + + +def safe_isclass(obj: object) -> bool: + """Ignore any exception via isinstance on Python 3.""" + try: + return inspect.isclass(obj) + except Exception: + return False + + +def get_user_id() -> int | None: + """Return the current process's real user id or None if it could not be + determined. + + :return: The user id or None if it could not be determined. + """ + # mypy follows the version and platform checking expectation of PEP 484: + # https://mypy.readthedocs.io/en/stable/common_issues.html?highlight=platform#python-version-and-system-platform-checks + # Containment checks are too complex for mypy v1.5.0 and cause failure. + if sys.platform == "win32" or sys.platform == "emscripten": + # win32 does not have a getuid() function. + # Emscripten has a return 0 stub. + return None + else: + # On other platforms, a return value of -1 is assumed to indicate that + # the current process's real user id could not be determined. + ERROR = -1 + uid = os.getuid() + return uid if uid != ERROR else None + + +if sys.version_info >= (3, 11): + from typing import assert_never +else: + + def assert_never(value: NoReturn) -> NoReturn: + assert False, f"Unhandled value: {value} ({type(value).__name__})" + + +class CallableBool: + """ + A bool-like object that can also be called, returning its true/false value. + + Used for backwards compatibility in cases where something was supposed to be a method + but was implemented as a simple attribute by mistake (see `TerminalReporter.isatty`). + + Do not use in new code. + """ + + def __init__(self, value: bool) -> None: + self._value = value + + def __bool__(self) -> bool: + return self._value + + def __call__(self) -> bool: + return self._value + + +def running_on_ci() -> bool: + """Check if we're currently running on a CI system.""" + # Only enable CI mode if one of these env variables is defined and non-empty. + # Note: review `regendoc` tox env in case this list is changed. + env_vars = ["CI", "BUILD_NUMBER"] + return any(os.environ.get(var) for var in env_vars) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/config/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/config/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..a027dbc02a4ff61efa535db1ca2688fd9ef37e4d --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/config/__init__.py @@ -0,0 +1,2203 @@ +# mypy: allow-untyped-defs +"""Command line options, config-file and conftest.py processing.""" + +from __future__ import annotations + +import argparse +import builtins +import collections.abc +from collections.abc import Callable +from collections.abc import Generator +from collections.abc import Iterable +from collections.abc import Iterator +from collections.abc import Mapping +from collections.abc import MutableMapping +from collections.abc import Sequence +import contextlib +import copy +import dataclasses +import enum +from functools import lru_cache +import glob +import importlib.metadata +import inspect +import os +import pathlib +import re +import shlex +import sys +from textwrap import dedent +import types +from types import FunctionType +from typing import Any +from typing import cast +from typing import Final +from typing import final +from typing import IO +from typing import TextIO +from typing import TYPE_CHECKING +import warnings + +import pluggy +from pluggy import HookimplMarker +from pluggy import HookimplOpts +from pluggy import HookspecMarker +from pluggy import HookspecOpts +from pluggy import PluginManager + +from .compat import PathAwareHookProxy +from .exceptions import PrintHelp as PrintHelp +from .exceptions import UsageError as UsageError +from .findpaths import ConfigValue +from .findpaths import determine_setup +from _pytest import __version__ +import _pytest._code +from _pytest._code import ExceptionInfo +from _pytest._code import filter_traceback +from _pytest._code.code import TracebackStyle +from _pytest._io import TerminalWriter +from _pytest.compat import assert_never +from _pytest.config.argparsing import Argument +from _pytest.config.argparsing import FILE_OR_DIR +from _pytest.config.argparsing import Parser +import _pytest.deprecated +import _pytest.hookspec +from _pytest.outcomes import fail +from _pytest.outcomes import Skipped +from _pytest.pathlib import absolutepath +from _pytest.pathlib import bestrelpath +from _pytest.pathlib import import_path +from _pytest.pathlib import ImportMode +from _pytest.pathlib import resolve_package_path +from _pytest.pathlib import safe_exists +from _pytest.stash import Stash +from _pytest.warning_types import PytestConfigWarning +from _pytest.warning_types import warn_explicit_for + + +if TYPE_CHECKING: + from _pytest.assertion.rewrite import AssertionRewritingHook + from _pytest.cacheprovider import Cache + from _pytest.terminal import TerminalReporter + +_PluggyPlugin = object +"""A type to represent plugin objects. + +Plugins can be any namespace, so we can't narrow it down much, but we use an +alias to make the intent clear. + +Ideally this type would be provided by pluggy itself. +""" + + +hookimpl = HookimplMarker("pytest") +hookspec = HookspecMarker("pytest") + + +@final +class ExitCode(enum.IntEnum): + """Encodes the valid exit codes by pytest. + + Currently users and plugins may supply other exit codes as well. + + .. versionadded:: 5.0 + """ + + #: Tests passed. + OK = 0 + #: Tests failed. + TESTS_FAILED = 1 + #: pytest was interrupted. + INTERRUPTED = 2 + #: An internal error got in the way. + INTERNAL_ERROR = 3 + #: pytest was misused. + USAGE_ERROR = 4 + #: pytest couldn't find tests. + NO_TESTS_COLLECTED = 5 + + __module__ = "pytest" + + +class ConftestImportFailure(Exception): + def __init__( + self, + path: pathlib.Path, + *, + cause: Exception, + ) -> None: + self.path = path + self.cause = cause + + def __str__(self) -> str: + return f"{type(self.cause).__name__}: {self.cause} (from {self.path})" + + +def filter_traceback_for_conftest_import_failure( + entry: _pytest._code.TracebackEntry, +) -> bool: + """Filter tracebacks entries which point to pytest internals or importlib. + + Make a special case for importlib because we use it to import test modules and conftest files + in _pytest.pathlib.import_path. + """ + return filter_traceback(entry) and "importlib" not in str(entry.path).split(os.sep) + + +def print_conftest_import_error(e: ConftestImportFailure, file: TextIO) -> None: + exc_info = ExceptionInfo.from_exception(e.cause) + tw = TerminalWriter(file) + tw.line(f"ImportError while loading conftest '{e.path}'.", red=True) + exc_info.traceback = exc_info.traceback.filter( + filter_traceback_for_conftest_import_failure + ) + exc_repr = ( + exc_info.getrepr(style="short", chain=False) + if exc_info.traceback + else exc_info.exconly() + ) + formatted_tb = str(exc_repr) + for line in formatted_tb.splitlines(): + tw.line(line.rstrip(), red=True) + + +def print_usage_error(e: UsageError, file: TextIO) -> None: + tw = TerminalWriter(file) + for msg in e.args: + tw.line(f"ERROR: {msg}\n", red=True) + + +def main( + args: list[str] | os.PathLike[str] | None = None, + plugins: Sequence[str | _PluggyPlugin] | None = None, +) -> int | ExitCode: + """Perform an in-process test run. + + :param args: + List of command line arguments. If `None` or not given, defaults to reading + arguments directly from the process command line (:data:`sys.argv`). + :param plugins: List of plugin objects to be auto-registered during initialization. + + :returns: An exit code. + """ + # Handle a single `--version` argument early to avoid starting up the entire pytest infrastructure. + new_args = sys.argv[1:] if args is None else args + if isinstance(new_args, Sequence) and new_args.count("--version") == 1: + sys.stdout.write(f"pytest {__version__}\n") + return ExitCode.OK + + old_pytest_version = os.environ.get("PYTEST_VERSION") + try: + os.environ["PYTEST_VERSION"] = __version__ + try: + config = _prepareconfig(new_args, plugins) + except ConftestImportFailure as e: + print_conftest_import_error(e, file=sys.stderr) + return ExitCode.USAGE_ERROR + + try: + ret: ExitCode | int = config.hook.pytest_cmdline_main(config=config) + try: + return ExitCode(ret) + except ValueError: + return ret + finally: + config._ensure_unconfigure() + except UsageError as e: + print_usage_error(e, file=sys.stderr) + return ExitCode.USAGE_ERROR + finally: + if old_pytest_version is None: + os.environ.pop("PYTEST_VERSION", None) + else: + os.environ["PYTEST_VERSION"] = old_pytest_version + + +def console_main() -> int: + """The CLI entry point of pytest. + + This function is not meant for programmable use; use `main()` instead. + """ + # https://docs.python.org/3/library/signal.html#note-on-sigpipe + try: + code = main() + sys.stdout.flush() + return code + except BrokenPipeError: + # Python flushes standard streams on exit; redirect remaining output + # to devnull to avoid another BrokenPipeError at shutdown + devnull = os.open(os.devnull, os.O_WRONLY) + os.dup2(devnull, sys.stdout.fileno()) + return 1 # Python exits with error code 1 on EPIPE + + +class cmdline: # compatibility namespace + main = staticmethod(main) + + +def filename_arg(path: str, optname: str) -> str: + """Argparse type validator for filename arguments. + + :path: Path of filename. + :optname: Name of the option. + """ + if os.path.isdir(path): + raise UsageError(f"{optname} must be a filename, given: {path}") + return path + + +def directory_arg(path: str, optname: str) -> str: + """Argparse type validator for directory arguments. + + :path: Path of directory. + :optname: Name of the option. + """ + if not os.path.isdir(path): + raise UsageError(f"{optname} must be a directory, given: {path}") + return path + + +# Plugins that cannot be disabled via "-p no:X" currently. +essential_plugins = ( + "mark", + "main", + "runner", + "fixtures", + "helpconfig", # Provides -p. +) + +default_plugins = ( + *essential_plugins, + "python", + "terminal", + "debugging", + "unittest", + "capture", + "skipping", + "legacypath", + "tmpdir", + "monkeypatch", + "recwarn", + "pastebin", + "assertion", + "junitxml", + "doctest", + "cacheprovider", + "setuponly", + "setupplan", + "stepwise", + "unraisableexception", + "threadexception", + "warnings", + "logging", + "reports", + "faulthandler", + "subtests", +) + +builtin_plugins = { + *default_plugins, + "pytester", + "pytester_assertions", + "terminalprogress", +} + + +def get_config( + args: Iterable[str] | None = None, + plugins: Sequence[str | _PluggyPlugin] | None = None, +) -> Config: + # Subsequent calls to main will create a fresh instance. + pluginmanager = PytestPluginManager() + invocation_params = Config.InvocationParams( + args=args or (), + plugins=plugins, + dir=pathlib.Path.cwd(), + ) + config = Config(pluginmanager, invocation_params=invocation_params) + + if invocation_params.args: + # Handle any "-p no:plugin" args. + pluginmanager.consider_preparse(invocation_params.args, exclude_only=True) + + for spec in default_plugins: + pluginmanager.import_plugin(spec) + + return config + + +def get_plugin_manager() -> PytestPluginManager: + """Obtain a new instance of the + :py:class:`pytest.PytestPluginManager`, with default plugins + already loaded. + + This function can be used by integration with other tools, like hooking + into pytest to run tests into an IDE. + """ + return get_config().pluginmanager + + +def _prepareconfig( + args: list[str] | os.PathLike[str], + plugins: Sequence[str | _PluggyPlugin] | None = None, +) -> Config: + if isinstance(args, os.PathLike): + args = [os.fspath(args)] + elif not isinstance(args, list): + msg = ( # type:ignore[unreachable] + "`args` parameter expected to be a list of strings, got: {!r} (type: {})" + ) + raise TypeError(msg.format(args, type(args))) + + initial_config = get_config(args, plugins) + pluginmanager = initial_config.pluginmanager + try: + if plugins: + for plugin in plugins: + if isinstance(plugin, str): + pluginmanager.consider_pluginarg(plugin) + else: + pluginmanager.register(plugin) + config: Config = pluginmanager.hook.pytest_cmdline_parse( + pluginmanager=pluginmanager, args=args + ) + return config + except BaseException: + initial_config._ensure_unconfigure() + raise + + +def _get_directory(path: pathlib.Path) -> pathlib.Path: + """Get the directory of a path - itself if already a directory.""" + if path.is_file(): + return path.parent + else: + return path + + +def _get_legacy_hook_marks( + method: Any, + hook_type: str, + opt_names: tuple[str, ...], +) -> dict[str, bool]: + if TYPE_CHECKING: + # abuse typeguard from importlib to avoid massive method type union that's lacking an alias + assert inspect.isroutine(method) + known_marks: set[str] = {m.name for m in getattr(method, "pytestmark", [])} + must_warn: list[str] = [] + opts: dict[str, bool] = {} + for opt_name in opt_names: + opt_attr = getattr(method, opt_name, AttributeError) + if opt_attr is not AttributeError: + must_warn.append(f"{opt_name}={opt_attr}") + opts[opt_name] = True + elif opt_name in known_marks: + must_warn.append(f"{opt_name}=True") + opts[opt_name] = True + else: + opts[opt_name] = False + if must_warn: + hook_opts = ", ".join(must_warn) + message = _pytest.deprecated.HOOK_LEGACY_MARKING.format( + type=hook_type, + fullname=method.__qualname__, + hook_opts=hook_opts, + ) + warn_explicit_for(cast(FunctionType, method), message) + return opts + + +@final +class PytestPluginManager(PluginManager): + """A :py:class:`pluggy.PluginManager <pluggy.PluginManager>` with + additional pytest-specific functionality: + + * Loading plugins from the command line, ``PYTEST_PLUGINS`` env variable and + ``pytest_plugins`` global variables found in plugins being loaded. + * ``conftest.py`` loading during start-up. + """ + + def __init__(self) -> None: + from _pytest.assertion import DummyRewriteHook + from _pytest.assertion import RewriteHook + + super().__init__("pytest") + + # -- State related to local conftest plugins. + # All loaded conftest modules. + self._conftest_plugins: set[types.ModuleType] = set() + # All conftest modules applicable for a directory. + # This includes the directory's own conftest modules as well + # as those of its parent directories. + self._dirpath2confmods: dict[pathlib.Path, list[types.ModuleType]] = {} + # Cutoff directory above which conftests are no longer discovered. + self._confcutdir: pathlib.Path | None = None + # If set, conftest loading is skipped. + self._noconftest = False + + # _getconftestmodules()'s call to _get_directory() causes a stat + # storm when it's called potentially thousands of times in a test + # session (#9478), often with the same path, so cache it. + self._get_directory = lru_cache(256)(_get_directory) + + # plugins that were explicitly skipped with pytest.skip + # list of (module name, skip reason) + # previously we would issue a warning when a plugin was skipped, but + # since we refactored warnings as first citizens of Config, they are + # just stored here to be used later. + self.skipped_plugins: list[tuple[str, str]] = [] + + self.add_hookspecs(_pytest.hookspec) + self.register(self) + if os.environ.get("PYTEST_DEBUG"): + err: IO[str] = sys.stderr + encoding: str = getattr(err, "encoding", "utf8") + try: + err = open( + os.dup(err.fileno()), + mode=err.mode, + buffering=1, + encoding=encoding, + ) + except Exception: + pass + self.trace.root.setwriter(err.write) + self.enable_tracing() + + # Config._consider_importhook will set a real object if required. + self.rewrite_hook: RewriteHook = DummyRewriteHook() + # Used to know when we are importing conftests after the pytest_configure stage. + self._configured = False + + def parse_hookimpl_opts( + self, plugin: _PluggyPlugin, name: str + ) -> HookimplOpts | None: + """:meta private:""" + # pytest hooks are always prefixed with "pytest_", + # so we avoid accessing possibly non-readable attributes + # (see issue #1073). + if not name.startswith("pytest_"): + return None + # Ignore names which cannot be hooks. + if name == "pytest_plugins": + return None + + opts = super().parse_hookimpl_opts(plugin, name) + if opts is not None: + return opts + + method = getattr(plugin, name) + # Consider only actual functions for hooks (#3775). + if not inspect.isroutine(method): + return None + # Collect unmarked hooks as long as they have the `pytest_' prefix. + legacy = _get_legacy_hook_marks( + method, "impl", ("tryfirst", "trylast", "optionalhook", "hookwrapper") + ) + return cast(HookimplOpts, legacy) + + def parse_hookspec_opts(self, module_or_class, name: str) -> HookspecOpts | None: + """:meta private:""" + opts = super().parse_hookspec_opts(module_or_class, name) + if opts is None: + method = getattr(module_or_class, name) + if name.startswith("pytest_"): + legacy = _get_legacy_hook_marks( + method, "spec", ("firstresult", "historic") + ) + opts = cast(HookspecOpts, legacy) + return opts + + def register(self, plugin: _PluggyPlugin, name: str | None = None) -> str | None: + if name in _pytest.deprecated.DEPRECATED_EXTERNAL_PLUGINS: + warnings.warn( + PytestConfigWarning( + "{} plugin has been merged into the core, " + "please remove it from your requirements.".format( + name.replace("_", "-") + ) + ) + ) + return None + plugin_name = super().register(plugin, name) + if plugin_name is not None: + self.hook.pytest_plugin_registered.call_historic( + kwargs=dict( + plugin=plugin, + plugin_name=plugin_name, + manager=self, + ) + ) + + if isinstance(plugin, types.ModuleType): + self.consider_module(plugin) + return plugin_name + + def getplugin(self, name: str): + # Support deprecated naming because plugins (xdist e.g.) use it. + plugin: _PluggyPlugin | None = self.get_plugin(name) + return plugin + + def hasplugin(self, name: str) -> bool: + """Return whether a plugin with the given name is registered.""" + return bool(self.get_plugin(name)) + + def pytest_configure(self, config: Config) -> None: + """:meta private:""" + # XXX now that the pluginmanager exposes hookimpl(tryfirst...) + # we should remove tryfirst/trylast as markers. + config.addinivalue_line( + "markers", + "tryfirst: mark a hook implementation function such that the " + "plugin machinery will try to call it first/as early as possible. " + "DEPRECATED, use @pytest.hookimpl(tryfirst=True) instead.", + ) + config.addinivalue_line( + "markers", + "trylast: mark a hook implementation function such that the " + "plugin machinery will try to call it last/as late as possible. " + "DEPRECATED, use @pytest.hookimpl(trylast=True) instead.", + ) + self._configured = True + + # + # Internal API for local conftest plugin handling. + # + def _set_initial_conftests( + self, + args: Sequence[str | pathlib.Path], + pyargs: bool, + noconftest: bool, + rootpath: pathlib.Path, + confcutdir: pathlib.Path | None, + invocation_dir: pathlib.Path, + importmode: ImportMode | str, + *, + consider_namespace_packages: bool, + ) -> None: + """Load initial conftest files given a preparsed "namespace". + + As conftest files may add their own command line options which have + arguments ('--my-opt somepath') we might get some false positives. + All builtin and 3rd party plugins will have been loaded, however, so + common options will not confuse our logic here. + """ + self._confcutdir = ( + absolutepath(invocation_dir / confcutdir) if confcutdir else None + ) + self._noconftest = noconftest + self._using_pyargs = pyargs + foundanchor = False + for initial_path in args: + path = str(initial_path) + # remove node-id syntax + i = path.find("::") + if i != -1: + path = path[:i] + anchor = absolutepath(invocation_dir / path) + + # Ensure we do not break if what appears to be an anchor + # is in fact a very long option (#10169, #11394). + if safe_exists(anchor): + self._try_load_conftest( + anchor, + importmode, + rootpath, + consider_namespace_packages=consider_namespace_packages, + ) + foundanchor = True + if not foundanchor: + self._try_load_conftest( + invocation_dir, + importmode, + rootpath, + consider_namespace_packages=consider_namespace_packages, + ) + + def _is_in_confcutdir(self, path: pathlib.Path) -> bool: + """Whether to consider the given path to load conftests from.""" + if self._confcutdir is None: + return True + # The semantics here are literally: + # Do not load a conftest if it is found upwards from confcut dir. + # But this is *not* the same as: + # Load only conftests from confcutdir or below. + # At first glance they might seem the same thing, however we do support use cases where + # we want to load conftests that are not found in confcutdir or below, but are found + # in completely different directory hierarchies like packages installed + # in out-of-source trees. + # (see #9767 for a regression where the logic was inverted). + return path not in self._confcutdir.parents + + def _try_load_conftest( + self, + anchor: pathlib.Path, + importmode: str | ImportMode, + rootpath: pathlib.Path, + *, + consider_namespace_packages: bool, + ) -> None: + self._loadconftestmodules( + anchor, + importmode, + rootpath, + consider_namespace_packages=consider_namespace_packages, + ) + # let's also consider test* subdirs + if anchor.is_dir(): + for x in anchor.glob("test*"): + if x.is_dir(): + self._loadconftestmodules( + x, + importmode, + rootpath, + consider_namespace_packages=consider_namespace_packages, + ) + + def _loadconftestmodules( + self, + path: pathlib.Path, + importmode: str | ImportMode, + rootpath: pathlib.Path, + *, + consider_namespace_packages: bool, + ) -> None: + if self._noconftest: + return + + directory = self._get_directory(path) + + # Optimization: avoid repeated searches in the same directory. + # Assumes always called with same importmode and rootpath. + if directory in self._dirpath2confmods: + return + + clist = [] + for parent in reversed((directory, *directory.parents)): + if self._is_in_confcutdir(parent): + conftestpath = parent / "conftest.py" + if conftestpath.is_file(): + mod = self._importconftest( + conftestpath, + importmode, + rootpath, + consider_namespace_packages=consider_namespace_packages, + ) + clist.append(mod) + self._dirpath2confmods[directory] = clist + + def _getconftestmodules(self, path: pathlib.Path) -> Sequence[types.ModuleType]: + directory = self._get_directory(path) + return self._dirpath2confmods.get(directory, ()) + + def _rget_with_confmod( + self, + name: str, + path: pathlib.Path, + ) -> tuple[types.ModuleType, Any]: + modules = self._getconftestmodules(path) + for mod in reversed(modules): + try: + return mod, getattr(mod, name) + except AttributeError: + continue + raise KeyError(name) + + def _importconftest( + self, + conftestpath: pathlib.Path, + importmode: str | ImportMode, + rootpath: pathlib.Path, + *, + consider_namespace_packages: bool, + ) -> types.ModuleType: + conftestpath_plugin_name = str(conftestpath) + existing = self.get_plugin(conftestpath_plugin_name) + if existing is not None: + return cast(types.ModuleType, existing) + + # conftest.py files there are not in a Python package all have module + # name "conftest", and thus conflict with each other. Clear the existing + # before loading the new one, otherwise the existing one will be + # returned from the module cache. + pkgpath = resolve_package_path(conftestpath) + if pkgpath is None: + try: + del sys.modules[conftestpath.stem] + except KeyError: + pass + + try: + mod = import_path( + conftestpath, + mode=importmode, + root=rootpath, + consider_namespace_packages=consider_namespace_packages, + ) + except Exception as e: + assert e.__traceback__ is not None + raise ConftestImportFailure(conftestpath, cause=e) from e + + self._check_non_top_pytest_plugins(mod, conftestpath) + + self._conftest_plugins.add(mod) + dirpath = conftestpath.parent + if dirpath in self._dirpath2confmods: + for path, mods in self._dirpath2confmods.items(): + if dirpath in path.parents or path == dirpath: + if mod in mods: + raise AssertionError( + f"While trying to load conftest path {conftestpath!s}, " + f"found that the module {mod} is already loaded with path {mod.__file__}. " + "This is not supposed to happen. Please report this issue to pytest." + ) + mods.append(mod) + self.trace(f"loading conftestmodule {mod!r}") + self.consider_conftest(mod, registration_name=conftestpath_plugin_name) + return mod + + def _check_non_top_pytest_plugins( + self, + mod: types.ModuleType, + conftestpath: pathlib.Path, + ) -> None: + if ( + hasattr(mod, "pytest_plugins") + and self._configured + and not self._using_pyargs + ): + msg = ( + "Defining 'pytest_plugins' in a non-top-level conftest is no longer supported:\n" + "It affects the entire test suite instead of just below the conftest as expected.\n" + " {}\n" + "Please move it to a top level conftest file at the rootdir:\n" + " {}\n" + "For more information, visit:\n" + " https://docs.pytest.org/en/stable/deprecations.html#pytest-plugins-in-non-top-level-conftest-files" + ) + fail(msg.format(conftestpath, self._confcutdir), pytrace=False) + + # + # API for bootstrapping plugin loading + # + # + + def consider_preparse( + self, args: Sequence[str], *, exclude_only: bool = False + ) -> None: + """:meta private:""" + i = 0 + n = len(args) + while i < n: + opt = args[i] + i += 1 + if isinstance(opt, str): + if opt == "-p": + try: + parg = args[i] + except IndexError: + return + i += 1 + elif opt.startswith("-p"): + parg = opt[2:] + else: + continue + parg = parg.strip() + if exclude_only and not parg.startswith("no:"): + continue + self.consider_pluginarg(parg) + + def consider_pluginarg(self, arg: str) -> None: + """:meta private:""" + if arg.startswith("no:"): + name = arg[3:] + if name in essential_plugins: + raise UsageError(f"plugin {name} cannot be disabled") + + if name.endswith("conftest.py"): + raise UsageError( + f"Blocking conftest files using -p is not supported: -p no:{name}\n" + "conftest.py files are not plugins and cannot be disabled via -p.\n" + ) + + # PR #4304: remove stepwise if cacheprovider is blocked. + if name == "cacheprovider": + self.set_blocked("stepwise") + self.set_blocked("pytest_stepwise") + + self.set_blocked(name) + if not name.startswith("pytest_"): + self.set_blocked("pytest_" + name) + else: + name = arg + # Unblock the plugin. + self.unblock(name) + if not name.startswith("pytest_"): + self.unblock("pytest_" + name) + self.import_plugin(arg, consider_entry_points=True) + + def consider_conftest( + self, conftestmodule: types.ModuleType, registration_name: str + ) -> None: + """:meta private:""" + self.register(conftestmodule, name=registration_name) + + def consider_env(self) -> None: + """:meta private:""" + self._import_plugin_specs(os.environ.get("PYTEST_PLUGINS")) + + def consider_module(self, mod: types.ModuleType) -> None: + """:meta private:""" + self._import_plugin_specs(getattr(mod, "pytest_plugins", [])) + + def _import_plugin_specs( + self, spec: None | types.ModuleType | str | Sequence[str] + ) -> None: + plugins = _get_plugin_specs_as_list(spec) + for import_spec in plugins: + self.import_plugin(import_spec) + + def import_plugin(self, modname: str, consider_entry_points: bool = False) -> None: + """Import a plugin with ``modname``. + + If ``consider_entry_points`` is True, entry point names are also + considered to find a plugin. + """ + # Most often modname refers to builtin modules, e.g. "pytester", + # "terminal" or "capture". Those plugins are registered under their + # basename for historic purposes but must be imported with the + # _pytest prefix. + assert isinstance(modname, str), ( + f"module name as text required, got {modname!r}" + ) + if self.is_blocked(modname) or self.get_plugin(modname) is not None: + return + + importspec = "_pytest." + modname if modname in builtin_plugins else modname + self.rewrite_hook.mark_rewrite(importspec) + + if consider_entry_points: + loaded = self.load_setuptools_entrypoints("pytest11", name=modname) + if loaded: + return + + try: + __import__(importspec) + except ImportError as e: + raise ImportError( + f'Error importing plugin "{modname}": {e.args[0]}' + ).with_traceback(e.__traceback__) from e + + except Skipped as e: + self.skipped_plugins.append((modname, e.msg or "")) + else: + mod = sys.modules[importspec] + self.register(mod, modname) + + +def _get_plugin_specs_as_list( + specs: None | types.ModuleType | str | Sequence[str], +) -> list[str]: + """Parse a plugins specification into a list of plugin names.""" + # None means empty. + if specs is None: + return [] + # Workaround for #3899 - a submodule which happens to be called "pytest_plugins". + if isinstance(specs, types.ModuleType): + return [] + # Comma-separated list. + if isinstance(specs, str): + return specs.split(",") if specs else [] + # Direct specification. + if isinstance(specs, collections.abc.Sequence): + return list(specs) + raise UsageError( + f"Plugins may be specified as a sequence or a ','-separated string of plugin names. Got: {specs!r}" + ) + + +class Notset: + def __repr__(self): + return "<NOTSET>" + + +notset = Notset() + + +def _iter_rewritable_modules(package_files: Iterable[str]) -> Iterator[str]: + """Given an iterable of file names in a source distribution, return the "names" that should + be marked for assertion rewrite. + + For example the package "pytest_mock/__init__.py" should be added as "pytest_mock" in + the assertion rewrite mechanism. + + This function has to deal with dist-info based distributions and egg based distributions + (which are still very much in use for "editable" installs). + + Here are the file names as seen in a dist-info based distribution: + + pytest_mock/__init__.py + pytest_mock/_version.py + pytest_mock/plugin.py + pytest_mock.egg-info/PKG-INFO + + Here are the file names as seen in an egg based distribution: + + src/pytest_mock/__init__.py + src/pytest_mock/_version.py + src/pytest_mock/plugin.py + src/pytest_mock.egg-info/PKG-INFO + LICENSE + setup.py + + We have to take in account those two distribution flavors in order to determine which + names should be considered for assertion rewriting. + + More information: + https://github.com/pytest-dev/pytest-mock/issues/167 + """ + package_files = list(package_files) + seen_some = False + for fn in package_files: + is_simple_module = "/" not in fn and fn.endswith(".py") + is_package = fn.count("/") == 1 and fn.endswith("__init__.py") + if is_simple_module: + module_name, _ = os.path.splitext(fn) + # we ignore "setup.py" at the root of the distribution + # as well as editable installation finder modules made by setuptools + if module_name != "setup" and not module_name.startswith("__editable__"): + seen_some = True + yield module_name + elif is_package: + package_name = os.path.dirname(fn) + seen_some = True + yield package_name + + if not seen_some: + # At this point we did not find any packages or modules suitable for assertion + # rewriting, so we try again by stripping the first path component (to account for + # "src" based source trees for example). + # This approach lets us have the common case continue to be fast, as egg-distributions + # are rarer. + new_package_files = [] + for fn in package_files: + parts = fn.split("/") + new_fn = "/".join(parts[1:]) + if new_fn: + new_package_files.append(new_fn) + if new_package_files: + yield from _iter_rewritable_modules(new_package_files) + + +class _DeprecatedInicfgProxy(MutableMapping[str, Any]): + """Compatibility proxy for the deprecated Config.inicfg.""" + + __slots__ = ("_config",) + + def __init__(self, config: Config) -> None: + self._config = config + + def __getitem__(self, key: str) -> Any: + return self._config._inicfg[key].value + + def __setitem__(self, key: str, value: Any) -> None: + self._config._inicfg[key] = ConfigValue(value, origin="override", mode="toml") + + def __delitem__(self, key: str) -> None: + del self._config._inicfg[key] + + def __iter__(self) -> Iterator[str]: + return iter(self._config._inicfg) + + def __len__(self) -> int: + return len(self._config._inicfg) + + +@final +class Config: + """Access to configuration values, pluginmanager and plugin hooks. + + :param PytestPluginManager pluginmanager: + A pytest PluginManager. + + :param InvocationParams invocation_params: + Object containing parameters regarding the :func:`pytest.main` + invocation. + """ + + @final + @dataclasses.dataclass(frozen=True) + class InvocationParams: + """Holds parameters passed during :func:`pytest.main`. + + The object attributes are read-only. + + .. versionadded:: 5.1 + + .. note:: + + Note that the environment variable ``PYTEST_ADDOPTS`` and the ``addopts`` + configuration option are handled by pytest, not being included in the ``args`` attribute. + + Plugins accessing ``InvocationParams`` must be aware of that. + """ + + args: tuple[str, ...] + """The command-line arguments as passed to :func:`pytest.main`.""" + plugins: Sequence[str | _PluggyPlugin] | None + """Extra plugins, might be `None`.""" + dir: pathlib.Path + """The directory from which :func:`pytest.main` was invoked.""" + + def __init__( + self, + *, + args: Iterable[str], + plugins: Sequence[str | _PluggyPlugin] | None, + dir: pathlib.Path, + ) -> None: + object.__setattr__(self, "args", tuple(args)) + object.__setattr__(self, "plugins", plugins) + object.__setattr__(self, "dir", dir) + + class ArgsSource(enum.Enum): + """Indicates the source of the test arguments. + + .. versionadded:: 7.2 + """ + + #: Command line arguments. + ARGS = enum.auto() + #: Invocation directory. + INVOCATION_DIR = enum.auto() + INCOVATION_DIR = INVOCATION_DIR # backwards compatibility alias + #: 'testpaths' configuration value. + TESTPATHS = enum.auto() + + # Set by cacheprovider plugin. + cache: Cache + + def __init__( + self, + pluginmanager: PytestPluginManager, + *, + invocation_params: InvocationParams | None = None, + ) -> None: + if invocation_params is None: + invocation_params = self.InvocationParams( + args=(), plugins=None, dir=pathlib.Path.cwd() + ) + + self.option = argparse.Namespace() + """Access to command line option as attributes. + + :type: argparse.Namespace + """ + + self.invocation_params = invocation_params + """The parameters with which pytest was invoked. + + :type: InvocationParams + """ + + self._parser = Parser( + usage=f"%(prog)s [options] [{FILE_OR_DIR}] [{FILE_OR_DIR}] [...]", + processopt=self._processopt, + _ispytest=True, + ) + self.pluginmanager = pluginmanager + """The plugin manager handles plugin registration and hook invocation. + + :type: PytestPluginManager + """ + + self.stash = Stash() + """A place where plugins can store information on the config for their + own use. + + :type: Stash + """ + # Deprecated alias. Was never public. Can be removed in a few releases. + self._store = self.stash + + self.trace = self.pluginmanager.trace.root.get("config") + self.hook: pluggy.HookRelay = PathAwareHookProxy(self.pluginmanager.hook) # type: ignore[assignment] + self._inicache: dict[str, Any] = {} + self._opt2dest: dict[str, str] = {} + self._cleanup_stack = contextlib.ExitStack() + self.pluginmanager.register(self, "pytestconfig") + self._configured = False + self.hook.pytest_addoption.call_historic( + kwargs=dict(parser=self._parser, pluginmanager=self.pluginmanager) + ) + self.args_source = Config.ArgsSource.ARGS + self.args: list[str] = [] + + @property + def inicfg(self) -> _DeprecatedInicfgProxy: + return _DeprecatedInicfgProxy(self) + + @property + def rootpath(self) -> pathlib.Path: + """The path to the :ref:`rootdir <rootdir>`. + + .. versionadded:: 6.1 + """ + return self._rootpath + + @property + def inipath(self) -> pathlib.Path | None: + """The path to the :ref:`configfile <configfiles>`. + + .. versionadded:: 6.1 + """ + return self._inipath + + def add_cleanup(self, func: Callable[[], None]) -> None: + """Add a function to be called when the config object gets out of + use (usually coinciding with pytest_unconfigure). + """ + self._cleanup_stack.callback(func) + + def _do_configure(self) -> None: + assert not self._configured + self._configured = True + self.hook.pytest_configure.call_historic(kwargs=dict(config=self)) + + def _ensure_unconfigure(self) -> None: + try: + if self._configured: + self._configured = False + try: + self.hook.pytest_unconfigure(config=self) + finally: + self.hook.pytest_configure._call_history = [] + finally: + try: + self._cleanup_stack.close() + finally: + self._cleanup_stack = contextlib.ExitStack() + + def get_terminal_writer(self) -> TerminalWriter: + terminalreporter: TerminalReporter | None = self.pluginmanager.get_plugin( + "terminalreporter" + ) + assert terminalreporter is not None + return terminalreporter._tw + + def pytest_cmdline_parse( + self, pluginmanager: PytestPluginManager, args: list[str] + ) -> Config: + try: + self.parse(args) + except UsageError: + # Handle `--version --version` and `--help` here in a minimal fashion. + # This gets done via helpconfig normally, but its + # pytest_cmdline_main is not called in case of errors. + if getattr(self.option, "version", False) or "--version" in args: + from _pytest.helpconfig import show_version_verbose + + # Note that `--version` (single argument) is handled early by `Config.main()`, so the only + # way we are reaching this point is via `--version --version`. + show_version_verbose(self) + elif ( + getattr(self.option, "help", False) or "--help" in args or "-h" in args + ): + self._parser.optparser.print_help() + sys.stdout.write( + "\nNOTE: displaying only minimal help due to UsageError.\n\n" + ) + + raise + + return self + + def notify_exception( + self, + excinfo: ExceptionInfo[BaseException], + option: argparse.Namespace | None = None, + ) -> None: + if option and getattr(option, "fulltrace", False): + style: TracebackStyle = "long" + else: + style = "native" + excrepr = excinfo.getrepr( + funcargs=True, showlocals=getattr(option, "showlocals", False), style=style + ) + res = self.hook.pytest_internalerror(excrepr=excrepr, excinfo=excinfo) + if not any(res): + for line in str(excrepr).split("\n"): + sys.stderr.write(f"INTERNALERROR> {line}\n") + sys.stderr.flush() + + def cwd_relative_nodeid(self, nodeid: str) -> str: + # nodeid's are relative to the rootpath, compute relative to cwd. + if self.invocation_params.dir != self.rootpath: + base_path_part, *nodeid_part = nodeid.split("::") + # Only process path part + fullpath = self.rootpath / base_path_part + relative_path = bestrelpath(self.invocation_params.dir, fullpath) + + nodeid = "::".join([relative_path, *nodeid_part]) + return nodeid + + @classmethod + def fromdictargs(cls, option_dict: Mapping[str, Any], args: list[str]) -> Config: + """Constructor usable for subprocesses.""" + config = get_config(args) + config.option.__dict__.update(option_dict) + config.parse(args, addopts=False) + for x in config.option.plugins: + config.pluginmanager.consider_pluginarg(x) + return config + + def _processopt(self, opt: Argument) -> None: + for name in opt._short_opts + opt._long_opts: + self._opt2dest[name] = opt.dest + + if hasattr(opt, "default"): + if not hasattr(self.option, opt.dest): + setattr(self.option, opt.dest, opt.default) + + @hookimpl(trylast=True) + def pytest_load_initial_conftests(self, early_config: Config) -> None: + # We haven't fully parsed the command line arguments yet, so + # early_config.args it not set yet. But we need it for + # discovering the initial conftests. So "pre-run" the logic here. + # It will be done for real in `parse()`. + args, _args_source = early_config._decide_args( + args=early_config.known_args_namespace.file_or_dir, + pyargs=early_config.known_args_namespace.pyargs, + testpaths=early_config.getini("testpaths"), + invocation_dir=early_config.invocation_params.dir, + rootpath=early_config.rootpath, + warn=False, + ) + self.pluginmanager._set_initial_conftests( + args=args, + pyargs=early_config.known_args_namespace.pyargs, + noconftest=early_config.known_args_namespace.noconftest, + rootpath=early_config.rootpath, + confcutdir=early_config.known_args_namespace.confcutdir, + invocation_dir=early_config.invocation_params.dir, + importmode=early_config.known_args_namespace.importmode, + consider_namespace_packages=early_config.getini( + "consider_namespace_packages" + ), + ) + + def _consider_importhook(self) -> None: + """Install the PEP 302 import hook if using assertion rewriting. + + Needs to parse the --assert=<mode> option from the commandline + and find all the installed plugins to mark them for rewriting + by the importhook. + """ + mode = getattr(self.known_args_namespace, "assertmode", "plain") + + disable_autoload = getattr( + self.known_args_namespace, "disable_plugin_autoload", False + ) or bool(os.environ.get("PYTEST_DISABLE_PLUGIN_AUTOLOAD")) + if mode == "rewrite": + import _pytest.assertion + + try: + hook = _pytest.assertion.install_importhook(self) + except SystemError: + mode = "plain" + else: + self._mark_plugins_for_rewrite(hook, disable_autoload) + self._warn_about_missing_assertion(mode) + + def _mark_plugins_for_rewrite( + self, hook: AssertionRewritingHook, disable_autoload: bool + ) -> None: + """Given an importhook, mark for rewrite any top-level + modules or packages in the distribution package for + all pytest plugins.""" + self.pluginmanager.rewrite_hook = hook + + if disable_autoload: + # We don't autoload from distribution package entry points, + # no need to continue. + return + + package_files = ( + str(file) + for dist in importlib.metadata.distributions() + if any(ep.group == "pytest11" for ep in dist.entry_points) + for file in dist.files or [] + ) + + for name in _iter_rewritable_modules(package_files): + hook.mark_rewrite(name) + + def _configure_python_path(self) -> None: + # `pythonpath = a b` will set `sys.path` to `[a, b, x, y, z, ...]` + for path in reversed(self.getini("pythonpath")): + sys.path.insert(0, str(path)) + self.add_cleanup(self._unconfigure_python_path) + + def _unconfigure_python_path(self) -> None: + for path in self.getini("pythonpath"): + path_str = str(path) + if path_str in sys.path: + sys.path.remove(path_str) + + def _validate_args(self, args: list[str], via: str) -> list[str]: + """Validate known args.""" + self._parser.extra_info["config source"] = via + try: + self._parser.parse_known_and_unknown_args( + args, namespace=copy.copy(self.option) + ) + finally: + self._parser.extra_info.pop("config source", None) + + return args + + def _decide_args( + self, + *, + args: list[str], + pyargs: bool, + testpaths: list[str], + invocation_dir: pathlib.Path, + rootpath: pathlib.Path, + warn: bool, + ) -> tuple[list[str], ArgsSource]: + """Decide the args (initial paths/nodeids) to use given the relevant inputs. + + :param warn: Whether can issue warnings. + + :returns: The args and the args source. Guaranteed to be non-empty. + """ + if args: + source = Config.ArgsSource.ARGS + result = args + else: + if invocation_dir == rootpath: + source = Config.ArgsSource.TESTPATHS + if pyargs: + result = testpaths + else: + result = [] + for path in testpaths: + result.extend(sorted(glob.iglob(path, recursive=True))) + if testpaths and not result: + if warn: + warning_text = ( + "No files were found in testpaths; " + "consider removing or adjusting your testpaths configuration. " + "Searching recursively from the current directory instead." + ) + self.issue_config_time_warning( + PytestConfigWarning(warning_text), stacklevel=3 + ) + else: + result = [] + if not result: + source = Config.ArgsSource.INVOCATION_DIR + result = [str(invocation_dir)] + return result, source + + @hookimpl(wrapper=True) + def pytest_collection(self) -> Generator[None, object, object]: + # Validate invalid configuration keys after collection is done so we + # take in account options added by late-loading conftest files. + try: + return (yield) + finally: + self._validate_config_options() + + def _checkversion(self) -> None: + import pytest + + minver_ini_value = self._inicfg.get("minversion", None) + minver = minver_ini_value.value if minver_ini_value is not None else None + if minver: + # Imported lazily to improve start-up time. + from packaging.version import Version + + if not isinstance(minver, str): + raise pytest.UsageError( + f"{self.inipath}: 'minversion' must be a single value" + ) + + if Version(minver) > Version(pytest.__version__): + raise pytest.UsageError( + f"{self.inipath}: 'minversion' requires pytest-{minver}, actual pytest-{pytest.__version__}'" + ) + + def _validate_config_options(self) -> None: + for key in sorted(self._get_unknown_ini_keys()): + self._warn_or_fail_if_strict(f"Unknown config option: {key}\n") + + def _validate_plugins(self) -> None: + required_plugins = sorted(self.getini("required_plugins")) + if not required_plugins: + return + + # Imported lazily to improve start-up time. + from packaging.requirements import InvalidRequirement + from packaging.requirements import Requirement + from packaging.version import Version + + plugin_info = self.pluginmanager.list_plugin_distinfo() + plugin_dist_info = {dist.project_name: dist.version for _, dist in plugin_info} + + missing_plugins = [] + for required_plugin in required_plugins: + try: + req = Requirement(required_plugin) + except InvalidRequirement: + missing_plugins.append(required_plugin) + continue + + if req.name not in plugin_dist_info: + missing_plugins.append(required_plugin) + elif not req.specifier.contains( + Version(plugin_dist_info[req.name]), prereleases=True + ): + missing_plugins.append(required_plugin) + + if missing_plugins: + raise UsageError( + "Missing required plugins: {}".format(", ".join(missing_plugins)), + ) + + def _warn_or_fail_if_strict(self, message: str) -> None: + strict_config = self.getini("strict_config") + if strict_config is None: + strict_config = self.getini("strict") + if strict_config: + raise UsageError(message) + + self.issue_config_time_warning(PytestConfigWarning(message), stacklevel=3) + + def _get_unknown_ini_keys(self) -> set[str]: + known_keys = self._parser._inidict.keys() | self._parser._ini_aliases.keys() + return self._inicfg.keys() - known_keys + + def parse(self, args: list[str], addopts: bool = True) -> None: + # Parse given cmdline arguments into this config object. + assert self.args == [], ( + "can only parse cmdline args at most once per Config object" + ) + + self.hook.pytest_addhooks.call_historic( + kwargs=dict(pluginmanager=self.pluginmanager) + ) + + if addopts: + env_addopts = os.environ.get("PYTEST_ADDOPTS", "") + if len(env_addopts): + args[:] = ( + self._validate_args(shlex.split(env_addopts), "via PYTEST_ADDOPTS") + + args + ) + + ns = self._parser.parse_known_args(args, namespace=copy.copy(self.option)) + rootpath, inipath, inicfg, ignored_config_files = determine_setup( + inifile=ns.inifilename, + override_ini=ns.override_ini, + args=ns.file_or_dir, + rootdir_cmd_arg=ns.rootdir or None, + invocation_dir=self.invocation_params.dir, + ) + self._rootpath = rootpath + self._inipath = inipath + self._ignored_config_files = ignored_config_files + self._inicfg = inicfg + self._parser.extra_info["rootdir"] = str(self.rootpath) + self._parser.extra_info["inifile"] = str(self.inipath) + + self._parser.addini("addopts", "Extra command line options", "args") + self._parser.addini("minversion", "Minimally required pytest version") + self._parser.addini( + "pythonpath", type="paths", help="Add paths to sys.path", default=[] + ) + self._parser.addini( + "required_plugins", + "Plugins that must be present for pytest to run", + type="args", + default=[], + ) + + if addopts: + args[:] = ( + self._validate_args(self.getini("addopts"), "via addopts config") + args + ) + + self.known_args_namespace = self._parser.parse_known_args( + args, namespace=copy.copy(self.option) + ) + self._checkversion() + self._consider_importhook() + self._configure_python_path() + self.pluginmanager.consider_preparse(args, exclude_only=False) + if ( + not os.environ.get("PYTEST_DISABLE_PLUGIN_AUTOLOAD") + and not self.known_args_namespace.disable_plugin_autoload + ): + # Autoloading from distribution package entry point has + # not been disabled. + self.pluginmanager.load_setuptools_entrypoints("pytest11") + # Otherwise only plugins explicitly specified in PYTEST_PLUGINS + # are going to be loaded. + self.pluginmanager.consider_env() + + self._parser.parse_known_args(args, namespace=self.known_args_namespace) + + self._validate_plugins() + self._warn_about_skipped_plugins() + + if self.known_args_namespace.confcutdir is None: + if self.inipath is not None: + confcutdir = str(self.inipath.parent) + else: + confcutdir = str(self.rootpath) + self.known_args_namespace.confcutdir = confcutdir + try: + self.hook.pytest_load_initial_conftests( + early_config=self, args=args, parser=self._parser + ) + except ConftestImportFailure as e: + if self.known_args_namespace.help or self.known_args_namespace.version: + # we don't want to prevent --help/--version to work + # so just let it pass and print a warning at the end + self.issue_config_time_warning( + PytestConfigWarning(f"could not load initial conftests: {e.path}"), + stacklevel=2, + ) + else: + raise + + try: + self._parser.parse(args, namespace=self.option) + except PrintHelp: + return + + self.args, self.args_source = self._decide_args( + args=getattr(self.option, FILE_OR_DIR), + pyargs=self.option.pyargs, + testpaths=self.getini("testpaths"), + invocation_dir=self.invocation_params.dir, + rootpath=self.rootpath, + warn=True, + ) + + def issue_config_time_warning(self, warning: Warning, stacklevel: int) -> None: + """Issue and handle a warning during the "configure" stage. + + During ``pytest_configure`` we can't capture warnings using the ``catch_warnings_for_item`` + function because it is not possible to have hook wrappers around ``pytest_configure``. + + This function is mainly intended for plugins that need to issue warnings during + ``pytest_configure`` (or similar stages). + + :param warning: The warning instance. + :param stacklevel: stacklevel forwarded to warnings.warn. + """ + if self.pluginmanager.is_blocked("warnings"): + return + + cmdline_filters = self.known_args_namespace.pythonwarnings or [] + config_filters = self.getini("filterwarnings") + + with warnings.catch_warnings(record=True) as records: + warnings.simplefilter("always", type(warning)) + apply_warning_filters(config_filters, cmdline_filters) + warnings.warn(warning, stacklevel=stacklevel) + + if records: + frame = sys._getframe(stacklevel - 1) + location = frame.f_code.co_filename, frame.f_lineno, frame.f_code.co_name + self.hook.pytest_warning_recorded.call_historic( + kwargs=dict( + warning_message=records[0], + when="config", + nodeid="", + location=location, + ) + ) + + def addinivalue_line(self, name: str, line: str) -> None: + """Add a line to a configuration option. The option must have been + declared but might not yet be set in which case the line becomes + the first line in its value.""" + x = self.getini(name) + assert isinstance(x, list) + x.append(line) # modifies the cached list inline + + def getini(self, name: str) -> Any: + """Return configuration value the an :ref:`configuration file <configfiles>`. + + If a configuration value is not defined in a + :ref:`configuration file <configfiles>`, then the ``default`` value + provided while registering the configuration through + :func:`parser.addini <pytest.Parser.addini>` will be returned. + Please note that you can even provide ``None`` as a valid + default value. + + If ``default`` is not provided while registering using + :func:`parser.addini <pytest.Parser.addini>`, then a default value + based on the ``type`` parameter passed to + :func:`parser.addini <pytest.Parser.addini>` will be returned. + The default values based on ``type`` are: + ``paths``, ``pathlist``, ``args`` and ``linelist`` : empty list ``[]`` + ``bool`` : ``False`` + ``string`` : empty string ``""`` + ``int`` : ``0`` + ``float`` : ``0.0`` + + If neither the ``default`` nor the ``type`` parameter is passed + while registering the configuration through + :func:`parser.addini <pytest.Parser.addini>`, then the configuration + is treated as a string and a default empty string '' is returned. + + If the specified name hasn't been registered through a prior + :func:`parser.addini <pytest.Parser.addini>` call (usually from a + plugin), a ValueError is raised. + """ + canonical_name = self._parser._ini_aliases.get(name, name) + try: + return self._inicache[canonical_name] + except KeyError: + pass + self._inicache[canonical_name] = val = self._getini(canonical_name) + return val + + # Meant for easy monkeypatching by legacypath plugin. + # Can be inlined back (with no cover removed) once legacypath is gone. + def _getini_unknown_type(self, name: str, type: str, value: object): + msg = ( + f"Option {name} has unknown configuration type {type} with value {value!r}" + ) + raise ValueError(msg) # pragma: no cover + + def _getini(self, name: str): + # If this is an alias, resolve to canonical name. + canonical_name = self._parser._ini_aliases.get(name, name) + + try: + _description, type, default = self._parser._inidict[canonical_name] + except KeyError as e: + raise ValueError(f"unknown configuration value: {name!r}") from e + + # Collect all possible values (canonical name + aliases) from _inicfg. + # Each candidate is (ConfigValue, is_canonical). + candidates = [] + if canonical_name in self._inicfg: + candidates.append((self._inicfg[canonical_name], True)) + for alias, target in self._parser._ini_aliases.items(): + if target == canonical_name and alias in self._inicfg: + candidates.append((self._inicfg[alias], False)) + + if not candidates: + return default + + # Pick the best candidate based on precedence: + # 1. CLI override takes precedence over file, then + # 2. Canonical name takes precedence over alias. + selected = max(candidates, key=lambda x: (x[0].origin == "override", x[1]))[0] + value = selected.value + mode = selected.mode + + if mode == "ini": + # In ini mode, values are always str | list[str]. + assert isinstance(value, (str, list)) + return self._getini_ini(name, canonical_name, type, value, default) + elif mode == "toml": + return self._getini_toml(name, canonical_name, type, value, default) + else: + assert_never(mode) + + def _getini_ini( + self, + name: str, + canonical_name: str, + type: str, + value: str | list[str], + default: Any, + ): + """Handle config values read in INI mode. + + In INI mode, values are stored as str or list[str] only, and coerced + from string based on the registered type. + """ + # Note: some coercions are only required if we are reading from .ini + # files, because the file format doesn't contain type information, but + # when reading from toml (in ini mode) we will get either str or list of + # str values (see load_config_dict_from_file). For example: + # + # ini: + # a_line_list = "tests acceptance" + # + # in this case, we need to split the string to obtain a list of strings. + # + # toml (ini mode): + # a_line_list = ["tests", "acceptance"] + # + # in this case, we already have a list ready to use. + if type == "paths": + dp = ( + self.inipath.parent + if self.inipath is not None + else self.invocation_params.dir + ) + input_values = shlex.split(value) if isinstance(value, str) else value + return [dp / x for x in input_values] + elif type == "args": + return shlex.split(value) if isinstance(value, str) else value + elif type == "linelist": + if isinstance(value, str): + return [t for t in map(lambda x: x.strip(), value.split("\n")) if t] + else: + return value + elif type == "bool": + return _strtobool(str(value).strip()) + elif type == "string": + return value + elif type == "int": + if not isinstance(value, str): + raise TypeError( + f"Expected an int string for option {name} of type integer, but got: {value!r}" + ) from None + return int(value) + elif type == "float": + if not isinstance(value, str): + raise TypeError( + f"Expected a float string for option {name} of type float, but got: {value!r}" + ) from None + return float(value) + else: + return self._getini_unknown_type(name, type, value) + + def _getini_toml( + self, + name: str, + canonical_name: str, + type: str, + value: object, + default: Any, + ): + """Handle TOML config values with strict type validation and no coercion. + + In TOML mode, values already have native types from TOML parsing. + We validate types match expectations exactly, including list items. + """ + value_type = builtins.type(value).__name__ + if type == "paths": + # Expect a list of strings. + if not isinstance(value, list): + raise TypeError( + f"{self.inipath}: config option '{name}' expects a list for type 'paths', " + f"got {value_type}: {value!r}" + ) + for i, item in enumerate(value): + if not isinstance(item, str): + item_type = builtins.type(item).__name__ + raise TypeError( + f"{self.inipath}: config option '{name}' expects a list of strings, " + f"but item at index {i} is {item_type}: {item!r}" + ) + dp = ( + self.inipath.parent + if self.inipath is not None + else self.invocation_params.dir + ) + return [dp / x for x in value] + elif type in {"args", "linelist"}: + # Expect a list of strings. + if not isinstance(value, list): + raise TypeError( + f"{self.inipath}: config option '{name}' expects a list for type '{type}', " + f"got {value_type}: {value!r}" + ) + for i, item in enumerate(value): + if not isinstance(item, str): + item_type = builtins.type(item).__name__ + raise TypeError( + f"{self.inipath}: config option '{name}' expects a list of strings, " + f"but item at index {i} is {item_type}: {item!r}" + ) + return list(value) + elif type == "bool": + # Expect a boolean. + if not isinstance(value, bool): + raise TypeError( + f"{self.inipath}: config option '{name}' expects a bool, " + f"got {value_type}: {value!r}" + ) + return value + elif type == "int": + # Expect an integer (but not bool, which is a subclass of int). + if not isinstance(value, int) or isinstance(value, bool): + raise TypeError( + f"{self.inipath}: config option '{name}' expects an int, " + f"got {value_type}: {value!r}" + ) + return value + elif type == "float": + # Expect a float or integer only. + if not isinstance(value, (float, int)) or isinstance(value, bool): + raise TypeError( + f"{self.inipath}: config option '{name}' expects a float, " + f"got {value_type}: {value!r}" + ) + return value + elif type == "string": + # Expect a string. + if not isinstance(value, str): + raise TypeError( + f"{self.inipath}: config option '{name}' expects a string, " + f"got {value_type}: {value!r}" + ) + return value + else: + return self._getini_unknown_type(name, type, value) + + def _getconftest_pathlist( + self, name: str, path: pathlib.Path + ) -> list[pathlib.Path] | None: + try: + mod, relroots = self.pluginmanager._rget_with_confmod(name, path) + except KeyError: + return None + assert mod.__file__ is not None + modpath = pathlib.Path(mod.__file__).parent + values: list[pathlib.Path] = [] + for relroot in relroots: + if isinstance(relroot, os.PathLike): + relroot = pathlib.Path(relroot) + else: + relroot = relroot.replace("/", os.sep) + relroot = absolutepath(modpath / relroot) + values.append(relroot) + return values + + def getoption(self, name: str, default: Any = notset, skip: bool = False): + """Return command line option value. + + :param name: Name of the option. You may also specify + the literal ``--OPT`` option instead of the "dest" option name. + :param default: Fallback value if no option of that name is **declared** via :hook:`pytest_addoption`. + Note this parameter will be ignored when the option is **declared** even if the option's value is ``None``. + :param skip: If ``True``, raise :func:`pytest.skip` if option is undeclared or has a ``None`` value. + Note that even if ``True``, if a default was specified it will be returned instead of a skip. + """ + name = self._opt2dest.get(name, name) + try: + val = getattr(self.option, name) + if val is None and skip: + raise AttributeError(name) + return val + except AttributeError as e: + if default is not notset: + return default + if skip: + import pytest + + pytest.skip(f"no {name!r} option found") + raise ValueError(f"no option named {name!r}") from e + + def getvalue(self, name: str, path=None): + """Deprecated, use getoption() instead.""" + return self.getoption(name) + + def getvalueorskip(self, name: str, path=None): + """Deprecated, use getoption(skip=True) instead.""" + return self.getoption(name, skip=True) + + #: Verbosity type for failed assertions (see :confval:`verbosity_assertions`). + VERBOSITY_ASSERTIONS: Final = "assertions" + #: Verbosity type for test case execution (see :confval:`verbosity_test_cases`). + VERBOSITY_TEST_CASES: Final = "test_cases" + #: Verbosity type for failed subtests (see :confval:`verbosity_subtests`). + VERBOSITY_SUBTESTS: Final = "subtests" + + _VERBOSITY_INI_DEFAULT: Final = "auto" + + def get_verbosity(self, verbosity_type: str | None = None) -> int: + r"""Retrieve the verbosity level for a fine-grained verbosity type. + + :param verbosity_type: Verbosity type to get level for. If a level is + configured for the given type, that value will be returned. If the + given type is not a known verbosity type, the global verbosity + level will be returned. If the given type is None (default), the + global verbosity level will be returned. + + To configure a level for a fine-grained verbosity type, the + configuration file should have a setting for the configuration name + and a numeric value for the verbosity level. A special value of "auto" + can be used to explicitly use the global verbosity level. + + Example: + + .. tab:: toml + + .. code-block:: toml + + [tool.pytest] + verbosity_assertions = 2 + + .. tab:: ini + + .. code-block:: ini + + [pytest] + verbosity_assertions = 2 + + .. code-block:: console + + pytest -v + + .. code-block:: python + + print(config.get_verbosity()) # 1 + print(config.get_verbosity(Config.VERBOSITY_ASSERTIONS)) # 2 + """ + global_level = self.getoption("verbose", default=0) + assert isinstance(global_level, int) + if verbosity_type is None: + return global_level + + ini_name = Config._verbosity_ini_name(verbosity_type) + if ini_name not in self._parser._inidict: + return global_level + + level = self.getini(ini_name) + if level == Config._VERBOSITY_INI_DEFAULT: + return global_level + + return int(level) + + @staticmethod + def _verbosity_ini_name(verbosity_type: str) -> str: + return f"verbosity_{verbosity_type}" + + @staticmethod + def _add_verbosity_ini(parser: Parser, verbosity_type: str, help: str) -> None: + """Add a output verbosity configuration option for the given output type. + + :param parser: Parser for command line arguments and config-file values. + :param verbosity_type: Fine-grained verbosity category. + :param help: Description of the output this type controls. + + The value should be retrieved via a call to + :py:func:`config.get_verbosity(type) <pytest.Config.get_verbosity>`. + """ + parser.addini( + Config._verbosity_ini_name(verbosity_type), + help=help, + type="string", + default=Config._VERBOSITY_INI_DEFAULT, + ) + + def _warn_about_missing_assertion(self, mode: str) -> None: + if not _assertion_supported(): + if mode == "plain": + warning_text = ( + "ASSERTIONS ARE NOT EXECUTED" + " and FAILING TESTS WILL PASS. Are you" + " using python -O?" + ) + else: + warning_text = ( + "assertions not in test modules or" + " plugins will be ignored" + " because assert statements are not executed " + "by the underlying Python interpreter " + "(are you using python -O?)\n" + ) + self.issue_config_time_warning( + PytestConfigWarning(warning_text), + stacklevel=3, + ) + + def _warn_about_skipped_plugins(self) -> None: + for module_name, msg in self.pluginmanager.skipped_plugins: + self.issue_config_time_warning( + PytestConfigWarning(f"skipped plugin {module_name!r}: {msg}"), + stacklevel=2, + ) + + +def _assertion_supported() -> bool: + try: + assert False + except AssertionError: + return True + else: + return False # type: ignore[unreachable] + + +def create_terminal_writer( + config: Config, file: TextIO | None = None +) -> TerminalWriter: + """Create a TerminalWriter instance configured according to the options + in the config object. + + Every code which requires a TerminalWriter object and has access to a + config object should use this function. + """ + tw = TerminalWriter(file=file) + + if config.option.color == "yes": + tw.hasmarkup = True + elif config.option.color == "no": + tw.hasmarkup = False + + if config.option.code_highlight == "yes": + tw.code_highlight = True + elif config.option.code_highlight == "no": + tw.code_highlight = False + + return tw + + +def _strtobool(val: str) -> bool: + """Convert a string representation of truth to True or False. + + True values are 'y', 'yes', 't', 'true', 'on', and '1'; false values + are 'n', 'no', 'f', 'false', 'off', and '0'. Raises ValueError if + 'val' is anything else. + + .. note:: Copied from distutils.util. + """ + val = val.lower() + if val in ("y", "yes", "t", "true", "on", "1"): + return True + elif val in ("n", "no", "f", "false", "off", "0"): + return False + else: + raise ValueError(f"invalid truth value {val!r}") + + +@lru_cache(maxsize=50) +def parse_warning_filter( + arg: str, *, escape: bool +) -> tuple[warnings._ActionKind, str, type[Warning], str, int]: + """Parse a warnings filter string. + + This is copied from warnings._setoption with the following changes: + + * Does not apply the filter. + * Escaping is optional. + * Raises UsageError so we get nice error messages on failure. + """ + __tracebackhide__ = True + error_template = dedent( + f"""\ + while parsing the following warning configuration: + + {arg} + + This error occurred: + + {{error}} + """ + ) + + parts = arg.split(":") + if len(parts) > 5: + doc_url = ( + "https://docs.python.org/3/library/warnings.html#describing-warning-filters" + ) + error = dedent( + f"""\ + Too many fields ({len(parts)}), expected at most 5 separated by colons: + + action:message:category:module:line + + For more information please consult: {doc_url} + """ + ) + raise UsageError(error_template.format(error=error)) + + while len(parts) < 5: + parts.append("") + action_, message, category_, module, lineno_ = (s.strip() for s in parts) + try: + action: warnings._ActionKind = warnings._getaction(action_) # type: ignore[attr-defined] + except warnings._OptionError as e: + raise UsageError(error_template.format(error=str(e))) from None + try: + category: type[Warning] = _resolve_warning_category(category_) + except ImportError: + raise + except Exception: + exc_info = ExceptionInfo.from_current() + exception_text = exc_info.getrepr(style="native") + raise UsageError(error_template.format(error=exception_text)) from None + if message and escape: + message = re.escape(message) + if module and escape: + module = re.escape(module) + r"\Z" + if lineno_: + try: + lineno = int(lineno_) + if lineno < 0: + raise ValueError("number is negative") + except ValueError as e: + raise UsageError( + error_template.format(error=f"invalid lineno {lineno_!r}: {e}") + ) from None + else: + lineno = 0 + try: + re.compile(message) + re.compile(module) + except re.error as e: + raise UsageError( + error_template.format(error=f"Invalid regex {e.pattern!r}: {e}") + ) from None + return action, message, category, module, lineno + + +def _resolve_warning_category(category: str) -> type[Warning]: + """ + Copied from warnings._getcategory, but changed so it lets exceptions (specially ImportErrors) + propagate so we can get access to their tracebacks (#9218). + """ + __tracebackhide__ = True + if not category: + return Warning + + if "." not in category: + import builtins as m + + klass = category + else: + module, _, klass = category.rpartition(".") + m = __import__(module, None, None, [klass]) + cat = getattr(m, klass) + if not issubclass(cat, Warning): + raise UsageError(f"{cat} is not a Warning subclass") + return cast(type[Warning], cat) + + +def apply_warning_filters( + config_filters: Iterable[str], cmdline_filters: Iterable[str] +) -> None: + """Applies pytest-configured filters to the warnings module""" + # Filters should have this precedence: cmdline options, config. + # Filters should be applied in the inverse order of precedence. + for arg in config_filters: + try: + warnings.filterwarnings(*parse_warning_filter(arg, escape=False)) + except ImportError as e: + warnings.warn( + f"Failed to import filter module '{e.name}': {arg}", PytestConfigWarning + ) + continue + + for arg in cmdline_filters: + try: + warnings.filterwarnings(*parse_warning_filter(arg, escape=True)) + except ImportError as e: + warnings.warn( + f"Failed to import filter module '{e.name}': {arg}", PytestConfigWarning + ) + continue diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/config/argparsing.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/config/argparsing.py new file mode 100644 index 0000000000000000000000000000000000000000..8216ad8b226a5fc086d68a0022413036dbb64b9a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/config/argparsing.py @@ -0,0 +1,578 @@ +# mypy: allow-untyped-defs +from __future__ import annotations + +import argparse +from collections.abc import Callable +from collections.abc import Mapping +from collections.abc import Sequence +import os +import sys +from typing import Any +from typing import final +from typing import Literal +from typing import NoReturn + +from .exceptions import UsageError +import _pytest._io +from _pytest.deprecated import check_ispytest + + +FILE_OR_DIR = "file_or_dir" + + +class NotSet: + def __repr__(self) -> str: + return "<notset>" + + +NOT_SET = NotSet() + + +@final +class Parser: + """Parser for command line arguments and config-file values. + + :ivar extra_info: Dict of generic param -> value to display in case + there's an error processing the command line arguments. + """ + + def __init__( + self, + usage: str | None = None, + processopt: Callable[[Argument], None] | None = None, + *, + _ispytest: bool = False, + ) -> None: + check_ispytest(_ispytest) + + from _pytest._argcomplete import filescompleter + + self._processopt = processopt + self.extra_info: dict[str, Any] = {} + self.optparser = PytestArgumentParser(self, usage, self.extra_info) + anonymous_arggroup = self.optparser.add_argument_group("Custom options") + self._anonymous = OptionGroup( + anonymous_arggroup, "_anonymous", self, _ispytest=True + ) + self._groups = [self._anonymous] + file_or_dir_arg = self.optparser.add_argument(FILE_OR_DIR, nargs="*") + file_or_dir_arg.completer = filescompleter # type: ignore + + self._inidict: dict[str, tuple[str, str, Any]] = {} + # Maps alias -> canonical name. + self._ini_aliases: dict[str, str] = {} + + @property + def prog(self) -> str: + return self.optparser.prog + + @prog.setter + def prog(self, value: str) -> None: + self.optparser.prog = value + + def processoption(self, option: Argument) -> None: + if self._processopt: + if option.dest: + self._processopt(option) + + def getgroup( + self, name: str, description: str = "", after: str | None = None + ) -> OptionGroup: + """Get (or create) a named option Group. + + :param name: Name of the option group. + :param description: Long description for --help output. + :param after: Name of another group, used for ordering --help output. + :returns: The option group. + + The returned group object has an ``addoption`` method with the same + signature as :func:`parser.addoption <pytest.Parser.addoption>` but + will be shown in the respective group in the output of + ``pytest --help``. + """ + for group in self._groups: + if group.name == name: + return group + + arggroup = self.optparser.add_argument_group(description or name) + group = OptionGroup(arggroup, name, self, _ispytest=True) + i = 0 + for i, grp in enumerate(self._groups): + if grp.name == after: + break + self._groups.insert(i + 1, group) + # argparse doesn't provide a way to control `--help` order, so must + # access its internals ☹. + self.optparser._action_groups.insert(i + 1, self.optparser._action_groups.pop()) + return group + + def addoption(self, *opts: str, **attrs: Any) -> None: + """Register a command line option. + + :param opts: + Option names, can be short or long options. + :param attrs: + Same attributes as the argparse library's :meth:`add_argument() + <argparse.ArgumentParser.add_argument>` function accepts. + + After command line parsing, options are available on the pytest config + object via ``config.option.NAME`` where ``NAME`` is usually set + by passing a ``dest`` attribute, for example + ``addoption("--long", dest="NAME", ...)``. + """ + self._anonymous.addoption(*opts, **attrs) + + def parse( + self, + args: Sequence[str | os.PathLike[str]], + namespace: argparse.Namespace | None = None, + ) -> argparse.Namespace: + """Parse the arguments. + + Unlike ``parse_known_args`` and ``parse_known_and_unknown_args``, + raises PrintHelp on `--help` and UsageError on unknown flags + + :meta private: + """ + from _pytest._argcomplete import try_argcomplete + + try_argcomplete(self.optparser) + strargs = [os.fspath(x) for x in args] + if namespace is None: + namespace = argparse.Namespace() + try: + namespace._raise_print_help = True + return self.optparser.parse_intermixed_args(strargs, namespace=namespace) + finally: + del namespace._raise_print_help + + def parse_known_args( + self, + args: Sequence[str | os.PathLike[str]], + namespace: argparse.Namespace | None = None, + ) -> argparse.Namespace: + """Parse the known arguments at this point. + + :returns: An argparse namespace object. + """ + return self.parse_known_and_unknown_args(args, namespace=namespace)[0] + + def parse_known_and_unknown_args( + self, + args: Sequence[str | os.PathLike[str]], + namespace: argparse.Namespace | None = None, + ) -> tuple[argparse.Namespace, list[str]]: + """Parse the known arguments at this point, and also return the + remaining unknown flag arguments. + + :returns: + A tuple containing an argparse namespace object for the known + arguments, and a list of unknown flag arguments. + """ + strargs = [os.fspath(x) for x in args] + if sys.version_info < (3, 12, 8) or (3, 13) <= sys.version_info < (3, 13, 1): + # Older argparse have a bugged parse_known_intermixed_args. + namespace, unknown = self.optparser.parse_known_args(strargs, namespace) + assert namespace is not None + file_or_dir = getattr(namespace, FILE_OR_DIR) + unknown_flags: list[str] = [] + for arg in unknown: + (unknown_flags if arg.startswith("-") else file_or_dir).append(arg) + return namespace, unknown_flags + else: + return self.optparser.parse_known_intermixed_args(strargs, namespace) + + def addini( + self, + name: str, + help: str, + type: Literal[ + "string", "paths", "pathlist", "args", "linelist", "bool", "int", "float" + ] + | None = None, + default: Any = NOT_SET, + *, + aliases: Sequence[str] = (), + ) -> None: + """Register a configuration file option. + + :param name: + Name of the configuration. + :param type: + Type of the configuration. Can be: + + * ``string``: a string + * ``bool``: a boolean + * ``args``: a list of strings, separated as in a shell + * ``linelist``: a list of strings, separated by line breaks + * ``paths``: a list of :class:`pathlib.Path`, separated as in a shell + * ``pathlist``: a list of ``py.path``, separated as in a shell + * ``int``: an integer + * ``float``: a floating-point number + + .. versionadded:: 8.4 + + The ``float`` and ``int`` types. + + For ``paths`` and ``pathlist`` types, they are considered relative to the config-file. + In case the execution is happening without a config-file defined, + they will be considered relative to the current working directory (for example with ``--override-ini``). + + .. versionadded:: 7.0 + The ``paths`` variable type. + + .. versionadded:: 8.1 + Use the current working directory to resolve ``paths`` and ``pathlist`` in the absence of a config-file. + + Defaults to ``string`` if ``None`` or not passed. + :param default: + Default value if no config-file option exists but is queried. + :param aliases: + Additional names by which this option can be referenced. + Aliases resolve to the canonical name. + + .. versionadded:: 9.0 + The ``aliases`` parameter. + + The value of configuration keys can be retrieved via a call to + :py:func:`config.getini(name) <pytest.Config.getini>`. + """ + assert type in ( + None, + "string", + "paths", + "pathlist", + "args", + "linelist", + "bool", + "int", + "float", + ) + if type is None: + type = "string" + if default is NOT_SET: + default = get_ini_default_for_type(type) + + self._inidict[name] = (help, type, default) + + for alias in aliases: + if alias in self._inidict: + raise ValueError( + f"alias {alias!r} conflicts with existing configuration option" + ) + if (already := self._ini_aliases.get(alias)) is not None: + raise ValueError(f"{alias!r} is already an alias of {already!r}") + self._ini_aliases[alias] = name + + +def get_ini_default_for_type( + type: Literal[ + "string", "paths", "pathlist", "args", "linelist", "bool", "int", "float" + ], +) -> Any: + """ + Used by addini to get the default value for a given config option type, when + default is not supplied. + """ + if type in ("paths", "pathlist", "args", "linelist"): + return [] + elif type == "bool": + return False + elif type == "int": + return 0 + elif type == "float": + return 0.0 + else: + return "" + + +class ArgumentError(Exception): + """Raised if an Argument instance is created with invalid or + inconsistent arguments.""" + + def __init__(self, msg: str, option: Argument | str) -> None: + self.msg = msg + self.option_id = str(option) + + def __str__(self) -> str: + if self.option_id: + return f"option {self.option_id}: {self.msg}" + else: + return self.msg + + +class Argument: + """Class that mimics the necessary behaviour of optparse.Option. + + It's currently a least effort implementation and ignoring choices + and integer prefixes. + + https://docs.python.org/3/library/optparse.html#optparse-standard-option-types + """ + + def __init__(self, *names: str, **attrs: Any) -> None: + """Store params in private vars for use in add_argument.""" + self._attrs = attrs + self._short_opts: list[str] = [] + self._long_opts: list[str] = [] + try: + self.type = attrs["type"] + except KeyError: + pass + try: + # Attribute existence is tested in Config._processopt. + self.default = attrs["default"] + except KeyError: + pass + self._set_opt_strings(names) + dest: str | None = attrs.get("dest") + if dest: + self.dest = dest + elif self._long_opts: + self.dest = self._long_opts[0][2:].replace("-", "_") + else: + try: + self.dest = self._short_opts[0][1:] + except IndexError as e: + self.dest = "???" # Needed for the error repr. + raise ArgumentError("need a long or short option", self) from e + + def names(self) -> list[str]: + return self._short_opts + self._long_opts + + def attrs(self) -> Mapping[str, Any]: + # Update any attributes set by processopt. + for attr in ("default", "dest", "help", self.dest): + try: + self._attrs[attr] = getattr(self, attr) + except AttributeError: + pass + return self._attrs + + def _set_opt_strings(self, opts: Sequence[str]) -> None: + """Directly from optparse. + + Might not be necessary as this is passed to argparse later on. + """ + for opt in opts: + if len(opt) < 2: + raise ArgumentError( + f"invalid option string {opt!r}: " + "must be at least two characters long", + self, + ) + elif len(opt) == 2: + if not (opt[0] == "-" and opt[1] != "-"): + raise ArgumentError( + f"invalid short option string {opt!r}: " + "must be of the form -x, (x any non-dash char)", + self, + ) + self._short_opts.append(opt) + else: + if not (opt[0:2] == "--" and opt[2] != "-"): + raise ArgumentError( + f"invalid long option string {opt!r}: " + "must start with --, followed by non-dash", + self, + ) + self._long_opts.append(opt) + + def __repr__(self) -> str: + args: list[str] = [] + if self._short_opts: + args += ["_short_opts: " + repr(self._short_opts)] + if self._long_opts: + args += ["_long_opts: " + repr(self._long_opts)] + args += ["dest: " + repr(self.dest)] + if hasattr(self, "type"): + args += ["type: " + repr(self.type)] + if hasattr(self, "default"): + args += ["default: " + repr(self.default)] + return "Argument({})".format(", ".join(args)) + + +class OptionGroup: + """A group of options shown in its own section.""" + + def __init__( + self, + arggroup: argparse._ArgumentGroup, + name: str, + parser: Parser | None, + _ispytest: bool = False, + ) -> None: + check_ispytest(_ispytest) + self._arggroup = arggroup + self.name = name + self.options: list[Argument] = [] + self.parser = parser + + def addoption(self, *opts: str, **attrs: Any) -> None: + """Add an option to this group. + + If a shortened version of a long option is specified, it will + be suppressed in the help. ``addoption('--twowords', '--two-words')`` + results in help showing ``--two-words`` only, but ``--twowords`` gets + accepted **and** the automatic destination is in ``args.twowords``. + + :param opts: + Option names, can be short or long options. + :param attrs: + Same attributes as the argparse library's :meth:`add_argument() + <argparse.ArgumentParser.add_argument>` function accepts. + """ + conflict = set(opts).intersection( + name for opt in self.options for name in opt.names() + ) + if conflict: + raise ValueError(f"option names {conflict} already added") + option = Argument(*opts, **attrs) + self._addoption_instance(option, shortupper=False) + + def _addoption(self, *opts: str, **attrs: Any) -> None: + option = Argument(*opts, **attrs) + self._addoption_instance(option, shortupper=True) + + def _addoption_instance(self, option: Argument, shortupper: bool = False) -> None: + if not shortupper: + for opt in option._short_opts: + if opt[0] == "-" and opt[1].islower(): + raise ValueError("lowercase shortoptions reserved") + + if self.parser: + self.parser.processoption(option) + + self._arggroup.add_argument(*option.names(), **option.attrs()) + self.options.append(option) + + +class PytestArgumentParser(argparse.ArgumentParser): + def __init__( + self, + parser: Parser, + usage: str | None, + extra_info: dict[str, str], + ) -> None: + self._parser = parser + super().__init__( + usage=usage, + add_help=False, + formatter_class=DropShorterLongHelpFormatter, + allow_abbrev=False, + fromfile_prefix_chars="@", + ) + # extra_info is a dict of (param -> value) to display if there's + # an usage error to provide more contextual information to the user. + self.extra_info = extra_info + + def error(self, message: str) -> NoReturn: + """Transform argparse error message into UsageError.""" + msg = f"{self.prog}: error: {message}" + if self.extra_info: + msg += "\n" + "\n".join( + f" {k}: {v}" for k, v in sorted(self.extra_info.items()) + ) + raise UsageError(self.format_usage() + msg) + + +class DropShorterLongHelpFormatter(argparse.HelpFormatter): + """Shorten help for long options that differ only in extra hyphens. + + - Collapse **long** options that are the same except for extra hyphens. + - Shortcut if there are only two options and one of them is a short one. + - Cache result on the action object as this is called at least 2 times. + """ + + def __init__(self, *args: Any, **kwargs: Any) -> None: + # Use more accurate terminal width. + if "width" not in kwargs: + kwargs["width"] = _pytest._io.get_terminal_width() + super().__init__(*args, **kwargs) + + def _format_action_invocation(self, action: argparse.Action) -> str: + orgstr = super()._format_action_invocation(action) + if orgstr and orgstr[0] != "-": # only optional arguments + return orgstr + res: str | None = getattr(action, "_formatted_action_invocation", None) + if res: + return res + options = orgstr.split(", ") + if len(options) == 2 and (len(options[0]) == 2 or len(options[1]) == 2): + # a shortcut for '-h, --help' or '--abc', '-a' + action._formatted_action_invocation = orgstr # type: ignore + return orgstr + return_list = [] + short_long: dict[str, str] = {} + for option in options: + if len(option) == 2 or option[2] == " ": + continue + if not option.startswith("--"): + raise ArgumentError( + f'long optional argument without "--": [{option}]', option + ) + xxoption = option[2:] + shortened = xxoption.replace("-", "") + if shortened not in short_long or len(short_long[shortened]) < len( + xxoption + ): + short_long[shortened] = xxoption + # now short_long has been filled out to the longest with dashes + # **and** we keep the right option ordering from add_argument + for option in options: + if len(option) == 2 or option[2] == " ": + return_list.append(option) + if option[2:] == short_long.get(option.replace("-", "")): + return_list.append(option.replace(" ", "=", 1)) + formatted_action_invocation = ", ".join(return_list) + action._formatted_action_invocation = formatted_action_invocation # type: ignore + return formatted_action_invocation + + def _split_lines(self, text, width): + """Wrap lines after splitting on original newlines. + + This allows to have explicit line breaks in the help text. + """ + import textwrap + + lines = [] + for line in text.splitlines(): + lines.extend(textwrap.wrap(line.strip(), width)) + return lines + + +class OverrideIniAction(argparse.Action): + """Custom argparse action that makes a CLI flag equivalent to overriding an + option, in addition to behaving like `store_true`. + + This can simplify things since code only needs to inspect the config option + and not consider the CLI flag. + """ + + def __init__( + self, + option_strings: Sequence[str], + dest: str, + nargs: int | str | None = None, + *args, + ini_option: str, + ini_value: str, + **kwargs, + ) -> None: + super().__init__(option_strings, dest, 0, *args, **kwargs) + self.ini_option = ini_option + self.ini_value = ini_value + + def __call__( + self, + parser: argparse.ArgumentParser, + namespace: argparse.Namespace, + *args, + **kwargs, + ) -> None: + setattr(namespace, self.dest, True) + current_overrides = getattr(namespace, "override_ini", None) + if current_overrides is None: + current_overrides = [] + current_overrides.append(f"{self.ini_option}={self.ini_value}") + setattr(namespace, "override_ini", current_overrides) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/config/compat.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/config/compat.py new file mode 100644 index 0000000000000000000000000000000000000000..21eab4c7e47aa2af1690887716055943c0f99fdc --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/config/compat.py @@ -0,0 +1,85 @@ +from __future__ import annotations + +from collections.abc import Mapping +import functools +from pathlib import Path +from typing import Any +import warnings + +import pluggy + +from ..compat import LEGACY_PATH +from ..compat import legacy_path +from ..deprecated import HOOK_LEGACY_PATH_ARG + + +# hookname: (Path, LEGACY_PATH) +imply_paths_hooks: Mapping[str, tuple[str, str]] = { + "pytest_ignore_collect": ("collection_path", "path"), + "pytest_collect_file": ("file_path", "path"), + "pytest_pycollect_makemodule": ("module_path", "path"), + "pytest_report_header": ("start_path", "startdir"), + "pytest_report_collectionfinish": ("start_path", "startdir"), +} + + +def _check_path(path: Path, fspath: LEGACY_PATH) -> None: + if Path(fspath) != path: + raise ValueError( + f"Path({fspath!r}) != {path!r}\n" + "if both path and fspath are given they need to be equal" + ) + + +class PathAwareHookProxy: + """ + this helper wraps around hook callers + until pluggy supports fixingcalls, this one will do + + it currently doesn't return full hook caller proxies for fixed hooks, + this may have to be changed later depending on bugs + """ + + def __init__(self, hook_relay: pluggy.HookRelay) -> None: + self._hook_relay = hook_relay + + def __dir__(self) -> list[str]: + return dir(self._hook_relay) + + def __getattr__(self, key: str) -> pluggy.HookCaller: + hook: pluggy.HookCaller = getattr(self._hook_relay, key) + if key not in imply_paths_hooks: + self.__dict__[key] = hook + return hook + else: + path_var, fspath_var = imply_paths_hooks[key] + + @functools.wraps(hook) + def fixed_hook(**kw: Any) -> Any: + path_value: Path | None = kw.pop(path_var, None) + fspath_value: LEGACY_PATH | None = kw.pop(fspath_var, None) + if fspath_value is not None: + warnings.warn( + HOOK_LEGACY_PATH_ARG.format( + pylib_path_arg=fspath_var, pathlib_path_arg=path_var + ), + stacklevel=2, + ) + if path_value is not None: + if fspath_value is not None: + _check_path(path_value, fspath_value) + else: + fspath_value = legacy_path(path_value) + else: + assert fspath_value is not None + path_value = Path(fspath_value) + + kw[path_var] = path_value + kw[fspath_var] = fspath_value + return hook(**kw) + + fixed_hook.name = hook.name # type: ignore[attr-defined] + fixed_hook.spec = hook.spec # type: ignore[attr-defined] + fixed_hook.__name__ = key + self.__dict__[key] = fixed_hook + return fixed_hook # type: ignore[return-value] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/config/exceptions.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/config/exceptions.py new file mode 100644 index 0000000000000000000000000000000000000000..d84a9ea67e07f3d9591883360fb5ee0c92422787 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/config/exceptions.py @@ -0,0 +1,15 @@ +from __future__ import annotations + +from typing import final + + +@final +class UsageError(Exception): + """Error in pytest usage or invocation.""" + + __module__ = "pytest" + + +class PrintHelp(Exception): + """Raised when pytest should print its help to skip the rest of the + argument parsing and validation.""" diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/config/findpaths.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/config/findpaths.py new file mode 100644 index 0000000000000000000000000000000000000000..3c628a09c2da7c16db785b4add163a05893ecad0 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/config/findpaths.py @@ -0,0 +1,350 @@ +from __future__ import annotations + +from collections.abc import Iterable +from collections.abc import Sequence +from dataclasses import dataclass +from dataclasses import KW_ONLY +import os +from pathlib import Path +import sys +from typing import Literal +from typing import TypeAlias + +import iniconfig + +from .exceptions import UsageError +from _pytest.outcomes import fail +from _pytest.pathlib import absolutepath +from _pytest.pathlib import commonpath +from _pytest.pathlib import safe_exists + + +@dataclass(frozen=True) +class ConfigValue: + """Represents a configuration value with its origin and parsing mode. + + This allows tracking whether a value came from a configuration file + or from a CLI override (--override-ini), which is important for + determining precedence when dealing with ini option aliases. + + The mode tracks the parsing mode/data model used for the value: + - "ini": from INI files or [tool.pytest.ini_options], where the only + supported value types are `str` or `list[str]`. + - "toml": from TOML files (not in INI mode), where native TOML types + are preserved. + """ + + value: object + _: KW_ONLY + origin: Literal["file", "override"] + mode: Literal["ini", "toml"] + + +ConfigDict: TypeAlias = dict[str, ConfigValue] + + +def _parse_ini_config(path: Path) -> iniconfig.IniConfig: + """Parse the given generic '.ini' file using legacy IniConfig parser, returning + the parsed object. + + Raise UsageError if the file cannot be parsed. + """ + try: + return iniconfig.IniConfig(str(path)) + except iniconfig.ParseError as exc: + raise UsageError(str(exc)) from exc + + +def load_config_dict_from_file( + filepath: Path, +) -> ConfigDict | None: + """Load pytest configuration from the given file path, if supported. + + Return None if the file does not contain valid pytest configuration. + """ + # Configuration from ini files are obtained from the [pytest] section, if present. + if filepath.suffix == ".ini": + iniconfig = _parse_ini_config(filepath) + + if "pytest" in iniconfig: + return { + k: ConfigValue(v, origin="file", mode="ini") + for k, v in iniconfig["pytest"].items() + } + else: + # "pytest.ini" files are always the source of configuration, even if empty. + if filepath.name in {"pytest.ini", ".pytest.ini"}: + return {} + + # '.cfg' files are considered if they contain a "[tool:pytest]" section. + elif filepath.suffix == ".cfg": + iniconfig = _parse_ini_config(filepath) + + if "tool:pytest" in iniconfig.sections: + return { + k: ConfigValue(v, origin="file", mode="ini") + for k, v in iniconfig["tool:pytest"].items() + } + elif "pytest" in iniconfig.sections: + # If a setup.cfg contains a "[pytest]" section, we raise a failure to indicate users that + # plain "[pytest]" sections in setup.cfg files is no longer supported (#3086). + fail(CFG_PYTEST_SECTION.format(filename="setup.cfg"), pytrace=False) + + # '.toml' files are considered if they contain a [tool.pytest] table (toml mode) + # or [tool.pytest.ini_options] table (ini mode) for pyproject.toml, + # or [pytest] table (toml mode) for pytest.toml/.pytest.toml. + elif filepath.suffix == ".toml": + if sys.version_info >= (3, 11): + import tomllib + else: + import tomli as tomllib + + toml_text = filepath.read_text(encoding="utf-8") + try: + config = tomllib.loads(toml_text) + except tomllib.TOMLDecodeError as exc: + raise UsageError(f"{filepath}: {exc}") from exc + + # pytest.toml and .pytest.toml use [pytest] table directly. + if filepath.name in ("pytest.toml", ".pytest.toml"): + pytest_config = config.get("pytest", {}) + if pytest_config: + # TOML mode - preserve native TOML types. + return { + k: ConfigValue(v, origin="file", mode="toml") + for k, v in pytest_config.items() + } + # "pytest.toml" files are always the source of configuration, even if empty. + return {} + + # pyproject.toml uses [tool.pytest] or [tool.pytest.ini_options]. + else: + tool_pytest = config.get("tool", {}).get("pytest", {}) + + # Check for toml mode config: [tool.pytest] with content outside of ini_options. + toml_config = {k: v for k, v in tool_pytest.items() if k != "ini_options"} + # Check for ini mode config: [tool.pytest.ini_options]. + ini_config = tool_pytest.get("ini_options", None) + + if toml_config and ini_config: + raise UsageError( + f"{filepath}: Cannot use both [tool.pytest] (native TOML types) and " + "[tool.pytest.ini_options] (string-based INI format) simultaneously. " + "Please use [tool.pytest] with native TOML types (recommended) " + "or [tool.pytest.ini_options] for backwards compatibility." + ) + + if toml_config: + # TOML mode - preserve native TOML types. + return { + k: ConfigValue(v, origin="file", mode="toml") + for k, v in toml_config.items() + } + + elif ini_config is not None: + # INI mode - TOML supports richer data types than INI files, but we need to + # convert all scalar values to str for compatibility with the INI system. + def make_scalar(v: object) -> str | list[str]: + return v if isinstance(v, list) else str(v) + + return { + k: ConfigValue(make_scalar(v), origin="file", mode="ini") + for k, v in ini_config.items() + } + + return None + + +def locate_config( + invocation_dir: Path, + args: Iterable[Path], +) -> tuple[Path | None, Path | None, ConfigDict, Sequence[str]]: + """Search in the list of arguments for a valid ini-file for pytest, + and return a tuple of (rootdir, inifile, cfg-dict, ignored-config-files), where + ignored-config-files is a list of config basenames found that contain + pytest configuration but were ignored.""" + config_names = [ + "pytest.toml", + ".pytest.toml", + "pytest.ini", + ".pytest.ini", + "pyproject.toml", + "tox.ini", + "setup.cfg", + ] + args = [x for x in args if not str(x).startswith("-")] + if not args: + args = [invocation_dir] + found_pyproject_toml: Path | None = None + ignored_config_files: list[str] = [] + + for arg in args: + argpath = absolutepath(arg) + for base in (argpath, *argpath.parents): + for config_name in config_names: + p = base / config_name + if p.is_file(): + if p.name == "pyproject.toml" and found_pyproject_toml is None: + found_pyproject_toml = p + ini_config = load_config_dict_from_file(p) + if ini_config is not None: + index = config_names.index(config_name) + for remainder in config_names[index + 1 :]: + p2 = base / remainder + if ( + p2.is_file() + and load_config_dict_from_file(p2) is not None + ): + ignored_config_files.append(remainder) + return base, p, ini_config, ignored_config_files + if found_pyproject_toml is not None: + return found_pyproject_toml.parent, found_pyproject_toml, {}, [] + return None, None, {}, [] + + +def get_common_ancestor( + invocation_dir: Path, + paths: Iterable[Path], +) -> Path: + common_ancestor: Path | None = None + for path in paths: + if not path.exists(): + continue + if common_ancestor is None: + common_ancestor = path + else: + if common_ancestor in path.parents or path == common_ancestor: + continue + elif path in common_ancestor.parents: + common_ancestor = path + else: + shared = commonpath(path, common_ancestor) + if shared is not None: + common_ancestor = shared + if common_ancestor is None: + common_ancestor = invocation_dir + elif common_ancestor.is_file(): + common_ancestor = common_ancestor.parent + return common_ancestor + + +def get_dirs_from_args(args: Iterable[str]) -> list[Path]: + def is_option(x: str) -> bool: + return x.startswith("-") + + def get_file_part_from_node_id(x: str) -> str: + return x.split("::")[0] + + def get_dir_from_path(path: Path) -> Path: + if path.is_dir(): + return path + return path.parent + + # These look like paths but may not exist + possible_paths = ( + absolutepath(get_file_part_from_node_id(arg)) + for arg in args + if not is_option(arg) + ) + + return [get_dir_from_path(path) for path in possible_paths if safe_exists(path)] + + +def parse_override_ini(override_ini: Sequence[str] | None) -> ConfigDict: + """Parse the -o/--override-ini command line arguments and return the overrides. + + :raises UsageError: + If one of the values is malformed. + """ + overrides = {} + # override_ini is a list of "ini=value" options. + # Always use the last item if multiple values are set for same ini-name, + # e.g. -o foo=bar1 -o foo=bar2 will set foo to bar2. + for ini_config in override_ini or (): + try: + key, user_ini_value = ini_config.split("=", 1) + except ValueError as e: + raise UsageError( + f"-o/--override-ini expects option=value style (got: {ini_config!r})." + ) from e + else: + overrides[key] = ConfigValue(user_ini_value, origin="override", mode="ini") + return overrides + + +CFG_PYTEST_SECTION = "[pytest] section in {filename} files is no longer supported, change to [tool:pytest] instead." + + +def determine_setup( + *, + inifile: str | None, + override_ini: Sequence[str] | None, + args: Sequence[str], + rootdir_cmd_arg: str | None, + invocation_dir: Path, +) -> tuple[Path, Path | None, ConfigDict, Sequence[str]]: + """Determine the rootdir, inifile and ini configuration values from the + command line arguments. + + :param inifile: + The `--inifile` command line argument, if given. + :param override_ini: + The -o/--override-ini command line arguments, if given. + :param args: + The free command line arguments. + :param rootdir_cmd_arg: + The `--rootdir` command line argument, if given. + :param invocation_dir: + The working directory when pytest was invoked. + + :raises UsageError: + """ + rootdir = None + dirs = get_dirs_from_args(args) + ignored_config_files: Sequence[str] = [] + + if inifile: + inipath_ = absolutepath(inifile) + inipath: Path | None = inipath_ + inicfg = load_config_dict_from_file(inipath_) or {} + if rootdir_cmd_arg is None: + rootdir = inipath_.parent + else: + ancestor = get_common_ancestor(invocation_dir, dirs) + rootdir, inipath, inicfg, ignored_config_files = locate_config( + invocation_dir, [ancestor] + ) + if rootdir is None and rootdir_cmd_arg is None: + for possible_rootdir in (ancestor, *ancestor.parents): + if (possible_rootdir / "setup.py").is_file(): + rootdir = possible_rootdir + break + else: + if dirs != [ancestor]: + rootdir, inipath, inicfg, _ = locate_config(invocation_dir, dirs) + if rootdir is None: + rootdir = get_common_ancestor( + invocation_dir, [invocation_dir, ancestor] + ) + if is_fs_root(rootdir): + rootdir = ancestor + if rootdir_cmd_arg: + rootdir = absolutepath(os.path.expandvars(rootdir_cmd_arg)) + if not rootdir.is_dir(): + raise UsageError( + f"Directory '{rootdir}' not found. Check your '--rootdir' option." + ) + + ini_overrides = parse_override_ini(override_ini) + inicfg.update(ini_overrides) + + assert rootdir is not None + return rootdir, inipath, inicfg, ignored_config_files + + +def is_fs_root(p: Path) -> bool: + r""" + Return True if the given path is pointing to the root of the + file system ("/" on Unix and "C:\\" on Windows for example). + """ + return os.path.splitdrive(str(p))[1] == os.sep diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/debugging.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/debugging.py new file mode 100644 index 0000000000000000000000000000000000000000..de1b2688f765a2982dbe10d86bffd9762f2f6512 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/debugging.py @@ -0,0 +1,407 @@ +# mypy: allow-untyped-defs +# ruff: noqa: T100 +"""Interactive debugging with PDB, the Python Debugger.""" + +from __future__ import annotations + +import argparse +from collections.abc import Callable +from collections.abc import Generator +import functools +import sys +import types +from typing import Any +import unittest + +from _pytest import outcomes +from _pytest._code import ExceptionInfo +from _pytest.capture import CaptureManager +from _pytest.config import Config +from _pytest.config import ConftestImportFailure +from _pytest.config import hookimpl +from _pytest.config import PytestPluginManager +from _pytest.config.argparsing import Parser +from _pytest.config.exceptions import UsageError +from _pytest.nodes import Node +from _pytest.reports import BaseReport +from _pytest.runner import CallInfo + + +def _validate_usepdb_cls(value: str) -> tuple[str, str]: + """Validate syntax of --pdbcls option.""" + try: + modname, classname = value.split(":") + except ValueError as e: + raise argparse.ArgumentTypeError( + f"{value!r} is not in the format 'modname:classname'" + ) from e + return (modname, classname) + + +def pytest_addoption(parser: Parser) -> None: + group = parser.getgroup("general") + group.addoption( + "--pdb", + dest="usepdb", + action="store_true", + help="Start the interactive Python debugger on errors or KeyboardInterrupt", + ) + group.addoption( + "--pdbcls", + dest="usepdb_cls", + metavar="modulename:classname", + type=_validate_usepdb_cls, + help="Specify a custom interactive Python debugger for use with --pdb." + "For example: --pdbcls=IPython.terminal.debugger:TerminalPdb", + ) + group.addoption( + "--trace", + dest="trace", + action="store_true", + help="Immediately break when running each test", + ) + + +def pytest_configure(config: Config) -> None: + import pdb + + if config.getvalue("trace"): + config.pluginmanager.register(PdbTrace(), "pdbtrace") + if config.getvalue("usepdb"): + config.pluginmanager.register(PdbInvoke(), "pdbinvoke") + + pytestPDB._saved.append( + (pdb.set_trace, pytestPDB._pluginmanager, pytestPDB._config) + ) + pdb.set_trace = pytestPDB.set_trace + pytestPDB._pluginmanager = config.pluginmanager + pytestPDB._config = config + + # NOTE: not using pytest_unconfigure, since it might get called although + # pytest_configure was not (if another plugin raises UsageError). + def fin() -> None: + ( + pdb.set_trace, + pytestPDB._pluginmanager, + pytestPDB._config, + ) = pytestPDB._saved.pop() + + config.add_cleanup(fin) + + +class pytestPDB: + """Pseudo PDB that defers to the real pdb.""" + + _pluginmanager: PytestPluginManager | None = None + _config: Config | None = None + _saved: list[ + tuple[Callable[..., None], PytestPluginManager | None, Config | None] + ] = [] + _recursive_debug = 0 + _wrapped_pdb_cls: tuple[type[Any], type[Any]] | None = None + + @classmethod + def _is_capturing(cls, capman: CaptureManager | None) -> str | bool: + if capman: + return capman.is_capturing() + return False + + @classmethod + def _import_pdb_cls(cls, capman: CaptureManager | None): + if not cls._config: + import pdb + + # Happens when using pytest.set_trace outside of a test. + return pdb.Pdb + + usepdb_cls = cls._config.getvalue("usepdb_cls") + + if cls._wrapped_pdb_cls and cls._wrapped_pdb_cls[0] == usepdb_cls: + return cls._wrapped_pdb_cls[1] + + if usepdb_cls: + modname, classname = usepdb_cls + + try: + __import__(modname) + mod = sys.modules[modname] + + # Handle --pdbcls=pdb:pdb.Pdb (useful e.g. with pdbpp). + parts = classname.split(".") + pdb_cls = getattr(mod, parts[0]) + for part in parts[1:]: + pdb_cls = getattr(pdb_cls, part) + except Exception as exc: + value = ":".join((modname, classname)) + raise UsageError( + f"--pdbcls: could not import {value!r}: {exc}" + ) from exc + else: + import pdb + + pdb_cls = pdb.Pdb + + wrapped_cls = cls._get_pdb_wrapper_class(pdb_cls, capman) + cls._wrapped_pdb_cls = (usepdb_cls, wrapped_cls) + return wrapped_cls + + @classmethod + def _get_pdb_wrapper_class(cls, pdb_cls, capman: CaptureManager | None): + import _pytest.config + + class PytestPdbWrapper(pdb_cls): + _pytest_capman = capman + _continued = False + + def do_debug(self, arg): + cls._recursive_debug += 1 + ret = super().do_debug(arg) + cls._recursive_debug -= 1 + return ret + + if hasattr(pdb_cls, "do_debug"): + do_debug.__doc__ = pdb_cls.do_debug.__doc__ + + def do_continue(self, arg): + ret = super().do_continue(arg) + if cls._recursive_debug == 0: + assert cls._config is not None + tw = _pytest.config.create_terminal_writer(cls._config) + tw.line() + + capman = self._pytest_capman + capturing = pytestPDB._is_capturing(capman) + if capturing: + if capturing == "global": + tw.sep(">", "PDB continue (IO-capturing resumed)") + else: + tw.sep( + ">", + f"PDB continue (IO-capturing resumed for {capturing})", + ) + assert capman is not None + capman.resume() + else: + tw.sep(">", "PDB continue") + assert cls._pluginmanager is not None + cls._pluginmanager.hook.pytest_leave_pdb(config=cls._config, pdb=self) + self._continued = True + return ret + + if hasattr(pdb_cls, "do_continue"): + do_continue.__doc__ = pdb_cls.do_continue.__doc__ + + do_c = do_cont = do_continue + + def do_quit(self, arg): + # Raise Exit outcome when quit command is used in pdb. + # + # This is a bit of a hack - it would be better if BdbQuit + # could be handled, but this would require to wrap the + # whole pytest run, and adjust the report etc. + ret = super().do_quit(arg) + + if cls._recursive_debug == 0: + outcomes.exit("Quitting debugger") + + return ret + + if hasattr(pdb_cls, "do_quit"): + do_quit.__doc__ = pdb_cls.do_quit.__doc__ + + do_q = do_quit + do_exit = do_quit + + def setup(self, f, tb): + """Suspend on setup(). + + Needed after do_continue resumed, and entering another + breakpoint again. + """ + ret = super().setup(f, tb) + if not ret and self._continued: + # pdb.setup() returns True if the command wants to exit + # from the interaction: do not suspend capturing then. + if self._pytest_capman: + self._pytest_capman.suspend_global_capture(in_=True) + return ret + + def get_stack(self, f, t): + stack, i = super().get_stack(f, t) + if f is None: + # Find last non-hidden frame. + i = max(0, len(stack) - 1) + while i and stack[i][0].f_locals.get("__tracebackhide__", False): + i -= 1 + return stack, i + + return PytestPdbWrapper + + @classmethod + def _init_pdb(cls, method, *args, **kwargs): + """Initialize PDB debugging, dropping any IO capturing.""" + import _pytest.config + + if cls._pluginmanager is None: + capman: CaptureManager | None = None + else: + capman = cls._pluginmanager.getplugin("capturemanager") + if capman: + capman.suspend(in_=True) + + if cls._config: + tw = _pytest.config.create_terminal_writer(cls._config) + tw.line() + + if cls._recursive_debug == 0: + # Handle header similar to pdb.set_trace in py37+. + header = kwargs.pop("header", None) + if header is not None: + tw.sep(">", header) + else: + capturing = cls._is_capturing(capman) + if capturing == "global": + tw.sep(">", f"PDB {method} (IO-capturing turned off)") + elif capturing: + tw.sep( + ">", + f"PDB {method} (IO-capturing turned off for {capturing})", + ) + else: + tw.sep(">", f"PDB {method}") + + _pdb = cls._import_pdb_cls(capman)(**kwargs) + + if cls._pluginmanager: + cls._pluginmanager.hook.pytest_enter_pdb(config=cls._config, pdb=_pdb) + return _pdb + + @classmethod + def set_trace(cls, *args, **kwargs) -> None: + """Invoke debugging via ``Pdb.set_trace``, dropping any IO capturing.""" + frame = sys._getframe().f_back + _pdb = cls._init_pdb("set_trace", *args, **kwargs) + _pdb.set_trace(frame) + + +class PdbInvoke: + def pytest_exception_interact( + self, node: Node, call: CallInfo[Any], report: BaseReport + ) -> None: + capman = node.config.pluginmanager.getplugin("capturemanager") + if capman: + capman.suspend_global_capture(in_=True) + out, err = capman.read_global_capture() + sys.stdout.write(out) + sys.stdout.write(err) + assert call.excinfo is not None + + if not isinstance(call.excinfo.value, unittest.SkipTest): + _enter_pdb(node, call.excinfo, report) + + def pytest_internalerror(self, excinfo: ExceptionInfo[BaseException]) -> None: + exc_or_tb = _postmortem_exc_or_tb(excinfo) + post_mortem(exc_or_tb) + + +class PdbTrace: + @hookimpl(wrapper=True) + def pytest_pyfunc_call(self, pyfuncitem) -> Generator[None, object, object]: + wrap_pytest_function_for_tracing(pyfuncitem) + return (yield) + + +def wrap_pytest_function_for_tracing(pyfuncitem) -> None: + """Change the Python function object of the given Function item by a + wrapper which actually enters pdb before calling the python function + itself, effectively leaving the user in the pdb prompt in the first + statement of the function.""" + _pdb = pytestPDB._init_pdb("runcall") + testfunction = pyfuncitem.obj + + # we can't just return `partial(pdb.runcall, testfunction)` because (on + # python < 3.7.4) runcall's first param is `func`, which means we'd get + # an exception if one of the kwargs to testfunction was called `func`. + @functools.wraps(testfunction) + def wrapper(*args, **kwargs) -> None: + func = functools.partial(testfunction, *args, **kwargs) + _pdb.runcall(func) + + pyfuncitem.obj = wrapper + + +def maybe_wrap_pytest_function_for_tracing(pyfuncitem) -> None: + """Wrap the given pytestfunct item for tracing support if --trace was given in + the command line.""" + if pyfuncitem.config.getvalue("trace"): + wrap_pytest_function_for_tracing(pyfuncitem) + + +def _enter_pdb( + node: Node, excinfo: ExceptionInfo[BaseException], rep: BaseReport +) -> BaseReport: + # XXX we reuse the TerminalReporter's terminalwriter + # because this seems to avoid some encoding related troubles + # for not completely clear reasons. + tw = node.config.pluginmanager.getplugin("terminalreporter")._tw + tw.line() + + showcapture = node.config.option.showcapture + + for sectionname, content in ( + ("stdout", rep.capstdout), + ("stderr", rep.capstderr), + ("log", rep.caplog), + ): + if showcapture in (sectionname, "all") and content: + tw.sep(">", "captured " + sectionname) + if content[-1:] == "\n": + content = content[:-1] + tw.line(content) + + tw.sep(">", "traceback") + rep.toterminal(tw) + tw.sep(">", "entering PDB") + tb_or_exc = _postmortem_exc_or_tb(excinfo) + rep._pdbshown = True # type: ignore[attr-defined] + post_mortem(tb_or_exc) + return rep + + +def _postmortem_exc_or_tb( + excinfo: ExceptionInfo[BaseException], +) -> types.TracebackType | BaseException: + from doctest import UnexpectedException + + get_exc = sys.version_info >= (3, 13) + if isinstance(excinfo.value, UnexpectedException): + # A doctest.UnexpectedException is not useful for post_mortem. + # Use the underlying exception instead: + underlying_exc = excinfo.value + if get_exc: + return underlying_exc.exc_info[1] + + return underlying_exc.exc_info[2] + elif isinstance(excinfo.value, ConftestImportFailure): + # A config.ConftestImportFailure is not useful for post_mortem. + # Use the underlying exception instead: + cause = excinfo.value.cause + if get_exc: + return cause + + assert cause.__traceback__ is not None + return cause.__traceback__ + else: + assert excinfo._excinfo is not None + if get_exc: + return excinfo._excinfo[1] + + return excinfo._excinfo[2] + + +def post_mortem(tb_or_exc: types.TracebackType | BaseException) -> None: + p = pytestPDB._init_pdb("post_mortem") + p.reset() + p.interaction(None, tb_or_exc) + if p.quitting: + outcomes.exit("Quitting debugger") diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/deprecated.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/deprecated.py new file mode 100644 index 0000000000000000000000000000000000000000..cb5d2e93e9347e52c85878b450f630e0a9bb80bd --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/deprecated.py @@ -0,0 +1,99 @@ +"""Deprecation messages and bits of code used elsewhere in the codebase that +is planned to be removed in the next pytest release. + +Keeping it in a central location makes it easy to track what is deprecated and should +be removed when the time comes. + +All constants defined in this module should be either instances of +:class:`PytestWarning`, or :class:`UnformattedWarning` +in case of warnings which need to format their messages. +""" + +from __future__ import annotations + +from warnings import warn + +from _pytest.warning_types import PytestDeprecationWarning +from _pytest.warning_types import PytestRemovedIn9Warning +from _pytest.warning_types import PytestRemovedIn10Warning +from _pytest.warning_types import UnformattedWarning + + +# set of plugins which have been integrated into the core; we use this list to ignore +# them during registration to avoid conflicts +DEPRECATED_EXTERNAL_PLUGINS = { + "pytest_catchlog", + "pytest_capturelog", + "pytest_faulthandler", + "pytest_subtests", +} + + +# This could have been removed pytest 8, but it's harmless and common, so no rush to remove. +YIELD_FIXTURE = PytestDeprecationWarning( + "@pytest.yield_fixture is deprecated.\n" + "Use @pytest.fixture instead; they are the same." +) + +# This deprecation is never really meant to be removed. +PRIVATE = PytestDeprecationWarning("A private pytest class or function was used.") + + +HOOK_LEGACY_PATH_ARG = UnformattedWarning( + PytestRemovedIn9Warning, + "The ({pylib_path_arg}: py.path.local) argument is deprecated, please use ({pathlib_path_arg}: pathlib.Path)\n" + "see https://docs.pytest.org/en/latest/deprecations.html" + "#py-path-local-arguments-for-hooks-replaced-with-pathlib-path", +) + +NODE_CTOR_FSPATH_ARG = UnformattedWarning( + PytestRemovedIn9Warning, + "The (fspath: py.path.local) argument to {node_type_name} is deprecated. " + "Please use the (path: pathlib.Path) argument instead.\n" + "See https://docs.pytest.org/en/latest/deprecations.html" + "#fspath-argument-for-node-constructors-replaced-with-pathlib-path", +) + +HOOK_LEGACY_MARKING = UnformattedWarning( + PytestDeprecationWarning, + "The hook{type} {fullname} uses old-style configuration options (marks or attributes).\n" + "Please use the pytest.hook{type}({hook_opts}) decorator instead\n" + " to configure the hooks.\n" + " See https://docs.pytest.org/en/latest/deprecations.html" + "#configuring-hook-specs-impls-using-markers", +) + +MARKED_FIXTURE = PytestRemovedIn9Warning( + "Marks applied to fixtures have no effect\n" + "See docs: https://docs.pytest.org/en/stable/deprecations.html#applying-a-mark-to-a-fixture-function" +) + +MONKEYPATCH_LEGACY_NAMESPACE_PACKAGES = PytestRemovedIn10Warning( + "monkeypatch.syspath_prepend() called with pkg_resources legacy namespace packages detected.\n" + "Legacy namespace packages (using pkg_resources.declare_namespace) are deprecated.\n" + "Please use native namespace packages (PEP 420) instead.\n" + "See https://docs.pytest.org/en/stable/deprecations.html#monkeypatch-fixup-namespace-packages" +) + +# You want to make some `__init__` or function "private". +# +# def my_private_function(some, args): +# ... +# +# Do this: +# +# def my_private_function(some, args, *, _ispytest: bool = False): +# check_ispytest(_ispytest) +# ... +# +# Change all internal/allowed calls to +# +# my_private_function(some, args, _ispytest=True) +# +# All other calls will get the default _ispytest=False and trigger +# the warning (possibly error in the future). + + +def check_ispytest(ispytest: bool) -> None: + if not ispytest: + warn(PRIVATE, stacklevel=3) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/doctest.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/doctest.py new file mode 100644 index 0000000000000000000000000000000000000000..cd255f5eeb6ec1e3506037e3a569a60d777bba8a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/doctest.py @@ -0,0 +1,736 @@ +# mypy: allow-untyped-defs +"""Discover and run doctests in modules and test files.""" + +from __future__ import annotations + +import bdb +from collections.abc import Callable +from collections.abc import Generator +from collections.abc import Iterable +from collections.abc import Sequence +from contextlib import contextmanager +import functools +import inspect +import os +from pathlib import Path +import platform +import re +import sys +import traceback +import types +from typing import Any +from typing import TYPE_CHECKING +import warnings + +from _pytest import outcomes +from _pytest._code.code import ExceptionInfo +from _pytest._code.code import ReprFileLocation +from _pytest._code.code import TerminalRepr +from _pytest._io import TerminalWriter +from _pytest.compat import safe_getattr +from _pytest.config import Config +from _pytest.config.argparsing import Parser +from _pytest.fixtures import fixture +from _pytest.fixtures import TopRequest +from _pytest.nodes import Collector +from _pytest.nodes import Item +from _pytest.outcomes import OutcomeException +from _pytest.outcomes import skip +from _pytest.pathlib import fnmatch_ex +from _pytest.python import Module +from _pytest.python_api import approx +from _pytest.warning_types import PytestWarning + + +if TYPE_CHECKING: + import doctest + + from typing_extensions import Self + +DOCTEST_REPORT_CHOICE_NONE = "none" +DOCTEST_REPORT_CHOICE_CDIFF = "cdiff" +DOCTEST_REPORT_CHOICE_NDIFF = "ndiff" +DOCTEST_REPORT_CHOICE_UDIFF = "udiff" +DOCTEST_REPORT_CHOICE_ONLY_FIRST_FAILURE = "only_first_failure" + +DOCTEST_REPORT_CHOICES = ( + DOCTEST_REPORT_CHOICE_NONE, + DOCTEST_REPORT_CHOICE_CDIFF, + DOCTEST_REPORT_CHOICE_NDIFF, + DOCTEST_REPORT_CHOICE_UDIFF, + DOCTEST_REPORT_CHOICE_ONLY_FIRST_FAILURE, +) + +# Lazy definition of runner class +RUNNER_CLASS = None +# Lazy definition of output checker class +CHECKER_CLASS: type[doctest.OutputChecker] | None = None + + +def pytest_addoption(parser: Parser) -> None: + parser.addini( + "doctest_optionflags", + "Option flags for doctests", + type="args", + default=["ELLIPSIS"], + ) + parser.addini( + "doctest_encoding", "Encoding used for doctest files", default="utf-8" + ) + group = parser.getgroup("collect") + group.addoption( + "--doctest-modules", + action="store_true", + default=False, + help="Run doctests in all .py modules", + dest="doctestmodules", + ) + group.addoption( + "--doctest-report", + type=str.lower, + default="udiff", + help="Choose another output format for diffs on doctest failure", + choices=DOCTEST_REPORT_CHOICES, + dest="doctestreport", + ) + group.addoption( + "--doctest-glob", + action="append", + default=[], + metavar="pat", + help="Doctests file matching pattern, default: test*.txt", + dest="doctestglob", + ) + group.addoption( + "--doctest-ignore-import-errors", + action="store_true", + default=False, + help="Ignore doctest collection errors", + dest="doctest_ignore_import_errors", + ) + group.addoption( + "--doctest-continue-on-failure", + action="store_true", + default=False, + help="For a given doctest, continue to run after the first failure", + dest="doctest_continue_on_failure", + ) + + +def pytest_unconfigure() -> None: + global RUNNER_CLASS + + RUNNER_CLASS = None + + +def pytest_collect_file( + file_path: Path, + parent: Collector, +) -> DoctestModule | DoctestTextfile | None: + config = parent.config + if file_path.suffix == ".py": + if config.option.doctestmodules and not any( + (_is_setup_py(file_path), _is_main_py(file_path)) + ): + return DoctestModule.from_parent(parent, path=file_path) + elif _is_doctest(config, file_path, parent): + return DoctestTextfile.from_parent(parent, path=file_path) + return None + + +def _is_setup_py(path: Path) -> bool: + if path.name != "setup.py": + return False + contents = path.read_bytes() + return b"setuptools" in contents or b"distutils" in contents + + +def _is_doctest(config: Config, path: Path, parent: Collector) -> bool: + if path.suffix in (".txt", ".rst") and parent.session.isinitpath(path): + return True + globs = config.getoption("doctestglob") or ["test*.txt"] + return any(fnmatch_ex(glob, path) for glob in globs) + + +def _is_main_py(path: Path) -> bool: + return path.name == "__main__.py" + + +class ReprFailDoctest(TerminalRepr): + def __init__( + self, reprlocation_lines: Sequence[tuple[ReprFileLocation, Sequence[str]]] + ) -> None: + self.reprlocation_lines = reprlocation_lines + + def toterminal(self, tw: TerminalWriter) -> None: + for reprlocation, lines in self.reprlocation_lines: + for line in lines: + tw.line(line) + reprlocation.toterminal(tw) + + +class MultipleDoctestFailures(Exception): + def __init__(self, failures: Sequence[doctest.DocTestFailure]) -> None: + super().__init__() + self.failures = failures + + +def _init_runner_class() -> type[doctest.DocTestRunner]: + import doctest + + class PytestDoctestRunner(doctest.DebugRunner): + """Runner to collect failures. + + Note that the out variable in this case is a list instead of a + stdout-like object. + """ + + def __init__( + self, + checker: doctest.OutputChecker | None = None, + verbose: bool | None = None, + optionflags: int = 0, + continue_on_failure: bool = True, + ) -> None: + super().__init__(checker=checker, verbose=verbose, optionflags=optionflags) + self.continue_on_failure = continue_on_failure + + def report_failure( + self, + out, + test: doctest.DocTest, + example: doctest.Example, + got: str, + ) -> None: + failure = doctest.DocTestFailure(test, example, got) + if self.continue_on_failure: + out.append(failure) + else: + raise failure + + def report_unexpected_exception( + self, + out, + test: doctest.DocTest, + example: doctest.Example, + exc_info: tuple[type[BaseException], BaseException, types.TracebackType], + ) -> None: + if isinstance(exc_info[1], OutcomeException): + raise exc_info[1] + if isinstance(exc_info[1], bdb.BdbQuit): + outcomes.exit("Quitting debugger") + failure = doctest.UnexpectedException(test, example, exc_info) + if self.continue_on_failure: + out.append(failure) + else: + raise failure + + return PytestDoctestRunner + + +def _get_runner( + checker: doctest.OutputChecker | None = None, + verbose: bool | None = None, + optionflags: int = 0, + continue_on_failure: bool = True, +) -> doctest.DocTestRunner: + # We need this in order to do a lazy import on doctest + global RUNNER_CLASS + if RUNNER_CLASS is None: + RUNNER_CLASS = _init_runner_class() + # Type ignored because the continue_on_failure argument is only defined on + # PytestDoctestRunner, which is lazily defined so can't be used as a type. + return RUNNER_CLASS( # type: ignore + checker=checker, + verbose=verbose, + optionflags=optionflags, + continue_on_failure=continue_on_failure, + ) + + +class DoctestItem(Item): + def __init__( + self, + name: str, + parent: DoctestTextfile | DoctestModule, + runner: doctest.DocTestRunner, + dtest: doctest.DocTest, + ) -> None: + super().__init__(name, parent) + self.runner = runner + self.dtest = dtest + + # Stuff needed for fixture support. + self.obj = None + fm = self.session._fixturemanager + fixtureinfo = fm.getfixtureinfo(node=self, func=None, cls=None) + self._fixtureinfo = fixtureinfo + self.fixturenames = fixtureinfo.names_closure + self._initrequest() + + @classmethod + def from_parent( # type: ignore[override] + cls, + parent: DoctestTextfile | DoctestModule, + *, + name: str, + runner: doctest.DocTestRunner, + dtest: doctest.DocTest, + ) -> Self: + # incompatible signature due to imposed limits on subclass + """The public named constructor.""" + return super().from_parent(name=name, parent=parent, runner=runner, dtest=dtest) + + def _initrequest(self) -> None: + self.funcargs: dict[str, object] = {} + self._request = TopRequest(self, _ispytest=True) # type: ignore[arg-type] + + def setup(self) -> None: + self._request._fillfixtures() + globs = dict(getfixture=self._request.getfixturevalue) + for name, value in self._request.getfixturevalue("doctest_namespace").items(): + globs[name] = value + self.dtest.globs.update(globs) + + def runtest(self) -> None: + _check_all_skipped(self.dtest) + self._disable_output_capturing_for_darwin() + failures: list[doctest.DocTestFailure] = [] + # Type ignored because we change the type of `out` from what + # doctest expects. + self.runner.run(self.dtest, out=failures) # type: ignore[arg-type] + if failures: + raise MultipleDoctestFailures(failures) + + def _disable_output_capturing_for_darwin(self) -> None: + """Disable output capturing. Otherwise, stdout is lost to doctest (#985).""" + if platform.system() != "Darwin": + return + capman = self.config.pluginmanager.getplugin("capturemanager") + if capman: + capman.suspend_global_capture(in_=True) + out, err = capman.read_global_capture() + sys.stdout.write(out) + sys.stderr.write(err) + + # TODO: Type ignored -- breaks Liskov Substitution. + def repr_failure( # type: ignore[override] + self, + excinfo: ExceptionInfo[BaseException], + ) -> str | TerminalRepr: + import doctest + + failures: ( + Sequence[doctest.DocTestFailure | doctest.UnexpectedException] | None + ) = None + if isinstance( + excinfo.value, doctest.DocTestFailure | doctest.UnexpectedException + ): + failures = [excinfo.value] + elif isinstance(excinfo.value, MultipleDoctestFailures): + failures = excinfo.value.failures + + if failures is None: + return super().repr_failure(excinfo) + + reprlocation_lines = [] + for failure in failures: + example = failure.example + test = failure.test + filename = test.filename + if test.lineno is None: + lineno = None + else: + lineno = test.lineno + example.lineno + 1 + message = type(failure).__name__ + # TODO: ReprFileLocation doesn't expect a None lineno. + reprlocation = ReprFileLocation(filename, lineno, message) # type: ignore[arg-type] + checker = _get_checker() + report_choice = _get_report_choice(self.config.getoption("doctestreport")) + if lineno is not None: + assert failure.test.docstring is not None + lines = failure.test.docstring.splitlines(False) + # add line numbers to the left of the error message + assert test.lineno is not None + lines = [ + f"{i + test.lineno + 1:03d} {x}" for (i, x) in enumerate(lines) + ] + # trim docstring error lines to 10 + lines = lines[max(example.lineno - 9, 0) : example.lineno + 1] + else: + lines = [ + "EXAMPLE LOCATION UNKNOWN, not showing all tests of that example" + ] + indent = ">>>" + for line in example.source.splitlines(): + lines.append(f"??? {indent} {line}") + indent = "..." + if isinstance(failure, doctest.DocTestFailure): + lines += checker.output_difference( + example, failure.got, report_choice + ).split("\n") + else: + inner_excinfo = ExceptionInfo.from_exc_info(failure.exc_info) + lines += [f"UNEXPECTED EXCEPTION: {inner_excinfo.value!r}"] + lines += [ + x.strip("\n") for x in traceback.format_exception(*failure.exc_info) + ] + reprlocation_lines.append((reprlocation, lines)) + return ReprFailDoctest(reprlocation_lines) + + def reportinfo(self) -> tuple[os.PathLike[str] | str, int | None, str]: + return self.path, self.dtest.lineno, f"[doctest] {self.name}" + + +def _get_flag_lookup() -> dict[str, int]: + import doctest + + return dict( + DONT_ACCEPT_TRUE_FOR_1=doctest.DONT_ACCEPT_TRUE_FOR_1, + DONT_ACCEPT_BLANKLINE=doctest.DONT_ACCEPT_BLANKLINE, + NORMALIZE_WHITESPACE=doctest.NORMALIZE_WHITESPACE, + ELLIPSIS=doctest.ELLIPSIS, + IGNORE_EXCEPTION_DETAIL=doctest.IGNORE_EXCEPTION_DETAIL, + COMPARISON_FLAGS=doctest.COMPARISON_FLAGS, + ALLOW_UNICODE=_get_allow_unicode_flag(), + ALLOW_BYTES=_get_allow_bytes_flag(), + NUMBER=_get_number_flag(), + ) + + +def get_optionflags(config: Config) -> int: + optionflags_str = config.getini("doctest_optionflags") + flag_lookup_table = _get_flag_lookup() + flag_acc = 0 + for flag in optionflags_str: + flag_acc |= flag_lookup_table[flag] + return flag_acc + + +def _get_continue_on_failure(config: Config) -> bool: + continue_on_failure: bool = config.getvalue("doctest_continue_on_failure") + if continue_on_failure: + # We need to turn off this if we use pdb since we should stop at + # the first failure. + if config.getvalue("usepdb"): + continue_on_failure = False + return continue_on_failure + + +class DoctestTextfile(Module): + obj = None + + def collect(self) -> Iterable[DoctestItem]: + import doctest + + # Inspired by doctest.testfile; ideally we would use it directly, + # but it doesn't support passing a custom checker. + encoding = self.config.getini("doctest_encoding") + text = self.path.read_text(encoding) + filename = str(self.path) + name = self.path.name + globs = {"__name__": "__main__"} + + optionflags = get_optionflags(self.config) + + runner = _get_runner( + verbose=False, + optionflags=optionflags, + checker=_get_checker(), + continue_on_failure=_get_continue_on_failure(self.config), + ) + + parser = doctest.DocTestParser() + test = parser.get_doctest(text, globs, name, filename, 0) + if test.examples: + yield DoctestItem.from_parent( + self, name=test.name, runner=runner, dtest=test + ) + + +def _check_all_skipped(test: doctest.DocTest) -> None: + """Raise pytest.skip() if all examples in the given DocTest have the SKIP + option set.""" + import doctest + + all_skipped = all(x.options.get(doctest.SKIP, False) for x in test.examples) + if all_skipped: + skip("all tests skipped by +SKIP option") + + +def _is_mocked(obj: object) -> bool: + """Return if an object is possibly a mock object by checking the + existence of a highly improbable attribute.""" + return ( + safe_getattr(obj, "pytest_mock_example_attribute_that_shouldnt_exist", None) + is not None + ) + + +@contextmanager +def _patch_unwrap_mock_aware() -> Generator[None]: + """Context manager which replaces ``inspect.unwrap`` with a version + that's aware of mock objects and doesn't recurse into them.""" + real_unwrap = inspect.unwrap + + def _mock_aware_unwrap( + func: Callable[..., Any], *, stop: Callable[[Any], Any] | None = None + ) -> Any: + try: + if stop is None or stop is _is_mocked: + return real_unwrap(func, stop=_is_mocked) + _stop = stop + return real_unwrap(func, stop=lambda obj: _is_mocked(obj) or _stop(func)) + except Exception as e: + warnings.warn( + f"Got {e!r} when unwrapping {func!r}. This is usually caused " + "by a violation of Python's object protocol; see e.g. " + "https://github.com/pytest-dev/pytest/issues/5080", + PytestWarning, + ) + raise + + inspect.unwrap = _mock_aware_unwrap + try: + yield + finally: + inspect.unwrap = real_unwrap + + +class DoctestModule(Module): + def collect(self) -> Iterable[DoctestItem]: + import doctest + + class MockAwareDocTestFinder(doctest.DocTestFinder): + py_ver_info_minor = sys.version_info[:2] + is_find_lineno_broken = ( + py_ver_info_minor < (3, 11) + or (py_ver_info_minor == (3, 11) and sys.version_info.micro < 9) + or (py_ver_info_minor == (3, 12) and sys.version_info.micro < 3) + ) + if is_find_lineno_broken: + + def _find_lineno(self, obj, source_lines): + """On older Pythons, doctest code does not take into account + `@property`. https://github.com/python/cpython/issues/61648 + + Moreover, wrapped Doctests need to be unwrapped so the correct + line number is returned. #8796 + """ + if isinstance(obj, property): + obj = getattr(obj, "fget", obj) + + if hasattr(obj, "__wrapped__"): + # Get the main obj in case of it being wrapped + obj = inspect.unwrap(obj) + + # Type ignored because this is a private function. + return super()._find_lineno( # type:ignore[misc] + obj, + source_lines, + ) + + if sys.version_info < (3, 13): + + def _from_module(self, module, object): + """`cached_property` objects are never considered a part + of the 'current module'. As such they are skipped by doctest. + Here we override `_from_module` to check the underlying + function instead. https://github.com/python/cpython/issues/107995 + """ + if isinstance(object, functools.cached_property): + object = object.func + + # Type ignored because this is a private function. + return super()._from_module(module, object) # type: ignore[misc] + + try: + module = self.obj + except Collector.CollectError: + if self.config.getvalue("doctest_ignore_import_errors"): + skip(f"unable to import module {self.path!r}") + else: + raise + + # While doctests currently don't support fixtures directly, we still + # need to pick up autouse fixtures. + self.session._fixturemanager.parsefactories(self) + + # Uses internal doctest module parsing mechanism. + finder = MockAwareDocTestFinder() + optionflags = get_optionflags(self.config) + runner = _get_runner( + verbose=False, + optionflags=optionflags, + checker=_get_checker(), + continue_on_failure=_get_continue_on_failure(self.config), + ) + + for test in finder.find(module, module.__name__): + if test.examples: # skip empty doctests + yield DoctestItem.from_parent( + self, name=test.name, runner=runner, dtest=test + ) + + +def _init_checker_class() -> type[doctest.OutputChecker]: + import doctest + + class LiteralsOutputChecker(doctest.OutputChecker): + # Based on doctest_nose_plugin.py from the nltk project + # (https://github.com/nltk/nltk) and on the "numtest" doctest extension + # by Sebastien Boisgerault (https://github.com/boisgera/numtest). + + _unicode_literal_re = re.compile(r"(\W|^)[uU]([rR]?[\'\"])", re.UNICODE) + _bytes_literal_re = re.compile(r"(\W|^)[bB]([rR]?[\'\"])", re.UNICODE) + _number_re = re.compile( + r""" + (?P<number> + (?P<mantissa> + (?P<integer1> [+-]?\d*)\.(?P<fraction>\d+) + | + (?P<integer2> [+-]?\d+)\. + ) + (?: + [Ee] + (?P<exponent1> [+-]?\d+) + )? + | + (?P<integer3> [+-]?\d+) + (?: + [Ee] + (?P<exponent2> [+-]?\d+) + ) + ) + """, + re.VERBOSE, + ) + + def check_output(self, want: str, got: str, optionflags: int) -> bool: + if super().check_output(want, got, optionflags): + return True + + allow_unicode = optionflags & _get_allow_unicode_flag() + allow_bytes = optionflags & _get_allow_bytes_flag() + allow_number = optionflags & _get_number_flag() + + if not allow_unicode and not allow_bytes and not allow_number: + return False + + def remove_prefixes(regex: re.Pattern[str], txt: str) -> str: + return re.sub(regex, r"\1\2", txt) + + if allow_unicode: + want = remove_prefixes(self._unicode_literal_re, want) + got = remove_prefixes(self._unicode_literal_re, got) + + if allow_bytes: + want = remove_prefixes(self._bytes_literal_re, want) + got = remove_prefixes(self._bytes_literal_re, got) + + if allow_number: + got = self._remove_unwanted_precision(want, got) + + return super().check_output(want, got, optionflags) + + def _remove_unwanted_precision(self, want: str, got: str) -> str: + wants = list(self._number_re.finditer(want)) + gots = list(self._number_re.finditer(got)) + if len(wants) != len(gots): + return got + offset = 0 + for w, g in zip(wants, gots, strict=True): + fraction: str | None = w.group("fraction") + exponent: str | None = w.group("exponent1") + if exponent is None: + exponent = w.group("exponent2") + precision = 0 if fraction is None else len(fraction) + if exponent is not None: + precision -= int(exponent) + if float(w.group()) == approx(float(g.group()), abs=10**-precision): + # They're close enough. Replace the text we actually + # got with the text we want, so that it will match when we + # check the string literally. + got = ( + got[: g.start() + offset] + w.group() + got[g.end() + offset :] + ) + offset += w.end() - w.start() - (g.end() - g.start()) + return got + + return LiteralsOutputChecker + + +def _get_checker() -> doctest.OutputChecker: + """Return a doctest.OutputChecker subclass that supports some + additional options: + + * ALLOW_UNICODE and ALLOW_BYTES options to ignore u'' and b'' + prefixes (respectively) in string literals. Useful when the same + doctest should run in Python 2 and Python 3. + + * NUMBER to ignore floating-point differences smaller than the + precision of the literal number in the doctest. + + An inner class is used to avoid importing "doctest" at the module + level. + """ + global CHECKER_CLASS + if CHECKER_CLASS is None: + CHECKER_CLASS = _init_checker_class() + return CHECKER_CLASS() + + +def _get_allow_unicode_flag() -> int: + """Register and return the ALLOW_UNICODE flag.""" + import doctest + + return doctest.register_optionflag("ALLOW_UNICODE") + + +def _get_allow_bytes_flag() -> int: + """Register and return the ALLOW_BYTES flag.""" + import doctest + + return doctest.register_optionflag("ALLOW_BYTES") + + +def _get_number_flag() -> int: + """Register and return the NUMBER flag.""" + import doctest + + return doctest.register_optionflag("NUMBER") + + +def _get_report_choice(key: str) -> int: + """Return the actual `doctest` module flag value. + + We want to do it as late as possible to avoid importing `doctest` and all + its dependencies when parsing options, as it adds overhead and breaks tests. + """ + import doctest + + return { + DOCTEST_REPORT_CHOICE_UDIFF: doctest.REPORT_UDIFF, + DOCTEST_REPORT_CHOICE_CDIFF: doctest.REPORT_CDIFF, + DOCTEST_REPORT_CHOICE_NDIFF: doctest.REPORT_NDIFF, + DOCTEST_REPORT_CHOICE_ONLY_FIRST_FAILURE: doctest.REPORT_ONLY_FIRST_FAILURE, + DOCTEST_REPORT_CHOICE_NONE: 0, + }[key] + + +@fixture(scope="session") +def doctest_namespace() -> dict[str, Any]: + """Fixture that returns a :py:class:`dict` that will be injected into the + namespace of doctests. + + Usually this fixture is used in conjunction with another ``autouse`` fixture: + + .. code-block:: python + + @pytest.fixture(autouse=True) + def add_np(doctest_namespace): + doctest_namespace["np"] = numpy + + For more details: :ref:`doctest_namespace`. + """ + return dict() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/faulthandler.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/faulthandler.py new file mode 100644 index 0000000000000000000000000000000000000000..080cf583813bf17efb7244e74711db30723af333 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/faulthandler.py @@ -0,0 +1,119 @@ +from __future__ import annotations + +from collections.abc import Generator +import os +import sys + +from _pytest.config import Config +from _pytest.config.argparsing import Parser +from _pytest.nodes import Item +from _pytest.stash import StashKey +import pytest + + +fault_handler_original_stderr_fd_key = StashKey[int]() +fault_handler_stderr_fd_key = StashKey[int]() + + +def pytest_addoption(parser: Parser) -> None: + help_timeout = ( + "Dump the traceback of all threads if a test takes " + "more than TIMEOUT seconds to finish" + ) + help_exit_on_timeout = ( + "Exit the test process if a test takes more than " + "faulthandler_timeout seconds to finish" + ) + parser.addini("faulthandler_timeout", help_timeout, default=0.0) + parser.addini( + "faulthandler_exit_on_timeout", help_exit_on_timeout, type="bool", default=False + ) + + +def pytest_configure(config: Config) -> None: + import faulthandler + + # at teardown we want to restore the original faulthandler fileno + # but faulthandler has no api to return the original fileno + # so here we stash the stderr fileno to be used at teardown + # sys.stderr and sys.__stderr__ may be closed or patched during the session + # so we can't rely on their values being good at that point (#11572). + stderr_fileno = get_stderr_fileno() + if faulthandler.is_enabled(): + config.stash[fault_handler_original_stderr_fd_key] = stderr_fileno + config.stash[fault_handler_stderr_fd_key] = os.dup(stderr_fileno) + faulthandler.enable(file=config.stash[fault_handler_stderr_fd_key]) + + +def pytest_unconfigure(config: Config) -> None: + import faulthandler + + faulthandler.disable() + # Close the dup file installed during pytest_configure. + if fault_handler_stderr_fd_key in config.stash: + os.close(config.stash[fault_handler_stderr_fd_key]) + del config.stash[fault_handler_stderr_fd_key] + # Re-enable the faulthandler if it was originally enabled. + if fault_handler_original_stderr_fd_key in config.stash: + faulthandler.enable(config.stash[fault_handler_original_stderr_fd_key]) + del config.stash[fault_handler_original_stderr_fd_key] + + +def get_stderr_fileno() -> int: + try: + fileno = sys.stderr.fileno() + # The Twisted Logger will return an invalid file descriptor since it is not backed + # by an FD. So, let's also forward this to the same code path as with pytest-xdist. + if fileno == -1: + raise AttributeError() + return fileno + except (AttributeError, ValueError): + # pytest-xdist monkeypatches sys.stderr with an object that is not an actual file. + # https://docs.python.org/3/library/faulthandler.html#issue-with-file-descriptors + # This is potentially dangerous, but the best we can do. + assert sys.__stderr__ is not None + return sys.__stderr__.fileno() + + +def get_timeout_config_value(config: Config) -> float: + return float(config.getini("faulthandler_timeout") or 0.0) + + +def get_exit_on_timeout_config_value(config: Config) -> bool: + exit_on_timeout = config.getini("faulthandler_exit_on_timeout") + assert isinstance(exit_on_timeout, bool) + return exit_on_timeout + + +@pytest.hookimpl(wrapper=True, trylast=True) +def pytest_runtest_protocol(item: Item) -> Generator[None, object, object]: + timeout = get_timeout_config_value(item.config) + exit_on_timeout = get_exit_on_timeout_config_value(item.config) + if timeout > 0: + import faulthandler + + stderr = item.config.stash[fault_handler_stderr_fd_key] + faulthandler.dump_traceback_later(timeout, file=stderr, exit=exit_on_timeout) + try: + return (yield) + finally: + faulthandler.cancel_dump_traceback_later() + else: + return (yield) + + +@pytest.hookimpl(tryfirst=True) +def pytest_enter_pdb() -> None: + """Cancel any traceback dumping due to timeout before entering pdb.""" + import faulthandler + + faulthandler.cancel_dump_traceback_later() + + +@pytest.hookimpl(tryfirst=True) +def pytest_exception_interact() -> None: + """Cancel any traceback dumping due to an interactive exception being + raised.""" + import faulthandler + + faulthandler.cancel_dump_traceback_later() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/fixtures.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/fixtures.py new file mode 100644 index 0000000000000000000000000000000000000000..27846db13a472a665105ebb6db1e20b683f30f93 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/fixtures.py @@ -0,0 +1,2047 @@ +# mypy: allow-untyped-defs +from __future__ import annotations + +import abc +from collections import defaultdict +from collections import deque +from collections import OrderedDict +from collections.abc import Callable +from collections.abc import Generator +from collections.abc import Iterable +from collections.abc import Iterator +from collections.abc import Mapping +from collections.abc import MutableMapping +from collections.abc import Sequence +from collections.abc import Set as AbstractSet +import dataclasses +import functools +import inspect +import os +from pathlib import Path +import sys +import types +from typing import Any +from typing import cast +from typing import Final +from typing import final +from typing import Generic +from typing import NoReturn +from typing import overload +from typing import TYPE_CHECKING +from typing import TypeVar +import warnings + +import _pytest +from _pytest import nodes +from _pytest._code import getfslineno +from _pytest._code import Source +from _pytest._code.code import FormattedExcinfo +from _pytest._code.code import TerminalRepr +from _pytest._io import TerminalWriter +from _pytest.compat import assert_never +from _pytest.compat import get_real_func +from _pytest.compat import getfuncargnames +from _pytest.compat import getimfunc +from _pytest.compat import getlocation +from _pytest.compat import NOTSET +from _pytest.compat import NotSetType +from _pytest.compat import safe_getattr +from _pytest.compat import safe_isclass +from _pytest.compat import signature +from _pytest.config import _PluggyPlugin +from _pytest.config import Config +from _pytest.config import ExitCode +from _pytest.config.argparsing import Parser +from _pytest.deprecated import check_ispytest +from _pytest.deprecated import MARKED_FIXTURE +from _pytest.deprecated import YIELD_FIXTURE +from _pytest.main import Session +from _pytest.mark import Mark +from _pytest.mark import ParameterSet +from _pytest.mark.structures import MarkDecorator +from _pytest.outcomes import fail +from _pytest.outcomes import skip +from _pytest.outcomes import TEST_OUTCOME +from _pytest.pathlib import absolutepath +from _pytest.pathlib import bestrelpath +from _pytest.scope import _ScopeName +from _pytest.scope import HIGH_SCOPES +from _pytest.scope import Scope +from _pytest.warning_types import PytestRemovedIn9Warning +from _pytest.warning_types import PytestWarning + + +if sys.version_info < (3, 11): + from exceptiongroup import BaseExceptionGroup + + +if TYPE_CHECKING: + from _pytest.python import CallSpec2 + from _pytest.python import Function + from _pytest.python import Metafunc + + +# The value of the fixture -- return/yield of the fixture function (type variable). +FixtureValue = TypeVar("FixtureValue", covariant=True) +# The type of the fixture function (type variable). +FixtureFunction = TypeVar("FixtureFunction", bound=Callable[..., object]) +# The type of a fixture function (type alias generic in fixture value). +_FixtureFunc = Callable[..., FixtureValue] | Callable[..., Generator[FixtureValue]] +# The type of FixtureDef.cached_result (type alias generic in fixture value). +_FixtureCachedResult = ( + tuple[ + # The result. + FixtureValue, + # Cache key. + object, + None, + ] + | tuple[ + None, + # Cache key. + object, + # The exception and the original traceback. + tuple[BaseException, types.TracebackType | None], + ] +) + + +def pytest_sessionstart(session: Session) -> None: + session._fixturemanager = FixtureManager(session) + + +def get_scope_package( + node: nodes.Item, + fixturedef: FixtureDef[object], +) -> nodes.Node | None: + from _pytest.python import Package + + for parent in node.iter_parents(): + if isinstance(parent, Package) and parent.nodeid == fixturedef.baseid: + return parent + return node.session + + +def get_scope_node(node: nodes.Node, scope: Scope) -> nodes.Node | None: + """Get the closest parent node (including self) which matches the given + scope. + + If there is no parent node for the scope (e.g. asking for class scope on a + Module, or on a Function when not defined in a class), returns None. + """ + import _pytest.python + + if scope is Scope.Function: + # Type ignored because this is actually safe, see: + # https://github.com/python/mypy/issues/4717 + return node.getparent(nodes.Item) # type: ignore[type-abstract] + elif scope is Scope.Class: + return node.getparent(_pytest.python.Class) + elif scope is Scope.Module: + return node.getparent(_pytest.python.Module) + elif scope is Scope.Package: + return node.getparent(_pytest.python.Package) + elif scope is Scope.Session: + return node.getparent(_pytest.main.Session) + else: + assert_never(scope) + + +# TODO: Try to use FixtureFunctionDefinition instead of the marker +def getfixturemarker(obj: object) -> FixtureFunctionMarker | None: + """Return fixturemarker or None if it doesn't exist""" + if isinstance(obj, FixtureFunctionDefinition): + return obj._fixture_function_marker + return None + + +# Algorithm for sorting on a per-parametrized resource setup basis. +# It is called for Session scope first and performs sorting +# down to the lower scopes such as to minimize number of "high scope" +# setups and teardowns. + + +@dataclasses.dataclass(frozen=True) +class ParamArgKey: + """A key for a high-scoped parameter used by an item. + + For use as a hashable key in `reorder_items`. The combination of fields + is meant to uniquely identify a particular "instance" of a param, + potentially shared by multiple items in a scope. + """ + + #: The param name. + argname: str + param_index: int + #: For scopes Package, Module, Class, the path to the file (directory in + #: Package's case) of the package/module/class where the item is defined. + scoped_item_path: Path | None + #: For Class scope, the class where the item is defined. + item_cls: type | None + + +_V = TypeVar("_V") +OrderedSet = dict[_V, None] + + +def get_param_argkeys(item: nodes.Item, scope: Scope) -> Iterator[ParamArgKey]: + """Return all ParamArgKeys for item matching the specified high scope.""" + assert scope is not Scope.Function + + try: + callspec: CallSpec2 = item.callspec # type: ignore[attr-defined] + except AttributeError: + return + + item_cls = None + if scope is Scope.Session: + scoped_item_path = None + elif scope is Scope.Package: + # Package key = module's directory. + scoped_item_path = item.path.parent + elif scope is Scope.Module: + scoped_item_path = item.path + elif scope is Scope.Class: + scoped_item_path = item.path + item_cls = item.cls # type: ignore[attr-defined] + else: + assert_never(scope) + + for argname in callspec.indices: + if callspec._arg2scope[argname] != scope: + continue + param_index = callspec.indices[argname] + yield ParamArgKey(argname, param_index, scoped_item_path, item_cls) + + +def reorder_items(items: Sequence[nodes.Item]) -> list[nodes.Item]: + argkeys_by_item: dict[Scope, dict[nodes.Item, OrderedSet[ParamArgKey]]] = {} + items_by_argkey: dict[Scope, dict[ParamArgKey, OrderedDict[nodes.Item, None]]] = {} + for scope in HIGH_SCOPES: + scoped_argkeys_by_item = argkeys_by_item[scope] = {} + scoped_items_by_argkey = items_by_argkey[scope] = defaultdict(OrderedDict) + for item in items: + argkeys = dict.fromkeys(get_param_argkeys(item, scope)) + if argkeys: + scoped_argkeys_by_item[item] = argkeys + for argkey in argkeys: + scoped_items_by_argkey[argkey][item] = None + + items_set = dict.fromkeys(items) + return list( + reorder_items_atscope( + items_set, argkeys_by_item, items_by_argkey, Scope.Session + ) + ) + + +def reorder_items_atscope( + items: OrderedSet[nodes.Item], + argkeys_by_item: Mapping[Scope, Mapping[nodes.Item, OrderedSet[ParamArgKey]]], + items_by_argkey: Mapping[ + Scope, Mapping[ParamArgKey, OrderedDict[nodes.Item, None]] + ], + scope: Scope, +) -> OrderedSet[nodes.Item]: + if scope is Scope.Function or len(items) < 3: + return items + + scoped_items_by_argkey = items_by_argkey[scope] + scoped_argkeys_by_item = argkeys_by_item[scope] + + ignore: set[ParamArgKey] = set() + items_deque = deque(items) + items_done: OrderedSet[nodes.Item] = {} + while items_deque: + no_argkey_items: OrderedSet[nodes.Item] = {} + slicing_argkey = None + while items_deque: + item = items_deque.popleft() + if item in items_done or item in no_argkey_items: + continue + argkeys = dict.fromkeys( + k for k in scoped_argkeys_by_item.get(item, ()) if k not in ignore + ) + if not argkeys: + no_argkey_items[item] = None + else: + slicing_argkey, _ = argkeys.popitem() + # We don't have to remove relevant items from later in the + # deque because they'll just be ignored. + matching_items = [ + i for i in scoped_items_by_argkey[slicing_argkey] if i in items + ] + for i in reversed(matching_items): + items_deque.appendleft(i) + # Fix items_by_argkey order. + for other_scope in HIGH_SCOPES: + other_scoped_items_by_argkey = items_by_argkey[other_scope] + for argkey in argkeys_by_item[other_scope].get(i, ()): + argkey_dict = other_scoped_items_by_argkey[argkey] + if not hasattr(sys, "pypy_version_info"): + argkey_dict[i] = None + argkey_dict.move_to_end(i, last=False) + else: + # Work around a bug in PyPy: + # https://github.com/pypy/pypy/issues/5257 + # https://github.com/pytest-dev/pytest/issues/13312 + bkp = argkey_dict.copy() + argkey_dict.clear() + argkey_dict[i] = None + argkey_dict.update(bkp) + break + if no_argkey_items: + reordered_no_argkey_items = reorder_items_atscope( + no_argkey_items, argkeys_by_item, items_by_argkey, scope.next_lower() + ) + items_done.update(reordered_no_argkey_items) + if slicing_argkey is not None: + ignore.add(slicing_argkey) + return items_done + + +@dataclasses.dataclass(frozen=True) +class FuncFixtureInfo: + """Fixture-related information for a fixture-requesting item (e.g. test + function). + + This is used to examine the fixtures which an item requests statically + (known during collection). This includes autouse fixtures, fixtures + requested by the `usefixtures` marker, fixtures requested in the function + parameters, and the transitive closure of these. + + An item may also request fixtures dynamically (using `request.getfixturevalue`); + these are not reflected here. + """ + + __slots__ = ("argnames", "initialnames", "name2fixturedefs", "names_closure") + + # Fixture names that the item requests directly by function parameters. + argnames: tuple[str, ...] + # Fixture names that the item immediately requires. These include + # argnames + fixture names specified via usefixtures and via autouse=True in + # fixture definitions. + initialnames: tuple[str, ...] + # The transitive closure of the fixture names that the item requires. + # Note: can't include dynamic dependencies (`request.getfixturevalue` calls). + names_closure: list[str] + # A map from a fixture name in the transitive closure to the FixtureDefs + # matching the name which are applicable to this function. + # There may be multiple overriding fixtures with the same name. The + # sequence is ordered from furthest to closes to the function. + name2fixturedefs: dict[str, Sequence[FixtureDef[Any]]] + + def prune_dependency_tree(self) -> None: + """Recompute names_closure from initialnames and name2fixturedefs. + + Can only reduce names_closure, which means that the new closure will + always be a subset of the old one. The order is preserved. + + This method is needed because direct parametrization may shadow some + of the fixtures that were included in the originally built dependency + tree. In this way the dependency tree can get pruned, and the closure + of argnames may get reduced. + """ + closure: set[str] = set() + working_set = set(self.initialnames) + while working_set: + argname = working_set.pop() + # Argname may be something not included in the original names_closure, + # in which case we ignore it. This currently happens with pseudo + # FixtureDefs which wrap 'get_direct_param_fixture_func(request)'. + # So they introduce the new dependency 'request' which might have + # been missing in the original tree (closure). + if argname not in closure and argname in self.names_closure: + closure.add(argname) + if argname in self.name2fixturedefs: + working_set.update(self.name2fixturedefs[argname][-1].argnames) + + self.names_closure[:] = sorted(closure, key=self.names_closure.index) + + +class FixtureRequest(abc.ABC): + """The type of the ``request`` fixture. + + A request object gives access to the requesting test context and has a + ``param`` attribute in case the fixture is parametrized. + """ + + def __init__( + self, + pyfuncitem: Function, + fixturename: str | None, + arg2fixturedefs: dict[str, Sequence[FixtureDef[Any]]], + fixture_defs: dict[str, FixtureDef[Any]], + *, + _ispytest: bool = False, + ) -> None: + check_ispytest(_ispytest) + #: Fixture for which this request is being performed. + self.fixturename: Final = fixturename + self._pyfuncitem: Final = pyfuncitem + # The FixtureDefs for each fixture name requested by this item. + # Starts from the statically-known fixturedefs resolved during + # collection. Dynamically requested fixtures (using + # `request.getfixturevalue("foo")`) are added dynamically. + self._arg2fixturedefs: Final = arg2fixturedefs + # The evaluated argnames so far, mapping to the FixtureDef they resolved + # to. + self._fixture_defs: Final = fixture_defs + # Notes on the type of `param`: + # -`request.param` is only defined in parametrized fixtures, and will raise + # AttributeError otherwise. Python typing has no notion of "undefined", so + # this cannot be reflected in the type. + # - Technically `param` is only (possibly) defined on SubRequest, not + # FixtureRequest, but the typing of that is still in flux so this cheats. + # - In the future we might consider using a generic for the param type, but + # for now just using Any. + self.param: Any + + @property + def _fixturemanager(self) -> FixtureManager: + return self._pyfuncitem.session._fixturemanager + + @property + @abc.abstractmethod + def _scope(self) -> Scope: + raise NotImplementedError() + + @property + def scope(self) -> _ScopeName: + """Scope string, one of "function", "class", "module", "package", "session".""" + return self._scope.value + + @abc.abstractmethod + def _check_scope( + self, + requested_fixturedef: FixtureDef[object], + requested_scope: Scope, + ) -> None: + raise NotImplementedError() + + @property + def fixturenames(self) -> list[str]: + """Names of all active fixtures in this request.""" + result = list(self._pyfuncitem.fixturenames) + result.extend(set(self._fixture_defs).difference(result)) + return result + + @property + @abc.abstractmethod + def node(self): + """Underlying collection node (depends on current request scope).""" + raise NotImplementedError() + + @property + def config(self) -> Config: + """The pytest config object associated with this request.""" + return self._pyfuncitem.config + + @property + def function(self): + """Test function object if the request has a per-function scope.""" + if self.scope != "function": + raise AttributeError( + f"function not available in {self.scope}-scoped context" + ) + return self._pyfuncitem.obj + + @property + def cls(self): + """Class (can be None) where the test function was collected.""" + if self.scope not in ("class", "function"): + raise AttributeError(f"cls not available in {self.scope}-scoped context") + clscol = self._pyfuncitem.getparent(_pytest.python.Class) + if clscol: + return clscol.obj + + @property + def instance(self): + """Instance (can be None) on which test function was collected.""" + if self.scope != "function": + return None + return getattr(self._pyfuncitem, "instance", None) + + @property + def module(self): + """Python module object where the test function was collected.""" + if self.scope not in ("function", "class", "module"): + raise AttributeError(f"module not available in {self.scope}-scoped context") + mod = self._pyfuncitem.getparent(_pytest.python.Module) + assert mod is not None + return mod.obj + + @property + def path(self) -> Path: + """Path where the test function was collected.""" + if self.scope not in ("function", "class", "module", "package"): + raise AttributeError(f"path not available in {self.scope}-scoped context") + return self._pyfuncitem.path + + @property + def keywords(self) -> MutableMapping[str, Any]: + """Keywords/markers dictionary for the underlying node.""" + node: nodes.Node = self.node + return node.keywords + + @property + def session(self) -> Session: + """Pytest session object.""" + return self._pyfuncitem.session + + @abc.abstractmethod + def addfinalizer(self, finalizer: Callable[[], object]) -> None: + """Add finalizer/teardown function to be called without arguments after + the last test within the requesting test context finished execution.""" + raise NotImplementedError() + + def applymarker(self, marker: str | MarkDecorator) -> None: + """Apply a marker to a single test function invocation. + + This method is useful if you don't want to have a keyword/marker + on all function invocations. + + :param marker: + An object created by a call to ``pytest.mark.NAME(...)``. + """ + self.node.add_marker(marker) + + def raiseerror(self, msg: str | None) -> NoReturn: + """Raise a FixtureLookupError exception. + + :param msg: + An optional custom error message. + """ + raise FixtureLookupError(None, self, msg) + + def getfixturevalue(self, argname: str) -> Any: + """Dynamically run a named fixture function. + + Declaring fixtures via function argument is recommended where possible. + But if you can only decide whether to use another fixture at test + setup time, you may use this function to retrieve it inside a fixture + or test function body. + + This method can be used during the test setup phase or the test run + phase, but during the test teardown phase a fixture's value may not + be available. + + :param argname: + The fixture name. + :raises pytest.FixtureLookupError: + If the given fixture could not be found. + """ + # Note that in addition to the use case described in the docstring, + # getfixturevalue() is also called by pytest itself during item and fixture + # setup to evaluate the fixtures that are requested statically + # (using function parameters, autouse, etc). + + fixturedef = self._get_active_fixturedef(argname) + assert fixturedef.cached_result is not None, ( + f'The fixture value for "{argname}" is not available. ' + "This can happen when the fixture has already been torn down." + ) + return fixturedef.cached_result[0] + + def _iter_chain(self) -> Iterator[SubRequest]: + """Yield all SubRequests in the chain, from self up. + + Note: does *not* yield the TopRequest. + """ + current = self + while isinstance(current, SubRequest): + yield current + current = current._parent_request + + def _get_active_fixturedef(self, argname: str) -> FixtureDef[object]: + if argname == "request": + return RequestFixtureDef(self) + + # If we already finished computing a fixture by this name in this item, + # return it. + fixturedef = self._fixture_defs.get(argname) + if fixturedef is not None: + self._check_scope(fixturedef, fixturedef._scope) + return fixturedef + + # Find the appropriate fixturedef. + fixturedefs = self._arg2fixturedefs.get(argname, None) + if fixturedefs is None: + # We arrive here because of a dynamic call to + # getfixturevalue(argname) which was naturally + # not known at parsing/collection time. + fixturedefs = self._fixturemanager.getfixturedefs(argname, self._pyfuncitem) + if fixturedefs is not None: + self._arg2fixturedefs[argname] = fixturedefs + # No fixtures defined with this name. + if fixturedefs is None: + raise FixtureLookupError(argname, self) + # The are no fixtures with this name applicable for the function. + if not fixturedefs: + raise FixtureLookupError(argname, self) + + # A fixture may override another fixture with the same name, e.g. a + # fixture in a module can override a fixture in a conftest, a fixture in + # a class can override a fixture in the module, and so on. + # An overriding fixture can request its own name (possibly indirectly); + # in this case it gets the value of the fixture it overrides, one level + # up. + # Check how many `argname`s deep we are, and take the next one. + # `fixturedefs` is sorted from furthest to closest, so use negative + # indexing to go in reverse. + index = -1 + for request in self._iter_chain(): + if request.fixturename == argname: + index -= 1 + # If already consumed all of the available levels, fail. + if -index > len(fixturedefs): + raise FixtureLookupError(argname, self) + fixturedef = fixturedefs[index] + + # Prepare a SubRequest object for calling the fixture. + try: + callspec = self._pyfuncitem.callspec + except AttributeError: + callspec = None + if callspec is not None and argname in callspec.params: + param = callspec.params[argname] + param_index = callspec.indices[argname] + # The parametrize invocation scope overrides the fixture's scope. + scope = callspec._arg2scope[argname] + else: + param = NOTSET + param_index = 0 + scope = fixturedef._scope + self._check_fixturedef_without_param(fixturedef) + # The parametrize invocation scope only controls caching behavior while + # allowing wider-scoped fixtures to keep depending on the parametrized + # fixture. Scope control is enforced for parametrized fixtures + # by recreating the whole fixture tree on parameter change. + # Hence `fixturedef._scope`, not `scope`. + self._check_scope(fixturedef, fixturedef._scope) + subrequest = SubRequest( + self, scope, param, param_index, fixturedef, _ispytest=True + ) + + # Make sure the fixture value is cached, running it if it isn't + fixturedef.execute(request=subrequest) + + self._fixture_defs[argname] = fixturedef + return fixturedef + + def _check_fixturedef_without_param(self, fixturedef: FixtureDef[object]) -> None: + """Check that this request is allowed to execute this fixturedef without + a param.""" + funcitem = self._pyfuncitem + has_params = fixturedef.params is not None + fixtures_not_supported = getattr(funcitem, "nofuncargs", False) + if has_params and fixtures_not_supported: + msg = ( + f"{funcitem.name} does not support fixtures, maybe unittest.TestCase subclass?\n" + f"Node id: {funcitem.nodeid}\n" + f"Function type: {type(funcitem).__name__}" + ) + fail(msg, pytrace=False) + if has_params: + frame = inspect.stack()[3] + frameinfo = inspect.getframeinfo(frame[0]) + source_path = absolutepath(frameinfo.filename) + source_lineno = frameinfo.lineno + try: + source_path_str = str(source_path.relative_to(funcitem.config.rootpath)) + except ValueError: + source_path_str = str(source_path) + location = getlocation(fixturedef.func, funcitem.config.rootpath) + msg = ( + "The requested fixture has no parameter defined for test:\n" + f" {funcitem.nodeid}\n\n" + f"Requested fixture '{fixturedef.argname}' defined in:\n" + f"{location}\n\n" + f"Requested here:\n" + f"{source_path_str}:{source_lineno}" + ) + fail(msg, pytrace=False) + + def _get_fixturestack(self) -> list[FixtureDef[Any]]: + values = [request._fixturedef for request in self._iter_chain()] + values.reverse() + return values + + +@final +class TopRequest(FixtureRequest): + """The type of the ``request`` fixture in a test function.""" + + def __init__(self, pyfuncitem: Function, *, _ispytest: bool = False) -> None: + super().__init__( + fixturename=None, + pyfuncitem=pyfuncitem, + arg2fixturedefs=pyfuncitem._fixtureinfo.name2fixturedefs.copy(), + fixture_defs={}, + _ispytest=_ispytest, + ) + + @property + def _scope(self) -> Scope: + return Scope.Function + + def _check_scope( + self, + requested_fixturedef: FixtureDef[object], + requested_scope: Scope, + ) -> None: + # TopRequest always has function scope so always valid. + pass + + @property + def node(self): + return self._pyfuncitem + + def __repr__(self) -> str: + return f"<FixtureRequest for {self.node!r}>" + + def _fillfixtures(self) -> None: + item = self._pyfuncitem + for argname in item.fixturenames: + if argname not in item.funcargs: + item.funcargs[argname] = self.getfixturevalue(argname) + + def addfinalizer(self, finalizer: Callable[[], object]) -> None: + self.node.addfinalizer(finalizer) + + +@final +class SubRequest(FixtureRequest): + """The type of the ``request`` fixture in a fixture function requested + (transitively) by a test function.""" + + def __init__( + self, + request: FixtureRequest, + scope: Scope, + param: Any, + param_index: int, + fixturedef: FixtureDef[object], + *, + _ispytest: bool = False, + ) -> None: + super().__init__( + pyfuncitem=request._pyfuncitem, + fixturename=fixturedef.argname, + fixture_defs=request._fixture_defs, + arg2fixturedefs=request._arg2fixturedefs, + _ispytest=_ispytest, + ) + self._parent_request: Final[FixtureRequest] = request + self._scope_field: Final = scope + self._fixturedef: Final[FixtureDef[object]] = fixturedef + if param is not NOTSET: + self.param = param + self.param_index: Final = param_index + + def __repr__(self) -> str: + return f"<SubRequest {self.fixturename!r} for {self._pyfuncitem!r}>" + + @property + def _scope(self) -> Scope: + return self._scope_field + + @property + def node(self): + scope = self._scope + if scope is Scope.Function: + # This might also be a non-function Item despite its attribute name. + node: nodes.Node | None = self._pyfuncitem + elif scope is Scope.Package: + node = get_scope_package(self._pyfuncitem, self._fixturedef) + else: + node = get_scope_node(self._pyfuncitem, scope) + if node is None and scope is Scope.Class: + # Fallback to function item itself. + node = self._pyfuncitem + assert node, ( + f'Could not obtain a node for scope "{scope}" for function {self._pyfuncitem!r}' + ) + return node + + def _check_scope( + self, + requested_fixturedef: FixtureDef[object], + requested_scope: Scope, + ) -> None: + if self._scope > requested_scope: + # Try to report something helpful. + argname = requested_fixturedef.argname + fixture_stack = "\n".join( + self._format_fixturedef_line(fixturedef) + for fixturedef in self._get_fixturestack() + ) + requested_fixture = self._format_fixturedef_line(requested_fixturedef) + fail( + f"ScopeMismatch: You tried to access the {requested_scope.value} scoped " + f"fixture {argname} with a {self._scope.value} scoped request object. " + f"Requesting fixture stack:\n{fixture_stack}\n" + f"Requested fixture:\n{requested_fixture}", + pytrace=False, + ) + + def _format_fixturedef_line(self, fixturedef: FixtureDef[object]) -> str: + factory = fixturedef.func + path, lineno = getfslineno(factory) + if isinstance(path, Path): + path = bestrelpath(self._pyfuncitem.session.path, path) + sig = signature(factory) + return f"{path}:{lineno + 1}: def {factory.__name__}{sig}" + + def addfinalizer(self, finalizer: Callable[[], object]) -> None: + self._fixturedef.addfinalizer(finalizer) + + +@final +class FixtureLookupError(LookupError): + """Could not return a requested fixture (missing or invalid).""" + + def __init__( + self, argname: str | None, request: FixtureRequest, msg: str | None = None + ) -> None: + self.argname = argname + self.request = request + self.fixturestack = request._get_fixturestack() + self.msg = msg + + def formatrepr(self) -> FixtureLookupErrorRepr: + tblines: list[str] = [] + addline = tblines.append + stack = [self.request._pyfuncitem.obj] + stack.extend(map(lambda x: x.func, self.fixturestack)) + msg = self.msg + # This function currently makes an assumption that a non-None msg means we + # have a non-empty `self.fixturestack`. This is currently true, but if + # somebody at some point want to extend the use of FixtureLookupError to + # new cases it might break. + # Add the assert to make it clearer to developer that this will fail, otherwise + # it crashes because `fspath` does not get set due to `stack` being empty. + assert self.msg is None or self.fixturestack, ( + "formatrepr assumptions broken, rewrite it to handle it" + ) + if msg is not None: + # The last fixture raise an error, let's present + # it at the requesting side. + stack = stack[:-1] + for function in stack: + fspath, lineno = getfslineno(function) + try: + lines, _ = inspect.getsourcelines(get_real_func(function)) + except (OSError, IndexError, TypeError): + error_msg = "file %s, line %s: source code not available" + addline(error_msg % (fspath, lineno + 1)) + else: + addline(f"file {fspath}, line {lineno + 1}") + for i, line in enumerate(lines): + line = line.rstrip() + addline(" " + line) + if line.lstrip().startswith("def"): + break + + if msg is None: + fm = self.request._fixturemanager + available = set() + parent = self.request._pyfuncitem.parent + assert parent is not None + for name, fixturedefs in fm._arg2fixturedefs.items(): + faclist = list(fm._matchfactories(fixturedefs, parent)) + if faclist: + available.add(name) + if self.argname in available: + msg = ( + f" recursive dependency involving fixture '{self.argname}' detected" + ) + else: + msg = f"fixture '{self.argname}' not found" + msg += "\n available fixtures: {}".format(", ".join(sorted(available))) + msg += "\n use 'pytest --fixtures [testpath]' for help on them." + + return FixtureLookupErrorRepr(fspath, lineno, tblines, msg, self.argname) + + +class FixtureLookupErrorRepr(TerminalRepr): + def __init__( + self, + filename: str | os.PathLike[str], + firstlineno: int, + tblines: Sequence[str], + errorstring: str, + argname: str | None, + ) -> None: + self.tblines = tblines + self.errorstring = errorstring + self.filename = filename + self.firstlineno = firstlineno + self.argname = argname + + def toterminal(self, tw: TerminalWriter) -> None: + # tw.line("FixtureLookupError: %s" %(self.argname), red=True) + for tbline in self.tblines: + tw.line(tbline.rstrip()) + lines = self.errorstring.split("\n") + if lines: + tw.line( + f"{FormattedExcinfo.fail_marker} {lines[0].strip()}", + red=True, + ) + for line in lines[1:]: + tw.line( + f"{FormattedExcinfo.flow_marker} {line.strip()}", + red=True, + ) + tw.line() + tw.line(f"{os.fspath(self.filename)}:{self.firstlineno + 1}") + + +def call_fixture_func( + fixturefunc: _FixtureFunc[FixtureValue], request: FixtureRequest, kwargs +) -> FixtureValue: + if inspect.isgeneratorfunction(fixturefunc): + fixturefunc = cast(Callable[..., Generator[FixtureValue]], fixturefunc) + generator = fixturefunc(**kwargs) + try: + fixture_result = next(generator) + except StopIteration: + raise ValueError(f"{request.fixturename} did not yield a value") from None + finalizer = functools.partial(_teardown_yield_fixture, fixturefunc, generator) + request.addfinalizer(finalizer) + else: + fixturefunc = cast(Callable[..., FixtureValue], fixturefunc) + fixture_result = fixturefunc(**kwargs) + return fixture_result + + +def _teardown_yield_fixture(fixturefunc, it) -> None: + """Execute the teardown of a fixture function by advancing the iterator + after the yield and ensure the iteration ends (if not it means there is + more than one yield in the function).""" + try: + next(it) + except StopIteration: + pass + else: + fs, lineno = getfslineno(fixturefunc) + fail( + f"fixture function has more than one 'yield':\n\n" + f"{Source(fixturefunc).indent()}\n" + f"{fs}:{lineno + 1}", + pytrace=False, + ) + + +def _eval_scope_callable( + scope_callable: Callable[[str, Config], _ScopeName], + fixture_name: str, + config: Config, +) -> _ScopeName: + try: + # Type ignored because there is no typing mechanism to specify + # keyword arguments, currently. + result = scope_callable(fixture_name=fixture_name, config=config) # type: ignore[call-arg] + except Exception as e: + raise TypeError( + f"Error evaluating {scope_callable} while defining fixture '{fixture_name}'.\n" + "Expected a function with the signature (*, fixture_name, config)" + ) from e + if not isinstance(result, str): + fail( + f"Expected {scope_callable} to return a 'str' while defining fixture '{fixture_name}', but it returned:\n" + f"{result!r}", + pytrace=False, + ) + return result + + +class FixtureDef(Generic[FixtureValue]): + """A container for a fixture definition. + + Note: At this time, only explicitly documented fields and methods are + considered public stable API. + """ + + def __init__( + self, + config: Config, + baseid: str | None, + argname: str, + func: _FixtureFunc[FixtureValue], + scope: Scope | _ScopeName | Callable[[str, Config], _ScopeName] | None, + params: Sequence[object] | None, + ids: tuple[object | None, ...] | Callable[[Any], object | None] | None = None, + *, + _ispytest: bool = False, + # only used in a deprecationwarning msg, can be removed in pytest9 + _autouse: bool = False, + ) -> None: + check_ispytest(_ispytest) + # The "base" node ID for the fixture. + # + # This is a node ID prefix. A fixture is only available to a node (e.g. + # a `Function` item) if the fixture's baseid is a nodeid of a parent of + # node. + # + # For a fixture found in a Collector's object (e.g. a `Module`s module, + # a `Class`'s class), the baseid is the Collector's nodeid. + # + # For a fixture found in a conftest plugin, the baseid is the conftest's + # directory path relative to the rootdir. + # + # For other plugins, the baseid is the empty string (always matches). + self.baseid: Final = baseid or "" + # Whether the fixture was found from a node or a conftest in the + # collection tree. Will be false for fixtures defined in non-conftest + # plugins. + self.has_location: Final = baseid is not None + # The fixture factory function. + self.func: Final = func + # The name by which the fixture may be requested. + self.argname: Final = argname + if scope is None: + scope = Scope.Function + elif callable(scope): + scope = _eval_scope_callable(scope, argname, config) + if isinstance(scope, str): + scope = Scope.from_user( + scope, descr=f"Fixture '{func.__name__}'", where=baseid + ) + self._scope: Final = scope + # If the fixture is directly parametrized, the parameter values. + self.params: Final = params + # If the fixture is directly parametrized, a tuple of explicit IDs to + # assign to the parameter values, or a callable to generate an ID given + # a parameter value. + self.ids: Final = ids + # The names requested by the fixtures. + self.argnames: Final = getfuncargnames(func, name=argname) + # If the fixture was executed, the current value of the fixture. + # Can change if the fixture is executed with different parameters. + self.cached_result: _FixtureCachedResult[FixtureValue] | None = None + self._finalizers: Final[list[Callable[[], object]]] = [] + + # only used to emit a deprecationwarning, can be removed in pytest9 + self._autouse = _autouse + + @property + def scope(self) -> _ScopeName: + """Scope string, one of "function", "class", "module", "package", "session".""" + return self._scope.value + + def addfinalizer(self, finalizer: Callable[[], object]) -> None: + self._finalizers.append(finalizer) + + def finish(self, request: SubRequest) -> None: + exceptions: list[BaseException] = [] + while self._finalizers: + fin = self._finalizers.pop() + try: + fin() + except BaseException as e: + exceptions.append(e) + node = request.node + node.ihook.pytest_fixture_post_finalizer(fixturedef=self, request=request) + # Even if finalization fails, we invalidate the cached fixture + # value and remove all finalizers because they may be bound methods + # which will keep instances alive. + self.cached_result = None + self._finalizers.clear() + if len(exceptions) == 1: + raise exceptions[0] + elif len(exceptions) > 1: + msg = f'errors while tearing down fixture "{self.argname}" of {node}' + raise BaseExceptionGroup(msg, exceptions[::-1]) + + def execute(self, request: SubRequest) -> FixtureValue: + """Return the value of this fixture, executing it if not cached.""" + # Ensure that the dependent fixtures requested by this fixture are loaded. + # This needs to be done before checking if we have a cached value, since + # if a dependent fixture has their cache invalidated, e.g. due to + # parametrization, they finalize themselves and fixtures depending on it + # (which will likely include this fixture) setting `self.cached_result = None`. + # See #4871 + requested_fixtures_that_should_finalize_us = [] + for argname in self.argnames: + fixturedef = request._get_active_fixturedef(argname) + # Saves requested fixtures in a list so we later can add our finalizer + # to them, ensuring that if a requested fixture gets torn down we get torn + # down first. This is generally handled by SetupState, but still currently + # needed when this fixture is not parametrized but depends on a parametrized + # fixture. + requested_fixtures_that_should_finalize_us.append(fixturedef) + + # Check for (and return) cached value/exception. + if self.cached_result is not None: + request_cache_key = self.cache_key(request) + cache_key = self.cached_result[1] + try: + # Attempt to make a normal == check: this might fail for objects + # which do not implement the standard comparison (like numpy arrays -- #6497). + cache_hit = bool(request_cache_key == cache_key) + except (ValueError, RuntimeError): + # If the comparison raises, use 'is' as fallback. + cache_hit = request_cache_key is cache_key + + if cache_hit: + if self.cached_result[2] is not None: + exc, exc_tb = self.cached_result[2] + raise exc.with_traceback(exc_tb) + else: + return self.cached_result[0] + # We have a previous but differently parametrized fixture instance + # so we need to tear it down before creating a new one. + self.finish(request) + assert self.cached_result is None + + # Add finalizer to requested fixtures we saved previously. + # We make sure to do this after checking for cached value to avoid + # adding our finalizer multiple times. (#12135) + finalizer = functools.partial(self.finish, request=request) + for parent_fixture in requested_fixtures_that_should_finalize_us: + parent_fixture.addfinalizer(finalizer) + + ihook = request.node.ihook + try: + # Setup the fixture, run the code in it, and cache the value + # in self.cached_result. + result: FixtureValue = ihook.pytest_fixture_setup( + fixturedef=self, request=request + ) + finally: + # Schedule our finalizer, even if the setup failed. + request.node.addfinalizer(finalizer) + + return result + + def cache_key(self, request: SubRequest) -> object: + return getattr(request, "param", None) + + def __repr__(self) -> str: + return f"<FixtureDef argname={self.argname!r} scope={self.scope!r} baseid={self.baseid!r}>" + + +class RequestFixtureDef(FixtureDef[FixtureRequest]): + """A custom FixtureDef for the special "request" fixture. + + A new one is generated on-demand whenever "request" is requested. + """ + + def __init__(self, request: FixtureRequest) -> None: + super().__init__( + config=request.config, + baseid=None, + argname="request", + func=lambda: request, + scope=Scope.Function, + params=None, + _ispytest=True, + ) + self.cached_result = (request, [0], None) + + def addfinalizer(self, finalizer: Callable[[], object]) -> None: + pass + + +def resolve_fixture_function( + fixturedef: FixtureDef[FixtureValue], request: FixtureRequest +) -> _FixtureFunc[FixtureValue]: + """Get the actual callable that can be called to obtain the fixture + value.""" + fixturefunc = fixturedef.func + # The fixture function needs to be bound to the actual + # request.instance so that code working with "fixturedef" behaves + # as expected. + instance = request.instance + if instance is not None: + # Handle the case where fixture is defined not in a test class, but some other class + # (for example a plugin class with a fixture), see #2270. + if hasattr(fixturefunc, "__self__") and not isinstance( + instance, + fixturefunc.__self__.__class__, + ): + return fixturefunc + fixturefunc = getimfunc(fixturedef.func) + if fixturefunc != fixturedef.func: + fixturefunc = fixturefunc.__get__(instance) + return fixturefunc + + +def pytest_fixture_setup( + fixturedef: FixtureDef[FixtureValue], request: SubRequest +) -> FixtureValue: + """Execution of fixture setup.""" + kwargs = {} + for argname in fixturedef.argnames: + kwargs[argname] = request.getfixturevalue(argname) + + fixturefunc = resolve_fixture_function(fixturedef, request) + my_cache_key = fixturedef.cache_key(request) + + if inspect.isasyncgenfunction(fixturefunc) or inspect.iscoroutinefunction( + fixturefunc + ): + auto_str = " with autouse=True" if fixturedef._autouse else "" + + warnings.warn( + PytestRemovedIn9Warning( + f"{request.node.name!r} requested an async fixture " + f"{request.fixturename!r}{auto_str}, with no plugin or hook that " + "handled it. This is usually an error, as pytest does not natively " + "support it. " + "This will turn into an error in pytest 9.\n" + "See: https://docs.pytest.org/en/stable/deprecations.html#sync-test-depending-on-async-fixture" + ), + # no stacklevel will point at users code, so we just point here + stacklevel=1, + ) + + try: + result = call_fixture_func(fixturefunc, request, kwargs) + except TEST_OUTCOME as e: + if isinstance(e, skip.Exception): + # The test requested a fixture which caused a skip. + # Don't show the fixture as the skip location, as then the user + # wouldn't know which test skipped. + e._use_item_location = True + fixturedef.cached_result = (None, my_cache_key, (e, e.__traceback__)) + raise + fixturedef.cached_result = (result, my_cache_key, None) + return result + + +@final +@dataclasses.dataclass(frozen=True) +class FixtureFunctionMarker: + scope: _ScopeName | Callable[[str, Config], _ScopeName] + params: tuple[object, ...] | None + autouse: bool = False + ids: tuple[object | None, ...] | Callable[[Any], object | None] | None = None + name: str | None = None + + _ispytest: dataclasses.InitVar[bool] = False + + def __post_init__(self, _ispytest: bool) -> None: + check_ispytest(_ispytest) + + def __call__(self, function: FixtureFunction) -> FixtureFunctionDefinition: + if inspect.isclass(function): + raise ValueError("class fixtures not supported (maybe in the future)") + + if isinstance(function, FixtureFunctionDefinition): + raise ValueError( + f"@pytest.fixture is being applied more than once to the same function {function.__name__!r}" + ) + + if hasattr(function, "pytestmark"): + warnings.warn(MARKED_FIXTURE, stacklevel=2) + + fixture_definition = FixtureFunctionDefinition( + function=function, fixture_function_marker=self, _ispytest=True + ) + + name = self.name or function.__name__ + if name == "request": + location = getlocation(function) + fail( + f"'request' is a reserved word for fixtures, use another name:\n {location}", + pytrace=False, + ) + + return fixture_definition + + +# TODO: paramspec/return type annotation tracking and storing +class FixtureFunctionDefinition: + def __init__( + self, + *, + function: Callable[..., Any], + fixture_function_marker: FixtureFunctionMarker, + instance: object | None = None, + _ispytest: bool = False, + ) -> None: + check_ispytest(_ispytest) + self.name = fixture_function_marker.name or function.__name__ + # In order to show the function that this fixture contains in messages. + # Set the __name__ to be same as the function __name__ or the given fixture name. + self.__name__ = self.name + self._fixture_function_marker = fixture_function_marker + if instance is not None: + self._fixture_function = cast( + Callable[..., Any], function.__get__(instance) + ) + else: + self._fixture_function = function + functools.update_wrapper(self, function) + + def __repr__(self) -> str: + return f"<pytest_fixture({self._fixture_function})>" + + def __get__(self, instance, owner=None): + """Behave like a method if the function it was applied to was a method.""" + return FixtureFunctionDefinition( + function=self._fixture_function, + fixture_function_marker=self._fixture_function_marker, + instance=instance, + _ispytest=True, + ) + + def __call__(self, *args: Any, **kwds: Any) -> Any: + message = ( + f'Fixture "{self.name}" called directly. Fixtures are not meant to be called directly,\n' + "but are created automatically when test functions request them as parameters.\n" + "See https://docs.pytest.org/en/stable/explanation/fixtures.html for more information about fixtures, and\n" + "https://docs.pytest.org/en/stable/deprecations.html#calling-fixtures-directly" + ) + fail(message, pytrace=False) + + def _get_wrapped_function(self) -> Callable[..., Any]: + return self._fixture_function + + +@overload +def fixture( + fixture_function: Callable[..., object], + *, + scope: _ScopeName | Callable[[str, Config], _ScopeName] = ..., + params: Iterable[object] | None = ..., + autouse: bool = ..., + ids: Sequence[object | None] | Callable[[Any], object | None] | None = ..., + name: str | None = ..., +) -> FixtureFunctionDefinition: ... + + +@overload +def fixture( + fixture_function: None = ..., + *, + scope: _ScopeName | Callable[[str, Config], _ScopeName] = ..., + params: Iterable[object] | None = ..., + autouse: bool = ..., + ids: Sequence[object | None] | Callable[[Any], object | None] | None = ..., + name: str | None = None, +) -> FixtureFunctionMarker: ... + + +def fixture( + fixture_function: FixtureFunction | None = None, + *, + scope: _ScopeName | Callable[[str, Config], _ScopeName] = "function", + params: Iterable[object] | None = None, + autouse: bool = False, + ids: Sequence[object | None] | Callable[[Any], object | None] | None = None, + name: str | None = None, +) -> FixtureFunctionMarker | FixtureFunctionDefinition: + """Decorator to mark a fixture factory function. + + This decorator can be used, with or without parameters, to define a + fixture function. + + The name of the fixture function can later be referenced to cause its + invocation ahead of running tests: test modules or classes can use the + ``pytest.mark.usefixtures(fixturename)`` marker. + + Test functions can directly use fixture names as input arguments in which + case the fixture instance returned from the fixture function will be + injected. + + Fixtures can provide their values to test functions using ``return`` or + ``yield`` statements. When using ``yield`` the code block after the + ``yield`` statement is executed as teardown code regardless of the test + outcome, and must yield exactly once. + + :param scope: + The scope for which this fixture is shared; one of ``"function"`` + (default), ``"class"``, ``"module"``, ``"package"`` or ``"session"``. + + This parameter may also be a callable which receives ``(fixture_name, config)`` + as parameters, and must return a ``str`` with one of the values mentioned above. + + See :ref:`dynamic scope` in the docs for more information. + + :param params: + An optional list of parameters which will cause multiple invocations + of the fixture function and all of the tests using it. The current + parameter is available in ``request.param``. + + :param autouse: + If True, the fixture func is activated for all tests that can see it. + If False (the default), an explicit reference is needed to activate + the fixture. + + :param ids: + Sequence of ids each corresponding to the params so that they are + part of the test id. If no ids are provided they will be generated + automatically from the params. + + :param name: + The name of the fixture. This defaults to the name of the decorated + function. If a fixture is used in the same module in which it is + defined, the function name of the fixture will be shadowed by the + function arg that requests the fixture; one way to resolve this is to + name the decorated function ``fixture_<fixturename>`` and then use + ``@pytest.fixture(name='<fixturename>')``. + """ + fixture_marker = FixtureFunctionMarker( + scope=scope, + params=tuple(params) if params is not None else None, + autouse=autouse, + ids=None if ids is None else ids if callable(ids) else tuple(ids), + name=name, + _ispytest=True, + ) + + # Direct decoration. + if fixture_function: + return fixture_marker(fixture_function) + + return fixture_marker + + +def yield_fixture( + fixture_function=None, + *args, + scope="function", + params=None, + autouse=False, + ids=None, + name=None, +): + """(Return a) decorator to mark a yield-fixture factory function. + + .. deprecated:: 3.0 + Use :py:func:`pytest.fixture` directly instead. + """ + warnings.warn(YIELD_FIXTURE, stacklevel=2) + return fixture( + fixture_function, + *args, + scope=scope, + params=params, + autouse=autouse, + ids=ids, + name=name, + ) + + +@fixture(scope="session") +def pytestconfig(request: FixtureRequest) -> Config: + """Session-scoped fixture that returns the session's :class:`pytest.Config` + object. + + Example:: + + def test_foo(pytestconfig): + if pytestconfig.get_verbosity() > 0: + ... + + """ + return request.config + + +def pytest_addoption(parser: Parser) -> None: + parser.addini( + "usefixtures", + type="args", + default=[], + help="List of default fixtures to be used with this project", + ) + group = parser.getgroup("general") + group.addoption( + "--fixtures", + "--funcargs", + action="store_true", + dest="showfixtures", + default=False, + help="Show available fixtures, sorted by plugin appearance " + "(fixtures with leading '_' are only shown with '-v')", + ) + group.addoption( + "--fixtures-per-test", + action="store_true", + dest="show_fixtures_per_test", + default=False, + help="Show fixtures per test", + ) + + +def pytest_cmdline_main(config: Config) -> int | ExitCode | None: + if config.option.showfixtures: + showfixtures(config) + return 0 + if config.option.show_fixtures_per_test: + show_fixtures_per_test(config) + return 0 + return None + + +def _get_direct_parametrize_args(node: nodes.Node) -> set[str]: + """Return all direct parametrization arguments of a node, so we don't + mistake them for fixtures. + + Check https://github.com/pytest-dev/pytest/issues/5036. + + These things are done later as well when dealing with parametrization + so this could be improved. + """ + parametrize_argnames: set[str] = set() + for marker in node.iter_markers(name="parametrize"): + if not marker.kwargs.get("indirect", False): + p_argnames, _ = ParameterSet._parse_parametrize_args( + *marker.args, **marker.kwargs + ) + parametrize_argnames.update(p_argnames) + return parametrize_argnames + + +def deduplicate_names(*seqs: Iterable[str]) -> tuple[str, ...]: + """De-duplicate the sequence of names while keeping the original order.""" + # Ideally we would use a set, but it does not preserve insertion order. + return tuple(dict.fromkeys(name for seq in seqs for name in seq)) + + +class FixtureManager: + """pytest fixture definitions and information is stored and managed + from this class. + + During collection fm.parsefactories() is called multiple times to parse + fixture function definitions into FixtureDef objects and internal + data structures. + + During collection of test functions, metafunc-mechanics instantiate + a FuncFixtureInfo object which is cached per node/func-name. + This FuncFixtureInfo object is later retrieved by Function nodes + which themselves offer a fixturenames attribute. + + The FuncFixtureInfo object holds information about fixtures and FixtureDefs + relevant for a particular function. An initial list of fixtures is + assembled like this: + + - config-defined usefixtures + - autouse-marked fixtures along the collection chain up from the function + - usefixtures markers at module/class/function level + - test function funcargs + + Subsequently the funcfixtureinfo.fixturenames attribute is computed + as the closure of the fixtures needed to setup the initial fixtures, + i.e. fixtures needed by fixture functions themselves are appended + to the fixturenames list. + + Upon the test-setup phases all fixturenames are instantiated, retrieved + by a lookup of their FuncFixtureInfo. + """ + + def __init__(self, session: Session) -> None: + self.session = session + self.config: Config = session.config + # Maps a fixture name (argname) to all of the FixtureDefs in the test + # suite/plugins defined with this name. Populated by parsefactories(). + # TODO: The order of the FixtureDefs list of each arg is significant, + # explain. + self._arg2fixturedefs: Final[dict[str, list[FixtureDef[Any]]]] = {} + self._holderobjseen: Final[set[object]] = set() + # A mapping from a nodeid to a list of autouse fixtures it defines. + self._nodeid_autousenames: Final[dict[str, list[str]]] = { + "": self.config.getini("usefixtures"), + } + session.config.pluginmanager.register(self, "funcmanage") + + def getfixtureinfo( + self, + node: nodes.Item, + func: Callable[..., object] | None, + cls: type | None, + ) -> FuncFixtureInfo: + """Calculate the :class:`FuncFixtureInfo` for an item. + + If ``func`` is None, or if the item sets an attribute + ``nofuncargs = True``, then ``func`` is not examined at all. + + :param node: + The item requesting the fixtures. + :param func: + The item's function. + :param cls: + If the function is a method, the method's class. + """ + if func is not None and not getattr(node, "nofuncargs", False): + argnames = getfuncargnames(func, name=node.name, cls=cls) + else: + argnames = () + usefixturesnames = self._getusefixturesnames(node) + autousenames = self._getautousenames(node) + initialnames = deduplicate_names(autousenames, usefixturesnames, argnames) + + direct_parametrize_args = _get_direct_parametrize_args(node) + + names_closure, arg2fixturedefs = self.getfixtureclosure( + parentnode=node, + initialnames=initialnames, + ignore_args=direct_parametrize_args, + ) + + return FuncFixtureInfo(argnames, initialnames, names_closure, arg2fixturedefs) + + def pytest_plugin_registered(self, plugin: _PluggyPlugin, plugin_name: str) -> None: + # Fixtures defined in conftest plugins are only visible to within the + # conftest's directory. This is unlike fixtures in non-conftest plugins + # which have global visibility. So for conftests, construct the base + # nodeid from the plugin name (which is the conftest path). + if plugin_name and plugin_name.endswith("conftest.py"): + # Note: we explicitly do *not* use `plugin.__file__` here -- The + # difference is that plugin_name has the correct capitalization on + # case-insensitive systems (Windows) and other normalization issues + # (issue #11816). + conftestpath = absolutepath(plugin_name) + try: + nodeid = str(conftestpath.parent.relative_to(self.config.rootpath)) + except ValueError: + nodeid = "" + if nodeid == ".": + nodeid = "" + if os.sep != nodes.SEP: + nodeid = nodeid.replace(os.sep, nodes.SEP) + else: + nodeid = None + + self.parsefactories(plugin, nodeid) + + def _getautousenames(self, node: nodes.Node) -> Iterator[str]: + """Return the names of autouse fixtures applicable to node.""" + for parentnode in node.listchain(): + basenames = self._nodeid_autousenames.get(parentnode.nodeid) + if basenames: + yield from basenames + + def _getusefixturesnames(self, node: nodes.Item) -> Iterator[str]: + """Return the names of usefixtures fixtures applicable to node.""" + for marker_node, mark in node.iter_markers_with_node(name="usefixtures"): + if not mark.args: + marker_node.warn( + PytestWarning( + f"usefixtures() in {node.nodeid} without arguments has no effect" + ) + ) + yield from mark.args + + def getfixtureclosure( + self, + parentnode: nodes.Node, + initialnames: tuple[str, ...], + ignore_args: AbstractSet[str], + ) -> tuple[list[str], dict[str, Sequence[FixtureDef[Any]]]]: + # Collect the closure of all fixtures, starting with the given + # fixturenames as the initial set. As we have to visit all + # factory definitions anyway, we also return an arg2fixturedefs + # mapping so that the caller can reuse it and does not have + # to re-discover fixturedefs again for each fixturename + # (discovering matching fixtures for a given name/node is expensive). + + fixturenames_closure = list(initialnames) + + arg2fixturedefs: dict[str, Sequence[FixtureDef[Any]]] = {} + + # Track the index for each fixture name in the simulated stack. + # Needed for handling override chains correctly, similar to _get_active_fixturedef. + # Using negative indices: -1 is the most specific (last), -2 is second to last, etc. + current_indices: dict[str, int] = {} + + def process_argname(argname: str) -> None: + # Optimization: already processed this argname. + if current_indices.get(argname) == -1: + return + + if argname not in fixturenames_closure: + fixturenames_closure.append(argname) + + if argname in ignore_args: + return + + fixturedefs = arg2fixturedefs.get(argname) + if not fixturedefs: + fixturedefs = self.getfixturedefs(argname, parentnode) + if not fixturedefs: + # Fixture not defined or not visible (will error during runtest). + return + arg2fixturedefs[argname] = fixturedefs + + index = current_indices.get(argname, -1) + if -index > len(fixturedefs): + # Exhausted the override chain (will error during runtest). + return + fixturedef = fixturedefs[index] + + current_indices[argname] = index - 1 + for dep in fixturedef.argnames: + process_argname(dep) + current_indices[argname] = index + + for name in initialnames: + process_argname(name) + + def sort_by_scope(arg_name: str) -> Scope: + try: + fixturedefs = arg2fixturedefs[arg_name] + except KeyError: + return Scope.Function + else: + return fixturedefs[-1]._scope + + fixturenames_closure.sort(key=sort_by_scope, reverse=True) + return fixturenames_closure, arg2fixturedefs + + def pytest_generate_tests(self, metafunc: Metafunc) -> None: + """Generate new tests based on parametrized fixtures used by the given metafunc""" + + def get_parametrize_mark_argnames(mark: Mark) -> Sequence[str]: + args, _ = ParameterSet._parse_parametrize_args(*mark.args, **mark.kwargs) + return args + + for argname in metafunc.fixturenames: + # Get the FixtureDefs for the argname. + fixture_defs = metafunc._arg2fixturedefs.get(argname) + if not fixture_defs: + # Will raise FixtureLookupError at setup time if not parametrized somewhere + # else (e.g @pytest.mark.parametrize) + continue + + # If the test itself parametrizes using this argname, give it + # precedence. + if any( + argname in get_parametrize_mark_argnames(mark) + for mark in metafunc.definition.iter_markers("parametrize") + ): + continue + + # In the common case we only look at the fixture def with the + # closest scope (last in the list). But if the fixture overrides + # another fixture, while requesting the super fixture, keep going + # in case the super fixture is parametrized (#1953). + for fixturedef in reversed(fixture_defs): + # Fixture is parametrized, apply it and stop. + if fixturedef.params is not None: + metafunc.parametrize( + argname, + fixturedef.params, + indirect=True, + scope=fixturedef.scope, + ids=fixturedef.ids, + ) + break + + # Not requesting the overridden super fixture, stop. + if argname not in fixturedef.argnames: + break + + # Try next super fixture, if any. + + def pytest_collection_modifyitems(self, items: list[nodes.Item]) -> None: + # Separate parametrized setups. + items[:] = reorder_items(items) + + def _register_fixture( + self, + *, + name: str, + func: _FixtureFunc[object], + nodeid: str | None, + scope: Scope | _ScopeName | Callable[[str, Config], _ScopeName] = "function", + params: Sequence[object] | None = None, + ids: tuple[object | None, ...] | Callable[[Any], object | None] | None = None, + autouse: bool = False, + ) -> None: + """Register a fixture + + :param name: + The fixture's name. + :param func: + The fixture's implementation function. + :param nodeid: + The visibility of the fixture. The fixture will be available to the + node with this nodeid and its children in the collection tree. + None means that the fixture is visible to the entire collection tree, + e.g. a fixture defined for general use in a plugin. + :param scope: + The fixture's scope. + :param params: + The fixture's parametrization params. + :param ids: + The fixture's IDs. + :param autouse: + Whether this is an autouse fixture. + """ + fixture_def = FixtureDef( + config=self.config, + baseid=nodeid, + argname=name, + func=func, + scope=scope, + params=params, + ids=ids, + _ispytest=True, + _autouse=autouse, + ) + + faclist = self._arg2fixturedefs.setdefault(name, []) + if fixture_def.has_location: + faclist.append(fixture_def) + else: + # fixturedefs with no location are at the front + # so this inserts the current fixturedef after the + # existing fixturedefs from external plugins but + # before the fixturedefs provided in conftests. + i = len([f for f in faclist if not f.has_location]) + faclist.insert(i, fixture_def) + if autouse: + self._nodeid_autousenames.setdefault(nodeid or "", []).append(name) + + @overload + def parsefactories( + self, + node_or_obj: nodes.Node, + ) -> None: + raise NotImplementedError() + + @overload + def parsefactories( + self, + node_or_obj: object, + nodeid: str | None, + ) -> None: + raise NotImplementedError() + + def parsefactories( + self, + node_or_obj: nodes.Node | object, + nodeid: str | NotSetType | None = NOTSET, + ) -> None: + """Collect fixtures from a collection node or object. + + Found fixtures are parsed into `FixtureDef`s and saved. + + If `node_or_object` is a collection node (with an underlying Python + object), the node's object is traversed and the node's nodeid is used to + determine the fixtures' visibility. `nodeid` must not be specified in + this case. + + If `node_or_object` is an object (e.g. a plugin), the object is + traversed and the given `nodeid` is used to determine the fixtures' + visibility. `nodeid` must be specified in this case; None and "" mean + total visibility. + """ + if nodeid is not NOTSET: + holderobj = node_or_obj + else: + assert isinstance(node_or_obj, nodes.Node) + holderobj = cast(object, node_or_obj.obj) # type: ignore[attr-defined] + assert isinstance(node_or_obj.nodeid, str) + nodeid = node_or_obj.nodeid + if holderobj in self._holderobjseen: + return + + # Avoid accessing `@property` (and other descriptors) when iterating fixtures. + if not safe_isclass(holderobj) and not isinstance(holderobj, types.ModuleType): + holderobj_tp: object = type(holderobj) + else: + holderobj_tp = holderobj + + self._holderobjseen.add(holderobj) + for name in dir(holderobj): + # The attribute can be an arbitrary descriptor, so the attribute + # access below can raise. safe_getattr() ignores such exceptions. + obj_ub = safe_getattr(holderobj_tp, name, None) + if type(obj_ub) is FixtureFunctionDefinition: + marker = obj_ub._fixture_function_marker + if marker.name: + fixture_name = marker.name + else: + fixture_name = name + + # OK we know it is a fixture -- now safe to look up on the _instance_. + try: + obj = getattr(holderobj, name) + # if the fixture is named in the decorator we cannot find it in the module + except AttributeError: + obj = obj_ub + + func = obj._get_wrapped_function() + + self._register_fixture( + name=fixture_name, + nodeid=nodeid, + func=func, + scope=marker.scope, + params=marker.params, + ids=marker.ids, + autouse=marker.autouse, + ) + + def getfixturedefs( + self, argname: str, node: nodes.Node + ) -> Sequence[FixtureDef[Any]] | None: + """Get FixtureDefs for a fixture name which are applicable + to a given node. + + Returns None if there are no fixtures at all defined with the given + name. (This is different from the case in which there are fixtures + with the given name, but none applicable to the node. In this case, + an empty result is returned). + + :param argname: Name of the fixture to search for. + :param node: The requesting Node. + """ + try: + fixturedefs = self._arg2fixturedefs[argname] + except KeyError: + return None + return tuple(self._matchfactories(fixturedefs, node)) + + def _matchfactories( + self, fixturedefs: Iterable[FixtureDef[Any]], node: nodes.Node + ) -> Iterator[FixtureDef[Any]]: + parentnodeids = {n.nodeid for n in node.iter_parents()} + for fixturedef in fixturedefs: + if fixturedef.baseid in parentnodeids: + yield fixturedef + + +def show_fixtures_per_test(config: Config) -> int | ExitCode: + from _pytest.main import wrap_session + + return wrap_session(config, _show_fixtures_per_test) + + +_PYTEST_DIR = Path(_pytest.__file__).parent + + +def _pretty_fixture_path(invocation_dir: Path, func) -> str: + loc = Path(getlocation(func, invocation_dir)) + prefix = Path("...", "_pytest") + try: + return str(prefix / loc.relative_to(_PYTEST_DIR)) + except ValueError: + return bestrelpath(invocation_dir, loc) + + +def _show_fixtures_per_test(config: Config, session: Session) -> None: + import _pytest.config + + session.perform_collect() + invocation_dir = config.invocation_params.dir + tw = _pytest.config.create_terminal_writer(config) + verbose = config.get_verbosity() + + def get_best_relpath(func) -> str: + loc = getlocation(func, invocation_dir) + return bestrelpath(invocation_dir, Path(loc)) + + def write_fixture(fixture_def: FixtureDef[object]) -> None: + argname = fixture_def.argname + if verbose <= 0 and argname.startswith("_"): + return + prettypath = _pretty_fixture_path(invocation_dir, fixture_def.func) + tw.write(f"{argname}", green=True) + tw.write(f" -- {prettypath}", yellow=True) + tw.write("\n") + fixture_doc = inspect.getdoc(fixture_def.func) + if fixture_doc: + write_docstring( + tw, + fixture_doc.split("\n\n", maxsplit=1)[0] + if verbose <= 0 + else fixture_doc, + ) + else: + tw.line(" no docstring available", red=True) + + def write_item(item: nodes.Item) -> None: + # Not all items have _fixtureinfo attribute. + info: FuncFixtureInfo | None = getattr(item, "_fixtureinfo", None) + if info is None or not info.name2fixturedefs: + # This test item does not use any fixtures. + return + tw.line() + tw.sep("-", f"fixtures used by {item.name}") + # TODO: Fix this type ignore. + tw.sep("-", f"({get_best_relpath(item.function)})") # type: ignore[attr-defined] + # dict key not used in loop but needed for sorting. + for _, fixturedefs in sorted(info.name2fixturedefs.items()): + assert fixturedefs is not None + if not fixturedefs: + continue + # Last item is expected to be the one used by the test item. + write_fixture(fixturedefs[-1]) + + for session_item in session.items: + write_item(session_item) + + +def showfixtures(config: Config) -> int | ExitCode: + from _pytest.main import wrap_session + + return wrap_session(config, _showfixtures_main) + + +def _showfixtures_main(config: Config, session: Session) -> None: + import _pytest.config + + session.perform_collect() + invocation_dir = config.invocation_params.dir + tw = _pytest.config.create_terminal_writer(config) + verbose = config.get_verbosity() + + fm = session._fixturemanager + + available = [] + seen: set[tuple[str, str]] = set() + + for argname, fixturedefs in fm._arg2fixturedefs.items(): + assert fixturedefs is not None + if not fixturedefs: + continue + for fixturedef in fixturedefs: + loc = getlocation(fixturedef.func, invocation_dir) + if (fixturedef.argname, loc) in seen: + continue + seen.add((fixturedef.argname, loc)) + available.append( + ( + len(fixturedef.baseid), + fixturedef.func.__module__, + _pretty_fixture_path(invocation_dir, fixturedef.func), + fixturedef.argname, + fixturedef, + ) + ) + + available.sort() + currentmodule = None + for baseid, module, prettypath, argname, fixturedef in available: + if currentmodule != module: + if not module.startswith("_pytest."): + tw.line() + tw.sep("-", f"fixtures defined from {module}") + currentmodule = module + if verbose <= 0 and argname.startswith("_"): + continue + tw.write(f"{argname}", green=True) + if fixturedef.scope != "function": + tw.write(f" [{fixturedef.scope} scope]", cyan=True) + tw.write(f" -- {prettypath}", yellow=True) + tw.write("\n") + doc = inspect.getdoc(fixturedef.func) + if doc: + write_docstring( + tw, doc.split("\n\n", maxsplit=1)[0] if verbose <= 0 else doc + ) + else: + tw.line(" no docstring available", red=True) + tw.line() + + +def write_docstring(tw: TerminalWriter, doc: str, indent: str = " ") -> None: + for line in doc.split("\n"): + tw.line(indent + line) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/freeze_support.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/freeze_support.py new file mode 100644 index 0000000000000000000000000000000000000000..959ff071d86be285aecf76a1c49c1e5de27c5cd2 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/freeze_support.py @@ -0,0 +1,45 @@ +"""Provides a function to report all internal modules for using freezing +tools.""" + +from __future__ import annotations + +from collections.abc import Iterator +import types + + +def freeze_includes() -> list[str]: + """Return a list of module names used by pytest that should be + included by cx_freeze.""" + import _pytest + + result = list(_iter_all_modules(_pytest)) + return result + + +def _iter_all_modules( + package: str | types.ModuleType, + prefix: str = "", +) -> Iterator[str]: + """Iterate over the names of all modules that can be found in the given + package, recursively. + + >>> import _pytest + >>> list(_iter_all_modules(_pytest)) + ['_pytest._argcomplete', '_pytest._code.code', ...] + """ + import os + import pkgutil + + if isinstance(package, str): + path = package + else: + # Type ignored because typeshed doesn't define ModuleType.__path__ + # (only defined on packages). + package_path = package.__path__ + path, prefix = package_path[0], package.__name__ + "." + for _, name, is_package in pkgutil.iter_modules([path]): + if is_package: + for m in _iter_all_modules(os.path.join(path, name), prefix=name + "."): + yield prefix + m + else: + yield prefix + name diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/helpconfig.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/helpconfig.py new file mode 100644 index 0000000000000000000000000000000000000000..6a22c9f58ac9b01197195f3cead4764af0adf349 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/helpconfig.py @@ -0,0 +1,293 @@ +# mypy: allow-untyped-defs +"""Version info, help messages, tracing configuration.""" + +from __future__ import annotations + +import argparse +from collections.abc import Generator +from collections.abc import Sequence +import os +import sys +from typing import Any + +from _pytest.config import Config +from _pytest.config import ExitCode +from _pytest.config import PrintHelp +from _pytest.config.argparsing import Parser +from _pytest.terminal import TerminalReporter +import pytest + + +class HelpAction(argparse.Action): + """An argparse Action that will raise a PrintHelp exception in order to skip + the rest of the argument parsing when --help is passed. + + This prevents argparse from raising UsageError when `--help` is used along + with missing required arguments when any are defined, for example by + ``pytest_addoption``. This is similar to the way that the builtin argparse + --help option is implemented by raising SystemExit. + + To opt in to this behavior, the parse caller must set + `namespace._raise_print_help = True`. Otherwise it just sets the option. + """ + + def __init__( + self, option_strings: Sequence[str], dest: str, *, help: str | None = None + ) -> None: + super().__init__( + option_strings=option_strings, + dest=dest, + nargs=0, + const=True, + default=False, + help=help, + ) + + def __call__( + self, + parser: argparse.ArgumentParser, + namespace: argparse.Namespace, + values: str | Sequence[Any] | None, + option_string: str | None = None, + ) -> None: + setattr(namespace, self.dest, self.const) + + if getattr(namespace, "_raise_print_help", False): + raise PrintHelp + + +def pytest_addoption(parser: Parser) -> None: + group = parser.getgroup("debugconfig") + group.addoption( + "--version", + "-V", + action="count", + default=0, + dest="version", + help="Display pytest version and information about plugins. " + "When given twice, also display information about plugins.", + ) + group._addoption( # private to use reserved lower-case short option + "-h", + "--help", + action=HelpAction, + dest="help", + help="Show help message and configuration info", + ) + group._addoption( # private to use reserved lower-case short option + "-p", + action="append", + dest="plugins", + default=[], + metavar="name", + help="Early-load given plugin module name or entry point (multi-allowed). " + "To avoid loading of plugins, use the `no:` prefix, e.g. " + "`no:doctest`. See also --disable-plugin-autoload.", + ) + group.addoption( + "--disable-plugin-autoload", + action="store_true", + default=False, + help="Disable plugin auto-loading through entry point packaging metadata. " + "Only plugins explicitly specified in -p or env var PYTEST_PLUGINS will be loaded.", + ) + group.addoption( + "--traceconfig", + "--trace-config", + action="store_true", + default=False, + help="Trace considerations of conftest.py files", + ) + group.addoption( + "--debug", + action="store", + nargs="?", + const="pytestdebug.log", + dest="debug", + metavar="DEBUG_FILE_NAME", + help="Store internal tracing debug information in this log file. " + "This file is opened with 'w' and truncated as a result, care advised. " + "Default: pytestdebug.log.", + ) + group._addoption( # private to use reserved lower-case short option + "-o", + "--override-ini", + dest="override_ini", + action="append", + help='Override configuration option with "option=value" style, ' + "e.g. `-o strict_xfail=True -o cache_dir=cache`.", + ) + + +@pytest.hookimpl(wrapper=True) +def pytest_cmdline_parse() -> Generator[None, Config, Config]: + config = yield + + if config.option.debug: + # --debug | --debug <file.log> was provided. + path = config.option.debug + debugfile = open(path, "w", encoding="utf-8") + debugfile.write( + "versions pytest-{}, " + "python-{}\ninvocation_dir={}\ncwd={}\nargs={}\n\n".format( + pytest.__version__, + ".".join(map(str, sys.version_info)), + config.invocation_params.dir, + os.getcwd(), + config.invocation_params.args, + ) + ) + config.trace.root.setwriter(debugfile.write) + undo_tracing = config.pluginmanager.enable_tracing() + sys.stderr.write(f"writing pytest debug information to {path}\n") + + def unset_tracing() -> None: + debugfile.close() + sys.stderr.write(f"wrote pytest debug information to {debugfile.name}\n") + config.trace.root.setwriter(None) + undo_tracing() + + config.add_cleanup(unset_tracing) + + return config + + +def show_version_verbose(config: Config) -> None: + """Show verbose pytest version installation, including plugins.""" + sys.stdout.write( + f"This is pytest version {pytest.__version__}, imported from {pytest.__file__}\n" + ) + plugininfo = getpluginversioninfo(config) + if plugininfo: + for line in plugininfo: + sys.stdout.write(line + "\n") + + +def pytest_cmdline_main(config: Config) -> int | ExitCode | None: + # Note: a single `--version` argument is handled directly by `Config.main()` to avoid starting up the entire + # pytest infrastructure just to display the version (#13574). + if config.option.version > 1: + show_version_verbose(config) + return ExitCode.OK + elif config.option.help: + config._do_configure() + showhelp(config) + config._ensure_unconfigure() + return ExitCode.OK + return None + + +def showhelp(config: Config) -> None: + import textwrap + + reporter: TerminalReporter | None = config.pluginmanager.get_plugin( + "terminalreporter" + ) + assert reporter is not None + tw = reporter._tw + tw.write(config._parser.optparser.format_help()) + tw.line() + tw.line( + "[pytest] configuration options in the first " + "pytest.toml|pytest.ini|tox.ini|setup.cfg|pyproject.toml file found:" + ) + tw.line() + + columns = tw.fullwidth # costly call + indent_len = 24 # based on argparse's max_help_position=24 + indent = " " * indent_len + for name in config._parser._inidict: + help, type, _default = config._parser._inidict[name] + if help is None: + raise TypeError(f"help argument cannot be None for {name}") + spec = f"{name} ({type}):" + tw.write(f" {spec}") + spec_len = len(spec) + if spec_len > (indent_len - 3): + # Display help starting at a new line. + tw.line() + helplines = textwrap.wrap( + help, + columns, + initial_indent=indent, + subsequent_indent=indent, + break_on_hyphens=False, + ) + + for line in helplines: + tw.line(line) + else: + # Display help starting after the spec, following lines indented. + tw.write(" " * (indent_len - spec_len - 2)) + wrapped = textwrap.wrap(help, columns - indent_len, break_on_hyphens=False) + + if wrapped: + tw.line(wrapped[0]) + for line in wrapped[1:]: + tw.line(indent + line) + + tw.line() + tw.line("Environment variables:") + vars = [ + ( + "CI", + "When set to a non-empty value, pytest knows it is running in a " + "CI process and does not truncate summary info", + ), + ("BUILD_NUMBER", "Equivalent to CI"), + ("PYTEST_ADDOPTS", "Extra command line options"), + ("PYTEST_PLUGINS", "Comma-separated plugins to load during startup"), + ("PYTEST_DISABLE_PLUGIN_AUTOLOAD", "Set to disable plugin auto-loading"), + ("PYTEST_DEBUG", "Set to enable debug tracing of pytest's internals"), + ("PYTEST_DEBUG_TEMPROOT", "Override the system temporary directory"), + ("PYTEST_THEME", "The Pygments style to use for code output"), + ("PYTEST_THEME_MODE", "Set the PYTEST_THEME to be either 'dark' or 'light'"), + ] + for name, help in vars: + tw.line(f" {name:<24} {help}") + tw.line() + tw.line() + + tw.line("to see available markers type: pytest --markers") + tw.line("to see available fixtures type: pytest --fixtures") + tw.line( + "(shown according to specified file_or_dir or current dir " + "if not specified; fixtures with leading '_' are only shown " + "with the '-v' option" + ) + + for warningreport in reporter.stats.get("warnings", []): + tw.line("warning : " + warningreport.message, red=True) + + +def getpluginversioninfo(config: Config) -> list[str]: + lines = [] + plugininfo = config.pluginmanager.list_plugin_distinfo() + if plugininfo: + lines.append("registered third-party plugins:") + for plugin, dist in plugininfo: + loc = getattr(plugin, "__file__", repr(plugin)) + content = f"{dist.project_name}-{dist.version} at {loc}" + lines.append(" " + content) + return lines + + +def pytest_report_header(config: Config) -> list[str]: + lines = [] + if config.option.debug or config.option.traceconfig: + lines.append(f"using: pytest-{pytest.__version__}") + + verinfo = getpluginversioninfo(config) + if verinfo: + lines.extend(verinfo) + + if config.option.traceconfig: + lines.append("active plugins:") + items = config.pluginmanager.list_name_plugin() + for name, plugin in items: + if hasattr(plugin, "__file__"): + r = plugin.__file__ + else: + r = repr(plugin) + lines.append(f" {name:<20}: {r}") + return lines diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/hookspec.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/hookspec.py new file mode 100644 index 0000000000000000000000000000000000000000..dab3fb698a2be9c8c9873910893430d9b5e67667 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/hookspec.py @@ -0,0 +1,1342 @@ +# mypy: allow-untyped-defs +# ruff: noqa: T100 +"""Hook specifications for pytest plugins which are invoked by pytest itself +and by builtin plugins.""" + +from __future__ import annotations + +from collections.abc import Mapping +from collections.abc import Sequence +from pathlib import Path +from typing import Any +from typing import TYPE_CHECKING + +from pluggy import HookspecMarker + +from .deprecated import HOOK_LEGACY_PATH_ARG + + +if TYPE_CHECKING: + import pdb + from typing import Literal + import warnings + + from _pytest._code.code import ExceptionInfo + from _pytest._code.code import ExceptionRepr + from _pytest.compat import LEGACY_PATH + from _pytest.config import _PluggyPlugin + from _pytest.config import Config + from _pytest.config import ExitCode + from _pytest.config import PytestPluginManager + from _pytest.config.argparsing import Parser + from _pytest.fixtures import FixtureDef + from _pytest.fixtures import SubRequest + from _pytest.main import Session + from _pytest.nodes import Collector + from _pytest.nodes import Item + from _pytest.outcomes import Exit + from _pytest.python import Class + from _pytest.python import Function + from _pytest.python import Metafunc + from _pytest.python import Module + from _pytest.reports import CollectReport + from _pytest.reports import TestReport + from _pytest.runner import CallInfo + from _pytest.terminal import TerminalReporter + from _pytest.terminal import TestShortLogReport + + +hookspec = HookspecMarker("pytest") + +# ------------------------------------------------------------------------- +# Initialization hooks called for every plugin +# ------------------------------------------------------------------------- + + +@hookspec(historic=True) +def pytest_addhooks(pluginmanager: PytestPluginManager) -> None: + """Called at plugin registration time to allow adding new hooks via a call to + :func:`pluginmanager.add_hookspecs(module_or_class, prefix) <pytest.PytestPluginManager.add_hookspecs>`. + + :param pluginmanager: The pytest plugin manager. + + .. note:: + This hook is incompatible with hook wrappers. + + Use in conftest plugins + ======================= + + If a conftest plugin implements this hook, it will be called immediately + when the conftest is registered. + """ + + +@hookspec(historic=True) +def pytest_plugin_registered( + plugin: _PluggyPlugin, + plugin_name: str, + manager: PytestPluginManager, +) -> None: + """A new pytest plugin got registered. + + :param plugin: The plugin module or instance. + :param plugin_name: The name by which the plugin is registered. + :param manager: The pytest plugin manager. + + .. note:: + This hook is incompatible with hook wrappers. + + Use in conftest plugins + ======================= + + If a conftest plugin implements this hook, it will be called immediately + when the conftest is registered, once for each plugin registered thus far + (including itself!), and for all plugins thereafter when they are + registered. + """ + + +@hookspec(historic=True) +def pytest_addoption(parser: Parser, pluginmanager: PytestPluginManager) -> None: + """Register argparse-style options and config-style config values, + called once at the beginning of a test run. + + :param parser: + To add command line options, call + :py:func:`parser.addoption(...) <pytest.Parser.addoption>`. + To add config-file values call :py:func:`parser.addini(...) + <pytest.Parser.addini>`. + + :param pluginmanager: + The pytest plugin manager, which can be used to install :py:func:`~pytest.hookspec`'s + or :py:func:`~pytest.hookimpl`'s and allow one plugin to call another plugin's hooks + to change how command line options are added. + + Options can later be accessed through the + :py:class:`config <pytest.Config>` object, respectively: + + - :py:func:`config.getoption(name) <pytest.Config.getoption>` to + retrieve the value of a command line option. + + - :py:func:`config.getini(name) <pytest.Config.getini>` to retrieve + a value read from a configuration file. + + The config object is passed around on many internal objects via the ``.config`` + attribute or can be retrieved as the ``pytestconfig`` fixture. + + .. note:: + This hook is incompatible with hook wrappers. + + Use in conftest plugins + ======================= + + If a conftest plugin implements this hook, it will be called immediately + when the conftest is registered. + + This hook is only called for :ref:`initial conftests <pluginorder>`. + """ + + +@hookspec(historic=True) +def pytest_configure(config: Config) -> None: + """Allow plugins and conftest files to perform initial configuration. + + .. note:: + This hook is incompatible with hook wrappers. + + :param config: The pytest config object. + + Use in conftest plugins + ======================= + + This hook is called for every :ref:`initial conftest <pluginorder>` file + after command line options have been parsed. After that, the hook is called + for other conftest files as they are registered. + """ + + +# ------------------------------------------------------------------------- +# Bootstrapping hooks called for plugins registered early enough: +# internal and 3rd party plugins. +# ------------------------------------------------------------------------- + + +@hookspec(firstresult=True) +def pytest_cmdline_parse( + pluginmanager: PytestPluginManager, args: list[str] +) -> Config | None: + """Return an initialized :class:`~pytest.Config`, parsing the specified args. + + Stops at first non-None result, see :ref:`firstresult`. + + .. note:: + This hook is only called for plugin classes passed to the + ``plugins`` arg when using `pytest.main`_ to perform an in-process + test run. + + :param pluginmanager: The pytest plugin manager. + :param args: List of arguments passed on the command line. + :returns: A pytest config object. + + Use in conftest plugins + ======================= + + This hook is not called for conftest files. + """ + + +def pytest_load_initial_conftests( + early_config: Config, parser: Parser, args: list[str] +) -> None: + """Called to implement the loading of :ref:`initial conftest files + <pluginorder>` ahead of command line option parsing. + + :param early_config: The pytest config object. + :param args: Arguments passed on the command line. + :param parser: To add command line options. + + Use in conftest plugins + ======================= + + This hook is not called for conftest files. + """ + + +@hookspec(firstresult=True) +def pytest_cmdline_main(config: Config) -> ExitCode | int | None: + """Called for performing the main command line action. + + The default implementation will invoke the configure hooks and + :hook:`pytest_runtestloop`. + + Stops at first non-None result, see :ref:`firstresult`. + + :param config: The pytest config object. + :returns: The exit code. + + Use in conftest plugins + ======================= + + This hook is only called for :ref:`initial conftests <pluginorder>`. + """ + + +# ------------------------------------------------------------------------- +# collection hooks +# ------------------------------------------------------------------------- + + +@hookspec(firstresult=True) +def pytest_collection(session: Session) -> object | None: + """Perform the collection phase for the given session. + + Stops at first non-None result, see :ref:`firstresult`. + The return value is not used, but only stops further processing. + + The default collection phase is this (see individual hooks for full details): + + 1. Starting from ``session`` as the initial collector: + + 1. ``pytest_collectstart(collector)`` + 2. ``report = pytest_make_collect_report(collector)`` + 3. ``pytest_exception_interact(collector, call, report)`` if an interactive exception occurred + 4. For each collected node: + + 1. If an item, ``pytest_itemcollected(item)`` + 2. If a collector, recurse into it. + + 5. ``pytest_collectreport(report)`` + + 2. ``pytest_collection_modifyitems(session, config, items)`` + + 1. ``pytest_deselected(items)`` for any deselected items (may be called multiple times) + + 3. Set ``session.items`` to the list of collected items + 4. ``pytest_collection_finish(session)`` + 5. Set ``session.testscollected`` to the number of collected items + + You can implement this hook to only perform some action before collection, + for example the terminal plugin uses it to start displaying the collection + counter (and returns `None`). + + :param session: The pytest session object. + + Use in conftest plugins + ======================= + + This hook is only called for :ref:`initial conftests <pluginorder>`. + """ + + +def pytest_collection_modifyitems( + session: Session, config: Config, items: list[Item] +) -> None: + """Called after collection has been performed. May filter or re-order + the items in-place. + + When items are deselected (filtered out from ``items``), + the hook :hook:`pytest_deselected` must be called explicitly + with the deselected items to properly notify other plugins, + e.g. with ``config.hook.pytest_deselected(items=deselected_items)``. + + :param session: The pytest session object. + :param config: The pytest config object. + :param items: List of item objects. + + Use in conftest plugins + ======================= + + Any conftest plugin can implement this hook. + """ + + +def pytest_collection_finish(session: Session) -> None: + """Called after collection has been performed and modified. + + :param session: The pytest session object. + + Use in conftest plugins + ======================= + + Any conftest plugin can implement this hook. + """ + + +@hookspec( + firstresult=True, + warn_on_impl_args={ + "path": HOOK_LEGACY_PATH_ARG.format( + pylib_path_arg="path", pathlib_path_arg="collection_path" + ), + }, +) +def pytest_ignore_collect( + collection_path: Path, path: LEGACY_PATH, config: Config +) -> bool | None: + """Return ``True`` to ignore this path for collection. + + Return ``None`` to let other plugins ignore the path for collection. + + Returning ``False`` will forcefully *not* ignore this path for collection, + without giving a chance for other plugins to ignore this path. + + This hook is consulted for all files and directories prior to calling + more specific hooks. + + Stops at first non-None result, see :ref:`firstresult`. + + :param collection_path: The path to analyze. + :type collection_path: pathlib.Path + :param path: The path to analyze (deprecated). + :param config: The pytest config object. + + .. versionchanged:: 7.0.0 + The ``collection_path`` parameter was added as a :class:`pathlib.Path` + equivalent of the ``path`` parameter. The ``path`` parameter + has been deprecated. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given collection path, only + conftest files in parent directories of the collection path are consulted + (if the path is a directory, its own conftest file is *not* consulted - a + directory cannot ignore itself!). + """ + + +@hookspec(firstresult=True) +def pytest_collect_directory(path: Path, parent: Collector) -> Collector | None: + """Create a :class:`~pytest.Collector` for the given directory, or None if + not relevant. + + .. versionadded:: 8.0 + + For best results, the returned collector should be a subclass of + :class:`~pytest.Directory`, but this is not required. + + The new node needs to have the specified ``parent`` as a parent. + + Stops at first non-None result, see :ref:`firstresult`. + + :param path: The path to analyze. + :type path: pathlib.Path + + See :ref:`custom directory collectors` for a simple example of use of this + hook. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given collection path, only + conftest files in parent directories of the collection path are consulted + (if the path is a directory, its own conftest file is *not* consulted - a + directory cannot collect itself!). + """ + + +@hookspec( + warn_on_impl_args={ + "path": HOOK_LEGACY_PATH_ARG.format( + pylib_path_arg="path", pathlib_path_arg="file_path" + ), + }, +) +def pytest_collect_file( + file_path: Path, path: LEGACY_PATH, parent: Collector +) -> Collector | None: + """Create a :class:`~pytest.Collector` for the given path, or None if not relevant. + + For best results, the returned collector should be a subclass of + :class:`~pytest.File`, but this is not required. + + The new node needs to have the specified ``parent`` as a parent. + + :param file_path: The path to analyze. + :type file_path: pathlib.Path + :param path: The path to collect (deprecated). + + .. versionchanged:: 7.0.0 + The ``file_path`` parameter was added as a :class:`pathlib.Path` + equivalent of the ``path`` parameter. The ``path`` parameter + has been deprecated. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given file path, only + conftest files in parent directories of the file path are consulted. + """ + + +# logging hooks for collection + + +def pytest_collectstart(collector: Collector) -> None: + """Collector starts collecting. + + :param collector: + The collector. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given collector, only + conftest files in the collector's directory and its parent directories are + consulted. + """ + + +def pytest_itemcollected(item: Item) -> None: + """We just collected a test item. + + :param item: + The item. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given item, only conftest + files in the item's directory and its parent directories are consulted. + """ + + +def pytest_collectreport(report: CollectReport) -> None: + """Collector finished collecting. + + :param report: + The collect report. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given collector, only + conftest files in the collector's directory and its parent directories are + consulted. + """ + + +def pytest_deselected(items: Sequence[Item]) -> None: + """Called for deselected test items, e.g. by keyword. + + Note that this hook has two integration aspects for plugins: + + - it can be *implemented* to be notified of deselected items + - it must be *called* from :hook:`pytest_collection_modifyitems` + implementations when items are deselected (to properly notify other plugins). + + May be called multiple times. + + :param items: + The items. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. + """ + + +@hookspec(firstresult=True) +def pytest_make_collect_report(collector: Collector) -> CollectReport | None: + """Perform :func:`collector.collect() <pytest.Collector.collect>` and return + a :class:`~pytest.CollectReport`. + + Stops at first non-None result, see :ref:`firstresult`. + + :param collector: + The collector. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given collector, only + conftest files in the collector's directory and its parent directories are + consulted. + """ + + +# ------------------------------------------------------------------------- +# Python test function related hooks +# ------------------------------------------------------------------------- + + +@hookspec( + firstresult=True, + warn_on_impl_args={ + "path": HOOK_LEGACY_PATH_ARG.format( + pylib_path_arg="path", pathlib_path_arg="module_path" + ), + }, +) +def pytest_pycollect_makemodule( + module_path: Path, path: LEGACY_PATH, parent +) -> Module | None: + """Return a :class:`pytest.Module` collector or None for the given path. + + This hook will be called for each matching test module path. + The :hook:`pytest_collect_file` hook needs to be used if you want to + create test modules for files that do not match as a test module. + + Stops at first non-None result, see :ref:`firstresult`. + + :param module_path: The path of the module to collect. + :type module_path: pathlib.Path + :param path: The path of the module to collect (deprecated). + + .. versionchanged:: 7.0.0 + The ``module_path`` parameter was added as a :class:`pathlib.Path` + equivalent of the ``path`` parameter. + + The ``path`` parameter has been deprecated in favor of ``fspath``. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given parent collector, + only conftest files in the collector's directory and its parent directories + are consulted. + """ + + +@hookspec(firstresult=True) +def pytest_pycollect_makeitem( + collector: Module | Class, name: str, obj: object +) -> None | Item | Collector | list[Item | Collector]: + """Return a custom item/collector for a Python object in a module, or None. + + Stops at first non-None result, see :ref:`firstresult`. + + :param collector: + The module/class collector. + :param name: + The name of the object in the module/class. + :param obj: + The object. + :returns: + The created items/collectors. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given collector, only + conftest files in the collector's directory and its parent directories + are consulted. + """ + + +@hookspec(firstresult=True) +def pytest_pyfunc_call(pyfuncitem: Function) -> object | None: + """Call underlying test function. + + Stops at first non-None result, see :ref:`firstresult`. + + :param pyfuncitem: + The function item. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given item, only + conftest files in the item's directory and its parent directories + are consulted. + """ + + +def pytest_generate_tests(metafunc: Metafunc) -> None: + """Generate (multiple) parametrized calls to a test function. + + :param metafunc: + The :class:`~pytest.Metafunc` helper for the test function. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given function definition, + only conftest files in the functions's directory and its parent directories + are consulted. + """ + + +@hookspec(firstresult=True) +def pytest_make_parametrize_id(config: Config, val: object, argname: str) -> str | None: + """Return a user-friendly string representation of the given ``val`` + that will be used by @pytest.mark.parametrize calls, or None if the hook + doesn't know about ``val``. + + The parameter name is available as ``argname``, if required. + + Stops at first non-None result, see :ref:`firstresult`. + + :param config: The pytest config object. + :param val: The parametrized value. + :param argname: The automatic parameter name produced by pytest. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. + """ + + +# ------------------------------------------------------------------------- +# runtest related hooks +# ------------------------------------------------------------------------- + + +@hookspec(firstresult=True) +def pytest_runtestloop(session: Session) -> object | None: + """Perform the main runtest loop (after collection finished). + + The default hook implementation performs the runtest protocol for all items + collected in the session (``session.items``), unless the collection failed + or the ``collectonly`` pytest option is set. + + If at any point :py:func:`pytest.exit` is called, the loop is + terminated immediately. + + If at any point ``session.shouldfail`` or ``session.shouldstop`` are set, the + loop is terminated after the runtest protocol for the current item is finished. + + :param session: The pytest session object. + + Stops at first non-None result, see :ref:`firstresult`. + The return value is not used, but only stops further processing. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. + """ + + +@hookspec(firstresult=True) +def pytest_runtest_protocol(item: Item, nextitem: Item | None) -> object | None: + """Perform the runtest protocol for a single test item. + + The default runtest protocol is this (see individual hooks for full details): + + - ``pytest_runtest_logstart(nodeid, location)`` + + - Setup phase: + - ``call = pytest_runtest_setup(item)`` (wrapped in ``CallInfo(when="setup")``) + - ``report = pytest_runtest_makereport(item, call)`` + - ``pytest_runtest_logreport(report)`` + - ``pytest_exception_interact(call, report)`` if an interactive exception occurred + + - Call phase, if the setup passed and the ``setuponly`` pytest option is not set: + - ``call = pytest_runtest_call(item)`` (wrapped in ``CallInfo(when="call")``) + - ``report = pytest_runtest_makereport(item, call)`` + - ``pytest_runtest_logreport(report)`` + - ``pytest_exception_interact(call, report)`` if an interactive exception occurred + + - Teardown phase: + - ``call = pytest_runtest_teardown(item, nextitem)`` (wrapped in ``CallInfo(when="teardown")``) + - ``report = pytest_runtest_makereport(item, call)`` + - ``pytest_runtest_logreport(report)`` + - ``pytest_exception_interact(call, report)`` if an interactive exception occurred + + - ``pytest_runtest_logfinish(nodeid, location)`` + + :param item: Test item for which the runtest protocol is performed. + :param nextitem: The scheduled-to-be-next test item (or None if this is the end my friend). + + Stops at first non-None result, see :ref:`firstresult`. + The return value is not used, but only stops further processing. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. + """ + + +def pytest_runtest_logstart(nodeid: str, location: tuple[str, int | None, str]) -> None: + """Called at the start of running the runtest protocol for a single item. + + See :hook:`pytest_runtest_protocol` for a description of the runtest protocol. + + :param nodeid: Full node ID of the item. + :param location: A tuple of ``(filename, lineno, testname)`` + where ``filename`` is a file path relative to ``config.rootpath`` + and ``lineno`` is 0-based. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given item, only conftest + files in the item's directory and its parent directories are consulted. + """ + + +def pytest_runtest_logfinish( + nodeid: str, location: tuple[str, int | None, str] +) -> None: + """Called at the end of running the runtest protocol for a single item. + + See :hook:`pytest_runtest_protocol` for a description of the runtest protocol. + + :param nodeid: Full node ID of the item. + :param location: A tuple of ``(filename, lineno, testname)`` + where ``filename`` is a file path relative to ``config.rootpath`` + and ``lineno`` is 0-based. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given item, only conftest + files in the item's directory and its parent directories are consulted. + """ + + +def pytest_runtest_setup(item: Item) -> None: + """Called to perform the setup phase for a test item. + + The default implementation runs ``setup()`` on ``item`` and all of its + parents (which haven't been setup yet). This includes obtaining the + values of fixtures required by the item (which haven't been obtained + yet). + + :param item: + The item. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given item, only conftest + files in the item's directory and its parent directories are consulted. + """ + + +def pytest_runtest_call(item: Item) -> None: + """Called to run the test for test item (the call phase). + + The default implementation calls ``item.runtest()``. + + :param item: + The item. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given item, only conftest + files in the item's directory and its parent directories are consulted. + """ + + +def pytest_runtest_teardown(item: Item, nextitem: Item | None) -> None: + """Called to perform the teardown phase for a test item. + + The default implementation runs the finalizers and calls ``teardown()`` + on ``item`` and all of its parents (which need to be torn down). This + includes running the teardown phase of fixtures required by the item (if + they go out of scope). + + :param item: + The item. + :param nextitem: + The scheduled-to-be-next test item (None if no further test item is + scheduled). This argument is used to perform exact teardowns, i.e. + calling just enough finalizers so that nextitem only needs to call + setup functions. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given item, only conftest + files in the item's directory and its parent directories are consulted. + """ + + +@hookspec(firstresult=True) +def pytest_runtest_makereport(item: Item, call: CallInfo[None]) -> TestReport | None: + """Called to create a :class:`~pytest.TestReport` for each of + the setup, call and teardown runtest phases of a test item. + + See :hook:`pytest_runtest_protocol` for a description of the runtest protocol. + + :param item: The item. + :param call: The :class:`~pytest.CallInfo` for the phase. + + Stops at first non-None result, see :ref:`firstresult`. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given item, only conftest + files in the item's directory and its parent directories are consulted. + """ + + +def pytest_runtest_logreport(report: TestReport) -> None: + """Process the :class:`~pytest.TestReport` produced for each + of the setup, call and teardown runtest phases of an item. + + See :hook:`pytest_runtest_protocol` for a description of the runtest protocol. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given item, only conftest + files in the item's directory and its parent directories are consulted. + """ + + +@hookspec(firstresult=True) +def pytest_report_to_serializable( + config: Config, + report: CollectReport | TestReport, +) -> dict[str, Any] | None: + """Serialize the given report object into a data structure suitable for + sending over the wire, e.g. converted to JSON. + + :param config: The pytest config object. + :param report: The report. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. The exact details may depend + on the plugin which calls the hook. + """ + + +@hookspec(firstresult=True) +def pytest_report_from_serializable( + config: Config, + data: dict[str, Any], +) -> CollectReport | TestReport | None: + """Restore a report object previously serialized with + :hook:`pytest_report_to_serializable`. + + :param config: The pytest config object. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. The exact details may depend + on the plugin which calls the hook. + """ + + +# ------------------------------------------------------------------------- +# Fixture related hooks +# ------------------------------------------------------------------------- + + +@hookspec(firstresult=True) +def pytest_fixture_setup( + fixturedef: FixtureDef[Any], request: SubRequest +) -> object | None: + """Perform fixture setup execution. + + :param fixturedef: + The fixture definition object. + :param request: + The fixture request object. + :returns: + The return value of the call to the fixture function. + + Stops at first non-None result, see :ref:`firstresult`. + + .. note:: + If the fixture function returns None, other implementations of + this hook function will continue to be called, according to the + behavior of the :ref:`firstresult` option. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given fixture, only + conftest files in the fixture scope's directory and its parent directories + are consulted. + """ + + +def pytest_fixture_post_finalizer( + fixturedef: FixtureDef[Any], request: SubRequest +) -> None: + """Called after fixture teardown, but before the cache is cleared, so + the fixture result ``fixturedef.cached_result`` is still available (not + ``None``). + + :param fixturedef: + The fixture definition object. + :param request: + The fixture request object. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given fixture, only + conftest files in the fixture scope's directory and its parent directories + are consulted. + """ + + +# ------------------------------------------------------------------------- +# test session related hooks +# ------------------------------------------------------------------------- + + +def pytest_sessionstart(session: Session) -> None: + """Called after the ``Session`` object has been created and before performing collection + and entering the run test loop. + + :param session: The pytest session object. + + Use in conftest plugins + ======================= + + This hook is only called for :ref:`initial conftests <pluginorder>`. + """ + + +def pytest_sessionfinish( + session: Session, + exitstatus: int | ExitCode, +) -> None: + """Called after whole test run finished, right before returning the exit status to the system. + + :param session: The pytest session object. + :param exitstatus: The status which pytest will return to the system. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. + """ + + +def pytest_unconfigure(config: Config) -> None: + """Called before test process is exited. + + :param config: The pytest config object. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. + """ + + +# ------------------------------------------------------------------------- +# hooks for customizing the assert methods +# ------------------------------------------------------------------------- + + +def pytest_assertrepr_compare( + config: Config, op: str, left: object, right: object +) -> list[str] | None: + """Return explanation for comparisons in failing assert expressions. + + Return None for no custom explanation, otherwise return a list + of strings. The strings will be joined by newlines but any newlines + *in* a string will be escaped. Note that all but the first line will + be indented slightly, the intention is for the first line to be a summary. + + :param config: The pytest config object. + :param op: The operator, e.g. `"=="`, `"!="`, `"not in"`. + :param left: The left operand. + :param right: The right operand. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given item, only conftest + files in the item's directory and its parent directories are consulted. + """ + + +def pytest_assertion_pass(item: Item, lineno: int, orig: str, expl: str) -> None: + """Called whenever an assertion passes. + + .. versionadded:: 5.0 + + Use this hook to do some processing after a passing assertion. + The original assertion information is available in the `orig` string + and the pytest introspected assertion information is available in the + `expl` string. + + This hook must be explicitly enabled by the :confval:`enable_assertion_pass_hook` + configuration option: + + .. tab:: toml + + .. code-block:: toml + + [pytest] + enable_assertion_pass_hook = true + + .. tab:: ini + + .. code-block:: ini + + [pytest] + enable_assertion_pass_hook = true + + You need to **clean the .pyc** files in your project directory and interpreter libraries + when enabling this option, as assertions will require to be re-written. + + :param item: pytest item object of current test. + :param lineno: Line number of the assert statement. + :param orig: String with the original assertion. + :param expl: String with the assert explanation. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given item, only conftest + files in the item's directory and its parent directories are consulted. + """ + + +# ------------------------------------------------------------------------- +# Hooks for influencing reporting (invoked from _pytest_terminal). +# ------------------------------------------------------------------------- + + +@hookspec( + warn_on_impl_args={ + "startdir": HOOK_LEGACY_PATH_ARG.format( + pylib_path_arg="startdir", pathlib_path_arg="start_path" + ), + }, +) +def pytest_report_header( # type:ignore[empty-body] + config: Config, start_path: Path, startdir: LEGACY_PATH +) -> str | list[str]: + """Return a string or list of strings to be displayed as header info for terminal reporting. + + :param config: The pytest config object. + :param start_path: The starting dir. + :type start_path: pathlib.Path + :param startdir: The starting dir (deprecated). + + .. note:: + + Lines returned by a plugin are displayed before those of plugins which + ran before it. + If you want to have your line(s) displayed first, use + :ref:`trylast=True <plugin-hookorder>`. + + .. versionchanged:: 7.0.0 + The ``start_path`` parameter was added as a :class:`pathlib.Path` + equivalent of the ``startdir`` parameter. The ``startdir`` parameter + has been deprecated. + + Use in conftest plugins + ======================= + + This hook is only called for :ref:`initial conftests <pluginorder>`. + """ + + +@hookspec( + warn_on_impl_args={ + "startdir": HOOK_LEGACY_PATH_ARG.format( + pylib_path_arg="startdir", pathlib_path_arg="start_path" + ), + }, +) +def pytest_report_collectionfinish( # type:ignore[empty-body] + config: Config, + start_path: Path, + startdir: LEGACY_PATH, + items: Sequence[Item], +) -> str | list[str]: + """Return a string or list of strings to be displayed after collection + has finished successfully. + + These strings will be displayed after the standard "collected X items" message. + + .. versionadded:: 3.2 + + :param config: The pytest config object. + :param start_path: The starting dir. + :type start_path: pathlib.Path + :param startdir: The starting dir (deprecated). + :param items: List of pytest items that are going to be executed; this list should not be modified. + + .. note:: + + Lines returned by a plugin are displayed before those of plugins which + ran before it. + If you want to have your line(s) displayed first, use + :ref:`trylast=True <plugin-hookorder>`. + + .. versionchanged:: 7.0.0 + The ``start_path`` parameter was added as a :class:`pathlib.Path` + equivalent of the ``startdir`` parameter. The ``startdir`` parameter + has been deprecated. + + Use in conftest plugins + ======================= + + Any conftest plugin can implement this hook. + """ + + +@hookspec(firstresult=True) +def pytest_report_teststatus( # type:ignore[empty-body] + report: CollectReport | TestReport, config: Config +) -> TestShortLogReport | tuple[str, str, str | tuple[str, Mapping[str, bool]]]: + """Return result-category, shortletter and verbose word for status + reporting. + + The result-category is a category in which to count the result, for + example "passed", "skipped", "error" or the empty string. + + The shortletter is shown as testing progresses, for example ".", "s", + "E" or the empty string. + + The verbose word is shown as testing progresses in verbose mode, for + example "PASSED", "SKIPPED", "ERROR" or the empty string. + + pytest may style these implicitly according to the report outcome. + To provide explicit styling, return a tuple for the verbose word, + for example ``"rerun", "R", ("RERUN", {"yellow": True})``. + + :param report: The report object whose status is to be returned. + :param config: The pytest config object. + :returns: The test status. + + Stops at first non-None result, see :ref:`firstresult`. + + Use in conftest plugins + ======================= + + Any conftest plugin can implement this hook. + """ + + +def pytest_terminal_summary( + terminalreporter: TerminalReporter, + exitstatus: ExitCode, + config: Config, +) -> None: + """Add a section to terminal summary reporting. + + :param terminalreporter: The internal terminal reporter object. + :param exitstatus: The exit status that will be reported back to the OS. + :param config: The pytest config object. + + .. versionadded:: 4.2 + The ``config`` parameter. + + Use in conftest plugins + ======================= + + Any conftest plugin can implement this hook. + """ + + +@hookspec(historic=True) +def pytest_warning_recorded( + warning_message: warnings.WarningMessage, + when: Literal["config", "collect", "runtest"], + nodeid: str, + location: tuple[str, int, str] | None, +) -> None: + """Process a warning captured by the internal pytest warnings plugin. + + :param warning_message: + The captured warning. This is the same object produced by :class:`warnings.catch_warnings`, + and contains the same attributes as the parameters of :py:func:`warnings.showwarning`. + + :param when: + Indicates when the warning was captured. Possible values: + + * ``"config"``: during pytest configuration/initialization stage. + * ``"collect"``: during test collection. + * ``"runtest"``: during test execution. + + :param nodeid: + Full id of the item. Empty string for warnings that are not specific to + a particular node. + + :param location: + When available, holds information about the execution context of the captured + warning (filename, linenumber, function). ``function`` evaluates to <module> + when the execution context is at the module level. + + .. versionadded:: 6.0 + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. If the warning is specific to a + particular node, only conftest files in parent directories of the node are + consulted. + """ + + +# ------------------------------------------------------------------------- +# Hooks for influencing skipping +# ------------------------------------------------------------------------- + + +def pytest_markeval_namespace( # type:ignore[empty-body] + config: Config, +) -> dict[str, Any]: + """Called when constructing the globals dictionary used for + evaluating string conditions in xfail/skipif markers. + + This is useful when the condition for a marker requires + objects that are expensive or impossible to obtain during + collection time, which is required by normal boolean + conditions. + + .. versionadded:: 6.2 + + :param config: The pytest config object. + :returns: A dictionary of additional globals to add. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given item, only conftest + files in parent directories of the item are consulted. + """ + + +# ------------------------------------------------------------------------- +# error handling and internal debugging hooks +# ------------------------------------------------------------------------- + + +def pytest_internalerror( + excrepr: ExceptionRepr, + excinfo: ExceptionInfo[BaseException], +) -> bool | None: + """Called for internal errors. + + Return True to suppress the fallback handling of printing an + INTERNALERROR message directly to sys.stderr. + + :param excrepr: The exception repr object. + :param excinfo: The exception info. + + Use in conftest plugins + ======================= + + Any conftest plugin can implement this hook. + """ + + +def pytest_keyboard_interrupt( + excinfo: ExceptionInfo[KeyboardInterrupt | Exit], +) -> None: + """Called for keyboard interrupt. + + :param excinfo: The exception info. + + Use in conftest plugins + ======================= + + Any conftest plugin can implement this hook. + """ + + +def pytest_exception_interact( + node: Item | Collector, + call: CallInfo[Any], + report: CollectReport | TestReport, +) -> None: + """Called when an exception was raised which can potentially be + interactively handled. + + May be called during collection (see :hook:`pytest_make_collect_report`), + in which case ``report`` is a :class:`~pytest.CollectReport`. + + May be called during runtest of an item (see :hook:`pytest_runtest_protocol`), + in which case ``report`` is a :class:`~pytest.TestReport`. + + This hook is not called if the exception that was raised is an internal + exception like ``skip.Exception``. + + :param node: + The item or collector. + :param call: + The call information. Contains the exception. + :param report: + The collection or test report. + + Use in conftest plugins + ======================= + + Any conftest file can implement this hook. For a given node, only conftest + files in parent directories of the node are consulted. + """ + + +def pytest_enter_pdb(config: Config, pdb: pdb.Pdb) -> None: + """Called upon pdb.set_trace(). + + Can be used by plugins to take special action just before the python + debugger enters interactive mode. + + :param config: The pytest config object. + :param pdb: The Pdb instance. + + Use in conftest plugins + ======================= + + Any conftest plugin can implement this hook. + """ + + +def pytest_leave_pdb(config: Config, pdb: pdb.Pdb) -> None: + """Called when leaving pdb (e.g. with continue after pdb.set_trace()). + + Can be used by plugins to take special action just after the python + debugger leaves interactive mode. + + :param config: The pytest config object. + :param pdb: The Pdb instance. + + Use in conftest plugins + ======================= + + Any conftest plugin can implement this hook. + """ diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/junitxml.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/junitxml.py new file mode 100644 index 0000000000000000000000000000000000000000..ae8d2b94d3672077480b555ce0f03e9e3daa3860 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/junitxml.py @@ -0,0 +1,695 @@ +# mypy: allow-untyped-defs +"""Report test results in JUnit-XML format, for use with Jenkins and build +integration servers. + +Based on initial code from Ross Lawley. + +Output conforms to +https://github.com/jenkinsci/xunit-plugin/blob/master/src/main/resources/org/jenkinsci/plugins/xunit/types/model/xsd/junit-10.xsd +""" + +from __future__ import annotations + +from collections.abc import Callable +import functools +import os +import platform +import re +import xml.etree.ElementTree as ET + +from _pytest import nodes +from _pytest import timing +from _pytest._code.code import ExceptionRepr +from _pytest._code.code import ReprFileLocation +from _pytest.config import Config +from _pytest.config import filename_arg +from _pytest.config.argparsing import Parser +from _pytest.fixtures import FixtureRequest +from _pytest.reports import TestReport +from _pytest.stash import StashKey +from _pytest.terminal import TerminalReporter +import pytest + + +xml_key = StashKey["LogXML"]() + + +def bin_xml_escape(arg: object) -> str: + r"""Visually escape invalid XML characters. + + For example, transforms + 'hello\aworld\b' + into + 'hello#x07world#x08' + Note that the #xABs are *not* XML escapes - missing the ampersand «. + The idea is to escape visually for the user rather than for XML itself. + """ + + def repl(matchobj: re.Match[str]) -> str: + i = ord(matchobj.group()) + if i <= 0xFF: + return f"#x{i:02X}" + else: + return f"#x{i:04X}" + + # The spec range of valid chars is: + # Char ::= #x9 | #xA | #xD | [#x20-#xD7FF] | [#xE000-#xFFFD] | [#x10000-#x10FFFF] + # For an unknown(?) reason, we disallow #x7F (DEL) as well. + illegal_xml_re = ( + "[^\u0009\u000a\u000d\u0020-\u007e\u0080-\ud7ff\ue000-\ufffd\u10000-\u10ffff]" + ) + return re.sub(illegal_xml_re, repl, str(arg)) + + +def merge_family(left, right) -> None: + result = {} + for kl, vl in left.items(): + for kr, vr in right.items(): + if not isinstance(vl, list): + raise TypeError(type(vl)) + result[kl] = vl + vr + left.update(result) + + +families = { # pylint: disable=dict-init-mutate + "_base": {"testcase": ["classname", "name"]}, + "_base_legacy": {"testcase": ["file", "line", "url"]}, +} +# xUnit 1.x inherits legacy attributes. +families["xunit1"] = families["_base"].copy() +merge_family(families["xunit1"], families["_base_legacy"]) + +# xUnit 2.x uses strict base attributes. +families["xunit2"] = families["_base"] + + +class _NodeReporter: + def __init__(self, nodeid: str | TestReport, xml: LogXML) -> None: + self.id = nodeid + self.xml = xml + self.add_stats = self.xml.add_stats + self.family = self.xml.family + self.duration = 0.0 + self.properties: list[tuple[str, str]] = [] + self.nodes: list[ET.Element] = [] + self.attrs: dict[str, str] = {} + + def append(self, node: ET.Element) -> None: + self.xml.add_stats(node.tag) + self.nodes.append(node) + + def add_property(self, name: str, value: object) -> None: + self.properties.append((str(name), bin_xml_escape(value))) + + def add_attribute(self, name: str, value: object) -> None: + self.attrs[str(name)] = bin_xml_escape(value) + + def make_properties_node(self) -> ET.Element | None: + """Return a Junit node containing custom properties, if any.""" + if self.properties: + properties = ET.Element("properties") + for name, value in self.properties: + properties.append(ET.Element("property", name=name, value=value)) + return properties + return None + + def record_testreport(self, testreport: TestReport) -> None: + names = mangle_test_address(testreport.nodeid) + existing_attrs = self.attrs + classnames = names[:-1] + if self.xml.prefix: + classnames.insert(0, self.xml.prefix) + attrs: dict[str, str] = { + "classname": ".".join(classnames), + "name": bin_xml_escape(names[-1]), + "file": testreport.location[0], + } + if testreport.location[1] is not None: + attrs["line"] = str(testreport.location[1]) + if hasattr(testreport, "url"): + attrs["url"] = testreport.url + self.attrs = attrs + self.attrs.update(existing_attrs) # Restore any user-defined attributes. + + # Preserve legacy testcase behavior. + if self.family == "xunit1": + return + + # Filter out attributes not permitted by this test family. + # Including custom attributes because they are not valid here. + temp_attrs = {} + for key in self.attrs: + if key in families[self.family]["testcase"]: + temp_attrs[key] = self.attrs[key] + self.attrs = temp_attrs + + def to_xml(self) -> ET.Element: + testcase = ET.Element("testcase", self.attrs, time=f"{self.duration:.3f}") + properties = self.make_properties_node() + if properties is not None: + testcase.append(properties) + testcase.extend(self.nodes) + return testcase + + def _add_simple(self, tag: str, message: str, data: str | None = None) -> None: + node = ET.Element(tag, message=message) + node.text = bin_xml_escape(data) + self.append(node) + + def write_captured_output(self, report: TestReport) -> None: + if not self.xml.log_passing_tests and report.passed: + return + + content_out = report.capstdout + content_log = report.caplog + content_err = report.capstderr + if self.xml.logging == "no": + return + content_all = "" + if self.xml.logging in ["log", "all"]: + content_all = self._prepare_content(content_log, " Captured Log ") + if self.xml.logging in ["system-out", "out-err", "all"]: + content_all += self._prepare_content(content_out, " Captured Out ") + self._write_content(report, content_all, "system-out") + content_all = "" + if self.xml.logging in ["system-err", "out-err", "all"]: + content_all += self._prepare_content(content_err, " Captured Err ") + self._write_content(report, content_all, "system-err") + content_all = "" + if content_all: + self._write_content(report, content_all, "system-out") + + def _prepare_content(self, content: str, header: str) -> str: + return "\n".join([header.center(80, "-"), content, ""]) + + def _write_content(self, report: TestReport, content: str, jheader: str) -> None: + tag = ET.Element(jheader) + tag.text = bin_xml_escape(content) + self.append(tag) + + def append_pass(self, report: TestReport) -> None: + self.add_stats("passed") + + def append_failure(self, report: TestReport) -> None: + # msg = str(report.longrepr.reprtraceback.extraline) + if hasattr(report, "wasxfail"): + self._add_simple("skipped", "xfail-marked test passes unexpectedly") + else: + assert report.longrepr is not None + reprcrash: ReprFileLocation | None = getattr( + report.longrepr, "reprcrash", None + ) + if reprcrash is not None: + message = reprcrash.message + else: + message = str(report.longrepr) + message = bin_xml_escape(message) + self._add_simple("failure", message, str(report.longrepr)) + + def append_collect_error(self, report: TestReport) -> None: + # msg = str(report.longrepr.reprtraceback.extraline) + assert report.longrepr is not None + self._add_simple("error", "collection failure", str(report.longrepr)) + + def append_collect_skipped(self, report: TestReport) -> None: + self._add_simple("skipped", "collection skipped", str(report.longrepr)) + + def append_error(self, report: TestReport) -> None: + assert report.longrepr is not None + reprcrash: ReprFileLocation | None = getattr(report.longrepr, "reprcrash", None) + if reprcrash is not None: + reason = reprcrash.message + else: + reason = str(report.longrepr) + + if report.when == "teardown": + msg = f'failed on teardown with "{reason}"' + else: + msg = f'failed on setup with "{reason}"' + self._add_simple("error", bin_xml_escape(msg), str(report.longrepr)) + + def append_skipped(self, report: TestReport) -> None: + if hasattr(report, "wasxfail"): + xfailreason = report.wasxfail + if xfailreason.startswith("reason: "): + xfailreason = xfailreason[8:] + xfailreason = bin_xml_escape(xfailreason) + skipped = ET.Element("skipped", type="pytest.xfail", message=xfailreason) + self.append(skipped) + else: + assert isinstance(report.longrepr, tuple) + filename, lineno, skipreason = report.longrepr + if skipreason.startswith("Skipped: "): + skipreason = skipreason[9:] + details = f"{filename}:{lineno}: {skipreason}" + + skipped = ET.Element( + "skipped", type="pytest.skip", message=bin_xml_escape(skipreason) + ) + skipped.text = bin_xml_escape(details) + self.append(skipped) + self.write_captured_output(report) + + def finalize(self) -> None: + data = self.to_xml() + self.__dict__.clear() + # Type ignored because mypy doesn't like overriding a method. + # Also the return value doesn't match... + self.to_xml = lambda: data # type: ignore[method-assign] + + +def _warn_incompatibility_with_xunit2( + request: FixtureRequest, fixture_name: str +) -> None: + """Emit a PytestWarning about the given fixture being incompatible with newer xunit revisions.""" + from _pytest.warning_types import PytestWarning + + xml = request.config.stash.get(xml_key, None) + if xml is not None and xml.family not in ("xunit1", "legacy"): + request.node.warn( + PytestWarning( + f"{fixture_name} is incompatible with junit_family '{xml.family}' (use 'legacy' or 'xunit1')" + ) + ) + + +@pytest.fixture +def record_property(request: FixtureRequest) -> Callable[[str, object], None]: + """Add extra properties to the calling test. + + User properties become part of the test report and are available to the + configured reporters, like JUnit XML. + + The fixture is callable with ``name, value``. The value is automatically + XML-encoded. + + Example:: + + def test_function(record_property): + record_property("example_key", 1) + """ + _warn_incompatibility_with_xunit2(request, "record_property") + + def append_property(name: str, value: object) -> None: + request.node.user_properties.append((name, value)) + + return append_property + + +@pytest.fixture +def record_xml_attribute(request: FixtureRequest) -> Callable[[str, object], None]: + """Add extra xml attributes to the tag for the calling test. + + The fixture is callable with ``name, value``. The value is + automatically XML-encoded. + """ + from _pytest.warning_types import PytestExperimentalApiWarning + + request.node.warn( + PytestExperimentalApiWarning("record_xml_attribute is an experimental feature") + ) + + _warn_incompatibility_with_xunit2(request, "record_xml_attribute") + + # Declare noop + def add_attr_noop(name: str, value: object) -> None: + pass + + attr_func = add_attr_noop + + xml = request.config.stash.get(xml_key, None) + if xml is not None: + node_reporter = xml.node_reporter(request.node.nodeid) + attr_func = node_reporter.add_attribute + + return attr_func + + +def _check_record_param_type(param: str, v: str) -> None: + """Used by record_testsuite_property to check that the given parameter name is of the proper + type.""" + __tracebackhide__ = True + if not isinstance(v, str): + msg = "{param} parameter needs to be a string, but {g} given" # type: ignore[unreachable] + raise TypeError(msg.format(param=param, g=type(v).__name__)) + + +@pytest.fixture(scope="session") +def record_testsuite_property(request: FixtureRequest) -> Callable[[str, object], None]: + """Record a new ``<property>`` tag as child of the root ``<testsuite>``. + + This is suitable to writing global information regarding the entire test + suite, and is compatible with ``xunit2`` JUnit family. + + This is a ``session``-scoped fixture which is called with ``(name, value)``. Example: + + .. code-block:: python + + def test_foo(record_testsuite_property): + record_testsuite_property("ARCH", "PPC") + record_testsuite_property("STORAGE_TYPE", "CEPH") + + :param name: + The property name. + :param value: + The property value. Will be converted to a string. + + .. warning:: + + Currently this fixture **does not work** with the + `pytest-xdist <https://github.com/pytest-dev/pytest-xdist>`__ plugin. See + :issue:`7767` for details. + """ + __tracebackhide__ = True + + def record_func(name: str, value: object) -> None: + """No-op function in case --junit-xml was not passed in the command-line.""" + __tracebackhide__ = True + _check_record_param_type("name", name) + + xml = request.config.stash.get(xml_key, None) + if xml is not None: + record_func = xml.add_global_property + return record_func + + +def pytest_addoption(parser: Parser) -> None: + group = parser.getgroup("terminal reporting") + group.addoption( + "--junitxml", + "--junit-xml", + action="store", + dest="xmlpath", + metavar="path", + type=functools.partial(filename_arg, optname="--junitxml"), + default=None, + help="Create junit-xml style report file at given path", + ) + group.addoption( + "--junitprefix", + "--junit-prefix", + action="store", + metavar="str", + default=None, + help="Prepend prefix to classnames in junit-xml output", + ) + parser.addini( + "junit_suite_name", "Test suite name for JUnit report", default="pytest" + ) + parser.addini( + "junit_logging", + "Write captured log messages to JUnit report: " + "one of no|log|system-out|system-err|out-err|all", + default="no", + ) + parser.addini( + "junit_log_passing_tests", + "Capture log information for passing tests to JUnit report: ", + type="bool", + default=True, + ) + parser.addini( + "junit_duration_report", + "Duration time to report: one of total|call", + default="total", + ) # choices=['total', 'call']) + parser.addini( + "junit_family", + "Emit XML for schema: one of legacy|xunit1|xunit2", + default="xunit2", + ) + + +def pytest_configure(config: Config) -> None: + xmlpath = config.option.xmlpath + # Prevent opening xmllog on worker nodes (xdist). + if xmlpath and not hasattr(config, "workerinput"): + junit_family = config.getini("junit_family") + config.stash[xml_key] = LogXML( + xmlpath, + config.option.junitprefix, + config.getini("junit_suite_name"), + config.getini("junit_logging"), + config.getini("junit_duration_report"), + junit_family, + config.getini("junit_log_passing_tests"), + ) + config.pluginmanager.register(config.stash[xml_key]) + + +def pytest_unconfigure(config: Config) -> None: + xml = config.stash.get(xml_key, None) + if xml: + del config.stash[xml_key] + config.pluginmanager.unregister(xml) + + +def mangle_test_address(address: str) -> list[str]: + path, possible_open_bracket, params = address.partition("[") + names = path.split("::") + # Convert file path to dotted path. + names[0] = names[0].replace(nodes.SEP, ".") + names[0] = re.sub(r"\.py$", "", names[0]) + # Put any params back. + names[-1] += possible_open_bracket + params + return names + + +class LogXML: + def __init__( + self, + logfile, + prefix: str | None, + suite_name: str = "pytest", + logging: str = "no", + report_duration: str = "total", + family="xunit1", + log_passing_tests: bool = True, + ) -> None: + logfile = os.path.expanduser(os.path.expandvars(logfile)) + self.logfile = os.path.normpath(os.path.abspath(logfile)) + self.prefix = prefix + self.suite_name = suite_name + self.logging = logging + self.log_passing_tests = log_passing_tests + self.report_duration = report_duration + self.family = family + self.stats: dict[str, int] = dict.fromkeys( + ["error", "passed", "failure", "skipped"], 0 + ) + self.node_reporters: dict[tuple[str | TestReport, object], _NodeReporter] = {} + self.node_reporters_ordered: list[_NodeReporter] = [] + self.global_properties: list[tuple[str, str]] = [] + + # List of reports that failed on call but teardown is pending. + self.open_reports: list[TestReport] = [] + self.cnt_double_fail_tests = 0 + + # Replaces convenience family with real family. + if self.family == "legacy": + self.family = "xunit1" + + def finalize(self, report: TestReport) -> None: + nodeid = getattr(report, "nodeid", report) + # Local hack to handle xdist report order. + workernode = getattr(report, "node", None) + reporter = self.node_reporters.pop((nodeid, workernode)) + + for propname, propvalue in report.user_properties: + reporter.add_property(propname, str(propvalue)) + + if reporter is not None: + reporter.finalize() + + def node_reporter(self, report: TestReport | str) -> _NodeReporter: + nodeid: str | TestReport = getattr(report, "nodeid", report) + # Local hack to handle xdist report order. + workernode = getattr(report, "node", None) + + key = nodeid, workernode + + if key in self.node_reporters: + # TODO: breaks for --dist=each + return self.node_reporters[key] + + reporter = _NodeReporter(nodeid, self) + + self.node_reporters[key] = reporter + self.node_reporters_ordered.append(reporter) + + return reporter + + def add_stats(self, key: str) -> None: + if key in self.stats: + self.stats[key] += 1 + + def _opentestcase(self, report: TestReport) -> _NodeReporter: + reporter = self.node_reporter(report) + reporter.record_testreport(report) + return reporter + + def pytest_runtest_logreport(self, report: TestReport) -> None: + """Handle a setup/call/teardown report, generating the appropriate + XML tags as necessary. + + Note: due to plugins like xdist, this hook may be called in interlaced + order with reports from other nodes. For example: + + Usual call order: + -> setup node1 + -> call node1 + -> teardown node1 + -> setup node2 + -> call node2 + -> teardown node2 + + Possible call order in xdist: + -> setup node1 + -> call node1 + -> setup node2 + -> call node2 + -> teardown node2 + -> teardown node1 + """ + close_report = None + if report.passed: + if report.when == "call": # ignore setup/teardown + reporter = self._opentestcase(report) + reporter.append_pass(report) + elif report.failed: + if report.when == "teardown": + # The following vars are needed when xdist plugin is used. + report_wid = getattr(report, "worker_id", None) + report_ii = getattr(report, "item_index", None) + close_report = next( + ( + rep + for rep in self.open_reports + if ( + rep.nodeid == report.nodeid + and getattr(rep, "item_index", None) == report_ii + and getattr(rep, "worker_id", None) == report_wid + ) + ), + None, + ) + if close_report: + # We need to open new testcase in case we have failure in + # call and error in teardown in order to follow junit + # schema. + self.finalize(close_report) + self.cnt_double_fail_tests += 1 + reporter = self._opentestcase(report) + if report.when == "call": + reporter.append_failure(report) + self.open_reports.append(report) + if not self.log_passing_tests: + reporter.write_captured_output(report) + else: + reporter.append_error(report) + elif report.skipped: + reporter = self._opentestcase(report) + reporter.append_skipped(report) + self.update_testcase_duration(report) + if report.when == "teardown": + reporter = self._opentestcase(report) + reporter.write_captured_output(report) + + self.finalize(report) + report_wid = getattr(report, "worker_id", None) + report_ii = getattr(report, "item_index", None) + close_report = next( + ( + rep + for rep in self.open_reports + if ( + rep.nodeid == report.nodeid + and getattr(rep, "item_index", None) == report_ii + and getattr(rep, "worker_id", None) == report_wid + ) + ), + None, + ) + if close_report: + self.open_reports.remove(close_report) + + def update_testcase_duration(self, report: TestReport) -> None: + """Accumulate total duration for nodeid from given report and update + the Junit.testcase with the new total if already created.""" + if self.report_duration in {"total", report.when}: + reporter = self.node_reporter(report) + reporter.duration += getattr(report, "duration", 0.0) + + def pytest_collectreport(self, report: TestReport) -> None: + if not report.passed: + reporter = self._opentestcase(report) + if report.failed: + reporter.append_collect_error(report) + else: + reporter.append_collect_skipped(report) + + def pytest_internalerror(self, excrepr: ExceptionRepr) -> None: + reporter = self.node_reporter("internal") + reporter.attrs.update(classname="pytest", name="internal") + reporter._add_simple("error", "internal error", str(excrepr)) + + def pytest_sessionstart(self) -> None: + self.suite_start = timing.Instant() + + def pytest_sessionfinish(self) -> None: + dirname = os.path.dirname(os.path.abspath(self.logfile)) + # exist_ok avoids filesystem race conditions between checking path existence and requesting creation + os.makedirs(dirname, exist_ok=True) + + with open(self.logfile, "w", encoding="utf-8") as logfile: + duration = self.suite_start.elapsed() + + numtests = ( + self.stats["passed"] + + self.stats["failure"] + + self.stats["skipped"] + + self.stats["error"] + - self.cnt_double_fail_tests + ) + logfile.write('<?xml version="1.0" encoding="utf-8"?>') + + suite_node = ET.Element( + "testsuite", + name=self.suite_name, + errors=str(self.stats["error"]), + failures=str(self.stats["failure"]), + skipped=str(self.stats["skipped"]), + tests=str(numtests), + time=f"{duration.seconds:.3f}", + timestamp=self.suite_start.as_utc().astimezone().isoformat(), + hostname=platform.node(), + ) + global_properties = self._get_global_properties_node() + if global_properties is not None: + suite_node.append(global_properties) + for node_reporter in self.node_reporters_ordered: + suite_node.append(node_reporter.to_xml()) + testsuites = ET.Element("testsuites") + testsuites.set("name", "pytest tests") + testsuites.append(suite_node) + logfile.write(ET.tostring(testsuites, encoding="unicode")) + + def pytest_terminal_summary( + self, terminalreporter: TerminalReporter, config: pytest.Config + ) -> None: + if config.get_verbosity() >= 0: + terminalreporter.write_sep("-", f"generated xml file: {self.logfile}") + + def add_global_property(self, name: str, value: object) -> None: + __tracebackhide__ = True + _check_record_param_type("name", name) + self.global_properties.append((name, bin_xml_escape(value))) + + def _get_global_properties_node(self) -> ET.Element | None: + """Return a Junit node containing custom properties, if any.""" + if self.global_properties: + properties = ET.Element("properties") + for name, value in self.global_properties: + properties.append(ET.Element("property", name=name, value=value)) + return properties + return None diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/legacypath.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/legacypath.py new file mode 100644 index 0000000000000000000000000000000000000000..59e8ef6e7427ed2f548c1da72c9acceb82ef31fa --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/legacypath.py @@ -0,0 +1,468 @@ +# mypy: allow-untyped-defs +"""Add backward compatibility support for the legacy py path type.""" + +from __future__ import annotations + +import dataclasses +from pathlib import Path +import shlex +import subprocess +from typing import Final +from typing import final +from typing import TYPE_CHECKING + +from iniconfig import SectionWrapper + +from _pytest.cacheprovider import Cache +from _pytest.compat import LEGACY_PATH +from _pytest.compat import legacy_path +from _pytest.config import Config +from _pytest.config import hookimpl +from _pytest.config import PytestPluginManager +from _pytest.deprecated import check_ispytest +from _pytest.fixtures import fixture +from _pytest.fixtures import FixtureRequest +from _pytest.main import Session +from _pytest.monkeypatch import MonkeyPatch +from _pytest.nodes import Collector +from _pytest.nodes import Item +from _pytest.nodes import Node +from _pytest.pytester import HookRecorder +from _pytest.pytester import Pytester +from _pytest.pytester import RunResult +from _pytest.terminal import TerminalReporter +from _pytest.tmpdir import TempPathFactory + + +if TYPE_CHECKING: + import pexpect + + +@final +class Testdir: + """ + Similar to :class:`Pytester`, but this class works with legacy legacy_path objects instead. + + All methods just forward to an internal :class:`Pytester` instance, converting results + to `legacy_path` objects as necessary. + """ + + __test__ = False + + CLOSE_STDIN: Final = Pytester.CLOSE_STDIN + TimeoutExpired: Final = Pytester.TimeoutExpired + + def __init__(self, pytester: Pytester, *, _ispytest: bool = False) -> None: + check_ispytest(_ispytest) + self._pytester = pytester + + @property + def tmpdir(self) -> LEGACY_PATH: + """Temporary directory where tests are executed.""" + return legacy_path(self._pytester.path) + + @property + def test_tmproot(self) -> LEGACY_PATH: + return legacy_path(self._pytester._test_tmproot) + + @property + def request(self): + return self._pytester._request + + @property + def plugins(self): + return self._pytester.plugins + + @plugins.setter + def plugins(self, plugins): + self._pytester.plugins = plugins + + @property + def monkeypatch(self) -> MonkeyPatch: + return self._pytester._monkeypatch + + def make_hook_recorder(self, pluginmanager) -> HookRecorder: + """See :meth:`Pytester.make_hook_recorder`.""" + return self._pytester.make_hook_recorder(pluginmanager) + + def chdir(self) -> None: + """See :meth:`Pytester.chdir`.""" + return self._pytester.chdir() + + def finalize(self) -> None: + return self._pytester._finalize() + + def makefile(self, ext, *args, **kwargs) -> LEGACY_PATH: + """See :meth:`Pytester.makefile`.""" + if ext and not ext.startswith("."): + # pytester.makefile is going to throw a ValueError in a way that + # testdir.makefile did not, because + # pathlib.Path is stricter suffixes than py.path + # This ext arguments is likely user error, but since testdir has + # allowed this, we will prepend "." as a workaround to avoid breaking + # testdir usage that worked before + ext = "." + ext + return legacy_path(self._pytester.makefile(ext, *args, **kwargs)) + + def makeconftest(self, source) -> LEGACY_PATH: + """See :meth:`Pytester.makeconftest`.""" + return legacy_path(self._pytester.makeconftest(source)) + + def makeini(self, source) -> LEGACY_PATH: + """See :meth:`Pytester.makeini`.""" + return legacy_path(self._pytester.makeini(source)) + + def getinicfg(self, source: str) -> SectionWrapper: + """See :meth:`Pytester.getinicfg`.""" + return self._pytester.getinicfg(source) + + def makepyprojecttoml(self, source) -> LEGACY_PATH: + """See :meth:`Pytester.makepyprojecttoml`.""" + return legacy_path(self._pytester.makepyprojecttoml(source)) + + def makepyfile(self, *args, **kwargs) -> LEGACY_PATH: + """See :meth:`Pytester.makepyfile`.""" + return legacy_path(self._pytester.makepyfile(*args, **kwargs)) + + def maketxtfile(self, *args, **kwargs) -> LEGACY_PATH: + """See :meth:`Pytester.maketxtfile`.""" + return legacy_path(self._pytester.maketxtfile(*args, **kwargs)) + + def syspathinsert(self, path=None) -> None: + """See :meth:`Pytester.syspathinsert`.""" + return self._pytester.syspathinsert(path) + + def mkdir(self, name) -> LEGACY_PATH: + """See :meth:`Pytester.mkdir`.""" + return legacy_path(self._pytester.mkdir(name)) + + def mkpydir(self, name) -> LEGACY_PATH: + """See :meth:`Pytester.mkpydir`.""" + return legacy_path(self._pytester.mkpydir(name)) + + def copy_example(self, name=None) -> LEGACY_PATH: + """See :meth:`Pytester.copy_example`.""" + return legacy_path(self._pytester.copy_example(name)) + + def getnode(self, config: Config, arg) -> Item | Collector | None: + """See :meth:`Pytester.getnode`.""" + return self._pytester.getnode(config, arg) + + def getpathnode(self, path): + """See :meth:`Pytester.getpathnode`.""" + return self._pytester.getpathnode(path) + + def genitems(self, colitems: list[Item | Collector]) -> list[Item]: + """See :meth:`Pytester.genitems`.""" + return self._pytester.genitems(colitems) + + def runitem(self, source): + """See :meth:`Pytester.runitem`.""" + return self._pytester.runitem(source) + + def inline_runsource(self, source, *cmdlineargs): + """See :meth:`Pytester.inline_runsource`.""" + return self._pytester.inline_runsource(source, *cmdlineargs) + + def inline_genitems(self, *args): + """See :meth:`Pytester.inline_genitems`.""" + return self._pytester.inline_genitems(*args) + + def inline_run(self, *args, plugins=(), no_reraise_ctrlc: bool = False): + """See :meth:`Pytester.inline_run`.""" + return self._pytester.inline_run( + *args, plugins=plugins, no_reraise_ctrlc=no_reraise_ctrlc + ) + + def runpytest_inprocess(self, *args, **kwargs) -> RunResult: + """See :meth:`Pytester.runpytest_inprocess`.""" + return self._pytester.runpytest_inprocess(*args, **kwargs) + + def runpytest(self, *args, **kwargs) -> RunResult: + """See :meth:`Pytester.runpytest`.""" + return self._pytester.runpytest(*args, **kwargs) + + def parseconfig(self, *args) -> Config: + """See :meth:`Pytester.parseconfig`.""" + return self._pytester.parseconfig(*args) + + def parseconfigure(self, *args) -> Config: + """See :meth:`Pytester.parseconfigure`.""" + return self._pytester.parseconfigure(*args) + + def getitem(self, source, funcname="test_func"): + """See :meth:`Pytester.getitem`.""" + return self._pytester.getitem(source, funcname) + + def getitems(self, source): + """See :meth:`Pytester.getitems`.""" + return self._pytester.getitems(source) + + def getmodulecol(self, source, configargs=(), withinit=False): + """See :meth:`Pytester.getmodulecol`.""" + return self._pytester.getmodulecol( + source, configargs=configargs, withinit=withinit + ) + + def collect_by_name(self, modcol: Collector, name: str) -> Item | Collector | None: + """See :meth:`Pytester.collect_by_name`.""" + return self._pytester.collect_by_name(modcol, name) + + def popen( + self, + cmdargs, + stdout=subprocess.PIPE, + stderr=subprocess.PIPE, + stdin=CLOSE_STDIN, + **kw, + ): + """See :meth:`Pytester.popen`.""" + return self._pytester.popen(cmdargs, stdout, stderr, stdin, **kw) + + def run(self, *cmdargs, timeout=None, stdin=CLOSE_STDIN) -> RunResult: + """See :meth:`Pytester.run`.""" + return self._pytester.run(*cmdargs, timeout=timeout, stdin=stdin) + + def runpython(self, script) -> RunResult: + """See :meth:`Pytester.runpython`.""" + return self._pytester.runpython(script) + + def runpython_c(self, command): + """See :meth:`Pytester.runpython_c`.""" + return self._pytester.runpython_c(command) + + def runpytest_subprocess(self, *args, timeout=None) -> RunResult: + """See :meth:`Pytester.runpytest_subprocess`.""" + return self._pytester.runpytest_subprocess(*args, timeout=timeout) + + def spawn_pytest(self, string: str, expect_timeout: float = 10.0) -> pexpect.spawn: + """See :meth:`Pytester.spawn_pytest`.""" + return self._pytester.spawn_pytest(string, expect_timeout=expect_timeout) + + def spawn(self, cmd: str, expect_timeout: float = 10.0) -> pexpect.spawn: + """See :meth:`Pytester.spawn`.""" + return self._pytester.spawn(cmd, expect_timeout=expect_timeout) + + def __repr__(self) -> str: + return f"<Testdir {self.tmpdir!r}>" + + def __str__(self) -> str: + return str(self.tmpdir) + + +class LegacyTestdirPlugin: + @staticmethod + @fixture + def testdir(pytester: Pytester) -> Testdir: + """ + Identical to :fixture:`pytester`, and provides an instance whose methods return + legacy ``LEGACY_PATH`` objects instead when applicable. + + New code should avoid using :fixture:`testdir` in favor of :fixture:`pytester`. + """ + return Testdir(pytester, _ispytest=True) + + +@final +@dataclasses.dataclass +class TempdirFactory: + """Backward compatibility wrapper that implements ``py.path.local`` + for :class:`TempPathFactory`. + + .. note:: + These days, it is preferred to use ``tmp_path_factory``. + + :ref:`About the tmpdir and tmpdir_factory fixtures<tmpdir and tmpdir_factory>`. + + """ + + _tmppath_factory: TempPathFactory + + def __init__( + self, tmppath_factory: TempPathFactory, *, _ispytest: bool = False + ) -> None: + check_ispytest(_ispytest) + self._tmppath_factory = tmppath_factory + + def mktemp(self, basename: str, numbered: bool = True) -> LEGACY_PATH: + """Same as :meth:`TempPathFactory.mktemp`, but returns a ``py.path.local`` object.""" + return legacy_path(self._tmppath_factory.mktemp(basename, numbered).resolve()) + + def getbasetemp(self) -> LEGACY_PATH: + """Same as :meth:`TempPathFactory.getbasetemp`, but returns a ``py.path.local`` object.""" + return legacy_path(self._tmppath_factory.getbasetemp().resolve()) + + +class LegacyTmpdirPlugin: + @staticmethod + @fixture(scope="session") + def tmpdir_factory(request: FixtureRequest) -> TempdirFactory: + """Return a :class:`pytest.TempdirFactory` instance for the test session.""" + # Set dynamically by pytest_configure(). + return request.config._tmpdirhandler # type: ignore + + @staticmethod + @fixture + def tmpdir(tmp_path: Path) -> LEGACY_PATH: + """Return a temporary directory (as `legacy_path`_ object) + which is unique to each test function invocation. + The temporary directory is created as a subdirectory + of the base temporary directory, with configurable retention, + as discussed in :ref:`temporary directory location and retention`. + + .. note:: + These days, it is preferred to use ``tmp_path``. + + :ref:`About the tmpdir and tmpdir_factory fixtures<tmpdir and tmpdir_factory>`. + + .. _legacy_path: https://py.readthedocs.io/en/latest/path.html + """ + return legacy_path(tmp_path) + + +def Cache_makedir(self: Cache, name: str) -> LEGACY_PATH: + """Return a directory path object with the given name. + + Same as :func:`mkdir`, but returns a legacy py path instance. + """ + return legacy_path(self.mkdir(name)) + + +def FixtureRequest_fspath(self: FixtureRequest) -> LEGACY_PATH: + """(deprecated) The file system path of the test module which collected this test.""" + return legacy_path(self.path) + + +def TerminalReporter_startdir(self: TerminalReporter) -> LEGACY_PATH: + """The directory from which pytest was invoked. + + Prefer to use ``startpath`` which is a :class:`pathlib.Path`. + + :type: LEGACY_PATH + """ + return legacy_path(self.startpath) + + +def Config_invocation_dir(self: Config) -> LEGACY_PATH: + """The directory from which pytest was invoked. + + Prefer to use :attr:`invocation_params.dir <InvocationParams.dir>`, + which is a :class:`pathlib.Path`. + + :type: LEGACY_PATH + """ + return legacy_path(str(self.invocation_params.dir)) + + +def Config_rootdir(self: Config) -> LEGACY_PATH: + """The path to the :ref:`rootdir <rootdir>`. + + Prefer to use :attr:`rootpath`, which is a :class:`pathlib.Path`. + + :type: LEGACY_PATH + """ + return legacy_path(str(self.rootpath)) + + +def Config_inifile(self: Config) -> LEGACY_PATH | None: + """The path to the :ref:`configfile <configfiles>`. + + Prefer to use :attr:`inipath`, which is a :class:`pathlib.Path`. + + :type: Optional[LEGACY_PATH] + """ + return legacy_path(str(self.inipath)) if self.inipath else None + + +def Session_startdir(self: Session) -> LEGACY_PATH: + """The path from which pytest was invoked. + + Prefer to use ``startpath`` which is a :class:`pathlib.Path`. + + :type: LEGACY_PATH + """ + return legacy_path(self.startpath) + + +def Config__getini_unknown_type(self, name: str, type: str, value: str | list[str]): + if type == "pathlist": + # TODO: This assert is probably not valid in all cases. + assert self.inipath is not None + dp = self.inipath.parent + input_values = shlex.split(value) if isinstance(value, str) else value + return [legacy_path(str(dp / x)) for x in input_values] + else: + raise ValueError(f"unknown configuration type: {type}", value) + + +def Node_fspath(self: Node) -> LEGACY_PATH: + """(deprecated) returns a legacy_path copy of self.path""" + return legacy_path(self.path) + + +def Node_fspath_set(self: Node, value: LEGACY_PATH) -> None: + self.path = Path(value) + + +@hookimpl(tryfirst=True) +def pytest_load_initial_conftests(early_config: Config) -> None: + """Monkeypatch legacy path attributes in several classes, as early as possible.""" + mp = MonkeyPatch() + early_config.add_cleanup(mp.undo) + + # Add Cache.makedir(). + mp.setattr(Cache, "makedir", Cache_makedir, raising=False) + + # Add FixtureRequest.fspath property. + mp.setattr(FixtureRequest, "fspath", property(FixtureRequest_fspath), raising=False) + + # Add TerminalReporter.startdir property. + mp.setattr( + TerminalReporter, "startdir", property(TerminalReporter_startdir), raising=False + ) + + # Add Config.{invocation_dir,rootdir,inifile} properties. + mp.setattr(Config, "invocation_dir", property(Config_invocation_dir), raising=False) + mp.setattr(Config, "rootdir", property(Config_rootdir), raising=False) + mp.setattr(Config, "inifile", property(Config_inifile), raising=False) + + # Add Session.startdir property. + mp.setattr(Session, "startdir", property(Session_startdir), raising=False) + + # Add pathlist configuration type. + mp.setattr(Config, "_getini_unknown_type", Config__getini_unknown_type) + + # Add Node.fspath property. + mp.setattr(Node, "fspath", property(Node_fspath, Node_fspath_set), raising=False) + + +@hookimpl +def pytest_configure(config: Config) -> None: + """Installs the LegacyTmpdirPlugin if the ``tmpdir`` plugin is also installed.""" + if config.pluginmanager.has_plugin("tmpdir"): + mp = MonkeyPatch() + config.add_cleanup(mp.undo) + # Create TmpdirFactory and attach it to the config object. + # + # This is to comply with existing plugins which expect the handler to be + # available at pytest_configure time, but ideally should be moved entirely + # to the tmpdir_factory session fixture. + try: + tmp_path_factory = config._tmp_path_factory # type: ignore[attr-defined] + except AttributeError: + # tmpdir plugin is blocked. + pass + else: + _tmpdirhandler = TempdirFactory(tmp_path_factory, _ispytest=True) + mp.setattr(config, "_tmpdirhandler", _tmpdirhandler, raising=False) + + config.pluginmanager.register(LegacyTmpdirPlugin, "legacypath-tmpdir") + + +@hookimpl +def pytest_plugin_registered(plugin: object, manager: PytestPluginManager) -> None: + # pytester is not loaded by default and is commonly loaded from a conftest, + # so checking for it in `pytest_configure` is not enough. + is_pytester = plugin is manager.get_plugin("pytester") + if is_pytester and not manager.is_registered(LegacyTestdirPlugin): + manager.register(LegacyTestdirPlugin, "legacypath-pytester") diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/logging.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/logging.py new file mode 100644 index 0000000000000000000000000000000000000000..e4fed579d2161da981e1ad2f502577a7a1fe596e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/logging.py @@ -0,0 +1,960 @@ +# mypy: allow-untyped-defs +"""Access and control log capturing.""" + +from __future__ import annotations + +from collections.abc import Generator +from collections.abc import Mapping +from collections.abc import Set as AbstractSet +from contextlib import contextmanager +from contextlib import nullcontext +from datetime import datetime +from datetime import timedelta +from datetime import timezone +import io +from io import StringIO +import logging +from logging import LogRecord +import os +from pathlib import Path +import re +from types import TracebackType +from typing import final +from typing import Generic +from typing import Literal +from typing import TYPE_CHECKING +from typing import TypeVar + +from _pytest import nodes +from _pytest._io import TerminalWriter +from _pytest.capture import CaptureManager +from _pytest.config import _strtobool +from _pytest.config import Config +from _pytest.config import create_terminal_writer +from _pytest.config import hookimpl +from _pytest.config import UsageError +from _pytest.config.argparsing import Parser +from _pytest.deprecated import check_ispytest +from _pytest.fixtures import fixture +from _pytest.fixtures import FixtureRequest +from _pytest.main import Session +from _pytest.stash import StashKey +from _pytest.terminal import TerminalReporter + + +if TYPE_CHECKING: + logging_StreamHandler = logging.StreamHandler[StringIO] +else: + logging_StreamHandler = logging.StreamHandler + +DEFAULT_LOG_FORMAT = "%(levelname)-8s %(name)s:%(filename)s:%(lineno)d %(message)s" +DEFAULT_LOG_DATE_FORMAT = "%H:%M:%S" +_ANSI_ESCAPE_SEQ = re.compile(r"\x1b\[[\d;]+m") +caplog_handler_key = StashKey["LogCaptureHandler"]() +caplog_records_key = StashKey[dict[str, list[logging.LogRecord]]]() + + +def _remove_ansi_escape_sequences(text: str) -> str: + return _ANSI_ESCAPE_SEQ.sub("", text) + + +class DatetimeFormatter(logging.Formatter): + """A logging formatter which formats record with + :func:`datetime.datetime.strftime` formatter instead of + :func:`time.strftime` in case of microseconds in format string. + """ + + def formatTime(self, record: LogRecord, datefmt: str | None = None) -> str: + if datefmt and "%f" in datefmt: + ct = self.converter(record.created) + tz = timezone(timedelta(seconds=ct.tm_gmtoff), ct.tm_zone) + # Construct `datetime.datetime` object from `struct_time` + # and msecs information from `record` + # Using int() instead of round() to avoid it exceeding 1_000_000 and causing a ValueError (#11861). + dt = datetime(*ct[0:6], microsecond=int(record.msecs * 1000), tzinfo=tz) + return dt.strftime(datefmt) + # Use `logging.Formatter` for non-microsecond formats + return super().formatTime(record, datefmt) + + +class ColoredLevelFormatter(DatetimeFormatter): + """A logging formatter which colorizes the %(levelname)..s part of the + log format passed to __init__.""" + + LOGLEVEL_COLOROPTS: Mapping[int, AbstractSet[str]] = { + logging.CRITICAL: {"red"}, + logging.ERROR: {"red", "bold"}, + logging.WARNING: {"yellow"}, + logging.WARN: {"yellow"}, + logging.INFO: {"green"}, + logging.DEBUG: {"purple"}, + logging.NOTSET: set(), + } + LEVELNAME_FMT_REGEX = re.compile(r"%\(levelname\)([+-.]?\d*(?:\.\d+)?s)") + + def __init__(self, terminalwriter: TerminalWriter, *args, **kwargs) -> None: + super().__init__(*args, **kwargs) + self._terminalwriter = terminalwriter + self._original_fmt = self._style._fmt + self._level_to_fmt_mapping: dict[int, str] = {} + + for level, color_opts in self.LOGLEVEL_COLOROPTS.items(): + self.add_color_level(level, *color_opts) + + def add_color_level(self, level: int, *color_opts: str) -> None: + """Add or update color opts for a log level. + + :param level: + Log level to apply a style to, e.g. ``logging.INFO``. + :param color_opts: + ANSI escape sequence color options. Capitalized colors indicates + background color, i.e. ``'green', 'Yellow', 'bold'`` will give bold + green text on yellow background. + + .. warning:: + This is an experimental API. + """ + assert self._fmt is not None + levelname_fmt_match = self.LEVELNAME_FMT_REGEX.search(self._fmt) + if not levelname_fmt_match: + return + levelname_fmt = levelname_fmt_match.group() + + formatted_levelname = levelname_fmt % {"levelname": logging.getLevelName(level)} + + # add ANSI escape sequences around the formatted levelname + color_kwargs = {name: True for name in color_opts} + colorized_formatted_levelname = self._terminalwriter.markup( + formatted_levelname, **color_kwargs + ) + self._level_to_fmt_mapping[level] = self.LEVELNAME_FMT_REGEX.sub( + colorized_formatted_levelname, self._fmt + ) + + def format(self, record: logging.LogRecord) -> str: + fmt = self._level_to_fmt_mapping.get(record.levelno, self._original_fmt) + self._style._fmt = fmt + return super().format(record) + + +class PercentStyleMultiline(logging.PercentStyle): + """A logging style with special support for multiline messages. + + If the message of a record consists of multiple lines, this style + formats the message as if each line were logged separately. + """ + + def __init__(self, fmt: str, auto_indent: int | str | bool | None) -> None: + super().__init__(fmt) + self._auto_indent = self._get_auto_indent(auto_indent) + + @staticmethod + def _get_auto_indent(auto_indent_option: int | str | bool | None) -> int: + """Determine the current auto indentation setting. + + Specify auto indent behavior (on/off/fixed) by passing in + extra={"auto_indent": [value]} to the call to logging.log() or + using a --log-auto-indent [value] command line or the + log_auto_indent [value] config option. + + Default behavior is auto-indent off. + + Using the string "True" or "on" or the boolean True as the value + turns auto indent on, using the string "False" or "off" or the + boolean False or the int 0 turns it off, and specifying a + positive integer fixes the indentation position to the value + specified. + + Any other values for the option are invalid, and will silently be + converted to the default. + + :param None|bool|int|str auto_indent_option: + User specified option for indentation from command line, config + or extra kwarg. Accepts int, bool or str. str option accepts the + same range of values as boolean config options, as well as + positive integers represented in str form. + + :returns: + Indentation value, which can be + -1 (automatically determine indentation) or + 0 (auto-indent turned off) or + >0 (explicitly set indentation position). + """ + if auto_indent_option is None: + return 0 + elif isinstance(auto_indent_option, bool): + if auto_indent_option: + return -1 + else: + return 0 + elif isinstance(auto_indent_option, int): + return int(auto_indent_option) + elif isinstance(auto_indent_option, str): + try: + return int(auto_indent_option) + except ValueError: + pass + try: + if _strtobool(auto_indent_option): + return -1 + except ValueError: + return 0 + + return 0 + + def format(self, record: logging.LogRecord) -> str: + if "\n" in record.message: + if hasattr(record, "auto_indent"): + # Passed in from the "extra={}" kwarg on the call to logging.log(). + auto_indent = self._get_auto_indent(record.auto_indent) + else: + auto_indent = self._auto_indent + + if auto_indent: + lines = record.message.splitlines() + formatted = self._fmt % {**record.__dict__, "message": lines[0]} + + if auto_indent < 0: + indentation = _remove_ansi_escape_sequences(formatted).find( + lines[0] + ) + else: + # Optimizes logging by allowing a fixed indentation. + indentation = auto_indent + lines[0] = formatted + return ("\n" + " " * indentation).join(lines) + return self._fmt % record.__dict__ + + +def get_option_ini(config: Config, *names: str): + for name in names: + ret = config.getoption(name) # 'default' arg won't work as expected + if ret is None: + ret = config.getini(name) + if ret: + return ret + + +def pytest_addoption(parser: Parser) -> None: + """Add options to control log capturing.""" + group = parser.getgroup("logging") + + def add_option_ini(option, dest, default=None, type=None, **kwargs): + parser.addini( + dest, default=default, type=type, help="Default value for " + option + ) + group.addoption(option, dest=dest, **kwargs) + + add_option_ini( + "--log-level", + dest="log_level", + default=None, + metavar="LEVEL", + help=( + "Level of messages to catch/display." + " Not set by default, so it depends on the root/parent log handler's" + ' effective level, where it is "WARNING" by default.' + ), + ) + add_option_ini( + "--log-format", + dest="log_format", + default=DEFAULT_LOG_FORMAT, + help="Log format used by the logging module", + ) + add_option_ini( + "--log-date-format", + dest="log_date_format", + default=DEFAULT_LOG_DATE_FORMAT, + help="Log date format used by the logging module", + ) + parser.addini( + "log_cli", + default=False, + type="bool", + help='Enable log display during test run (also known as "live logging")', + ) + add_option_ini( + "--log-cli-level", dest="log_cli_level", default=None, help="CLI logging level" + ) + add_option_ini( + "--log-cli-format", + dest="log_cli_format", + default=None, + help="Log format used by the logging module", + ) + add_option_ini( + "--log-cli-date-format", + dest="log_cli_date_format", + default=None, + help="Log date format used by the logging module", + ) + add_option_ini( + "--log-file", + dest="log_file", + default=None, + help="Path to a file when logging will be written to", + ) + add_option_ini( + "--log-file-mode", + dest="log_file_mode", + default="w", + choices=["w", "a"], + help="Log file open mode", + ) + add_option_ini( + "--log-file-level", + dest="log_file_level", + default=None, + help="Log file logging level", + ) + add_option_ini( + "--log-file-format", + dest="log_file_format", + default=None, + help="Log format used by the logging module", + ) + add_option_ini( + "--log-file-date-format", + dest="log_file_date_format", + default=None, + help="Log date format used by the logging module", + ) + add_option_ini( + "--log-auto-indent", + dest="log_auto_indent", + default=None, + help="Auto-indent multiline messages passed to the logging module. Accepts true|on, false|off or an integer.", + ) + group.addoption( + "--log-disable", + action="append", + default=[], + dest="logger_disable", + help="Disable a logger by name. Can be passed multiple times.", + ) + + +_HandlerType = TypeVar("_HandlerType", bound=logging.Handler) + + +# Not using @contextmanager for performance reasons. +class catching_logs(Generic[_HandlerType]): + """Context manager that prepares the whole logging machinery properly.""" + + __slots__ = ("handler", "level", "orig_level") + + def __init__(self, handler: _HandlerType, level: int | None = None) -> None: + self.handler = handler + self.level = level + + def __enter__(self) -> _HandlerType: + root_logger = logging.getLogger() + if self.level is not None: + self.handler.setLevel(self.level) + root_logger.addHandler(self.handler) + if self.level is not None: + self.orig_level = root_logger.level + root_logger.setLevel(min(self.orig_level, self.level)) + return self.handler + + def __exit__( + self, + exc_type: type[BaseException] | None, + exc_val: BaseException | None, + exc_tb: TracebackType | None, + ) -> None: + root_logger = logging.getLogger() + if self.level is not None: + root_logger.setLevel(self.orig_level) + root_logger.removeHandler(self.handler) + + +class LogCaptureHandler(logging_StreamHandler): + """A logging handler that stores log records and the log text.""" + + def __init__(self) -> None: + """Create a new log handler.""" + super().__init__(StringIO()) + self.records: list[logging.LogRecord] = [] + + def emit(self, record: logging.LogRecord) -> None: + """Keep the log records in a list in addition to the log text.""" + self.records.append(record) + super().emit(record) + + def reset(self) -> None: + self.records = [] + self.stream = StringIO() + + def clear(self) -> None: + self.records.clear() + self.stream = StringIO() + + def handleError(self, record: logging.LogRecord) -> None: + if logging.raiseExceptions: + # Fail the test if the log message is bad (emit failed). + # The default behavior of logging is to print "Logging error" + # to stderr with the call stack and some extra details. + # pytest wants to make such mistakes visible during testing. + raise # noqa: PLE0704 + + +@final +class LogCaptureFixture: + """Provides access and control of log capturing.""" + + def __init__(self, item: nodes.Node, *, _ispytest: bool = False) -> None: + check_ispytest(_ispytest) + self._item = item + self._initial_handler_level: int | None = None + # Dict of log name -> log level. + self._initial_logger_levels: dict[str | None, int] = {} + self._initial_disabled_logging_level: int | None = None + + def _finalize(self) -> None: + """Finalize the fixture. + + This restores the log levels and the disabled logging levels changed by :meth:`set_level`. + """ + # Restore log levels. + if self._initial_handler_level is not None: + self.handler.setLevel(self._initial_handler_level) + for logger_name, level in self._initial_logger_levels.items(): + logger = logging.getLogger(logger_name) + logger.setLevel(level) + # Disable logging at the original disabled logging level. + if self._initial_disabled_logging_level is not None: + logging.disable(self._initial_disabled_logging_level) + self._initial_disabled_logging_level = None + + @property + def handler(self) -> LogCaptureHandler: + """Get the logging handler used by the fixture.""" + return self._item.stash[caplog_handler_key] + + def get_records( + self, when: Literal["setup", "call", "teardown"] + ) -> list[logging.LogRecord]: + """Get the logging records for one of the possible test phases. + + :param when: + Which test phase to obtain the records from. + Valid values are: "setup", "call" and "teardown". + + :returns: The list of captured records at the given stage. + + .. versionadded:: 3.4 + """ + return self._item.stash[caplog_records_key].get(when, []) + + @property + def text(self) -> str: + """The formatted log text.""" + return _remove_ansi_escape_sequences(self.handler.stream.getvalue()) + + @property + def records(self) -> list[logging.LogRecord]: + """The list of log records.""" + return self.handler.records + + @property + def record_tuples(self) -> list[tuple[str, int, str]]: + """A list of a stripped down version of log records intended + for use in assertion comparison. + + The format of the tuple is: + + (logger_name, log_level, message) + """ + return [(r.name, r.levelno, r.getMessage()) for r in self.records] + + @property + def messages(self) -> list[str]: + """A list of format-interpolated log messages. + + Unlike 'records', which contains the format string and parameters for + interpolation, log messages in this list are all interpolated. + + Unlike 'text', which contains the output from the handler, log + messages in this list are unadorned with levels, timestamps, etc, + making exact comparisons more reliable. + + Note that traceback or stack info (from :func:`logging.exception` or + the `exc_info` or `stack_info` arguments to the logging functions) is + not included, as this is added by the formatter in the handler. + + .. versionadded:: 3.7 + """ + return [r.getMessage() for r in self.records] + + def clear(self) -> None: + """Reset the list of log records and the captured log text.""" + self.handler.clear() + + def _force_enable_logging( + self, level: int | str, logger_obj: logging.Logger + ) -> int: + """Enable the desired logging level if the global level was disabled via ``logging.disabled``. + + Only enables logging levels greater than or equal to the requested ``level``. + + Does nothing if the desired ``level`` wasn't disabled. + + :param level: + The logger level caplog should capture. + All logging is enabled if a non-standard logging level string is supplied. + Valid level strings are in :data:`logging._nameToLevel`. + :param logger_obj: The logger object to check. + + :return: The original disabled logging level. + """ + original_disable_level: int = logger_obj.manager.disable + + if isinstance(level, str): + # Try to translate the level string to an int for `logging.disable()` + level = logging.getLevelName(level) + + if not isinstance(level, int): + # The level provided was not valid, so just un-disable all logging. + logging.disable(logging.NOTSET) + elif not logger_obj.isEnabledFor(level): + # Each level is `10` away from other levels. + # https://docs.python.org/3/library/logging.html#logging-levels + disable_level = max(level - 10, logging.NOTSET) + logging.disable(disable_level) + + return original_disable_level + + def set_level(self, level: int | str, logger: str | None = None) -> None: + """Set the threshold level of a logger for the duration of a test. + + Logging messages which are less severe than this level will not be captured. + + .. versionchanged:: 3.4 + The levels of the loggers changed by this function will be + restored to their initial values at the end of the test. + + Will enable the requested logging level if it was disabled via :func:`logging.disable`. + + :param level: The level. + :param logger: The logger to update. If not given, the root logger. + """ + logger_obj = logging.getLogger(logger) + # Save the original log-level to restore it during teardown. + self._initial_logger_levels.setdefault(logger, logger_obj.level) + logger_obj.setLevel(level) + if self._initial_handler_level is None: + self._initial_handler_level = self.handler.level + self.handler.setLevel(level) + initial_disabled_logging_level = self._force_enable_logging(level, logger_obj) + if self._initial_disabled_logging_level is None: + self._initial_disabled_logging_level = initial_disabled_logging_level + + @contextmanager + def at_level(self, level: int | str, logger: str | None = None) -> Generator[None]: + """Context manager that sets the level for capturing of logs. After + the end of the 'with' statement the level is restored to its original + value. + + Will enable the requested logging level if it was disabled via :func:`logging.disable`. + + :param level: The level. + :param logger: The logger to update. If not given, the root logger. + """ + logger_obj = logging.getLogger(logger) + orig_level = logger_obj.level + logger_obj.setLevel(level) + handler_orig_level = self.handler.level + self.handler.setLevel(level) + original_disable_level = self._force_enable_logging(level, logger_obj) + try: + yield + finally: + logger_obj.setLevel(orig_level) + self.handler.setLevel(handler_orig_level) + logging.disable(original_disable_level) + + @contextmanager + def filtering(self, filter_: logging.Filter) -> Generator[None]: + """Context manager that temporarily adds the given filter to the caplog's + :meth:`handler` for the 'with' statement block, and removes that filter at the + end of the block. + + :param filter_: A custom :class:`logging.Filter` object. + + .. versionadded:: 7.5 + """ + self.handler.addFilter(filter_) + try: + yield + finally: + self.handler.removeFilter(filter_) + + +@fixture +def caplog(request: FixtureRequest) -> Generator[LogCaptureFixture]: + """Access and control log capturing. + + Captured logs are available through the following properties/methods:: + + * caplog.messages -> list of format-interpolated log messages + * caplog.text -> string containing formatted log output + * caplog.records -> list of logging.LogRecord instances + * caplog.record_tuples -> list of (logger_name, level, message) tuples + * caplog.clear() -> clear captured records and formatted log output string + """ + result = LogCaptureFixture(request.node, _ispytest=True) + yield result + result._finalize() + + +def get_log_level_for_setting(config: Config, *setting_names: str) -> int | None: + for setting_name in setting_names: + log_level = config.getoption(setting_name) + if log_level is None: + log_level = config.getini(setting_name) + if log_level: + break + else: + return None + + if isinstance(log_level, str): + log_level = log_level.upper() + try: + return int(getattr(logging, log_level, log_level)) + except ValueError as e: + # Python logging does not recognise this as a logging level + raise UsageError( + f"'{log_level}' is not recognized as a logging level name for " + f"'{setting_name}'. Please consider passing the " + "logging level num instead." + ) from e + + +# run after terminalreporter/capturemanager are configured +@hookimpl(trylast=True) +def pytest_configure(config: Config) -> None: + config.pluginmanager.register(LoggingPlugin(config), "logging-plugin") + + +class LoggingPlugin: + """Attaches to the logging module and captures log messages for each test.""" + + def __init__(self, config: Config) -> None: + """Create a new plugin to capture log messages. + + The formatter can be safely shared across all handlers so + create a single one for the entire test session here. + """ + self._config = config + + # Report logging. + self.formatter = self._create_formatter( + get_option_ini(config, "log_format"), + get_option_ini(config, "log_date_format"), + get_option_ini(config, "log_auto_indent"), + ) + self.log_level = get_log_level_for_setting(config, "log_level") + self.caplog_handler = LogCaptureHandler() + self.caplog_handler.setFormatter(self.formatter) + self.report_handler = LogCaptureHandler() + self.report_handler.setFormatter(self.formatter) + + # File logging. + self.log_file_level = get_log_level_for_setting( + config, "log_file_level", "log_level" + ) + log_file = get_option_ini(config, "log_file") or os.devnull + if log_file != os.devnull: + directory = os.path.dirname(os.path.abspath(log_file)) + if not os.path.isdir(directory): + os.makedirs(directory) + + self.log_file_mode = get_option_ini(config, "log_file_mode") or "w" + self.log_file_handler = _FileHandler( + log_file, mode=self.log_file_mode, encoding="UTF-8" + ) + log_file_format = get_option_ini(config, "log_file_format", "log_format") + log_file_date_format = get_option_ini( + config, "log_file_date_format", "log_date_format" + ) + + log_file_formatter = DatetimeFormatter( + log_file_format, datefmt=log_file_date_format + ) + self.log_file_handler.setFormatter(log_file_formatter) + + # CLI/live logging. + self.log_cli_level = get_log_level_for_setting( + config, "log_cli_level", "log_level" + ) + if self._log_cli_enabled(): + terminal_reporter = config.pluginmanager.get_plugin("terminalreporter") + # Guaranteed by `_log_cli_enabled()`. + assert terminal_reporter is not None + capture_manager = config.pluginmanager.get_plugin("capturemanager") + # if capturemanager plugin is disabled, live logging still works. + self.log_cli_handler: ( + _LiveLoggingStreamHandler | _LiveLoggingNullHandler + ) = _LiveLoggingStreamHandler(terminal_reporter, capture_manager) + else: + self.log_cli_handler = _LiveLoggingNullHandler() + log_cli_formatter = self._create_formatter( + get_option_ini(config, "log_cli_format", "log_format"), + get_option_ini(config, "log_cli_date_format", "log_date_format"), + get_option_ini(config, "log_auto_indent"), + ) + self.log_cli_handler.setFormatter(log_cli_formatter) + self._disable_loggers(loggers_to_disable=config.option.logger_disable) + + def _disable_loggers(self, loggers_to_disable: list[str]) -> None: + if not loggers_to_disable: + return + + for name in loggers_to_disable: + logger = logging.getLogger(name) + logger.disabled = True + + def _create_formatter(self, log_format, log_date_format, auto_indent): + # Color option doesn't exist if terminal plugin is disabled. + color = getattr(self._config.option, "color", "no") + if color != "no" and ColoredLevelFormatter.LEVELNAME_FMT_REGEX.search( + log_format + ): + formatter: logging.Formatter = ColoredLevelFormatter( + create_terminal_writer(self._config), log_format, log_date_format + ) + else: + formatter = DatetimeFormatter(log_format, log_date_format) + + formatter._style = PercentStyleMultiline( + formatter._style._fmt, auto_indent=auto_indent + ) + + return formatter + + def set_log_path(self, fname: str) -> None: + """Set the filename parameter for Logging.FileHandler(). + + Creates parent directory if it does not exist. + + .. warning:: + This is an experimental API. + """ + fpath = Path(fname) + + if not fpath.is_absolute(): + fpath = self._config.rootpath / fpath + + if not fpath.parent.exists(): + fpath.parent.mkdir(exist_ok=True, parents=True) + + # https://github.com/python/mypy/issues/11193 + stream: io.TextIOWrapper = fpath.open(mode=self.log_file_mode, encoding="UTF-8") # type: ignore[assignment] + old_stream = self.log_file_handler.setStream(stream) + if old_stream: + old_stream.close() + + def _log_cli_enabled(self) -> bool: + """Return whether live logging is enabled.""" + enabled = self._config.getoption( + "--log-cli-level" + ) is not None or self._config.getini("log_cli") + if not enabled: + return False + + terminal_reporter = self._config.pluginmanager.get_plugin("terminalreporter") + if terminal_reporter is None: + # terminal reporter is disabled e.g. by pytest-xdist. + return False + + return True + + @hookimpl(wrapper=True, tryfirst=True) + def pytest_sessionstart(self) -> Generator[None]: + self.log_cli_handler.set_when("sessionstart") + + with catching_logs(self.log_cli_handler, level=self.log_cli_level): + with catching_logs(self.log_file_handler, level=self.log_file_level): + return (yield) + + @hookimpl(wrapper=True, tryfirst=True) + def pytest_collection(self) -> Generator[None]: + self.log_cli_handler.set_when("collection") + + with catching_logs(self.log_cli_handler, level=self.log_cli_level): + with catching_logs(self.log_file_handler, level=self.log_file_level): + return (yield) + + @hookimpl(wrapper=True) + def pytest_runtestloop(self, session: Session) -> Generator[None, object, object]: + if session.config.option.collectonly: + return (yield) + + if self._log_cli_enabled() and self._config.get_verbosity() < 1: + # The verbose flag is needed to avoid messy test progress output. + self._config.option.verbose = 1 + + with catching_logs(self.log_cli_handler, level=self.log_cli_level): + with catching_logs(self.log_file_handler, level=self.log_file_level): + return (yield) # Run all the tests. + + @hookimpl + def pytest_runtest_logstart(self) -> None: + self.log_cli_handler.reset() + self.log_cli_handler.set_when("start") + + @hookimpl + def pytest_runtest_logreport(self) -> None: + self.log_cli_handler.set_when("logreport") + + @contextmanager + def _runtest_for(self, item: nodes.Item, when: str) -> Generator[None]: + """Implement the internals of the pytest_runtest_xxx() hooks.""" + with ( + catching_logs( + self.caplog_handler, + level=self.log_level, + ) as caplog_handler, + catching_logs( + self.report_handler, + level=self.log_level, + ) as report_handler, + ): + caplog_handler.reset() + report_handler.reset() + item.stash[caplog_records_key][when] = caplog_handler.records + item.stash[caplog_handler_key] = caplog_handler + + try: + yield + finally: + log = report_handler.stream.getvalue().strip() + item.add_report_section(when, "log", log) + + @hookimpl(wrapper=True) + def pytest_runtest_setup(self, item: nodes.Item) -> Generator[None]: + self.log_cli_handler.set_when("setup") + + empty: dict[str, list[logging.LogRecord]] = {} + item.stash[caplog_records_key] = empty + with self._runtest_for(item, "setup"): + yield + + @hookimpl(wrapper=True) + def pytest_runtest_call(self, item: nodes.Item) -> Generator[None]: + self.log_cli_handler.set_when("call") + + with self._runtest_for(item, "call"): + yield + + @hookimpl(wrapper=True) + def pytest_runtest_teardown(self, item: nodes.Item) -> Generator[None]: + self.log_cli_handler.set_when("teardown") + + try: + with self._runtest_for(item, "teardown"): + yield + finally: + del item.stash[caplog_records_key] + del item.stash[caplog_handler_key] + + @hookimpl + def pytest_runtest_logfinish(self) -> None: + self.log_cli_handler.set_when("finish") + + @hookimpl(wrapper=True, tryfirst=True) + def pytest_sessionfinish(self) -> Generator[None]: + self.log_cli_handler.set_when("sessionfinish") + + with catching_logs(self.log_cli_handler, level=self.log_cli_level): + with catching_logs(self.log_file_handler, level=self.log_file_level): + return (yield) + + @hookimpl + def pytest_unconfigure(self) -> None: + # Close the FileHandler explicitly. + # (logging.shutdown might have lost the weakref?!) + self.log_file_handler.close() + + +class _FileHandler(logging.FileHandler): + """A logging FileHandler with pytest tweaks.""" + + def handleError(self, record: logging.LogRecord) -> None: + # Handled by LogCaptureHandler. + pass + + +class _LiveLoggingStreamHandler(logging_StreamHandler): + """A logging StreamHandler used by the live logging feature: it will + write a newline before the first log message in each test. + + During live logging we must also explicitly disable stdout/stderr + capturing otherwise it will get captured and won't appear in the + terminal. + """ + + # Officially stream needs to be a IO[str], but TerminalReporter + # isn't. So force it. + stream: TerminalReporter = None # type: ignore + + def __init__( + self, + terminal_reporter: TerminalReporter, + capture_manager: CaptureManager | None, + ) -> None: + super().__init__(stream=terminal_reporter) # type: ignore[arg-type] + self.capture_manager = capture_manager + self.reset() + self.set_when(None) + self._test_outcome_written = False + + def reset(self) -> None: + """Reset the handler; should be called before the start of each test.""" + self._first_record_emitted = False + + def set_when(self, when: str | None) -> None: + """Prepare for the given test phase (setup/call/teardown).""" + self._when = when + self._section_name_shown = False + if when == "start": + self._test_outcome_written = False + + def emit(self, record: logging.LogRecord) -> None: + ctx_manager = ( + self.capture_manager.global_and_fixture_disabled() + if self.capture_manager + else nullcontext() + ) + with ctx_manager: + if not self._first_record_emitted: + self.stream.write("\n") + self._first_record_emitted = True + elif self._when in ("teardown", "finish"): + if not self._test_outcome_written: + self._test_outcome_written = True + self.stream.write("\n") + if not self._section_name_shown and self._when: + self.stream.section("live log " + self._when, sep="-", bold=True) + self._section_name_shown = True + super().emit(record) + + def handleError(self, record: logging.LogRecord) -> None: + # Handled by LogCaptureHandler. + pass + + +class _LiveLoggingNullHandler(logging.NullHandler): + """A logging handler used when live logging is disabled.""" + + def reset(self) -> None: + pass + + def set_when(self, when: str) -> None: + pass + + def handleError(self, record: logging.LogRecord) -> None: + # Handled by LogCaptureHandler. + pass diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/main.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/main.py new file mode 100644 index 0000000000000000000000000000000000000000..9bc930df8e86730cdb6eb35eba912dbdebb22e8b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/main.py @@ -0,0 +1,1203 @@ +"""Core implementation of the testing process: init, session, runtest loop.""" + +from __future__ import annotations + +import argparse +from collections.abc import Callable +from collections.abc import Iterable +from collections.abc import Iterator +from collections.abc import Sequence +from collections.abc import Set as AbstractSet +import dataclasses +import fnmatch +import functools +import importlib +import importlib.util +import os +from pathlib import Path +import sys +from typing import final +from typing import Literal +from typing import overload +from typing import TYPE_CHECKING +import warnings + +import pluggy + +from _pytest import nodes +import _pytest._code +from _pytest.config import Config +from _pytest.config import directory_arg +from _pytest.config import ExitCode +from _pytest.config import hookimpl +from _pytest.config import PytestPluginManager +from _pytest.config import UsageError +from _pytest.config.argparsing import OverrideIniAction +from _pytest.config.argparsing import Parser +from _pytest.config.compat import PathAwareHookProxy +from _pytest.outcomes import exit +from _pytest.pathlib import absolutepath +from _pytest.pathlib import bestrelpath +from _pytest.pathlib import fnmatch_ex +from _pytest.pathlib import safe_exists +from _pytest.pathlib import samefile_nofollow +from _pytest.pathlib import scandir +from _pytest.reports import CollectReport +from _pytest.reports import TestReport +from _pytest.runner import collect_one_node +from _pytest.runner import SetupState +from _pytest.warning_types import PytestWarning + + +if TYPE_CHECKING: + from typing_extensions import Self + + from _pytest.fixtures import FixtureManager + + +def pytest_addoption(parser: Parser) -> None: + group = parser.getgroup("general") + group._addoption( # private to use reserved lower-case short option + "-x", + "--exitfirst", + action="store_const", + dest="maxfail", + const=1, + help="Exit instantly on first error or failed test", + ) + group.addoption( + "--maxfail", + metavar="num", + action="store", + type=int, + dest="maxfail", + default=0, + help="Exit after first num failures or errors", + ) + group.addoption( + "--strict-config", + action=OverrideIniAction, + ini_option="strict_config", + ini_value="true", + help="Enables the strict_config option", + ) + group.addoption( + "--strict-markers", + action=OverrideIniAction, + ini_option="strict_markers", + ini_value="true", + help="Enables the strict_markers option", + ) + group.addoption( + "--strict", + action=OverrideIniAction, + ini_option="strict", + ini_value="true", + help="Enables the strict option", + ) + parser.addini( + "strict_config", + "Any warnings encountered while parsing the `pytest` section of the " + "configuration file raise errors", + type="bool", + # None => fallback to `strict`. + default=None, + ) + parser.addini( + "strict_markers", + "Markers not registered in the `markers` section of the configuration " + "file raise errors", + type="bool", + # None => fallback to `strict`. + default=None, + ) + parser.addini( + "strict", + "Enables all strictness options, currently: " + "strict_config, strict_markers, strict_xfail, strict_parametrization_ids", + type="bool", + default=False, + ) + + group = parser.getgroup("pytest-warnings") + group.addoption( + "-W", + "--pythonwarnings", + action="append", + help="Set which warnings to report, see -W option of Python itself", + ) + parser.addini( + "filterwarnings", + type="linelist", + help="Each line specifies a pattern for " + "warnings.filterwarnings. " + "Processed after -W/--pythonwarnings.", + ) + + group = parser.getgroup("collect", "collection") + group.addoption( + "--collectonly", + "--collect-only", + "--co", + action="store_true", + help="Only collect tests, don't execute them", + ) + group.addoption( + "--pyargs", + action="store_true", + help="Try to interpret all arguments as Python packages", + ) + group.addoption( + "--ignore", + action="append", + metavar="path", + help="Ignore path during collection (multi-allowed)", + ) + group.addoption( + "--ignore-glob", + action="append", + metavar="path", + help="Ignore path pattern during collection (multi-allowed)", + ) + group.addoption( + "--deselect", + action="append", + metavar="nodeid_prefix", + help="Deselect item (via node id prefix) during collection (multi-allowed)", + ) + group.addoption( + "--confcutdir", + dest="confcutdir", + default=None, + metavar="dir", + type=functools.partial(directory_arg, optname="--confcutdir"), + help="Only load conftest.py's relative to specified dir", + ) + group.addoption( + "--noconftest", + action="store_true", + dest="noconftest", + default=False, + help="Don't load any conftest.py files", + ) + group.addoption( + "--keepduplicates", + "--keep-duplicates", + action="store_true", + dest="keepduplicates", + default=False, + help="Keep duplicate tests", + ) + group.addoption( + "--collect-in-virtualenv", + action="store_true", + dest="collect_in_virtualenv", + default=False, + help="Don't ignore tests in a local virtualenv directory", + ) + group.addoption( + "--continue-on-collection-errors", + action="store_true", + default=False, + dest="continue_on_collection_errors", + help="Force test execution even if collection errors occur", + ) + group.addoption( + "--import-mode", + default="prepend", + choices=["prepend", "append", "importlib"], + dest="importmode", + help="Prepend/append to sys.path when importing test modules and conftest " + "files. Default: prepend.", + ) + parser.addini( + "norecursedirs", + "Directory patterns to avoid for recursion", + type="args", + default=[ + "*.egg", + ".*", + "_darcs", + "build", + "CVS", + "dist", + "node_modules", + "venv", + "{arch}", + ], + ) + parser.addini( + "testpaths", + "Directories to search for tests when no files or directories are given on the " + "command line", + type="args", + default=[], + ) + parser.addini( + "collect_imported_tests", + "Whether to collect tests in imported modules outside `testpaths`", + type="bool", + default=True, + ) + parser.addini( + "consider_namespace_packages", + type="bool", + default=False, + help="Consider namespace packages when resolving module names during import", + ) + + group = parser.getgroup("debugconfig", "test session debugging and configuration") + group._addoption( # private to use reserved lower-case short option + "-c", + "--config-file", + metavar="FILE", + type=str, + dest="inifilename", + help="Load configuration from `FILE` instead of trying to locate one of the " + "implicit configuration files.", + ) + group.addoption( + "--rootdir", + action="store", + dest="rootdir", + help="Define root directory for tests. Can be relative path: 'root_dir', './root_dir', " + "'root_dir/another_dir/'; absolute path: '/home/user/root_dir'; path with variables: " + "'$HOME/root_dir'.", + ) + group.addoption( + "--basetemp", + dest="basetemp", + default=None, + type=validate_basetemp, + metavar="dir", + help=( + "Base temporary directory for this test run. " + "(Warning: this directory is removed if it exists.)" + ), + ) + + +def validate_basetemp(path: str) -> str: + # GH 7119 + msg = "basetemp must not be empty, the current working directory or any parent directory of it" + + # empty path + if not path: + raise argparse.ArgumentTypeError(msg) + + def is_ancestor(base: Path, query: Path) -> bool: + """Return whether query is an ancestor of base.""" + if base == query: + return True + return query in base.parents + + # check if path is an ancestor of cwd + if is_ancestor(Path.cwd(), Path(path).absolute()): + raise argparse.ArgumentTypeError(msg) + + # check symlinks for ancestors + if is_ancestor(Path.cwd().resolve(), Path(path).resolve()): + raise argparse.ArgumentTypeError(msg) + + return path + + +def wrap_session( + config: Config, doit: Callable[[Config, Session], int | ExitCode | None] +) -> int | ExitCode: + """Skeleton command line program.""" + session = Session.from_config(config) + session.exitstatus = ExitCode.OK + initstate = 0 + try: + try: + config._do_configure() + initstate = 1 + config.hook.pytest_sessionstart(session=session) + initstate = 2 + session.exitstatus = doit(config, session) or 0 + except UsageError: + session.exitstatus = ExitCode.USAGE_ERROR + raise + except Failed: + session.exitstatus = ExitCode.TESTS_FAILED + except (KeyboardInterrupt, exit.Exception): + excinfo = _pytest._code.ExceptionInfo.from_current() + exitstatus: int | ExitCode = ExitCode.INTERRUPTED + if isinstance(excinfo.value, exit.Exception): + if excinfo.value.returncode is not None: + exitstatus = excinfo.value.returncode + if initstate < 2: + sys.stderr.write(f"{excinfo.typename}: {excinfo.value.msg}\n") + config.hook.pytest_keyboard_interrupt(excinfo=excinfo) + session.exitstatus = exitstatus + except BaseException: + session.exitstatus = ExitCode.INTERNAL_ERROR + excinfo = _pytest._code.ExceptionInfo.from_current() + try: + config.notify_exception(excinfo, config.option) + except exit.Exception as exc: + if exc.returncode is not None: + session.exitstatus = exc.returncode + sys.stderr.write(f"{type(exc).__name__}: {exc}\n") + else: + if isinstance(excinfo.value, SystemExit): + sys.stderr.write("mainloop: caught unexpected SystemExit!\n") + + finally: + # Explicitly break reference cycle. + excinfo = None # type: ignore + os.chdir(session.startpath) + if initstate >= 2: + try: + config.hook.pytest_sessionfinish( + session=session, exitstatus=session.exitstatus + ) + except exit.Exception as exc: + if exc.returncode is not None: + session.exitstatus = exc.returncode + sys.stderr.write(f"{type(exc).__name__}: {exc}\n") + config._ensure_unconfigure() + return session.exitstatus + + +def pytest_cmdline_main(config: Config) -> int | ExitCode: + return wrap_session(config, _main) + + +def _main(config: Config, session: Session) -> int | ExitCode | None: + """Default command line protocol for initialization, session, + running tests and reporting.""" + config.hook.pytest_collection(session=session) + config.hook.pytest_runtestloop(session=session) + + if session.testsfailed: + return ExitCode.TESTS_FAILED + elif session.testscollected == 0: + return ExitCode.NO_TESTS_COLLECTED + return None + + +def pytest_collection(session: Session) -> None: + session.perform_collect() + + +def pytest_runtestloop(session: Session) -> bool: + if session.testsfailed and not session.config.option.continue_on_collection_errors: + raise session.Interrupted( + f"{session.testsfailed} error{'s' if session.testsfailed != 1 else ''} during collection" + ) + + if session.config.option.collectonly: + return True + + for i, item in enumerate(session.items): + nextitem = session.items[i + 1] if i + 1 < len(session.items) else None + item.config.hook.pytest_runtest_protocol(item=item, nextitem=nextitem) + if session.shouldfail: + raise session.Failed(session.shouldfail) + if session.shouldstop: + raise session.Interrupted(session.shouldstop) + return True + + +def _in_venv(path: Path) -> bool: + """Attempt to detect if ``path`` is the root of a Virtual Environment by + checking for the existence of the pyvenv.cfg file. + + [https://peps.python.org/pep-0405/] + + For regression protection we also check for conda environments that do not include pyenv.cfg yet -- + https://github.com/conda/conda/issues/13337 is the conda issue tracking adding pyenv.cfg. + + Checking for the `conda-meta/history` file per https://github.com/pytest-dev/pytest/issues/12652#issuecomment-2246336902. + + """ + try: + return ( + path.joinpath("pyvenv.cfg").is_file() + or path.joinpath("conda-meta", "history").is_file() + ) + except OSError: + return False + + +def pytest_ignore_collect(collection_path: Path, config: Config) -> bool | None: + if collection_path.name == "__pycache__": + return True + + ignore_paths = config._getconftest_pathlist( + "collect_ignore", path=collection_path.parent + ) + ignore_paths = ignore_paths or [] + excludeopt = config.getoption("ignore") + if excludeopt: + ignore_paths.extend(absolutepath(x) for x in excludeopt) + + if collection_path in ignore_paths: + return True + + ignore_globs = config._getconftest_pathlist( + "collect_ignore_glob", path=collection_path.parent + ) + ignore_globs = ignore_globs or [] + excludeglobopt = config.getoption("ignore_glob") + if excludeglobopt: + ignore_globs.extend(absolutepath(x) for x in excludeglobopt) + + if any(fnmatch.fnmatch(str(collection_path), str(glob)) for glob in ignore_globs): + return True + + allow_in_venv = config.getoption("collect_in_virtualenv") + if not allow_in_venv and _in_venv(collection_path): + return True + + if collection_path.is_dir(): + norecursepatterns = config.getini("norecursedirs") + if any(fnmatch_ex(pat, collection_path) for pat in norecursepatterns): + return True + + return None + + +def pytest_collect_directory( + path: Path, parent: nodes.Collector +) -> nodes.Collector | None: + return Dir.from_parent(parent, path=path) + + +def pytest_collection_modifyitems(items: list[nodes.Item], config: Config) -> None: + deselect_prefixes = tuple(config.getoption("deselect") or []) + if not deselect_prefixes: + return + + remaining = [] + deselected = [] + for colitem in items: + if colitem.nodeid.startswith(deselect_prefixes): + deselected.append(colitem) + else: + remaining.append(colitem) + + if deselected: + config.hook.pytest_deselected(items=deselected) + items[:] = remaining + + +class FSHookProxy: + def __init__( + self, + pm: PytestPluginManager, + remove_mods: AbstractSet[object], + ) -> None: + self.pm = pm + self.remove_mods = remove_mods + + def __getattr__(self, name: str) -> pluggy.HookCaller: + x = self.pm.subset_hook_caller(name, remove_plugins=self.remove_mods) + self.__dict__[name] = x + return x + + +class Interrupted(KeyboardInterrupt): + """Signals that the test run was interrupted.""" + + __module__ = "builtins" # For py3. + + +class Failed(Exception): + """Signals a stop as failed test run.""" + + +@dataclasses.dataclass +class _bestrelpath_cache(dict[Path, str]): + __slots__ = ("path",) + + path: Path + + def __missing__(self, path: Path) -> str: + r = bestrelpath(self.path, path) + self[path] = r + return r + + +@final +class Dir(nodes.Directory): + """Collector of files in a file system directory. + + .. versionadded:: 8.0 + + .. note:: + + Python directories with an `__init__.py` file are instead collected by + :class:`~pytest.Package` by default. Both are :class:`~pytest.Directory` + collectors. + """ + + @classmethod + def from_parent( # type: ignore[override] + cls, + parent: nodes.Collector, + *, + path: Path, + ) -> Self: + """The public constructor. + + :param parent: The parent collector of this Dir. + :param path: The directory's path. + :type path: pathlib.Path + """ + return super().from_parent(parent=parent, path=path) + + def collect(self) -> Iterable[nodes.Item | nodes.Collector]: + config = self.config + col: nodes.Collector | None + cols: Sequence[nodes.Collector] + ihook = self.ihook + for direntry in scandir(self.path): + if direntry.is_dir(): + path = Path(direntry.path) + if not self.session.isinitpath(path, with_parents=True): + if ihook.pytest_ignore_collect(collection_path=path, config=config): + continue + col = ihook.pytest_collect_directory(path=path, parent=self) + if col is not None: + yield col + + elif direntry.is_file(): + path = Path(direntry.path) + if not self.session.isinitpath(path): + if ihook.pytest_ignore_collect(collection_path=path, config=config): + continue + cols = ihook.pytest_collect_file(file_path=path, parent=self) + yield from cols + + +@final +class Session(nodes.Collector): + """The root of the collection tree. + + ``Session`` collects the initial paths given as arguments to pytest. + """ + + Interrupted = Interrupted + Failed = Failed + # Set on the session by runner.pytest_sessionstart. + _setupstate: SetupState + # Set on the session by fixtures.pytest_sessionstart. + _fixturemanager: FixtureManager + exitstatus: int | ExitCode + + def __init__(self, config: Config) -> None: + super().__init__( + name="", + path=config.rootpath, + fspath=None, + parent=None, + config=config, + session=self, + nodeid="", + ) + self.testsfailed = 0 + self.testscollected = 0 + self._shouldstop: bool | str = False + self._shouldfail: bool | str = False + self.trace = config.trace.root.get("collection") + self._initialpaths: frozenset[Path] = frozenset() + self._initialpaths_with_parents: frozenset[Path] = frozenset() + self._notfound: list[tuple[str, Sequence[nodes.Collector]]] = [] + self._initial_parts: list[CollectionArgument] = [] + self._collection_cache: dict[nodes.Collector, CollectReport] = {} + self.items: list[nodes.Item] = [] + + self._bestrelpathcache: dict[Path, str] = _bestrelpath_cache(config.rootpath) + + self.config.pluginmanager.register(self, name="session") + + @classmethod + def from_config(cls, config: Config) -> Session: + session: Session = cls._create(config=config) + return session + + def __repr__(self) -> str: + return ( + f"<{self.__class__.__name__} {self.name} " + f"exitstatus=%r " + f"testsfailed={self.testsfailed} " + f"testscollected={self.testscollected}>" + ) % getattr(self, "exitstatus", "<UNSET>") + + @property + def shouldstop(self) -> bool | str: + return self._shouldstop + + @shouldstop.setter + def shouldstop(self, value: bool | str) -> None: + # The runner checks shouldfail and assumes that if it is set we are + # definitely stopping, so prevent unsetting it. + if value is False and self._shouldstop: + warnings.warn( + PytestWarning( + "session.shouldstop cannot be unset after it has been set; ignoring." + ), + stacklevel=2, + ) + return + self._shouldstop = value + + @property + def shouldfail(self) -> bool | str: + return self._shouldfail + + @shouldfail.setter + def shouldfail(self, value: bool | str) -> None: + # The runner checks shouldfail and assumes that if it is set we are + # definitely stopping, so prevent unsetting it. + if value is False and self._shouldfail: + warnings.warn( + PytestWarning( + "session.shouldfail cannot be unset after it has been set; ignoring." + ), + stacklevel=2, + ) + return + self._shouldfail = value + + @property + def startpath(self) -> Path: + """The path from which pytest was invoked. + + .. versionadded:: 7.0.0 + """ + return self.config.invocation_params.dir + + def _node_location_to_relpath(self, node_path: Path) -> str: + # bestrelpath is a quite slow function. + return self._bestrelpathcache[node_path] + + @hookimpl(tryfirst=True) + def pytest_collectstart(self) -> None: + if self.shouldfail: + raise self.Failed(self.shouldfail) + if self.shouldstop: + raise self.Interrupted(self.shouldstop) + + @hookimpl(tryfirst=True) + def pytest_runtest_logreport(self, report: TestReport | CollectReport) -> None: + if report.failed and not hasattr(report, "wasxfail"): + self.testsfailed += 1 + maxfail = self.config.getvalue("maxfail") + if maxfail and self.testsfailed >= maxfail: + self.shouldfail = f"stopping after {self.testsfailed} failures" + + pytest_collectreport = pytest_runtest_logreport + + def isinitpath( + self, + path: str | os.PathLike[str], + *, + with_parents: bool = False, + ) -> bool: + """Is path an initial path? + + An initial path is a path explicitly given to pytest on the command + line. + + :param with_parents: + If set, also return True if the path is a parent of an initial path. + + .. versionchanged:: 8.0 + Added the ``with_parents`` parameter. + """ + # Optimization: Path(Path(...)) is much slower than isinstance. + path_ = path if isinstance(path, Path) else Path(path) + if with_parents: + return path_ in self._initialpaths_with_parents + else: + return path_ in self._initialpaths + + def gethookproxy(self, fspath: os.PathLike[str]) -> pluggy.HookRelay: + # Optimization: Path(Path(...)) is much slower than isinstance. + path = fspath if isinstance(fspath, Path) else Path(fspath) + pm = self.config.pluginmanager + # Check if we have the common case of running + # hooks with all conftest.py files. + my_conftestmodules = pm._getconftestmodules(path) + remove_mods = pm._conftest_plugins.difference(my_conftestmodules) + proxy: pluggy.HookRelay + if remove_mods: + # One or more conftests are not in use at this path. + proxy = PathAwareHookProxy(FSHookProxy(pm, remove_mods)) # type: ignore[arg-type,assignment] + else: + # All plugins are active for this fspath. + proxy = self.config.hook + return proxy + + def _collect_path( + self, + path: Path, + path_cache: dict[Path, Sequence[nodes.Collector]], + ) -> Sequence[nodes.Collector]: + """Create a Collector for the given path. + + `path_cache` makes it so the same Collectors are returned for the same + path. + """ + if path in path_cache: + return path_cache[path] + + if path.is_dir(): + ihook = self.gethookproxy(path.parent) + col: nodes.Collector | None = ihook.pytest_collect_directory( + path=path, parent=self + ) + cols: Sequence[nodes.Collector] = (col,) if col is not None else () + + elif path.is_file(): + ihook = self.gethookproxy(path) + cols = ihook.pytest_collect_file(file_path=path, parent=self) + + else: + # Broken symlink or invalid/missing file. + cols = () + + path_cache[path] = cols + return cols + + @overload + def perform_collect( + self, args: Sequence[str] | None = ..., genitems: Literal[True] = ... + ) -> Sequence[nodes.Item]: ... + + @overload + def perform_collect( + self, args: Sequence[str] | None = ..., genitems: bool = ... + ) -> Sequence[nodes.Item | nodes.Collector]: ... + + def perform_collect( + self, args: Sequence[str] | None = None, genitems: bool = True + ) -> Sequence[nodes.Item | nodes.Collector]: + """Perform the collection phase for this session. + + This is called by the default :hook:`pytest_collection` hook + implementation; see the documentation of this hook for more details. + For testing purposes, it may also be called directly on a fresh + ``Session``. + + This function normally recursively expands any collectors collected + from the session to their items, and only items are returned. For + testing purposes, this may be suppressed by passing ``genitems=False``, + in which case the return value contains these collectors unexpanded, + and ``session.items`` is empty. + """ + if args is None: + args = self.config.args + + self.trace("perform_collect", self, args) + self.trace.root.indent += 1 + + hook = self.config.hook + + self._notfound = [] + self._initial_parts = [] + self._collection_cache = {} + self.items = [] + items: Sequence[nodes.Item | nodes.Collector] = self.items + consider_namespace_packages: bool = self.config.getini( + "consider_namespace_packages" + ) + try: + initialpaths: list[Path] = [] + initialpaths_with_parents: list[Path] = [] + + collection_args = [ + resolve_collection_argument( + self.config.invocation_params.dir, + arg, + i, + as_pypath=self.config.option.pyargs, + consider_namespace_packages=consider_namespace_packages, + ) + for i, arg in enumerate(args) + ] + + if not self.config.getoption("keepduplicates"): + # Normalize the collection arguments -- remove duplicates and overlaps. + self._initial_parts = normalize_collection_arguments(collection_args) + else: + self._initial_parts = collection_args + + for collection_argument in self._initial_parts: + initialpaths.append(collection_argument.path) + initialpaths_with_parents.append(collection_argument.path) + initialpaths_with_parents.extend(collection_argument.path.parents) + self._initialpaths = frozenset(initialpaths) + self._initialpaths_with_parents = frozenset(initialpaths_with_parents) + + rep = collect_one_node(self) + self.ihook.pytest_collectreport(report=rep) + self.trace.root.indent -= 1 + if self._notfound: + errors = [] + for arg, collectors in self._notfound: + if collectors: + errors.append( + f"not found: {arg}\n(no match in any of {collectors!r})" + ) + else: + errors.append(f"found no collectors for {arg}") + + raise UsageError(*errors) + + if not genitems: + items = rep.result + else: + if rep.passed: + for node in rep.result: + self.items.extend(self.genitems(node)) + + self.config.pluginmanager.check_pending() + hook.pytest_collection_modifyitems( + session=self, config=self.config, items=items + ) + finally: + self._notfound = [] + self._initial_parts = [] + self._collection_cache = {} + hook.pytest_collection_finish(session=self) + + if genitems: + self.testscollected = len(items) + + return items + + def _collect_one_node( + self, + node: nodes.Collector, + handle_dupes: bool = True, + ) -> tuple[CollectReport, bool]: + if node in self._collection_cache and handle_dupes: + rep = self._collection_cache[node] + return rep, True + else: + rep = collect_one_node(node) + self._collection_cache[node] = rep + return rep, False + + def collect(self) -> Iterator[nodes.Item | nodes.Collector]: + # This is a cache for the root directories of the initial paths. + # We can't use collection_cache for Session because of its special + # role as the bootstrapping collector. + path_cache: dict[Path, Sequence[nodes.Collector]] = {} + + pm = self.config.pluginmanager + + for collection_argument in self._initial_parts: + self.trace("processing argument", collection_argument) + self.trace.root.indent += 1 + + argpath = collection_argument.path + names = collection_argument.parts + parametrization = collection_argument.parametrization + module_name = collection_argument.module_name + + # resolve_collection_argument() ensures this. + if argpath.is_dir(): + assert not names, f"invalid arg {(argpath, names)!r}" + + paths = [argpath] + # Add relevant parents of the path, from the root, e.g. + # /a/b/c.py -> [/, /a, /a/b, /a/b/c.py] + if module_name is None: + # Paths outside of the confcutdir should not be considered. + for path in argpath.parents: + if not pm._is_in_confcutdir(path): + break + paths.insert(0, path) + else: + # For --pyargs arguments, only consider paths matching the module + # name. Paths beyond the package hierarchy are not included. + module_name_parts = module_name.split(".") + for i, path in enumerate(argpath.parents, 2): + if i > len(module_name_parts) or path.stem != module_name_parts[-i]: + break + paths.insert(0, path) + + # Start going over the parts from the root, collecting each level + # and discarding all nodes which don't match the level's part. + any_matched_in_initial_part = False + notfound_collectors = [] + work: list[tuple[nodes.Collector | nodes.Item, list[Path | str]]] = [ + (self, [*paths, *names]) + ] + while work: + matchnode, matchparts = work.pop() + + # Pop'd all of the parts, this is a match. + if not matchparts: + yield matchnode + any_matched_in_initial_part = True + continue + + # Should have been matched by now, discard. + if not isinstance(matchnode, nodes.Collector): + continue + + # Collect this level of matching. + # Collecting Session (self) is done directly to avoid endless + # recursion to this function. + subnodes: Sequence[nodes.Collector | nodes.Item] + if isinstance(matchnode, Session): + assert isinstance(matchparts[0], Path) + subnodes = matchnode._collect_path(matchparts[0], path_cache) + else: + # For backward compat, files given directly multiple + # times on the command line should not be deduplicated. + handle_dupes = not ( + len(matchparts) == 1 + and isinstance(matchparts[0], Path) + and matchparts[0].is_file() + ) + rep, duplicate = self._collect_one_node(matchnode, handle_dupes) + if not duplicate and not rep.passed: + # Report collection failures here to avoid failing to + # run some test specified in the command line because + # the module could not be imported (#134). + matchnode.ihook.pytest_collectreport(report=rep) + if not rep.passed: + continue + subnodes = rep.result + + # Prune this level. + any_matched_in_collector = False + for node in reversed(subnodes): + # Path part e.g. `/a/b/` in `/a/b/test_file.py::TestIt::test_it`. + if isinstance(matchparts[0], Path): + is_match = node.path == matchparts[0] + if sys.platform == "win32" and not is_match: + # In case the file paths do not match, fallback to samefile() to + # account for short-paths on Windows (#11895). But use a version + # which doesn't resolve symlinks, otherwise we might match the + # same file more than once (#12039). + is_match = samefile_nofollow(node.path, matchparts[0]) + + # Name part e.g. `TestIt` in `/a/b/test_file.py::TestIt::test_it`. + else: + if len(matchparts) == 1: + # This the last part, one parametrization goes. + if parametrization is not None: + # A parametrized arg must match exactly. + is_match = node.name == matchparts[0] + parametrization + else: + # A non-parameterized arg matches all parametrizations (if any). + # TODO: Remove the hacky split once the collection structure + # contains parametrization. + is_match = node.name.split("[")[0] == matchparts[0] + else: + is_match = node.name == matchparts[0] + if is_match: + work.append((node, matchparts[1:])) + any_matched_in_collector = True + + if not any_matched_in_collector: + notfound_collectors.append(matchnode) + + if not any_matched_in_initial_part: + report_arg = "::".join((str(argpath), *names)) + self._notfound.append((report_arg, notfound_collectors)) + + self.trace.root.indent -= 1 + + def genitems(self, node: nodes.Item | nodes.Collector) -> Iterator[nodes.Item]: + self.trace("genitems", node) + if isinstance(node, nodes.Item): + node.ihook.pytest_itemcollected(item=node) + yield node + else: + assert isinstance(node, nodes.Collector) + # For backward compat, dedup only applies to files. + handle_dupes = not isinstance(node, nodes.File) + rep, duplicate = self._collect_one_node(node, handle_dupes) + if rep.passed: + for subnode in rep.result: + yield from self.genitems(subnode) + if not duplicate: + node.ihook.pytest_collectreport(report=rep) + + +def search_pypath( + module_name: str, *, consider_namespace_packages: bool = False +) -> str | None: + """Search sys.path for the given a dotted module name, and return its file + system path if found.""" + try: + spec = importlib.util.find_spec(module_name) + # AttributeError: looks like package module, but actually filename + # ImportError: module does not exist + # ValueError: not a module name + except (AttributeError, ImportError, ValueError): + return None + + if spec is None: + return None + + if ( + spec.submodule_search_locations is None + or len(spec.submodule_search_locations) == 0 + ): + # Must be a simple module. + return spec.origin + + if consider_namespace_packages: + # If submodule_search_locations is set, it's a package (regular or namespace). + # Typically there is a single entry, but documentation claims it can be empty too + # (e.g. if the package has no physical location). + return spec.submodule_search_locations[0] + + if spec.origin is None: + # This is only the case for namespace packages + return None + + return os.path.dirname(spec.origin) + + +@dataclasses.dataclass(frozen=True) +class CollectionArgument: + """A resolved collection argument.""" + + path: Path + parts: Sequence[str] + parametrization: str | None + module_name: str | None + original_index: int + + +def resolve_collection_argument( + invocation_path: Path, + arg: str, + arg_index: int, + *, + as_pypath: bool = False, + consider_namespace_packages: bool = False, +) -> CollectionArgument: + """Parse path arguments optionally containing selection parts and return (fspath, names). + + Command-line arguments can point to files and/or directories, and optionally contain + parts for specific tests selection, for example: + + "pkg/tests/test_foo.py::TestClass::test_foo" + + This function ensures the path exists, and returns a resolved `CollectionArgument`: + + CollectionArgument( + path=Path("/full/path/to/pkg/tests/test_foo.py"), + parts=["TestClass", "test_foo"], + module_name=None, + ) + + When as_pypath is True, expects that the command-line argument actually contains + module paths instead of file-system paths: + + "pkg.tests.test_foo::TestClass::test_foo[a,b]" + + In which case we search sys.path for a matching module, and then return the *path* to the + found module, which may look like this: + + CollectionArgument( + path=Path("/home/u/myvenv/lib/site-packages/pkg/tests/test_foo.py"), + parts=["TestClass", "test_foo"], + parametrization="[a,b]", + module_name="pkg.tests.test_foo", + ) + + If the path doesn't exist, raise UsageError. + If the path is a directory and selection parts are present, raise UsageError. + """ + base, squacket, rest = arg.partition("[") + strpath, *parts = base.split("::") + if squacket and not parts: + raise UsageError(f"path cannot contain [] parametrization: {arg}") + parametrization = f"{squacket}{rest}" if squacket else None + module_name = None + if as_pypath: + pyarg_strpath = search_pypath( + strpath, consider_namespace_packages=consider_namespace_packages + ) + if pyarg_strpath is not None: + module_name = strpath + strpath = pyarg_strpath + fspath = invocation_path / strpath + fspath = absolutepath(fspath) + if not safe_exists(fspath): + msg = ( + "module or package not found: {arg} (missing __init__.py?)" + if as_pypath + else "file or directory not found: {arg}" + ) + raise UsageError(msg.format(arg=arg)) + if parts and fspath.is_dir(): + msg = ( + "package argument cannot contain :: selection parts: {arg}" + if as_pypath + else "directory argument cannot contain :: selection parts: {arg}" + ) + raise UsageError(msg.format(arg=arg)) + return CollectionArgument( + path=fspath, + parts=parts, + parametrization=parametrization, + module_name=module_name, + original_index=arg_index, + ) + + +def is_collection_argument_subsumed_by( + arg: CollectionArgument, by: CollectionArgument +) -> bool: + """Check if `arg` is subsumed (contained) by `by`.""" + # First check path subsumption. + if by.path != arg.path: + # `by` subsumes `arg` if `by` is a parent directory of `arg` and has no + # parts (collects everything in that directory). + if not by.parts: + return arg.path.is_relative_to(by.path) + return False + # Paths are equal, check parts. + # For example: ("TestClass",) is a prefix of ("TestClass", "test_method"). + if len(by.parts) > len(arg.parts) or arg.parts[: len(by.parts)] != by.parts: + return False + # Paths and parts are equal, check parametrization. + # A `by` without parametrization (None) matches everything, e.g. + # `pytest x.py::test_it` matches `x.py::test_it[0]`. Otherwise must be + # exactly equal. + if by.parametrization is not None and by.parametrization != arg.parametrization: + return False + return True + + +def normalize_collection_arguments( + collection_args: Sequence[CollectionArgument], +) -> list[CollectionArgument]: + """Normalize collection arguments to eliminate overlapping paths and parts. + + Detects when collection arguments overlap in either paths or parts and only + keeps the shorter prefix, or the earliest argument if duplicate, preserving + order. The result is prefix-free. + """ + # A quadratic algorithm is not acceptable since large inputs are possible. + # So this uses an O(n*log(n)) algorithm which takes advantage of the + # property that after sorting, a collection argument will immediately + # precede collection arguments it subsumes. An O(n) algorithm is not worth + # it. + collection_args_sorted = sorted( + collection_args, + key=lambda arg: (arg.path, arg.parts, arg.parametrization or ""), + ) + normalized: list[CollectionArgument] = [] + last_kept = None + for arg in collection_args_sorted: + if last_kept is None or not is_collection_argument_subsumed_by(arg, last_kept): + normalized.append(arg) + last_kept = arg + normalized.sort(key=lambda arg: arg.original_index) + return normalized diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/mark/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/mark/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..841d7811fddbb96a7ac7615e998602b834ba091a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/mark/__init__.py @@ -0,0 +1,301 @@ +"""Generic mechanism for marking and selecting python functions.""" + +from __future__ import annotations + +import collections +from collections.abc import Collection +from collections.abc import Iterable +from collections.abc import Set as AbstractSet +import dataclasses +from typing import TYPE_CHECKING + +from .expression import Expression +from .structures import _HiddenParam +from .structures import EMPTY_PARAMETERSET_OPTION +from .structures import get_empty_parameterset_mark +from .structures import HIDDEN_PARAM +from .structures import Mark +from .structures import MARK_GEN +from .structures import MarkDecorator +from .structures import MarkGenerator +from .structures import ParameterSet +from _pytest.config import Config +from _pytest.config import ExitCode +from _pytest.config import hookimpl +from _pytest.config import UsageError +from _pytest.config.argparsing import NOT_SET +from _pytest.config.argparsing import Parser +from _pytest.stash import StashKey + + +if TYPE_CHECKING: + from _pytest.nodes import Item + + +__all__ = [ + "HIDDEN_PARAM", + "MARK_GEN", + "Mark", + "MarkDecorator", + "MarkGenerator", + "ParameterSet", + "get_empty_parameterset_mark", +] + + +old_mark_config_key = StashKey[Config | None]() + + +def param( + *values: object, + marks: MarkDecorator | Collection[MarkDecorator | Mark] = (), + id: str | _HiddenParam | None = None, +) -> ParameterSet: + """Specify a parameter in `pytest.mark.parametrize`_ calls or + :ref:`parametrized fixtures <fixture-parametrize-marks>`. + + .. code-block:: python + + @pytest.mark.parametrize( + "test_input,expected", + [ + ("3+5", 8), + pytest.param("6*9", 42, marks=pytest.mark.xfail), + ], + ) + def test_eval(test_input, expected): + assert eval(test_input) == expected + + :param values: Variable args of the values of the parameter set, in order. + + :param marks: + A single mark or a list of marks to be applied to this parameter set. + + :ref:`pytest.mark.usefixtures <pytest.mark.usefixtures ref>` cannot be added via this parameter. + + :type id: str | Literal[pytest.HIDDEN_PARAM] | None + :param id: + The id to attribute to this parameter set. + + .. versionadded:: 8.4 + :ref:`hidden-param` means to hide the parameter set + from the test name. Can only be used at most 1 time, as + test names need to be unique. + """ + return ParameterSet.param(*values, marks=marks, id=id) + + +def pytest_addoption(parser: Parser) -> None: + group = parser.getgroup("general") + group._addoption( # private to use reserved lower-case short option + "-k", + action="store", + dest="keyword", + default="", + metavar="EXPRESSION", + help="Only run tests which match the given substring expression. " + "An expression is a Python evaluable expression " + "where all names are substring-matched against test names " + "and their parent classes. Example: -k 'test_method or test_" + "other' matches all test functions and classes whose name " + "contains 'test_method' or 'test_other', while -k 'not test_method' " + "matches those that don't contain 'test_method' in their names. " + "-k 'not test_method and not test_other' will eliminate the matches. " + "Additionally keywords are matched to classes and functions " + "containing extra names in their 'extra_keyword_matches' set, " + "as well as functions which have names assigned directly to them. " + "The matching is case-insensitive.", + ) + + group._addoption( # private to use reserved lower-case short option + "-m", + action="store", + dest="markexpr", + default="", + metavar="MARKEXPR", + help="Only run tests matching given mark expression. " + "For example: -m 'mark1 and not mark2'.", + ) + + group.addoption( + "--markers", + action="store_true", + help="show markers (builtin, plugin and per-project ones).", + ) + + parser.addini("markers", "Register new markers for test functions", "linelist") + parser.addini(EMPTY_PARAMETERSET_OPTION, "Default marker for empty parametersets") + + +@hookimpl(tryfirst=True) +def pytest_cmdline_main(config: Config) -> int | ExitCode | None: + import _pytest.config + + if config.option.markers: + config._do_configure() + tw = _pytest.config.create_terminal_writer(config) + for line in config.getini("markers"): + parts = line.split(":", 1) + name = parts[0] + rest = parts[1] if len(parts) == 2 else "" + tw.write(f"@pytest.mark.{name}:", bold=True) + tw.line(rest) + tw.line() + config._ensure_unconfigure() + return 0 + + return None + + +@dataclasses.dataclass +class KeywordMatcher: + """A matcher for keywords. + + Given a list of names, matches any substring of one of these names. The + string inclusion check is case-insensitive. + + Will match on the name of colitem, including the names of its parents. + Only matches names of items which are either a :class:`Class` or a + :class:`Function`. + + Additionally, matches on names in the 'extra_keyword_matches' set of + any item, as well as names directly assigned to test functions. + """ + + __slots__ = ("_names",) + + _names: AbstractSet[str] + + @classmethod + def from_item(cls, item: Item) -> KeywordMatcher: + mapped_names = set() + + # Add the names of the current item and any parent items, + # except the Session and root Directory's which are not + # interesting for matching. + import pytest + + for node in item.listchain(): + if isinstance(node, pytest.Session): + continue + if isinstance(node, pytest.Directory) and isinstance( + node.parent, pytest.Session + ): + continue + mapped_names.add(node.name) + + # Add the names added as extra keywords to current or parent items. + mapped_names.update(item.listextrakeywords()) + + # Add the names attached to the current function through direct assignment. + function_obj = getattr(item, "function", None) + if function_obj: + mapped_names.update(function_obj.__dict__) + + # Add the markers to the keywords as we no longer handle them correctly. + mapped_names.update(mark.name for mark in item.iter_markers()) + + return cls(mapped_names) + + def __call__(self, subname: str, /, **kwargs: str | int | bool | None) -> bool: + if kwargs: + raise UsageError("Keyword expressions do not support call parameters.") + subname = subname.lower() + return any(subname in name.lower() for name in self._names) + + +def deselect_by_keyword(items: list[Item], config: Config) -> None: + keywordexpr = config.option.keyword.lstrip() + if not keywordexpr: + return + + expr = _parse_expression(keywordexpr, "Wrong expression passed to '-k'") + + remaining = [] + deselected = [] + for colitem in items: + if not expr.evaluate(KeywordMatcher.from_item(colitem)): + deselected.append(colitem) + else: + remaining.append(colitem) + + if deselected: + config.hook.pytest_deselected(items=deselected) + items[:] = remaining + + +@dataclasses.dataclass +class MarkMatcher: + """A matcher for markers which are present. + + Tries to match on any marker names, attached to the given colitem. + """ + + __slots__ = ("own_mark_name_mapping",) + + own_mark_name_mapping: dict[str, list[Mark]] + + @classmethod + def from_markers(cls, markers: Iterable[Mark]) -> MarkMatcher: + mark_name_mapping = collections.defaultdict(list) + for mark in markers: + mark_name_mapping[mark.name].append(mark) + return cls(mark_name_mapping) + + def __call__(self, name: str, /, **kwargs: str | int | bool | None) -> bool: + if not (matches := self.own_mark_name_mapping.get(name, [])): + return False + + for mark in matches: # pylint: disable=consider-using-any-or-all + if all(mark.kwargs.get(k, NOT_SET) == v for k, v in kwargs.items()): + return True + return False + + +def deselect_by_mark(items: list[Item], config: Config) -> None: + matchexpr = config.option.markexpr + if not matchexpr: + return + + expr = _parse_expression(matchexpr, "Wrong expression passed to '-m'") + remaining: list[Item] = [] + deselected: list[Item] = [] + for item in items: + if expr.evaluate(MarkMatcher.from_markers(item.iter_markers())): + remaining.append(item) + else: + deselected.append(item) + if deselected: + config.hook.pytest_deselected(items=deselected) + items[:] = remaining + + +def _parse_expression(expr: str, exc_message: str) -> Expression: + try: + return Expression.compile(expr) + except SyntaxError as e: + raise UsageError( + f"{exc_message}: {e.text}: at column {e.offset}: {e.msg}" + ) from None + + +def pytest_collection_modifyitems(items: list[Item], config: Config) -> None: + deselect_by_keyword(items, config) + deselect_by_mark(items, config) + + +def pytest_configure(config: Config) -> None: + config.stash[old_mark_config_key] = MARK_GEN._config + MARK_GEN._config = config + + empty_parameterset = config.getini(EMPTY_PARAMETERSET_OPTION) + + if empty_parameterset not in ("skip", "xfail", "fail_at_collect", None, ""): + raise UsageError( + f"{EMPTY_PARAMETERSET_OPTION!s} must be one of skip, xfail or fail_at_collect" + f" but it is {empty_parameterset!r}" + ) + + +def pytest_unconfigure(config: Config) -> None: + MARK_GEN._config = config.stash.get(old_mark_config_key, None) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/mark/expression.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/mark/expression.py new file mode 100644 index 0000000000000000000000000000000000000000..3bdbd03c2b55ca20aba1c56d49056a9cf13d4953 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/mark/expression.py @@ -0,0 +1,353 @@ +r"""Evaluate match expressions, as used by `-k` and `-m`. + +The grammar is: + +expression: expr? EOF +expr: and_expr ('or' and_expr)* +and_expr: not_expr ('and' not_expr)* +not_expr: 'not' not_expr | '(' expr ')' | ident kwargs? + +ident: (\w|:|\+|-|\.|\[|\]|\\|/)+ +kwargs: ('(' name '=' value ( ', ' name '=' value )* ')') +name: a valid ident, but not a reserved keyword +value: (unescaped) string literal | (-)?[0-9]+ | 'False' | 'True' | 'None' + +The semantics are: + +- Empty expression evaluates to False. +- ident evaluates to True or False according to a provided matcher function. +- ident with parentheses and keyword arguments evaluates to True or False according to a provided matcher function. +- or/and/not evaluate according to the usual boolean semantics. +""" + +from __future__ import annotations + +import ast +from collections.abc import Iterator +from collections.abc import Mapping +from collections.abc import Sequence +import dataclasses +import enum +import keyword +import re +import types +from typing import Final +from typing import final +from typing import Literal +from typing import NoReturn +from typing import overload +from typing import Protocol + + +__all__ = [ + "Expression", + "ExpressionMatcher", +] + + +FILE_NAME: Final = "<pytest match expression>" + + +class TokenType(enum.Enum): + LPAREN = "left parenthesis" + RPAREN = "right parenthesis" + OR = "or" + AND = "and" + NOT = "not" + IDENT = "identifier" + EOF = "end of input" + EQUAL = "=" + STRING = "string literal" + COMMA = "," + + +@dataclasses.dataclass(frozen=True) +class Token: + __slots__ = ("pos", "type", "value") + type: TokenType + value: str + pos: int + + +class Scanner: + __slots__ = ("current", "input", "tokens") + + def __init__(self, input: str) -> None: + self.input = input + self.tokens = self.lex(input) + self.current = next(self.tokens) + + def lex(self, input: str) -> Iterator[Token]: + pos = 0 + while pos < len(input): + if input[pos] in (" ", "\t"): + pos += 1 + elif input[pos] == "(": + yield Token(TokenType.LPAREN, "(", pos) + pos += 1 + elif input[pos] == ")": + yield Token(TokenType.RPAREN, ")", pos) + pos += 1 + elif input[pos] == "=": + yield Token(TokenType.EQUAL, "=", pos) + pos += 1 + elif input[pos] == ",": + yield Token(TokenType.COMMA, ",", pos) + pos += 1 + elif (quote_char := input[pos]) in ("'", '"'): + end_quote_pos = input.find(quote_char, pos + 1) + if end_quote_pos == -1: + raise SyntaxError( + f'closing quote "{quote_char}" is missing', + (FILE_NAME, 1, pos + 1, input), + ) + value = input[pos : end_quote_pos + 1] + if (backslash_pos := input.find("\\")) != -1: + raise SyntaxError( + r'escaping with "\" not supported in marker expression', + (FILE_NAME, 1, backslash_pos + 1, input), + ) + yield Token(TokenType.STRING, value, pos) + pos += len(value) + else: + match = re.match(r"(:?\w|:|\+|-|\.|\[|\]|\\|/)+", input[pos:]) + if match: + value = match.group(0) + if value == "or": + yield Token(TokenType.OR, value, pos) + elif value == "and": + yield Token(TokenType.AND, value, pos) + elif value == "not": + yield Token(TokenType.NOT, value, pos) + else: + yield Token(TokenType.IDENT, value, pos) + pos += len(value) + else: + raise SyntaxError( + f'unexpected character "{input[pos]}"', + (FILE_NAME, 1, pos + 1, input), + ) + yield Token(TokenType.EOF, "", pos) + + @overload + def accept(self, type: TokenType, *, reject: Literal[True]) -> Token: ... + + @overload + def accept( + self, type: TokenType, *, reject: Literal[False] = False + ) -> Token | None: ... + + def accept(self, type: TokenType, *, reject: bool = False) -> Token | None: + if self.current.type is type: + token = self.current + if token.type is not TokenType.EOF: + self.current = next(self.tokens) + return token + if reject: + self.reject((type,)) + return None + + def reject(self, expected: Sequence[TokenType]) -> NoReturn: + raise SyntaxError( + "expected {}; got {}".format( + " OR ".join(type.value for type in expected), + self.current.type.value, + ), + (FILE_NAME, 1, self.current.pos + 1, self.input), + ) + + +# True, False and None are legal match expression identifiers, +# but illegal as Python identifiers. To fix this, this prefix +# is added to identifiers in the conversion to Python AST. +IDENT_PREFIX = "$" + + +def expression(s: Scanner) -> ast.Expression: + if s.accept(TokenType.EOF): + ret: ast.expr = ast.Constant(False) + else: + ret = expr(s) + s.accept(TokenType.EOF, reject=True) + return ast.fix_missing_locations(ast.Expression(ret)) + + +def expr(s: Scanner) -> ast.expr: + ret = and_expr(s) + while s.accept(TokenType.OR): + rhs = and_expr(s) + ret = ast.BoolOp(ast.Or(), [ret, rhs]) + return ret + + +def and_expr(s: Scanner) -> ast.expr: + ret = not_expr(s) + while s.accept(TokenType.AND): + rhs = not_expr(s) + ret = ast.BoolOp(ast.And(), [ret, rhs]) + return ret + + +def not_expr(s: Scanner) -> ast.expr: + if s.accept(TokenType.NOT): + return ast.UnaryOp(ast.Not(), not_expr(s)) + if s.accept(TokenType.LPAREN): + ret = expr(s) + s.accept(TokenType.RPAREN, reject=True) + return ret + ident = s.accept(TokenType.IDENT) + if ident: + name = ast.Name(IDENT_PREFIX + ident.value, ast.Load()) + if s.accept(TokenType.LPAREN): + ret = ast.Call(func=name, args=[], keywords=all_kwargs(s)) + s.accept(TokenType.RPAREN, reject=True) + else: + ret = name + return ret + + s.reject((TokenType.NOT, TokenType.LPAREN, TokenType.IDENT)) + + +BUILTIN_MATCHERS = {"True": True, "False": False, "None": None} + + +def single_kwarg(s: Scanner) -> ast.keyword: + keyword_name = s.accept(TokenType.IDENT, reject=True) + if not keyword_name.value.isidentifier(): + raise SyntaxError( + f"not a valid python identifier {keyword_name.value}", + (FILE_NAME, 1, keyword_name.pos + 1, s.input), + ) + if keyword.iskeyword(keyword_name.value): + raise SyntaxError( + f"unexpected reserved python keyword `{keyword_name.value}`", + (FILE_NAME, 1, keyword_name.pos + 1, s.input), + ) + s.accept(TokenType.EQUAL, reject=True) + + if value_token := s.accept(TokenType.STRING): + value: str | int | bool | None = value_token.value[1:-1] # strip quotes + else: + value_token = s.accept(TokenType.IDENT, reject=True) + if (number := value_token.value).isdigit() or ( + number.startswith("-") and number[1:].isdigit() + ): + value = int(number) + elif value_token.value in BUILTIN_MATCHERS: + value = BUILTIN_MATCHERS[value_token.value] + else: + raise SyntaxError( + f'unexpected character/s "{value_token.value}"', + (FILE_NAME, 1, value_token.pos + 1, s.input), + ) + + ret = ast.keyword(keyword_name.value, ast.Constant(value)) + return ret + + +def all_kwargs(s: Scanner) -> list[ast.keyword]: + ret = [single_kwarg(s)] + while s.accept(TokenType.COMMA): + ret.append(single_kwarg(s)) + return ret + + +class ExpressionMatcher(Protocol): + """A callable which, given an identifier and optional kwargs, should return + whether it matches in an :class:`Expression` evaluation. + + Should be prepared to handle arbitrary strings as input. + + If no kwargs are provided, the expression of the form `foo`. + If kwargs are provided, the expression is of the form `foo(1, b=True, "s")`. + + If the expression is not supported (e.g. don't want to accept the kwargs + syntax variant), should raise :class:`~pytest.UsageError`. + + Example:: + + def matcher(name: str, /, **kwargs: str | int | bool | None) -> bool: + # Match `cat`. + if name == "cat" and not kwargs: + return True + # Match `dog(barks=True)`. + if name == "dog" and kwargs == {"barks": False}: + return True + return False + """ + + def __call__(self, name: str, /, **kwargs: str | int | bool | None) -> bool: ... + + +@dataclasses.dataclass +class MatcherNameAdapter: + matcher: ExpressionMatcher + name: str + + def __bool__(self) -> bool: + return self.matcher(self.name) + + def __call__(self, **kwargs: str | int | bool | None) -> bool: + return self.matcher(self.name, **kwargs) + + +class MatcherAdapter(Mapping[str, MatcherNameAdapter]): + """Adapts a matcher function to a locals mapping as required by eval().""" + + def __init__(self, matcher: ExpressionMatcher) -> None: + self.matcher = matcher + + def __getitem__(self, key: str) -> MatcherNameAdapter: + return MatcherNameAdapter(matcher=self.matcher, name=key[len(IDENT_PREFIX) :]) + + def __iter__(self) -> Iterator[str]: + raise NotImplementedError() + + def __len__(self) -> int: + raise NotImplementedError() + + +@final +class Expression: + """A compiled match expression as used by -k and -m. + + The expression can be evaluated against different matchers. + """ + + __slots__ = ("_code", "input") + + def __init__(self, input: str, code: types.CodeType) -> None: + #: The original input line, as a string. + self.input: Final = input + self._code: Final = code + + @classmethod + def compile(cls, input: str) -> Expression: + """Compile a match expression. + + :param input: The input expression - one line. + + :raises SyntaxError: If the expression is malformed. + """ + astexpr = expression(Scanner(input)) + code = compile( + astexpr, + filename="<pytest match expression>", + mode="eval", + ) + return Expression(input, code) + + def evaluate(self, matcher: ExpressionMatcher) -> bool: + """Evaluate the match expression. + + :param matcher: + A callback which determines whether an identifier matches or not. + See the :class:`ExpressionMatcher` protocol for details and example. + + :returns: Whether the expression matches or not. + + :raises UsageError: + If the matcher doesn't support the expression. Cannot happen if the + matcher supports all expressions. + """ + return bool(eval(self._code, {"__builtins__": {}}, MatcherAdapter(matcher))) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/mark/structures.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/mark/structures.py new file mode 100644 index 0000000000000000000000000000000000000000..97842fc57049feba02e3f9f2cd81b3fb116bfb57 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/mark/structures.py @@ -0,0 +1,664 @@ +# mypy: allow-untyped-defs +from __future__ import annotations + +import collections.abc +from collections.abc import Callable +from collections.abc import Collection +from collections.abc import Iterable +from collections.abc import Iterator +from collections.abc import Mapping +from collections.abc import MutableMapping +from collections.abc import Sequence +import dataclasses +import enum +import inspect +from typing import Any +from typing import final +from typing import NamedTuple +from typing import overload +from typing import TYPE_CHECKING +from typing import TypeVar +import warnings + +from .._code import getfslineno +from ..compat import NOTSET +from ..compat import NotSetType +from _pytest.config import Config +from _pytest.deprecated import check_ispytest +from _pytest.deprecated import MARKED_FIXTURE +from _pytest.outcomes import fail +from _pytest.raises import AbstractRaises +from _pytest.scope import _ScopeName +from _pytest.warning_types import PytestUnknownMarkWarning + + +if TYPE_CHECKING: + from ..nodes import Node + + +EMPTY_PARAMETERSET_OPTION = "empty_parameter_set_mark" + + +# Singleton type for HIDDEN_PARAM, as described in: +# https://www.python.org/dev/peps/pep-0484/#support-for-singleton-types-in-unions +class _HiddenParam(enum.Enum): + token = 0 + + +#: Can be used as a parameter set id to hide it from the test name. +HIDDEN_PARAM = _HiddenParam.token + + +def istestfunc(func) -> bool: + return callable(func) and getattr(func, "__name__", "<lambda>") != "<lambda>" + + +def get_empty_parameterset_mark( + config: Config, argnames: Sequence[str], func +) -> MarkDecorator: + from ..nodes import Collector + + argslisting = ", ".join(argnames) + + _fs, lineno = getfslineno(func) + reason = f"got empty parameter set for ({argslisting})" + requested_mark = config.getini(EMPTY_PARAMETERSET_OPTION) + if requested_mark in ("", None, "skip"): + mark = MARK_GEN.skip(reason=reason) + elif requested_mark == "xfail": + mark = MARK_GEN.xfail(reason=reason, run=False) + elif requested_mark == "fail_at_collect": + raise Collector.CollectError( + f"Empty parameter set in '{func.__name__}' at line {lineno + 1}" + ) + else: + raise LookupError(requested_mark) + return mark + + +class ParameterSet(NamedTuple): + """A set of values for a set of parameters along with associated marks and + an optional ID for the set. + + Examples:: + + pytest.param(1, 2, 3) + # ParameterSet(values=(1, 2, 3), marks=(), id=None) + + pytest.param("hello", id="greeting") + # ParameterSet(values=("hello",), marks=(), id="greeting") + + # Parameter set with marks + pytest.param(42, marks=pytest.mark.xfail) + # ParameterSet(values=(42,), marks=(MarkDecorator(...),), id=None) + + # From parametrize mark (parameter names + list of parameter sets) + pytest.mark.parametrize( + ("a", "b", "expected"), + [ + (1, 2, 3), + pytest.param(40, 2, 42, id="everything"), + ], + ) + # ParameterSet(values=(1, 2, 3), marks=(), id=None) + # ParameterSet(values=(40, 2, 42), marks=(), id="everything") + """ + + values: Sequence[object | NotSetType] + marks: Collection[MarkDecorator | Mark] + id: str | _HiddenParam | None + + @classmethod + def param( + cls, + *values: object, + marks: MarkDecorator | Collection[MarkDecorator | Mark] = (), + id: str | _HiddenParam | None = None, + ) -> ParameterSet: + if isinstance(marks, MarkDecorator): + marks = (marks,) + else: + assert isinstance(marks, collections.abc.Collection) + if any(i.name == "usefixtures" for i in marks): + raise ValueError( + "pytest.param cannot add pytest.mark.usefixtures; see " + "https://docs.pytest.org/en/stable/reference/reference.html#pytest-param" + ) + + if id is not None: + if not isinstance(id, str) and id is not HIDDEN_PARAM: + raise TypeError( + "Expected id to be a string or a `pytest.HIDDEN_PARAM` sentinel, " + f"got {type(id)}: {id!r}", + ) + return cls(values, marks, id) + + @classmethod + def extract_from( + cls, + parameterset: ParameterSet | Sequence[object] | object, + force_tuple: bool = False, + ) -> ParameterSet: + """Extract from an object or objects. + + :param parameterset: + A legacy style parameterset that may or may not be a tuple, + and may or may not be wrapped into a mess of mark objects. + + :param force_tuple: + Enforce tuple wrapping so single argument tuple values + don't get decomposed and break tests. + """ + if isinstance(parameterset, cls): + return parameterset + if force_tuple: + return cls.param(parameterset) + else: + # TODO: Refactor to fix this type-ignore. Currently the following + # passes type-checking but crashes: + # + # @pytest.mark.parametrize(('x', 'y'), [1, 2]) + # def test_foo(x, y): pass + return cls(parameterset, marks=[], id=None) # type: ignore[arg-type] + + @staticmethod + def _parse_parametrize_args( + argnames: str | Sequence[str], + argvalues: Iterable[ParameterSet | Sequence[object] | object], + *args, + **kwargs, + ) -> tuple[Sequence[str], bool]: + if isinstance(argnames, str): + argnames = [x.strip() for x in argnames.split(",") if x.strip()] + force_tuple = len(argnames) == 1 + else: + force_tuple = False + return argnames, force_tuple + + @staticmethod + def _parse_parametrize_parameters( + argvalues: Iterable[ParameterSet | Sequence[object] | object], + force_tuple: bool, + ) -> list[ParameterSet]: + return [ + ParameterSet.extract_from(x, force_tuple=force_tuple) for x in argvalues + ] + + @classmethod + def _for_parametrize( + cls, + argnames: str | Sequence[str], + argvalues: Iterable[ParameterSet | Sequence[object] | object], + func, + config: Config, + nodeid: str, + ) -> tuple[Sequence[str], list[ParameterSet]]: + argnames, force_tuple = cls._parse_parametrize_args(argnames, argvalues) + parameters = cls._parse_parametrize_parameters(argvalues, force_tuple) + del argvalues + + if parameters: + # Check all parameter sets have the correct number of values. + for param in parameters: + if len(param.values) != len(argnames): + msg = ( + '{nodeid}: in "parametrize" the number of names ({names_len}):\n' + " {names}\n" + "must be equal to the number of values ({values_len}):\n" + " {values}" + ) + fail( + msg.format( + nodeid=nodeid, + values=param.values, + names=argnames, + names_len=len(argnames), + values_len=len(param.values), + ), + pytrace=False, + ) + else: + # Empty parameter set (likely computed at runtime): create a single + # parameter set with NOTSET values, with the "empty parameter set" mark applied to it. + mark = get_empty_parameterset_mark(config, argnames, func) + parameters.append( + ParameterSet( + values=(NOTSET,) * len(argnames), marks=[mark], id="NOTSET" + ) + ) + return argnames, parameters + + +@final +@dataclasses.dataclass(frozen=True) +class Mark: + """A pytest mark.""" + + #: Name of the mark. + name: str + #: Positional arguments of the mark decorator. + args: tuple[Any, ...] + #: Keyword arguments of the mark decorator. + kwargs: Mapping[str, Any] + + #: Source Mark for ids with parametrize Marks. + _param_ids_from: Mark | None = dataclasses.field(default=None, repr=False) + #: Resolved/generated ids with parametrize Marks. + _param_ids_generated: Sequence[str] | None = dataclasses.field( + default=None, repr=False + ) + + def __init__( + self, + name: str, + args: tuple[Any, ...], + kwargs: Mapping[str, Any], + param_ids_from: Mark | None = None, + param_ids_generated: Sequence[str] | None = None, + *, + _ispytest: bool = False, + ) -> None: + """:meta private:""" + check_ispytest(_ispytest) + # Weirdness to bypass frozen=True. + object.__setattr__(self, "name", name) + object.__setattr__(self, "args", args) + object.__setattr__(self, "kwargs", kwargs) + object.__setattr__(self, "_param_ids_from", param_ids_from) + object.__setattr__(self, "_param_ids_generated", param_ids_generated) + + def _has_param_ids(self) -> bool: + return "ids" in self.kwargs or len(self.args) >= 4 + + def combined_with(self, other: Mark) -> Mark: + """Return a new Mark which is a combination of this + Mark and another Mark. + + Combines by appending args and merging kwargs. + + :param Mark other: The mark to combine with. + :rtype: Mark + """ + assert self.name == other.name + + # Remember source of ids with parametrize Marks. + param_ids_from: Mark | None = None + if self.name == "parametrize": + if other._has_param_ids(): + param_ids_from = other + elif self._has_param_ids(): + param_ids_from = self + + return Mark( + self.name, + self.args + other.args, + dict(self.kwargs, **other.kwargs), + param_ids_from=param_ids_from, + _ispytest=True, + ) + + +# A generic parameter designating an object to which a Mark may +# be applied -- a test function (callable) or class. +# Note: a lambda is not allowed, but this can't be represented. +Markable = TypeVar("Markable", bound=Callable[..., object] | type) + + +@dataclasses.dataclass +class MarkDecorator: + """A decorator for applying a mark on test functions and classes. + + ``MarkDecorators`` are created with ``pytest.mark``:: + + mark1 = pytest.mark.NAME # Simple MarkDecorator + mark2 = pytest.mark.NAME(name1=value) # Parametrized MarkDecorator + + and can then be applied as decorators to test functions:: + + @mark2 + def test_function(): + pass + + When a ``MarkDecorator`` is called, it does the following: + + 1. If called with a single class as its only positional argument and no + additional keyword arguments, it attaches the mark to the class so it + gets applied automatically to all test cases found in that class. + + 2. If called with a single function as its only positional argument and + no additional keyword arguments, it attaches the mark to the function, + containing all the arguments already stored internally in the + ``MarkDecorator``. + + 3. When called in any other case, it returns a new ``MarkDecorator`` + instance with the original ``MarkDecorator``'s content updated with + the arguments passed to this call. + + Note: The rules above prevent a ``MarkDecorator`` from storing only a + single function or class reference as its positional argument with no + additional keyword or positional arguments. You can work around this by + using `with_args()`. + """ + + mark: Mark + + def __init__(self, mark: Mark, *, _ispytest: bool = False) -> None: + """:meta private:""" + check_ispytest(_ispytest) + self.mark = mark + + @property + def name(self) -> str: + """Alias for mark.name.""" + return self.mark.name + + @property + def args(self) -> tuple[Any, ...]: + """Alias for mark.args.""" + return self.mark.args + + @property + def kwargs(self) -> Mapping[str, Any]: + """Alias for mark.kwargs.""" + return self.mark.kwargs + + @property + def markname(self) -> str: + """:meta private:""" + return self.name # for backward-compat (2.4.1 had this attr) + + def with_args(self, *args: object, **kwargs: object) -> MarkDecorator: + """Return a MarkDecorator with extra arguments added. + + Unlike calling the MarkDecorator, with_args() can be used even + if the sole argument is a callable/class. + """ + mark = Mark(self.name, args, kwargs, _ispytest=True) + return MarkDecorator(self.mark.combined_with(mark), _ispytest=True) + + # Type ignored because the overloads overlap with an incompatible + # return type. Not much we can do about that. Thankfully mypy picks + # the first match so it works out even if we break the rules. + @overload + def __call__(self, arg: Markable) -> Markable: # type: ignore[overload-overlap] + pass + + @overload + def __call__(self, *args: object, **kwargs: object) -> MarkDecorator: + pass + + def __call__(self, *args: object, **kwargs: object): + """Call the MarkDecorator.""" + if args and not kwargs: + func = args[0] + is_class = inspect.isclass(func) + # For staticmethods/classmethods, the marks are eventually fetched from the + # function object, not the descriptor, so unwrap. + unwrapped_func = func + if isinstance(func, staticmethod | classmethod): + unwrapped_func = func.__func__ + if len(args) == 1 and (istestfunc(unwrapped_func) or is_class): + store_mark(unwrapped_func, self.mark, stacklevel=3) + return func + return self.with_args(*args, **kwargs) + + +def get_unpacked_marks( + obj: object | type, + *, + consider_mro: bool = True, +) -> list[Mark]: + """Obtain the unpacked marks that are stored on an object. + + If obj is a class and consider_mro is true, return marks applied to + this class and all of its super-classes in MRO order. If consider_mro + is false, only return marks applied directly to this class. + """ + if isinstance(obj, type): + if not consider_mro: + mark_lists = [obj.__dict__.get("pytestmark", [])] + else: + mark_lists = [ + x.__dict__.get("pytestmark", []) for x in reversed(obj.__mro__) + ] + mark_list = [] + for item in mark_lists: + if isinstance(item, list): + mark_list.extend(item) + else: + mark_list.append(item) + else: + mark_attribute = getattr(obj, "pytestmark", []) + if isinstance(mark_attribute, list): + mark_list = mark_attribute + else: + mark_list = [mark_attribute] + return list(normalize_mark_list(mark_list)) + + +def normalize_mark_list( + mark_list: Iterable[Mark | MarkDecorator], +) -> Iterable[Mark]: + """ + Normalize an iterable of Mark or MarkDecorator objects into a list of marks + by retrieving the `mark` attribute on MarkDecorator instances. + + :param mark_list: marks to normalize + :returns: A new list of the extracted Mark objects + """ + for mark in mark_list: + mark_obj = getattr(mark, "mark", mark) + if not isinstance(mark_obj, Mark): + raise TypeError(f"got {mark_obj!r} instead of Mark") + yield mark_obj + + +def store_mark(obj, mark: Mark, *, stacklevel: int = 2) -> None: + """Store a Mark on an object. + + This is used to implement the Mark declarations/decorators correctly. + """ + assert isinstance(mark, Mark), mark + + from ..fixtures import getfixturemarker + + if getfixturemarker(obj) is not None: + warnings.warn(MARKED_FIXTURE, stacklevel=stacklevel) + + # Always reassign name to avoid updating pytestmark in a reference that + # was only borrowed. + obj.pytestmark = [*get_unpacked_marks(obj, consider_mro=False), mark] + + +# Typing for builtin pytest marks. This is cheating; it gives builtin marks +# special privilege, and breaks modularity. But practicality beats purity... +if TYPE_CHECKING: + + class _SkipMarkDecorator(MarkDecorator): + @overload # type: ignore[override,no-overload-impl] + def __call__(self, arg: Markable) -> Markable: ... + + @overload + def __call__(self, reason: str = ...) -> MarkDecorator: ... + + class _SkipifMarkDecorator(MarkDecorator): + def __call__( # type: ignore[override] + self, + condition: str | bool = ..., + *conditions: str | bool, + reason: str = ..., + ) -> MarkDecorator: ... + + class _XfailMarkDecorator(MarkDecorator): + @overload # type: ignore[override,no-overload-impl] + def __call__(self, arg: Markable) -> Markable: ... + + @overload + def __call__( + self, + condition: str | bool = True, + *conditions: str | bool, + reason: str = ..., + run: bool = ..., + raises: None + | type[BaseException] + | tuple[type[BaseException], ...] + | AbstractRaises[BaseException] = ..., + strict: bool = ..., + ) -> MarkDecorator: ... + + class _ParametrizeMarkDecorator(MarkDecorator): + def __call__( # type: ignore[override] + self, + argnames: str | Sequence[str], + argvalues: Iterable[ParameterSet | Sequence[object] | object], + *, + indirect: bool | Sequence[str] = ..., + ids: Iterable[None | str | float | int | bool] + | Callable[[Any], object | None] + | None = ..., + scope: _ScopeName | None = ..., + ) -> MarkDecorator: ... + + class _UsefixturesMarkDecorator(MarkDecorator): + def __call__(self, *fixtures: str) -> MarkDecorator: # type: ignore[override] + ... + + class _FilterwarningsMarkDecorator(MarkDecorator): + def __call__(self, *filters: str) -> MarkDecorator: # type: ignore[override] + ... + + +@final +class MarkGenerator: + """Factory for :class:`MarkDecorator` objects - exposed as + a ``pytest.mark`` singleton instance. + + Example:: + + import pytest + + + @pytest.mark.slowtest + def test_function(): + pass + + applies a 'slowtest' :class:`Mark` on ``test_function``. + """ + + # See TYPE_CHECKING above. + if TYPE_CHECKING: + skip: _SkipMarkDecorator + skipif: _SkipifMarkDecorator + xfail: _XfailMarkDecorator + parametrize: _ParametrizeMarkDecorator + usefixtures: _UsefixturesMarkDecorator + filterwarnings: _FilterwarningsMarkDecorator + + def __init__(self, *, _ispytest: bool = False) -> None: + check_ispytest(_ispytest) + self._config: Config | None = None + self._markers: set[str] = set() + + def __getattr__(self, name: str) -> MarkDecorator: + """Generate a new :class:`MarkDecorator` with the given name.""" + if name[0] == "_": + raise AttributeError("Marker name must NOT start with underscore") + + if self._config is not None: + # We store a set of markers as a performance optimisation - if a mark + # name is in the set we definitely know it, but a mark may be known and + # not in the set. We therefore start by updating the set! + if name not in self._markers: + for line in self._config.getini("markers"): + # example lines: "skipif(condition): skip the given test if..." + # or "hypothesis: tests which use Hypothesis", so to get the + # marker name we split on both `:` and `(`. + marker = line.split(":")[0].split("(")[0].strip() + self._markers.add(marker) + + # If the name is not in the set of known marks after updating, + # then it really is time to issue a warning or an error. + if name not in self._markers: + # Raise a specific error for common misspellings of "parametrize". + if name in ["parameterize", "parametrise", "parameterise"]: + __tracebackhide__ = True + fail(f"Unknown '{name}' mark, did you mean 'parametrize'?") + + strict_markers = self._config.getini("strict_markers") + if strict_markers is None: + strict_markers = self._config.getini("strict") + if strict_markers: + fail( + f"{name!r} not found in `markers` configuration option", + pytrace=False, + ) + + warnings.warn( + f"Unknown pytest.mark.{name} - is this a typo? You can register " + "custom marks to avoid this warning - for details, see " + "https://docs.pytest.org/en/stable/how-to/mark.html", + PytestUnknownMarkWarning, + 2, + ) + + return MarkDecorator(Mark(name, (), {}, _ispytest=True), _ispytest=True) + + +MARK_GEN = MarkGenerator(_ispytest=True) + + +@final +class NodeKeywords(MutableMapping[str, Any]): + __slots__ = ("_markers", "node", "parent") + + def __init__(self, node: Node) -> None: + self.node = node + self.parent = node.parent + self._markers = {node.name: True} + + def __getitem__(self, key: str) -> Any: + try: + return self._markers[key] + except KeyError: + if self.parent is None: + raise + return self.parent.keywords[key] + + def __setitem__(self, key: str, value: Any) -> None: + self._markers[key] = value + + # Note: we could've avoided explicitly implementing some of the methods + # below and use the collections.abc fallback, but that would be slow. + + def __contains__(self, key: object) -> bool: + return key in self._markers or ( + self.parent is not None and key in self.parent.keywords + ) + + def update( # type: ignore[override] + self, + other: Mapping[str, Any] | Iterable[tuple[str, Any]] = (), + **kwds: Any, + ) -> None: + self._markers.update(other) + self._markers.update(kwds) + + def __delitem__(self, key: str) -> None: + raise ValueError("cannot delete key in keywords dict") + + def __iter__(self) -> Iterator[str]: + # Doesn't need to be fast. + yield from self._markers + if self.parent is not None: + for keyword in self.parent.keywords: + # self._marks and self.parent.keywords can have duplicates. + if keyword not in self._markers: + yield keyword + + def __len__(self) -> int: + # Doesn't need to be fast. + return sum(1 for keyword in self) + + def __repr__(self) -> str: + return f"<NodeKeywords for node {self.node}>" diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/monkeypatch.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/monkeypatch.py new file mode 100644 index 0000000000000000000000000000000000000000..07cc3fc4b0f520553aa4786d18436b6c080b60c8 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/monkeypatch.py @@ -0,0 +1,435 @@ +# mypy: allow-untyped-defs +"""Monkeypatching and mocking functionality.""" + +from __future__ import annotations + +from collections.abc import Generator +from collections.abc import Mapping +from collections.abc import MutableMapping +from contextlib import contextmanager +import os +from pathlib import Path +import re +import sys +from typing import Any +from typing import final +from typing import overload +from typing import TypeVar +import warnings + +from _pytest.deprecated import MONKEYPATCH_LEGACY_NAMESPACE_PACKAGES +from _pytest.fixtures import fixture +from _pytest.warning_types import PytestWarning + + +RE_IMPORT_ERROR_NAME = re.compile(r"^No module named (.*)$") + + +K = TypeVar("K") +V = TypeVar("V") + + +@fixture +def monkeypatch() -> Generator[MonkeyPatch]: + """A convenient fixture for monkey-patching. + + The fixture provides these methods to modify objects, dictionaries, or + :data:`os.environ`: + + * :meth:`monkeypatch.setattr(obj, name, value, raising=True) <pytest.MonkeyPatch.setattr>` + * :meth:`monkeypatch.delattr(obj, name, raising=True) <pytest.MonkeyPatch.delattr>` + * :meth:`monkeypatch.setitem(mapping, name, value) <pytest.MonkeyPatch.setitem>` + * :meth:`monkeypatch.delitem(obj, name, raising=True) <pytest.MonkeyPatch.delitem>` + * :meth:`monkeypatch.setenv(name, value, prepend=None) <pytest.MonkeyPatch.setenv>` + * :meth:`monkeypatch.delenv(name, raising=True) <pytest.MonkeyPatch.delenv>` + * :meth:`monkeypatch.syspath_prepend(path) <pytest.MonkeyPatch.syspath_prepend>` + * :meth:`monkeypatch.chdir(path) <pytest.MonkeyPatch.chdir>` + * :meth:`monkeypatch.context() <pytest.MonkeyPatch.context>` + + All modifications will be undone after the requesting test function or + fixture has finished. The ``raising`` parameter determines if a :class:`KeyError` + or :class:`AttributeError` will be raised if the set/deletion operation does not have the + specified target. + + To undo modifications done by the fixture in a contained scope, + use :meth:`context() <pytest.MonkeyPatch.context>`. + """ + mpatch = MonkeyPatch() + yield mpatch + mpatch.undo() + + +def resolve(name: str) -> object: + # Simplified from zope.dottedname. + parts = name.split(".") + + used = parts.pop(0) + found: object = __import__(used) + for part in parts: + used += "." + part + try: + found = getattr(found, part) + except AttributeError: + pass + else: + continue + # We use explicit un-nesting of the handling block in order + # to avoid nested exceptions. + try: + __import__(used) + except ImportError as ex: + expected = str(ex).split()[-1] + if expected == used: + raise + else: + raise ImportError(f"import error in {used}: {ex}") from ex + found = annotated_getattr(found, part, used) + return found + + +def annotated_getattr(obj: object, name: str, ann: str) -> object: + try: + obj = getattr(obj, name) + except AttributeError as e: + raise AttributeError( + f"{type(obj).__name__!r} object at {ann} has no attribute {name!r}" + ) from e + return obj + + +def derive_importpath(import_path: str, raising: bool) -> tuple[str, object]: + if not isinstance(import_path, str) or "." not in import_path: + raise TypeError(f"must be absolute import path string, not {import_path!r}") + module, attr = import_path.rsplit(".", 1) + target = resolve(module) + if raising: + annotated_getattr(target, attr, ann=module) + return attr, target + + +class Notset: + def __repr__(self) -> str: + return "<notset>" + + +notset = Notset() + + +@final +class MonkeyPatch: + """Helper to conveniently monkeypatch attributes/items/environment + variables/syspath. + + Returned by the :fixture:`monkeypatch` fixture. + + .. versionchanged:: 6.2 + Can now also be used directly as `pytest.MonkeyPatch()`, for when + the fixture is not available. In this case, use + :meth:`with MonkeyPatch.context() as mp: <context>` or remember to call + :meth:`undo` explicitly. + """ + + def __init__(self) -> None: + self._setattr: list[tuple[object, str, object]] = [] + self._setitem: list[tuple[Mapping[Any, Any], object, object]] = [] + self._cwd: str | None = None + self._savesyspath: list[str] | None = None + + @classmethod + @contextmanager + def context(cls) -> Generator[MonkeyPatch]: + """Context manager that returns a new :class:`MonkeyPatch` object + which undoes any patching done inside the ``with`` block upon exit. + + Example: + + .. code-block:: python + + import functools + + + def test_partial(monkeypatch): + with monkeypatch.context() as m: + m.setattr(functools, "partial", 3) + + Useful in situations where it is desired to undo some patches before the test ends, + such as mocking ``stdlib`` functions that might break pytest itself if mocked (for examples + of this see :issue:`3290`). + """ + m = cls() + try: + yield m + finally: + m.undo() + + @overload + def setattr( + self, + target: str, + name: object, + value: Notset = ..., + raising: bool = ..., + ) -> None: ... + + @overload + def setattr( + self, + target: object, + name: str, + value: object, + raising: bool = ..., + ) -> None: ... + + def setattr( + self, + target: str | object, + name: object | str, + value: object = notset, + raising: bool = True, + ) -> None: + """ + Set attribute value on target, memorizing the old value. + + For example: + + .. code-block:: python + + import os + + monkeypatch.setattr(os, "getcwd", lambda: "/") + + The code above replaces the :func:`os.getcwd` function by a ``lambda`` which + always returns ``"/"``. + + For convenience, you can specify a string as ``target`` which + will be interpreted as a dotted import path, with the last part + being the attribute name: + + .. code-block:: python + + monkeypatch.setattr("os.getcwd", lambda: "/") + + Raises :class:`AttributeError` if the attribute does not exist, unless + ``raising`` is set to False. + + **Where to patch** + + ``monkeypatch.setattr`` works by (temporarily) changing the object that a name points to with another one. + There can be many names pointing to any individual object, so for patching to work you must ensure + that you patch the name used by the system under test. + + See the section :ref:`Where to patch <python:where-to-patch>` in the :mod:`unittest.mock` + docs for a complete explanation, which is meant for :func:`unittest.mock.patch` but + applies to ``monkeypatch.setattr`` as well. + """ + __tracebackhide__ = True + import inspect + + if isinstance(value, Notset): + if not isinstance(target, str): + raise TypeError( + "use setattr(target, name, value) or " + "setattr(target, value) with target being a dotted " + "import string" + ) + value = name + name, target = derive_importpath(target, raising) + else: + if not isinstance(name, str): + raise TypeError( + "use setattr(target, name, value) with name being a string or " + "setattr(target, value) with target being a dotted " + "import string" + ) + + oldval = getattr(target, name, notset) + if raising and oldval is notset: + raise AttributeError(f"{target!r} has no attribute {name!r}") + + # avoid class descriptors like staticmethod/classmethod + if inspect.isclass(target): + oldval = target.__dict__.get(name, notset) + self._setattr.append((target, name, oldval)) + setattr(target, name, value) + + def delattr( + self, + target: object | str, + name: str | Notset = notset, + raising: bool = True, + ) -> None: + """Delete attribute ``name`` from ``target``. + + If no ``name`` is specified and ``target`` is a string + it will be interpreted as a dotted import path with the + last part being the attribute name. + + Raises AttributeError it the attribute does not exist, unless + ``raising`` is set to False. + """ + __tracebackhide__ = True + import inspect + + if isinstance(name, Notset): + if not isinstance(target, str): + raise TypeError( + "use delattr(target, name) or " + "delattr(target) with target being a dotted " + "import string" + ) + name, target = derive_importpath(target, raising) + + if not hasattr(target, name): + if raising: + raise AttributeError(name) + else: + oldval = getattr(target, name, notset) + # Avoid class descriptors like staticmethod/classmethod. + if inspect.isclass(target): + oldval = target.__dict__.get(name, notset) + self._setattr.append((target, name, oldval)) + delattr(target, name) + + def setitem(self, dic: Mapping[K, V], name: K, value: V) -> None: + """Set dictionary entry ``name`` to value.""" + self._setitem.append((dic, name, dic.get(name, notset))) + # Not all Mapping types support indexing, but MutableMapping doesn't support TypedDict + dic[name] = value # type: ignore[index] + + def delitem(self, dic: Mapping[K, V], name: K, raising: bool = True) -> None: + """Delete ``name`` from dict. + + Raises ``KeyError`` if it doesn't exist, unless ``raising`` is set to + False. + """ + if name not in dic: + if raising: + raise KeyError(name) + else: + self._setitem.append((dic, name, dic.get(name, notset))) + # Not all Mapping types support indexing, but MutableMapping doesn't support TypedDict + del dic[name] # type: ignore[attr-defined] + + def setenv(self, name: str, value: str, prepend: str | None = None) -> None: + """Set environment variable ``name`` to ``value``. + + If ``prepend`` is a character, read the current environment variable + value and prepend the ``value`` adjoined with the ``prepend`` + character. + """ + if not isinstance(value, str): + warnings.warn( # type: ignore[unreachable] + PytestWarning( + f"Value of environment variable {name} type should be str, but got " + f"{value!r} (type: {type(value).__name__}); converted to str implicitly" + ), + stacklevel=2, + ) + value = str(value) + if prepend and name in os.environ: + value = value + prepend + os.environ[name] + self.setitem(os.environ, name, value) + + def delenv(self, name: str, raising: bool = True) -> None: + """Delete ``name`` from the environment. + + Raises ``KeyError`` if it does not exist, unless ``raising`` is set to + False. + """ + environ: MutableMapping[str, str] = os.environ + self.delitem(environ, name, raising=raising) + + def syspath_prepend(self, path) -> None: + """Prepend ``path`` to ``sys.path`` list of import locations.""" + if self._savesyspath is None: + self._savesyspath = sys.path[:] + sys.path.insert(0, str(path)) + + # https://github.com/pypa/setuptools/blob/d8b901bc/docs/pkg_resources.txt#L162-L171 + # this is only needed when pkg_resources was already loaded by the namespace package + if "pkg_resources" in sys.modules: + import pkg_resources + from pkg_resources import fixup_namespace_packages + + # Only issue deprecation warning if this call would actually have an + # effect for this specific path. + if ( + hasattr(pkg_resources, "_namespace_packages") + and pkg_resources._namespace_packages + ): + path_obj = Path(str(path)) + for ns_pkg in pkg_resources._namespace_packages: + if ns_pkg is None: + continue + ns_pkg_path = path_obj / ns_pkg.replace(".", os.sep) + if ns_pkg_path.is_dir(): + warnings.warn( + MONKEYPATCH_LEGACY_NAMESPACE_PACKAGES, stacklevel=2 + ) + break + + fixup_namespace_packages(str(path)) + + # A call to syspathinsert() usually means that the caller wants to + # import some dynamically created files, thus with python3 we + # invalidate its import caches. + # This is especially important when any namespace package is in use, + # since then the mtime based FileFinder cache (that gets created in + # this case already) gets not invalidated when writing the new files + # quickly afterwards. + from importlib import invalidate_caches + + invalidate_caches() + + def chdir(self, path: str | os.PathLike[str]) -> None: + """Change the current working directory to the specified path. + + :param path: + The path to change into. + """ + if self._cwd is None: + self._cwd = os.getcwd() + os.chdir(path) + + def undo(self) -> None: + """Undo previous changes. + + This call consumes the undo stack. Calling it a second time has no + effect unless you do more monkeypatching after the undo call. + + There is generally no need to call `undo()`, since it is + called automatically during tear-down. + + .. note:: + The same `monkeypatch` fixture is used across a + single test function invocation. If `monkeypatch` is used both by + the test function itself and one of the test fixtures, + calling `undo()` will undo all of the changes made in + both functions. + + Prefer to use :meth:`context() <pytest.MonkeyPatch.context>` instead. + """ + for obj, name, value in reversed(self._setattr): + if value is not notset: + setattr(obj, name, value) + else: + delattr(obj, name) + self._setattr[:] = [] + for dictionary, key, value in reversed(self._setitem): + if value is notset: + try: + # Not all Mapping types support indexing, but MutableMapping doesn't support TypedDict + del dictionary[key] # type: ignore[attr-defined] + except KeyError: + pass # Was already deleted, so we have the desired state. + else: + # Not all Mapping types support indexing, but MutableMapping doesn't support TypedDict + dictionary[key] = value # type: ignore[index] + self._setitem[:] = [] + if self._savesyspath is not None: + sys.path[:] = self._savesyspath + self._savesyspath = None + + if self._cwd is not None: + os.chdir(self._cwd) + self._cwd = None diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/nodes.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/nodes.py new file mode 100644 index 0000000000000000000000000000000000000000..6690f6ab1f814671d3342e5f14d85fbc39d7b083 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/nodes.py @@ -0,0 +1,772 @@ +# mypy: allow-untyped-defs +from __future__ import annotations + +import abc +from collections.abc import Callable +from collections.abc import Iterable +from collections.abc import Iterator +from collections.abc import MutableMapping +from functools import cached_property +from functools import lru_cache +import os +import pathlib +from pathlib import Path +from typing import Any +from typing import cast +from typing import NoReturn +from typing import overload +from typing import TYPE_CHECKING +from typing import TypeVar +import warnings + +import pluggy + +import _pytest._code +from _pytest._code import getfslineno +from _pytest._code.code import ExceptionInfo +from _pytest._code.code import TerminalRepr +from _pytest._code.code import Traceback +from _pytest._code.code import TracebackStyle +from _pytest.compat import LEGACY_PATH +from _pytest.compat import signature +from _pytest.config import Config +from _pytest.config import ConftestImportFailure +from _pytest.config.compat import _check_path +from _pytest.deprecated import NODE_CTOR_FSPATH_ARG +from _pytest.mark.structures import Mark +from _pytest.mark.structures import MarkDecorator +from _pytest.mark.structures import NodeKeywords +from _pytest.outcomes import fail +from _pytest.pathlib import absolutepath +from _pytest.stash import Stash +from _pytest.warning_types import PytestWarning + + +if TYPE_CHECKING: + from typing_extensions import Self + + # Imported here due to circular import. + from _pytest.main import Session + + +SEP = "/" + +tracebackcutdir = Path(_pytest.__file__).parent + + +_T = TypeVar("_T") + + +def _imply_path( + node_type: type[Node], + path: Path | None, + fspath: LEGACY_PATH | None, +) -> Path: + if fspath is not None: + warnings.warn( + NODE_CTOR_FSPATH_ARG.format( + node_type_name=node_type.__name__, + ), + stacklevel=6, + ) + if path is not None: + if fspath is not None: + _check_path(path, fspath) + return path + else: + assert fspath is not None + return Path(fspath) + + +_NodeType = TypeVar("_NodeType", bound="Node") + + +class NodeMeta(abc.ABCMeta): + """Metaclass used by :class:`Node` to enforce that direct construction raises + :class:`Failed`. + + This behaviour supports the indirection introduced with :meth:`Node.from_parent`, + the named constructor to be used instead of direct construction. The design + decision to enforce indirection with :class:`NodeMeta` was made as a + temporary aid for refactoring the collection tree, which was diagnosed to + have :class:`Node` objects whose creational patterns were overly entangled. + Once the refactoring is complete, this metaclass can be removed. + + See https://github.com/pytest-dev/pytest/projects/3 for an overview of the + progress on detangling the :class:`Node` classes. + """ + + def __call__(cls, *k, **kw) -> NoReturn: + msg = ( + "Direct construction of {name} has been deprecated, please use {name}.from_parent.\n" + "See " + "https://docs.pytest.org/en/stable/deprecations.html#node-construction-changed-to-node-from-parent" + " for more details." + ).format(name=f"{cls.__module__}.{cls.__name__}") + fail(msg, pytrace=False) + + def _create(cls: type[_T], *k, **kw) -> _T: + try: + return super().__call__(*k, **kw) # type: ignore[no-any-return,misc] + except TypeError: + sig = signature(getattr(cls, "__init__")) + known_kw = {k: v for k, v in kw.items() if k in sig.parameters} + from .warning_types import PytestDeprecationWarning + + warnings.warn( + PytestDeprecationWarning( + f"{cls} is not using a cooperative constructor and only takes {set(known_kw)}.\n" + "See https://docs.pytest.org/en/stable/deprecations.html" + "#constructors-of-custom-pytest-node-subclasses-should-take-kwargs " + "for more details." + ) + ) + + return super().__call__(*k, **known_kw) # type: ignore[no-any-return,misc] + + +class Node(abc.ABC, metaclass=NodeMeta): + r"""Base class of :class:`Collector` and :class:`Item`, the components of + the test collection tree. + + ``Collector``\'s are the internal nodes of the tree, and ``Item``\'s are the + leaf nodes. + """ + + # Implemented in the legacypath plugin. + #: A ``LEGACY_PATH`` copy of the :attr:`path` attribute. Intended for usage + #: for methods not migrated to ``pathlib.Path`` yet, such as + #: :meth:`Item.reportinfo <pytest.Item.reportinfo>`. Will be deprecated in + #: a future release, prefer using :attr:`path` instead. + fspath: LEGACY_PATH + + # Use __slots__ to make attribute access faster. + # Note that __dict__ is still available. + __slots__ = ( + "__dict__", + "_nodeid", + "_store", + "config", + "name", + "parent", + "path", + "session", + ) + + def __init__( + self, + name: str, + parent: Node | None = None, + config: Config | None = None, + session: Session | None = None, + fspath: LEGACY_PATH | None = None, + path: Path | None = None, + nodeid: str | None = None, + ) -> None: + #: A unique name within the scope of the parent node. + self.name: str = name + + #: The parent collector node. + self.parent = parent + + if config: + #: The pytest config object. + self.config: Config = config + else: + if not parent: + raise TypeError("config or parent must be provided") + self.config = parent.config + + if session: + #: The pytest session this node is part of. + self.session: Session = session + else: + if not parent: + raise TypeError("session or parent must be provided") + self.session = parent.session + + if path is None and fspath is None: + path = getattr(parent, "path", None) + #: Filesystem path where this node was collected from (can be None). + self.path: pathlib.Path = _imply_path(type(self), path, fspath=fspath) + + # The explicit annotation is to avoid publicly exposing NodeKeywords. + #: Keywords/markers collected from all scopes. + self.keywords: MutableMapping[str, Any] = NodeKeywords(self) + + #: The marker objects belonging to this node. + self.own_markers: list[Mark] = [] + + #: Allow adding of extra keywords to use for matching. + self.extra_keyword_matches: set[str] = set() + + if nodeid is not None: + assert "::()" not in nodeid + self._nodeid = nodeid + else: + if not self.parent: + raise TypeError("nodeid or parent must be provided") + self._nodeid = self.parent.nodeid + "::" + self.name + + #: A place where plugins can store information on the node for their + #: own use. + self.stash: Stash = Stash() + # Deprecated alias. Was never public. Can be removed in a few releases. + self._store = self.stash + + @classmethod + def from_parent(cls, parent: Node, **kw) -> Self: + """Public constructor for Nodes. + + This indirection got introduced in order to enable removing + the fragile logic from the node constructors. + + Subclasses can use ``super().from_parent(...)`` when overriding the + construction. + + :param parent: The parent node of this Node. + """ + if "config" in kw: + raise TypeError("config is not a valid argument for from_parent") + if "session" in kw: + raise TypeError("session is not a valid argument for from_parent") + return cls._create(parent=parent, **kw) + + @property + def ihook(self) -> pluggy.HookRelay: + """fspath-sensitive hook proxy used to call pytest hooks.""" + return self.session.gethookproxy(self.path) + + def __repr__(self) -> str: + return "<{} {}>".format(self.__class__.__name__, getattr(self, "name", None)) + + def warn(self, warning: Warning) -> None: + """Issue a warning for this Node. + + Warnings will be displayed after the test session, unless explicitly suppressed. + + :param Warning warning: + The warning instance to issue. + + :raises ValueError: If ``warning`` instance is not a subclass of Warning. + + Example usage: + + .. code-block:: python + + node.warn(PytestWarning("some message")) + node.warn(UserWarning("some message")) + + .. versionchanged:: 6.2 + Any subclass of :class:`Warning` is now accepted, rather than only + :class:`PytestWarning <pytest.PytestWarning>` subclasses. + """ + # enforce type checks here to avoid getting a generic type error later otherwise. + if not isinstance(warning, Warning): + raise ValueError( + f"warning must be an instance of Warning or subclass, got {warning!r}" + ) + path, lineno = get_fslocation_from_item(self) + assert lineno is not None + warnings.warn_explicit( + warning, + category=None, + filename=str(path), + lineno=lineno + 1, + ) + + # Methods for ordering nodes. + + @property + def nodeid(self) -> str: + """A ::-separated string denoting its collection tree address.""" + return self._nodeid + + def __hash__(self) -> int: + return hash(self._nodeid) + + def setup(self) -> None: + pass + + def teardown(self) -> None: + pass + + def iter_parents(self) -> Iterator[Node]: + """Iterate over all parent collectors starting from and including self + up to the root of the collection tree. + + .. versionadded:: 8.1 + """ + parent: Node | None = self + while parent is not None: + yield parent + parent = parent.parent + + def listchain(self) -> list[Node]: + """Return a list of all parent collectors starting from the root of the + collection tree down to and including self.""" + chain = [] + item: Node | None = self + while item is not None: + chain.append(item) + item = item.parent + chain.reverse() + return chain + + def add_marker(self, marker: str | MarkDecorator, append: bool = True) -> None: + """Dynamically add a marker object to the node. + + :param marker: + The marker. + :param append: + Whether to append the marker, or prepend it. + """ + from _pytest.mark import MARK_GEN + + if isinstance(marker, MarkDecorator): + marker_ = marker + elif isinstance(marker, str): + marker_ = getattr(MARK_GEN, marker) + else: + raise ValueError("is not a string or pytest.mark.* Marker") + self.keywords[marker_.name] = marker_ + if append: + self.own_markers.append(marker_.mark) + else: + self.own_markers.insert(0, marker_.mark) + + def iter_markers(self, name: str | None = None) -> Iterator[Mark]: + """Iterate over all markers of the node. + + :param name: If given, filter the results by the name attribute. + :returns: An iterator of the markers of the node. + """ + return (x[1] for x in self.iter_markers_with_node(name=name)) + + def iter_markers_with_node( + self, name: str | None = None + ) -> Iterator[tuple[Node, Mark]]: + """Iterate over all markers of the node. + + :param name: If given, filter the results by the name attribute. + :returns: An iterator of (node, mark) tuples. + """ + for node in self.iter_parents(): + for mark in node.own_markers: + if name is None or getattr(mark, "name", None) == name: + yield node, mark + + @overload + def get_closest_marker(self, name: str) -> Mark | None: ... + + @overload + def get_closest_marker(self, name: str, default: Mark) -> Mark: ... + + def get_closest_marker(self, name: str, default: Mark | None = None) -> Mark | None: + """Return the first marker matching the name, from closest (for + example function) to farther level (for example module level). + + :param default: Fallback return value if no marker was found. + :param name: Name to filter by. + """ + return next(self.iter_markers(name=name), default) + + def listextrakeywords(self) -> set[str]: + """Return a set of all extra keywords in self and any parents.""" + extra_keywords: set[str] = set() + for item in self.listchain(): + extra_keywords.update(item.extra_keyword_matches) + return extra_keywords + + def listnames(self) -> list[str]: + return [x.name for x in self.listchain()] + + def addfinalizer(self, fin: Callable[[], object]) -> None: + """Register a function to be called without arguments when this node is + finalized. + + This method can only be called when this node is active + in a setup chain, for example during self.setup(). + """ + self.session._setupstate.addfinalizer(fin, self) + + def getparent(self, cls: type[_NodeType]) -> _NodeType | None: + """Get the closest parent node (including self) which is an instance of + the given class. + + :param cls: The node class to search for. + :returns: The node, if found. + """ + for node in self.iter_parents(): + if isinstance(node, cls): + return node + return None + + def _traceback_filter(self, excinfo: ExceptionInfo[BaseException]) -> Traceback: + return excinfo.traceback + + def _repr_failure_py( + self, + excinfo: ExceptionInfo[BaseException], + style: TracebackStyle | None = None, + ) -> TerminalRepr: + from _pytest.fixtures import FixtureLookupError + + if isinstance(excinfo.value, ConftestImportFailure): + excinfo = ExceptionInfo.from_exception(excinfo.value.cause) + if isinstance(excinfo.value, fail.Exception): + if not excinfo.value.pytrace: + style = "value" + if isinstance(excinfo.value, FixtureLookupError): + return excinfo.value.formatrepr() + + tbfilter: bool | Callable[[ExceptionInfo[BaseException]], Traceback] + if self.config.getoption("fulltrace", False): + style = "long" + tbfilter = False + else: + tbfilter = self._traceback_filter + if style == "auto": + style = "long" + # XXX should excinfo.getrepr record all data and toterminal() process it? + if style is None: + if self.config.getoption("tbstyle", "auto") == "short": + style = "short" + else: + style = "long" + + if self.config.get_verbosity() > 1: + truncate_locals = False + else: + truncate_locals = True + + truncate_args = False if self.config.get_verbosity() > 2 else True + + # excinfo.getrepr() formats paths relative to the CWD if `abspath` is False. + # It is possible for a fixture/test to change the CWD while this code runs, which + # would then result in the user seeing confusing paths in the failure message. + # To fix this, if the CWD changed, always display the full absolute path. + # It will be better to just always display paths relative to invocation_dir, but + # this requires a lot of plumbing (#6428). + try: + abspath = Path(os.getcwd()) != self.config.invocation_params.dir + except OSError: + abspath = True + + return excinfo.getrepr( + funcargs=True, + abspath=abspath, + showlocals=self.config.getoption("showlocals", False), + style=style, + tbfilter=tbfilter, + truncate_locals=truncate_locals, + truncate_args=truncate_args, + ) + + def repr_failure( + self, + excinfo: ExceptionInfo[BaseException], + style: TracebackStyle | None = None, + ) -> str | TerminalRepr: + """Return a representation of a collection or test failure. + + .. seealso:: :ref:`non-python tests` + + :param excinfo: Exception information for the failure. + """ + return self._repr_failure_py(excinfo, style) + + +def get_fslocation_from_item(node: Node) -> tuple[str | Path, int | None]: + """Try to extract the actual location from a node, depending on available attributes: + + * "location": a pair (path, lineno) + * "obj": a Python object that the node wraps. + * "path": just a path + + :rtype: A tuple of (str|Path, int) with filename and 0-based line number. + """ + # See Item.location. + location: tuple[str, int | None, str] | None = getattr(node, "location", None) + if location is not None: + return location[:2] + obj = getattr(node, "obj", None) + if obj is not None: + return getfslineno(obj) + return getattr(node, "path", "unknown location"), -1 + + +class Collector(Node, abc.ABC): + """Base class of all collectors. + + Collector create children through `collect()` and thus iteratively build + the collection tree. + """ + + class CollectError(Exception): + """An error during collection, contains a custom message.""" + + @abc.abstractmethod + def collect(self) -> Iterable[Item | Collector]: + """Collect children (items and collectors) for this collector.""" + raise NotImplementedError("abstract") + + # TODO: This omits the style= parameter which breaks Liskov Substitution. + def repr_failure( # type: ignore[override] + self, excinfo: ExceptionInfo[BaseException] + ) -> str | TerminalRepr: + """Return a representation of a collection failure. + + :param excinfo: Exception information for the failure. + """ + if isinstance(excinfo.value, self.CollectError) and not self.config.getoption( + "fulltrace", False + ): + exc = excinfo.value + return str(exc.args[0]) + + # Respect explicit tbstyle option, but default to "short" + # (_repr_failure_py uses "long" with "fulltrace" option always). + tbstyle = self.config.getoption("tbstyle", "auto") + if tbstyle == "auto": + tbstyle = "short" + + return self._repr_failure_py(excinfo, style=tbstyle) + + def _traceback_filter(self, excinfo: ExceptionInfo[BaseException]) -> Traceback: + if hasattr(self, "path"): + traceback = excinfo.traceback + ntraceback = traceback.cut(path=self.path) + if ntraceback == traceback: + ntraceback = ntraceback.cut(excludepath=tracebackcutdir) + return ntraceback.filter(excinfo) + return excinfo.traceback + + +@lru_cache(maxsize=1000) +def _check_initialpaths_for_relpath( + initial_paths: frozenset[Path], path: Path +) -> str | None: + if path in initial_paths: + return "" + + for parent in path.parents: + if parent in initial_paths: + return str(path.relative_to(parent)) + + return None + + +class FSCollector(Collector, abc.ABC): + """Base class for filesystem collectors.""" + + def __init__( + self, + fspath: LEGACY_PATH | None = None, + path_or_parent: Path | Node | None = None, + path: Path | None = None, + name: str | None = None, + parent: Node | None = None, + config: Config | None = None, + session: Session | None = None, + nodeid: str | None = None, + ) -> None: + if path_or_parent: + if isinstance(path_or_parent, Node): + assert parent is None + parent = cast(FSCollector, path_or_parent) + elif isinstance(path_or_parent, Path): + assert path is None + path = path_or_parent + + path = _imply_path(type(self), path, fspath=fspath) + if name is None: + name = path.name + if parent is not None and parent.path != path: + try: + rel = path.relative_to(parent.path) + except ValueError: + pass + else: + name = str(rel) + name = name.replace(os.sep, SEP) + self.path = path + + if session is None: + assert parent is not None + session = parent.session + + if nodeid is None: + try: + nodeid = str(self.path.relative_to(session.config.rootpath)) + except ValueError: + nodeid = _check_initialpaths_for_relpath(session._initialpaths, path) + + if nodeid and os.sep != SEP: + nodeid = nodeid.replace(os.sep, SEP) + + super().__init__( + name=name, + parent=parent, + config=config, + session=session, + nodeid=nodeid, + path=path, + ) + + @classmethod + def from_parent( + cls, + parent, + *, + fspath: LEGACY_PATH | None = None, + path: Path | None = None, + **kw, + ) -> Self: + """The public constructor.""" + return super().from_parent(parent=parent, fspath=fspath, path=path, **kw) + + +class File(FSCollector, abc.ABC): + """Base class for collecting tests from a file. + + :ref:`non-python tests`. + """ + + +class Directory(FSCollector, abc.ABC): + """Base class for collecting files from a directory. + + A basic directory collector does the following: goes over the files and + sub-directories in the directory and creates collectors for them by calling + the hooks :hook:`pytest_collect_directory` and :hook:`pytest_collect_file`, + after checking that they are not ignored using + :hook:`pytest_ignore_collect`. + + The default directory collectors are :class:`~pytest.Dir` and + :class:`~pytest.Package`. + + .. versionadded:: 8.0 + + :ref:`custom directory collectors`. + """ + + +class Item(Node, abc.ABC): + """Base class of all test invocation items. + + Note that for a single function there might be multiple test invocation items. + """ + + nextitem = None + + def __init__( + self, + name, + parent=None, + config: Config | None = None, + session: Session | None = None, + nodeid: str | None = None, + **kw, + ) -> None: + # The first two arguments are intentionally passed positionally, + # to keep plugins who define a node type which inherits from + # (pytest.Item, pytest.File) working (see issue #8435). + # They can be made kwargs when the deprecation above is done. + super().__init__( + name, + parent, + config=config, + session=session, + nodeid=nodeid, + **kw, + ) + self._report_sections: list[tuple[str, str, str]] = [] + + #: A list of tuples (name, value) that holds user defined properties + #: for this test. + self.user_properties: list[tuple[str, object]] = [] + + self._check_item_and_collector_diamond_inheritance() + + def _check_item_and_collector_diamond_inheritance(self) -> None: + """ + Check if the current type inherits from both File and Collector + at the same time, emitting a warning accordingly (#8447). + """ + cls = type(self) + + # We inject an attribute in the type to avoid issuing this warning + # for the same class more than once, which is not helpful. + # It is a hack, but was deemed acceptable in order to avoid + # flooding the user in the common case. + attr_name = "_pytest_diamond_inheritance_warning_shown" + if getattr(cls, attr_name, False): + return + setattr(cls, attr_name, True) + + problems = ", ".join( + base.__name__ for base in cls.__bases__ if issubclass(base, Collector) + ) + if problems: + warnings.warn( + f"{cls.__name__} is an Item subclass and should not be a collector, " + f"however its bases {problems} are collectors.\n" + "Please split the Collectors and the Item into separate node types.\n" + "Pytest Doc example: https://docs.pytest.org/en/latest/example/nonpython.html\n" + "example pull request on a plugin: https://github.com/asmeurer/pytest-flakes/pull/40/", + PytestWarning, + ) + + @abc.abstractmethod + def runtest(self) -> None: + """Run the test case for this item. + + Must be implemented by subclasses. + + .. seealso:: :ref:`non-python tests` + """ + raise NotImplementedError("runtest must be implemented by Item subclass") + + def add_report_section(self, when: str, key: str, content: str) -> None: + """Add a new report section, similar to what's done internally to add + stdout and stderr captured output:: + + item.add_report_section("call", "stdout", "report section contents") + + :param str when: + One of the possible capture states, ``"setup"``, ``"call"``, ``"teardown"``. + :param str key: + Name of the section, can be customized at will. Pytest uses ``"stdout"`` and + ``"stderr"`` internally. + :param str content: + The full contents as a string. + """ + if content: + self._report_sections.append((when, key, content)) + + def reportinfo(self) -> tuple[os.PathLike[str] | str, int | None, str]: + """Get location information for this item for test reports. + + Returns a tuple with three elements: + + - The path of the test (default ``self.path``) + - The 0-based line number of the test (default ``None``) + - A name of the test to be shown (default ``""``) + + .. seealso:: :ref:`non-python tests` + """ + return self.path, None, "" + + @cached_property + def location(self) -> tuple[str, int | None, str]: + """ + Returns a tuple of ``(relfspath, lineno, testname)`` for this item + where ``relfspath`` is file path relative to ``config.rootpath`` + and lineno is a 0-based line number. + """ + location = self.reportinfo() + path = absolutepath(location[0]) + relfspath = self.session._node_location_to_relpath(path) + assert type(location[2]) is str + return (relfspath, location[1], location[2]) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/outcomes.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/outcomes.py new file mode 100644 index 0000000000000000000000000000000000000000..766be95c0f75567498d7cccfab549b24035239bc --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/outcomes.py @@ -0,0 +1,308 @@ +"""Exception classes and constants handling test outcomes as well as +functions creating them.""" + +from __future__ import annotations + +import sys +from typing import Any +from typing import ClassVar +from typing import NoReturn + +from .warning_types import PytestDeprecationWarning + + +class OutcomeException(BaseException): + """OutcomeException and its subclass instances indicate and contain info + about test and collection outcomes.""" + + def __init__(self, msg: str | None = None, pytrace: bool = True) -> None: + if msg is not None and not isinstance(msg, str): + error_msg = ( # type: ignore[unreachable] + "{} expected string as 'msg' parameter, got '{}' instead.\n" + "Perhaps you meant to use a mark?" + ) + raise TypeError(error_msg.format(type(self).__name__, type(msg).__name__)) + super().__init__(msg) + self.msg = msg + self.pytrace = pytrace + + def __repr__(self) -> str: + if self.msg is not None: + return self.msg + return f"<{self.__class__.__name__} instance>" + + __str__ = __repr__ + + +TEST_OUTCOME = (OutcomeException, Exception) + + +class Skipped(OutcomeException): + # XXX hackish: on 3k we fake to live in the builtins + # in order to have Skipped exception printing shorter/nicer + __module__ = "builtins" + + def __init__( + self, + msg: str | None = None, + pytrace: bool = True, + allow_module_level: bool = False, + *, + _use_item_location: bool = False, + ) -> None: + super().__init__(msg=msg, pytrace=pytrace) + self.allow_module_level = allow_module_level + # If true, the skip location is reported as the item's location, + # instead of the place that raises the exception/calls skip(). + self._use_item_location = _use_item_location + + +class Failed(OutcomeException): + """Raised from an explicit call to pytest.fail().""" + + __module__ = "builtins" + + +class Exit(Exception): + """Raised for immediate program exits (no tracebacks/summaries).""" + + def __init__( + self, msg: str = "unknown reason", returncode: int | None = None + ) -> None: + self.msg = msg + self.returncode = returncode + super().__init__(msg) + + +class XFailed(Failed): + """Raised from an explicit call to pytest.xfail().""" + + +class _Exit: + """Exit testing process. + + :param reason: + The message to show as the reason for exiting pytest. reason has a default value + only because `msg` is deprecated. + + :param returncode: + Return code to be used when exiting pytest. None means the same as ``0`` (no error), + same as :func:`sys.exit`. + + :raises pytest.exit.Exception: + The exception that is raised. + """ + + Exception: ClassVar[type[Exit]] = Exit + + def __call__(self, reason: str = "", returncode: int | None = None) -> NoReturn: + __tracebackhide__ = True + raise Exit(msg=reason, returncode=returncode) + + +exit: _Exit = _Exit() + + +class _Skip: + """Skip an executing test with the given message. + + This function should be called only during testing (setup, call or teardown) or + during collection by using the ``allow_module_level`` flag. This function can + be called in doctests as well. + + :param reason: + The message to show the user as reason for the skip. + + :param allow_module_level: + Allows this function to be called at module level. + Raising the skip exception at module level will stop + the execution of the module and prevent the collection of all tests in the module, + even those defined before the `skip` call. + + Defaults to False. + + :raises pytest.skip.Exception: + The exception that is raised. + + .. note:: + It is better to use the :ref:`pytest.mark.skipif ref` marker when + possible to declare a test to be skipped under certain conditions + like mismatching platforms or dependencies. + Similarly, use the ``# doctest: +SKIP`` directive (see :py:data:`doctest.SKIP`) + to skip a doctest statically. + """ + + Exception: ClassVar[type[Skipped]] = Skipped + + def __call__(self, reason: str = "", allow_module_level: bool = False) -> NoReturn: + __tracebackhide__ = True + raise Skipped(msg=reason, allow_module_level=allow_module_level) + + +skip: _Skip = _Skip() + + +class _Fail: + """Explicitly fail an executing test with the given message. + + :param reason: + The message to show the user as reason for the failure. + + :param pytrace: + If False, msg represents the full failure information and no + python traceback will be reported. + + :raises pytest.fail.Exception: + The exception that is raised. + """ + + Exception: ClassVar[type[Failed]] = Failed + + def __call__(self, reason: str = "", pytrace: bool = True) -> NoReturn: + __tracebackhide__ = True + raise Failed(msg=reason, pytrace=pytrace) + + +fail: _Fail = _Fail() + + +class _XFail: + """Imperatively xfail an executing test or setup function with the given reason. + + This function should be called only during testing (setup, call or teardown). + + No other code is executed after using ``xfail()`` (it is implemented + internally by raising an exception). + + :param reason: + The message to show the user as reason for the xfail. + + .. note:: + It is better to use the :ref:`pytest.mark.xfail ref` marker when + possible to declare a test to be xfailed under certain conditions + like known bugs or missing features. + + :raises pytest.xfail.Exception: + The exception that is raised. + """ + + Exception: ClassVar[type[XFailed]] = XFailed + + def __call__(self, reason: str = "") -> NoReturn: + __tracebackhide__ = True + raise XFailed(msg=reason) + + +xfail: _XFail = _XFail() + + +def importorskip( + modname: str, + minversion: str | None = None, + reason: str | None = None, + *, + exc_type: type[ImportError] | None = None, +) -> Any: + """Import and return the requested module ``modname``, or skip the + current test if the module cannot be imported. + + :param modname: + The name of the module to import. + :param minversion: + If given, the imported module's ``__version__`` attribute must be at + least this minimal version, otherwise the test is still skipped. + :param reason: + If given, this reason is shown as the message when the module cannot + be imported. + :param exc_type: + The exception that should be captured in order to skip modules. + Must be :py:class:`ImportError` or a subclass. + + If the module can be imported but raises :class:`ImportError`, pytest will + issue a warning to the user, as often users expect the module not to be + found (which would raise :class:`ModuleNotFoundError` instead). + + This warning can be suppressed by passing ``exc_type=ImportError`` explicitly. + + See :ref:`import-or-skip-import-error` for details. + + + :returns: + The imported module. This should be assigned to its canonical name. + + :raises pytest.skip.Exception: + If the module cannot be imported. + + Example:: + + docutils = pytest.importorskip("docutils") + + .. versionadded:: 8.2 + + The ``exc_type`` parameter. + """ + import warnings + + __tracebackhide__ = True + compile(modname, "", "eval") # to catch syntaxerrors + + # Until pytest 9.1, we will warn the user if we catch ImportError (instead of ModuleNotFoundError), + # as this might be hiding an installation/environment problem, which is not usually what is intended + # when using importorskip() (#11523). + # In 9.1, to keep the function signature compatible, we just change the code below to: + # 1. Use `exc_type = ModuleNotFoundError` if `exc_type` is not given. + # 2. Remove `warn_on_import` and the warning handling. + if exc_type is None: + exc_type = ImportError + warn_on_import_error = True + else: + warn_on_import_error = False + + skipped: Skipped | None = None + warning: Warning | None = None + + with warnings.catch_warnings(): + # Make sure to ignore ImportWarnings that might happen because + # of existing directories with the same name we're trying to + # import but without a __init__.py file. + warnings.simplefilter("ignore") + + try: + __import__(modname) + except exc_type as exc: + # Do not raise or issue warnings inside the catch_warnings() block. + if reason is None: + reason = f"could not import {modname!r}: {exc}" + skipped = Skipped(reason, allow_module_level=True) + + if warn_on_import_error and not isinstance(exc, ModuleNotFoundError): + lines = [ + "", + f"Module '{modname}' was found, but when imported by pytest it raised:", + f" {exc!r}", + "In pytest 9.1 this warning will become an error by default.", + "You can fix the underlying problem, or alternatively overwrite this behavior and silence this " + "warning by passing exc_type=ImportError explicitly.", + "See https://docs.pytest.org/en/stable/deprecations.html#pytest-importorskip-default-behavior-regarding-importerror", + ] + warning = PytestDeprecationWarning("\n".join(lines)) + + if warning: + warnings.warn(warning, stacklevel=2) + if skipped: + raise skipped + + mod = sys.modules[modname] + if minversion is None: + return mod + verattr = getattr(mod, "__version__", None) + if minversion is not None: + # Imported lazily to improve start-up time. + from packaging.version import Version + + if verattr is None or Version(verattr) < Version(minversion): + raise Skipped( + f"module {modname!r} has __version__ {verattr!r}, required is: {minversion!r}", + allow_module_level=True, + ) + return mod diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/pastebin.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/pastebin.py new file mode 100644 index 0000000000000000000000000000000000000000..c7b39d96f029c31d00a6a85125a77f4314fc97a5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/pastebin.py @@ -0,0 +1,117 @@ +# mypy: allow-untyped-defs +"""Submit failure or test session information to a pastebin service.""" + +from __future__ import annotations + +from io import StringIO +import tempfile +from typing import IO + +from _pytest.config import Config +from _pytest.config import create_terminal_writer +from _pytest.config.argparsing import Parser +from _pytest.stash import StashKey +from _pytest.terminal import TerminalReporter +import pytest + + +pastebinfile_key = StashKey[IO[bytes]]() + + +def pytest_addoption(parser: Parser) -> None: + group = parser.getgroup("terminal reporting") + group.addoption( + "--pastebin", + metavar="mode", + action="store", + dest="pastebin", + default=None, + choices=["failed", "all"], + help="Send failed|all info to bpaste.net pastebin service", + ) + + +@pytest.hookimpl(trylast=True) +def pytest_configure(config: Config) -> None: + if config.option.pastebin == "all": + tr = config.pluginmanager.getplugin("terminalreporter") + # If no terminal reporter plugin is present, nothing we can do here; + # this can happen when this function executes in a worker node + # when using pytest-xdist, for example. + if tr is not None: + # pastebin file will be UTF-8 encoded binary file. + config.stash[pastebinfile_key] = tempfile.TemporaryFile("w+b") + oldwrite = tr._tw.write + + def tee_write(s, **kwargs): + oldwrite(s, **kwargs) + if isinstance(s, str): + s = s.encode("utf-8") + config.stash[pastebinfile_key].write(s) + + tr._tw.write = tee_write + + +def pytest_unconfigure(config: Config) -> None: + if pastebinfile_key in config.stash: + pastebinfile = config.stash[pastebinfile_key] + # Get terminal contents and delete file. + pastebinfile.seek(0) + sessionlog = pastebinfile.read() + pastebinfile.close() + del config.stash[pastebinfile_key] + # Undo our patching in the terminal reporter. + tr = config.pluginmanager.getplugin("terminalreporter") + del tr._tw.__dict__["write"] + # Write summary. + tr.write_sep("=", "Sending information to Paste Service") + pastebinurl = create_new_paste(sessionlog) + tr.write_line(f"pastebin session-log: {pastebinurl}\n") + + +def create_new_paste(contents: str | bytes) -> str: + """Create a new paste using the bpaste.net service. + + :contents: Paste contents string. + :returns: URL to the pasted contents, or an error message. + """ + import re + from urllib.error import HTTPError + from urllib.parse import urlencode + from urllib.request import urlopen + + params = {"code": contents, "lexer": "text", "expiry": "1week"} + url = "https://bpa.st" + try: + response: str = ( + urlopen(url, data=urlencode(params).encode("ascii")).read().decode("utf-8") + ) + except HTTPError as e: + with e: # HTTPErrors are also http responses that must be closed! + return f"bad response: {e}" + except OSError as e: # eg urllib.error.URLError + return f"bad response: {e}" + m = re.search(r'href="/raw/(\w+)"', response) + if m: + return f"{url}/show/{m.group(1)}" + else: + return "bad response: invalid format ('" + response + "')" + + +def pytest_terminal_summary(terminalreporter: TerminalReporter) -> None: + if terminalreporter.config.option.pastebin != "failed": + return + if "failed" in terminalreporter.stats: + terminalreporter.write_sep("=", "Sending information to Paste Service") + for rep in terminalreporter.stats["failed"]: + try: + msg = rep.longrepr.reprtraceback.reprentries[-1].reprfileloc + except AttributeError: + msg = terminalreporter._getfailureheadline(rep) + file = StringIO() + tw = create_terminal_writer(terminalreporter.config, file) + rep.toterminal(tw) + s = file.getvalue() + assert len(s) + pastebinurl = create_new_paste(s) + terminalreporter.write_line(f"{msg} --> {pastebinurl}") diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/pathlib.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/pathlib.py new file mode 100644 index 0000000000000000000000000000000000000000..cd15434605dcec1b6c29b7222dcbfb7a78b18af1 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/pathlib.py @@ -0,0 +1,1063 @@ +from __future__ import annotations + +import atexit +from collections.abc import Callable +from collections.abc import Iterable +from collections.abc import Iterator +import contextlib +from enum import Enum +from errno import EBADF +from errno import ELOOP +from errno import ENOENT +from errno import ENOTDIR +import fnmatch +from functools import partial +from importlib.machinery import ModuleSpec +from importlib.machinery import PathFinder +import importlib.util +import itertools +import os +from os.path import expanduser +from os.path import expandvars +from os.path import isabs +from os.path import sep +from pathlib import Path +from pathlib import PurePath +from posixpath import sep as posix_sep +import shutil +import sys +import types +from types import ModuleType +from typing import Any +from typing import TypeVar +import uuid +import warnings + +from _pytest.compat import assert_never +from _pytest.outcomes import skip +from _pytest.warning_types import PytestWarning + + +if sys.version_info < (3, 11): + from importlib._bootstrap_external import _NamespaceLoader as NamespaceLoader +else: + from importlib.machinery import NamespaceLoader + +LOCK_TIMEOUT = 60 * 60 * 24 * 3 + +_AnyPurePath = TypeVar("_AnyPurePath", bound=PurePath) + +# The following function, variables and comments were +# copied from cpython 3.9 Lib/pathlib.py file. + +# EBADF - guard against macOS `stat` throwing EBADF +_IGNORED_ERRORS = (ENOENT, ENOTDIR, EBADF, ELOOP) + +_IGNORED_WINERRORS = ( + 21, # ERROR_NOT_READY - drive exists but is not accessible + 1921, # ERROR_CANT_RESOLVE_FILENAME - fix for broken symlink pointing to itself +) + + +def _ignore_error(exception: Exception) -> bool: + return ( + getattr(exception, "errno", None) in _IGNORED_ERRORS + or getattr(exception, "winerror", None) in _IGNORED_WINERRORS + ) + + +def get_lock_path(path: _AnyPurePath) -> _AnyPurePath: + return path.joinpath(".lock") + + +def on_rm_rf_error( + func: Callable[..., Any] | None, + path: str, + excinfo: BaseException + | tuple[type[BaseException], BaseException, types.TracebackType | None], + *, + start_path: Path, +) -> bool: + """Handle known read-only errors during rmtree. + + The returned value is used only by our own tests. + """ + if isinstance(excinfo, BaseException): + exc = excinfo + else: + exc = excinfo[1] + + # Another process removed the file in the middle of the "rm_rf" (xdist for example). + # More context: https://github.com/pytest-dev/pytest/issues/5974#issuecomment-543799018 + if isinstance(exc, FileNotFoundError): + return False + + if not isinstance(exc, PermissionError): + warnings.warn( + PytestWarning(f"(rm_rf) error removing {path}\n{type(exc)}: {exc}") + ) + return False + + if func not in (os.rmdir, os.remove, os.unlink): + if func not in (os.open,): + warnings.warn( + PytestWarning( + f"(rm_rf) unknown function {func} when removing {path}:\n{type(exc)}: {exc}" + ) + ) + return False + + # Chmod + retry. + import stat + + def chmod_rw(p: str) -> None: + mode = os.stat(p).st_mode + os.chmod(p, mode | stat.S_IRUSR | stat.S_IWUSR) + + # For files, we need to recursively go upwards in the directories to + # ensure they all are also writable. + p = Path(path) + if p.is_file(): + for parent in p.parents: + chmod_rw(str(parent)) + # Stop when we reach the original path passed to rm_rf. + if parent == start_path: + break + chmod_rw(str(path)) + + func(path) + return True + + +def ensure_extended_length_path(path: Path) -> Path: + """Get the extended-length version of a path (Windows). + + On Windows, by default, the maximum length of a path (MAX_PATH) is 260 + characters, and operations on paths longer than that fail. But it is possible + to overcome this by converting the path to "extended-length" form before + performing the operation: + https://docs.microsoft.com/en-us/windows/win32/fileio/naming-a-file#maximum-path-length-limitation + + On Windows, this function returns the extended-length absolute version of path. + On other platforms it returns path unchanged. + """ + if sys.platform.startswith("win32"): + path = path.resolve() + path = Path(get_extended_length_path_str(str(path))) + return path + + +def get_extended_length_path_str(path: str) -> str: + """Convert a path to a Windows extended length path.""" + long_path_prefix = "\\\\?\\" + unc_long_path_prefix = "\\\\?\\UNC\\" + if path.startswith((long_path_prefix, unc_long_path_prefix)): + return path + # UNC + if path.startswith("\\\\"): + return unc_long_path_prefix + path[2:] + return long_path_prefix + path + + +def rm_rf(path: Path) -> None: + """Remove the path contents recursively, even if some elements + are read-only.""" + path = ensure_extended_length_path(path) + onerror = partial(on_rm_rf_error, start_path=path) + if sys.version_info >= (3, 12): + shutil.rmtree(str(path), onexc=onerror) + else: + shutil.rmtree(str(path), onerror=onerror) + + +def find_prefixed(root: Path, prefix: str) -> Iterator[os.DirEntry[str]]: + """Find all elements in root that begin with the prefix, case-insensitive.""" + l_prefix = prefix.lower() + for x in os.scandir(root): + if x.name.lower().startswith(l_prefix): + yield x + + +def extract_suffixes(iter: Iterable[os.DirEntry[str]], prefix: str) -> Iterator[str]: + """Return the parts of the paths following the prefix. + + :param iter: Iterator over path names. + :param prefix: Expected prefix of the path names. + """ + p_len = len(prefix) + for entry in iter: + yield entry.name[p_len:] + + +def find_suffixes(root: Path, prefix: str) -> Iterator[str]: + """Combine find_prefixes and extract_suffixes.""" + return extract_suffixes(find_prefixed(root, prefix), prefix) + + +def parse_num(maybe_num: str) -> int: + """Parse number path suffixes, returns -1 on error.""" + try: + return int(maybe_num) + except ValueError: + return -1 + + +def _force_symlink(root: Path, target: str | PurePath, link_to: str | Path) -> None: + """Helper to create the current symlink. + + It's full of race conditions that are reasonably OK to ignore + for the context of best effort linking to the latest test run. + + The presumption being that in case of much parallelism + the inaccuracy is going to be acceptable. + """ + current_symlink = root.joinpath(target) + try: + current_symlink.unlink() + except OSError: + pass + try: + current_symlink.symlink_to(link_to) + except Exception: + pass + + +def make_numbered_dir(root: Path, prefix: str, mode: int = 0o700) -> Path: + """Create a directory with an increased number as suffix for the given prefix.""" + for i in range(10): + # try up to 10 times to create the folder + max_existing = max(map(parse_num, find_suffixes(root, prefix)), default=-1) + new_number = max_existing + 1 + new_path = root.joinpath(f"{prefix}{new_number}") + try: + new_path.mkdir(mode=mode) + except Exception: + pass + else: + _force_symlink(root, prefix + "current", new_path) + return new_path + else: + raise OSError( + "could not create numbered dir with prefix " + f"{prefix} in {root} after 10 tries" + ) + + +def create_cleanup_lock(p: Path) -> Path: + """Create a lock to prevent premature folder cleanup.""" + lock_path = get_lock_path(p) + try: + fd = os.open(str(lock_path), os.O_WRONLY | os.O_CREAT | os.O_EXCL, 0o644) + except FileExistsError as e: + raise OSError(f"cannot create lockfile in {p}") from e + else: + pid = os.getpid() + spid = str(pid).encode() + os.write(fd, spid) + os.close(fd) + if not lock_path.is_file(): + raise OSError("lock path got renamed after successful creation") + return lock_path + + +def register_cleanup_lock_removal( + lock_path: Path, register: Any = atexit.register +) -> Any: + """Register a cleanup function for removing a lock, by default on atexit.""" + pid = os.getpid() + + def cleanup_on_exit(lock_path: Path = lock_path, original_pid: int = pid) -> None: + current_pid = os.getpid() + if current_pid != original_pid: + # fork + return + try: + lock_path.unlink() + except OSError: + pass + + return register(cleanup_on_exit) + + +def maybe_delete_a_numbered_dir(path: Path) -> None: + """Remove a numbered directory if its lock can be obtained and it does + not seem to be in use.""" + path = ensure_extended_length_path(path) + lock_path = None + try: + lock_path = create_cleanup_lock(path) + parent = path.parent + + garbage = parent.joinpath(f"garbage-{uuid.uuid4()}") + path.rename(garbage) + rm_rf(garbage) + except OSError: + # known races: + # * other process did a cleanup at the same time + # * deletable folder was found + # * process cwd (Windows) + return + finally: + # If we created the lock, ensure we remove it even if we failed + # to properly remove the numbered dir. + if lock_path is not None: + try: + lock_path.unlink() + except OSError: + pass + + +def ensure_deletable(path: Path, consider_lock_dead_if_created_before: float) -> bool: + """Check if `path` is deletable based on whether the lock file is expired.""" + if path.is_symlink(): + return False + lock = get_lock_path(path) + try: + if not lock.is_file(): + return True + except OSError: + # we might not have access to the lock file at all, in this case assume + # we don't have access to the entire directory (#7491). + return False + try: + lock_time = lock.stat().st_mtime + except Exception: + return False + else: + if lock_time < consider_lock_dead_if_created_before: + # We want to ignore any errors while trying to remove the lock such as: + # - PermissionDenied, like the file permissions have changed since the lock creation; + # - FileNotFoundError, in case another pytest process got here first; + # and any other cause of failure. + with contextlib.suppress(OSError): + lock.unlink() + return True + return False + + +def try_cleanup(path: Path, consider_lock_dead_if_created_before: float) -> None: + """Try to cleanup a folder if we can ensure it's deletable.""" + if ensure_deletable(path, consider_lock_dead_if_created_before): + maybe_delete_a_numbered_dir(path) + + +def cleanup_candidates(root: Path, prefix: str, keep: int) -> Iterator[Path]: + """List candidates for numbered directories to be removed - follows py.path.""" + max_existing = max(map(parse_num, find_suffixes(root, prefix)), default=-1) + max_delete = max_existing - keep + entries = find_prefixed(root, prefix) + entries, entries2 = itertools.tee(entries) + numbers = map(parse_num, extract_suffixes(entries2, prefix)) + for entry, number in zip(entries, numbers, strict=True): + if number <= max_delete: + yield Path(entry) + + +def cleanup_dead_symlinks(root: Path) -> None: + for left_dir in root.iterdir(): + if left_dir.is_symlink(): + if not left_dir.resolve().exists(): + left_dir.unlink() + + +def cleanup_numbered_dir( + root: Path, prefix: str, keep: int, consider_lock_dead_if_created_before: float +) -> None: + """Cleanup for lock driven numbered directories.""" + if not root.exists(): + return + for path in cleanup_candidates(root, prefix, keep): + try_cleanup(path, consider_lock_dead_if_created_before) + for path in root.glob("garbage-*"): + try_cleanup(path, consider_lock_dead_if_created_before) + + cleanup_dead_symlinks(root) + + +def make_numbered_dir_with_cleanup( + root: Path, + prefix: str, + keep: int, + lock_timeout: float, + mode: int, +) -> Path: + """Create a numbered dir with a cleanup lock and remove old ones.""" + e = None + for i in range(10): + try: + p = make_numbered_dir(root, prefix, mode) + # Only lock the current dir when keep is not 0 + if keep != 0: + lock_path = create_cleanup_lock(p) + register_cleanup_lock_removal(lock_path) + except Exception as exc: + e = exc + else: + consider_lock_dead_if_created_before = p.stat().st_mtime - lock_timeout + # Register a cleanup for program exit + atexit.register( + cleanup_numbered_dir, + root, + prefix, + keep, + consider_lock_dead_if_created_before, + ) + return p + assert e is not None + raise e + + +def resolve_from_str(input: str, rootpath: Path) -> Path: + input = expanduser(input) + input = expandvars(input) + if isabs(input): + return Path(input) + else: + return rootpath.joinpath(input) + + +def fnmatch_ex(pattern: str, path: str | os.PathLike[str]) -> bool: + """A port of FNMatcher from py.path.common which works with PurePath() instances. + + The difference between this algorithm and PurePath.match() is that the + latter matches "**" glob expressions for each part of the path, while + this algorithm uses the whole path instead. + + For example: + "tests/foo/bar/doc/test_foo.py" matches pattern "tests/**/doc/test*.py" + with this algorithm, but not with PurePath.match(). + + This algorithm was ported to keep backward-compatibility with existing + settings which assume paths match according this logic. + + References: + * https://bugs.python.org/issue29249 + * https://bugs.python.org/issue34731 + """ + path = PurePath(path) + iswin32 = sys.platform.startswith("win") + + if iswin32 and sep not in pattern and posix_sep in pattern: + # Running on Windows, the pattern has no Windows path separators, + # and the pattern has one or more Posix path separators. Replace + # the Posix path separators with the Windows path separator. + pattern = pattern.replace(posix_sep, sep) + + if sep not in pattern: + name = path.name + else: + name = str(path) + if path.is_absolute() and not os.path.isabs(pattern): + pattern = f"*{os.sep}{pattern}" + return fnmatch.fnmatch(name, pattern) + + +def parts(s: str) -> set[str]: + parts = s.split(sep) + return {sep.join(parts[: i + 1]) or sep for i in range(len(parts))} + + +def symlink_or_skip( + src: os.PathLike[str] | str, + dst: os.PathLike[str] | str, + **kwargs: Any, +) -> None: + """Make a symlink, or skip the test in case symlinks are not supported.""" + try: + os.symlink(src, dst, **kwargs) + except OSError as e: + skip(f"symlinks not supported: {e}") + + +class ImportMode(Enum): + """Possible values for `mode` parameter of `import_path`.""" + + prepend = "prepend" + append = "append" + importlib = "importlib" + + +class ImportPathMismatchError(ImportError): + """Raised on import_path() if there is a mismatch of __file__'s. + + This can happen when `import_path` is called multiple times with different filenames that has + the same basename but reside in packages + (for example "/tests1/test_foo.py" and "/tests2/test_foo.py"). + """ + + +def import_path( + path: str | os.PathLike[str], + *, + mode: str | ImportMode = ImportMode.prepend, + root: Path, + consider_namespace_packages: bool, +) -> ModuleType: + """ + Import and return a module from the given path, which can be a file (a module) or + a directory (a package). + + :param path: + Path to the file to import. + + :param mode: + Controls the underlying import mechanism that will be used: + + * ImportMode.prepend: the directory containing the module (or package, taking + `__init__.py` files into account) will be put at the *start* of `sys.path` before + being imported with `importlib.import_module`. + + * ImportMode.append: same as `prepend`, but the directory will be appended + to the end of `sys.path`, if not already in `sys.path`. + + * ImportMode.importlib: uses more fine control mechanisms provided by `importlib` + to import the module, which avoids having to muck with `sys.path` at all. It effectively + allows having same-named test modules in different places. + + :param root: + Used as an anchor when mode == ImportMode.importlib to obtain + a unique name for the module being imported so it can safely be stored + into ``sys.modules``. + + :param consider_namespace_packages: + If True, consider namespace packages when resolving module names. + + :raises ImportPathMismatchError: + If after importing the given `path` and the module `__file__` + are different. Only raised in `prepend` and `append` modes. + """ + path = Path(path) + mode = ImportMode(mode) + + if not path.exists(): + raise ImportError(path) + + if mode is ImportMode.importlib: + # Try to import this module using the standard import mechanisms, but + # without touching sys.path. + try: + pkg_root, module_name = resolve_pkg_root_and_module_name( + path, consider_namespace_packages=consider_namespace_packages + ) + except CouldNotResolvePathError: + pass + else: + # If the given module name is already in sys.modules, do not import it again. + with contextlib.suppress(KeyError): + return sys.modules[module_name] + + mod = _import_module_using_spec( + module_name, path, pkg_root, insert_modules=False + ) + if mod is not None: + return mod + + # Could not import the module with the current sys.path, so we fall back + # to importing the file as a single module, not being a part of a package. + module_name = module_name_from_path(path, root) + with contextlib.suppress(KeyError): + return sys.modules[module_name] + + mod = _import_module_using_spec( + module_name, path, path.parent, insert_modules=True + ) + if mod is None: + raise ImportError(f"Can't find module {module_name} at location {path}") + return mod + + try: + pkg_root, module_name = resolve_pkg_root_and_module_name( + path, consider_namespace_packages=consider_namespace_packages + ) + except CouldNotResolvePathError: + pkg_root, module_name = path.parent, path.stem + + # Change sys.path permanently: restoring it at the end of this function would cause surprising + # problems because of delayed imports: for example, a conftest.py file imported by this function + # might have local imports, which would fail at runtime if we restored sys.path. + if mode is ImportMode.append: + if str(pkg_root) not in sys.path: + sys.path.append(str(pkg_root)) + elif mode is ImportMode.prepend: + if str(pkg_root) != sys.path[0]: + sys.path.insert(0, str(pkg_root)) + else: + assert_never(mode) + + importlib.import_module(module_name) + + mod = sys.modules[module_name] + if path.name == "__init__.py": + return mod + + ignore = os.environ.get("PY_IGNORE_IMPORTMISMATCH", "") + if ignore != "1": + module_file = mod.__file__ + if module_file is None: + raise ImportPathMismatchError(module_name, module_file, path) + + if module_file.endswith((".pyc", ".pyo")): + module_file = module_file[:-1] + if module_file.endswith(os.sep + "__init__.py"): + module_file = module_file[: -(len(os.sep + "__init__.py"))] + + try: + is_same = _is_same(str(path), module_file) + except FileNotFoundError: + is_same = False + + if not is_same: + raise ImportPathMismatchError(module_name, module_file, path) + + return mod + + +def _import_module_using_spec( + module_name: str, module_path: Path, module_location: Path, *, insert_modules: bool +) -> ModuleType | None: + """ + Tries to import a module by its canonical name, path, and its parent location. + + :param module_name: + The expected module name, will become the key of `sys.modules`. + + :param module_path: + The file path of the module, for example `/foo/bar/test_demo.py`. + If module is a package, pass the path to the `__init__.py` of the package. + If module is a namespace package, pass directory path. + + :param module_location: + The parent location of the module. + If module is a package, pass the directory containing the `__init__.py` file. + + :param insert_modules: + If True, will call `insert_missing_modules` to create empty intermediate modules + with made-up module names (when importing test files not reachable from `sys.path`). + + Example 1 of parent_module_*: + + module_name: "a.b.c.demo" + module_path: Path("a/b/c/demo.py") + module_location: Path("a/b/c/") + if "a.b.c" is package ("a/b/c/__init__.py" exists), then + parent_module_name: "a.b.c" + parent_module_path: Path("a/b/c/__init__.py") + parent_module_location: Path("a/b/c/") + else: + parent_module_name: "a.b.c" + parent_module_path: Path("a/b/c") + parent_module_location: Path("a/b/") + + Example 2 of parent_module_*: + + module_name: "a.b.c" + module_path: Path("a/b/c/__init__.py") + module_location: Path("a/b/c/") + if "a.b" is package ("a/b/__init__.py" exists), then + parent_module_name: "a.b" + parent_module_path: Path("a/b/__init__.py") + parent_module_location: Path("a/b/") + else: + parent_module_name: "a.b" + parent_module_path: Path("a/b/") + parent_module_location: Path("a/") + """ + # Attempt to import the parent module, seems is our responsibility: + # https://github.com/python/cpython/blob/73906d5c908c1e0b73c5436faeff7d93698fc074/Lib/importlib/_bootstrap.py#L1308-L1311 + parent_module_name, _, name = module_name.rpartition(".") + parent_module: ModuleType | None = None + if parent_module_name: + parent_module = sys.modules.get(parent_module_name) + # If the parent_module lacks the `__path__` attribute, AttributeError when finding a submodule's spec, + # requiring re-import according to the path. + need_reimport = not hasattr(parent_module, "__path__") + if parent_module is None or need_reimport: + # Get parent_location based on location, get parent_path based on path. + if module_path.name == "__init__.py": + # If the current module is in a package, + # need to leave the package first and then enter the parent module. + parent_module_path = module_path.parent.parent + else: + parent_module_path = module_path.parent + + if (parent_module_path / "__init__.py").is_file(): + # If the parent module is a package, loading by __init__.py file. + parent_module_path = parent_module_path / "__init__.py" + + parent_module = _import_module_using_spec( + parent_module_name, + parent_module_path, + parent_module_path.parent, + insert_modules=insert_modules, + ) + + # Checking with sys.meta_path first in case one of its hooks can import this module, + # such as our own assertion-rewrite hook. + for meta_importer in sys.meta_path: + module_name_of_meta = getattr(meta_importer.__class__, "__module__", "") + if module_name_of_meta == "_pytest.assertion.rewrite" and module_path.is_file(): + # Import modules in subdirectories by module_path + # to ensure assertion rewrites are not missed (#12659). + find_spec_path = [str(module_location), str(module_path)] + else: + find_spec_path = [str(module_location)] + + spec = meta_importer.find_spec(module_name, find_spec_path) + + if spec_matches_module_path(spec, module_path): + break + else: + loader = None + if module_path.is_dir(): + # The `spec_from_file_location` matches a loader based on the file extension by default. + # For a namespace package, need to manually specify a loader. + loader = NamespaceLoader(name, module_path, PathFinder()) # type: ignore[arg-type] + + spec = importlib.util.spec_from_file_location( + module_name, str(module_path), loader=loader + ) + + if spec_matches_module_path(spec, module_path): + assert spec is not None + # Find spec and import this module. + mod = importlib.util.module_from_spec(spec) + sys.modules[module_name] = mod + spec.loader.exec_module(mod) # type: ignore[union-attr] + + # Set this module as an attribute of the parent module (#12194). + if parent_module is not None: + setattr(parent_module, name, mod) + + if insert_modules: + insert_missing_modules(sys.modules, module_name) + return mod + + return None + + +def spec_matches_module_path(module_spec: ModuleSpec | None, module_path: Path) -> bool: + """Return true if the given ModuleSpec can be used to import the given module path.""" + if module_spec is None: + return False + + if module_spec.origin: + return Path(module_spec.origin) == module_path + + # Compare the path with the `module_spec.submodule_Search_Locations` in case + # the module is part of a namespace package. + # https://docs.python.org/3/library/importlib.html#importlib.machinery.ModuleSpec.submodule_search_locations + if module_spec.submodule_search_locations: # can be None. + for path in module_spec.submodule_search_locations: + if Path(path) == module_path: + return True + + return False + + +# Implement a special _is_same function on Windows which returns True if the two filenames +# compare equal, to circumvent os.path.samefile returning False for mounts in UNC (#7678). +if sys.platform.startswith("win"): + + def _is_same(f1: str, f2: str) -> bool: + return Path(f1) == Path(f2) or os.path.samefile(f1, f2) + +else: + + def _is_same(f1: str, f2: str) -> bool: + return os.path.samefile(f1, f2) + + +def module_name_from_path(path: Path, root: Path) -> str: + """ + Return a dotted module name based on the given path, anchored on root. + + For example: path="projects/src/tests/test_foo.py" and root="/projects", the + resulting module name will be "src.tests.test_foo". + """ + path = path.with_suffix("") + try: + relative_path = path.relative_to(root) + except ValueError: + # If we can't get a relative path to root, use the full path, except + # for the first part ("d:\\" or "/" depending on the platform, for example). + path_parts = path.parts[1:] + else: + # Use the parts for the relative path to the root path. + path_parts = relative_path.parts + + # Module name for packages do not contain the __init__ file, unless + # the `__init__.py` file is at the root. + if len(path_parts) >= 2 and path_parts[-1] == "__init__": + path_parts = path_parts[:-1] + + # Module names cannot contain ".", normalize them to "_". This prevents + # a directory having a "." in the name (".env.310" for example) causing extra intermediate modules. + # Also, important to replace "." at the start of paths, as those are considered relative imports. + path_parts = tuple(x.replace(".", "_") for x in path_parts) + + return ".".join(path_parts) + + +def insert_missing_modules(modules: dict[str, ModuleType], module_name: str) -> None: + """ + Used by ``import_path`` to create intermediate modules when using mode=importlib. + + When we want to import a module as "src.tests.test_foo" for example, we need + to create empty modules "src" and "src.tests" after inserting "src.tests.test_foo", + otherwise "src.tests.test_foo" is not importable by ``__import__``. + """ + module_parts = module_name.split(".") + while module_name: + parent_module_name, _, child_name = module_name.rpartition(".") + if parent_module_name: + parent_module = modules.get(parent_module_name) + if parent_module is None: + try: + # If sys.meta_path is empty, calling import_module will issue + # a warning and raise ModuleNotFoundError. To avoid the + # warning, we check sys.meta_path explicitly and raise the error + # ourselves to fall back to creating a dummy module. + if not sys.meta_path: + raise ModuleNotFoundError + parent_module = importlib.import_module(parent_module_name) + except ModuleNotFoundError: + parent_module = ModuleType( + module_name, + doc="Empty module created by pytest's importmode=importlib.", + ) + modules[parent_module_name] = parent_module + + # Add child attribute to the parent that can reference the child + # modules. + if not hasattr(parent_module, child_name): + setattr(parent_module, child_name, modules[module_name]) + + module_parts.pop(-1) + module_name = ".".join(module_parts) + + +def resolve_package_path(path: Path) -> Path | None: + """Return the Python package path by looking for the last + directory upwards which still contains an __init__.py. + + Returns None if it cannot be determined. + """ + result = None + for parent in itertools.chain((path,), path.parents): + if parent.is_dir(): + if not (parent / "__init__.py").is_file(): + break + if not parent.name.isidentifier(): + break + result = parent + return result + + +def resolve_pkg_root_and_module_name( + path: Path, *, consider_namespace_packages: bool = False +) -> tuple[Path, str]: + """ + Return the path to the directory of the root package that contains the + given Python file, and its module name: + + src/ + app/ + __init__.py + core/ + __init__.py + models.py + + Passing the full path to `models.py` will yield Path("src") and "app.core.models". + + If consider_namespace_packages is True, then we additionally check upwards in the hierarchy + for namespace packages: + + https://packaging.python.org/en/latest/guides/packaging-namespace-packages + + Raises CouldNotResolvePathError if the given path does not belong to a package (missing any __init__.py files). + """ + pkg_root: Path | None = None + pkg_path = resolve_package_path(path) + if pkg_path is not None: + pkg_root = pkg_path.parent + if consider_namespace_packages: + start = pkg_root if pkg_root is not None else path.parent + for candidate in (start, *start.parents): + module_name = compute_module_name(candidate, path) + if module_name and is_importable(module_name, path): + # Point the pkg_root to the root of the namespace package. + pkg_root = candidate + break + + if pkg_root is not None: + module_name = compute_module_name(pkg_root, path) + if module_name: + return pkg_root, module_name + + raise CouldNotResolvePathError(f"Could not resolve for {path}") + + +def is_importable(module_name: str, module_path: Path) -> bool: + """ + Return if the given module path could be imported normally by Python, akin to the user + entering the REPL and importing the corresponding module name directly, and corresponds + to the module_path specified. + + :param module_name: + Full module name that we want to check if is importable. + For example, "app.models". + + :param module_path: + Full path to the python module/package we want to check if is importable. + For example, "/projects/src/app/models.py". + """ + try: + # Note this is different from what we do in ``_import_module_using_spec``, where we explicitly search through + # sys.meta_path to be able to pass the path of the module that we want to import (``meta_importer.find_spec``). + # Using importlib.util.find_spec() is different, it gives the same results as trying to import + # the module normally in the REPL. + spec = importlib.util.find_spec(module_name) + except (ImportError, ValueError, ImportWarning): + return False + else: + return spec_matches_module_path(spec, module_path) + + +def compute_module_name(root: Path, module_path: Path) -> str | None: + """Compute a module name based on a path and a root anchor.""" + try: + path_without_suffix = module_path.with_suffix("") + except ValueError: + # Empty paths (such as Path.cwd()) might break meta_path hooks (like our own assertion rewriter). + return None + + try: + relative = path_without_suffix.relative_to(root) + except ValueError: # pragma: no cover + return None + names = list(relative.parts) + if not names: + return None + if names[-1] == "__init__": + names.pop() + return ".".join(names) + + +class CouldNotResolvePathError(Exception): + """Custom exception raised by resolve_pkg_root_and_module_name.""" + + +def scandir( + path: str | os.PathLike[str], + sort_key: Callable[[os.DirEntry[str]], object] = lambda entry: entry.name, +) -> list[os.DirEntry[str]]: + """Scan a directory recursively, in breadth-first order. + + The returned entries are sorted according to the given key. + The default is to sort by name. + If the directory does not exist, return an empty list. + """ + entries = [] + # Attempt to create a scandir iterator for the given path. + try: + scandir_iter = os.scandir(path) + except FileNotFoundError: + # If the directory does not exist, return an empty list. + return [] + # Use the scandir iterator in a context manager to ensure it is properly closed. + with scandir_iter as s: + for entry in s: + try: + entry.is_file() + except OSError as err: + if _ignore_error(err): + continue + # Reraise non-ignorable errors to avoid hiding issues. + raise + entries.append(entry) + entries.sort(key=sort_key) # type: ignore[arg-type] + return entries + + +def visit( + path: str | os.PathLike[str], recurse: Callable[[os.DirEntry[str]], bool] +) -> Iterator[os.DirEntry[str]]: + """Walk a directory recursively, in breadth-first order. + + The `recurse` predicate determines whether a directory is recursed. + + Entries at each directory level are sorted. + """ + entries = scandir(path) + yield from entries + for entry in entries: + if entry.is_dir() and recurse(entry): + yield from visit(entry.path, recurse) + + +def absolutepath(path: str | os.PathLike[str]) -> Path: + """Convert a path to an absolute path using os.path.abspath. + + Prefer this over Path.resolve() (see #6523). + Prefer this over Path.absolute() (not public, doesn't normalize). + """ + return Path(os.path.abspath(path)) + + +def commonpath(path1: Path, path2: Path) -> Path | None: + """Return the common part shared with the other path, or None if there is + no common part. + + If one path is relative and one is absolute, returns None. + """ + try: + return Path(os.path.commonpath((str(path1), str(path2)))) + except ValueError: + return None + + +def bestrelpath(directory: Path, dest: Path) -> str: + """Return a string which is a relative path from directory to dest such + that directory/bestrelpath == dest. + + The paths must be either both absolute or both relative. + + If no such path can be determined, returns dest. + """ + assert isinstance(directory, Path) + assert isinstance(dest, Path) + if dest == directory: + return os.curdir + # Find the longest common directory. + base = commonpath(directory, dest) + # Can be the case on Windows for two absolute paths on different drives. + # Can be the case for two relative paths without common prefix. + # Can be the case for a relative path and an absolute path. + if not base: + return str(dest) + reldirectory = directory.relative_to(base) + reldest = dest.relative_to(base) + return os.path.join( + # Back from directory to base. + *([os.pardir] * len(reldirectory.parts)), + # Forward from base to dest. + *reldest.parts, + ) + + +def safe_exists(p: Path) -> bool: + """Like Path.exists(), but account for input arguments that might be too long (#11394).""" + try: + return p.exists() + except (ValueError, OSError): + # ValueError: stat: path too long for Windows + # OSError: [WinError 123] The filename, directory name, or volume label syntax is incorrect + return False + + +def samefile_nofollow(p1: Path, p2: Path) -> bool: + """Test whether two paths reference the same actual file or directory. + + Unlike Path.samefile(), does not resolve symlinks. + """ + return os.path.samestat(p1.lstat(), p2.lstat()) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/py.typed b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/py.typed new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/pytester.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/pytester.py new file mode 100644 index 0000000000000000000000000000000000000000..1cd5f05dd7edaa173b0bf07f88f9533c83b534a9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/pytester.py @@ -0,0 +1,1791 @@ +# mypy: allow-untyped-defs +"""(Disabled by default) support for testing pytest and pytest plugins. + +PYTEST_DONT_REWRITE +""" + +from __future__ import annotations + +import collections.abc +from collections.abc import Callable +from collections.abc import Generator +from collections.abc import Iterable +from collections.abc import Sequence +import contextlib +from fnmatch import fnmatch +import gc +import importlib +from io import StringIO +import locale +import os +from pathlib import Path +import platform +import re +import shutil +import subprocess +import sys +import traceback +from typing import Any +from typing import Final +from typing import final +from typing import IO +from typing import Literal +from typing import overload +from typing import TextIO +from typing import TYPE_CHECKING +from weakref import WeakKeyDictionary + +from iniconfig import IniConfig +from iniconfig import SectionWrapper + +from _pytest import timing +from _pytest._code import Source +from _pytest.capture import _get_multicapture +from _pytest.compat import NOTSET +from _pytest.compat import NotSetType +from _pytest.config import _PluggyPlugin +from _pytest.config import Config +from _pytest.config import ExitCode +from _pytest.config import hookimpl +from _pytest.config import main +from _pytest.config import PytestPluginManager +from _pytest.config.argparsing import Parser +from _pytest.deprecated import check_ispytest +from _pytest.fixtures import fixture +from _pytest.fixtures import FixtureRequest +from _pytest.main import Session +from _pytest.monkeypatch import MonkeyPatch +from _pytest.nodes import Collector +from _pytest.nodes import Item +from _pytest.outcomes import fail +from _pytest.outcomes import importorskip +from _pytest.outcomes import skip +from _pytest.pathlib import bestrelpath +from _pytest.pathlib import make_numbered_dir +from _pytest.reports import CollectReport +from _pytest.reports import TestReport +from _pytest.tmpdir import TempPathFactory +from _pytest.warning_types import PytestFDWarning + + +if TYPE_CHECKING: + import pexpect + + +pytest_plugins = ["pytester_assertions"] + + +IGNORE_PAM = [ # filenames added when obtaining details about the current user + "/var/lib/sss/mc/passwd" +] + + +def pytest_addoption(parser: Parser) -> None: + parser.addoption( + "--lsof", + action="store_true", + dest="lsof", + default=False, + help="Run FD checks if lsof is available", + ) + + parser.addoption( + "--runpytest", + default="inprocess", + dest="runpytest", + choices=("inprocess", "subprocess"), + help=( + "Run pytest sub runs in tests using an 'inprocess' " + "or 'subprocess' (python -m main) method" + ), + ) + + parser.addini( + "pytester_example_dir", help="Directory to take the pytester example files from" + ) + + +def pytest_configure(config: Config) -> None: + if config.getvalue("lsof"): + checker = LsofFdLeakChecker() + if checker.matching_platform(): + config.pluginmanager.register(checker) + + config.addinivalue_line( + "markers", + "pytester_example_path(*path_segments): join the given path " + "segments to `pytester_example_dir` for this test.", + ) + + +class LsofFdLeakChecker: + def get_open_files(self) -> list[tuple[str, str]]: + if sys.version_info >= (3, 11): + # New in Python 3.11, ignores utf-8 mode + encoding = locale.getencoding() + else: + encoding = locale.getpreferredencoding(False) + out = subprocess.run( + ("lsof", "-Ffn0", "-p", str(os.getpid())), + stdout=subprocess.PIPE, + stderr=subprocess.DEVNULL, + check=True, + text=True, + encoding=encoding, + ).stdout + + def isopen(line: str) -> bool: + return line.startswith("f") and ( + "deleted" not in line + and "mem" not in line + and "txt" not in line + and "cwd" not in line + ) + + open_files = [] + + for line in out.split("\n"): + if isopen(line): + fields = line.split("\0") + fd = fields[0][1:] + filename = fields[1][1:] + if filename in IGNORE_PAM: + continue + if filename.startswith("/"): + open_files.append((fd, filename)) + + return open_files + + def matching_platform(self) -> bool: + try: + subprocess.run(("lsof", "-v"), check=True) + except (OSError, subprocess.CalledProcessError): + return False + else: + return True + + @hookimpl(wrapper=True, tryfirst=True) + def pytest_runtest_protocol(self, item: Item) -> Generator[None, object, object]: + lines1 = self.get_open_files() + try: + return (yield) + finally: + if hasattr(sys, "pypy_version_info"): + gc.collect() + lines2 = self.get_open_files() + + new_fds = {t[0] for t in lines2} - {t[0] for t in lines1} + leaked_files = [t for t in lines2 if t[0] in new_fds] + if leaked_files: + error = [ + f"***** {len(leaked_files)} FD leakage detected", + *(str(f) for f in leaked_files), + "*** Before:", + *(str(f) for f in lines1), + "*** After:", + *(str(f) for f in lines2), + f"***** {len(leaked_files)} FD leakage detected", + "*** function {}:{}: {} ".format(*item.location), + "See issue #2366", + ] + item.warn(PytestFDWarning("\n".join(error))) + + +# used at least by pytest-xdist plugin + + +@fixture +def _pytest(request: FixtureRequest) -> PytestArg: + """Return a helper which offers a gethookrecorder(hook) method which + returns a HookRecorder instance which helps to make assertions about called + hooks.""" + return PytestArg(request) + + +class PytestArg: + def __init__(self, request: FixtureRequest) -> None: + self._request = request + + def gethookrecorder(self, hook) -> HookRecorder: + hookrecorder = HookRecorder(hook._pm) + self._request.addfinalizer(hookrecorder.finish_recording) + return hookrecorder + + +def get_public_names(values: Iterable[str]) -> list[str]: + """Only return names from iterator values without a leading underscore.""" + return [x for x in values if x[0] != "_"] + + +@final +class RecordedHookCall: + """A recorded call to a hook. + + The arguments to the hook call are set as attributes. + For example: + + .. code-block:: python + + calls = hook_recorder.getcalls("pytest_runtest_setup") + # Suppose pytest_runtest_setup was called once with `item=an_item`. + assert calls[0].item is an_item + """ + + def __init__(self, name: str, kwargs) -> None: + self.__dict__.update(kwargs) + self._name = name + + def __repr__(self) -> str: + d = self.__dict__.copy() + del d["_name"] + return f"<RecordedHookCall {self._name!r}(**{d!r})>" + + if TYPE_CHECKING: + # The class has undetermined attributes, this tells mypy about it. + def __getattr__(self, key: str): ... + + +@final +class HookRecorder: + """Record all hooks called in a plugin manager. + + Hook recorders are created by :class:`Pytester`. + + This wraps all the hook calls in the plugin manager, recording each call + before propagating the normal calls. + """ + + def __init__( + self, pluginmanager: PytestPluginManager, *, _ispytest: bool = False + ) -> None: + check_ispytest(_ispytest) + + self._pluginmanager = pluginmanager + self.calls: list[RecordedHookCall] = [] + self.ret: int | ExitCode | None = None + + def before(hook_name: str, hook_impls, kwargs) -> None: + self.calls.append(RecordedHookCall(hook_name, kwargs)) + + def after(outcome, hook_name: str, hook_impls, kwargs) -> None: + pass + + self._undo_wrapping = pluginmanager.add_hookcall_monitoring(before, after) + + def finish_recording(self) -> None: + self._undo_wrapping() + + def getcalls(self, names: str | Iterable[str]) -> list[RecordedHookCall]: + """Get all recorded calls to hooks with the given names (or name).""" + if isinstance(names, str): + names = names.split() + return [call for call in self.calls if call._name in names] + + def assert_contains(self, entries: Sequence[tuple[str, str]]) -> None: + __tracebackhide__ = True + i = 0 + entries = list(entries) + # Since Python 3.13, f_locals is not a dict, but eval requires a dict. + backlocals = dict(sys._getframe(1).f_locals) + while entries: + name, check = entries.pop(0) + for ind, call in enumerate(self.calls[i:]): + if call._name == name: + print("NAMEMATCH", name, call) + if eval(check, backlocals, call.__dict__): + print("CHECKERMATCH", repr(check), "->", call) + else: + print("NOCHECKERMATCH", repr(check), "-", call) + continue + i += ind + 1 + break + print("NONAMEMATCH", name, "with", call) + else: + fail(f"could not find {name!r} check {check!r}") + + def popcall(self, name: str) -> RecordedHookCall: + __tracebackhide__ = True + for i, call in enumerate(self.calls): + if call._name == name: + del self.calls[i] + return call + lines = [f"could not find call {name!r}, in:"] + lines.extend([f" {x}" for x in self.calls]) + fail("\n".join(lines)) + + def getcall(self, name: str) -> RecordedHookCall: + values = self.getcalls(name) + assert len(values) == 1, (name, values) + return values[0] + + # functionality for test reports + + @overload + def getreports( + self, + names: Literal["pytest_collectreport"], + ) -> Sequence[CollectReport]: ... + + @overload + def getreports( + self, + names: Literal["pytest_runtest_logreport"], + ) -> Sequence[TestReport]: ... + + @overload + def getreports( + self, + names: str | Iterable[str] = ( + "pytest_collectreport", + "pytest_runtest_logreport", + ), + ) -> Sequence[CollectReport | TestReport]: ... + + def getreports( + self, + names: str | Iterable[str] = ( + "pytest_collectreport", + "pytest_runtest_logreport", + ), + ) -> Sequence[CollectReport | TestReport]: + return [x.report for x in self.getcalls(names)] + + def matchreport( + self, + inamepart: str = "", + names: str | Iterable[str] = ( + "pytest_runtest_logreport", + "pytest_collectreport", + ), + when: str | None = None, + ) -> CollectReport | TestReport: + """Return a testreport whose dotted import path matches.""" + values = [] + for rep in self.getreports(names=names): + if not when and rep.when != "call" and rep.passed: + # setup/teardown passing reports - let's ignore those + continue + if when and rep.when != when: + continue + if not inamepart or inamepart in rep.nodeid.split("::"): + values.append(rep) + if not values: + raise ValueError( + f"could not find test report matching {inamepart!r}: " + "no test reports at all!" + ) + if len(values) > 1: + raise ValueError( + f"found 2 or more testreports matching {inamepart!r}: {values}" + ) + return values[0] + + @overload + def getfailures( + self, + names: Literal["pytest_collectreport"], + ) -> Sequence[CollectReport]: ... + + @overload + def getfailures( + self, + names: Literal["pytest_runtest_logreport"], + ) -> Sequence[TestReport]: ... + + @overload + def getfailures( + self, + names: str | Iterable[str] = ( + "pytest_collectreport", + "pytest_runtest_logreport", + ), + ) -> Sequence[CollectReport | TestReport]: ... + + def getfailures( + self, + names: str | Iterable[str] = ( + "pytest_collectreport", + "pytest_runtest_logreport", + ), + ) -> Sequence[CollectReport | TestReport]: + return [rep for rep in self.getreports(names) if rep.failed] + + def getfailedcollections(self) -> Sequence[CollectReport]: + return self.getfailures("pytest_collectreport") + + def listoutcomes( + self, + ) -> tuple[ + Sequence[TestReport], + Sequence[CollectReport | TestReport], + Sequence[CollectReport | TestReport], + ]: + passed = [] + skipped = [] + failed = [] + for rep in self.getreports( + ("pytest_collectreport", "pytest_runtest_logreport") + ): + if rep.passed: + if rep.when == "call": + assert isinstance(rep, TestReport) + passed.append(rep) + elif rep.skipped: + skipped.append(rep) + else: + assert rep.failed, f"Unexpected outcome: {rep!r}" + failed.append(rep) + return passed, skipped, failed + + def countoutcomes(self) -> list[int]: + return [len(x) for x in self.listoutcomes()] + + def assertoutcome(self, passed: int = 0, skipped: int = 0, failed: int = 0) -> None: + __tracebackhide__ = True + from _pytest.pytester_assertions import assertoutcome + + outcomes = self.listoutcomes() + assertoutcome( + outcomes, + passed=passed, + skipped=skipped, + failed=failed, + ) + + def clear(self) -> None: + self.calls[:] = [] + + +@fixture +def linecomp() -> LineComp: + """A :class: `LineComp` instance for checking that an input linearly + contains a sequence of strings.""" + return LineComp() + + +@fixture(name="LineMatcher") +def LineMatcher_fixture(request: FixtureRequest) -> type[LineMatcher]: + """A reference to the :class: `LineMatcher`. + + This is instantiable with a list of lines (without their trailing newlines). + This is useful for testing large texts, such as the output of commands. + """ + return LineMatcher + + +@fixture +def pytester( + request: FixtureRequest, tmp_path_factory: TempPathFactory, monkeypatch: MonkeyPatch +) -> Pytester: + """ + Facilities to write tests/configuration files, execute pytest in isolation, and match + against expected output, perfect for black-box testing of pytest plugins. + + It attempts to isolate the test run from external factors as much as possible, modifying + the current working directory to ``path`` and environment variables during initialization. + + It is particularly useful for testing plugins. It is similar to the :fixture:`tmp_path` + fixture but provides methods which aid in testing pytest itself. + """ + return Pytester(request, tmp_path_factory, monkeypatch, _ispytest=True) + + +@fixture +def _sys_snapshot() -> Generator[None]: + snappaths = SysPathsSnapshot() + snapmods = SysModulesSnapshot() + yield + snapmods.restore() + snappaths.restore() + + +@fixture +def _config_for_test() -> Generator[Config]: + from _pytest.config import get_config + + config = get_config() + yield config + config._ensure_unconfigure() # cleanup, e.g. capman closing tmpfiles. + + +# Regex to match the session duration string in the summary: "74.34s". +rex_session_duration = re.compile(r"\d+\.\d\ds") +# Regex to match all the counts and phrases in the summary line: "34 passed, 111 skipped". +rex_outcome = re.compile(r"(\d+) (\w+)") + + +@final +class RunResult: + """The result of running a command from :class:`~pytest.Pytester`.""" + + def __init__( + self, + ret: int | ExitCode, + outlines: list[str], + errlines: list[str], + duration: float, + ) -> None: + try: + self.ret: int | ExitCode = ExitCode(ret) + """The return value.""" + except ValueError: + self.ret = ret + self.outlines = outlines + """List of lines captured from stdout.""" + self.errlines = errlines + """List of lines captured from stderr.""" + self.stdout = LineMatcher(outlines) + """:class:`~pytest.LineMatcher` of stdout. + + Use e.g. :func:`str(stdout) <pytest.LineMatcher.__str__()>` to reconstruct stdout, or the commonly used + :func:`stdout.fnmatch_lines() <pytest.LineMatcher.fnmatch_lines()>` method. + """ + self.stderr = LineMatcher(errlines) + """:class:`~pytest.LineMatcher` of stderr.""" + self.duration = duration + """Duration in seconds.""" + + def __repr__(self) -> str: + return ( + f"<RunResult ret={self.ret!s} " + f"len(stdout.lines)={len(self.stdout.lines)} " + f"len(stderr.lines)={len(self.stderr.lines)} " + f"duration={self.duration:.2f}s>" + ) + + def parseoutcomes(self) -> dict[str, int]: + """Return a dictionary of outcome noun -> count from parsing the terminal + output that the test process produced. + + The returned nouns will always be in plural form:: + + ======= 1 failed, 1 passed, 1 warning, 1 error in 0.13s ==== + + Will return ``{"failed": 1, "passed": 1, "warnings": 1, "errors": 1}``. + """ + return self.parse_summary_nouns(self.outlines) + + @classmethod + def parse_summary_nouns(cls, lines) -> dict[str, int]: + """Extract the nouns from a pytest terminal summary line. + + It always returns the plural noun for consistency:: + + ======= 1 failed, 1 passed, 1 warning, 1 error in 0.13s ==== + + Will return ``{"failed": 1, "passed": 1, "warnings": 1, "errors": 1}``. + """ + for line in reversed(lines): + if rex_session_duration.search(line): + outcomes = rex_outcome.findall(line) + ret = {noun: int(count) for (count, noun) in outcomes} + break + else: + raise ValueError("Pytest terminal summary report not found") + + to_plural = { + "warning": "warnings", + "error": "errors", + } + return {to_plural.get(k, k): v for k, v in ret.items()} + + def assert_outcomes( + self, + passed: int = 0, + skipped: int = 0, + failed: int = 0, + errors: int = 0, + xpassed: int = 0, + xfailed: int = 0, + warnings: int | None = None, + deselected: int | None = None, + ) -> None: + """ + Assert that the specified outcomes appear with the respective + numbers (0 means it didn't occur) in the text output from a test run. + + ``warnings`` and ``deselected`` are only checked if not None. + """ + __tracebackhide__ = True + from _pytest.pytester_assertions import assert_outcomes + + outcomes = self.parseoutcomes() + assert_outcomes( + outcomes, + passed=passed, + skipped=skipped, + failed=failed, + errors=errors, + xpassed=xpassed, + xfailed=xfailed, + warnings=warnings, + deselected=deselected, + ) + + +class SysModulesSnapshot: + def __init__(self, preserve: Callable[[str], bool] | None = None) -> None: + self.__preserve = preserve + self.__saved = dict(sys.modules) + + def restore(self) -> None: + if self.__preserve: + self.__saved.update( + (k, m) for k, m in sys.modules.items() if self.__preserve(k) + ) + sys.modules.clear() + sys.modules.update(self.__saved) + + +class SysPathsSnapshot: + def __init__(self) -> None: + self.__saved = list(sys.path), list(sys.meta_path) + + def restore(self) -> None: + sys.path[:], sys.meta_path[:] = self.__saved + + +@final +class Pytester: + """ + Facilities to write tests/configuration files, execute pytest in isolation, and match + against expected output, perfect for black-box testing of pytest plugins. + + It attempts to isolate the test run from external factors as much as possible, modifying + the current working directory to :attr:`path` and environment variables during initialization. + """ + + __test__ = False + + CLOSE_STDIN: Final = NOTSET + + class TimeoutExpired(Exception): + pass + + def __init__( + self, + request: FixtureRequest, + tmp_path_factory: TempPathFactory, + monkeypatch: MonkeyPatch, + *, + _ispytest: bool = False, + ) -> None: + check_ispytest(_ispytest) + self._request = request + self._mod_collections: WeakKeyDictionary[Collector, list[Item | Collector]] = ( + WeakKeyDictionary() + ) + if request.function: + name: str = request.function.__name__ + else: + name = request.node.name + self._name = name + self._path: Path = tmp_path_factory.mktemp(name, numbered=True) + #: A list of plugins to use with :py:meth:`parseconfig` and + #: :py:meth:`runpytest`. Initially this is an empty list but plugins can + #: be added to the list. + #: + #: When running in subprocess mode, specify plugins by name (str) - adding + #: plugin objects directly is not supported. + self.plugins: list[str | _PluggyPlugin] = [] + self._sys_path_snapshot = SysPathsSnapshot() + self._sys_modules_snapshot = self.__take_sys_modules_snapshot() + self._request.addfinalizer(self._finalize) + self._method = self._request.config.getoption("--runpytest") + self._test_tmproot = tmp_path_factory.mktemp(f"tmp-{name}", numbered=True) + + self._monkeypatch = mp = monkeypatch + self.chdir() + mp.setenv("PYTEST_DEBUG_TEMPROOT", str(self._test_tmproot)) + # Ensure no unexpected caching via tox. + mp.delenv("TOX_ENV_DIR", raising=False) + # Discard outer pytest options. + mp.delenv("PYTEST_ADDOPTS", raising=False) + # Ensure no user config is used. + tmphome = str(self.path) + mp.setenv("HOME", tmphome) + mp.setenv("USERPROFILE", tmphome) + # Do not use colors for inner runs by default. + mp.setenv("PY_COLORS", "0") + + @property + def path(self) -> Path: + """Temporary directory path used to create files/run tests from, etc.""" + return self._path + + def __repr__(self) -> str: + return f"<Pytester {self.path!r}>" + + def _finalize(self) -> None: + """ + Clean up global state artifacts. + + Some methods modify the global interpreter state and this tries to + clean this up. It does not remove the temporary directory however so + it can be looked at after the test run has finished. + """ + self._sys_modules_snapshot.restore() + self._sys_path_snapshot.restore() + + def __take_sys_modules_snapshot(self) -> SysModulesSnapshot: + # Some zope modules used by twisted-related tests keep internal state + # and can't be deleted; we had some trouble in the past with + # `zope.interface` for example. + # + # Preserve readline due to https://bugs.python.org/issue41033. + # pexpect issues a SIGWINCH. + def preserve_module(name): + return name.startswith(("zope", "readline")) + + return SysModulesSnapshot(preserve=preserve_module) + + def make_hook_recorder(self, pluginmanager: PytestPluginManager) -> HookRecorder: + """Create a new :class:`HookRecorder` for a :class:`PytestPluginManager`.""" + pluginmanager.reprec = reprec = HookRecorder(pluginmanager, _ispytest=True) # type: ignore[attr-defined] + self._request.addfinalizer(reprec.finish_recording) + return reprec + + def chdir(self) -> None: + """Cd into the temporary directory. + + This is done automatically upon instantiation. + """ + self._monkeypatch.chdir(self.path) + + def _makefile( + self, + ext: str, + lines: Sequence[Any | bytes], + files: dict[str, str], + encoding: str = "utf-8", + ) -> Path: + items = list(files.items()) + + if ext is None: + raise TypeError("ext must not be None") + + if ext and not ext.startswith("."): + raise ValueError( + f"pytester.makefile expects a file extension, try .{ext} instead of {ext}" + ) + + def to_text(s: Any | bytes) -> str: + return s.decode(encoding) if isinstance(s, bytes) else str(s) + + if lines: + source = "\n".join(to_text(x) for x in lines) + basename = self._name + items.insert(0, (basename, source)) + + ret = None + for basename, value in items: + p = self.path.joinpath(basename).with_suffix(ext) + p.parent.mkdir(parents=True, exist_ok=True) + source_ = Source(value) + source = "\n".join(to_text(line) for line in source_.lines) + p.write_text(source.strip(), encoding=encoding) + if ret is None: + ret = p + assert ret is not None + return ret + + def makefile(self, ext: str, *args: str, **kwargs: str) -> Path: + r"""Create new text file(s) in the test directory. + + :param ext: + The extension the file(s) should use, including the dot, e.g. `.py`. + :param args: + All args are treated as strings and joined using newlines. + The result is written as contents to the file. The name of the + file is based on the test function requesting this fixture. + :param kwargs: + Each keyword is the name of a file, while the value of it will + be written as contents of the file. + :returns: + The first created file. + + Examples: + + .. code-block:: python + + pytester.makefile(".txt", "line1", "line2") + + pytester.makefile(".ini", pytest="[pytest]\naddopts=-rs\n") + + To create binary files, use :meth:`pathlib.Path.write_bytes` directly: + + .. code-block:: python + + filename = pytester.path.joinpath("foo.bin") + filename.write_bytes(b"...") + """ + return self._makefile(ext, args, kwargs) + + def makeconftest(self, source: str) -> Path: + """Write a conftest.py file. + + :param source: The contents. + :returns: The conftest.py file. + """ + return self.makepyfile(conftest=source) + + def makeini(self, source: str) -> Path: + """Write a tox.ini file. + + :param source: The contents. + :returns: The tox.ini file. + """ + return self.makefile(".ini", tox=source) + + def maketoml(self, source: str) -> Path: + """Write a pytest.toml file. + + :param source: The contents. + :returns: The pytest.toml file. + + .. versionadded:: 9.0 + """ + return self.makefile(".toml", pytest=source) + + def getinicfg(self, source: str) -> SectionWrapper: + """Return the pytest section from the tox.ini config file.""" + p = self.makeini(source) + return IniConfig(str(p))["pytest"] + + def makepyprojecttoml(self, source: str) -> Path: + """Write a pyproject.toml file. + + :param source: The contents. + :returns: The pyproject.ini file. + + .. versionadded:: 6.0 + """ + return self.makefile(".toml", pyproject=source) + + def makepyfile(self, *args, **kwargs) -> Path: + r"""Shortcut for .makefile() with a .py extension. + + Defaults to the test name with a '.py' extension, e.g test_foobar.py, overwriting + existing files. + + Examples: + + .. code-block:: python + + def test_something(pytester): + # Initial file is created test_something.py. + pytester.makepyfile("foobar") + # To create multiple files, pass kwargs accordingly. + pytester.makepyfile(custom="foobar") + # At this point, both 'test_something.py' & 'custom.py' exist in the test directory. + + """ + return self._makefile(".py", args, kwargs) + + def maketxtfile(self, *args, **kwargs) -> Path: + r"""Shortcut for .makefile() with a .txt extension. + + Defaults to the test name with a '.txt' extension, e.g test_foobar.txt, overwriting + existing files. + + Examples: + + .. code-block:: python + + def test_something(pytester): + # Initial file is created test_something.txt. + pytester.maketxtfile("foobar") + # To create multiple files, pass kwargs accordingly. + pytester.maketxtfile(custom="foobar") + # At this point, both 'test_something.txt' & 'custom.txt' exist in the test directory. + + """ + return self._makefile(".txt", args, kwargs) + + def syspathinsert(self, path: str | os.PathLike[str] | None = None) -> None: + """Prepend a directory to sys.path, defaults to :attr:`path`. + + This is undone automatically when this object dies at the end of each + test. + + :param path: + The path. + """ + if path is None: + path = self.path + + self._monkeypatch.syspath_prepend(str(path)) + + def mkdir(self, name: str | os.PathLike[str]) -> Path: + """Create a new (sub)directory. + + :param name: + The name of the directory, relative to the pytester path. + :returns: + The created directory. + :rtype: pathlib.Path + """ + p = self.path / name + p.mkdir() + return p + + def mkpydir(self, name: str | os.PathLike[str]) -> Path: + """Create a new python package. + + This creates a (sub)directory with an empty ``__init__.py`` file so it + gets recognised as a Python package. + """ + p = self.path / name + p.mkdir() + p.joinpath("__init__.py").touch() + return p + + def copy_example(self, name: str | None = None) -> Path: + """Copy file from project's directory into the testdir. + + :param name: + The name of the file to copy. + :return: + Path to the copied directory (inside ``self.path``). + :rtype: pathlib.Path + """ + example_dir_ = self._request.config.getini("pytester_example_dir") + if example_dir_ is None: + raise ValueError("pytester_example_dir is unset, can't copy examples") + example_dir: Path = self._request.config.rootpath / example_dir_ + + for extra_element in self._request.node.iter_markers("pytester_example_path"): + assert extra_element.args + example_dir = example_dir.joinpath(*extra_element.args) + + if name is None: + func_name = self._name + maybe_dir = example_dir / func_name + maybe_file = example_dir / (func_name + ".py") + + if maybe_dir.is_dir(): + example_path = maybe_dir + elif maybe_file.is_file(): + example_path = maybe_file + else: + raise LookupError( + f"{func_name} can't be found as module or package in {example_dir}" + ) + else: + example_path = example_dir.joinpath(name) + + if example_path.is_dir() and not example_path.joinpath("__init__.py").is_file(): + shutil.copytree(example_path, self.path, symlinks=True, dirs_exist_ok=True) + return self.path + elif example_path.is_file(): + result = self.path.joinpath(example_path.name) + shutil.copy(example_path, result) + return result + else: + raise LookupError( + f'example "{example_path}" is not found as a file or directory' + ) + + def getnode(self, config: Config, arg: str | os.PathLike[str]) -> Collector | Item: + """Get the collection node of a file. + + :param config: + A pytest config. + See :py:meth:`parseconfig` and :py:meth:`parseconfigure` for creating it. + :param arg: + Path to the file. + :returns: + The node. + """ + session = Session.from_config(config) + assert "::" not in str(arg) + p = Path(os.path.abspath(arg)) + config.hook.pytest_sessionstart(session=session) + res = session.perform_collect([str(p)], genitems=False)[0] + config.hook.pytest_sessionfinish(session=session, exitstatus=ExitCode.OK) + return res + + def getpathnode(self, path: str | os.PathLike[str]) -> Collector | Item: + """Return the collection node of a file. + + This is like :py:meth:`getnode` but uses :py:meth:`parseconfigure` to + create the (configured) pytest Config instance. + + :param path: + Path to the file. + :returns: + The node. + """ + path = Path(path) + config = self.parseconfigure(path) + session = Session.from_config(config) + x = bestrelpath(session.path, path) + config.hook.pytest_sessionstart(session=session) + res = session.perform_collect([x], genitems=False)[0] + config.hook.pytest_sessionfinish(session=session, exitstatus=ExitCode.OK) + return res + + def genitems(self, colitems: Sequence[Item | Collector]) -> list[Item]: + """Generate all test items from a collection node. + + This recurses into the collection node and returns a list of all the + test items contained within. + + :param colitems: + The collection nodes. + :returns: + The collected items. + """ + session = colitems[0].session + result: list[Item] = [] + for colitem in colitems: + result.extend(session.genitems(colitem)) + return result + + def runitem(self, source: str) -> Any: + """Run the "test_func" Item. + + The calling test instance (class containing the test method) must + provide a ``.getrunner()`` method which should return a runner which + can run the test protocol for a single item, e.g. + ``_pytest.runner.runtestprotocol``. + """ + # used from runner functional tests + item = self.getitem(source) + # the test class where we are called from wants to provide the runner + testclassinstance = self._request.instance + runner = testclassinstance.getrunner() + return runner(item) + + def inline_runsource(self, source: str, *cmdlineargs) -> HookRecorder: + """Run a test module in process using ``pytest.main()``. + + This run writes "source" into a temporary file and runs + ``pytest.main()`` on it, returning a :py:class:`HookRecorder` instance + for the result. + + :param source: The source code of the test module. + :param cmdlineargs: Any extra command line arguments to use. + """ + p = self.makepyfile(source) + values = [*list(cmdlineargs), p] + return self.inline_run(*values) + + def inline_genitems(self, *args) -> tuple[list[Item], HookRecorder]: + """Run ``pytest.main(['--collect-only'])`` in-process. + + Runs the :py:func:`pytest.main` function to run all of pytest inside + the test process itself like :py:meth:`inline_run`, but returns a + tuple of the collected items and a :py:class:`HookRecorder` instance. + """ + rec = self.inline_run("--collect-only", *args) + items = [x.item for x in rec.getcalls("pytest_itemcollected")] + return items, rec + + def inline_run( + self, + *args: str | os.PathLike[str], + plugins=(), + no_reraise_ctrlc: bool = False, + ) -> HookRecorder: + """Run ``pytest.main()`` in-process, returning a HookRecorder. + + Runs the :py:func:`pytest.main` function to run all of pytest inside + the test process itself. This means it can return a + :py:class:`HookRecorder` instance which gives more detailed results + from that run than can be done by matching stdout/stderr from + :py:meth:`runpytest`. + + :param args: + Command line arguments to pass to :py:func:`pytest.main`. + :param plugins: + Extra plugin instances the ``pytest.main()`` instance should use. + :param no_reraise_ctrlc: + Typically we reraise keyboard interrupts from the child run. If + True, the KeyboardInterrupt exception is captured. + """ + from _pytest.unraisableexception import gc_collect_iterations_key + + # (maybe a cpython bug?) the importlib cache sometimes isn't updated + # properly between file creation and inline_run (especially if imports + # are interspersed with file creation) + importlib.invalidate_caches() + + plugins = list(plugins) + finalizers = [] + try: + # Any sys.module or sys.path changes done while running pytest + # inline should be reverted after the test run completes to avoid + # clashing with later inline tests run within the same pytest test, + # e.g. just because they use matching test module names. + finalizers.append(self.__take_sys_modules_snapshot().restore) + finalizers.append(SysPathsSnapshot().restore) + + # Important note: + # - our tests should not leave any other references/registrations + # laying around other than possibly loaded test modules + # referenced from sys.modules, as nothing will clean those up + # automatically + + rec = [] + + class PytesterHelperPlugin: + @staticmethod + def pytest_configure(config: Config) -> None: + rec.append(self.make_hook_recorder(config.pluginmanager)) + + # The unraisable plugin GC collect slows down inline + # pytester runs too much. + config.stash[gc_collect_iterations_key] = 0 + + plugins.append(PytesterHelperPlugin()) + ret = main([str(x) for x in args], plugins=plugins) + if len(rec) == 1: + reprec = rec.pop() + else: + + class reprec: # type: ignore + pass + + reprec.ret = ret + + # Typically we reraise keyboard interrupts from the child run + # because it's our user requesting interruption of the testing. + if ret == ExitCode.INTERRUPTED and not no_reraise_ctrlc: + calls = reprec.getcalls("pytest_keyboard_interrupt") + if calls and calls[-1].excinfo.type == KeyboardInterrupt: + raise KeyboardInterrupt() + return reprec + finally: + for finalizer in finalizers: + finalizer() + + def runpytest_inprocess( + self, *args: str | os.PathLike[str], **kwargs: Any + ) -> RunResult: + """Return result of running pytest in-process, providing a similar + interface to what self.runpytest() provides.""" + syspathinsert = kwargs.pop("syspathinsert", False) + + if syspathinsert: + self.syspathinsert() + instant = timing.Instant() + capture = _get_multicapture("sys") + capture.start_capturing() + try: + try: + reprec = self.inline_run(*args, **kwargs) + except SystemExit as e: + ret = e.args[0] + try: + ret = ExitCode(e.args[0]) + except ValueError: + pass + + class reprec: # type: ignore + ret = ret + + except Exception: + traceback.print_exc() + + class reprec: # type: ignore + ret = ExitCode(3) + + finally: + out, err = capture.readouterr() + capture.stop_capturing() + sys.stdout.write(out) + sys.stderr.write(err) + + assert reprec.ret is not None + res = RunResult( + reprec.ret, out.splitlines(), err.splitlines(), instant.elapsed().seconds + ) + res.reprec = reprec # type: ignore + return res + + def runpytest(self, *args: str | os.PathLike[str], **kwargs: Any) -> RunResult: + """Run pytest inline or in a subprocess, depending on the command line + option "--runpytest" and return a :py:class:`~pytest.RunResult`.""" + new_args = self._ensure_basetemp(args) + if self._method == "inprocess": + return self.runpytest_inprocess(*new_args, **kwargs) + elif self._method == "subprocess": + return self.runpytest_subprocess(*new_args, **kwargs) + raise RuntimeError(f"Unrecognized runpytest option: {self._method}") + + def _ensure_basetemp( + self, args: Sequence[str | os.PathLike[str]] + ) -> list[str | os.PathLike[str]]: + new_args = list(args) + for x in new_args: + if str(x).startswith("--basetemp"): + break + else: + new_args.append( + "--basetemp={}".format(self.path.parent.joinpath("basetemp")) + ) + return new_args + + def parseconfig(self, *args: str | os.PathLike[str]) -> Config: + """Return a new pytest :class:`pytest.Config` instance from given + commandline args. + + This invokes the pytest bootstrapping code in _pytest.config to create a + new :py:class:`pytest.PytestPluginManager` and call the + :hook:`pytest_cmdline_parse` hook to create a new :class:`pytest.Config` + instance. + + If :attr:`plugins` has been populated they should be plugin modules + to be registered with the plugin manager. + """ + import _pytest.config + + new_args = [str(x) for x in self._ensure_basetemp(args)] + + config = _pytest.config._prepareconfig(new_args, self.plugins) + # we don't know what the test will do with this half-setup config + # object and thus we make sure it gets unconfigured properly in any + # case (otherwise capturing could still be active, for example) + self._request.addfinalizer(config._ensure_unconfigure) + return config + + def parseconfigure(self, *args: str | os.PathLike[str]) -> Config: + """Return a new pytest configured Config instance. + + Returns a new :py:class:`pytest.Config` instance like + :py:meth:`parseconfig`, but also calls the :hook:`pytest_configure` + hook. + """ + config = self.parseconfig(*args) + config._do_configure() + return config + + def getitem( + self, source: str | os.PathLike[str], funcname: str = "test_func" + ) -> Item: + """Return the test item for a test function. + + Writes the source to a python file and runs pytest's collection on + the resulting module, returning the test item for the requested + function name. + + :param source: + The module source. + :param funcname: + The name of the test function for which to return a test item. + :returns: + The test item. + """ + items = self.getitems(source) + for item in items: + if item.name == funcname: + return item + assert 0, f"{funcname!r} item not found in module:\n{source}\nitems: {items}" + + def getitems(self, source: str | os.PathLike[str]) -> list[Item]: + """Return all test items collected from the module. + + Writes the source to a Python file and runs pytest's collection on + the resulting module, returning all test items contained within. + """ + modcol = self.getmodulecol(source) + return self.genitems([modcol]) + + def getmodulecol( + self, + source: str | os.PathLike[str], + configargs=(), + *, + withinit: bool = False, + ): + """Return the module collection node for ``source``. + + Writes ``source`` to a file using :py:meth:`makepyfile` and then + runs the pytest collection on it, returning the collection node for the + test module. + + :param source: + The source code of the module to collect. + + :param configargs: + Any extra arguments to pass to :py:meth:`parseconfigure`. + + :param withinit: + Whether to also write an ``__init__.py`` file to the same + directory to ensure it is a package. + """ + if isinstance(source, os.PathLike): + path = self.path.joinpath(source) + assert not withinit, "not supported for paths" + else: + kw = {self._name: str(source)} + path = self.makepyfile(**kw) + if withinit: + self.makepyfile(__init__="#") + self.config = config = self.parseconfigure(path, *configargs) + return self.getnode(config, path) + + def collect_by_name(self, modcol: Collector, name: str) -> Item | Collector | None: + """Return the collection node for name from the module collection. + + Searches a module collection node for a collection node matching the + given name. + + :param modcol: A module collection node; see :py:meth:`getmodulecol`. + :param name: The name of the node to return. + """ + if modcol not in self._mod_collections: + self._mod_collections[modcol] = list(modcol.collect()) + for colitem in self._mod_collections[modcol]: + if colitem.name == name: + return colitem + return None + + def popen( + self, + cmdargs: Sequence[str | os.PathLike[str]], + stdout: int | TextIO = subprocess.PIPE, + stderr: int | TextIO = subprocess.PIPE, + stdin: NotSetType | bytes | IO[Any] | int = CLOSE_STDIN, + **kw, + ): + """Invoke :py:class:`subprocess.Popen`. + + Calls :py:class:`subprocess.Popen` making sure the current working + directory is in ``PYTHONPATH``. + + You probably want to use :py:meth:`run` instead. + """ + env = os.environ.copy() + env["PYTHONPATH"] = os.pathsep.join( + filter(None, [os.getcwd(), env.get("PYTHONPATH", "")]) + ) + kw["env"] = env + + if stdin is self.CLOSE_STDIN: + kw["stdin"] = subprocess.PIPE + elif isinstance(stdin, bytes): + kw["stdin"] = subprocess.PIPE + else: + kw["stdin"] = stdin + + popen = subprocess.Popen(cmdargs, stdout=stdout, stderr=stderr, **kw) + if stdin is self.CLOSE_STDIN: + assert popen.stdin is not None + popen.stdin.close() + elif isinstance(stdin, bytes): + assert popen.stdin is not None + popen.stdin.write(stdin) + + return popen + + def run( + self, + *cmdargs: str | os.PathLike[str], + timeout: float | None = None, + stdin: NotSetType | bytes | IO[Any] | int = CLOSE_STDIN, + ) -> RunResult: + """Run a command with arguments. + + Run a process using :py:class:`subprocess.Popen` saving the stdout and + stderr. + + :param cmdargs: + The sequence of arguments to pass to :py:class:`subprocess.Popen`, + with path-like objects being converted to :py:class:`str` + automatically. + :param timeout: + The period in seconds after which to timeout and raise + :py:class:`Pytester.TimeoutExpired`. + :param stdin: + Optional standard input. + + - If it is ``CLOSE_STDIN`` (Default), then this method calls + :py:class:`subprocess.Popen` with ``stdin=subprocess.PIPE``, and + the standard input is closed immediately after the new command is + started. + + - If it is of type :py:class:`bytes`, these bytes are sent to the + standard input of the command. + + - Otherwise, it is passed through to :py:class:`subprocess.Popen`. + For further information in this case, consult the document of the + ``stdin`` parameter in :py:class:`subprocess.Popen`. + :type stdin: _pytest.compat.NotSetType | bytes | IO[Any] | int + :returns: + The result. + + """ + __tracebackhide__ = True + + cmdargs = tuple(os.fspath(arg) for arg in cmdargs) + p1 = self.path.joinpath("stdout") + p2 = self.path.joinpath("stderr") + print("running:", *cmdargs) + print(" in:", Path.cwd()) + + with p1.open("w", encoding="utf8") as f1, p2.open("w", encoding="utf8") as f2: + instant = timing.Instant() + popen = self.popen( + cmdargs, + stdin=stdin, + stdout=f1, + stderr=f2, + ) + if popen.stdin is not None: + popen.stdin.close() + + def handle_timeout() -> None: + __tracebackhide__ = True + + timeout_message = f"{timeout} second timeout expired running: {cmdargs}" + + popen.kill() + popen.wait() + raise self.TimeoutExpired(timeout_message) + + if timeout is None: + ret = popen.wait() + else: + try: + ret = popen.wait(timeout) + except subprocess.TimeoutExpired: + handle_timeout() + f1.flush() + f2.flush() + + with p1.open(encoding="utf8") as f1, p2.open(encoding="utf8") as f2: + out = f1.read().splitlines() + err = f2.read().splitlines() + + self._dump_lines(out, sys.stdout) + self._dump_lines(err, sys.stderr) + + with contextlib.suppress(ValueError): + ret = ExitCode(ret) + return RunResult(ret, out, err, instant.elapsed().seconds) + + def _dump_lines(self, lines, fp): + try: + for line in lines: + print(line, file=fp) + except UnicodeEncodeError: + print(f"couldn't print to {fp} because of encoding") + + def _getpytestargs(self) -> tuple[str, ...]: + return sys.executable, "-mpytest" + + def runpython(self, script: os.PathLike[str]) -> RunResult: + """Run a python script using sys.executable as interpreter.""" + return self.run(sys.executable, script) + + def runpython_c(self, command: str) -> RunResult: + """Run ``python -c "command"``.""" + return self.run(sys.executable, "-c", command) + + def runpytest_subprocess( + self, *args: str | os.PathLike[str], timeout: float | None = None + ) -> RunResult: + """Run pytest as a subprocess with given arguments. + + Any plugins added to the :py:attr:`plugins` list will be added using the + ``-p`` command line option. Additionally ``--basetemp`` is used to put + any temporary files and directories in a numbered directory prefixed + with "runpytest-" to not conflict with the normal numbered pytest + location for temporary files and directories. + + :param args: + The sequence of arguments to pass to the pytest subprocess. + :param timeout: + The period in seconds after which to timeout and raise + :py:class:`Pytester.TimeoutExpired`. + :returns: + The result. + """ + __tracebackhide__ = True + p = make_numbered_dir(root=self.path, prefix="runpytest-", mode=0o700) + args = (f"--basetemp={p}", *args) + for plugin in self.plugins: + if not isinstance(plugin, str): + raise ValueError( + f"Specifying plugins as objects is not supported in pytester subprocess mode; " + f"specify by name instead: {plugin}" + ) + args = ("-p", plugin, *args) + args = self._getpytestargs() + args + return self.run(*args, timeout=timeout) + + def spawn_pytest(self, string: str, expect_timeout: float = 10.0) -> pexpect.spawn: + """Run pytest using pexpect. + + This makes sure to use the right pytest and sets up the temporary + directory locations. + + The pexpect child is returned. + """ + basetemp = self.path / "temp-pexpect" + basetemp.mkdir(mode=0o700) + invoke = " ".join(map(str, self._getpytestargs())) + cmd = f"{invoke} --basetemp={basetemp} {string}" + return self.spawn(cmd, expect_timeout=expect_timeout) + + def spawn(self, cmd: str, expect_timeout: float = 10.0) -> pexpect.spawn: + """Run a command using pexpect. + + The pexpect child is returned. + """ + pexpect = importorskip("pexpect", "3.0") + if hasattr(sys, "pypy_version_info") and "64" in platform.machine(): + skip("pypy-64 bit not supported") + if not hasattr(pexpect, "spawn"): + skip("pexpect.spawn not available") + logfile = self.path.joinpath("spawn.out").open("wb") + + child = pexpect.spawn(cmd, logfile=logfile, timeout=expect_timeout) + self._request.addfinalizer(logfile.close) + return child + + +class LineComp: + def __init__(self) -> None: + self.stringio = StringIO() + """:class:`python:io.StringIO()` instance used for input.""" + + def assert_contains_lines(self, lines2: Sequence[str]) -> None: + """Assert that ``lines2`` are contained (linearly) in :attr:`stringio`'s value. + + Lines are matched using :func:`LineMatcher.fnmatch_lines <pytest.LineMatcher.fnmatch_lines>`. + """ + __tracebackhide__ = True + val = self.stringio.getvalue() + self.stringio.truncate(0) + self.stringio.seek(0) + lines1 = val.split("\n") + LineMatcher(lines1).fnmatch_lines(lines2) + + +class LineMatcher: + """Flexible matching of text. + + This is a convenience class to test large texts like the output of + commands. + + The constructor takes a list of lines without their trailing newlines, i.e. + ``text.splitlines()``. + """ + + def __init__(self, lines: list[str]) -> None: + self.lines = lines + self._log_output: list[str] = [] + + def __str__(self) -> str: + """Return the entire original text. + + .. versionadded:: 6.2 + You can use :meth:`str` in older versions. + """ + return "\n".join(self.lines) + + def _getlines(self, lines2: str | Sequence[str] | Source) -> Sequence[str]: + if isinstance(lines2, str): + lines2 = Source(lines2) + if isinstance(lines2, Source): + lines2 = lines2.strip().lines + return lines2 + + def fnmatch_lines_random(self, lines2: Sequence[str]) -> None: + """Check lines exist in the output in any order (using :func:`python:fnmatch.fnmatch`).""" + __tracebackhide__ = True + self._match_lines_random(lines2, fnmatch) + + def re_match_lines_random(self, lines2: Sequence[str]) -> None: + """Check lines exist in the output in any order (using :func:`python:re.match`).""" + __tracebackhide__ = True + self._match_lines_random(lines2, lambda name, pat: bool(re.match(pat, name))) + + def _match_lines_random( + self, lines2: Sequence[str], match_func: Callable[[str, str], bool] + ) -> None: + __tracebackhide__ = True + lines2 = self._getlines(lines2) + for line in lines2: + for x in self.lines: + if line == x or match_func(x, line): + self._log("matched: ", repr(line)) + break + else: + msg = f"line {line!r} not found in output" + self._log(msg) + self._fail(msg) + + def get_lines_after(self, fnline: str) -> Sequence[str]: + """Return all lines following the given line in the text. + + The given line can contain glob wildcards. + """ + for i, line in enumerate(self.lines): + if fnline == line or fnmatch(line, fnline): + return self.lines[i + 1 :] + raise ValueError(f"line {fnline!r} not found in output") + + def _log(self, *args) -> None: + self._log_output.append(" ".join(str(x) for x in args)) + + @property + def _log_text(self) -> str: + return "\n".join(self._log_output) + + def fnmatch_lines( + self, lines2: Sequence[str], *, consecutive: bool = False + ) -> None: + """Check lines exist in the output (using :func:`python:fnmatch.fnmatch`). + + The argument is a list of lines which have to match and can use glob + wildcards. If they do not match a pytest.fail() is called. The + matches and non-matches are also shown as part of the error message. + + :param lines2: String patterns to match. + :param consecutive: Match lines consecutively? + """ + __tracebackhide__ = True + self._match_lines(lines2, fnmatch, "fnmatch", consecutive=consecutive) + + def re_match_lines( + self, lines2: Sequence[str], *, consecutive: bool = False + ) -> None: + """Check lines exist in the output (using :func:`python:re.match`). + + The argument is a list of lines which have to match using ``re.match``. + If they do not match a pytest.fail() is called. + + The matches and non-matches are also shown as part of the error message. + + :param lines2: string patterns to match. + :param consecutive: match lines consecutively? + """ + __tracebackhide__ = True + self._match_lines( + lines2, + lambda name, pat: bool(re.match(pat, name)), + "re.match", + consecutive=consecutive, + ) + + def _match_lines( + self, + lines2: Sequence[str], + match_func: Callable[[str, str], bool], + match_nickname: str, + *, + consecutive: bool = False, + ) -> None: + """Underlying implementation of ``fnmatch_lines`` and ``re_match_lines``. + + :param Sequence[str] lines2: + List of string patterns to match. The actual format depends on + ``match_func``. + :param match_func: + A callable ``match_func(line, pattern)`` where line is the + captured line from stdout/stderr and pattern is the matching + pattern. + :param str match_nickname: + The nickname for the match function that will be logged to stdout + when a match occurs. + :param consecutive: + Match lines consecutively? + """ + if not isinstance(lines2, collections.abc.Sequence): + raise TypeError(f"invalid type for lines2: {type(lines2).__name__}") + lines2 = self._getlines(lines2) + lines1 = self.lines[:] + extralines = [] + __tracebackhide__ = True + wnick = len(match_nickname) + 1 + started = False + for line in lines2: + nomatchprinted = False + while lines1: + nextline = lines1.pop(0) + if line == nextline: + self._log("exact match:", repr(line)) + started = True + break + elif match_func(nextline, line): + self._log(f"{match_nickname}:", repr(line)) + self._log( + "{:>{width}}".format("with:", width=wnick), repr(nextline) + ) + started = True + break + else: + if consecutive and started: + msg = f"no consecutive match: {line!r}" + self._log(msg) + self._log( + "{:>{width}}".format("with:", width=wnick), repr(nextline) + ) + self._fail(msg) + if not nomatchprinted: + self._log( + "{:>{width}}".format("nomatch:", width=wnick), repr(line) + ) + nomatchprinted = True + self._log("{:>{width}}".format("and:", width=wnick), repr(nextline)) + extralines.append(nextline) + else: + msg = f"remains unmatched: {line!r}" + self._log(msg) + self._fail(msg) + self._log_output = [] + + def no_fnmatch_line(self, pat: str) -> None: + """Ensure captured lines do not match the given pattern, using ``fnmatch.fnmatch``. + + :param str pat: The pattern to match lines. + """ + __tracebackhide__ = True + self._no_match_line(pat, fnmatch, "fnmatch") + + def no_re_match_line(self, pat: str) -> None: + """Ensure captured lines do not match the given pattern, using ``re.match``. + + :param str pat: The regular expression to match lines. + """ + __tracebackhide__ = True + self._no_match_line( + pat, lambda name, pat: bool(re.match(pat, name)), "re.match" + ) + + def _no_match_line( + self, pat: str, match_func: Callable[[str, str], bool], match_nickname: str + ) -> None: + """Ensure captured lines does not have a the given pattern, using ``fnmatch.fnmatch``. + + :param str pat: The pattern to match lines. + """ + __tracebackhide__ = True + nomatch_printed = False + wnick = len(match_nickname) + 1 + for line in self.lines: + if match_func(line, pat): + msg = f"{match_nickname}: {pat!r}" + self._log(msg) + self._log("{:>{width}}".format("with:", width=wnick), repr(line)) + self._fail(msg) + else: + if not nomatch_printed: + self._log("{:>{width}}".format("nomatch:", width=wnick), repr(pat)) + nomatch_printed = True + self._log("{:>{width}}".format("and:", width=wnick), repr(line)) + self._log_output = [] + + def _fail(self, msg: str) -> None: + __tracebackhide__ = True + log_text = self._log_text + self._log_output = [] + fail(log_text) + + def str(self) -> str: + """Return the entire original text.""" + return str(self) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/pytester_assertions.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/pytester_assertions.py new file mode 100644 index 0000000000000000000000000000000000000000..915cc8a10ff4781da48a44d88bf591788b8ab673 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/pytester_assertions.py @@ -0,0 +1,74 @@ +"""Helper plugin for pytester; should not be loaded on its own.""" + +# This plugin contains assertions used by pytester. pytester cannot +# contain them itself, since it is imported by the `pytest` module, +# hence cannot be subject to assertion rewriting, which requires a +# module to not be already imported. +from __future__ import annotations + +from collections.abc import Sequence + +from _pytest.reports import CollectReport +from _pytest.reports import TestReport + + +def assertoutcome( + outcomes: tuple[ + Sequence[TestReport], + Sequence[CollectReport | TestReport], + Sequence[CollectReport | TestReport], + ], + passed: int = 0, + skipped: int = 0, + failed: int = 0, +) -> None: + __tracebackhide__ = True + + realpassed, realskipped, realfailed = outcomes + obtained = { + "passed": len(realpassed), + "skipped": len(realskipped), + "failed": len(realfailed), + } + expected = {"passed": passed, "skipped": skipped, "failed": failed} + assert obtained == expected, outcomes + + +def assert_outcomes( + outcomes: dict[str, int], + passed: int = 0, + skipped: int = 0, + failed: int = 0, + errors: int = 0, + xpassed: int = 0, + xfailed: int = 0, + warnings: int | None = None, + deselected: int | None = None, +) -> None: + """Assert that the specified outcomes appear with the respective + numbers (0 means it didn't occur) in the text output from a test run.""" + __tracebackhide__ = True + + obtained = { + "passed": outcomes.get("passed", 0), + "skipped": outcomes.get("skipped", 0), + "failed": outcomes.get("failed", 0), + "errors": outcomes.get("errors", 0), + "xpassed": outcomes.get("xpassed", 0), + "xfailed": outcomes.get("xfailed", 0), + } + expected = { + "passed": passed, + "skipped": skipped, + "failed": failed, + "errors": errors, + "xpassed": xpassed, + "xfailed": xfailed, + } + if warnings is not None: + obtained["warnings"] = outcomes.get("warnings", 0) + expected["warnings"] = warnings + if deselected is not None: + obtained["deselected"] = outcomes.get("deselected", 0) + expected["deselected"] = deselected + assert obtained == expected diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/python.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/python.py new file mode 100644 index 0000000000000000000000000000000000000000..e63751877a40b8e5768236ff4c3bc2fb09699482 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/python.py @@ -0,0 +1,1772 @@ +# mypy: allow-untyped-defs +"""Python test discovery, setup and run of test functions.""" + +from __future__ import annotations + +import abc +from collections import Counter +from collections import defaultdict +from collections.abc import Callable +from collections.abc import Generator +from collections.abc import Iterable +from collections.abc import Iterator +from collections.abc import Mapping +from collections.abc import Sequence +import dataclasses +import enum +import fnmatch +from functools import partial +import inspect +import itertools +import os +from pathlib import Path +import re +import textwrap +import types +from typing import Any +from typing import cast +from typing import final +from typing import Literal +from typing import NoReturn +from typing import TYPE_CHECKING +import warnings + +import _pytest +from _pytest import fixtures +from _pytest import nodes +from _pytest._code import filter_traceback +from _pytest._code import getfslineno +from _pytest._code.code import ExceptionInfo +from _pytest._code.code import TerminalRepr +from _pytest._code.code import Traceback +from _pytest._io.saferepr import saferepr +from _pytest.compat import ascii_escaped +from _pytest.compat import get_default_arg_names +from _pytest.compat import get_real_func +from _pytest.compat import getimfunc +from _pytest.compat import is_async_function +from _pytest.compat import LEGACY_PATH +from _pytest.compat import NOTSET +from _pytest.compat import safe_getattr +from _pytest.compat import safe_isclass +from _pytest.config import Config +from _pytest.config import hookimpl +from _pytest.config.argparsing import Parser +from _pytest.deprecated import check_ispytest +from _pytest.fixtures import FixtureDef +from _pytest.fixtures import FixtureRequest +from _pytest.fixtures import FuncFixtureInfo +from _pytest.fixtures import get_scope_node +from _pytest.main import Session +from _pytest.mark import ParameterSet +from _pytest.mark.structures import _HiddenParam +from _pytest.mark.structures import get_unpacked_marks +from _pytest.mark.structures import HIDDEN_PARAM +from _pytest.mark.structures import Mark +from _pytest.mark.structures import MarkDecorator +from _pytest.mark.structures import normalize_mark_list +from _pytest.outcomes import fail +from _pytest.outcomes import skip +from _pytest.pathlib import fnmatch_ex +from _pytest.pathlib import import_path +from _pytest.pathlib import ImportPathMismatchError +from _pytest.pathlib import scandir +from _pytest.scope import _ScopeName +from _pytest.scope import Scope +from _pytest.stash import StashKey +from _pytest.warning_types import PytestCollectionWarning +from _pytest.warning_types import PytestReturnNotNoneWarning + + +if TYPE_CHECKING: + from typing_extensions import Self + + +def pytest_addoption(parser: Parser) -> None: + parser.addini( + "python_files", + type="args", + # NOTE: default is also used in AssertionRewritingHook. + default=["test_*.py", "*_test.py"], + help="Glob-style file patterns for Python test module discovery", + ) + parser.addini( + "python_classes", + type="args", + default=["Test"], + help="Prefixes or glob names for Python test class discovery", + ) + parser.addini( + "python_functions", + type="args", + default=["test"], + help="Prefixes or glob names for Python test function and method discovery", + ) + parser.addini( + "disable_test_id_escaping_and_forfeit_all_rights_to_community_support", + type="bool", + default=False, + help="Disable string escape non-ASCII characters, might cause unwanted " + "side effects(use at your own risk)", + ) + parser.addini( + "strict_parametrization_ids", + type="bool", + # None => fallback to `strict`. + default=None, + help="Emit an error if non-unique parameter set IDs are detected", + ) + + +def pytest_generate_tests(metafunc: Metafunc) -> None: + for marker in metafunc.definition.iter_markers(name="parametrize"): + metafunc.parametrize(*marker.args, **marker.kwargs, _param_mark=marker) + + +def pytest_configure(config: Config) -> None: + config.addinivalue_line( + "markers", + "parametrize(argnames, argvalues): call a test function multiple " + "times passing in different arguments in turn. argvalues generally " + "needs to be a list of values if argnames specifies only one name " + "or a list of tuples of values if argnames specifies multiple names. " + "Example: @parametrize('arg1', [1,2]) would lead to two calls of the " + "decorated test function, one with arg1=1 and another with arg1=2." + "see https://docs.pytest.org/en/stable/how-to/parametrize.html for more info " + "and examples.", + ) + config.addinivalue_line( + "markers", + "usefixtures(fixturename1, fixturename2, ...): mark tests as needing " + "all of the specified fixtures. see " + "https://docs.pytest.org/en/stable/explanation/fixtures.html#usefixtures ", + ) + + +def async_fail(nodeid: str) -> None: + msg = ( + "async def functions are not natively supported.\n" + "You need to install a suitable plugin for your async framework, for example:\n" + " - anyio\n" + " - pytest-asyncio\n" + " - pytest-tornasync\n" + " - pytest-trio\n" + " - pytest-twisted" + ) + fail(msg, pytrace=False) + + +@hookimpl(trylast=True) +def pytest_pyfunc_call(pyfuncitem: Function) -> object | None: + testfunction = pyfuncitem.obj + if is_async_function(testfunction): + async_fail(pyfuncitem.nodeid) + funcargs = pyfuncitem.funcargs + testargs = {arg: funcargs[arg] for arg in pyfuncitem._fixtureinfo.argnames} + result = testfunction(**testargs) + if hasattr(result, "__await__") or hasattr(result, "__aiter__"): + async_fail(pyfuncitem.nodeid) + elif result is not None: + warnings.warn( + PytestReturnNotNoneWarning( + f"Test functions should return None, but {pyfuncitem.nodeid} returned {type(result)!r}.\n" + "Did you mean to use `assert` instead of `return`?\n" + "See https://docs.pytest.org/en/stable/how-to/assert.html#return-not-none for more information." + ) + ) + return True + + +def pytest_collect_directory( + path: Path, parent: nodes.Collector +) -> nodes.Collector | None: + pkginit = path / "__init__.py" + try: + has_pkginit = pkginit.is_file() + except PermissionError: + # See https://github.com/pytest-dev/pytest/issues/12120#issuecomment-2106349096. + return None + if has_pkginit: + return Package.from_parent(parent, path=path) + return None + + +def pytest_collect_file(file_path: Path, parent: nodes.Collector) -> Module | None: + if file_path.suffix == ".py": + if not parent.session.isinitpath(file_path): + if not path_matches_patterns( + file_path, parent.config.getini("python_files") + ): + return None + ihook = parent.session.gethookproxy(file_path) + module: Module = ihook.pytest_pycollect_makemodule( + module_path=file_path, parent=parent + ) + return module + return None + + +def path_matches_patterns(path: Path, patterns: Iterable[str]) -> bool: + """Return whether path matches any of the patterns in the list of globs given.""" + return any(fnmatch_ex(pattern, path) for pattern in patterns) + + +def pytest_pycollect_makemodule(module_path: Path, parent) -> Module: + return Module.from_parent(parent, path=module_path) + + +@hookimpl(trylast=True) +def pytest_pycollect_makeitem( + collector: Module | Class, name: str, obj: object +) -> None | nodes.Item | nodes.Collector | list[nodes.Item | nodes.Collector]: + assert isinstance(collector, Class | Module), type(collector) + # Nothing was collected elsewhere, let's do it here. + if safe_isclass(obj): + if collector.istestclass(obj, name): + return Class.from_parent(collector, name=name, obj=obj) + elif collector.istestfunction(obj, name): + # mock seems to store unbound methods (issue473), normalize it. + obj = getattr(obj, "__func__", obj) + # We need to try and unwrap the function if it's a functools.partial + # or a functools.wrapped. + # We mustn't if it's been wrapped with mock.patch (python 2 only). + if not (inspect.isfunction(obj) or inspect.isfunction(get_real_func(obj))): + filename, lineno = getfslineno(obj) + warnings.warn_explicit( + message=PytestCollectionWarning( + f"cannot collect {name!r} because it is not a function." + ), + category=None, + filename=str(filename), + lineno=lineno + 1, + ) + elif getattr(obj, "__test__", True): + if inspect.isgeneratorfunction(obj): + fail( + f"'yield' keyword is allowed in fixtures, but not in tests ({name})", + pytrace=False, + ) + return list(collector._genfunctions(name, obj)) + return None + return None + + +class PyobjMixin(nodes.Node): + """this mix-in inherits from Node to carry over the typing information + + as its intended to always mix in before a node + its position in the mro is unaffected""" + + _ALLOW_MARKERS = True + + @property + def module(self): + """Python module object this node was collected from (can be None).""" + node = self.getparent(Module) + return node.obj if node is not None else None + + @property + def cls(self): + """Python class object this node was collected from (can be None).""" + node = self.getparent(Class) + return node.obj if node is not None else None + + @property + def instance(self): + """Python instance object the function is bound to. + + Returns None if not a test method, e.g. for a standalone test function, + a class or a module. + """ + # Overridden by Function. + return None + + @property + def obj(self): + """Underlying Python object.""" + obj = getattr(self, "_obj", None) + if obj is None: + self._obj = obj = self._getobj() + # XXX evil hack + # used to avoid Function marker duplication + if self._ALLOW_MARKERS: + self.own_markers.extend(get_unpacked_marks(self.obj)) + # This assumes that `obj` is called before there is a chance + # to add custom keys to `self.keywords`, so no fear of overriding. + self.keywords.update((mark.name, mark) for mark in self.own_markers) + return obj + + @obj.setter + def obj(self, value): + self._obj = value + + def _getobj(self): + """Get the underlying Python object. May be overwritten by subclasses.""" + # TODO: Improve the type of `parent` such that assert/ignore aren't needed. + assert self.parent is not None + obj = self.parent.obj # type: ignore[attr-defined] + return getattr(obj, self.name) + + def getmodpath(self, stopatmodule: bool = True, includemodule: bool = False) -> str: + """Return Python path relative to the containing module.""" + parts = [] + for node in self.iter_parents(): + name = node.name + if isinstance(node, Module): + name = os.path.splitext(name)[0] + if stopatmodule: + if includemodule: + parts.append(name) + break + parts.append(name) + parts.reverse() + return ".".join(parts) + + def reportinfo(self) -> tuple[os.PathLike[str] | str, int | None, str]: + # XXX caching? + path, lineno = getfslineno(self.obj) + modpath = self.getmodpath() + return path, lineno, modpath + + +# As an optimization, these builtin attribute names are pre-ignored when +# iterating over an object during collection -- the pytest_pycollect_makeitem +# hook is not called for them. +# fmt: off +class _EmptyClass: pass # noqa: E701 +IGNORED_ATTRIBUTES = frozenset.union( + frozenset(), + # Module. + dir(types.ModuleType("empty_module")), + # Some extra module attributes the above doesn't catch. + {"__builtins__", "__file__", "__cached__"}, + # Class. + dir(_EmptyClass), + # Instance. + dir(_EmptyClass()), +) +del _EmptyClass +# fmt: on + + +class PyCollector(PyobjMixin, nodes.Collector, abc.ABC): + def funcnamefilter(self, name: str) -> bool: + return self._matches_prefix_or_glob_option("python_functions", name) + + def isnosetest(self, obj: object) -> bool: + """Look for the __test__ attribute, which is applied by the + @nose.tools.istest decorator. + """ + # We explicitly check for "is True" here to not mistakenly treat + # classes with a custom __getattr__ returning something truthy (like a + # function) as test classes. + return safe_getattr(obj, "__test__", False) is True + + def classnamefilter(self, name: str) -> bool: + return self._matches_prefix_or_glob_option("python_classes", name) + + def istestfunction(self, obj: object, name: str) -> bool: + if self.funcnamefilter(name) or self.isnosetest(obj): + if isinstance(obj, staticmethod | classmethod): + # staticmethods and classmethods need to be unwrapped. + obj = safe_getattr(obj, "__func__", False) + return callable(obj) and fixtures.getfixturemarker(obj) is None + else: + return False + + def istestclass(self, obj: object, name: str) -> bool: + if not (self.classnamefilter(name) or self.isnosetest(obj)): + return False + if inspect.isabstract(obj): + return False + return True + + def _matches_prefix_or_glob_option(self, option_name: str, name: str) -> bool: + """Check if the given name matches the prefix or glob-pattern defined + in configuration.""" + for option in self.config.getini(option_name): + if name.startswith(option): + return True + # Check that name looks like a glob-string before calling fnmatch + # because this is called for every name in each collected module, + # and fnmatch is somewhat expensive to call. + elif ("*" in option or "?" in option or "[" in option) and fnmatch.fnmatch( + name, option + ): + return True + return False + + def collect(self) -> Iterable[nodes.Item | nodes.Collector]: + if not getattr(self.obj, "__test__", True): + return [] + + # Avoid random getattrs and peek in the __dict__ instead. + dicts = [getattr(self.obj, "__dict__", {})] + if isinstance(self.obj, type): + for basecls in self.obj.__mro__: + dicts.append(basecls.__dict__) + + # In each class, nodes should be definition ordered. + # __dict__ is definition ordered. + seen: set[str] = set() + dict_values: list[list[nodes.Item | nodes.Collector]] = [] + collect_imported_tests = self.session.config.getini("collect_imported_tests") + ihook = self.ihook + for dic in dicts: + values: list[nodes.Item | nodes.Collector] = [] + # Note: seems like the dict can change during iteration - + # be careful not to remove the list() without consideration. + for name, obj in list(dic.items()): + if name in IGNORED_ATTRIBUTES: + continue + if name in seen: + continue + seen.add(name) + + if not collect_imported_tests and isinstance(self, Module): + # Do not collect functions and classes from other modules. + if inspect.isfunction(obj) or inspect.isclass(obj): + if obj.__module__ != self._getobj().__name__: + continue + + res = ihook.pytest_pycollect_makeitem( + collector=self, name=name, obj=obj + ) + if res is None: + continue + elif isinstance(res, list): + values.extend(res) + else: + values.append(res) + dict_values.append(values) + + # Between classes in the class hierarchy, reverse-MRO order -- nodes + # inherited from base classes should come before subclasses. + result = [] + for values in reversed(dict_values): + result.extend(values) + return result + + def _genfunctions(self, name: str, funcobj) -> Iterator[Function]: + modulecol = self.getparent(Module) + assert modulecol is not None + module = modulecol.obj + clscol = self.getparent(Class) + cls = (clscol and clscol.obj) or None + + definition = FunctionDefinition.from_parent(self, name=name, callobj=funcobj) + fixtureinfo = definition._fixtureinfo + + # pytest_generate_tests impls call metafunc.parametrize() which fills + # metafunc._calls, the outcome of the hook. + metafunc = Metafunc( + definition=definition, + fixtureinfo=fixtureinfo, + config=self.config, + cls=cls, + module=module, + _ispytest=True, + ) + methods = [] + if hasattr(module, "pytest_generate_tests"): + methods.append(module.pytest_generate_tests) + if cls is not None and hasattr(cls, "pytest_generate_tests"): + methods.append(cls().pytest_generate_tests) + self.ihook.pytest_generate_tests.call_extra(methods, dict(metafunc=metafunc)) + + if not metafunc._calls: + yield Function.from_parent(self, name=name, fixtureinfo=fixtureinfo) + else: + metafunc._recompute_direct_params_indices() + # Direct parametrizations taking place in module/class-specific + # `metafunc.parametrize` calls may have shadowed some fixtures, so make sure + # we update what the function really needs a.k.a its fixture closure. Note that + # direct parametrizations using `@pytest.mark.parametrize` have already been considered + # into making the closure using `ignore_args` arg to `getfixtureclosure`. + fixtureinfo.prune_dependency_tree() + + for callspec in metafunc._calls: + subname = f"{name}[{callspec.id}]" if callspec._idlist else name + yield Function.from_parent( + self, + name=subname, + callspec=callspec, + fixtureinfo=fixtureinfo, + keywords={callspec.id: True}, + originalname=name, + ) + + +def importtestmodule( + path: Path, + config: Config, +): + # We assume we are only called once per module. + importmode = config.getoption("--import-mode") + try: + mod = import_path( + path, + mode=importmode, + root=config.rootpath, + consider_namespace_packages=config.getini("consider_namespace_packages"), + ) + except SyntaxError as e: + raise nodes.Collector.CollectError( + ExceptionInfo.from_current().getrepr(style="short") + ) from e + except ImportPathMismatchError as e: + raise nodes.Collector.CollectError( + "import file mismatch:\n" + "imported module {!r} has this __file__ attribute:\n" + " {}\n" + "which is not the same as the test file we want to collect:\n" + " {}\n" + "HINT: remove __pycache__ / .pyc files and/or use a " + "unique basename for your test file modules".format(*e.args) + ) from e + except ImportError as e: + exc_info = ExceptionInfo.from_current() + if config.get_verbosity() < 2: + exc_info.traceback = exc_info.traceback.filter(filter_traceback) + exc_repr = ( + exc_info.getrepr(style="short") + if exc_info.traceback + else exc_info.exconly() + ) + formatted_tb = str(exc_repr) + raise nodes.Collector.CollectError( + f"ImportError while importing test module '{path}'.\n" + "Hint: make sure your test modules/packages have valid Python names.\n" + "Traceback:\n" + f"{formatted_tb}" + ) from e + except skip.Exception as e: + if e.allow_module_level: + raise + raise nodes.Collector.CollectError( + "Using pytest.skip outside of a test will skip the entire module. " + "If that's your intention, pass `allow_module_level=True`. " + "If you want to skip a specific test or an entire class, " + "use the @pytest.mark.skip or @pytest.mark.skipif decorators." + ) from e + config.pluginmanager.consider_module(mod) + return mod + + +class Module(nodes.File, PyCollector): + """Collector for test classes and functions in a Python module.""" + + def _getobj(self): + return importtestmodule(self.path, self.config) + + def collect(self) -> Iterable[nodes.Item | nodes.Collector]: + self._register_setup_module_fixture() + self._register_setup_function_fixture() + self.session._fixturemanager.parsefactories(self) + return super().collect() + + def _register_setup_module_fixture(self) -> None: + """Register an autouse, module-scoped fixture for the collected module object + that invokes setUpModule/tearDownModule if either or both are available. + + Using a fixture to invoke this methods ensures we play nicely and unsurprisingly with + other fixtures (#517). + """ + setup_module = _get_first_non_fixture_func( + self.obj, ("setUpModule", "setup_module") + ) + teardown_module = _get_first_non_fixture_func( + self.obj, ("tearDownModule", "teardown_module") + ) + + if setup_module is None and teardown_module is None: + return + + def xunit_setup_module_fixture(request) -> Generator[None]: + module = request.module + if setup_module is not None: + _call_with_optional_argument(setup_module, module) + yield + if teardown_module is not None: + _call_with_optional_argument(teardown_module, module) + + self.session._fixturemanager._register_fixture( + # Use a unique name to speed up lookup. + name=f"_xunit_setup_module_fixture_{self.obj.__name__}", + func=xunit_setup_module_fixture, + nodeid=self.nodeid, + scope="module", + autouse=True, + ) + + def _register_setup_function_fixture(self) -> None: + """Register an autouse, function-scoped fixture for the collected module object + that invokes setup_function/teardown_function if either or both are available. + + Using a fixture to invoke this methods ensures we play nicely and unsurprisingly with + other fixtures (#517). + """ + setup_function = _get_first_non_fixture_func(self.obj, ("setup_function",)) + teardown_function = _get_first_non_fixture_func( + self.obj, ("teardown_function",) + ) + if setup_function is None and teardown_function is None: + return + + def xunit_setup_function_fixture(request) -> Generator[None]: + if request.instance is not None: + # in this case we are bound to an instance, so we need to let + # setup_method handle this + yield + return + function = request.function + if setup_function is not None: + _call_with_optional_argument(setup_function, function) + yield + if teardown_function is not None: + _call_with_optional_argument(teardown_function, function) + + self.session._fixturemanager._register_fixture( + # Use a unique name to speed up lookup. + name=f"_xunit_setup_function_fixture_{self.obj.__name__}", + func=xunit_setup_function_fixture, + nodeid=self.nodeid, + scope="function", + autouse=True, + ) + + +class Package(nodes.Directory): + """Collector for files and directories in a Python packages -- directories + with an `__init__.py` file. + + .. note:: + + Directories without an `__init__.py` file are instead collected by + :class:`~pytest.Dir` by default. Both are :class:`~pytest.Directory` + collectors. + + .. versionchanged:: 8.0 + + Now inherits from :class:`~pytest.Directory`. + """ + + def __init__( + self, + fspath: LEGACY_PATH | None, + parent: nodes.Collector, + # NOTE: following args are unused: + config=None, + session=None, + nodeid=None, + path: Path | None = None, + ) -> None: + # NOTE: Could be just the following, but kept as-is for compat. + # super().__init__(self, fspath, parent=parent) + session = parent.session + super().__init__( + fspath=fspath, + path=path, + parent=parent, + config=config, + session=session, + nodeid=nodeid, + ) + + def setup(self) -> None: + init_mod = importtestmodule(self.path / "__init__.py", self.config) + + # Not using fixtures to call setup_module here because autouse fixtures + # from packages are not called automatically (#4085). + setup_module = _get_first_non_fixture_func( + init_mod, ("setUpModule", "setup_module") + ) + if setup_module is not None: + _call_with_optional_argument(setup_module, init_mod) + + teardown_module = _get_first_non_fixture_func( + init_mod, ("tearDownModule", "teardown_module") + ) + if teardown_module is not None: + func = partial(_call_with_optional_argument, teardown_module, init_mod) + self.addfinalizer(func) + + def collect(self) -> Iterable[nodes.Item | nodes.Collector]: + # Always collect __init__.py first. + def sort_key(entry: os.DirEntry[str]) -> object: + return (entry.name != "__init__.py", entry.name) + + config = self.config + col: nodes.Collector | None + cols: Sequence[nodes.Collector] + ihook = self.ihook + for direntry in scandir(self.path, sort_key): + if direntry.is_dir(): + path = Path(direntry.path) + if not self.session.isinitpath(path, with_parents=True): + if ihook.pytest_ignore_collect(collection_path=path, config=config): + continue + col = ihook.pytest_collect_directory(path=path, parent=self) + if col is not None: + yield col + + elif direntry.is_file(): + path = Path(direntry.path) + if not self.session.isinitpath(path): + if ihook.pytest_ignore_collect(collection_path=path, config=config): + continue + cols = ihook.pytest_collect_file(file_path=path, parent=self) + yield from cols + + +def _call_with_optional_argument(func, arg) -> None: + """Call the given function with the given argument if func accepts one argument, otherwise + calls func without arguments.""" + arg_count = func.__code__.co_argcount + if inspect.ismethod(func): + arg_count -= 1 + if arg_count: + func(arg) + else: + func() + + +def _get_first_non_fixture_func(obj: object, names: Iterable[str]) -> object | None: + """Return the attribute from the given object to be used as a setup/teardown + xunit-style function, but only if not marked as a fixture to avoid calling it twice. + """ + for name in names: + meth: object | None = getattr(obj, name, None) + if meth is not None and fixtures.getfixturemarker(meth) is None: + return meth + return None + + +class Class(PyCollector): + """Collector for test methods (and nested classes) in a Python class.""" + + @classmethod + def from_parent(cls, parent, *, name, obj=None, **kw) -> Self: # type: ignore[override] + """The public constructor.""" + return super().from_parent(name=name, parent=parent, **kw) + + def newinstance(self): + return self.obj() + + def collect(self) -> Iterable[nodes.Item | nodes.Collector]: + if not safe_getattr(self.obj, "__test__", True): + return [] + if hasinit(self.obj): + assert self.parent is not None + self.warn( + PytestCollectionWarning( + f"cannot collect test class {self.obj.__name__!r} because it has a " + f"__init__ constructor (from: {self.parent.nodeid})" + ) + ) + return [] + elif hasnew(self.obj): + assert self.parent is not None + self.warn( + PytestCollectionWarning( + f"cannot collect test class {self.obj.__name__!r} because it has a " + f"__new__ constructor (from: {self.parent.nodeid})" + ) + ) + return [] + + self._register_setup_class_fixture() + self._register_setup_method_fixture() + + self.session._fixturemanager.parsefactories(self.newinstance(), self.nodeid) + + return super().collect() + + def _register_setup_class_fixture(self) -> None: + """Register an autouse, class scoped fixture into the collected class object + that invokes setup_class/teardown_class if either or both are available. + + Using a fixture to invoke this methods ensures we play nicely and unsurprisingly with + other fixtures (#517). + """ + setup_class = _get_first_non_fixture_func(self.obj, ("setup_class",)) + teardown_class = _get_first_non_fixture_func(self.obj, ("teardown_class",)) + if setup_class is None and teardown_class is None: + return + + def xunit_setup_class_fixture(request) -> Generator[None]: + cls = request.cls + if setup_class is not None: + func = getimfunc(setup_class) + _call_with_optional_argument(func, cls) + yield + if teardown_class is not None: + func = getimfunc(teardown_class) + _call_with_optional_argument(func, cls) + + self.session._fixturemanager._register_fixture( + # Use a unique name to speed up lookup. + name=f"_xunit_setup_class_fixture_{self.obj.__qualname__}", + func=xunit_setup_class_fixture, + nodeid=self.nodeid, + scope="class", + autouse=True, + ) + + def _register_setup_method_fixture(self) -> None: + """Register an autouse, function scoped fixture into the collected class object + that invokes setup_method/teardown_method if either or both are available. + + Using a fixture to invoke these methods ensures we play nicely and unsurprisingly with + other fixtures (#517). + """ + setup_name = "setup_method" + setup_method = _get_first_non_fixture_func(self.obj, (setup_name,)) + teardown_name = "teardown_method" + teardown_method = _get_first_non_fixture_func(self.obj, (teardown_name,)) + if setup_method is None and teardown_method is None: + return + + def xunit_setup_method_fixture(request) -> Generator[None]: + instance = request.instance + method = request.function + if setup_method is not None: + func = getattr(instance, setup_name) + _call_with_optional_argument(func, method) + yield + if teardown_method is not None: + func = getattr(instance, teardown_name) + _call_with_optional_argument(func, method) + + self.session._fixturemanager._register_fixture( + # Use a unique name to speed up lookup. + name=f"_xunit_setup_method_fixture_{self.obj.__qualname__}", + func=xunit_setup_method_fixture, + nodeid=self.nodeid, + scope="function", + autouse=True, + ) + + +def hasinit(obj: object) -> bool: + init: object = getattr(obj, "__init__", None) + if init: + return init != object.__init__ + return False + + +def hasnew(obj: object) -> bool: + new: object = getattr(obj, "__new__", None) + if new: + return new != object.__new__ + return False + + +@final +@dataclasses.dataclass(frozen=True) +class IdMaker: + """Make IDs for a parametrization.""" + + __slots__ = ( + "argnames", + "config", + "func_name", + "idfn", + "ids", + "nodeid", + "parametersets", + ) + + # The argnames of the parametrization. + argnames: Sequence[str] + # The ParameterSets of the parametrization. + parametersets: Sequence[ParameterSet] + # Optionally, a user-provided callable to make IDs for parameters in a + # ParameterSet. + idfn: Callable[[Any], object | None] | None + # Optionally, explicit IDs for ParameterSets by index. + ids: Sequence[object | None] | None + # Optionally, the pytest config. + # Used for controlling ASCII escaping, determining parametrization ID + # strictness, and for calling the :hook:`pytest_make_parametrize_id` hook. + config: Config | None + # Optionally, the ID of the node being parametrized. + # Used only for clearer error messages. + nodeid: str | None + # Optionally, the ID of the function being parametrized. + # Used only for clearer error messages. + func_name: str | None + + def make_unique_parameterset_ids(self) -> list[str | _HiddenParam]: + """Make a unique identifier for each ParameterSet, that may be used to + identify the parametrization in a node ID. + + If strict_parametrization_ids is enabled, and duplicates are detected, + raises CollectError. Otherwise makes the IDs unique as follows: + + Format is <prm_1_token>-...-<prm_n_token>[counter], where prm_x_token is + - user-provided id, if given + - else an id derived from the value, applicable for certain types + - else <argname><parameterset index> + The counter suffix is appended only in case a string wouldn't be unique + otherwise. + """ + resolved_ids = list(self._resolve_ids()) + # All IDs must be unique! + if len(resolved_ids) != len(set(resolved_ids)): + # Record the number of occurrences of each ID. + id_counts = Counter(resolved_ids) + + if self._strict_parametrization_ids_enabled(): + parameters = ", ".join(self.argnames) + parametersets = ", ".join( + [saferepr(list(param.values)) for param in self.parametersets] + ) + ids = ", ".join( + id if id is not HIDDEN_PARAM else "<hidden>" for id in resolved_ids + ) + duplicates = ", ".join( + id if id is not HIDDEN_PARAM else "<hidden>" + for id, count in id_counts.items() + if count > 1 + ) + msg = textwrap.dedent(f""" + Duplicate parametrization IDs detected, but strict_parametrization_ids is set. + + Test name: {self.nodeid} + Parameters: {parameters} + Parameter sets: {parametersets} + IDs: {ids} + Duplicates: {duplicates} + + You can fix this problem using `@pytest.mark.parametrize(..., ids=...)` or `pytest.param(..., id=...)`. + """).strip() # noqa: E501 + raise nodes.Collector.CollectError(msg) + + # Map the ID to its next suffix. + id_suffixes: dict[str, int] = defaultdict(int) + # Suffix non-unique IDs to make them unique. + for index, id in enumerate(resolved_ids): + if id_counts[id] > 1: + if id is HIDDEN_PARAM: + self._complain_multiple_hidden_parameter_sets() + suffix = "" + if id and id[-1].isdigit(): + suffix = "_" + new_id = f"{id}{suffix}{id_suffixes[id]}" + while new_id in set(resolved_ids): + id_suffixes[id] += 1 + new_id = f"{id}{suffix}{id_suffixes[id]}" + resolved_ids[index] = new_id + id_suffixes[id] += 1 + assert len(resolved_ids) == len(set(resolved_ids)), ( + f"Internal error: {resolved_ids=}" + ) + return resolved_ids + + def _strict_parametrization_ids_enabled(self) -> bool: + if self.config is None: + return False + strict_parametrization_ids = self.config.getini("strict_parametrization_ids") + if strict_parametrization_ids is None: + strict_parametrization_ids = self.config.getini("strict") + return cast(bool, strict_parametrization_ids) + + def _resolve_ids(self) -> Iterable[str | _HiddenParam]: + """Resolve IDs for all ParameterSets (may contain duplicates).""" + for idx, parameterset in enumerate(self.parametersets): + if parameterset.id is not None: + # ID provided directly - pytest.param(..., id="...") + if parameterset.id is HIDDEN_PARAM: + yield HIDDEN_PARAM + else: + yield _ascii_escaped_by_config(parameterset.id, self.config) + elif self.ids and idx < len(self.ids) and self.ids[idx] is not None: + # ID provided in the IDs list - parametrize(..., ids=[...]). + if self.ids[idx] is HIDDEN_PARAM: + yield HIDDEN_PARAM + else: + yield self._idval_from_value_required(self.ids[idx], idx) + else: + # ID not provided - generate it. + yield "-".join( + self._idval(val, argname, idx) + for val, argname in zip( + parameterset.values, self.argnames, strict=True + ) + ) + + def _idval(self, val: object, argname: str, idx: int) -> str: + """Make an ID for a parameter in a ParameterSet.""" + idval = self._idval_from_function(val, argname, idx) + if idval is not None: + return idval + idval = self._idval_from_hook(val, argname) + if idval is not None: + return idval + idval = self._idval_from_value(val) + if idval is not None: + return idval + return self._idval_from_argname(argname, idx) + + def _idval_from_function(self, val: object, argname: str, idx: int) -> str | None: + """Try to make an ID for a parameter in a ParameterSet using the + user-provided id callable, if given.""" + if self.idfn is None: + return None + try: + id = self.idfn(val) + except Exception as e: + prefix = f"{self.nodeid}: " if self.nodeid is not None else "" + msg = "error raised while trying to determine id of parameter '{}' at position {}" + msg = prefix + msg.format(argname, idx) + raise ValueError(msg) from e + if id is None: + return None + return self._idval_from_value(id) + + def _idval_from_hook(self, val: object, argname: str) -> str | None: + """Try to make an ID for a parameter in a ParameterSet by calling the + :hook:`pytest_make_parametrize_id` hook.""" + if self.config: + id: str | None = self.config.hook.pytest_make_parametrize_id( + config=self.config, val=val, argname=argname + ) + return id + return None + + def _idval_from_value(self, val: object) -> str | None: + """Try to make an ID for a parameter in a ParameterSet from its value, + if the value type is supported.""" + if isinstance(val, str | bytes): + return _ascii_escaped_by_config(val, self.config) + elif val is None or isinstance(val, float | int | bool | complex): + return str(val) + elif isinstance(val, re.Pattern): + return ascii_escaped(val.pattern) + elif val is NOTSET: + # Fallback to default. Note that NOTSET is an enum.Enum. + pass + elif isinstance(val, enum.Enum): + return str(val) + elif isinstance(getattr(val, "__name__", None), str): + # Name of a class, function, module, etc. + name: str = getattr(val, "__name__") + return name + return None + + def _idval_from_value_required(self, val: object, idx: int) -> str: + """Like _idval_from_value(), but fails if the type is not supported.""" + id = self._idval_from_value(val) + if id is not None: + return id + + # Fail. + prefix = self._make_error_prefix() + msg = ( + f"{prefix}ids contains unsupported value {saferepr(val)} (type: {type(val)!r}) at index {idx}. " + "Supported types are: str, bytes, int, float, complex, bool, enum, regex or anything with a __name__." + ) + fail(msg, pytrace=False) + + @staticmethod + def _idval_from_argname(argname: str, idx: int) -> str: + """Make an ID for a parameter in a ParameterSet from the argument name + and the index of the ParameterSet.""" + return str(argname) + str(idx) + + def _complain_multiple_hidden_parameter_sets(self) -> NoReturn: + fail( + f"{self._make_error_prefix()}multiple instances of HIDDEN_PARAM " + "cannot be used in the same parametrize call, " + "because the tests names need to be unique." + ) + + def _make_error_prefix(self) -> str: + if self.func_name is not None: + return f"In {self.func_name}: " + elif self.nodeid is not None: + return f"In {self.nodeid}: " + else: + return "" + + +@final +@dataclasses.dataclass(frozen=True) +class CallSpec2: + """A planned parameterized invocation of a test function. + + Calculated during collection for a given test function's Metafunc. + Once collection is over, each callspec is turned into a single Item + and stored in item.callspec. + """ + + # arg name -> arg value which will be passed to a fixture or pseudo-fixture + # of the same name. (indirect or direct parametrization respectively) + params: dict[str, object] = dataclasses.field(default_factory=dict) + # arg name -> arg index. + indices: dict[str, int] = dataclasses.field(default_factory=dict) + # arg name -> parameter scope. + # Used for sorting parametrized resources. + _arg2scope: Mapping[str, Scope] = dataclasses.field(default_factory=dict) + # Parts which will be added to the item's name in `[..]` separated by "-". + _idlist: Sequence[str] = dataclasses.field(default_factory=tuple) + # Marks which will be applied to the item. + marks: list[Mark] = dataclasses.field(default_factory=list) + + def setmulti( + self, + *, + argnames: Iterable[str], + valset: Iterable[object], + id: str | _HiddenParam, + marks: Iterable[Mark | MarkDecorator], + scope: Scope, + param_index: int, + nodeid: str, + ) -> CallSpec2: + params = self.params.copy() + indices = self.indices.copy() + arg2scope = dict(self._arg2scope) + for arg, val in zip(argnames, valset, strict=True): + if arg in params: + raise nodes.Collector.CollectError( + f"{nodeid}: duplicate parametrization of {arg!r}" + ) + params[arg] = val + indices[arg] = param_index + arg2scope[arg] = scope + return CallSpec2( + params=params, + indices=indices, + _arg2scope=arg2scope, + _idlist=self._idlist if id is HIDDEN_PARAM else [*self._idlist, id], + marks=[*self.marks, *normalize_mark_list(marks)], + ) + + def getparam(self, name: str) -> object: + try: + return self.params[name] + except KeyError as e: + raise ValueError(name) from e + + @property + def id(self) -> str: + return "-".join(self._idlist) + + +def get_direct_param_fixture_func(request: FixtureRequest) -> Any: + return request.param + + +# Used for storing pseudo fixturedefs for direct parametrization. +name2pseudofixturedef_key = StashKey[dict[str, FixtureDef[Any]]]() + + +@final +class Metafunc: + """Objects passed to the :hook:`pytest_generate_tests` hook. + + They help to inspect a test function and to generate tests according to + test configuration or values specified in the class or module where a + test function is defined. + """ + + def __init__( + self, + definition: FunctionDefinition, + fixtureinfo: fixtures.FuncFixtureInfo, + config: Config, + cls=None, + module=None, + *, + _ispytest: bool = False, + ) -> None: + check_ispytest(_ispytest) + + #: Access to the underlying :class:`_pytest.python.FunctionDefinition`. + self.definition = definition + + #: Access to the :class:`pytest.Config` object for the test session. + self.config = config + + #: The module object where the test function is defined in. + self.module = module + + #: Underlying Python test function. + self.function = definition.obj + + #: Set of fixture names required by the test function. + self.fixturenames = fixtureinfo.names_closure + + #: Class object where the test function is defined in or ``None``. + self.cls = cls + + self._arg2fixturedefs = fixtureinfo.name2fixturedefs + + # Result of parametrize(). + self._calls: list[CallSpec2] = [] + + self._params_directness: dict[str, Literal["indirect", "direct"]] = {} + + def parametrize( + self, + argnames: str | Sequence[str], + argvalues: Iterable[ParameterSet | Sequence[object] | object], + indirect: bool | Sequence[str] = False, + ids: Iterable[object | None] | Callable[[Any], object | None] | None = None, + scope: _ScopeName | None = None, + *, + _param_mark: Mark | None = None, + ) -> None: + """Add new invocations to the underlying test function using the list + of argvalues for the given argnames. Parametrization is performed + during the collection phase. If you need to setup expensive resources + see about setting ``indirect`` to do it at test setup time instead. + + Can be called multiple times per test function (but only on different + argument names), in which case each call parametrizes all previous + parametrizations, e.g. + + :: + + unparametrized: t + parametrize ["x", "y"]: t[x], t[y] + parametrize [1, 2]: t[x-1], t[x-2], t[y-1], t[y-2] + + :param argnames: + A comma-separated string denoting one or more argument names, or + a list/tuple of argument strings. + + :param argvalues: + The list of argvalues determines how often a test is invoked with + different argument values. + + If only one argname was specified argvalues is a list of values. + If N argnames were specified, argvalues must be a list of + N-tuples, where each tuple-element specifies a value for its + respective argname. + + :param indirect: + A list of arguments' names (subset of argnames) or a boolean. + If True the list contains all names from the argnames. Each + argvalue corresponding to an argname in this list will + be passed as request.param to its respective argname fixture + function so that it can perform more expensive setups during the + setup phase of a test rather than at collection time. + + :param ids: + Sequence of (or generator for) ids for ``argvalues``, + or a callable to return part of the id for each argvalue. + + With sequences (and generators like ``itertools.count()``) the + returned ids should be of type ``string``, ``int``, ``float``, + ``bool``, or ``None``. + They are mapped to the corresponding index in ``argvalues``. + ``None`` means to use the auto-generated id. + + .. versionadded:: 8.4 + :ref:`hidden-param` means to hide the parameter set + from the test name. Can only be used at most 1 time, as + test names need to be unique. + + If it is a callable it will be called for each entry in + ``argvalues``, and the return value is used as part of the + auto-generated id for the whole set (where parts are joined with + dashes ("-")). + This is useful to provide more specific ids for certain items, e.g. + dates. Returning ``None`` will use an auto-generated id. + + If no ids are provided they will be generated automatically from + the argvalues. + + :param scope: + If specified it denotes the scope of the parameters. + The scope is used for grouping tests by parameter instances. + It will also override any fixture-function defined scope, allowing + to set a dynamic scope using test context or configuration. + """ + nodeid = self.definition.nodeid + + argnames, parametersets = ParameterSet._for_parametrize( + argnames, + argvalues, + self.function, + self.config, + nodeid=self.definition.nodeid, + ) + del argvalues + + if "request" in argnames: + fail( + f"{nodeid}: 'request' is a reserved name and cannot be used in @pytest.mark.parametrize", + pytrace=False, + ) + + if scope is not None: + scope_ = Scope.from_user( + scope, descr=f"parametrize() call in {self.function.__name__}" + ) + else: + scope_ = _find_parametrized_scope(argnames, self._arg2fixturedefs, indirect) + + self._validate_if_using_arg_names(argnames, indirect) + + # Use any already (possibly) generated ids with parametrize Marks. + if _param_mark and _param_mark._param_ids_from: + generated_ids = _param_mark._param_ids_from._param_ids_generated + if generated_ids is not None: + ids = generated_ids + + ids = self._resolve_parameter_set_ids( + argnames, ids, parametersets, nodeid=self.definition.nodeid + ) + + # Store used (possibly generated) ids with parametrize Marks. + if _param_mark and _param_mark._param_ids_from and generated_ids is None: + object.__setattr__(_param_mark._param_ids_from, "_param_ids_generated", ids) + + # Calculate directness. + arg_directness = self._resolve_args_directness(argnames, indirect) + self._params_directness.update(arg_directness) + + # Add direct parametrizations as fixturedefs to arg2fixturedefs by + # registering artificial "pseudo" FixtureDef's such that later at test + # setup time we can rely on FixtureDefs to exist for all argnames. + node = None + # For scopes higher than function, a "pseudo" FixtureDef might have + # already been created for the scope. We thus store and cache the + # FixtureDef on the node related to the scope. + if scope_ is Scope.Function: + name2pseudofixturedef = None + else: + collector = self.definition.parent + assert collector is not None + node = get_scope_node(collector, scope_) + if node is None: + # If used class scope and there is no class, use module-level + # collector (for now). + if scope_ is Scope.Class: + assert isinstance(collector, Module) + node = collector + # If used package scope and there is no package, use session + # (for now). + elif scope_ is Scope.Package: + node = collector.session + else: + assert False, f"Unhandled missing scope: {scope}" + default: dict[str, FixtureDef[Any]] = {} + name2pseudofixturedef = node.stash.setdefault( + name2pseudofixturedef_key, default + ) + for argname in argnames: + if arg_directness[argname] == "indirect": + continue + if name2pseudofixturedef is not None and argname in name2pseudofixturedef: + fixturedef = name2pseudofixturedef[argname] + else: + fixturedef = FixtureDef( + config=self.config, + baseid="", + argname=argname, + func=get_direct_param_fixture_func, + scope=scope_, + params=None, + ids=None, + _ispytest=True, + ) + if name2pseudofixturedef is not None: + name2pseudofixturedef[argname] = fixturedef + self._arg2fixturedefs[argname] = [fixturedef] + + # Create the new calls: if we are parametrize() multiple times (by applying the decorator + # more than once) then we accumulate those calls generating the cartesian product + # of all calls. + newcalls = [] + for callspec in self._calls or [CallSpec2()]: + for param_index, (param_id, param_set) in enumerate( + zip(ids, parametersets, strict=True) + ): + newcallspec = callspec.setmulti( + argnames=argnames, + valset=param_set.values, + id=param_id, + marks=param_set.marks, + scope=scope_, + param_index=param_index, + nodeid=nodeid, + ) + newcalls.append(newcallspec) + self._calls = newcalls + + def _resolve_parameter_set_ids( + self, + argnames: Sequence[str], + ids: Iterable[object | None] | Callable[[Any], object | None] | None, + parametersets: Sequence[ParameterSet], + nodeid: str, + ) -> list[str | _HiddenParam]: + """Resolve the actual ids for the given parameter sets. + + :param argnames: + Argument names passed to ``parametrize()``. + :param ids: + The `ids` parameter of the ``parametrize()`` call (see docs). + :param parametersets: + The parameter sets, each containing a set of values corresponding + to ``argnames``. + :param nodeid str: + The nodeid of the definition item that generated this + parametrization. + :returns: + List with ids for each parameter set given. + """ + if ids is None: + idfn = None + ids_ = None + elif callable(ids): + idfn = ids + ids_ = None + else: + idfn = None + ids_ = self._validate_ids(ids, parametersets, self.function.__name__) + id_maker = IdMaker( + argnames, + parametersets, + idfn, + ids_, + self.config, + nodeid=nodeid, + func_name=self.function.__name__, + ) + return id_maker.make_unique_parameterset_ids() + + def _validate_ids( + self, + ids: Iterable[object | None], + parametersets: Sequence[ParameterSet], + func_name: str, + ) -> list[object | None]: + try: + num_ids = len(ids) # type: ignore[arg-type] + except TypeError: + try: + iter(ids) + except TypeError as e: + raise TypeError("ids must be a callable or an iterable") from e + num_ids = len(parametersets) + + # num_ids == 0 is a special case: https://github.com/pytest-dev/pytest/issues/1849 + if num_ids != len(parametersets) and num_ids != 0: + msg = "In {}: {} parameter sets specified, with different number of ids: {}" + fail(msg.format(func_name, len(parametersets), num_ids), pytrace=False) + + return list(itertools.islice(ids, num_ids)) + + def _resolve_args_directness( + self, + argnames: Sequence[str], + indirect: bool | Sequence[str], + ) -> dict[str, Literal["indirect", "direct"]]: + """Resolve if each parametrized argument must be considered an indirect + parameter to a fixture of the same name, or a direct parameter to the + parametrized function, based on the ``indirect`` parameter of the + parametrized() call. + + :param argnames: + List of argument names passed to ``parametrize()``. + :param indirect: + Same as the ``indirect`` parameter of ``parametrize()``. + :returns + A dict mapping each arg name to either "indirect" or "direct". + """ + arg_directness: dict[str, Literal["indirect", "direct"]] + if isinstance(indirect, bool): + arg_directness = dict.fromkeys( + argnames, "indirect" if indirect else "direct" + ) + elif isinstance(indirect, Sequence): + arg_directness = dict.fromkeys(argnames, "direct") + for arg in indirect: + if arg not in argnames: + fail( + f"In {self.function.__name__}: indirect fixture '{arg}' doesn't exist", + pytrace=False, + ) + arg_directness[arg] = "indirect" + else: + fail( + f"In {self.function.__name__}: expected Sequence or boolean" + f" for indirect, got {type(indirect).__name__}", + pytrace=False, + ) + return arg_directness + + def _validate_if_using_arg_names( + self, + argnames: Sequence[str], + indirect: bool | Sequence[str], + ) -> None: + """Check if all argnames are being used, by default values, or directly/indirectly. + + :param List[str] argnames: List of argument names passed to ``parametrize()``. + :param indirect: Same as the ``indirect`` parameter of ``parametrize()``. + :raises ValueError: If validation fails. + """ + default_arg_names = set(get_default_arg_names(self.function)) + func_name = self.function.__name__ + for arg in argnames: + if arg not in self.fixturenames: + if arg in default_arg_names: + fail( + f"In {func_name}: function already takes an argument '{arg}' with a default value", + pytrace=False, + ) + else: + if isinstance(indirect, Sequence): + name = "fixture" if arg in indirect else "argument" + else: + name = "fixture" if indirect else "argument" + fail( + f"In {func_name}: function uses no {name} '{arg}'", + pytrace=False, + ) + + def _recompute_direct_params_indices(self) -> None: + for argname, param_type in self._params_directness.items(): + if param_type == "direct": + for i, callspec in enumerate(self._calls): + callspec.indices[argname] = i + + +def _find_parametrized_scope( + argnames: Sequence[str], + arg2fixturedefs: Mapping[str, Sequence[fixtures.FixtureDef[object]]], + indirect: bool | Sequence[str], +) -> Scope: + """Find the most appropriate scope for a parametrized call based on its arguments. + + When there's at least one direct argument, always use "function" scope. + + When a test function is parametrized and all its arguments are indirect + (e.g. fixtures), return the most narrow scope based on the fixtures used. + + Related to issue #1832, based on code posted by @Kingdread. + """ + if isinstance(indirect, Sequence): + all_arguments_are_fixtures = len(indirect) == len(argnames) + else: + all_arguments_are_fixtures = bool(indirect) + + if all_arguments_are_fixtures: + fixturedefs = arg2fixturedefs or {} + used_scopes = [ + fixturedef[-1]._scope + for name, fixturedef in fixturedefs.items() + if name in argnames + ] + # Takes the most narrow scope from used fixtures. + return min(used_scopes, default=Scope.Function) + + return Scope.Function + + +def _ascii_escaped_by_config(val: str | bytes, config: Config | None) -> str: + if config is None: + escape_option = False + else: + escape_option = config.getini( + "disable_test_id_escaping_and_forfeit_all_rights_to_community_support" + ) + # TODO: If escaping is turned off and the user passes bytes, + # will return a bytes. For now we ignore this but the + # code *probably* doesn't handle this case. + return val if escape_option else ascii_escaped(val) # type: ignore + + +class Function(PyobjMixin, nodes.Item): + """Item responsible for setting up and executing a Python test function. + + :param name: + The full function name, including any decorations like those + added by parametrization (``my_func[my_param]``). + :param parent: + The parent Node. + :param config: + The pytest Config object. + :param callspec: + If given, this function has been parametrized and the callspec contains + meta information about the parametrization. + :param callobj: + If given, the object which will be called when the Function is invoked, + otherwise the callobj will be obtained from ``parent`` using ``originalname``. + :param keywords: + Keywords bound to the function object for "-k" matching. + :param session: + The pytest Session object. + :param fixtureinfo: + Fixture information already resolved at this fixture node.. + :param originalname: + The attribute name to use for accessing the underlying function object. + Defaults to ``name``. Set this if name is different from the original name, + for example when it contains decorations like those added by parametrization + (``my_func[my_param]``). + """ + + # Disable since functions handle it themselves. + _ALLOW_MARKERS = False + + def __init__( + self, + name: str, + parent, + config: Config | None = None, + callspec: CallSpec2 | None = None, + callobj=NOTSET, + keywords: Mapping[str, Any] | None = None, + session: Session | None = None, + fixtureinfo: FuncFixtureInfo | None = None, + originalname: str | None = None, + ) -> None: + super().__init__(name, parent, config=config, session=session) + + if callobj is not NOTSET: + self._obj = callobj + self._instance = getattr(callobj, "__self__", None) + + #: Original function name, without any decorations (for example + #: parametrization adds a ``"[...]"`` suffix to function names), used to access + #: the underlying function object from ``parent`` (in case ``callobj`` is not given + #: explicitly). + #: + #: .. versionadded:: 3.0 + self.originalname = originalname or name + + # Note: when FunctionDefinition is introduced, we should change ``originalname`` + # to a readonly property that returns FunctionDefinition.name. + + self.own_markers.extend(get_unpacked_marks(self.obj)) + if callspec: + self.callspec = callspec + self.own_markers.extend(callspec.marks) + + # todo: this is a hell of a hack + # https://github.com/pytest-dev/pytest/issues/4569 + # Note: the order of the updates is important here; indicates what + # takes priority (ctor argument over function attributes over markers). + # Take own_markers only; NodeKeywords handles parent traversal on its own. + self.keywords.update((mark.name, mark) for mark in self.own_markers) + self.keywords.update(self.obj.__dict__) + if keywords: + self.keywords.update(keywords) + + if fixtureinfo is None: + fm = self.session._fixturemanager + fixtureinfo = fm.getfixtureinfo(self, self.obj, self.cls) + self._fixtureinfo: FuncFixtureInfo = fixtureinfo + self.fixturenames = fixtureinfo.names_closure + self._initrequest() + + # todo: determine sound type limitations + @classmethod + def from_parent(cls, parent, **kw) -> Self: + """The public constructor.""" + return super().from_parent(parent=parent, **kw) + + def _initrequest(self) -> None: + self.funcargs: dict[str, object] = {} + self._request = fixtures.TopRequest(self, _ispytest=True) + + @property + def function(self): + """Underlying python 'function' object.""" + return getimfunc(self.obj) + + @property + def instance(self): + try: + return self._instance + except AttributeError: + if isinstance(self.parent, Class): + # Each Function gets a fresh class instance. + self._instance = self._getinstance() + else: + self._instance = None + return self._instance + + def _getinstance(self): + if isinstance(self.parent, Class): + # Each Function gets a fresh class instance. + return self.parent.newinstance() + else: + return None + + def _getobj(self): + instance = self.instance + if instance is not None: + parent_obj = instance + else: + assert self.parent is not None + parent_obj = self.parent.obj # type: ignore[attr-defined] + return getattr(parent_obj, self.originalname) + + @property + def _pyfuncitem(self): + """(compatonly) for code expecting pytest-2.2 style request objects.""" + return self + + def runtest(self) -> None: + """Execute the underlying test function.""" + self.ihook.pytest_pyfunc_call(pyfuncitem=self) + + def setup(self) -> None: + self._request._fillfixtures() + + def _traceback_filter(self, excinfo: ExceptionInfo[BaseException]) -> Traceback: + if hasattr(self, "_obj") and not self.config.getoption("fulltrace", False): + code = _pytest._code.Code.from_function(get_real_func(self.obj)) + path, firstlineno = code.path, code.firstlineno + traceback = excinfo.traceback + ntraceback = traceback.cut(path=path, firstlineno=firstlineno) + if ntraceback == traceback: + ntraceback = ntraceback.cut(path=path) + if ntraceback == traceback: + ntraceback = ntraceback.filter(filter_traceback) + if not ntraceback: + ntraceback = traceback + ntraceback = ntraceback.filter(excinfo) + + # issue364: mark all but first and last frames to + # only show a single-line message for each frame. + if self.config.getoption("tbstyle", "auto") == "auto": + if len(ntraceback) > 2: + ntraceback = Traceback( + ( + ntraceback[0], + *(t.with_repr_style("short") for t in ntraceback[1:-1]), + ntraceback[-1], + ) + ) + + return ntraceback + return excinfo.traceback + + # TODO: Type ignored -- breaks Liskov Substitution. + def repr_failure( # type: ignore[override] + self, + excinfo: ExceptionInfo[BaseException], + ) -> str | TerminalRepr: + style = self.config.getoption("tbstyle", "auto") + if style == "auto": + style = "long" + return self._repr_failure_py(excinfo, style=style) + + +class FunctionDefinition(Function): + """This class is a stop gap solution until we evolve to have actual function + definition nodes and manage to get rid of ``metafunc``.""" + + def runtest(self) -> None: + raise RuntimeError("function definitions are not supposed to be run as tests") + + setup = runtest diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/python_api.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/python_api.py new file mode 100644 index 0000000000000000000000000000000000000000..bab70aa4a8c07c2c0906e948d195d6bc097a0c87 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/python_api.py @@ -0,0 +1,819 @@ +# mypy: allow-untyped-defs +from __future__ import annotations + +from collections.abc import Collection +from collections.abc import Mapping +from collections.abc import Sequence +from collections.abc import Sized +from decimal import Decimal +import math +from numbers import Complex +import pprint +import sys +from typing import Any +from typing import TYPE_CHECKING + + +if TYPE_CHECKING: + from numpy import ndarray + + +def _compare_approx( + full_object: object, + message_data: Sequence[tuple[str, str, str]], + number_of_elements: int, + different_ids: Sequence[object], + max_abs_diff: float, + max_rel_diff: float, +) -> list[str]: + message_list = list(message_data) + message_list.insert(0, ("Index", "Obtained", "Expected")) + max_sizes = [0, 0, 0] + for index, obtained, expected in message_list: + max_sizes[0] = max(max_sizes[0], len(index)) + max_sizes[1] = max(max_sizes[1], len(obtained)) + max_sizes[2] = max(max_sizes[2], len(expected)) + explanation = [ + f"comparison failed. Mismatched elements: {len(different_ids)} / {number_of_elements}:", + f"Max absolute difference: {max_abs_diff}", + f"Max relative difference: {max_rel_diff}", + ] + [ + f"{indexes:<{max_sizes[0]}} | {obtained:<{max_sizes[1]}} | {expected:<{max_sizes[2]}}" + for indexes, obtained, expected in message_list + ] + return explanation + + +# builtin pytest.approx helper + + +class ApproxBase: + """Provide shared utilities for making approximate comparisons between + numbers or sequences of numbers.""" + + # Tell numpy to use our `__eq__` operator instead of its. + __array_ufunc__ = None + __array_priority__ = 100 + + def __init__(self, expected, rel=None, abs=None, nan_ok: bool = False) -> None: + __tracebackhide__ = True + self.expected = expected + self.abs = abs + self.rel = rel + self.nan_ok = nan_ok + self._check_type() + + def __repr__(self) -> str: + raise NotImplementedError + + def _repr_compare(self, other_side: Any) -> list[str]: + return [ + "comparison failed", + f"Obtained: {other_side}", + f"Expected: {self}", + ] + + def __eq__(self, actual) -> bool: + return all( + a == self._approx_scalar(x) for a, x in self._yield_comparisons(actual) + ) + + def __bool__(self): + __tracebackhide__ = True + raise AssertionError( + "approx() is not supported in a boolean context.\nDid you mean: `assert a == approx(b)`?" + ) + + # Ignore type because of https://github.com/python/mypy/issues/4266. + __hash__ = None # type: ignore + + def __ne__(self, actual) -> bool: + return not (actual == self) + + def _approx_scalar(self, x) -> ApproxScalar: + if isinstance(x, Decimal): + return ApproxDecimal(x, rel=self.rel, abs=self.abs, nan_ok=self.nan_ok) + return ApproxScalar(x, rel=self.rel, abs=self.abs, nan_ok=self.nan_ok) + + def _yield_comparisons(self, actual): + """Yield all the pairs of numbers to be compared. + + This is used to implement the `__eq__` method. + """ + raise NotImplementedError + + def _check_type(self) -> None: + """Raise a TypeError if the expected value is not a valid type.""" + # This is only a concern if the expected value is a sequence. In every + # other case, the approx() function ensures that the expected value has + # a numeric type. For this reason, the default is to do nothing. The + # classes that deal with sequences should reimplement this method to + # raise if there are any non-numeric elements in the sequence. + + +def _recursive_sequence_map(f, x): + """Recursively map a function over a sequence of arbitrary depth""" + if isinstance(x, list | tuple): + seq_type = type(x) + return seq_type(_recursive_sequence_map(f, xi) for xi in x) + elif _is_sequence_like(x): + return [_recursive_sequence_map(f, xi) for xi in x] + else: + return f(x) + + +class ApproxNumpy(ApproxBase): + """Perform approximate comparisons where the expected value is numpy array.""" + + def __repr__(self) -> str: + list_scalars = _recursive_sequence_map( + self._approx_scalar, self.expected.tolist() + ) + return f"approx({list_scalars!r})" + + def _repr_compare(self, other_side: ndarray | list[Any]) -> list[str]: + import itertools + import math + + def get_value_from_nested_list( + nested_list: list[Any], nd_index: tuple[Any, ...] + ) -> Any: + """ + Helper function to get the value out of a nested list, given an n-dimensional index. + This mimics numpy's indexing, but for raw nested python lists. + """ + value: Any = nested_list + for i in nd_index: + value = value[i] + return value + + np_array_shape = self.expected.shape + approx_side_as_seq = _recursive_sequence_map( + self._approx_scalar, self.expected.tolist() + ) + + # convert other_side to numpy array to ensure shape attribute is available + other_side_as_array = _as_numpy_array(other_side) + assert other_side_as_array is not None + + if np_array_shape != other_side_as_array.shape: + return [ + "Impossible to compare arrays with different shapes.", + f"Shapes: {np_array_shape} and {other_side_as_array.shape}", + ] + + number_of_elements = self.expected.size + max_abs_diff = -math.inf + max_rel_diff = -math.inf + different_ids = [] + for index in itertools.product(*(range(i) for i in np_array_shape)): + approx_value = get_value_from_nested_list(approx_side_as_seq, index) + other_value = get_value_from_nested_list(other_side_as_array, index) + if approx_value != other_value: + abs_diff = abs(approx_value.expected - other_value) + max_abs_diff = max(max_abs_diff, abs_diff) + if other_value == 0.0: + max_rel_diff = math.inf + else: + max_rel_diff = max(max_rel_diff, abs_diff / abs(other_value)) + different_ids.append(index) + + message_data = [ + ( + str(index), + str(get_value_from_nested_list(other_side_as_array, index)), + str(get_value_from_nested_list(approx_side_as_seq, index)), + ) + for index in different_ids + ] + return _compare_approx( + self.expected, + message_data, + number_of_elements, + different_ids, + max_abs_diff, + max_rel_diff, + ) + + def __eq__(self, actual) -> bool: + import numpy as np + + # self.expected is supposed to always be an array here. + + if not np.isscalar(actual): + try: + actual = np.asarray(actual) + except Exception as e: + raise TypeError(f"cannot compare '{actual}' to numpy.ndarray") from e + + if not np.isscalar(actual) and actual.shape != self.expected.shape: + return False + + return super().__eq__(actual) + + def _yield_comparisons(self, actual): + import numpy as np + + # `actual` can either be a numpy array or a scalar, it is treated in + # `__eq__` before being passed to `ApproxBase.__eq__`, which is the + # only method that calls this one. + + if np.isscalar(actual): + for i in np.ndindex(self.expected.shape): + yield actual, self.expected[i].item() + else: + for i in np.ndindex(self.expected.shape): + yield actual[i].item(), self.expected[i].item() + + +class ApproxMapping(ApproxBase): + """Perform approximate comparisons where the expected value is a mapping + with numeric values (the keys can be anything).""" + + def __repr__(self) -> str: + return f"approx({ ({k: self._approx_scalar(v) for k, v in self.expected.items()})!r})" + + def _repr_compare(self, other_side: Mapping[object, float]) -> list[str]: + import math + + if len(self.expected) != len(other_side): + return [ + "Impossible to compare mappings with different sizes.", + f"Lengths: {len(self.expected)} and {len(other_side)}", + ] + + if self.expected.keys() != other_side.keys(): + return [ + "comparison failed.", + f"Mappings has different keys: expected {self.expected.keys()} but got {other_side.keys()}", + ] + + approx_side_as_map = { + k: self._approx_scalar(v) for k, v in self.expected.items() + } + + number_of_elements = len(approx_side_as_map) + max_abs_diff = -math.inf + max_rel_diff = -math.inf + different_ids = [] + for approx_key, approx_value in approx_side_as_map.items(): + other_value = other_side[approx_key] + if approx_value != other_value: + if approx_value.expected is not None and other_value is not None: + try: + max_abs_diff = max( + max_abs_diff, abs(approx_value.expected - other_value) + ) + if approx_value.expected == 0.0: + max_rel_diff = math.inf + else: + max_rel_diff = max( + max_rel_diff, + abs( + (approx_value.expected - other_value) + / approx_value.expected + ), + ) + except ZeroDivisionError: + pass + different_ids.append(approx_key) + + message_data = [ + (str(key), str(other_side[key]), str(approx_side_as_map[key])) + for key in different_ids + ] + + return _compare_approx( + self.expected, + message_data, + number_of_elements, + different_ids, + max_abs_diff, + max_rel_diff, + ) + + def __eq__(self, actual) -> bool: + try: + if set(actual.keys()) != set(self.expected.keys()): + return False + except AttributeError: + return False + + return super().__eq__(actual) + + def _yield_comparisons(self, actual): + for k in self.expected.keys(): + yield actual[k], self.expected[k] + + def _check_type(self) -> None: + __tracebackhide__ = True + for key, value in self.expected.items(): + if isinstance(value, type(self.expected)): + msg = "pytest.approx() does not support nested dictionaries: key={!r} value={!r}\n full mapping={}" + raise TypeError(msg.format(key, value, pprint.pformat(self.expected))) + + +class ApproxSequenceLike(ApproxBase): + """Perform approximate comparisons where the expected value is a sequence of numbers.""" + + def __repr__(self) -> str: + seq_type = type(self.expected) + if seq_type not in (tuple, list): + seq_type = list + return f"approx({seq_type(self._approx_scalar(x) for x in self.expected)!r})" + + def _repr_compare(self, other_side: Sequence[float]) -> list[str]: + import math + + if len(self.expected) != len(other_side): + return [ + "Impossible to compare lists with different sizes.", + f"Lengths: {len(self.expected)} and {len(other_side)}", + ] + + approx_side_as_map = _recursive_sequence_map(self._approx_scalar, self.expected) + + number_of_elements = len(approx_side_as_map) + max_abs_diff = -math.inf + max_rel_diff = -math.inf + different_ids = [] + for i, (approx_value, other_value) in enumerate( + zip(approx_side_as_map, other_side, strict=True) + ): + if approx_value != other_value: + try: + abs_diff = abs(approx_value.expected - other_value) + max_abs_diff = max(max_abs_diff, abs_diff) + # Ignore non-numbers for the diff calculations (#13012). + except TypeError: + pass + else: + if other_value == 0.0: + max_rel_diff = math.inf + else: + max_rel_diff = max(max_rel_diff, abs_diff / abs(other_value)) + different_ids.append(i) + message_data = [ + (str(i), str(other_side[i]), str(approx_side_as_map[i])) + for i in different_ids + ] + + return _compare_approx( + self.expected, + message_data, + number_of_elements, + different_ids, + max_abs_diff, + max_rel_diff, + ) + + def __eq__(self, actual) -> bool: + try: + if len(actual) != len(self.expected): + return False + except TypeError: + return False + return super().__eq__(actual) + + def _yield_comparisons(self, actual): + return zip(actual, self.expected, strict=True) + + def _check_type(self) -> None: + __tracebackhide__ = True + for index, x in enumerate(self.expected): + if isinstance(x, type(self.expected)): + msg = "pytest.approx() does not support nested data structures: {!r} at index {}\n full sequence: {}" + raise TypeError(msg.format(x, index, pprint.pformat(self.expected))) + + +class ApproxScalar(ApproxBase): + """Perform approximate comparisons where the expected value is a single number.""" + + # Using Real should be better than this Union, but not possible yet: + # https://github.com/python/typeshed/pull/3108 + DEFAULT_ABSOLUTE_TOLERANCE: float | Decimal = 1e-12 + DEFAULT_RELATIVE_TOLERANCE: float | Decimal = 1e-6 + + def __repr__(self) -> str: + """Return a string communicating both the expected value and the + tolerance for the comparison being made. + + For example, ``1.0 ± 1e-6``, ``(3+4j) ± 5e-6 ∠ ±180°``. + """ + # Don't show a tolerance for values that aren't compared using + # tolerances, i.e. non-numerics and infinities. Need to call abs to + # handle complex numbers, e.g. (inf + 1j). + if ( + isinstance(self.expected, bool) + or (not isinstance(self.expected, Complex | Decimal)) + or math.isinf(abs(self.expected) or isinstance(self.expected, bool)) + ): + return str(self.expected) + + # If a sensible tolerance can't be calculated, self.tolerance will + # raise a ValueError. In this case, display '???'. + try: + if 1e-3 <= self.tolerance < 1e3: + vetted_tolerance = f"{self.tolerance:n}" + else: + vetted_tolerance = f"{self.tolerance:.1e}" + + if ( + isinstance(self.expected, Complex) + and self.expected.imag + and not math.isinf(self.tolerance) + ): + vetted_tolerance += " ∠ ±180°" + except ValueError: + vetted_tolerance = "???" + + return f"{self.expected} ± {vetted_tolerance}" + + def __eq__(self, actual) -> bool: + """Return whether the given value is equal to the expected value + within the pre-specified tolerance.""" + + def is_bool(val: Any) -> bool: + # Check if `val` is a native bool or numpy bool. + if isinstance(val, bool): + return True + if np := sys.modules.get("numpy"): + return isinstance(val, np.bool_) + return False + + asarray = _as_numpy_array(actual) + if asarray is not None: + # Call ``__eq__()`` manually to prevent infinite-recursion with + # numpy<1.13. See #3748. + return all(self.__eq__(a) for a in asarray.flat) + + # Short-circuit exact equality, except for bool and np.bool_ + if is_bool(self.expected) and not is_bool(actual): + return False + elif actual == self.expected: + return True + + # If either type is non-numeric, fall back to strict equality. + # NB: we need Complex, rather than just Number, to ensure that __abs__, + # __sub__, and __float__ are defined. Also, consider bool to be + # non-numeric, even though it has the required arithmetic. + if is_bool(self.expected) or not ( + isinstance(self.expected, Complex | Decimal) + and isinstance(actual, Complex | Decimal) + ): + return False + + # Allow the user to control whether NaNs are considered equal to each + # other or not. The abs() calls are for compatibility with complex + # numbers. + if math.isnan(abs(self.expected)): + return self.nan_ok and math.isnan(abs(actual)) + + # Infinity shouldn't be approximately equal to anything but itself, but + # if there's a relative tolerance, it will be infinite and infinity + # will seem approximately equal to everything. The equal-to-itself + # case would have been short circuited above, so here we can just + # return false if the expected value is infinite. The abs() call is + # for compatibility with complex numbers. + if math.isinf(abs(self.expected)): + return False + + # Return true if the two numbers are within the tolerance. + result: bool = abs(self.expected - actual) <= self.tolerance + return result + + __hash__ = None + + @property + def tolerance(self): + """Return the tolerance for the comparison. + + This could be either an absolute tolerance or a relative tolerance, + depending on what the user specified or which would be larger. + """ + + def set_default(x, default): + return x if x is not None else default + + # Figure out what the absolute tolerance should be. ``self.abs`` is + # either None or a value specified by the user. + absolute_tolerance = set_default(self.abs, self.DEFAULT_ABSOLUTE_TOLERANCE) + + if absolute_tolerance < 0: + raise ValueError( + f"absolute tolerance can't be negative: {absolute_tolerance}" + ) + if math.isnan(absolute_tolerance): + raise ValueError("absolute tolerance can't be NaN.") + + # If the user specified an absolute tolerance but not a relative one, + # just return the absolute tolerance. + if self.rel is None: + if self.abs is not None: + return absolute_tolerance + + # Figure out what the relative tolerance should be. ``self.rel`` is + # either None or a value specified by the user. This is done after + # we've made sure the user didn't ask for an absolute tolerance only, + # because we don't want to raise errors about the relative tolerance if + # we aren't even going to use it. + relative_tolerance = set_default( + self.rel, self.DEFAULT_RELATIVE_TOLERANCE + ) * abs(self.expected) + + if relative_tolerance < 0: + raise ValueError( + f"relative tolerance can't be negative: {relative_tolerance}" + ) + if math.isnan(relative_tolerance): + raise ValueError("relative tolerance can't be NaN.") + + # Return the larger of the relative and absolute tolerances. + return max(relative_tolerance, absolute_tolerance) + + +class ApproxDecimal(ApproxScalar): + """Perform approximate comparisons where the expected value is a Decimal.""" + + DEFAULT_ABSOLUTE_TOLERANCE = Decimal("1e-12") + DEFAULT_RELATIVE_TOLERANCE = Decimal("1e-6") + + def __repr__(self) -> str: + if isinstance(self.rel, float): + rel = Decimal.from_float(self.rel) + else: + rel = self.rel + + if isinstance(self.abs, float): + abs_ = Decimal.from_float(self.abs) + else: + abs_ = self.abs + + tol_str = "???" + if rel is not None and Decimal("1e-3") <= rel <= Decimal("1e3"): + tol_str = f"{rel:.1e}" + elif abs_ is not None: + tol_str = f"{abs_:.1e}" + + return f"{self.expected} ± {tol_str}" + + +def approx(expected, rel=None, abs=None, nan_ok: bool = False) -> ApproxBase: + """Assert that two numbers (or two ordered sequences of numbers) are equal to each other + within some tolerance. + + Due to the :doc:`python:tutorial/floatingpoint`, numbers that we + would intuitively expect to be equal are not always so:: + + >>> 0.1 + 0.2 == 0.3 + False + + This problem is commonly encountered when writing tests, e.g. when making + sure that floating-point values are what you expect them to be. One way to + deal with this problem is to assert that two floating-point numbers are + equal to within some appropriate tolerance:: + + >>> abs((0.1 + 0.2) - 0.3) < 1e-6 + True + + However, comparisons like this are tedious to write and difficult to + understand. Furthermore, absolute comparisons like the one above are + usually discouraged because there's no tolerance that works well for all + situations. ``1e-6`` is good for numbers around ``1``, but too small for + very big numbers and too big for very small ones. It's better to express + the tolerance as a fraction of the expected value, but relative comparisons + like that are even more difficult to write correctly and concisely. + + The ``approx`` class performs floating-point comparisons using a syntax + that's as intuitive as possible:: + + >>> from pytest import approx + >>> 0.1 + 0.2 == approx(0.3) + True + + The same syntax also works for ordered sequences of numbers:: + + >>> (0.1 + 0.2, 0.2 + 0.4) == approx((0.3, 0.6)) + True + + ``numpy`` arrays:: + + >>> import numpy as np # doctest: +SKIP + >>> np.array([0.1, 0.2]) + np.array([0.2, 0.4]) == approx(np.array([0.3, 0.6])) # doctest: +SKIP + True + + And for a ``numpy`` array against a scalar:: + + >>> import numpy as np # doctest: +SKIP + >>> np.array([0.1, 0.2]) + np.array([0.2, 0.1]) == approx(0.3) # doctest: +SKIP + True + + Only ordered sequences are supported, because ``approx`` needs + to infer the relative position of the sequences without ambiguity. This means + ``sets`` and other unordered sequences are not supported. + + Finally, dictionary *values* can also be compared:: + + >>> {'a': 0.1 + 0.2, 'b': 0.2 + 0.4} == approx({'a': 0.3, 'b': 0.6}) + True + + The comparison will be true if both mappings have the same keys and their + respective values match the expected tolerances. + + **Tolerances** + + By default, ``approx`` considers numbers within a relative tolerance of + ``1e-6`` (i.e. one part in a million) of its expected value to be equal. + This treatment would lead to surprising results if the expected value was + ``0.0``, because nothing but ``0.0`` itself is relatively close to ``0.0``. + To handle this case less surprisingly, ``approx`` also considers numbers + within an absolute tolerance of ``1e-12`` of its expected value to be + equal. Infinity and NaN are special cases. Infinity is only considered + equal to itself, regardless of the relative tolerance. NaN is not + considered equal to anything by default, but you can make it be equal to + itself by setting the ``nan_ok`` argument to True. (This is meant to + facilitate comparing arrays that use NaN to mean "no data".) + + Both the relative and absolute tolerances can be changed by passing + arguments to the ``approx`` constructor:: + + >>> 1.0001 == approx(1) + False + >>> 1.0001 == approx(1, rel=1e-3) + True + >>> 1.0001 == approx(1, abs=1e-3) + True + + If you specify ``abs`` but not ``rel``, the comparison will not consider + the relative tolerance at all. In other words, two numbers that are within + the default relative tolerance of ``1e-6`` will still be considered unequal + if they exceed the specified absolute tolerance. If you specify both + ``abs`` and ``rel``, the numbers will be considered equal if either + tolerance is met:: + + >>> 1 + 1e-8 == approx(1) + True + >>> 1 + 1e-8 == approx(1, abs=1e-12) + False + >>> 1 + 1e-8 == approx(1, rel=1e-6, abs=1e-12) + True + + **Non-numeric types** + + You can also use ``approx`` to compare non-numeric types, or dicts and + sequences containing non-numeric types, in which case it falls back to + strict equality. This can be useful for comparing dicts and sequences that + can contain optional values:: + + >>> {"required": 1.0000005, "optional": None} == approx({"required": 1, "optional": None}) + True + >>> [None, 1.0000005] == approx([None,1]) + True + >>> ["foo", 1.0000005] == approx([None,1]) + False + + If you're thinking about using ``approx``, then you might want to know how + it compares to other good ways of comparing floating-point numbers. All of + these algorithms are based on relative and absolute tolerances and should + agree for the most part, but they do have meaningful differences: + + - ``math.isclose(a, b, rel_tol=1e-9, abs_tol=0.0)``: True if the relative + tolerance is met w.r.t. either ``a`` or ``b`` or if the absolute + tolerance is met. Because the relative tolerance is calculated w.r.t. + both ``a`` and ``b``, this test is symmetric (i.e. neither ``a`` nor + ``b`` is a "reference value"). You have to specify an absolute tolerance + if you want to compare to ``0.0`` because there is no tolerance by + default. More information: :py:func:`math.isclose`. + + - ``numpy.isclose(a, b, rtol=1e-5, atol=1e-8)``: True if the difference + between ``a`` and ``b`` is less that the sum of the relative tolerance + w.r.t. ``b`` and the absolute tolerance. Because the relative tolerance + is only calculated w.r.t. ``b``, this test is asymmetric and you can + think of ``b`` as the reference value. Support for comparing sequences + is provided by :py:func:`numpy.allclose`. More information: + :std:doc:`numpy:reference/generated/numpy.isclose`. + + - ``unittest.TestCase.assertAlmostEqual(a, b)``: True if ``a`` and ``b`` + are within an absolute tolerance of ``1e-7``. No relative tolerance is + considered , so this function is not appropriate for very large or very + small numbers. Also, it's only available in subclasses of ``unittest.TestCase`` + and it's ugly because it doesn't follow PEP8. More information: + :py:meth:`unittest.TestCase.assertAlmostEqual`. + + - ``a == pytest.approx(b, rel=1e-6, abs=1e-12)``: True if the relative + tolerance is met w.r.t. ``b`` or if the absolute tolerance is met. + Because the relative tolerance is only calculated w.r.t. ``b``, this test + is asymmetric and you can think of ``b`` as the reference value. In the + special case that you explicitly specify an absolute tolerance but not a + relative tolerance, only the absolute tolerance is considered. + + .. note:: + + ``approx`` can handle numpy arrays, but we recommend the + specialised test helpers in :std:doc:`numpy:reference/routines.testing` + if you need support for comparisons, NaNs, or ULP-based tolerances. + + To match strings using regex, you can use + `Matches <https://github.com/asottile/re-assert#re_assertmatchespattern-str-args-kwargs>`_ + from the + `re_assert package <https://github.com/asottile/re-assert>`_. + + + .. note:: + + Unlike built-in equality, this function considers + booleans unequal to numeric zero or one. For example:: + + >>> 1 == approx(True) + False + + .. warning:: + + .. versionchanged:: 3.2 + + In order to avoid inconsistent behavior, :py:exc:`TypeError` is + raised for ``>``, ``>=``, ``<`` and ``<=`` comparisons. + The example below illustrates the problem:: + + assert approx(0.1) > 0.1 + 1e-10 # calls approx(0.1).__gt__(0.1 + 1e-10) + assert 0.1 + 1e-10 > approx(0.1) # calls approx(0.1).__lt__(0.1 + 1e-10) + + In the second example one expects ``approx(0.1).__le__(0.1 + 1e-10)`` + to be called. But instead, ``approx(0.1).__lt__(0.1 + 1e-10)`` is used to + comparison. This is because the call hierarchy of rich comparisons + follows a fixed behavior. More information: :py:meth:`object.__ge__` + + .. versionchanged:: 3.7.1 + ``approx`` raises ``TypeError`` when it encounters a dict value or + sequence element of non-numeric type. + + .. versionchanged:: 6.1.0 + ``approx`` falls back to strict equality for non-numeric types instead + of raising ``TypeError``. + """ + # Delegate the comparison to a class that knows how to deal with the type + # of the expected value (e.g. int, float, list, dict, numpy.array, etc). + # + # The primary responsibility of these classes is to implement ``__eq__()`` + # and ``__repr__()``. The former is used to actually check if some + # "actual" value is equivalent to the given expected value within the + # allowed tolerance. The latter is used to show the user the expected + # value and tolerance, in the case that a test failed. + # + # The actual logic for making approximate comparisons can be found in + # ApproxScalar, which is used to compare individual numbers. All of the + # other Approx classes eventually delegate to this class. The ApproxBase + # class provides some convenient methods and overloads, but isn't really + # essential. + + __tracebackhide__ = True + + if isinstance(expected, Decimal): + cls: type[ApproxBase] = ApproxDecimal + elif isinstance(expected, Mapping): + cls = ApproxMapping + elif _is_numpy_array(expected): + expected = _as_numpy_array(expected) + cls = ApproxNumpy + elif _is_sequence_like(expected): + cls = ApproxSequenceLike + elif isinstance(expected, Collection) and not isinstance(expected, str | bytes): + msg = f"pytest.approx() only supports ordered sequences, but got: {expected!r}" + raise TypeError(msg) + else: + cls = ApproxScalar + + return cls(expected, rel, abs, nan_ok) + + +def _is_sequence_like(expected: object) -> bool: + return ( + hasattr(expected, "__getitem__") + and isinstance(expected, Sized) + and not isinstance(expected, str | bytes) + ) + + +def _is_numpy_array(obj: object) -> bool: + """ + Return true if the given object is implicitly convertible to ndarray, + and numpy is already imported. + """ + return _as_numpy_array(obj) is not None + + +def _as_numpy_array(obj: object) -> ndarray | None: + """ + Return an ndarray if the given object is implicitly convertible to ndarray, + and numpy is already imported, otherwise None. + """ + np: Any = sys.modules.get("numpy") + if np is not None: + # avoid infinite recursion on numpy scalars, which have __array__ + if np.isscalar(obj): + return None + elif isinstance(obj, np.ndarray): + return obj + elif hasattr(obj, "__array__") or hasattr("obj", "__array_interface__"): + return np.asarray(obj) + return None diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/raises.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/raises.py new file mode 100644 index 0000000000000000000000000000000000000000..7c246fde2802101ec6029dcdce8bd8322f674a64 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/raises.py @@ -0,0 +1,1517 @@ +from __future__ import annotations + +from abc import ABC +from abc import abstractmethod +import re +from re import Pattern +import sys +from textwrap import indent +from typing import Any +from typing import cast +from typing import final +from typing import Generic +from typing import get_args +from typing import get_origin +from typing import Literal +from typing import overload +from typing import TYPE_CHECKING +import warnings + +from _pytest._code import ExceptionInfo +from _pytest._code.code import stringify_exception +from _pytest.outcomes import fail +from _pytest.warning_types import PytestWarning + + +if TYPE_CHECKING: + from collections.abc import Callable + from collections.abc import Sequence + + # for some reason Sphinx does not play well with 'from types import TracebackType' + import types + from typing import TypeGuard + + from typing_extensions import ParamSpec + from typing_extensions import TypeVar + + P = ParamSpec("P") + + # this conditional definition is because we want to allow a TypeVar default + BaseExcT_co_default = TypeVar( + "BaseExcT_co_default", + bound=BaseException, + default=BaseException, + covariant=True, + ) + + # Use short name because it shows up in docs. + E = TypeVar("E", bound=BaseException, default=BaseException) +else: + from typing import TypeVar + + BaseExcT_co_default = TypeVar( + "BaseExcT_co_default", bound=BaseException, covariant=True + ) + +# RaisesGroup doesn't work with a default. +BaseExcT_co = TypeVar("BaseExcT_co", bound=BaseException, covariant=True) +BaseExcT_1 = TypeVar("BaseExcT_1", bound=BaseException) +BaseExcT_2 = TypeVar("BaseExcT_2", bound=BaseException) +ExcT_1 = TypeVar("ExcT_1", bound=Exception) +ExcT_2 = TypeVar("ExcT_2", bound=Exception) + +if sys.version_info < (3, 11): + from exceptiongroup import BaseExceptionGroup + from exceptiongroup import ExceptionGroup + + +# String patterns default to including the unicode flag. +_REGEX_NO_FLAGS = re.compile(r"").flags + + +# pytest.raises helper +@overload +def raises( + expected_exception: type[E] | tuple[type[E], ...], + *, + match: str | re.Pattern[str] | None = ..., + check: Callable[[E], bool] = ..., +) -> RaisesExc[E]: ... + + +@overload +def raises( + *, + match: str | re.Pattern[str], + # If exception_type is not provided, check() must do any typechecks itself. + check: Callable[[BaseException], bool] = ..., +) -> RaisesExc[BaseException]: ... + + +@overload +def raises(*, check: Callable[[BaseException], bool]) -> RaisesExc[BaseException]: ... + + +@overload +def raises( + expected_exception: type[E] | tuple[type[E], ...], + func: Callable[..., Any], + *args: Any, + **kwargs: Any, +) -> ExceptionInfo[E]: ... + + +def raises( + expected_exception: type[E] | tuple[type[E], ...] | None = None, + *args: Any, + **kwargs: Any, +) -> RaisesExc[BaseException] | ExceptionInfo[E]: + r"""Assert that a code block/function call raises an exception type, or one of its subclasses. + + :param expected_exception: + The expected exception type, or a tuple if one of multiple possible + exception types are expected. Note that subclasses of the passed exceptions + will also match. + + This is not a required parameter, you may opt to only use ``match`` and/or + ``check`` for verifying the raised exception. + + :kwparam str | re.Pattern[str] | None match: + If specified, a string containing a regular expression, + or a regular expression object, that is tested against the string + representation of the exception and its :pep:`678` `__notes__` + using :func:`re.search`. + + To match a literal string that may contain :ref:`special characters + <re-syntax>`, the pattern can first be escaped with :func:`re.escape`. + + (This is only used when ``pytest.raises`` is used as a context manager, + and passed through to the function otherwise. + When using ``pytest.raises`` as a function, you can use: + ``pytest.raises(Exc, func, match="passed on").match("my pattern")``.) + + :kwparam Callable[[BaseException], bool] check: + + .. versionadded:: 8.4 + + If specified, a callable that will be called with the exception as a parameter + after checking the type and the match regex if specified. + If it returns ``True`` it will be considered a match, if not it will + be considered a failed match. + + + Use ``pytest.raises`` as a context manager, which will capture the exception of the given + type, or any of its subclasses:: + + >>> import pytest + >>> with pytest.raises(ZeroDivisionError): + ... 1/0 + + If the code block does not raise the expected exception (:class:`ZeroDivisionError` in the example + above), or no exception at all, the check will fail instead. + + You can also use the keyword argument ``match`` to assert that the + exception matches a text or regex:: + + >>> with pytest.raises(ValueError, match='must be 0 or None'): + ... raise ValueError("value must be 0 or None") + + >>> with pytest.raises(ValueError, match=r'must be \d+$'): + ... raise ValueError("value must be 42") + + The ``match`` argument searches the formatted exception string, which includes any + `PEP-678 <https://peps.python.org/pep-0678/>`__ ``__notes__``: + + >>> with pytest.raises(ValueError, match=r"had a note added"): # doctest: +SKIP + ... e = ValueError("value must be 42") + ... e.add_note("had a note added") + ... raise e + + The ``check`` argument, if provided, must return True when passed the raised exception + for the match to be successful, otherwise an :exc:`AssertionError` is raised. + + >>> import errno + >>> with pytest.raises(OSError, check=lambda e: e.errno == errno.EACCES): + ... raise OSError(errno.EACCES, "no permission to view") + + The context manager produces an :class:`ExceptionInfo` object which can be used to inspect the + details of the captured exception:: + + >>> with pytest.raises(ValueError) as exc_info: + ... raise ValueError("value must be 42") + >>> assert exc_info.type is ValueError + >>> assert exc_info.value.args[0] == "value must be 42" + + .. warning:: + + Given that ``pytest.raises`` matches subclasses, be wary of using it to match :class:`Exception` like this:: + + # Careful, this will catch ANY exception raised. + with pytest.raises(Exception): + some_function() + + Because :class:`Exception` is the base class of almost all exceptions, it is easy for this to hide + real bugs, where the user wrote this expecting a specific exception, but some other exception is being + raised due to a bug introduced during a refactoring. + + Avoid using ``pytest.raises`` to catch :class:`Exception` unless certain that you really want to catch + **any** exception raised. + + .. note:: + + When using ``pytest.raises`` as a context manager, it's worthwhile to + note that normal context manager rules apply and that the exception + raised *must* be the final line in the scope of the context manager. + Lines of code after that, within the scope of the context manager will + not be executed. For example:: + + >>> value = 15 + >>> with pytest.raises(ValueError) as exc_info: + ... if value > 10: + ... raise ValueError("value must be <= 10") + ... assert exc_info.type is ValueError # This will not execute. + + Instead, the following approach must be taken (note the difference in + scope):: + + >>> with pytest.raises(ValueError) as exc_info: + ... if value > 10: + ... raise ValueError("value must be <= 10") + ... + >>> assert exc_info.type is ValueError + + **Expecting exception groups** + + When expecting exceptions wrapped in :exc:`BaseExceptionGroup` or + :exc:`ExceptionGroup`, you should instead use :class:`pytest.RaisesGroup`. + + **Using with** ``pytest.mark.parametrize`` + + When using :ref:`pytest.mark.parametrize ref` + it is possible to parametrize tests such that + some runs raise an exception and others do not. + + See :ref:`parametrizing_conditional_raising` for an example. + + .. seealso:: + + :ref:`assertraises` for more examples and detailed discussion. + + **Legacy form** + + It is possible to specify a callable by passing a to-be-called lambda:: + + >>> raises(ZeroDivisionError, lambda: 1/0) + <ExceptionInfo ...> + + or you can specify an arbitrary callable with arguments:: + + >>> def f(x): return 1/x + ... + >>> raises(ZeroDivisionError, f, 0) + <ExceptionInfo ...> + >>> raises(ZeroDivisionError, f, x=0) + <ExceptionInfo ...> + + The form above is fully supported but discouraged for new code because the + context manager form is regarded as more readable and less error-prone. + + .. note:: + Similar to caught exception objects in Python, explicitly clearing + local references to returned ``ExceptionInfo`` objects can + help the Python interpreter speed up its garbage collection. + + Clearing those references breaks a reference cycle + (``ExceptionInfo`` --> caught exception --> frame stack raising + the exception --> current frame stack --> local variables --> + ``ExceptionInfo``) which makes Python keep all objects referenced + from that cycle (including all local variables in the current + frame) alive until the next cyclic garbage collection run. + More detailed information can be found in the official Python + documentation for :ref:`the try statement <python:try>`. + """ + __tracebackhide__ = True + + if not args: + if set(kwargs) - {"match", "check", "expected_exception"}: + msg = "Unexpected keyword arguments passed to pytest.raises: " + msg += ", ".join(sorted(kwargs)) + msg += "\nUse context-manager form instead?" + raise TypeError(msg) + + if expected_exception is None: + return RaisesExc(**kwargs) + return RaisesExc(expected_exception, **kwargs) + + if not expected_exception: + raise ValueError( + f"Expected an exception type or a tuple of exception types, but got `{expected_exception!r}`. " + f"Raising exceptions is already understood as failing the test, so you don't need " + f"any special code to say 'this should never raise an exception'." + ) + func = args[0] + if not callable(func): + raise TypeError(f"{func!r} object (type: {type(func)}) must be callable") + with RaisesExc(expected_exception) as excinfo: + func(*args[1:], **kwargs) + try: + return excinfo + finally: + del excinfo + + +# note: RaisesExc/RaisesGroup uses fail() internally, so this alias +# indicates (to [internal] plugins?) that `pytest.raises` will +# raise `_pytest.outcomes.Failed`, where +# `outcomes.Failed is outcomes.fail.Exception is raises.Exception` +# note: this is *not* the same as `_pytest.main.Failed` +# note: mypy does not recognize this attribute, and it's not possible +# to use a protocol/decorator like the others in outcomes due to +# https://github.com/python/mypy/issues/18715 +raises.Exception = fail.Exception # type: ignore[attr-defined] + + +def _match_pattern(match: Pattern[str]) -> str | Pattern[str]: + """Helper function to remove redundant `re.compile` calls when printing regex""" + return match.pattern if match.flags == _REGEX_NO_FLAGS else match + + +def repr_callable(fun: Callable[[BaseExcT_1], bool]) -> str: + """Get the repr of a ``check`` parameter. + + Split out so it can be monkeypatched (e.g. by hypothesis) + """ + return repr(fun) + + +def backquote(s: str) -> str: + return "`" + s + "`" + + +def _exception_type_name( + e: type[BaseException] | tuple[type[BaseException], ...], +) -> str: + if isinstance(e, type): + return e.__name__ + if len(e) == 1: + return e[0].__name__ + return "(" + ", ".join(ee.__name__ for ee in e) + ")" + + +def _check_raw_type( + expected_type: type[BaseException] | tuple[type[BaseException], ...] | None, + exception: BaseException, +) -> str | None: + if expected_type is None or expected_type == (): + return None + + if not isinstance( + exception, + expected_type, + ): + actual_type_str = backquote(_exception_type_name(type(exception)) + "()") + expected_type_str = backquote(_exception_type_name(expected_type)) + if ( + isinstance(exception, BaseExceptionGroup) + and isinstance(expected_type, type) + and not issubclass(expected_type, BaseExceptionGroup) + ): + return f"Unexpected nested {actual_type_str}, expected {expected_type_str}" + return f"{actual_type_str} is not an instance of {expected_type_str}" + return None + + +def is_fully_escaped(s: str) -> bool: + # we know we won't compile with re.VERBOSE, so whitespace doesn't need to be escaped + metacharacters = "{}()+.*?^$[]" + return not any( + c in metacharacters and (i == 0 or s[i - 1] != "\\") for (i, c) in enumerate(s) + ) + + +def unescape(s: str) -> str: + return re.sub(r"\\([{}()+-.*?^$\[\]\s\\])", r"\1", s) + + +# These classes conceptually differ from ExceptionInfo in that ExceptionInfo is tied, and +# constructed from, a particular exception - whereas these are constructed with expected +# exceptions, and later allow matching towards particular exceptions. +# But there's overlap in `ExceptionInfo.match` and `AbstractRaises._check_match`, as with +# `AbstractRaises.matches` and `ExceptionInfo.errisinstance`+`ExceptionInfo.group_contains`. +# The interaction between these classes should perhaps be improved. +class AbstractRaises(ABC, Generic[BaseExcT_co]): + """ABC with common functionality shared between RaisesExc and RaisesGroup""" + + def __init__( + self, + *, + match: str | Pattern[str] | None, + check: Callable[[BaseExcT_co], bool] | None, + ) -> None: + if isinstance(match, str): + # juggle error in order to avoid context to fail (necessary?) + re_error = None + try: + self.match: Pattern[str] | None = re.compile(match) + except re.error as e: + re_error = e + if re_error is not None: + fail(f"Invalid regex pattern provided to 'match': {re_error}") + if match == "": + warnings.warn( + PytestWarning( + "matching against an empty string will *always* pass. If you want " + "to check for an empty message you need to pass '^$'. If you don't " + "want to match you should pass `None` or leave out the parameter." + ), + stacklevel=2, + ) + else: + self.match = match + + # check if this is a fully escaped regex and has ^$ to match fully + # in which case we can do a proper diff on error + self.rawmatch: str | None = None + if isinstance(match, str) or ( + isinstance(match, Pattern) and match.flags == _REGEX_NO_FLAGS + ): + if isinstance(match, Pattern): + match = match.pattern + if ( + match + and match[0] == "^" + and match[-1] == "$" + and is_fully_escaped(match[1:-1]) + ): + self.rawmatch = unescape(match[1:-1]) + + self.check = check + self._fail_reason: str | None = None + + # used to suppress repeated printing of `repr(self.check)` + self._nested: bool = False + + # set in self._parse_exc + self.is_baseexception = False + + def _parse_exc( + self, exc: type[BaseExcT_1] | types.GenericAlias, expected: str + ) -> type[BaseExcT_1]: + if isinstance(exc, type) and issubclass(exc, BaseException): + if not issubclass(exc, Exception): + self.is_baseexception = True + return exc + # because RaisesGroup does not support variable number of exceptions there's + # still a use for RaisesExc(ExceptionGroup[Exception]). + origin_exc: type[BaseException] | None = get_origin(exc) + if origin_exc and issubclass(origin_exc, BaseExceptionGroup): + exc_type = get_args(exc)[0] + if ( + issubclass(origin_exc, ExceptionGroup) and exc_type in (Exception, Any) + ) or ( + issubclass(origin_exc, BaseExceptionGroup) + and exc_type in (BaseException, Any) + ): + if not issubclass(origin_exc, ExceptionGroup): + self.is_baseexception = True + return cast(type[BaseExcT_1], origin_exc) + else: + raise ValueError( + f"Only `ExceptionGroup[Exception]` or `BaseExceptionGroup[BaseException]` " + f"are accepted as generic types but got `{exc}`. " + f"As `raises` will catch all instances of the specified group regardless of the " + f"generic argument specific nested exceptions has to be checked " + f"with `RaisesGroup`." + ) + # unclear if the Type/ValueError distinction is even helpful here + msg = f"Expected {expected}, but got " + if isinstance(exc, type): # type: ignore[unreachable] + raise ValueError(msg + f"{exc.__name__!r}") + if isinstance(exc, BaseException): # type: ignore[unreachable] + raise TypeError(msg + f"an exception instance: {type(exc).__name__}") + raise TypeError(msg + repr(type(exc).__name__)) + + @property + def fail_reason(self) -> str | None: + """Set after a call to :meth:`matches` to give a human-readable reason for why the match failed. + When used as a context manager the string will be printed as the reason for the + test failing.""" + return self._fail_reason + + def _check_check( + self: AbstractRaises[BaseExcT_1], + exception: BaseExcT_1, + ) -> bool: + if self.check is None: + return True + + if self.check(exception): + return True + + check_repr = "" if self._nested else " " + repr_callable(self.check) + self._fail_reason = f"check{check_repr} did not return True" + return False + + # TODO: harmonize with ExceptionInfo.match + def _check_match(self, e: BaseException) -> bool: + if self.match is None or re.search( + self.match, + stringified_exception := stringify_exception( + e, include_subexception_msg=False + ), + ): + return True + + # if we're matching a group, make sure we're explicit to reduce confusion + # if they're trying to match an exception contained within the group + maybe_specify_type = ( + f" the `{_exception_type_name(type(e))}()`" + if isinstance(e, BaseExceptionGroup) + else "" + ) + if isinstance(self.rawmatch, str): + # TODO: it instructs to use `-v` to print leading text, but that doesn't work + # I also don't know if this is the proper entry point, or tool to use at all + from _pytest.assertion.util import _diff_text + from _pytest.assertion.util import dummy_highlighter + + diff = _diff_text(self.rawmatch, stringified_exception, dummy_highlighter) + self._fail_reason = ("\n" if diff[0][0] == "-" else "") + "\n".join(diff) + return False + + self._fail_reason = ( + f"Regex pattern did not match{maybe_specify_type}.\n" + f" Expected regex: {_match_pattern(self.match)!r}\n" + f" Actual message: {stringified_exception!r}" + ) + if _match_pattern(self.match) == stringified_exception: + self._fail_reason += "\n Did you mean to `re.escape()` the regex?" + return False + + @abstractmethod + def matches( + self: AbstractRaises[BaseExcT_1], exception: BaseException + ) -> TypeGuard[BaseExcT_1]: + """Check if an exception matches the requirements of this AbstractRaises. + If it fails, :meth:`AbstractRaises.fail_reason` should be set. + """ + + +@final +class RaisesExc(AbstractRaises[BaseExcT_co_default]): + """ + .. versionadded:: 8.4 + + + This is the class constructed when calling :func:`pytest.raises`, but may be used + directly as a helper class with :class:`RaisesGroup` when you want to specify + requirements on sub-exceptions. + + You don't need this if you only want to specify the type, since :class:`RaisesGroup` + accepts ``type[BaseException]``. + + :param type[BaseException] | tuple[type[BaseException]] | None expected_exception: + The expected type, or one of several possible types. + May be ``None`` in order to only make use of ``match`` and/or ``check`` + + The type is checked with :func:`isinstance`, and does not need to be an exact match. + If that is wanted you can use the ``check`` parameter. + + :kwparam str | Pattern[str] match: + A regex to match. + + :kwparam Callable[[BaseException], bool] check: + If specified, a callable that will be called with the exception as a parameter + after checking the type and the match regex if specified. + If it returns ``True`` it will be considered a match, if not it will + be considered a failed match. + + :meth:`RaisesExc.matches` can also be used standalone to check individual exceptions. + + Examples:: + + with RaisesGroup(RaisesExc(ValueError, match="string")) + ... + with RaisesGroup(RaisesExc(check=lambda x: x.args == (3, "hello"))): + ... + with RaisesGroup(RaisesExc(check=lambda x: type(x) is ValueError)): + ... + """ + + # Trio bundled hypothesis monkeypatching, we will probably instead assume that + # hypothesis will handle that in their pytest plugin by the time this is released. + # Alternatively we could add a version of get_pretty_function_description ourselves + # https://github.com/HypothesisWorks/hypothesis/blob/8ced2f59f5c7bea3344e35d2d53e1f8f8eb9fcd8/hypothesis-python/src/hypothesis/internal/reflection.py#L439 + + # At least one of the three parameters must be passed. + @overload + def __init__( + self, + expected_exception: ( + type[BaseExcT_co_default] | tuple[type[BaseExcT_co_default], ...] + ), + /, + *, + match: str | Pattern[str] | None = ..., + check: Callable[[BaseExcT_co_default], bool] | None = ..., + ) -> None: ... + + @overload + def __init__( + self: RaisesExc[BaseException], # Give E a value. + /, + *, + match: str | Pattern[str] | None, + # If exception_type is not provided, check() must do any typechecks itself. + check: Callable[[BaseException], bool] | None = ..., + ) -> None: ... + + @overload + def __init__(self, /, *, check: Callable[[BaseException], bool]) -> None: ... + + def __init__( + self, + expected_exception: ( + type[BaseExcT_co_default] | tuple[type[BaseExcT_co_default], ...] | None + ) = None, + /, + *, + match: str | Pattern[str] | None = None, + check: Callable[[BaseExcT_co_default], bool] | None = None, + ): + super().__init__(match=match, check=check) + if isinstance(expected_exception, tuple): + expected_exceptions = expected_exception + elif expected_exception is None: + expected_exceptions = () + else: + expected_exceptions = (expected_exception,) + + if (expected_exceptions == ()) and match is None and check is None: + raise ValueError("You must specify at least one parameter to match on.") + + self.expected_exceptions = tuple( + self._parse_exc(e, expected="a BaseException type") + for e in expected_exceptions + ) + + self._just_propagate = False + + def matches( + self, + exception: BaseException | None, + ) -> TypeGuard[BaseExcT_co_default]: + """Check if an exception matches the requirements of this :class:`RaisesExc`. + If it fails, :attr:`RaisesExc.fail_reason` will be set. + + Examples:: + + assert RaisesExc(ValueError).matches(my_exception): + # is equivalent to + assert isinstance(my_exception, ValueError) + + # this can be useful when checking e.g. the ``__cause__`` of an exception. + with pytest.raises(ValueError) as excinfo: + ... + assert RaisesExc(SyntaxError, match="foo").matches(excinfo.value.__cause__) + # above line is equivalent to + assert isinstance(excinfo.value.__cause__, SyntaxError) + assert re.search("foo", str(excinfo.value.__cause__) + + """ + self._just_propagate = False + if exception is None: + self._fail_reason = "exception is None" + return False + if not self._check_type(exception): + self._just_propagate = True + return False + + if not self._check_match(exception): + return False + + return self._check_check(exception) + + def __repr__(self) -> str: + parameters = [] + if self.expected_exceptions: + parameters.append(_exception_type_name(self.expected_exceptions)) + if self.match is not None: + # If no flags were specified, discard the redundant re.compile() here. + parameters.append( + f"match={_match_pattern(self.match)!r}", + ) + if self.check is not None: + parameters.append(f"check={repr_callable(self.check)}") + return f"RaisesExc({', '.join(parameters)})" + + def _check_type(self, exception: BaseException) -> TypeGuard[BaseExcT_co_default]: + self._fail_reason = _check_raw_type(self.expected_exceptions, exception) + return self._fail_reason is None + + def __enter__(self) -> ExceptionInfo[BaseExcT_co_default]: + self.excinfo: ExceptionInfo[BaseExcT_co_default] = ExceptionInfo.for_later() + return self.excinfo + + # TODO: move common code into superclass + def __exit__( + self, + exc_type: type[BaseException] | None, + exc_val: BaseException | None, + exc_tb: types.TracebackType | None, + ) -> bool: + __tracebackhide__ = True + if exc_type is None: + if not self.expected_exceptions: + fail("DID NOT RAISE any exception") + if len(self.expected_exceptions) > 1: + fail(f"DID NOT RAISE any of {self.expected_exceptions!r}") + + fail(f"DID NOT RAISE {self.expected_exceptions[0]!r}") + + assert self.excinfo is not None, ( + "Internal error - should have been constructed in __enter__" + ) + + if not self.matches(exc_val): + if self._just_propagate: + return False + raise AssertionError(self._fail_reason) + + # Cast to narrow the exception type now that it's verified.... + # even though the TypeGuard in self.matches should be narrowing + exc_info = cast( + "tuple[type[BaseExcT_co_default], BaseExcT_co_default, types.TracebackType]", + (exc_type, exc_val, exc_tb), + ) + self.excinfo.fill_unfilled(exc_info) + return True + + +@final +class RaisesGroup(AbstractRaises[BaseExceptionGroup[BaseExcT_co]]): + """ + .. versionadded:: 8.4 + + Contextmanager for checking for an expected :exc:`ExceptionGroup`. + This works similar to :func:`pytest.raises`, but allows for specifying the structure of an :exc:`ExceptionGroup`. + :meth:`ExceptionInfo.group_contains` also tries to handle exception groups, + but it is very bad at checking that you *didn't* get unexpected exceptions. + + The catching behaviour differs from :ref:`except* <except_star>`, being much + stricter about the structure by default. + By using ``allow_unwrapped=True`` and ``flatten_subgroups=True`` you can match + :ref:`except* <except_star>` fully when expecting a single exception. + + :param args: + Any number of exception types, :class:`RaisesGroup` or :class:`RaisesExc` + to specify the exceptions contained in this exception. + All specified exceptions must be present in the raised group, *and no others*. + + If you expect a variable number of exceptions you need to use + :func:`pytest.raises(ExceptionGroup) <pytest.raises>` and manually check + the contained exceptions. Consider making use of :meth:`RaisesExc.matches`. + + It does not care about the order of the exceptions, so + ``RaisesGroup(ValueError, TypeError)`` + is equivalent to + ``RaisesGroup(TypeError, ValueError)``. + :kwparam str | re.Pattern[str] | None match: + If specified, a string containing a regular expression, + or a regular expression object, that is tested against the string + representation of the exception group and its :pep:`678` `__notes__` + using :func:`re.search`. + + To match a literal string that may contain :ref:`special characters + <re-syntax>`, the pattern can first be escaped with :func:`re.escape`. + + Note that " (5 subgroups)" will be stripped from the ``repr`` before matching. + :kwparam Callable[[E], bool] check: + If specified, a callable that will be called with the group as a parameter + after successfully matching the expected exceptions. If it returns ``True`` + it will be considered a match, if not it will be considered a failed match. + :kwparam bool allow_unwrapped: + If expecting a single exception or :class:`RaisesExc` it will match even + if the exception is not inside an exceptiongroup. + + Using this together with ``match``, ``check`` or expecting multiple exceptions + will raise an error. + :kwparam bool flatten_subgroups: + "flatten" any groups inside the raised exception group, extracting all exceptions + inside any nested groups, before matching. Without this it expects you to + fully specify the nesting structure by passing :class:`RaisesGroup` as expected + parameter. + + Examples:: + + with RaisesGroup(ValueError): + raise ExceptionGroup("", (ValueError(),)) + # match + with RaisesGroup( + ValueError, + ValueError, + RaisesExc(TypeError, match="^expected int$"), + match="^my group$", + ): + raise ExceptionGroup( + "my group", + [ + ValueError(), + TypeError("expected int"), + ValueError(), + ], + ) + # check + with RaisesGroup( + KeyboardInterrupt, + match="^hello$", + check=lambda x: isinstance(x.__cause__, ValueError), + ): + raise BaseExceptionGroup("hello", [KeyboardInterrupt()]) from ValueError + # nested groups + with RaisesGroup(RaisesGroup(ValueError)): + raise ExceptionGroup("", (ExceptionGroup("", (ValueError(),)),)) + + # flatten_subgroups + with RaisesGroup(ValueError, flatten_subgroups=True): + raise ExceptionGroup("", (ExceptionGroup("", (ValueError(),)),)) + + # allow_unwrapped + with RaisesGroup(ValueError, allow_unwrapped=True): + raise ValueError + + + :meth:`RaisesGroup.matches` can also be used directly to check a standalone exception group. + + + The matching algorithm is greedy, which means cases such as this may fail:: + + with RaisesGroup(ValueError, RaisesExc(ValueError, match="hello")): + raise ExceptionGroup("", (ValueError("hello"), ValueError("goodbye"))) + + even though it generally does not care about the order of the exceptions in the group. + To avoid the above you should specify the first :exc:`ValueError` with a :class:`RaisesExc` as well. + + .. note:: + When raised exceptions don't match the expected ones, you'll get a detailed error + message explaining why. This includes ``repr(check)`` if set, which in Python can be + overly verbose, showing memory locations etc etc. + + If installed and imported (in e.g. ``conftest.py``), the ``hypothesis`` library will + monkeypatch this output to provide shorter & more readable repr's. + """ + + # allow_unwrapped=True requires: singular exception, exception not being + # RaisesGroup instance, match is None, check is None + @overload + def __init__( + self, + expected_exception: type[BaseExcT_co] | RaisesExc[BaseExcT_co], + /, + *, + allow_unwrapped: Literal[True], + flatten_subgroups: bool = False, + ) -> None: ... + + # flatten_subgroups = True also requires no nested RaisesGroup + @overload + def __init__( + self, + expected_exception: type[BaseExcT_co] | RaisesExc[BaseExcT_co], + /, + *other_exceptions: type[BaseExcT_co] | RaisesExc[BaseExcT_co], + flatten_subgroups: Literal[True], + match: str | Pattern[str] | None = None, + check: Callable[[BaseExceptionGroup[BaseExcT_co]], bool] | None = None, + ) -> None: ... + + # simplify the typevars if possible (the following 3 are equivalent but go simpler->complicated) + # ... the first handles RaisesGroup[ValueError], the second RaisesGroup[ExceptionGroup[ValueError]], + # the third RaisesGroup[ValueError | ExceptionGroup[ValueError]]. + # ... otherwise, we will get results like RaisesGroup[ValueError | ExceptionGroup[Never]] (I think) + # (technically correct but misleading) + @overload + def __init__( + self: RaisesGroup[ExcT_1], + expected_exception: type[ExcT_1] | RaisesExc[ExcT_1], + /, + *other_exceptions: type[ExcT_1] | RaisesExc[ExcT_1], + match: str | Pattern[str] | None = None, + check: Callable[[ExceptionGroup[ExcT_1]], bool] | None = None, + ) -> None: ... + + @overload + def __init__( + self: RaisesGroup[ExceptionGroup[ExcT_2]], + expected_exception: RaisesGroup[ExcT_2], + /, + *other_exceptions: RaisesGroup[ExcT_2], + match: str | Pattern[str] | None = None, + check: Callable[[ExceptionGroup[ExceptionGroup[ExcT_2]]], bool] | None = None, + ) -> None: ... + + @overload + def __init__( + self: RaisesGroup[ExcT_1 | ExceptionGroup[ExcT_2]], + expected_exception: type[ExcT_1] | RaisesExc[ExcT_1] | RaisesGroup[ExcT_2], + /, + *other_exceptions: type[ExcT_1] | RaisesExc[ExcT_1] | RaisesGroup[ExcT_2], + match: str | Pattern[str] | None = None, + check: ( + Callable[[ExceptionGroup[ExcT_1 | ExceptionGroup[ExcT_2]]], bool] | None + ) = None, + ) -> None: ... + + # same as the above 3 but handling BaseException + @overload + def __init__( + self: RaisesGroup[BaseExcT_1], + expected_exception: type[BaseExcT_1] | RaisesExc[BaseExcT_1], + /, + *other_exceptions: type[BaseExcT_1] | RaisesExc[BaseExcT_1], + match: str | Pattern[str] | None = None, + check: Callable[[BaseExceptionGroup[BaseExcT_1]], bool] | None = None, + ) -> None: ... + + @overload + def __init__( + self: RaisesGroup[BaseExceptionGroup[BaseExcT_2]], + expected_exception: RaisesGroup[BaseExcT_2], + /, + *other_exceptions: RaisesGroup[BaseExcT_2], + match: str | Pattern[str] | None = None, + check: ( + Callable[[BaseExceptionGroup[BaseExceptionGroup[BaseExcT_2]]], bool] | None + ) = None, + ) -> None: ... + + @overload + def __init__( + self: RaisesGroup[BaseExcT_1 | BaseExceptionGroup[BaseExcT_2]], + expected_exception: type[BaseExcT_1] + | RaisesExc[BaseExcT_1] + | RaisesGroup[BaseExcT_2], + /, + *other_exceptions: type[BaseExcT_1] + | RaisesExc[BaseExcT_1] + | RaisesGroup[BaseExcT_2], + match: str | Pattern[str] | None = None, + check: ( + Callable[ + [BaseExceptionGroup[BaseExcT_1 | BaseExceptionGroup[BaseExcT_2]]], + bool, + ] + | None + ) = None, + ) -> None: ... + + def __init__( + self: RaisesGroup[ExcT_1 | BaseExcT_1 | BaseExceptionGroup[BaseExcT_2]], + expected_exception: type[BaseExcT_1] + | RaisesExc[BaseExcT_1] + | RaisesGroup[BaseExcT_2], + /, + *other_exceptions: type[BaseExcT_1] + | RaisesExc[BaseExcT_1] + | RaisesGroup[BaseExcT_2], + allow_unwrapped: bool = False, + flatten_subgroups: bool = False, + match: str | Pattern[str] | None = None, + check: ( + Callable[[BaseExceptionGroup[BaseExcT_1]], bool] + | Callable[[ExceptionGroup[ExcT_1]], bool] + | None + ) = None, + ): + # The type hint on the `self` and `check` parameters uses different formats + # that are *very* hard to reconcile while adhering to the overloads, so we cast + # it to avoid an error when passing it to super().__init__ + check = cast( + "Callable[[BaseExceptionGroup[ExcT_1|BaseExcT_1|BaseExceptionGroup[BaseExcT_2]]], bool]", + check, + ) + super().__init__(match=match, check=check) + self.allow_unwrapped = allow_unwrapped + self.flatten_subgroups: bool = flatten_subgroups + self.is_baseexception = False + + if allow_unwrapped and other_exceptions: + raise ValueError( + "You cannot specify multiple exceptions with `allow_unwrapped=True.`" + " If you want to match one of multiple possible exceptions you should" + " use a `RaisesExc`." + " E.g. `RaisesExc(check=lambda e: isinstance(e, (...)))`", + ) + if allow_unwrapped and isinstance(expected_exception, RaisesGroup): + raise ValueError( + "`allow_unwrapped=True` has no effect when expecting a `RaisesGroup`." + " You might want it in the expected `RaisesGroup`, or" + " `flatten_subgroups=True` if you don't care about the structure.", + ) + if allow_unwrapped and (match is not None or check is not None): + raise ValueError( + "`allow_unwrapped=True` bypasses the `match` and `check` parameters" + " if the exception is unwrapped. If you intended to match/check the" + " exception you should use a `RaisesExc` object. If you want to match/check" + " the exceptiongroup when the exception *is* wrapped you need to" + " do e.g. `if isinstance(exc.value, ExceptionGroup):" + " assert RaisesGroup(...).matches(exc.value)` afterwards.", + ) + + self.expected_exceptions: tuple[ + type[BaseExcT_co] | RaisesExc[BaseExcT_co] | RaisesGroup[BaseException], ... + ] = tuple( + self._parse_excgroup(e, "a BaseException type, RaisesExc, or RaisesGroup") + for e in ( + expected_exception, + *other_exceptions, + ) + ) + + def _parse_excgroup( + self, + exc: ( + type[BaseExcT_co] + | types.GenericAlias + | RaisesExc[BaseExcT_1] + | RaisesGroup[BaseExcT_2] + ), + expected: str, + ) -> type[BaseExcT_co] | RaisesExc[BaseExcT_1] | RaisesGroup[BaseExcT_2]: + # verify exception type and set `self.is_baseexception` + if isinstance(exc, RaisesGroup): + if self.flatten_subgroups: + raise ValueError( + "You cannot specify a nested structure inside a RaisesGroup with" + " `flatten_subgroups=True`. The parameter will flatten subgroups" + " in the raised exceptiongroup before matching, which would never" + " match a nested structure.", + ) + self.is_baseexception |= exc.is_baseexception + exc._nested = True + return exc + elif isinstance(exc, RaisesExc): + self.is_baseexception |= exc.is_baseexception + exc._nested = True + return exc + elif isinstance(exc, tuple): + raise TypeError( + f"Expected {expected}, but got {type(exc).__name__!r}.\n" + "RaisesGroup does not support tuples of exception types when expecting one of " + "several possible exception types like RaisesExc.\n" + "If you meant to expect a group with multiple exceptions, list them as separate arguments." + ) + else: + return super()._parse_exc(exc, expected) + + @overload + def __enter__( + self: RaisesGroup[ExcT_1], + ) -> ExceptionInfo[ExceptionGroup[ExcT_1]]: ... + @overload + def __enter__( + self: RaisesGroup[BaseExcT_1], + ) -> ExceptionInfo[BaseExceptionGroup[BaseExcT_1]]: ... + + def __enter__(self) -> ExceptionInfo[BaseExceptionGroup[BaseException]]: + self.excinfo: ExceptionInfo[BaseExceptionGroup[BaseExcT_co]] = ( + ExceptionInfo.for_later() + ) + return self.excinfo + + def __repr__(self) -> str: + reqs = [ + e.__name__ if isinstance(e, type) else repr(e) + for e in self.expected_exceptions + ] + if self.allow_unwrapped: + reqs.append(f"allow_unwrapped={self.allow_unwrapped}") + if self.flatten_subgroups: + reqs.append(f"flatten_subgroups={self.flatten_subgroups}") + if self.match is not None: + # If no flags were specified, discard the redundant re.compile() here. + reqs.append(f"match={_match_pattern(self.match)!r}") + if self.check is not None: + reqs.append(f"check={repr_callable(self.check)}") + return f"RaisesGroup({', '.join(reqs)})" + + def _unroll_exceptions( + self, + exceptions: Sequence[BaseException], + ) -> Sequence[BaseException]: + """Used if `flatten_subgroups=True`.""" + res: list[BaseException] = [] + for exc in exceptions: + if isinstance(exc, BaseExceptionGroup): + res.extend(self._unroll_exceptions(exc.exceptions)) + + else: + res.append(exc) + return res + + @overload + def matches( + self: RaisesGroup[ExcT_1], + exception: BaseException | None, + ) -> TypeGuard[ExceptionGroup[ExcT_1]]: ... + @overload + def matches( + self: RaisesGroup[BaseExcT_1], + exception: BaseException | None, + ) -> TypeGuard[BaseExceptionGroup[BaseExcT_1]]: ... + + def matches( + self, + exception: BaseException | None, + ) -> bool: + """Check if an exception matches the requirements of this RaisesGroup. + If it fails, `RaisesGroup.fail_reason` will be set. + + Example:: + + with pytest.raises(TypeError) as excinfo: + ... + assert RaisesGroup(ValueError).matches(excinfo.value.__cause__) + # the above line is equivalent to + myexc = excinfo.value.__cause + assert isinstance(myexc, BaseExceptionGroup) + assert len(myexc.exceptions) == 1 + assert isinstance(myexc.exceptions[0], ValueError) + """ + self._fail_reason = None + if exception is None: + self._fail_reason = "exception is None" + return False + if not isinstance(exception, BaseExceptionGroup): + # we opt to only print type of the exception here, as the repr would + # likely be quite long + not_group_msg = f"`{type(exception).__name__}()` is not an exception group" + if len(self.expected_exceptions) > 1: + self._fail_reason = not_group_msg + return False + # if we have 1 expected exception, check if it would work even if + # allow_unwrapped is not set + res = self._check_expected(self.expected_exceptions[0], exception) + if res is None and self.allow_unwrapped: + return True + + if res is None: + self._fail_reason = ( + f"{not_group_msg}, but would match with `allow_unwrapped=True`" + ) + elif self.allow_unwrapped: + self._fail_reason = res + else: + self._fail_reason = not_group_msg + return False + + actual_exceptions: Sequence[BaseException] = exception.exceptions + if self.flatten_subgroups: + actual_exceptions = self._unroll_exceptions(actual_exceptions) + + if not self._check_match(exception): + self._fail_reason = cast(str, self._fail_reason) + old_reason = self._fail_reason + if ( + len(actual_exceptions) == len(self.expected_exceptions) == 1 + and isinstance(expected := self.expected_exceptions[0], type) + and isinstance(actual := actual_exceptions[0], expected) + and self._check_match(actual) + ): + assert self.match is not None, "can't be None if _check_match failed" + assert self._fail_reason is old_reason is not None + self._fail_reason += ( + f"\n" + f" but matched the expected `{self._repr_expected(expected)}`.\n" + f" You might want " + f"`RaisesGroup(RaisesExc({expected.__name__}, match={_match_pattern(self.match)!r}))`" + ) + else: + self._fail_reason = old_reason + return False + + # do the full check on expected exceptions + if not self._check_exceptions( + exception, + actual_exceptions, + ): + self._fail_reason = cast(str, self._fail_reason) + assert self._fail_reason is not None + old_reason = self._fail_reason + # if we're not expecting a nested structure, and there is one, do a second + # pass where we try flattening it + if ( + not self.flatten_subgroups + and not any( + isinstance(e, RaisesGroup) for e in self.expected_exceptions + ) + and any(isinstance(e, BaseExceptionGroup) for e in actual_exceptions) + and self._check_exceptions( + exception, + self._unroll_exceptions(exception.exceptions), + ) + ): + # only indent if it's a single-line reason. In a multi-line there's already + # indented lines that this does not belong to. + indent = " " if "\n" not in self._fail_reason else "" + self._fail_reason = ( + old_reason + + f"\n{indent}Did you mean to use `flatten_subgroups=True`?" + ) + else: + self._fail_reason = old_reason + return False + + # Only run `self.check` once we know `exception` is of the correct type. + if not self._check_check(exception): + reason = ( + cast(str, self._fail_reason) + f" on the {type(exception).__name__}" + ) + if ( + len(actual_exceptions) == len(self.expected_exceptions) == 1 + and isinstance(expected := self.expected_exceptions[0], type) + # we explicitly break typing here :) + and self._check_check(actual_exceptions[0]) # type: ignore[arg-type] + ): + self._fail_reason = reason + ( + f", but did return True for the expected {self._repr_expected(expected)}." + f" You might want RaisesGroup(RaisesExc({expected.__name__}, check=<...>))" + ) + else: + self._fail_reason = reason + return False + + return True + + @staticmethod + def _check_expected( + expected_type: ( + type[BaseException] | RaisesExc[BaseException] | RaisesGroup[BaseException] + ), + exception: BaseException, + ) -> str | None: + """Helper method for `RaisesGroup.matches` and `RaisesGroup._check_exceptions` + to check one of potentially several expected exceptions.""" + if isinstance(expected_type, type): + return _check_raw_type(expected_type, exception) + res = expected_type.matches(exception) + if res: + return None + assert expected_type.fail_reason is not None + if expected_type.fail_reason.startswith("\n"): + return f"\n{expected_type!r}: {indent(expected_type.fail_reason, ' ')}" + return f"{expected_type!r}: {expected_type.fail_reason}" + + @staticmethod + def _repr_expected(e: type[BaseException] | AbstractRaises[BaseException]) -> str: + """Get the repr of an expected type/RaisesExc/RaisesGroup, but we only want + the name if it's a type""" + if isinstance(e, type): + return _exception_type_name(e) + return repr(e) + + @overload + def _check_exceptions( + self: RaisesGroup[ExcT_1], + _exception: Exception, + actual_exceptions: Sequence[Exception], + ) -> TypeGuard[ExceptionGroup[ExcT_1]]: ... + @overload + def _check_exceptions( + self: RaisesGroup[BaseExcT_1], + _exception: BaseException, + actual_exceptions: Sequence[BaseException], + ) -> TypeGuard[BaseExceptionGroup[BaseExcT_1]]: ... + + def _check_exceptions( + self, + _exception: BaseException, + actual_exceptions: Sequence[BaseException], + ) -> bool: + """Helper method for RaisesGroup.matches that attempts to pair up expected and actual exceptions""" + # The _exception parameter is not used, but necessary for the TypeGuard + + # full table with all results + results = ResultHolder(self.expected_exceptions, actual_exceptions) + + # (indexes of) raised exceptions that haven't (yet) found an expected + remaining_actual = list(range(len(actual_exceptions))) + # (indexes of) expected exceptions that haven't found a matching raised + failed_expected: list[int] = [] + # successful greedy matches + matches: dict[int, int] = {} + + # loop over expected exceptions first to get a more predictable result + for i_exp, expected in enumerate(self.expected_exceptions): + for i_rem in remaining_actual: + res = self._check_expected(expected, actual_exceptions[i_rem]) + results.set_result(i_exp, i_rem, res) + if res is None: + remaining_actual.remove(i_rem) + matches[i_exp] = i_rem + break + else: + failed_expected.append(i_exp) + + # All exceptions matched up successfully + if not remaining_actual and not failed_expected: + return True + + # in case of a single expected and single raised we simplify the output + if 1 == len(actual_exceptions) == len(self.expected_exceptions): + assert not matches + self._fail_reason = res + return False + + # The test case is failing, so we can do a slow and exhaustive check to find + # duplicate matches etc that will be helpful in debugging + for i_exp, expected in enumerate(self.expected_exceptions): + for i_actual, actual in enumerate(actual_exceptions): + if results.has_result(i_exp, i_actual): + continue + results.set_result( + i_exp, i_actual, self._check_expected(expected, actual) + ) + + successful_str = ( + f"{len(matches)} matched exception{'s' if len(matches) > 1 else ''}. " + if matches + else "" + ) + + # all expected were found + if not failed_expected and results.no_match_for_actual(remaining_actual): + self._fail_reason = ( + f"{successful_str}Unexpected exception(s):" + f" {[actual_exceptions[i] for i in remaining_actual]!r}" + ) + return False + # all raised exceptions were expected + if not remaining_actual and results.no_match_for_expected(failed_expected): + no_match_for_str = ", ".join( + self._repr_expected(self.expected_exceptions[i]) + for i in failed_expected + ) + self._fail_reason = f"{successful_str}Too few exceptions raised, found no match for: [{no_match_for_str}]" + return False + + # if there's only one remaining and one failed, and the unmatched didn't match anything else, + # we elect to only print why the remaining and the failed didn't match. + if ( + 1 == len(remaining_actual) == len(failed_expected) + and results.no_match_for_actual(remaining_actual) + and results.no_match_for_expected(failed_expected) + ): + self._fail_reason = f"{successful_str}{results.get_result(failed_expected[0], remaining_actual[0])}" + return False + + # there's both expected and raised exceptions without matches + s = "" + if matches: + s += f"\n{successful_str}" + indent_1 = " " * 2 + indent_2 = " " * 4 + + if not remaining_actual: + s += "\nToo few exceptions raised!" + elif not failed_expected: + s += "\nUnexpected exception(s)!" + + if failed_expected: + s += "\nThe following expected exceptions did not find a match:" + rev_matches = {v: k for k, v in matches.items()} + for i_failed in failed_expected: + s += ( + f"\n{indent_1}{self._repr_expected(self.expected_exceptions[i_failed])}" + ) + for i_actual, actual in enumerate(actual_exceptions): + if results.get_result(i_exp, i_actual) is None: + # we print full repr of match target + s += ( + f"\n{indent_2}It matches {backquote(repr(actual))} which was paired with " + + backquote( + self._repr_expected( + self.expected_exceptions[rev_matches[i_actual]] + ) + ) + ) + + if remaining_actual: + s += "\nThe following raised exceptions did not find a match" + for i_actual in remaining_actual: + s += f"\n{indent_1}{actual_exceptions[i_actual]!r}:" + for i_exp, expected in enumerate(self.expected_exceptions): + res = results.get_result(i_exp, i_actual) + if i_exp in failed_expected: + assert res is not None + if res[0] != "\n": + s += "\n" + s += indent(res, indent_2) + if res is None: + # we print full repr of match target + s += ( + f"\n{indent_2}It matches {backquote(self._repr_expected(expected))} " + f"which was paired with {backquote(repr(actual_exceptions[matches[i_exp]]))}" + ) + + if len(self.expected_exceptions) == len(actual_exceptions) and possible_match( + results + ): + s += ( + "\nThere exist a possible match when attempting an exhaustive check," + " but RaisesGroup uses a greedy algorithm. " + "Please make your expected exceptions more stringent with `RaisesExc` etc" + " so the greedy algorithm can function." + ) + self._fail_reason = s + return False + + def __exit__( + self, + exc_type: type[BaseException] | None, + exc_val: BaseException | None, + exc_tb: types.TracebackType | None, + ) -> bool: + __tracebackhide__ = True + if exc_type is None: + fail(f"DID NOT RAISE any exception, expected `{self.expected_type()}`") + + assert self.excinfo is not None, ( + "Internal error - should have been constructed in __enter__" + ) + + # group_str is the only thing that differs between RaisesExc and RaisesGroup... + # I might just scrap it? Or make it part of fail_reason + group_str = ( + "(group)" + if self.allow_unwrapped and not issubclass(exc_type, BaseExceptionGroup) + else "group" + ) + + if not self.matches(exc_val): + fail(f"Raised exception {group_str} did not match: {self._fail_reason}") + + # Cast to narrow the exception type now that it's verified.... + # even though the TypeGuard in self.matches should be narrowing + exc_info = cast( + "tuple[type[BaseExceptionGroup[BaseExcT_co]], BaseExceptionGroup[BaseExcT_co], types.TracebackType]", + (exc_type, exc_val, exc_tb), + ) + self.excinfo.fill_unfilled(exc_info) + return True + + def expected_type(self) -> str: + subexcs = [] + for e in self.expected_exceptions: + if isinstance(e, RaisesExc): + subexcs.append(repr(e)) + elif isinstance(e, RaisesGroup): + subexcs.append(e.expected_type()) + elif isinstance(e, type): + subexcs.append(e.__name__) + else: # pragma: no cover + raise AssertionError("unknown type") + group_type = "Base" if self.is_baseexception else "" + return f"{group_type}ExceptionGroup({', '.join(subexcs)})" + + +@final +class NotChecked: + """Singleton for unchecked values in ResultHolder""" + + +class ResultHolder: + """Container for results of checking exceptions. + Used in RaisesGroup._check_exceptions and possible_match. + """ + + def __init__( + self, + expected_exceptions: tuple[ + type[BaseException] | AbstractRaises[BaseException], ... + ], + actual_exceptions: Sequence[BaseException], + ) -> None: + self.results: list[list[str | type[NotChecked] | None]] = [ + [NotChecked for _ in expected_exceptions] for _ in actual_exceptions + ] + + def set_result(self, expected: int, actual: int, result: str | None) -> None: + self.results[actual][expected] = result + + def get_result(self, expected: int, actual: int) -> str | None: + res = self.results[actual][expected] + assert res is not NotChecked + # mypy doesn't support identity checking against anything but None + return res # type: ignore[return-value] + + def has_result(self, expected: int, actual: int) -> bool: + return self.results[actual][expected] is not NotChecked + + def no_match_for_expected(self, expected: list[int]) -> bool: + for i in expected: + for actual_results in self.results: + assert actual_results[i] is not NotChecked + if actual_results[i] is None: + return False + return True + + def no_match_for_actual(self, actual: list[int]) -> bool: + for i in actual: + for res in self.results[i]: + assert res is not NotChecked + if res is None: + return False + return True + + +def possible_match(results: ResultHolder, used: set[int] | None = None) -> bool: + if used is None: + used = set() + curr_row = len(used) + if curr_row == len(results.results): + return True + return any( + val is None and i not in used and possible_match(results, used | {i}) + for (i, val) in enumerate(results.results[curr_row]) + ) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/recwarn.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/recwarn.py new file mode 100644 index 0000000000000000000000000000000000000000..e3db717bfe475c210d4e38ff233369e6872ae81c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/recwarn.py @@ -0,0 +1,367 @@ +# mypy: allow-untyped-defs +"""Record warnings during test function execution.""" + +from __future__ import annotations + +from collections.abc import Callable +from collections.abc import Generator +from collections.abc import Iterator +from pprint import pformat +import re +from types import TracebackType +from typing import Any +from typing import final +from typing import overload +from typing import TYPE_CHECKING +from typing import TypeVar + + +if TYPE_CHECKING: + from typing_extensions import Self + +import warnings + +from _pytest.deprecated import check_ispytest +from _pytest.fixtures import fixture +from _pytest.outcomes import Exit +from _pytest.outcomes import fail + + +T = TypeVar("T") + + +@fixture +def recwarn() -> Generator[WarningsRecorder]: + """Return a :class:`WarningsRecorder` instance that records all warnings emitted by test functions. + + See :ref:`warnings` for information on warning categories. + """ + wrec = WarningsRecorder(_ispytest=True) + with wrec: + warnings.simplefilter("default") + yield wrec + + +@overload +def deprecated_call( + *, match: str | re.Pattern[str] | None = ... +) -> WarningsRecorder: ... + + +@overload +def deprecated_call(func: Callable[..., T], *args: Any, **kwargs: Any) -> T: ... + + +def deprecated_call( + func: Callable[..., Any] | None = None, *args: Any, **kwargs: Any +) -> WarningsRecorder | Any: + """Assert that code produces a ``DeprecationWarning`` or ``PendingDeprecationWarning`` or ``FutureWarning``. + + This function can be used as a context manager:: + + >>> import warnings + >>> def api_call_v2(): + ... warnings.warn('use v3 of this api', DeprecationWarning) + ... return 200 + + >>> import pytest + >>> with pytest.deprecated_call(): + ... assert api_call_v2() == 200 + + It can also be used by passing a function and ``*args`` and ``**kwargs``, + in which case it will ensure calling ``func(*args, **kwargs)`` produces one of + the warnings types above. The return value is the return value of the function. + + In the context manager form you may use the keyword argument ``match`` to assert + that the warning matches a text or regex. + + The context manager produces a list of :class:`warnings.WarningMessage` objects, + one for each warning raised. + """ + __tracebackhide__ = True + if func is not None: + args = (func, *args) + return warns( + (DeprecationWarning, PendingDeprecationWarning, FutureWarning), *args, **kwargs + ) + + +@overload +def warns( + expected_warning: type[Warning] | tuple[type[Warning], ...] = ..., + *, + match: str | re.Pattern[str] | None = ..., +) -> WarningsChecker: ... + + +@overload +def warns( + expected_warning: type[Warning] | tuple[type[Warning], ...], + func: Callable[..., T], + *args: Any, + **kwargs: Any, +) -> T: ... + + +def warns( + expected_warning: type[Warning] | tuple[type[Warning], ...] = Warning, + *args: Any, + match: str | re.Pattern[str] | None = None, + **kwargs: Any, +) -> WarningsChecker | Any: + r"""Assert that code raises a particular class of warning. + + Specifically, the parameter ``expected_warning`` can be a warning class or tuple + of warning classes, and the code inside the ``with`` block must issue at least one + warning of that class or classes. + + This helper produces a list of :class:`warnings.WarningMessage` objects, one for + each warning emitted (regardless of whether it is an ``expected_warning`` or not). + Since pytest 8.0, unmatched warnings are also re-emitted when the context closes. + + This function can be used as a context manager:: + + >>> import pytest + >>> with pytest.warns(RuntimeWarning): + ... warnings.warn("my warning", RuntimeWarning) + + In the context manager form you may use the keyword argument ``match`` to assert + that the warning matches a text or regex:: + + >>> with pytest.warns(UserWarning, match='must be 0 or None'): + ... warnings.warn("value must be 0 or None", UserWarning) + + >>> with pytest.warns(UserWarning, match=r'must be \d+$'): + ... warnings.warn("value must be 42", UserWarning) + + >>> with pytest.warns(UserWarning): # catch re-emitted warning + ... with pytest.warns(UserWarning, match=r'must be \d+$'): + ... warnings.warn("this is not here", UserWarning) + Traceback (most recent call last): + ... + Failed: DID NOT WARN. No warnings of type ...UserWarning... were emitted... + + **Using with** ``pytest.mark.parametrize`` + + When using :ref:`pytest.mark.parametrize ref` it is possible to parametrize tests + such that some runs raise a warning and others do not. + + This could be achieved in the same way as with exceptions, see + :ref:`parametrizing_conditional_raising` for an example. + + """ + __tracebackhide__ = True + if not args: + if kwargs: + argnames = ", ".join(sorted(kwargs)) + raise TypeError( + f"Unexpected keyword arguments passed to pytest.warns: {argnames}" + "\nUse context-manager form instead?" + ) + return WarningsChecker(expected_warning, match_expr=match, _ispytest=True) + else: + func = args[0] + if not callable(func): + raise TypeError(f"{func!r} object (type: {type(func)}) must be callable") + with WarningsChecker(expected_warning, _ispytest=True): + return func(*args[1:], **kwargs) + + +class WarningsRecorder(warnings.catch_warnings): + """A context manager to record raised warnings. + + Each recorded warning is an instance of :class:`warnings.WarningMessage`. + + Adapted from `warnings.catch_warnings`. + + .. note:: + ``DeprecationWarning`` and ``PendingDeprecationWarning`` are treated + differently; see :ref:`ensuring_function_triggers`. + + """ + + def __init__(self, *, _ispytest: bool = False) -> None: + check_ispytest(_ispytest) + super().__init__(record=True) + self._entered = False + self._list: list[warnings.WarningMessage] = [] + + @property + def list(self) -> list[warnings.WarningMessage]: + """The list of recorded warnings.""" + return self._list + + def __getitem__(self, i: int) -> warnings.WarningMessage: + """Get a recorded warning by index.""" + return self._list[i] + + def __iter__(self) -> Iterator[warnings.WarningMessage]: + """Iterate through the recorded warnings.""" + return iter(self._list) + + def __len__(self) -> int: + """The number of recorded warnings.""" + return len(self._list) + + def pop(self, cls: type[Warning] = Warning) -> warnings.WarningMessage: + """Pop the first recorded warning which is an instance of ``cls``, + but not an instance of a child class of any other match. + Raises ``AssertionError`` if there is no match. + """ + best_idx: int | None = None + for i, w in enumerate(self._list): + if w.category == cls: + return self._list.pop(i) # exact match, stop looking + if issubclass(w.category, cls) and ( + best_idx is None + or not issubclass(w.category, self._list[best_idx].category) + ): + best_idx = i + if best_idx is not None: + return self._list.pop(best_idx) + __tracebackhide__ = True + raise AssertionError(f"{cls!r} not found in warning list") + + def clear(self) -> None: + """Clear the list of recorded warnings.""" + self._list[:] = [] + + # Type ignored because we basically want the `catch_warnings` generic type + # parameter to be ourselves but that is not possible(?). + def __enter__(self) -> Self: # type: ignore[override] + if self._entered: + __tracebackhide__ = True + raise RuntimeError(f"Cannot enter {self!r} twice") + _list = super().__enter__() + # record=True means it's None. + assert _list is not None + self._list = _list + warnings.simplefilter("always") + return self + + def __exit__( + self, + exc_type: type[BaseException] | None, + exc_val: BaseException | None, + exc_tb: TracebackType | None, + ) -> None: + if not self._entered: + __tracebackhide__ = True + raise RuntimeError(f"Cannot exit {self!r} without entering first") + + super().__exit__(exc_type, exc_val, exc_tb) + + # Built-in catch_warnings does not reset entered state so we do it + # manually here for this context manager to become reusable. + self._entered = False + + +@final +class WarningsChecker(WarningsRecorder): + def __init__( + self, + expected_warning: type[Warning] | tuple[type[Warning], ...] = Warning, + match_expr: str | re.Pattern[str] | None = None, + *, + _ispytest: bool = False, + ) -> None: + check_ispytest(_ispytest) + super().__init__(_ispytest=True) + + msg = "exceptions must be derived from Warning, not %s" + if isinstance(expected_warning, tuple): + for exc in expected_warning: + if not issubclass(exc, Warning): + raise TypeError(msg % type(exc)) + expected_warning_tup = expected_warning + elif isinstance(expected_warning, type) and issubclass( + expected_warning, Warning + ): + expected_warning_tup = (expected_warning,) + else: + raise TypeError(msg % type(expected_warning)) + + self.expected_warning = expected_warning_tup + self.match_expr = match_expr + + def matches(self, warning: warnings.WarningMessage) -> bool: + assert self.expected_warning is not None + return issubclass(warning.category, self.expected_warning) and bool( + self.match_expr is None or re.search(self.match_expr, str(warning.message)) + ) + + def __exit__( + self, + exc_type: type[BaseException] | None, + exc_val: BaseException | None, + exc_tb: TracebackType | None, + ) -> None: + super().__exit__(exc_type, exc_val, exc_tb) + + __tracebackhide__ = True + + # BaseExceptions like pytest.{skip,fail,xfail,exit} or Ctrl-C within + # pytest.warns should *not* trigger "DID NOT WARN" and get suppressed + # when the warning doesn't happen. Control-flow exceptions should always + # propagate. + if exc_val is not None and ( + not isinstance(exc_val, Exception) + # Exit is an Exception, not a BaseException, for some reason. + or isinstance(exc_val, Exit) + ): + return + + def found_str() -> str: + return pformat([record.message for record in self], indent=2) + + try: + if not any(issubclass(w.category, self.expected_warning) for w in self): + fail( + f"DID NOT WARN. No warnings of type {self.expected_warning} were emitted.\n" + f" Emitted warnings: {found_str()}." + ) + elif not any(self.matches(w) for w in self): + fail( + f"DID NOT WARN. No warnings of type {self.expected_warning} matching the regex were emitted.\n" + f" Regex: {self.match_expr}\n" + f" Emitted warnings: {found_str()}." + ) + finally: + # Whether or not any warnings matched, we want to re-emit all unmatched warnings. + for w in self: + if not self.matches(w): + warnings.warn_explicit( + message=w.message, + category=w.category, + filename=w.filename, + lineno=w.lineno, + module=w.__module__, + source=w.source, + ) + + # Currently in Python it is possible to pass other types than an + # `str` message when creating `Warning` instances, however this + # causes an exception when :func:`warnings.filterwarnings` is used + # to filter those warnings. See + # https://github.com/python/cpython/issues/103577 for a discussion. + # While this can be considered a bug in CPython, we put guards in + # pytest as the error message produced without this check in place + # is confusing (#10865). + for w in self: + if type(w.message) is not UserWarning: + # If the warning was of an incorrect type then `warnings.warn()` + # creates a UserWarning. Any other warning must have been specified + # explicitly. + continue + if not w.message.args: + # UserWarning() without arguments must have been specified explicitly. + continue + msg = w.message.args[0] + if isinstance(msg, str): + continue + # It's possible that UserWarning was explicitly specified, and + # its first argument was not a string. But that case can't be + # distinguished from an invalid type. + raise TypeError( + f"Warning must be str or Warning, got {msg!r} (type {type(msg).__name__})" + ) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/reports.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/reports.py new file mode 100644 index 0000000000000000000000000000000000000000..011a69db00155c507a344280927a0787daf39fe8 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/reports.py @@ -0,0 +1,694 @@ +# mypy: allow-untyped-defs +from __future__ import annotations + +from collections.abc import Iterable +from collections.abc import Iterator +from collections.abc import Mapping +from collections.abc import Sequence +import dataclasses +from io import StringIO +import os +from pprint import pprint +import sys +from typing import Any +from typing import cast +from typing import final +from typing import Literal +from typing import NoReturn +from typing import TYPE_CHECKING + +from _pytest._code.code import ExceptionChainRepr +from _pytest._code.code import ExceptionInfo +from _pytest._code.code import ExceptionRepr +from _pytest._code.code import ReprEntry +from _pytest._code.code import ReprEntryNative +from _pytest._code.code import ReprExceptionInfo +from _pytest._code.code import ReprFileLocation +from _pytest._code.code import ReprFuncArgs +from _pytest._code.code import ReprLocals +from _pytest._code.code import ReprTraceback +from _pytest._code.code import TerminalRepr +from _pytest._io import TerminalWriter +from _pytest.config import Config +from _pytest.nodes import Collector +from _pytest.nodes import Item +from _pytest.outcomes import fail +from _pytest.outcomes import skip + + +if sys.version_info < (3, 11): + from exceptiongroup import BaseExceptionGroup + + +if TYPE_CHECKING: + from typing_extensions import Self + + from _pytest.runner import CallInfo + + +def getworkerinfoline(node): + try: + return node._workerinfocache + except AttributeError: + d = node.workerinfo + ver = "{}.{}.{}".format(*d["version_info"][:3]) + node._workerinfocache = s = "[{}] {} -- Python {} {}".format( + d["id"], d["sysplatform"], ver, d["executable"] + ) + return s + + +class BaseReport: + when: str | None + location: tuple[str, int | None, str] | None + longrepr: ( + None | ExceptionInfo[BaseException] | tuple[str, int, str] | str | TerminalRepr + ) + sections: list[tuple[str, str]] + nodeid: str + outcome: Literal["passed", "failed", "skipped"] + + def __init__(self, **kw: Any) -> None: + self.__dict__.update(kw) + + if TYPE_CHECKING: + # Can have arbitrary fields given to __init__(). + def __getattr__(self, key: str) -> Any: ... + + def toterminal(self, out: TerminalWriter) -> None: + if hasattr(self, "node"): + worker_info = getworkerinfoline(self.node) + if worker_info: + out.line(worker_info) + + longrepr = self.longrepr + if longrepr is None: + return + + if hasattr(longrepr, "toterminal"): + longrepr_terminal = cast(TerminalRepr, longrepr) + longrepr_terminal.toterminal(out) + else: + try: + s = str(longrepr) + except UnicodeEncodeError: + s = "<unprintable longrepr>" + out.line(s) + + def get_sections(self, prefix: str) -> Iterator[tuple[str, str]]: + for name, content in self.sections: + if name.startswith(prefix): + yield prefix, content + + @property + def longreprtext(self) -> str: + """Read-only property that returns the full string representation of + ``longrepr``. + + .. versionadded:: 3.0 + """ + file = StringIO() + tw = TerminalWriter(file) + tw.hasmarkup = False + self.toterminal(tw) + exc = file.getvalue() + return exc.strip() + + @property + def caplog(self) -> str: + """Return captured log lines, if log capturing is enabled. + + .. versionadded:: 3.5 + """ + return "\n".join( + content for (prefix, content) in self.get_sections("Captured log") + ) + + @property + def capstdout(self) -> str: + """Return captured text from stdout, if capturing is enabled. + + .. versionadded:: 3.0 + """ + return "".join( + content for (prefix, content) in self.get_sections("Captured stdout") + ) + + @property + def capstderr(self) -> str: + """Return captured text from stderr, if capturing is enabled. + + .. versionadded:: 3.0 + """ + return "".join( + content for (prefix, content) in self.get_sections("Captured stderr") + ) + + @property + def passed(self) -> bool: + """Whether the outcome is passed.""" + return self.outcome == "passed" + + @property + def failed(self) -> bool: + """Whether the outcome is failed.""" + return self.outcome == "failed" + + @property + def skipped(self) -> bool: + """Whether the outcome is skipped.""" + return self.outcome == "skipped" + + @property + def fspath(self) -> str: + """The path portion of the reported node, as a string.""" + return self.nodeid.split("::")[0] + + @property + def count_towards_summary(self) -> bool: + """**Experimental** Whether this report should be counted towards the + totals shown at the end of the test session: "1 passed, 1 failure, etc". + + .. note:: + + This function is considered **experimental**, so beware that it is subject to changes + even in patch releases. + """ + return True + + @property + def head_line(self) -> str | None: + """**Experimental** The head line shown with longrepr output for this + report, more commonly during traceback representation during + failures:: + + ________ Test.foo ________ + + + In the example above, the head_line is "Test.foo". + + .. note:: + + This function is considered **experimental**, so beware that it is subject to changes + even in patch releases. + """ + if self.location is not None: + _fspath, _lineno, domain = self.location + return domain + return None + + def _get_verbose_word_with_markup( + self, config: Config, default_markup: Mapping[str, bool] + ) -> tuple[str, Mapping[str, bool]]: + _category, _short, verbose = config.hook.pytest_report_teststatus( + report=self, config=config + ) + + if isinstance(verbose, str): + return verbose, default_markup + + if isinstance(verbose, Sequence) and len(verbose) == 2: + word, markup = verbose + if isinstance(word, str) and isinstance(markup, Mapping): + return word, markup + + fail( # pragma: no cover + "pytest_report_teststatus() hook (from a plugin) returned " + f"an invalid verbose value: {verbose!r}.\nExpected either a string " + "or a tuple of (word, markup)." + ) + + def _to_json(self) -> dict[str, Any]: + """Return the contents of this report as a dict of builtin entries, + suitable for serialization. + + This was originally the serialize_report() function from xdist (ca03269). + + Experimental method. + """ + return _report_to_json(self) + + @classmethod + def _from_json(cls, reportdict: dict[str, object]) -> Self: + """Create either a TestReport or CollectReport, depending on the calling class. + + It is the callers responsibility to know which class to pass here. + + This was originally the serialize_report() function from xdist (ca03269). + + Experimental method. + """ + kwargs = _report_kwargs_from_json(reportdict) + return cls(**kwargs) + + +def _report_unserialization_failure( + type_name: str, report_class: type[BaseReport], reportdict +) -> NoReturn: + url = "https://github.com/pytest-dev/pytest/issues" + stream = StringIO() + pprint("-" * 100, stream=stream) + pprint(f"INTERNALERROR: Unknown entry type returned: {type_name}", stream=stream) + pprint(f"report_name: {report_class}", stream=stream) + pprint(reportdict, stream=stream) + pprint(f"Please report this bug at {url}", stream=stream) + pprint("-" * 100, stream=stream) + raise RuntimeError(stream.getvalue()) + + +def _format_failed_longrepr( + item: Item, call: CallInfo[None], excinfo: ExceptionInfo[BaseException] +): + if call.when == "call": + longrepr = item.repr_failure(excinfo) + else: + # Exception in setup or teardown. + longrepr = item._repr_failure_py( + excinfo, style=item.config.getoption("tbstyle", "auto") + ) + return longrepr + + +def _format_exception_group_all_skipped_longrepr( + item: Item, + excinfo: ExceptionInfo[BaseExceptionGroup[BaseException | BaseExceptionGroup]], +) -> tuple[str, int, str]: + r = excinfo._getreprcrash() + assert r is not None, ( + "There should always be a traceback entry for skipping a test." + ) + if all( + getattr(skip, "_use_item_location", False) for skip in excinfo.value.exceptions + ): + path, line = item.reportinfo()[:2] + assert line is not None + loc = (os.fspath(path), line + 1) + default_msg = "skipped" + else: + loc = (str(r.path), r.lineno) + default_msg = r.message + + # Get all unique skip messages. + msgs: list[str] = [] + for exception in excinfo.value.exceptions: + m = getattr(exception, "msg", None) or ( + exception.args[0] if exception.args else None + ) + if m and m not in msgs: + msgs.append(m) + + reason = "; ".join(msgs) if msgs else default_msg + longrepr = (*loc, reason) + return longrepr + + +class TestReport(BaseReport): + """Basic test report object (also used for setup and teardown calls if + they fail). + + Reports can contain arbitrary extra attributes. + """ + + __test__ = False + + # Defined by skipping plugin. + # xfail reason if xfailed, otherwise not defined. Use hasattr to distinguish. + wasxfail: str + + def __init__( + self, + nodeid: str, + location: tuple[str, int | None, str], + keywords: Mapping[str, Any], + outcome: Literal["passed", "failed", "skipped"], + longrepr: None + | ExceptionInfo[BaseException] + | tuple[str, int, str] + | str + | TerminalRepr, + when: Literal["setup", "call", "teardown"], + sections: Iterable[tuple[str, str]] = (), + duration: float = 0, + start: float = 0, + stop: float = 0, + user_properties: Iterable[tuple[str, object]] | None = None, + **extra, + ) -> None: + #: Normalized collection nodeid. + self.nodeid = nodeid + + #: A (filesystempath, lineno, domaininfo) tuple indicating the + #: actual location of a test item - it might be different from the + #: collected one e.g. if a method is inherited from a different module. + #: The filesystempath may be relative to ``config.rootdir``. + #: The line number is 0-based. + self.location: tuple[str, int | None, str] = location + + #: A name -> value dictionary containing all keywords and + #: markers associated with a test invocation. + self.keywords: Mapping[str, Any] = keywords + + #: Test outcome, always one of "passed", "failed", "skipped". + self.outcome = outcome + + #: None or a failure representation. + self.longrepr = longrepr + + #: One of 'setup', 'call', 'teardown' to indicate runtest phase. + self.when: Literal["setup", "call", "teardown"] = when + + #: User properties is a list of tuples (name, value) that holds user + #: defined properties of the test. + self.user_properties = list(user_properties or []) + + #: Tuples of str ``(heading, content)`` with extra information + #: for the test report. Used by pytest to add text captured + #: from ``stdout``, ``stderr``, and intercepted logging events. May + #: be used by other plugins to add arbitrary information to reports. + self.sections = list(sections) + + #: Time it took to run just the test. + self.duration: float = duration + + #: The system time when the call started, in seconds since the epoch. + self.start: float = start + #: The system time when the call ended, in seconds since the epoch. + self.stop: float = stop + + self.__dict__.update(extra) + + def __repr__(self) -> str: + return f"<{self.__class__.__name__} {self.nodeid!r} when={self.when!r} outcome={self.outcome!r}>" + + @classmethod + def from_item_and_call(cls, item: Item, call: CallInfo[None]) -> TestReport: + """Create and fill a TestReport with standard item and call info. + + :param item: The item. + :param call: The call info. + """ + when = call.when + # Remove "collect" from the Literal type -- only for collection calls. + assert when != "collect" + duration = call.duration + start = call.start + stop = call.stop + keywords = {x: 1 for x in item.keywords} + excinfo = call.excinfo + sections = [] + if not call.excinfo: + outcome: Literal["passed", "failed", "skipped"] = "passed" + longrepr: ( + None + | ExceptionInfo[BaseException] + | tuple[str, int, str] + | str + | TerminalRepr + ) = None + else: + if not isinstance(excinfo, ExceptionInfo): + outcome = "failed" + longrepr = excinfo + elif isinstance(excinfo.value, skip.Exception): + outcome = "skipped" + r = excinfo._getreprcrash() + assert r is not None, ( + "There should always be a traceback entry for skipping a test." + ) + if excinfo.value._use_item_location: + path, line = item.reportinfo()[:2] + assert line is not None + longrepr = (os.fspath(path), line + 1, r.message) + else: + longrepr = (str(r.path), r.lineno, r.message) + elif isinstance(excinfo.value, BaseExceptionGroup) and ( + excinfo.value.split(skip.Exception)[1] is None + ): + # All exceptions in the group are skip exceptions. + outcome = "skipped" + excinfo = cast( + ExceptionInfo[ + BaseExceptionGroup[BaseException | BaseExceptionGroup] + ], + excinfo, + ) + longrepr = _format_exception_group_all_skipped_longrepr(item, excinfo) + else: + outcome = "failed" + longrepr = _format_failed_longrepr(item, call, excinfo) + for rwhen, key, content in item._report_sections: + sections.append((f"Captured {key} {rwhen}", content)) + return cls( + item.nodeid, + item.location, + keywords, + outcome, + longrepr, + when, + sections, + duration, + start, + stop, + user_properties=item.user_properties, + ) + + +@final +class CollectReport(BaseReport): + """Collection report object. + + Reports can contain arbitrary extra attributes. + """ + + when = "collect" + + def __init__( + self, + nodeid: str, + outcome: Literal["passed", "failed", "skipped"], + longrepr: None + | ExceptionInfo[BaseException] + | tuple[str, int, str] + | str + | TerminalRepr, + result: list[Item | Collector] | None, + sections: Iterable[tuple[str, str]] = (), + **extra, + ) -> None: + #: Normalized collection nodeid. + self.nodeid = nodeid + + #: Test outcome, always one of "passed", "failed", "skipped". + self.outcome = outcome + + #: None or a failure representation. + self.longrepr = longrepr + + #: The collected items and collection nodes. + self.result = result or [] + + #: Tuples of str ``(heading, content)`` with extra information + #: for the test report. Used by pytest to add text captured + #: from ``stdout``, ``stderr``, and intercepted logging events. May + #: be used by other plugins to add arbitrary information to reports. + self.sections = list(sections) + + self.__dict__.update(extra) + + @property + def location( # type:ignore[override] + self, + ) -> tuple[str, int | None, str] | None: + return (self.fspath, None, self.fspath) + + def __repr__(self) -> str: + return f"<CollectReport {self.nodeid!r} lenresult={len(self.result)} outcome={self.outcome!r}>" + + +class CollectErrorRepr(TerminalRepr): + def __init__(self, msg: str) -> None: + self.longrepr = msg + + def toterminal(self, out: TerminalWriter) -> None: + out.line(self.longrepr, red=True) + + +def pytest_report_to_serializable( + report: CollectReport | TestReport, +) -> dict[str, Any] | None: + if isinstance(report, TestReport | CollectReport): + data = report._to_json() + data["$report_type"] = report.__class__.__name__ + return data + # TODO: Check if this is actually reachable. + return None # type: ignore[unreachable] + + +def pytest_report_from_serializable( + data: dict[str, Any], +) -> CollectReport | TestReport | None: + if "$report_type" in data: + if data["$report_type"] == "TestReport": + return TestReport._from_json(data) + elif data["$report_type"] == "CollectReport": + return CollectReport._from_json(data) + assert False, "Unknown report_type unserialize data: {}".format( + data["$report_type"] + ) + return None + + +def _report_to_json(report: BaseReport) -> dict[str, Any]: + """Return the contents of this report as a dict of builtin entries, + suitable for serialization. + + This was originally the serialize_report() function from xdist (ca03269). + """ + + def serialize_repr_entry( + entry: ReprEntry | ReprEntryNative, + ) -> dict[str, Any]: + data = dataclasses.asdict(entry) + for key, value in data.items(): + if hasattr(value, "__dict__"): + data[key] = dataclasses.asdict(value) + entry_data = {"type": type(entry).__name__, "data": data} + return entry_data + + def serialize_repr_traceback(reprtraceback: ReprTraceback) -> dict[str, Any]: + result = dataclasses.asdict(reprtraceback) + result["reprentries"] = [ + serialize_repr_entry(x) for x in reprtraceback.reprentries + ] + return result + + def serialize_repr_crash( + reprcrash: ReprFileLocation | None, + ) -> dict[str, Any] | None: + if reprcrash is not None: + return dataclasses.asdict(reprcrash) + else: + return None + + def serialize_exception_longrepr(rep: BaseReport) -> dict[str, Any]: + assert rep.longrepr is not None + # TODO: Investigate whether the duck typing is really necessary here. + longrepr = cast(ExceptionRepr, rep.longrepr) + result: dict[str, Any] = { + "reprcrash": serialize_repr_crash(longrepr.reprcrash), + "reprtraceback": serialize_repr_traceback(longrepr.reprtraceback), + "sections": longrepr.sections, + } + if isinstance(longrepr, ExceptionChainRepr): + result["chain"] = [] + for repr_traceback, repr_crash, description in longrepr.chain: + result["chain"].append( + ( + serialize_repr_traceback(repr_traceback), + serialize_repr_crash(repr_crash), + description, + ) + ) + else: + result["chain"] = None + return result + + d = report.__dict__.copy() + if hasattr(report.longrepr, "toterminal"): + if hasattr(report.longrepr, "reprtraceback") and hasattr( + report.longrepr, "reprcrash" + ): + d["longrepr"] = serialize_exception_longrepr(report) + else: + d["longrepr"] = str(report.longrepr) + else: + d["longrepr"] = report.longrepr + for name in d: + if isinstance(d[name], os.PathLike): + d[name] = os.fspath(d[name]) + elif name == "result": + d[name] = None # for now + return d + + +def _report_kwargs_from_json(reportdict: dict[str, Any]) -> dict[str, Any]: + """Return **kwargs that can be used to construct a TestReport or + CollectReport instance. + + This was originally the serialize_report() function from xdist (ca03269). + """ + + def deserialize_repr_entry(entry_data): + data = entry_data["data"] + entry_type = entry_data["type"] + if entry_type == "ReprEntry": + reprfuncargs = None + reprfileloc = None + reprlocals = None + if data["reprfuncargs"]: + reprfuncargs = ReprFuncArgs(**data["reprfuncargs"]) + if data["reprfileloc"]: + reprfileloc = ReprFileLocation(**data["reprfileloc"]) + if data["reprlocals"]: + reprlocals = ReprLocals(data["reprlocals"]["lines"]) + + reprentry: ReprEntry | ReprEntryNative = ReprEntry( + lines=data["lines"], + reprfuncargs=reprfuncargs, + reprlocals=reprlocals, + reprfileloc=reprfileloc, + style=data["style"], + ) + elif entry_type == "ReprEntryNative": + reprentry = ReprEntryNative(data["lines"]) + else: + _report_unserialization_failure(entry_type, TestReport, reportdict) + return reprentry + + def deserialize_repr_traceback(repr_traceback_dict): + repr_traceback_dict["reprentries"] = [ + deserialize_repr_entry(x) for x in repr_traceback_dict["reprentries"] + ] + return ReprTraceback(**repr_traceback_dict) + + def deserialize_repr_crash(repr_crash_dict: dict[str, Any] | None): + if repr_crash_dict is not None: + return ReprFileLocation(**repr_crash_dict) + else: + return None + + if ( + reportdict["longrepr"] + and "reprcrash" in reportdict["longrepr"] + and "reprtraceback" in reportdict["longrepr"] + ): + reprtraceback = deserialize_repr_traceback( + reportdict["longrepr"]["reprtraceback"] + ) + reprcrash = deserialize_repr_crash(reportdict["longrepr"]["reprcrash"]) + if reportdict["longrepr"]["chain"]: + chain = [] + for repr_traceback_data, repr_crash_data, description in reportdict[ + "longrepr" + ]["chain"]: + chain.append( + ( + deserialize_repr_traceback(repr_traceback_data), + deserialize_repr_crash(repr_crash_data), + description, + ) + ) + exception_info: ExceptionChainRepr | ReprExceptionInfo = ExceptionChainRepr( + chain + ) + else: + exception_info = ReprExceptionInfo( + reprtraceback=reprtraceback, + reprcrash=reprcrash, + ) + + for section in reportdict["longrepr"]["sections"]: + exception_info.addsection(*section) + reportdict["longrepr"] = exception_info + + return reportdict diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/runner.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/runner.py new file mode 100644 index 0000000000000000000000000000000000000000..9c20ff9e638f56d7e039729ebcda6d8f38e9c551 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/runner.py @@ -0,0 +1,580 @@ +# mypy: allow-untyped-defs +"""Basic collect and runtest protocol implementations.""" + +from __future__ import annotations + +import bdb +from collections.abc import Callable +import dataclasses +import os +import sys +import types +from typing import cast +from typing import final +from typing import Generic +from typing import Literal +from typing import TYPE_CHECKING +from typing import TypeVar + +from .config import Config +from .reports import BaseReport +from .reports import CollectErrorRepr +from .reports import CollectReport +from .reports import TestReport +from _pytest import timing +from _pytest._code.code import ExceptionChainRepr +from _pytest._code.code import ExceptionInfo +from _pytest._code.code import TerminalRepr +from _pytest.config.argparsing import Parser +from _pytest.deprecated import check_ispytest +from _pytest.nodes import Collector +from _pytest.nodes import Directory +from _pytest.nodes import Item +from _pytest.nodes import Node +from _pytest.outcomes import Exit +from _pytest.outcomes import OutcomeException +from _pytest.outcomes import Skipped +from _pytest.outcomes import TEST_OUTCOME + + +if sys.version_info < (3, 11): + from exceptiongroup import BaseExceptionGroup + +if TYPE_CHECKING: + from _pytest.main import Session + from _pytest.terminal import TerminalReporter + +# +# pytest plugin hooks. + + +def pytest_addoption(parser: Parser) -> None: + group = parser.getgroup("terminal reporting", "Reporting", after="general") + group.addoption( + "--durations", + action="store", + type=int, + default=None, + metavar="N", + help="Show N slowest setup/test durations (N=0 for all)", + ) + group.addoption( + "--durations-min", + action="store", + type=float, + default=None, + metavar="N", + help="Minimal duration in seconds for inclusion in slowest list. " + "Default: 0.005 (or 0.0 if -vv is given).", + ) + + +def pytest_terminal_summary(terminalreporter: TerminalReporter) -> None: + durations = terminalreporter.config.option.durations + durations_min = terminalreporter.config.option.durations_min + verbose = terminalreporter.config.get_verbosity() + if durations is None: + return + if durations_min is None: + durations_min = 0.005 if verbose < 2 else 0.0 + tr = terminalreporter + dlist = [] + for replist in tr.stats.values(): + for rep in replist: + if hasattr(rep, "duration"): + dlist.append(rep) + if not dlist: + return + dlist.sort(key=lambda x: x.duration, reverse=True) + if not durations: + tr.write_sep("=", "slowest durations") + else: + tr.write_sep("=", f"slowest {durations} durations") + dlist = dlist[:durations] + + for i, rep in enumerate(dlist): + if rep.duration < durations_min: + tr.write_line("") + message = f"({len(dlist) - i} durations < {durations_min:g}s hidden." + if terminalreporter.config.option.durations_min is None: + message += " Use -vv to show these durations." + message += ")" + tr.write_line(message) + break + tr.write_line(f"{rep.duration:02.2f}s {rep.when:<8} {rep.nodeid}") + + +def pytest_sessionstart(session: Session) -> None: + session._setupstate = SetupState() + + +def pytest_sessionfinish(session: Session) -> None: + session._setupstate.teardown_exact(None) + + +def pytest_runtest_protocol(item: Item, nextitem: Item | None) -> bool: + ihook = item.ihook + ihook.pytest_runtest_logstart(nodeid=item.nodeid, location=item.location) + runtestprotocol(item, nextitem=nextitem) + ihook.pytest_runtest_logfinish(nodeid=item.nodeid, location=item.location) + return True + + +def runtestprotocol( + item: Item, log: bool = True, nextitem: Item | None = None +) -> list[TestReport]: + hasrequest = hasattr(item, "_request") + if hasrequest and not item._request: # type: ignore[attr-defined] + # This only happens if the item is re-run, as is done by + # pytest-rerunfailures. + item._initrequest() # type: ignore[attr-defined] + rep = call_and_report(item, "setup", log) + reports = [rep] + if rep.passed: + if item.config.getoption("setupshow", False): + show_test_item(item) + if not item.config.getoption("setuponly", False): + reports.append(call_and_report(item, "call", log)) + # If the session is about to fail or stop, teardown everything - this is + # necessary to correctly report fixture teardown errors (see #11706) + if item.session.shouldfail or item.session.shouldstop: + nextitem = None + reports.append(call_and_report(item, "teardown", log, nextitem=nextitem)) + # After all teardown hooks have been called + # want funcargs and request info to go away. + if hasrequest: + item._request = False # type: ignore[attr-defined] + item.funcargs = None # type: ignore[attr-defined] + return reports + + +def show_test_item(item: Item) -> None: + """Show test function, parameters and the fixtures of the test item.""" + tw = item.config.get_terminal_writer() + tw.line() + tw.write(" " * 8) + tw.write(item.nodeid) + used_fixtures = sorted(getattr(item, "fixturenames", [])) + if used_fixtures: + tw.write(" (fixtures used: {})".format(", ".join(used_fixtures))) + tw.flush() + + +def pytest_runtest_setup(item: Item) -> None: + _update_current_test_var(item, "setup") + item.session._setupstate.setup(item) + + +def pytest_runtest_call(item: Item) -> None: + _update_current_test_var(item, "call") + try: + del sys.last_type + del sys.last_value + del sys.last_traceback + if sys.version_info >= (3, 12, 0): + del sys.last_exc # type:ignore[attr-defined] + except AttributeError: + pass + try: + item.runtest() + except Exception as e: + # Store trace info to allow postmortem debugging + sys.last_type = type(e) + sys.last_value = e + if sys.version_info >= (3, 12, 0): + sys.last_exc = e # type:ignore[attr-defined] + assert e.__traceback__ is not None + # Skip *this* frame + sys.last_traceback = e.__traceback__.tb_next + raise + + +def pytest_runtest_teardown(item: Item, nextitem: Item | None) -> None: + _update_current_test_var(item, "teardown") + item.session._setupstate.teardown_exact(nextitem) + _update_current_test_var(item, None) + + +def _update_current_test_var( + item: Item, when: Literal["setup", "call", "teardown"] | None +) -> None: + """Update :envvar:`PYTEST_CURRENT_TEST` to reflect the current item and stage. + + If ``when`` is None, delete ``PYTEST_CURRENT_TEST`` from the environment. + """ + var_name = "PYTEST_CURRENT_TEST" + if when: + value = f"{item.nodeid} ({when})" + # don't allow null bytes on environment variables (see #2644, #2957) + value = value.replace("\x00", "(null)") + os.environ[var_name] = value + else: + os.environ.pop(var_name) + + +def pytest_report_teststatus(report: BaseReport) -> tuple[str, str, str] | None: + if report.when in ("setup", "teardown"): + if report.failed: + # category, shortletter, verbose-word + return "error", "E", "ERROR" + elif report.skipped: + return "skipped", "s", "SKIPPED" + else: + return "", "", "" + return None + + +# +# Implementation + + +def call_and_report( + item: Item, when: Literal["setup", "call", "teardown"], log: bool = True, **kwds +) -> TestReport: + ihook = item.ihook + if when == "setup": + runtest_hook: Callable[..., None] = ihook.pytest_runtest_setup + elif when == "call": + runtest_hook = ihook.pytest_runtest_call + elif when == "teardown": + runtest_hook = ihook.pytest_runtest_teardown + else: + assert False, f"Unhandled runtest hook case: {when}" + + call = CallInfo.from_call( + lambda: runtest_hook(item=item, **kwds), + when=when, + reraise=get_reraise_exceptions(item.config), + ) + report: TestReport = ihook.pytest_runtest_makereport(item=item, call=call) + if log: + ihook.pytest_runtest_logreport(report=report) + if check_interactive_exception(call, report): + ihook.pytest_exception_interact(node=item, call=call, report=report) + return report + + +def get_reraise_exceptions(config: Config) -> tuple[type[BaseException], ...]: + """Return exception types that should not be suppressed in general.""" + reraise: tuple[type[BaseException], ...] = (Exit,) + if not config.getoption("usepdb", False): + reraise += (KeyboardInterrupt,) + return reraise + + +def check_interactive_exception(call: CallInfo[object], report: BaseReport) -> bool: + """Check whether the call raised an exception that should be reported as + interactive.""" + if call.excinfo is None: + # Didn't raise. + return False + if hasattr(report, "wasxfail"): + # Exception was expected. + return False + if isinstance(call.excinfo.value, Skipped | bdb.BdbQuit): + # Special control flow exception. + return False + return True + + +TResult = TypeVar("TResult", covariant=True) + + +@final +@dataclasses.dataclass +class CallInfo(Generic[TResult]): + """Result/Exception info of a function invocation.""" + + _result: TResult | None + #: The captured exception of the call, if it raised. + excinfo: ExceptionInfo[BaseException] | None + #: The system time when the call started, in seconds since the epoch. + start: float + #: The system time when the call ended, in seconds since the epoch. + stop: float + #: The call duration, in seconds. + duration: float + #: The context of invocation: "collect", "setup", "call" or "teardown". + when: Literal["collect", "setup", "call", "teardown"] + + def __init__( + self, + result: TResult | None, + excinfo: ExceptionInfo[BaseException] | None, + start: float, + stop: float, + duration: float, + when: Literal["collect", "setup", "call", "teardown"], + *, + _ispytest: bool = False, + ) -> None: + check_ispytest(_ispytest) + self._result = result + self.excinfo = excinfo + self.start = start + self.stop = stop + self.duration = duration + self.when = when + + @property + def result(self) -> TResult: + """The return value of the call, if it didn't raise. + + Can only be accessed if excinfo is None. + """ + if self.excinfo is not None: + raise AttributeError(f"{self!r} has no valid result") + # The cast is safe because an exception wasn't raised, hence + # _result has the expected function return type (which may be + # None, that's why a cast and not an assert). + return cast(TResult, self._result) + + @classmethod + def from_call( + cls, + func: Callable[[], TResult], + when: Literal["collect", "setup", "call", "teardown"], + reraise: type[BaseException] | tuple[type[BaseException], ...] | None = None, + ) -> CallInfo[TResult]: + """Call func, wrapping the result in a CallInfo. + + :param func: + The function to call. Called without arguments. + :type func: Callable[[], _pytest.runner.TResult] + :param when: + The phase in which the function is called. + :param reraise: + Exception or exceptions that shall propagate if raised by the + function, instead of being wrapped in the CallInfo. + """ + excinfo = None + instant = timing.Instant() + try: + result: TResult | None = func() + except BaseException: + excinfo = ExceptionInfo.from_current() + if reraise is not None and isinstance(excinfo.value, reraise): + raise + result = None + duration = instant.elapsed() + return cls( + start=duration.start.time, + stop=duration.stop.time, + duration=duration.seconds, + when=when, + result=result, + excinfo=excinfo, + _ispytest=True, + ) + + def __repr__(self) -> str: + if self.excinfo is None: + return f"<CallInfo when={self.when!r} result: {self._result!r}>" + return f"<CallInfo when={self.when!r} excinfo={self.excinfo!r}>" + + +def pytest_runtest_makereport(item: Item, call: CallInfo[None]) -> TestReport: + return TestReport.from_item_and_call(item, call) + + +def pytest_make_collect_report(collector: Collector) -> CollectReport: + def collect() -> list[Item | Collector]: + # Before collecting, if this is a Directory, load the conftests. + # If a conftest import fails to load, it is considered a collection + # error of the Directory collector. This is why it's done inside of the + # CallInfo wrapper. + # + # Note: initial conftests are loaded early, not here. + if isinstance(collector, Directory): + collector.config.pluginmanager._loadconftestmodules( + collector.path, + collector.config.getoption("importmode"), + rootpath=collector.config.rootpath, + consider_namespace_packages=collector.config.getini( + "consider_namespace_packages" + ), + ) + + return list(collector.collect()) + + call = CallInfo.from_call( + collect, "collect", reraise=(KeyboardInterrupt, SystemExit) + ) + longrepr: None | tuple[str, int, str] | str | TerminalRepr = None + if not call.excinfo: + outcome: Literal["passed", "skipped", "failed"] = "passed" + else: + skip_exceptions = [Skipped] + unittest = sys.modules.get("unittest") + if unittest is not None: + skip_exceptions.append(unittest.SkipTest) + if isinstance(call.excinfo.value, tuple(skip_exceptions)): + outcome = "skipped" + r_ = collector._repr_failure_py(call.excinfo, "line") + assert isinstance(r_, ExceptionChainRepr), repr(r_) + r = r_.reprcrash + assert r + longrepr = (str(r.path), r.lineno, r.message) + else: + outcome = "failed" + errorinfo = collector.repr_failure(call.excinfo) + if not hasattr(errorinfo, "toterminal"): + assert isinstance(errorinfo, str) + errorinfo = CollectErrorRepr(errorinfo) + longrepr = errorinfo + result = call.result if not call.excinfo else None + rep = CollectReport(collector.nodeid, outcome, longrepr, result) + rep.call = call # type: ignore # see collect_one_node + return rep + + +class SetupState: + """Shared state for setting up/tearing down test items or collectors + in a session. + + Suppose we have a collection tree as follows: + + <Session session> + <Module mod1> + <Function item1> + <Module mod2> + <Function item2> + + The SetupState maintains a stack. The stack starts out empty: + + [] + + During the setup phase of item1, setup(item1) is called. What it does + is: + + push session to stack, run session.setup() + push mod1 to stack, run mod1.setup() + push item1 to stack, run item1.setup() + + The stack is: + + [session, mod1, item1] + + While the stack is in this shape, it is allowed to add finalizers to + each of session, mod1, item1 using addfinalizer(). + + During the teardown phase of item1, teardown_exact(item2) is called, + where item2 is the next item to item1. What it does is: + + pop item1 from stack, run its teardowns + pop mod1 from stack, run its teardowns + + mod1 was popped because it ended its purpose with item1. The stack is: + + [session] + + During the setup phase of item2, setup(item2) is called. What it does + is: + + push mod2 to stack, run mod2.setup() + push item2 to stack, run item2.setup() + + Stack: + + [session, mod2, item2] + + During the teardown phase of item2, teardown_exact(None) is called, + because item2 is the last item. What it does is: + + pop item2 from stack, run its teardowns + pop mod2 from stack, run its teardowns + pop session from stack, run its teardowns + + Stack: + + [] + + The end! + """ + + def __init__(self) -> None: + # The stack is in the dict insertion order. + self.stack: dict[ + Node, + tuple[ + # Node's finalizers. + list[Callable[[], object]], + # Node's exception and original traceback, if its setup raised. + tuple[OutcomeException | Exception, types.TracebackType | None] | None, + ], + ] = {} + + def setup(self, item: Item) -> None: + """Setup objects along the collector chain to the item.""" + needed_collectors = item.listchain() + + # If a collector fails its setup, fail its entire subtree of items. + # The setup is not retried for each item - the same exception is used. + for col, (finalizers, exc) in self.stack.items(): + assert col in needed_collectors, "previous item was not torn down properly" + if exc: + raise exc[0].with_traceback(exc[1]) + + for col in needed_collectors[len(self.stack) :]: + assert col not in self.stack + # Push onto the stack. + self.stack[col] = ([col.teardown], None) + try: + col.setup() + except TEST_OUTCOME as exc: + self.stack[col] = (self.stack[col][0], (exc, exc.__traceback__)) + raise + + def addfinalizer(self, finalizer: Callable[[], object], node: Node) -> None: + """Attach a finalizer to the given node. + + The node must be currently active in the stack. + """ + assert node and not isinstance(node, tuple) + assert callable(finalizer) + assert node in self.stack, (node, self.stack) + self.stack[node][0].append(finalizer) + + def teardown_exact(self, nextitem: Item | None) -> None: + """Teardown the current stack up until reaching nodes that nextitem + also descends from. + + When nextitem is None (meaning we're at the last item), the entire + stack is torn down. + """ + needed_collectors = (nextitem and nextitem.listchain()) or [] + exceptions: list[BaseException] = [] + while self.stack: + if list(self.stack.keys()) == needed_collectors[: len(self.stack)]: + break + node, (finalizers, _) = self.stack.popitem() + these_exceptions = [] + while finalizers: + fin = finalizers.pop() + try: + fin() + except TEST_OUTCOME as e: + these_exceptions.append(e) + + if len(these_exceptions) == 1: + exceptions.extend(these_exceptions) + elif these_exceptions: + msg = f"errors while tearing down {node!r}" + exceptions.append(BaseExceptionGroup(msg, these_exceptions[::-1])) + + if len(exceptions) == 1: + raise exceptions[0] + elif exceptions: + raise BaseExceptionGroup("errors during test teardown", exceptions[::-1]) + if nextitem is None: + assert not self.stack + + +def collect_one_node(collector: Collector) -> CollectReport: + ihook = collector.ihook + ihook.pytest_collectstart(collector=collector) + rep: CollectReport = ihook.pytest_make_collect_report(collector=collector) + call = rep.__dict__.pop("call", None) + if call and check_interactive_exception(call, rep): + ihook.pytest_exception_interact(node=collector, call=call, report=rep) + return rep diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/scope.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/scope.py new file mode 100644 index 0000000000000000000000000000000000000000..2b007e878936a2c7c8b40d7470ea6ac457c5251b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/scope.py @@ -0,0 +1,91 @@ +""" +Scope definition and related utilities. + +Those are defined here, instead of in the 'fixtures' module because +their use is spread across many other pytest modules, and centralizing it in 'fixtures' +would cause circular references. + +Also this makes the module light to import, as it should. +""" + +from __future__ import annotations + +from enum import Enum +from functools import total_ordering +from typing import Literal + + +_ScopeName = Literal["session", "package", "module", "class", "function"] + + +@total_ordering +class Scope(Enum): + """ + Represents one of the possible fixture scopes in pytest. + + Scopes are ordered from lower to higher, that is: + + ->>> higher ->>> + + Function < Class < Module < Package < Session + + <<<- lower <<<- + """ + + # Scopes need to be listed from lower to higher. + Function = "function" + Class = "class" + Module = "module" + Package = "package" + Session = "session" + + def next_lower(self) -> Scope: + """Return the next lower scope.""" + index = _SCOPE_INDICES[self] + if index == 0: + raise ValueError(f"{self} is the lower-most scope") + return _ALL_SCOPES[index - 1] + + def next_higher(self) -> Scope: + """Return the next higher scope.""" + index = _SCOPE_INDICES[self] + if index == len(_SCOPE_INDICES) - 1: + raise ValueError(f"{self} is the upper-most scope") + return _ALL_SCOPES[index + 1] + + def __lt__(self, other: Scope) -> bool: + self_index = _SCOPE_INDICES[self] + other_index = _SCOPE_INDICES[other] + return self_index < other_index + + @classmethod + def from_user( + cls, scope_name: _ScopeName, descr: str, where: str | None = None + ) -> Scope: + """ + Given a scope name from the user, return the equivalent Scope enum. Should be used + whenever we want to convert a user provided scope name to its enum object. + + If the scope name is invalid, construct a user friendly message and call pytest.fail. + """ + from _pytest.outcomes import fail + + try: + # Holding this reference is necessary for mypy at the moment. + scope = Scope(scope_name) + except ValueError: + fail( + "{} {}got an unexpected scope value '{}'".format( + descr, f"from {where} " if where else "", scope_name + ), + pytrace=False, + ) + return scope + + +_ALL_SCOPES = list(Scope) +_SCOPE_INDICES = {scope: index for index, scope in enumerate(_ALL_SCOPES)} + + +# Ordered list of scopes which can contain many tests (in practice all except Function). +HIGH_SCOPES = [x for x in Scope if x is not Scope.Function] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/setuponly.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/setuponly.py new file mode 100644 index 0000000000000000000000000000000000000000..7e6b46bcdb4ab6e646653df9f847b11b5f50e943 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/setuponly.py @@ -0,0 +1,98 @@ +from __future__ import annotations + +from collections.abc import Generator + +from _pytest._io.saferepr import saferepr +from _pytest.config import Config +from _pytest.config import ExitCode +from _pytest.config.argparsing import Parser +from _pytest.fixtures import FixtureDef +from _pytest.fixtures import SubRequest +from _pytest.scope import Scope +import pytest + + +def pytest_addoption(parser: Parser) -> None: + group = parser.getgroup("debugconfig") + group.addoption( + "--setuponly", + "--setup-only", + action="store_true", + help="Only setup fixtures, do not execute tests", + ) + group.addoption( + "--setupshow", + "--setup-show", + action="store_true", + help="Show setup of fixtures while executing tests", + ) + + +@pytest.hookimpl(wrapper=True) +def pytest_fixture_setup( + fixturedef: FixtureDef[object], request: SubRequest +) -> Generator[None, object, object]: + try: + return (yield) + finally: + if request.config.option.setupshow: + if hasattr(request, "param"): + # Save the fixture parameter so ._show_fixture_action() can + # display it now and during the teardown (in .finish()). + if fixturedef.ids: + if callable(fixturedef.ids): + param = fixturedef.ids(request.param) + else: + param = fixturedef.ids[request.param_index] + else: + param = request.param + fixturedef.cached_param = param # type: ignore[attr-defined] + _show_fixture_action(fixturedef, request.config, "SETUP") + + +def pytest_fixture_post_finalizer( + fixturedef: FixtureDef[object], request: SubRequest +) -> None: + if fixturedef.cached_result is not None: + config = request.config + if config.option.setupshow: + _show_fixture_action(fixturedef, request.config, "TEARDOWN") + if hasattr(fixturedef, "cached_param"): + del fixturedef.cached_param + + +def _show_fixture_action( + fixturedef: FixtureDef[object], config: Config, msg: str +) -> None: + capman = config.pluginmanager.getplugin("capturemanager") + if capman: + capman.suspend_global_capture() + + tw = config.get_terminal_writer() + tw.line() + # Use smaller indentation the higher the scope: Session = 0, Package = 1, etc. + scope_indent = list(reversed(Scope)).index(fixturedef._scope) + tw.write(" " * 2 * scope_indent) + + scopename = fixturedef.scope[0].upper() + tw.write(f"{msg:<8} {scopename} {fixturedef.argname}") + + if msg == "SETUP": + deps = sorted(arg for arg in fixturedef.argnames if arg != "request") + if deps: + tw.write(" (fixtures used: {})".format(", ".join(deps))) + + if hasattr(fixturedef, "cached_param"): + tw.write(f"[{saferepr(fixturedef.cached_param, maxsize=42)}]") + + tw.flush() + + if capman: + capman.resume_global_capture() + + +@pytest.hookimpl(tryfirst=True) +def pytest_cmdline_main(config: Config) -> int | ExitCode | None: + if config.option.setuponly: + config.option.setupshow = True + return None diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/setupplan.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/setupplan.py new file mode 100644 index 0000000000000000000000000000000000000000..4e124cce2434e02d928c8ceb8cc8eaf63e271404 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/setupplan.py @@ -0,0 +1,39 @@ +from __future__ import annotations + +from _pytest.config import Config +from _pytest.config import ExitCode +from _pytest.config.argparsing import Parser +from _pytest.fixtures import FixtureDef +from _pytest.fixtures import SubRequest +import pytest + + +def pytest_addoption(parser: Parser) -> None: + group = parser.getgroup("debugconfig") + group.addoption( + "--setupplan", + "--setup-plan", + action="store_true", + help="Show what fixtures and tests would be executed but " + "don't execute anything", + ) + + +@pytest.hookimpl(tryfirst=True) +def pytest_fixture_setup( + fixturedef: FixtureDef[object], request: SubRequest +) -> object | None: + # Will return a dummy fixture if the setuponly option is provided. + if request.config.option.setupplan: + my_cache_key = fixturedef.cache_key(request) + fixturedef.cached_result = (None, my_cache_key, None) + return fixturedef.cached_result + return None + + +@pytest.hookimpl(tryfirst=True) +def pytest_cmdline_main(config: Config) -> int | ExitCode | None: + if config.option.setupplan: + config.option.setuponly = True + config.option.setupshow = True + return None diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/skipping.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/skipping.py new file mode 100644 index 0000000000000000000000000000000000000000..3b067629de0ea681b4e165b73748d27658835197 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/skipping.py @@ -0,0 +1,321 @@ +# mypy: allow-untyped-defs +"""Support for skip/xfail functions and markers.""" + +from __future__ import annotations + +from collections.abc import Generator +from collections.abc import Mapping +import dataclasses +import os +import platform +import sys +import traceback + +from _pytest.config import Config +from _pytest.config import hookimpl +from _pytest.config.argparsing import Parser +from _pytest.mark.structures import Mark +from _pytest.nodes import Item +from _pytest.outcomes import fail +from _pytest.outcomes import skip +from _pytest.outcomes import xfail +from _pytest.raises import AbstractRaises +from _pytest.reports import BaseReport +from _pytest.reports import TestReport +from _pytest.runner import CallInfo +from _pytest.stash import StashKey + + +def pytest_addoption(parser: Parser) -> None: + group = parser.getgroup("general") + group.addoption( + "--runxfail", + action="store_true", + dest="runxfail", + default=False, + help="Report the results of xfail tests as if they were not marked", + ) + + parser.addini( + "strict_xfail", + "Default for the strict parameter of xfail " + "markers when not given explicitly (default: False) (alias: xfail_strict)", + type="bool", + # None => fallback to `strict`. + default=None, + aliases=["xfail_strict"], + ) + + +def pytest_configure(config: Config) -> None: + if config.option.runxfail: + # yay a hack + import pytest + + old = pytest.xfail + config.add_cleanup(lambda: setattr(pytest, "xfail", old)) + + def nop(*args, **kwargs): + pass + + nop.Exception = xfail.Exception # type: ignore[attr-defined] + setattr(pytest, "xfail", nop) + + config.addinivalue_line( + "markers", + "skip(reason=None): skip the given test function with an optional reason. " + 'Example: skip(reason="no way of currently testing this") skips the ' + "test.", + ) + config.addinivalue_line( + "markers", + "skipif(condition, ..., *, reason=...): " + "skip the given test function if any of the conditions evaluate to True. " + "Example: skipif(sys.platform == 'win32') skips the test if we are on the win32 platform. " + "See https://docs.pytest.org/en/stable/reference/reference.html#pytest-mark-skipif", + ) + config.addinivalue_line( + "markers", + "xfail(condition, ..., *, reason=..., run=True, raises=None, strict=strict_xfail): " + "mark the test function as an expected failure if any of the conditions " + "evaluate to True. Optionally specify a reason for better reporting " + "and run=False if you don't even want to execute the test function. " + "If only specific exception(s) are expected, you can list them in " + "raises, and if the test fails in other ways, it will be reported as " + "a true failure. See https://docs.pytest.org/en/stable/reference/reference.html#pytest-mark-xfail", + ) + + +def evaluate_condition(item: Item, mark: Mark, condition: object) -> tuple[bool, str]: + """Evaluate a single skipif/xfail condition. + + If an old-style string condition is given, it is eval()'d, otherwise the + condition is bool()'d. If this fails, an appropriately formatted pytest.fail + is raised. + + Returns (result, reason). The reason is only relevant if the result is True. + """ + # String condition. + if isinstance(condition, str): + globals_ = { + "os": os, + "sys": sys, + "platform": platform, + "config": item.config, + } + for dictionary in reversed( + item.ihook.pytest_markeval_namespace(config=item.config) + ): + if not isinstance(dictionary, Mapping): + raise ValueError( + f"pytest_markeval_namespace() needs to return a dict, got {dictionary!r}" + ) + globals_.update(dictionary) + if hasattr(item, "obj"): + globals_.update(item.obj.__globals__) + try: + filename = f"<{mark.name} condition>" + condition_code = compile(condition, filename, "eval") + result = eval(condition_code, globals_) + except SyntaxError as exc: + msglines = [ + f"Error evaluating {mark.name!r} condition", + " " + condition, + " " + " " * (exc.offset or 0) + "^", + "SyntaxError: invalid syntax", + ] + fail("\n".join(msglines), pytrace=False) + except Exception as exc: + msglines = [ + f"Error evaluating {mark.name!r} condition", + " " + condition, + *traceback.format_exception_only(type(exc), exc), + ] + fail("\n".join(msglines), pytrace=False) + + # Boolean condition. + else: + try: + result = bool(condition) + except Exception as exc: + msglines = [ + f"Error evaluating {mark.name!r} condition as a boolean", + *traceback.format_exception_only(type(exc), exc), + ] + fail("\n".join(msglines), pytrace=False) + + reason = mark.kwargs.get("reason", None) + if reason is None: + if isinstance(condition, str): + reason = "condition: " + condition + else: + # XXX better be checked at collection time + msg = ( + f"Error evaluating {mark.name!r}: " + + "you need to specify reason=STRING when using booleans as conditions." + ) + fail(msg, pytrace=False) + + return result, reason + + +@dataclasses.dataclass(frozen=True) +class Skip: + """The result of evaluate_skip_marks().""" + + reason: str = "unconditional skip" + + +def evaluate_skip_marks(item: Item) -> Skip | None: + """Evaluate skip and skipif marks on item, returning Skip if triggered.""" + for mark in item.iter_markers(name="skipif"): + if "condition" not in mark.kwargs: + conditions = mark.args + else: + conditions = (mark.kwargs["condition"],) + + # Unconditional. + if not conditions: + reason = mark.kwargs.get("reason", "") + return Skip(reason) + + # If any of the conditions are true. + for condition in conditions: + result, reason = evaluate_condition(item, mark, condition) + if result: + return Skip(reason) + + for mark in item.iter_markers(name="skip"): + try: + return Skip(*mark.args, **mark.kwargs) + except TypeError as e: + raise TypeError(str(e) + " - maybe you meant pytest.mark.skipif?") from None + + return None + + +@dataclasses.dataclass(frozen=True) +class Xfail: + """The result of evaluate_xfail_marks().""" + + __slots__ = ("raises", "reason", "run", "strict") + + reason: str + run: bool + strict: bool + raises: ( + type[BaseException] + | tuple[type[BaseException], ...] + | AbstractRaises[BaseException] + | None + ) + + +def evaluate_xfail_marks(item: Item) -> Xfail | None: + """Evaluate xfail marks on item, returning Xfail if triggered.""" + for mark in item.iter_markers(name="xfail"): + run = mark.kwargs.get("run", True) + strict = mark.kwargs.get("strict") + if strict is None: + strict = item.config.getini("strict_xfail") + if strict is None: + strict = item.config.getini("strict") + raises = mark.kwargs.get("raises", None) + if "condition" not in mark.kwargs: + conditions = mark.args + else: + conditions = (mark.kwargs["condition"],) + + # Unconditional. + if not conditions: + reason = mark.kwargs.get("reason", "") + return Xfail(reason, run, strict, raises) + + # If any of the conditions are true. + for condition in conditions: + result, reason = evaluate_condition(item, mark, condition) + if result: + return Xfail(reason, run, strict, raises) + + return None + + +# Saves the xfail mark evaluation. Can be refreshed during call if None. +xfailed_key = StashKey[Xfail | None]() + + +@hookimpl(tryfirst=True) +def pytest_runtest_setup(item: Item) -> None: + skipped = evaluate_skip_marks(item) + if skipped: + raise skip.Exception(skipped.reason, _use_item_location=True) + + item.stash[xfailed_key] = xfailed = evaluate_xfail_marks(item) + if xfailed and not item.config.option.runxfail and not xfailed.run: + xfail("[NOTRUN] " + xfailed.reason) + + +@hookimpl(wrapper=True) +def pytest_runtest_call(item: Item) -> Generator[None]: + xfailed = item.stash.get(xfailed_key, None) + if xfailed is None: + item.stash[xfailed_key] = xfailed = evaluate_xfail_marks(item) + + if xfailed and not item.config.option.runxfail and not xfailed.run: + xfail("[NOTRUN] " + xfailed.reason) + + try: + return (yield) + finally: + # The test run may have added an xfail mark dynamically. + xfailed = item.stash.get(xfailed_key, None) + if xfailed is None: + item.stash[xfailed_key] = xfailed = evaluate_xfail_marks(item) + + +@hookimpl(wrapper=True) +def pytest_runtest_makereport( + item: Item, call: CallInfo[None] +) -> Generator[None, TestReport, TestReport]: + rep = yield + xfailed = item.stash.get(xfailed_key, None) + if item.config.option.runxfail: + pass # don't interfere + elif call.excinfo and isinstance(call.excinfo.value, xfail.Exception): + assert call.excinfo.value.msg is not None + rep.wasxfail = call.excinfo.value.msg + rep.outcome = "skipped" + elif not rep.skipped and xfailed: + if call.excinfo: + raises = xfailed.raises + if raises is None or ( + ( + isinstance(raises, type | tuple) + and isinstance(call.excinfo.value, raises) + ) + or ( + isinstance(raises, AbstractRaises) + and raises.matches(call.excinfo.value) + ) + ): + rep.outcome = "skipped" + rep.wasxfail = xfailed.reason + else: + rep.outcome = "failed" + elif call.when == "call": + if xfailed.strict: + rep.outcome = "failed" + rep.longrepr = "[XPASS(strict)] " + xfailed.reason + else: + rep.outcome = "passed" + rep.wasxfail = xfailed.reason + return rep + + +def pytest_report_teststatus(report: BaseReport) -> tuple[str, str, str] | None: + if hasattr(report, "wasxfail"): + if report.skipped: + return "xfailed", "x", "XFAIL" + elif report.passed: + return "xpassed", "X", "XPASS" + return None diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/stash.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/stash.py new file mode 100644 index 0000000000000000000000000000000000000000..6a9ff884e04880129db61e4b521be72e18c31919 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/stash.py @@ -0,0 +1,116 @@ +from __future__ import annotations + +from typing import Any +from typing import cast +from typing import Generic +from typing import TypeVar + + +__all__ = ["Stash", "StashKey"] + + +T = TypeVar("T") +D = TypeVar("D") + + +class StashKey(Generic[T]): + """``StashKey`` is an object used as a key to a :class:`Stash`. + + A ``StashKey`` is associated with the type ``T`` of the value of the key. + + A ``StashKey`` is unique and cannot conflict with another key. + + .. versionadded:: 7.0 + """ + + __slots__ = () + + +class Stash: + r"""``Stash`` is a type-safe heterogeneous mutable mapping that + allows keys and value types to be defined separately from + where it (the ``Stash``) is created. + + Usually you will be given an object which has a ``Stash``, for example + :class:`~pytest.Config` or a :class:`~_pytest.nodes.Node`: + + .. code-block:: python + + stash: Stash = some_object.stash + + If a module or plugin wants to store data in this ``Stash``, it creates + :class:`StashKey`\s for its keys (at the module level): + + .. code-block:: python + + # At the top-level of the module + some_str_key = StashKey[str]() + some_bool_key = StashKey[bool]() + + To store information: + + .. code-block:: python + + # Value type must match the key. + stash[some_str_key] = "value" + stash[some_bool_key] = True + + To retrieve the information: + + .. code-block:: python + + # The static type of some_str is str. + some_str = stash[some_str_key] + # The static type of some_bool is bool. + some_bool = stash[some_bool_key] + + .. versionadded:: 7.0 + """ + + __slots__ = ("_storage",) + + def __init__(self) -> None: + self._storage: dict[StashKey[Any], object] = {} + + def __setitem__(self, key: StashKey[T], value: T) -> None: + """Set a value for key.""" + self._storage[key] = value + + def __getitem__(self, key: StashKey[T]) -> T: + """Get the value for key. + + Raises ``KeyError`` if the key wasn't set before. + """ + return cast(T, self._storage[key]) + + def get(self, key: StashKey[T], default: D) -> T | D: + """Get the value for key, or return default if the key wasn't set + before.""" + try: + return self[key] + except KeyError: + return default + + def setdefault(self, key: StashKey[T], default: T) -> T: + """Return the value of key if already set, otherwise set the value + of key to default and return default.""" + try: + return self[key] + except KeyError: + self[key] = default + return default + + def __delitem__(self, key: StashKey[T]) -> None: + """Delete the value for key. + + Raises ``KeyError`` if the key wasn't set before. + """ + del self._storage[key] + + def __contains__(self, key: StashKey[T]) -> bool: + """Return whether key was set.""" + return key in self._storage + + def __len__(self) -> int: + """Return how many items exist in the stash.""" + return len(self._storage) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/stepwise.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/stepwise.py new file mode 100644 index 0000000000000000000000000000000000000000..8901540eb59760822b1346861f8f8098fabe83a4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/stepwise.py @@ -0,0 +1,209 @@ +from __future__ import annotations + +import dataclasses +from datetime import datetime +from datetime import timedelta +from typing import Any +from typing import TYPE_CHECKING + +from _pytest import nodes +from _pytest.cacheprovider import Cache +from _pytest.config import Config +from _pytest.config.argparsing import Parser +from _pytest.main import Session +from _pytest.reports import TestReport + + +if TYPE_CHECKING: + from typing_extensions import Self + +STEPWISE_CACHE_DIR = "cache/stepwise" + + +def pytest_addoption(parser: Parser) -> None: + group = parser.getgroup("general") + group.addoption( + "--sw", + "--stepwise", + action="store_true", + default=False, + dest="stepwise", + help="Exit on test failure and continue from last failing test next time", + ) + group.addoption( + "--sw-skip", + "--stepwise-skip", + action="store_true", + default=False, + dest="stepwise_skip", + help="Ignore the first failing test but stop on the next failing test. " + "Implicitly enables --stepwise.", + ) + group.addoption( + "--sw-reset", + "--stepwise-reset", + action="store_true", + default=False, + dest="stepwise_reset", + help="Resets stepwise state, restarting the stepwise workflow. " + "Implicitly enables --stepwise.", + ) + + +def pytest_configure(config: Config) -> None: + # --stepwise-skip/--stepwise-reset implies stepwise. + if config.option.stepwise_skip or config.option.stepwise_reset: + config.option.stepwise = True + if config.getoption("stepwise"): + config.pluginmanager.register(StepwisePlugin(config), "stepwiseplugin") + + +def pytest_sessionfinish(session: Session) -> None: + if not session.config.getoption("stepwise"): + assert session.config.cache is not None + if hasattr(session.config, "workerinput"): + # Do not update cache if this process is a xdist worker to prevent + # race conditions (#10641). + return + + +@dataclasses.dataclass +class StepwiseCacheInfo: + # The nodeid of the last failed test. + last_failed: str | None + + # The number of tests in the last time --stepwise was run. + # We use this information as a simple way to invalidate the cache information, avoiding + # confusing behavior in case the cache is stale. + last_test_count: int | None + + # The date when the cache was last updated, for information purposes only. + last_cache_date_str: str + + @property + def last_cache_date(self) -> datetime: + return datetime.fromisoformat(self.last_cache_date_str) + + @classmethod + def empty(cls) -> Self: + return cls( + last_failed=None, + last_test_count=None, + last_cache_date_str=datetime.now().isoformat(), + ) + + def update_date_to_now(self) -> None: + self.last_cache_date_str = datetime.now().isoformat() + + +class StepwisePlugin: + def __init__(self, config: Config) -> None: + self.config = config + self.session: Session | None = None + self.report_status: list[str] = [] + assert config.cache is not None + self.cache: Cache = config.cache + self.skip: bool = config.getoption("stepwise_skip") + self.reset: bool = config.getoption("stepwise_reset") + self.cached_info = self._load_cached_info() + + def _load_cached_info(self) -> StepwiseCacheInfo: + cached_dict: dict[str, Any] | None = self.cache.get(STEPWISE_CACHE_DIR, None) + if cached_dict: + try: + return StepwiseCacheInfo( + cached_dict["last_failed"], + cached_dict["last_test_count"], + cached_dict["last_cache_date_str"], + ) + except (KeyError, TypeError) as e: + error = f"{type(e).__name__}: {e}" + self.report_status.append(f"error reading cache, discarding ({error})") + + # Cache not found or error during load, return a new cache. + return StepwiseCacheInfo.empty() + + def pytest_sessionstart(self, session: Session) -> None: + self.session = session + + def pytest_collection_modifyitems( + self, config: Config, items: list[nodes.Item] + ) -> None: + last_test_count = self.cached_info.last_test_count + self.cached_info.last_test_count = len(items) + + if self.reset: + self.report_status.append("resetting state, not skipping.") + self.cached_info.last_failed = None + return + + if not self.cached_info.last_failed: + self.report_status.append("no previously failed tests, not skipping.") + return + + if last_test_count is not None and last_test_count != len(items): + self.report_status.append( + f"test count changed, not skipping (now {len(items)} tests, previously {last_test_count})." + ) + self.cached_info.last_failed = None + return + + # Check all item nodes until we find a match on last failed. + failed_index = None + for index, item in enumerate(items): + if item.nodeid == self.cached_info.last_failed: + failed_index = index + break + + # If the previously failed test was not found among the test items, + # do not skip any tests. + if failed_index is None: + self.report_status.append("previously failed test not found, not skipping.") + else: + cache_age = datetime.now() - self.cached_info.last_cache_date + # Round up to avoid showing microseconds. + cache_age = timedelta(seconds=int(cache_age.total_seconds())) + self.report_status.append( + f"skipping {failed_index} already passed items (cache from {cache_age} ago," + f" use --sw-reset to discard)." + ) + deselected = items[:failed_index] + del items[:failed_index] + config.hook.pytest_deselected(items=deselected) + + def pytest_runtest_logreport(self, report: TestReport) -> None: + if report.failed: + if self.skip: + # Remove test from the failed ones (if it exists) and unset the skip option + # to make sure the following tests will not be skipped. + if report.nodeid == self.cached_info.last_failed: + self.cached_info.last_failed = None + + self.skip = False + else: + # Mark test as the last failing and interrupt the test session. + self.cached_info.last_failed = report.nodeid + assert self.session is not None + self.session.shouldstop = ( + "Test failed, continuing from this test next run." + ) + + else: + # If the test was actually run and did pass. + if report.when == "call": + # Remove test from the failed ones, if exists. + if report.nodeid == self.cached_info.last_failed: + self.cached_info.last_failed = None + + def pytest_report_collectionfinish(self) -> list[str] | None: + if self.config.get_verbosity() >= 0 and self.report_status: + return [f"stepwise: {x}" for x in self.report_status] + return None + + def pytest_sessionfinish(self) -> None: + if hasattr(self.config, "workerinput"): + # Do not update cache if this process is a xdist worker to prevent + # race conditions (#10641). + return + self.cached_info.update_date_to_now() + self.cache.set(STEPWISE_CACHE_DIR, dataclasses.asdict(self.cached_info)) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/subtests.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/subtests.py new file mode 100644 index 0000000000000000000000000000000000000000..e0ceb27f4b1ca8f6681faf082c314fc1bebd3f04 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/subtests.py @@ -0,0 +1,411 @@ +"""Builtin plugin that adds subtests support.""" + +from __future__ import annotations + +from collections import defaultdict +from collections.abc import Callable +from collections.abc import Iterator +from collections.abc import Mapping +from contextlib import AbstractContextManager +from contextlib import contextmanager +from contextlib import ExitStack +from contextlib import nullcontext +import dataclasses +import time +from types import TracebackType +from typing import Any +from typing import TYPE_CHECKING + +import pluggy + +from _pytest._code import ExceptionInfo +from _pytest._io.saferepr import saferepr +from _pytest.capture import CaptureFixture +from _pytest.capture import FDCapture +from _pytest.capture import SysCapture +from _pytest.config import Config +from _pytest.config import hookimpl +from _pytest.config.argparsing import Parser +from _pytest.deprecated import check_ispytest +from _pytest.fixtures import fixture +from _pytest.fixtures import SubRequest +from _pytest.logging import catching_logs +from _pytest.logging import LogCaptureHandler +from _pytest.logging import LoggingPlugin +from _pytest.reports import TestReport +from _pytest.runner import CallInfo +from _pytest.runner import check_interactive_exception +from _pytest.runner import get_reraise_exceptions +from _pytest.stash import StashKey + + +if TYPE_CHECKING: + from typing_extensions import Self + + +def pytest_addoption(parser: Parser) -> None: + Config._add_verbosity_ini( + parser, + Config.VERBOSITY_SUBTESTS, + help=( + "Specify verbosity level for subtests. " + "Higher levels will generate output for passed subtests. Failed subtests are always reported." + ), + ) + + +@dataclasses.dataclass(frozen=True, slots=True, kw_only=True) +class SubtestContext: + """The values passed to Subtests.test() that are included in the test report.""" + + msg: str | None + kwargs: Mapping[str, Any] + + def _to_json(self) -> dict[str, Any]: + return dataclasses.asdict(self) + + @classmethod + def _from_json(cls, d: dict[str, Any]) -> Self: + return cls(msg=d["msg"], kwargs=d["kwargs"]) + + +@dataclasses.dataclass(init=False) +class SubtestReport(TestReport): + context: SubtestContext + + @property + def head_line(self) -> str: + _, _, domain = self.location + return f"{domain} {self._sub_test_description()}" + + def _sub_test_description(self) -> str: + parts = [] + if self.context.msg is not None: + parts.append(f"[{self.context.msg}]") + if self.context.kwargs: + params_desc = ", ".join( + f"{k}={saferepr(v)}" for (k, v) in self.context.kwargs.items() + ) + parts.append(f"({params_desc})") + return " ".join(parts) or "(<subtest>)" + + def _to_json(self) -> dict[str, Any]: + data = super()._to_json() + del data["context"] + data["_report_type"] = "SubTestReport" + data["_subtest.context"] = self.context._to_json() + return data + + @classmethod + def _from_json(cls, reportdict: dict[str, Any]) -> SubtestReport: + report = super()._from_json(reportdict) + report.context = SubtestContext._from_json(reportdict["_subtest.context"]) + return report + + @classmethod + def _new( + cls, + test_report: TestReport, + context: SubtestContext, + captured_output: Captured | None, + captured_logs: CapturedLogs | None, + ) -> Self: + result = super()._from_json(test_report._to_json()) + result.context = context + + if captured_output: + if captured_output.out: + result.sections.append(("Captured stdout call", captured_output.out)) + if captured_output.err: + result.sections.append(("Captured stderr call", captured_output.err)) + + if captured_logs and (log := captured_logs.handler.stream.getvalue()): + result.sections.append(("Captured log call", log)) + + return result + + +@fixture +def subtests(request: SubRequest) -> Subtests: + """Provides subtests functionality.""" + capmam = request.node.config.pluginmanager.get_plugin("capturemanager") + suspend_capture_ctx = ( + capmam.global_and_fixture_disabled if capmam is not None else nullcontext + ) + return Subtests(request.node.ihook, suspend_capture_ctx, request, _ispytest=True) + + +class Subtests: + """Subtests fixture, enables declaring subtests inside test functions via the :meth:`test` method.""" + + def __init__( + self, + ihook: pluggy.HookRelay, + suspend_capture_ctx: Callable[[], AbstractContextManager[None]], + request: SubRequest, + *, + _ispytest: bool = False, + ) -> None: + check_ispytest(_ispytest) + self._ihook = ihook + self._suspend_capture_ctx = suspend_capture_ctx + self._request = request + + def test( + self, + msg: str | None = None, + **kwargs: Any, + ) -> _SubTestContextManager: + """ + Context manager for subtests, capturing exceptions raised inside the subtest scope and + reporting assertion failures and errors individually. + + Usage + ----- + + .. code-block:: python + + def test(subtests): + for i in range(5): + with subtests.test("custom message", i=i): + assert i % 2 == 0 + + :param msg: + If given, the message will be shown in the test report in case of subtest failure. + + :param kwargs: + Arbitrary values that are also added to the subtest report. + """ + return _SubTestContextManager( + self._ihook, + msg, + kwargs, + request=self._request, + suspend_capture_ctx=self._suspend_capture_ctx, + config=self._request.config, + ) + + +@dataclasses.dataclass +class _SubTestContextManager: + """ + Context manager for subtests, capturing exceptions raised inside the subtest scope and handling + them through the pytest machinery. + """ + + # Note: initially the logic for this context manager was implemented directly + # in Subtests.test() as a @contextmanager, however, it is not possible to control the output fully when + # exiting from it due to an exception when in `--exitfirst` mode, so this was refactored into an + # explicit context manager class (pytest-dev/pytest-subtests#134). + + ihook: pluggy.HookRelay + msg: str | None + kwargs: dict[str, Any] + suspend_capture_ctx: Callable[[], AbstractContextManager[None]] + request: SubRequest + config: Config + + def __enter__(self) -> None: + __tracebackhide__ = True + + self._start = time.time() + self._precise_start = time.perf_counter() + self._exc_info = None + + self._exit_stack = ExitStack() + self._captured_output = self._exit_stack.enter_context( + capturing_output(self.request) + ) + self._captured_logs = self._exit_stack.enter_context( + capturing_logs(self.request) + ) + + def __exit__( + self, + exc_type: type[BaseException] | None, + exc_val: BaseException | None, + exc_tb: TracebackType | None, + ) -> bool: + __tracebackhide__ = True + if exc_val is not None: + exc_info = ExceptionInfo.from_exception(exc_val) + else: + exc_info = None + + self._exit_stack.close() + + precise_stop = time.perf_counter() + duration = precise_stop - self._precise_start + stop = time.time() + + call_info = CallInfo[None]( + None, + exc_info, + start=self._start, + stop=stop, + duration=duration, + when="call", + _ispytest=True, + ) + report = self.ihook.pytest_runtest_makereport( + item=self.request.node, call=call_info + ) + sub_report = SubtestReport._new( + report, + SubtestContext(msg=self.msg, kwargs=self.kwargs), + captured_output=self._captured_output, + captured_logs=self._captured_logs, + ) + + if sub_report.failed: + failed_subtests = self.config.stash[failed_subtests_key] + failed_subtests[self.request.node.nodeid] += 1 + + with self.suspend_capture_ctx(): + self.ihook.pytest_runtest_logreport(report=sub_report) + + if check_interactive_exception(call_info, sub_report): + self.ihook.pytest_exception_interact( + node=self.request.node, call=call_info, report=sub_report + ) + + if exc_val is not None: + if isinstance(exc_val, get_reraise_exceptions(self.config)): + return False + if self.request.session.shouldfail: + return False + return True + + +@contextmanager +def capturing_output(request: SubRequest) -> Iterator[Captured]: + option = request.config.getoption("capture", None) + + capman = request.config.pluginmanager.getplugin("capturemanager") + if getattr(capman, "_capture_fixture", None): + # capsys or capfd are active, subtest should not capture. + fixture = None + elif option == "sys": + fixture = CaptureFixture(SysCapture, request, _ispytest=True) + elif option == "fd": + fixture = CaptureFixture(FDCapture, request, _ispytest=True) + else: + fixture = None + + if fixture is not None: + fixture._start() + + captured = Captured() + try: + yield captured + finally: + if fixture is not None: + out, err = fixture.readouterr() + fixture.close() + captured.out = out + captured.err = err + + +@contextmanager +def capturing_logs( + request: SubRequest, +) -> Iterator[CapturedLogs | None]: + logging_plugin: LoggingPlugin | None = request.config.pluginmanager.getplugin( + "logging-plugin" + ) + if logging_plugin is None: + yield None + else: + handler = LogCaptureHandler() + handler.setFormatter(logging_plugin.formatter) + + captured_logs = CapturedLogs(handler) + with catching_logs(handler, level=logging_plugin.log_level): + yield captured_logs + + +@dataclasses.dataclass +class Captured: + out: str = "" + err: str = "" + + +@dataclasses.dataclass +class CapturedLogs: + handler: LogCaptureHandler + + +def pytest_report_to_serializable(report: TestReport) -> dict[str, Any] | None: + if isinstance(report, SubtestReport): + return report._to_json() + return None + + +def pytest_report_from_serializable(data: dict[str, Any]) -> SubtestReport | None: + if data.get("_report_type") == "SubTestReport": + return SubtestReport._from_json(data) + return None + + +# Dict of nodeid -> number of failed subtests. +# Used to fail top-level tests that passed but contain failed subtests. +failed_subtests_key = StashKey[defaultdict[str, int]]() + + +def pytest_configure(config: Config) -> None: + config.stash[failed_subtests_key] = defaultdict(lambda: 0) + + +@hookimpl(tryfirst=True) +def pytest_report_teststatus( + report: TestReport, + config: Config, +) -> tuple[str, str, str | Mapping[str, bool]] | None: + if report.when != "call": + return None + + quiet = config.get_verbosity(Config.VERBOSITY_SUBTESTS) == 0 + if isinstance(report, SubtestReport): + outcome = report.outcome + description = report._sub_test_description() + + if hasattr(report, "wasxfail"): + if quiet: + return "", "", "" + elif outcome == "skipped": + category = "xfailed" + short = "y" # x letter is used for regular xfail, y for subtest xfail + status = "SUBXFAIL" + # outcome == "passed" in an xfail is only possible via a @pytest.mark.xfail mark, which + # is not applicable to a subtest, which only handles pytest.xfail(). + else: # pragma: no cover + # This should not normally happen, unless some plugin is setting wasxfail without + # the correct outcome. Pytest expects the call outcome to be either skipped or + # passed in case of xfail. + # Let's pass this report to the next hook. + return None + return category, short, f"{status}{description}" + + if report.failed: + return outcome, "u", f"SUBFAILED{description}" + else: + if report.passed: + if quiet: + return "", "", "" + else: + return f"subtests {outcome}", "u", f"SUBPASSED{description}" + elif report.skipped: + if quiet: + return "", "", "" + else: + return outcome, "-", f"SUBSKIPPED{description}" + + else: + failed_subtests_count = config.stash[failed_subtests_key][report.nodeid] + # Top-level test, fail if it contains failed subtests and it has passed. + if report.passed and failed_subtests_count > 0: + report.outcome = "failed" + suffix = "s" if failed_subtests_count > 1 else "" + report.longrepr = f"contains {failed_subtests_count} failed subtest{suffix}" + + return None diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/terminal.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/terminal.py new file mode 100644 index 0000000000000000000000000000000000000000..e66e4f48dd69b1127185e46cb9c0a95390268909 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/terminal.py @@ -0,0 +1,1763 @@ +# mypy: allow-untyped-defs +"""Terminal reporting of the full testing process. + +This is a good source for looking at the various reporting hooks. +""" + +from __future__ import annotations + +import argparse +from collections import Counter +from collections.abc import Callable +from collections.abc import Generator +from collections.abc import Mapping +from collections.abc import Sequence +import dataclasses +import datetime +from functools import partial +import inspect +from pathlib import Path +import platform +import sys +import textwrap +from typing import Any +from typing import ClassVar +from typing import final +from typing import Literal +from typing import NamedTuple +from typing import TextIO +from typing import TYPE_CHECKING +import warnings + +import pluggy + +from _pytest import compat +from _pytest import nodes +from _pytest import timing +from _pytest._code import ExceptionInfo +from _pytest._code.code import ExceptionRepr +from _pytest._io import TerminalWriter +from _pytest._io.wcwidth import wcswidth +import _pytest._version +from _pytest.compat import running_on_ci +from _pytest.config import _PluggyPlugin +from _pytest.config import Config +from _pytest.config import ExitCode +from _pytest.config import hookimpl +from _pytest.config.argparsing import Parser +from _pytest.nodes import Item +from _pytest.nodes import Node +from _pytest.pathlib import absolutepath +from _pytest.pathlib import bestrelpath +from _pytest.reports import BaseReport +from _pytest.reports import CollectReport +from _pytest.reports import TestReport + + +if TYPE_CHECKING: + from _pytest.main import Session + + +REPORT_COLLECTING_RESOLUTION = 0.5 + +KNOWN_TYPES = ( + "failed", + "passed", + "skipped", + "deselected", + "xfailed", + "xpassed", + "warnings", + "error", + "subtests passed", + "subtests failed", + "subtests skipped", +) + +_REPORTCHARS_DEFAULT = "fE" + + +class MoreQuietAction(argparse.Action): + """A modified copy of the argparse count action which counts down and updates + the legacy quiet attribute at the same time. + + Used to unify verbosity handling. + """ + + def __init__( + self, + option_strings: Sequence[str], + dest: str, + default: object = None, + required: bool = False, + help: str | None = None, + ) -> None: + super().__init__( + option_strings=option_strings, + dest=dest, + nargs=0, + default=default, + required=required, + help=help, + ) + + def __call__( + self, + parser: argparse.ArgumentParser, + namespace: argparse.Namespace, + values: str | Sequence[object] | None, + option_string: str | None = None, + ) -> None: + new_count = getattr(namespace, self.dest, 0) - 1 + setattr(namespace, self.dest, new_count) + # todo Deprecate config.quiet + namespace.quiet = getattr(namespace, "quiet", 0) + 1 + + +class TestShortLogReport(NamedTuple): + """Used to store the test status result category, shortletter and verbose word. + For example ``"rerun", "R", ("RERUN", {"yellow": True})``. + + :ivar category: + The class of result, for example ``“passed”``, ``“skipped”``, ``“error”``, or the empty string. + + :ivar letter: + The short letter shown as testing progresses, for example ``"."``, ``"s"``, ``"E"``, or the empty string. + + :ivar word: + Verbose word is shown as testing progresses in verbose mode, for example ``"PASSED"``, ``"SKIPPED"``, + ``"ERROR"``, or the empty string. + """ + + category: str + letter: str + word: str | tuple[str, Mapping[str, bool]] + + +def pytest_addoption(parser: Parser) -> None: + group = parser.getgroup("terminal reporting", "Reporting", after="general") + group._addoption( # private to use reserved lower-case short option + "-v", + "--verbose", + action="count", + default=0, + dest="verbose", + help="Increase verbosity", + ) + group.addoption( + "--no-header", + action="store_true", + default=False, + dest="no_header", + help="Disable header", + ) + group.addoption( + "--no-summary", + action="store_true", + default=False, + dest="no_summary", + help="Disable summary", + ) + group.addoption( + "--no-fold-skipped", + action="store_false", + dest="fold_skipped", + default=True, + help="Do not fold skipped tests in short summary.", + ) + group.addoption( + "--force-short-summary", + action="store_true", + dest="force_short_summary", + default=False, + help="Force condensed summary output regardless of verbosity level.", + ) + group._addoption( # private to use reserved lower-case short option + "-q", + "--quiet", + action=MoreQuietAction, + default=0, + dest="verbose", + help="Decrease verbosity", + ) + group.addoption( + "--verbosity", + dest="verbose", + type=int, + default=0, + help="Set verbosity. Default: 0.", + ) + group._addoption( # private to use reserved lower-case short option + "-r", + action="store", + dest="reportchars", + default=_REPORTCHARS_DEFAULT, + metavar="chars", + help="Show extra test summary info as specified by chars: (f)ailed, " + "(E)rror, (s)kipped, (x)failed, (X)passed, " + "(p)assed, (P)assed with output, (a)ll except passed (p/P), or (A)ll. " + "(w)arnings are enabled by default (see --disable-warnings), " + "'N' can be used to reset the list. (default: 'fE').", + ) + group.addoption( + "--disable-warnings", + "--disable-pytest-warnings", + default=False, + dest="disable_warnings", + action="store_true", + help="Disable warnings summary", + ) + group._addoption( # private to use reserved lower-case short option + "-l", + "--showlocals", + action="store_true", + dest="showlocals", + default=False, + help="Show locals in tracebacks (disabled by default)", + ) + group.addoption( + "--no-showlocals", + action="store_false", + dest="showlocals", + help="Hide locals in tracebacks (negate --showlocals passed through addopts)", + ) + group.addoption( + "--tb", + metavar="style", + action="store", + dest="tbstyle", + default="auto", + choices=["auto", "long", "short", "no", "line", "native"], + help="Traceback print mode (auto/long/short/line/native/no)", + ) + group.addoption( + "--xfail-tb", + action="store_true", + dest="xfail_tb", + default=False, + help="Show tracebacks for xfail (as long as --tb != no)", + ) + group.addoption( + "--show-capture", + action="store", + dest="showcapture", + choices=["no", "stdout", "stderr", "log", "all"], + default="all", + help="Controls how captured stdout/stderr/log is shown on failed tests. " + "Default: all.", + ) + group.addoption( + "--fulltrace", + "--full-trace", + action="store_true", + default=False, + help="Don't cut any tracebacks (default is to cut)", + ) + group.addoption( + "--color", + metavar="color", + action="store", + dest="color", + default="auto", + choices=["yes", "no", "auto"], + help="Color terminal output (yes/no/auto)", + ) + group.addoption( + "--code-highlight", + default="yes", + choices=["yes", "no"], + help="Whether code should be highlighted (only if --color is also enabled). " + "Default: yes.", + ) + + parser.addini( + "console_output_style", + help='Console output: "classic", or with additional progress information ' + '("progress" (percentage) | "count" | "progress-even-when-capture-no" (forces ' + "progress even when capture=no)", + default="progress", + ) + Config._add_verbosity_ini( + parser, + Config.VERBOSITY_TEST_CASES, + help=( + "Specify a verbosity level for test case execution, overriding the main level. " + "Higher levels will provide more detailed information about each test case executed." + ), + ) + + +def pytest_configure(config: Config) -> None: + reporter = TerminalReporter(config, sys.stdout) + config.pluginmanager.register(reporter, "terminalreporter") + if config.option.debug or config.option.traceconfig: + + def mywriter(tags, args): + msg = " ".join(map(str, args)) + reporter.write_line("[traceconfig] " + msg) + + config.trace.root.setprocessor("pytest:config", mywriter) + + # See terminalprogress.py. + # On Windows it's safe to load by default. + if sys.platform == "win32": + config.pluginmanager.import_plugin("terminalprogress") + + +def getreportopt(config: Config) -> str: + reportchars: str = config.option.reportchars + + old_aliases = {"F", "S"} + reportopts = "" + for char in reportchars: + if char in old_aliases: + char = char.lower() + if char == "a": + reportopts = "sxXEf" + elif char == "A": + reportopts = "PpsxXEf" + elif char == "N": + reportopts = "" + elif char not in reportopts: + reportopts += char + + if not config.option.disable_warnings and "w" not in reportopts: + reportopts = "w" + reportopts + elif config.option.disable_warnings and "w" in reportopts: + reportopts = reportopts.replace("w", "") + + return reportopts + + +@hookimpl(trylast=True) # after _pytest.runner +def pytest_report_teststatus(report: BaseReport) -> tuple[str, str, str]: + letter = "F" + if report.passed: + letter = "." + elif report.skipped: + letter = "s" + + outcome: str = report.outcome + if report.when in ("collect", "setup", "teardown") and outcome == "failed": + outcome = "error" + letter = "E" + + return outcome, letter, outcome.upper() + + +@dataclasses.dataclass +class WarningReport: + """Simple structure to hold warnings information captured by ``pytest_warning_recorded``. + + :ivar str message: + User friendly message about the warning. + :ivar str|None nodeid: + nodeid that generated the warning (see ``get_location``). + :ivar tuple fslocation: + File system location of the source of the warning (see ``get_location``). + """ + + message: str + nodeid: str | None = None + fslocation: tuple[str, int] | None = None + + count_towards_summary: ClassVar = True + + def get_location(self, config: Config) -> str | None: + """Return the more user-friendly information about the location of a warning, or None.""" + if self.nodeid: + return self.nodeid + if self.fslocation: + filename, linenum = self.fslocation + relpath = bestrelpath(config.invocation_params.dir, absolutepath(filename)) + return f"{relpath}:{linenum}" + return None + + +@final +class TerminalReporter: + def __init__(self, config: Config, file: TextIO | None = None) -> None: + import _pytest.config + + self.config = config + self._numcollected = 0 + self._session: Session | None = None + self._showfspath: bool | None = None + + self.stats: dict[str, list[Any]] = {} + self._main_color: str | None = None + self._known_types: list[str] | None = None + self.startpath = config.invocation_params.dir + if file is None: + file = sys.stdout + self._tw = _pytest.config.create_terminal_writer(config, file) + self._screen_width = self._tw.fullwidth + self.currentfspath: None | Path | str | int = None + self.reportchars = getreportopt(config) + self.foldskipped = config.option.fold_skipped + self.hasmarkup = self._tw.hasmarkup + # isatty should be a method but was wrongly implemented as a boolean. + # We use CallableBool here to support both. + self.isatty = compat.CallableBool(file.isatty()) + self._progress_nodeids_reported: set[str] = set() + self._timing_nodeids_reported: set[str] = set() + self._show_progress_info = self._determine_show_progress_info() + self._collect_report_last_write = timing.Instant() + self._already_displayed_warnings: int | None = None + self._keyboardinterrupt_memo: ExceptionRepr | None = None + + def _determine_show_progress_info( + self, + ) -> Literal["progress", "count", "times", False]: + """Return whether we should display progress information based on the current config.""" + # do not show progress if we are not capturing output (#3038) unless explicitly + # overridden by progress-even-when-capture-no + if ( + self.config.getoption("capture", "no") == "no" + and self.config.getini("console_output_style") + != "progress-even-when-capture-no" + ): + return False + # do not show progress if we are showing fixture setup/teardown + if self.config.getoption("setupshow", False): + return False + cfg: str = self.config.getini("console_output_style") + if cfg in {"progress", "progress-even-when-capture-no"}: + return "progress" + elif cfg == "count": + return "count" + elif cfg == "times": + return "times" + else: + return False + + @property + def verbosity(self) -> int: + verbosity: int = self.config.option.verbose + return verbosity + + @property + def showheader(self) -> bool: + return self.verbosity >= 0 + + @property + def no_header(self) -> bool: + return bool(self.config.option.no_header) + + @property + def no_summary(self) -> bool: + return bool(self.config.option.no_summary) + + @property + def showfspath(self) -> bool: + if self._showfspath is None: + return self.config.get_verbosity(Config.VERBOSITY_TEST_CASES) >= 0 + return self._showfspath + + @showfspath.setter + def showfspath(self, value: bool | None) -> None: + self._showfspath = value + + @property + def showlongtestinfo(self) -> bool: + return self.config.get_verbosity(Config.VERBOSITY_TEST_CASES) > 0 + + @property + def reported_progress(self) -> int: + """The amount of items reported in the progress so far. + + :meta private: + """ + return len(self._progress_nodeids_reported) + + def hasopt(self, char: str) -> bool: + char = {"xfailed": "x", "skipped": "s"}.get(char, char) + return char in self.reportchars + + def write_fspath_result(self, nodeid: str, res: str, **markup: bool) -> None: + fspath = self.config.rootpath / nodeid.split("::")[0] + if self.currentfspath is None or fspath != self.currentfspath: + if self.currentfspath is not None and self._show_progress_info: + self._write_progress_information_filling_space() + self.currentfspath = fspath + relfspath = bestrelpath(self.startpath, fspath) + self._tw.line() + self._tw.write(relfspath + " ") + self._tw.write(res, flush=True, **markup) + + def write_ensure_prefix(self, prefix: str, extra: str = "", **kwargs) -> None: + if self.currentfspath != prefix: + self._tw.line() + self.currentfspath = prefix + self._tw.write(prefix) + if extra: + self._tw.write(extra, **kwargs) + self.currentfspath = -2 + + def ensure_newline(self) -> None: + if self.currentfspath: + self._tw.line() + self.currentfspath = None + + def wrap_write( + self, + content: str, + *, + flush: bool = False, + margin: int = 8, + line_sep: str = "\n", + **markup: bool, + ) -> None: + """Wrap message with margin for progress info.""" + width_of_current_line = self._tw.width_of_current_line + wrapped = line_sep.join( + textwrap.wrap( + " " * width_of_current_line + content, + width=self._screen_width - margin, + drop_whitespace=True, + replace_whitespace=False, + ), + ) + wrapped = wrapped[width_of_current_line:] + self._tw.write(wrapped, flush=flush, **markup) + + def write(self, content: str, *, flush: bool = False, **markup: bool) -> None: + self._tw.write(content, flush=flush, **markup) + + def write_raw(self, content: str, *, flush: bool = False) -> None: + self._tw.write_raw(content, flush=flush) + + def flush(self) -> None: + self._tw.flush() + + def write_line(self, line: str | bytes, **markup: bool) -> None: + if not isinstance(line, str): + line = str(line, errors="replace") + self.ensure_newline() + self._tw.line(line, **markup) + + def rewrite(self, line: str, **markup: bool) -> None: + """Rewinds the terminal cursor to the beginning and writes the given line. + + :param erase: + If True, will also add spaces until the full terminal width to ensure + previous lines are properly erased. + + The rest of the keyword arguments are markup instructions. + """ + erase = markup.pop("erase", False) + if erase: + fill_count = self._tw.fullwidth - len(line) - 1 + fill = " " * fill_count + else: + fill = "" + line = str(line) + self._tw.write("\r" + line + fill, **markup) + + def write_sep( + self, + sep: str, + title: str | None = None, + fullwidth: int | None = None, + **markup: bool, + ) -> None: + self.ensure_newline() + self._tw.sep(sep, title, fullwidth, **markup) + + def section(self, title: str, sep: str = "=", **kw: bool) -> None: + self._tw.sep(sep, title, **kw) + + def line(self, msg: str, **kw: bool) -> None: + self._tw.line(msg, **kw) + + def _add_stats(self, category: str, items: Sequence[Any]) -> None: + set_main_color = category not in self.stats + self.stats.setdefault(category, []).extend(items) + if set_main_color: + self._set_main_color() + + def pytest_internalerror(self, excrepr: ExceptionRepr) -> bool: + for line in str(excrepr).split("\n"): + self.write_line("INTERNALERROR> " + line) + return True + + def pytest_warning_recorded( + self, + warning_message: warnings.WarningMessage, + nodeid: str, + ) -> None: + from _pytest.warnings import warning_record_to_str + + fslocation = warning_message.filename, warning_message.lineno + message = warning_record_to_str(warning_message) + + warning_report = WarningReport( + fslocation=fslocation, message=message, nodeid=nodeid + ) + self._add_stats("warnings", [warning_report]) + + def pytest_plugin_registered(self, plugin: _PluggyPlugin) -> None: + if self.config.option.traceconfig: + msg = f"PLUGIN registered: {plugin}" + # XXX This event may happen during setup/teardown time + # which unfortunately captures our output here + # which garbles our output if we use self.write_line. + self.write_line(msg) + + def pytest_deselected(self, items: Sequence[Item]) -> None: + self._add_stats("deselected", items) + + def pytest_runtest_logstart( + self, nodeid: str, location: tuple[str, int | None, str] + ) -> None: + fspath, lineno, domain = location + # Ensure that the path is printed before the + # 1st test of a module starts running. + if self.showlongtestinfo: + line = self._locationline(nodeid, fspath, lineno, domain) + self.write_ensure_prefix(line, "") + self.flush() + elif self.showfspath: + self.write_fspath_result(nodeid, "") + self.flush() + + def pytest_runtest_logreport(self, report: TestReport) -> None: + self._tests_ran = True + rep = report + + res = TestShortLogReport( + *self.config.hook.pytest_report_teststatus(report=rep, config=self.config) + ) + category, letter, word = res.category, res.letter, res.word + if not isinstance(word, tuple): + markup = None + else: + word, markup = word + self._add_stats(category, [rep]) + if not letter and not word: + # Probably passed setup/teardown. + return + if markup is None: + was_xfail = hasattr(report, "wasxfail") + if rep.passed and not was_xfail: + markup = {"green": True} + elif rep.passed and was_xfail: + markup = {"yellow": True} + elif rep.failed: + markup = {"red": True} + elif rep.skipped: + markup = {"yellow": True} + else: + markup = {} + self._progress_nodeids_reported.add(rep.nodeid) + if self.config.get_verbosity(Config.VERBOSITY_TEST_CASES) <= 0: + self._tw.write(letter, **markup) + # When running in xdist, the logreport and logfinish of multiple + # items are interspersed, e.g. `logreport`, `logreport`, + # `logfinish`, `logfinish`. To avoid the "past edge" calculation + # from getting confused and overflowing (#7166), do the past edge + # printing here and not in logfinish, except for the 100% which + # should only be printed after all teardowns are finished. + if self._show_progress_info and not self._is_last_item: + self._write_progress_information_if_past_edge() + else: + line = self._locationline(rep.nodeid, *rep.location) + running_xdist = hasattr(rep, "node") + if not running_xdist: + self.write_ensure_prefix(line, word, **markup) + if rep.skipped or hasattr(report, "wasxfail"): + reason = _get_raw_skip_reason(rep) + if self.config.get_verbosity(Config.VERBOSITY_TEST_CASES) < 2: + available_width = ( + (self._tw.fullwidth - self._tw.width_of_current_line) + - len(" [100%]") + - 1 + ) + formatted_reason = _format_trimmed( + " ({})", reason, available_width + ) + else: + formatted_reason = f" ({reason})" + + if reason and formatted_reason is not None: + self.wrap_write(formatted_reason) + if self._show_progress_info: + self._write_progress_information_filling_space() + else: + self.ensure_newline() + self._tw.write(f"[{rep.node.gateway.id}]") + if self._show_progress_info: + self._tw.write( + self._get_progress_information_message() + " ", cyan=True + ) + else: + self._tw.write(" ") + self._tw.write(word, **markup) + self._tw.write(" " + line) + self.currentfspath = -2 + self.flush() + + @property + def _is_last_item(self) -> bool: + assert self._session is not None + return self.reported_progress == self._session.testscollected + + @hookimpl(wrapper=True) + def pytest_runtestloop(self) -> Generator[None, object, object]: + result = yield + + # Write the final/100% progress -- deferred until the loop is complete. + if ( + self.config.get_verbosity(Config.VERBOSITY_TEST_CASES) <= 0 + and self._show_progress_info + and self.reported_progress + ): + self._write_progress_information_filling_space() + + return result + + def _get_progress_information_message(self) -> str: + assert self._session + collected = self._session.testscollected + if self._show_progress_info == "count": + if collected: + progress = self.reported_progress + counter_format = f"{{:{len(str(collected))}d}}" + format_string = f" [{counter_format}/{{}}]" + return format_string.format(progress, collected) + return f" [ {collected} / {collected} ]" + if self._show_progress_info == "times": + if not collected: + return "" + all_reports = ( + self._get_reports_to_display("passed") + + self._get_reports_to_display("xpassed") + + self._get_reports_to_display("failed") + + self._get_reports_to_display("xfailed") + + self._get_reports_to_display("skipped") + + self._get_reports_to_display("error") + + self._get_reports_to_display("") + ) + current_location = all_reports[-1].location[0] + not_reported = [ + r for r in all_reports if r.nodeid not in self._timing_nodeids_reported + ] + tests_in_module = sum( + i.location[0] == current_location for i in self._session.items + ) + tests_completed = sum( + r.when == "setup" + for r in not_reported + if r.location[0] == current_location + ) + last_in_module = tests_completed == tests_in_module + if self.showlongtestinfo or last_in_module: + self._timing_nodeids_reported.update(r.nodeid for r in not_reported) + return format_node_duration( + sum(r.duration for r in not_reported if isinstance(r, TestReport)) + ) + return "" + if collected: + return f" [{self.reported_progress * 100 // collected:3d}%]" + return " [100%]" + + def _write_progress_information_if_past_edge(self) -> None: + w = self._width_of_current_line + if self._show_progress_info == "count": + assert self._session + num_tests = self._session.testscollected + progress_length = len(f" [{num_tests}/{num_tests}]") + elif self._show_progress_info == "times": + progress_length = len(" 99h 59m") + else: + progress_length = len(" [100%]") + past_edge = w + progress_length + 1 >= self._screen_width + if past_edge: + main_color, _ = self._get_main_color() + msg = self._get_progress_information_message() + self._tw.write(msg + "\n", **{main_color: True}) + + def _write_progress_information_filling_space(self) -> None: + color, _ = self._get_main_color() + msg = self._get_progress_information_message() + w = self._width_of_current_line + fill = self._tw.fullwidth - w - 1 + self.write(msg.rjust(fill), flush=True, **{color: True}) + + @property + def _width_of_current_line(self) -> int: + """Return the width of the current line.""" + return self._tw.width_of_current_line + + def pytest_collection(self) -> None: + if self.isatty(): + if self.config.option.verbose >= 0: + self.write("collecting ... ", flush=True, bold=True) + elif self.config.option.verbose >= 1: + self.write("collecting ... ", flush=True, bold=True) + + def pytest_collectreport(self, report: CollectReport) -> None: + if report.failed: + self._add_stats("error", [report]) + elif report.skipped: + self._add_stats("skipped", [report]) + items = [x for x in report.result if isinstance(x, Item)] + self._numcollected += len(items) + if self.isatty(): + self.report_collect() + + def report_collect(self, final: bool = False) -> None: + if self.config.option.verbose < 0: + return + + if not final: + # Only write the "collecting" report every `REPORT_COLLECTING_RESOLUTION`. + if ( + self._collect_report_last_write.elapsed().seconds + < REPORT_COLLECTING_RESOLUTION + ): + return + self._collect_report_last_write = timing.Instant() + + errors = len(self.stats.get("error", [])) + skipped = len(self.stats.get("skipped", [])) + deselected = len(self.stats.get("deselected", [])) + selected = self._numcollected - deselected + line = "collected " if final else "collecting " + line += ( + str(self._numcollected) + " item" + ("" if self._numcollected == 1 else "s") + ) + if errors: + line += f" / {errors} error{'s' if errors != 1 else ''}" + if deselected: + line += f" / {deselected} deselected" + if skipped: + line += f" / {skipped} skipped" + if self._numcollected > selected: + line += f" / {selected} selected" + if self.isatty(): + self.rewrite(line, bold=True, erase=True) + if final: + self.write("\n") + else: + self.write_line(line) + + @hookimpl(trylast=True) + def pytest_sessionstart(self, session: Session) -> None: + self._session = session + self._session_start = timing.Instant() + if not self.showheader: + return + self.write_sep("=", "test session starts", bold=True) + verinfo = platform.python_version() + if not self.no_header: + msg = f"platform {sys.platform} -- Python {verinfo}" + pypy_version_info = getattr(sys, "pypy_version_info", None) + if pypy_version_info: + verinfo = ".".join(map(str, pypy_version_info[:3])) + msg += f"[pypy-{verinfo}-{pypy_version_info[3]}]" + msg += f", pytest-{_pytest._version.version}, pluggy-{pluggy.__version__}" + if ( + self.verbosity > 0 + or self.config.option.debug + or getattr(self.config.option, "pastebin", None) + ): + msg += " -- " + str(sys.executable) + self.write_line(msg) + lines = self.config.hook.pytest_report_header( + config=self.config, start_path=self.startpath + ) + self._write_report_lines_from_hooks(lines) + + def _write_report_lines_from_hooks( + self, lines: Sequence[str | Sequence[str]] + ) -> None: + for line_or_lines in reversed(lines): + if isinstance(line_or_lines, str): + self.write_line(line_or_lines) + else: + for line in line_or_lines: + self.write_line(line) + + def pytest_report_header(self, config: Config) -> list[str]: + result = [f"rootdir: {config.rootpath}"] + + if config.inipath: + warning = "" + if config._ignored_config_files: + warning = f" (WARNING: ignoring pytest config in {', '.join(config._ignored_config_files)}!)" + result.append( + "configfile: " + bestrelpath(config.rootpath, config.inipath) + warning + ) + + if config.args_source == Config.ArgsSource.TESTPATHS: + testpaths: list[str] = config.getini("testpaths") + result.append("testpaths: {}".format(", ".join(testpaths))) + + plugininfo = config.pluginmanager.list_plugin_distinfo() + if plugininfo: + result.append( + "plugins: {}".format(", ".join(_plugin_nameversions(plugininfo))) + ) + return result + + def pytest_collection_finish(self, session: Session) -> None: + self.report_collect(True) + + lines = self.config.hook.pytest_report_collectionfinish( + config=self.config, + start_path=self.startpath, + items=session.items, + ) + self._write_report_lines_from_hooks(lines) + + if self.config.getoption("collectonly"): + if session.items: + if self.config.option.verbose > -1: + self._tw.line("") + self._printcollecteditems(session.items) + + failed = self.stats.get("failed") + if failed: + self._tw.sep("!", "collection failures") + for rep in failed: + rep.toterminal(self._tw) + + def _printcollecteditems(self, items: Sequence[Item]) -> None: + test_cases_verbosity = self.config.get_verbosity(Config.VERBOSITY_TEST_CASES) + if test_cases_verbosity < 0: + if test_cases_verbosity < -1: + counts = Counter(item.nodeid.split("::", 1)[0] for item in items) + for name, count in sorted(counts.items()): + self._tw.line(f"{name}: {count}") + else: + for item in items: + self._tw.line(item.nodeid) + return + stack: list[Node] = [] + indent = "" + for item in items: + needed_collectors = item.listchain()[1:] # strip root node + while stack: + if stack == needed_collectors[: len(stack)]: + break + stack.pop() + for col in needed_collectors[len(stack) :]: + stack.append(col) + indent = (len(stack) - 1) * " " + self._tw.line(f"{indent}{col}") + if test_cases_verbosity >= 1: + obj = getattr(col, "obj", None) + doc = inspect.getdoc(obj) if obj else None + if doc: + for line in doc.splitlines(): + self._tw.line("{}{}".format(indent + " ", line)) + + @hookimpl(wrapper=True) + def pytest_sessionfinish( + self, session: Session, exitstatus: int | ExitCode + ) -> Generator[None]: + result = yield + self._tw.line("") + summary_exit_codes = ( + ExitCode.OK, + ExitCode.TESTS_FAILED, + ExitCode.INTERRUPTED, + ExitCode.USAGE_ERROR, + ExitCode.NO_TESTS_COLLECTED, + ) + if exitstatus in summary_exit_codes and not self.no_summary: + self.config.hook.pytest_terminal_summary( + terminalreporter=self, exitstatus=exitstatus, config=self.config + ) + if session.shouldfail: + self.write_sep("!", str(session.shouldfail), red=True) + if exitstatus == ExitCode.INTERRUPTED: + self._report_keyboardinterrupt() + self._keyboardinterrupt_memo = None + elif session.shouldstop: + self.write_sep("!", str(session.shouldstop), red=True) + self.summary_stats() + return result + + @hookimpl(wrapper=True) + def pytest_terminal_summary(self) -> Generator[None]: + self.summary_errors() + self.summary_failures() + self.summary_xfailures() + self.summary_warnings() + self.summary_passes() + self.summary_xpasses() + try: + return (yield) + finally: + self.short_test_summary() + # Display any extra warnings from teardown here (if any). + self.summary_warnings() + + def pytest_keyboard_interrupt(self, excinfo: ExceptionInfo[BaseException]) -> None: + self._keyboardinterrupt_memo = excinfo.getrepr(funcargs=True) + + def pytest_unconfigure(self) -> None: + if self._keyboardinterrupt_memo is not None: + self._report_keyboardinterrupt() + + def _report_keyboardinterrupt(self) -> None: + excrepr = self._keyboardinterrupt_memo + assert excrepr is not None + assert excrepr.reprcrash is not None + msg = excrepr.reprcrash.message + self.write_sep("!", msg) + if "KeyboardInterrupt" in msg: + if self.config.option.fulltrace: + excrepr.toterminal(self._tw) + else: + excrepr.reprcrash.toterminal(self._tw) + self._tw.line( + "(to show a full traceback on KeyboardInterrupt use --full-trace)", + yellow=True, + ) + + def _locationline( + self, nodeid: str, fspath: str, lineno: int | None, domain: str + ) -> str: + def mkrel(nodeid: str) -> str: + line = self.config.cwd_relative_nodeid(nodeid) + if domain and line.endswith(domain): + line = line[: -len(domain)] + values = domain.split("[") + values[0] = values[0].replace(".", "::") # don't replace '.' in params + line += "[".join(values) + return line + + # fspath comes from testid which has a "/"-normalized path. + if fspath: + res = mkrel(nodeid) + if self.verbosity >= 2 and nodeid.split("::")[0] != fspath.replace( + "\\", nodes.SEP + ): + res += " <- " + bestrelpath(self.startpath, Path(fspath)) + else: + res = "[location]" + return res + " " + + def _getfailureheadline(self, rep): + head_line = rep.head_line + if head_line: + return head_line + return "test session" # XXX? + + def _getcrashline(self, rep): + try: + return str(rep.longrepr.reprcrash) + except AttributeError: + try: + return str(rep.longrepr)[:50] + except AttributeError: + return "" + + # + # Summaries for sessionfinish. + # + def getreports(self, name: str): + return [x for x in self.stats.get(name, ()) if not hasattr(x, "_pdbshown")] + + def summary_warnings(self) -> None: + if self.hasopt("w"): + all_warnings: list[WarningReport] | None = self.stats.get("warnings") + if not all_warnings: + return + + final = self._already_displayed_warnings is not None + if final: + warning_reports = all_warnings[self._already_displayed_warnings :] + else: + warning_reports = all_warnings + self._already_displayed_warnings = len(warning_reports) + if not warning_reports: + return + + reports_grouped_by_message: dict[str, list[WarningReport]] = {} + for wr in warning_reports: + reports_grouped_by_message.setdefault(wr.message, []).append(wr) + + def collapsed_location_report(reports: list[WarningReport]) -> str: + locations = [] + for w in reports: + location = w.get_location(self.config) + if location: + locations.append(location) + + if len(locations) < 10: + return "\n".join(map(str, locations)) + + counts_by_filename = Counter( + str(loc).split("::", 1)[0] for loc in locations + ) + return "\n".join( + "{}: {} warning{}".format(k, v, "s" if v > 1 else "") + for k, v in counts_by_filename.items() + ) + + title = "warnings summary (final)" if final else "warnings summary" + self.write_sep("=", title, yellow=True, bold=False) + for message, message_reports in reports_grouped_by_message.items(): + maybe_location = collapsed_location_report(message_reports) + if maybe_location: + self._tw.line(maybe_location) + lines = message.splitlines() + indented = "\n".join(" " + x for x in lines) + message = indented.rstrip() + else: + message = message.rstrip() + self._tw.line(message) + self._tw.line() + self._tw.line( + "-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html" + ) + + def summary_passes(self) -> None: + self.summary_passes_combined("passed", "PASSES", "P") + + def summary_xpasses(self) -> None: + self.summary_passes_combined("xpassed", "XPASSES", "X") + + def summary_passes_combined( + self, which_reports: str, sep_title: str, needed_opt: str + ) -> None: + if self.config.option.tbstyle != "no": + if self.hasopt(needed_opt): + reports: list[TestReport] = self.getreports(which_reports) + if not reports: + return + self.write_sep("=", sep_title) + for rep in reports: + if rep.sections: + msg = self._getfailureheadline(rep) + self.write_sep("_", msg, green=True, bold=True) + self._outrep_summary(rep) + self._handle_teardown_sections(rep.nodeid) + + def _get_teardown_reports(self, nodeid: str) -> list[TestReport]: + reports = self.getreports("") + return [ + report + for report in reports + if report.when == "teardown" and report.nodeid == nodeid + ] + + def _handle_teardown_sections(self, nodeid: str) -> None: + for report in self._get_teardown_reports(nodeid): + self.print_teardown_sections(report) + + def print_teardown_sections(self, rep: TestReport) -> None: + showcapture = self.config.option.showcapture + if showcapture == "no": + return + for secname, content in rep.sections: + if showcapture != "all" and showcapture not in secname: + continue + if "teardown" in secname: + self._tw.sep("-", secname) + if content[-1:] == "\n": + content = content[:-1] + self._tw.line(content) + + def summary_failures(self) -> None: + style = self.config.option.tbstyle + self.summary_failures_combined("failed", "FAILURES", style=style) + + def summary_xfailures(self) -> None: + show_tb = self.config.option.xfail_tb + style = self.config.option.tbstyle if show_tb else "no" + self.summary_failures_combined("xfailed", "XFAILURES", style=style) + + def summary_failures_combined( + self, + which_reports: str, + sep_title: str, + *, + style: str, + needed_opt: str | None = None, + ) -> None: + if style != "no": + if not needed_opt or self.hasopt(needed_opt): + reports: list[BaseReport] = self.getreports(which_reports) + if not reports: + return + self.write_sep("=", sep_title) + if style == "line": + for rep in reports: + line = self._getcrashline(rep) + self._outrep_summary(rep) + self.write_line(line) + else: + for rep in reports: + msg = self._getfailureheadline(rep) + self.write_sep("_", msg, red=True, bold=True) + self._outrep_summary(rep) + self._handle_teardown_sections(rep.nodeid) + + def summary_errors(self) -> None: + if self.config.option.tbstyle != "no": + reports: list[BaseReport] = self.getreports("error") + if not reports: + return + self.write_sep("=", "ERRORS") + for rep in self.stats["error"]: + msg = self._getfailureheadline(rep) + if rep.when == "collect": + msg = "ERROR collecting " + msg + else: + msg = f"ERROR at {rep.when} of {msg}" + self.write_sep("_", msg, red=True, bold=True) + self._outrep_summary(rep) + + def _outrep_summary(self, rep: BaseReport) -> None: + rep.toterminal(self._tw) + showcapture = self.config.option.showcapture + if showcapture == "no": + return + for secname, content in rep.sections: + if showcapture != "all" and showcapture not in secname: + continue + self._tw.sep("-", secname) + if content[-1:] == "\n": + content = content[:-1] + self._tw.line(content) + + def summary_stats(self) -> None: + if self.verbosity < -1: + return + + session_duration = self._session_start.elapsed() + (parts, main_color) = self.build_summary_stats_line() + line_parts = [] + + display_sep = self.verbosity >= 0 + if display_sep: + fullwidth = self._tw.fullwidth + for text, markup in parts: + with_markup = self._tw.markup(text, **markup) + if display_sep: + fullwidth += len(with_markup) - len(text) + line_parts.append(with_markup) + msg = ", ".join(line_parts) + + main_markup = {main_color: True} + duration = f" in {format_session_duration(session_duration.seconds)}" + duration_with_markup = self._tw.markup(duration, **main_markup) + if display_sep: + fullwidth += len(duration_with_markup) - len(duration) + msg += duration_with_markup + + if display_sep: + markup_for_end_sep = self._tw.markup("", **main_markup) + if markup_for_end_sep.endswith("\x1b[0m"): + markup_for_end_sep = markup_for_end_sep[:-4] + fullwidth += len(markup_for_end_sep) + msg += markup_for_end_sep + + if display_sep: + self.write_sep("=", msg, fullwidth=fullwidth, **main_markup) + else: + self.write_line(msg, **main_markup) + + def short_test_summary(self) -> None: + if not self.reportchars: + return + + def show_simple(lines: list[str], *, stat: str) -> None: + failed = self.stats.get(stat, []) + if not failed: + return + config = self.config + for rep in failed: + color = _color_for_type.get(stat, _color_for_type_default) + line = _get_line_with_reprcrash_message( + config, rep, self._tw, {color: True} + ) + lines.append(line) + + def show_xfailed(lines: list[str]) -> None: + xfailed = self.stats.get("xfailed", []) + for rep in xfailed: + verbose_word, verbose_markup = rep._get_verbose_word_with_markup( + self.config, {_color_for_type["warnings"]: True} + ) + markup_word = self._tw.markup(verbose_word, **verbose_markup) + nodeid = _get_node_id_with_markup(self._tw, self.config, rep) + line = f"{markup_word} {nodeid}" + reason = rep.wasxfail + if reason: + line += " - " + str(reason) + + lines.append(line) + + def show_xpassed(lines: list[str]) -> None: + xpassed = self.stats.get("xpassed", []) + for rep in xpassed: + verbose_word, verbose_markup = rep._get_verbose_word_with_markup( + self.config, {_color_for_type["warnings"]: True} + ) + markup_word = self._tw.markup(verbose_word, **verbose_markup) + nodeid = _get_node_id_with_markup(self._tw, self.config, rep) + line = f"{markup_word} {nodeid}" + reason = rep.wasxfail + if reason: + line += " - " + str(reason) + lines.append(line) + + def show_skipped_folded(lines: list[str]) -> None: + skipped: list[CollectReport] = self.stats.get("skipped", []) + fskips = _folded_skips(self.startpath, skipped) if skipped else [] + if not fskips: + return + verbose_word, verbose_markup = skipped[0]._get_verbose_word_with_markup( + self.config, {_color_for_type["warnings"]: True} + ) + markup_word = self._tw.markup(verbose_word, **verbose_markup) + prefix = "Skipped: " + for num, fspath, lineno, reason in fskips: + if reason.startswith(prefix): + reason = reason[len(prefix) :] + if lineno is not None: + lines.append(f"{markup_word} [{num}] {fspath}:{lineno}: {reason}") + else: + lines.append(f"{markup_word} [{num}] {fspath}: {reason}") + + def show_skipped_unfolded(lines: list[str]) -> None: + skipped: list[CollectReport] = self.stats.get("skipped", []) + + for rep in skipped: + assert rep.longrepr is not None + assert isinstance(rep.longrepr, tuple), (rep, rep.longrepr) + assert len(rep.longrepr) == 3, (rep, rep.longrepr) + + verbose_word, verbose_markup = rep._get_verbose_word_with_markup( + self.config, {_color_for_type["warnings"]: True} + ) + markup_word = self._tw.markup(verbose_word, **verbose_markup) + nodeid = _get_node_id_with_markup(self._tw, self.config, rep) + line = f"{markup_word} {nodeid}" + reason = rep.longrepr[2] + if reason: + line += " - " + str(reason) + lines.append(line) + + def show_skipped(lines: list[str]) -> None: + if self.foldskipped: + show_skipped_folded(lines) + else: + show_skipped_unfolded(lines) + + REPORTCHAR_ACTIONS: Mapping[str, Callable[[list[str]], None]] = { + "x": show_xfailed, + "X": show_xpassed, + "f": partial(show_simple, stat="failed"), + "s": show_skipped, + "p": partial(show_simple, stat="passed"), + "E": partial(show_simple, stat="error"), + } + + lines: list[str] = [] + for char in self.reportchars: + action = REPORTCHAR_ACTIONS.get(char) + if action: # skipping e.g. "P" (passed with output) here. + action(lines) + + if lines: + self.write_sep("=", "short test summary info", cyan=True, bold=True) + for line in lines: + self.write_line(line) + + def _get_main_color(self) -> tuple[str, list[str]]: + if self._main_color is None or self._known_types is None or self._is_last_item: + self._set_main_color() + assert self._main_color + assert self._known_types + return self._main_color, self._known_types + + def _determine_main_color(self, unknown_type_seen: bool) -> str: + stats = self.stats + if "failed" in stats or "error" in stats: + main_color = "red" + elif "warnings" in stats or "xpassed" in stats or unknown_type_seen: + main_color = "yellow" + elif "passed" in stats or not self._is_last_item: + main_color = "green" + else: + main_color = "yellow" + return main_color + + def _set_main_color(self) -> None: + unknown_types: list[str] = [] + for found_type in self.stats: + if found_type: # setup/teardown reports have an empty key, ignore them + if found_type not in KNOWN_TYPES and found_type not in unknown_types: + unknown_types.append(found_type) + self._known_types = list(KNOWN_TYPES) + unknown_types + self._main_color = self._determine_main_color(bool(unknown_types)) + + def build_summary_stats_line(self) -> tuple[list[tuple[str, dict[str, bool]]], str]: + """ + Build the parts used in the last summary stats line. + + The summary stats line is the line shown at the end, "=== 12 passed, 2 errors in Xs===". + + This function builds a list of the "parts" that make up for the text in that line, in + the example above it would be:: + + [ + ("12 passed", {"green": True}), + ("2 errors", {"red": True} + ] + + That last dict for each line is a "markup dictionary", used by TerminalWriter to + color output. + + The final color of the line is also determined by this function, and is the second + element of the returned tuple. + """ + if self.config.getoption("collectonly"): + return self._build_collect_only_summary_stats_line() + else: + return self._build_normal_summary_stats_line() + + def _get_reports_to_display(self, key: str) -> list[Any]: + """Get test/collection reports for the given status key, such as `passed` or `error`.""" + reports = self.stats.get(key, []) + return [x for x in reports if getattr(x, "count_towards_summary", True)] + + def _build_normal_summary_stats_line( + self, + ) -> tuple[list[tuple[str, dict[str, bool]]], str]: + main_color, known_types = self._get_main_color() + parts = [] + + for key in known_types: + reports = self._get_reports_to_display(key) + if reports: + count = len(reports) + color = _color_for_type.get(key, _color_for_type_default) + markup = {color: True, "bold": color == main_color} + parts.append(("%d %s" % pluralize(count, key), markup)) # noqa: UP031 + + if not parts: + parts = [("no tests ran", {_color_for_type_default: True})] + + return parts, main_color + + def _build_collect_only_summary_stats_line( + self, + ) -> tuple[list[tuple[str, dict[str, bool]]], str]: + deselected = len(self._get_reports_to_display("deselected")) + errors = len(self._get_reports_to_display("error")) + + if self._numcollected == 0: + parts = [("no tests collected", {"yellow": True})] + main_color = "yellow" + + elif deselected == 0: + main_color = "green" + collected_output = "%d %s collected" % pluralize(self._numcollected, "test") # noqa: UP031 + parts = [(collected_output, {main_color: True})] + else: + all_tests_were_deselected = self._numcollected == deselected + if all_tests_were_deselected: + main_color = "yellow" + collected_output = f"no tests collected ({deselected} deselected)" + else: + main_color = "green" + selected = self._numcollected - deselected + collected_output = f"{selected}/{self._numcollected} tests collected ({deselected} deselected)" + + parts = [(collected_output, {main_color: True})] + + if errors: + main_color = _color_for_type["error"] + parts += [("%d %s" % pluralize(errors, "error"), {main_color: True})] # noqa: UP031 + + return parts, main_color + + +def _get_node_id_with_markup(tw: TerminalWriter, config: Config, rep: BaseReport): + nodeid = config.cwd_relative_nodeid(rep.nodeid) + path, *parts = nodeid.split("::") + if parts: + parts_markup = tw.markup("::".join(parts), bold=True) + return path + "::" + parts_markup + else: + return path + + +def _format_trimmed(format: str, msg: str, available_width: int) -> str | None: + """Format msg into format, ellipsizing it if doesn't fit in available_width. + + Returns None if even the ellipsis can't fit. + """ + # Only use the first line. + i = msg.find("\n") + if i != -1: + msg = msg[:i] + + ellipsis = "..." + format_width = wcswidth(format.format("")) + if format_width + len(ellipsis) > available_width: + return None + + if format_width + wcswidth(msg) > available_width: + available_width -= len(ellipsis) + msg = msg[:available_width] + while format_width + wcswidth(msg) > available_width: + msg = msg[:-1] + msg += ellipsis + + return format.format(msg) + + +def _get_line_with_reprcrash_message( + config: Config, rep: BaseReport, tw: TerminalWriter, word_markup: dict[str, bool] +) -> str: + """Get summary line for a report, trying to add reprcrash message.""" + verbose_word, verbose_markup = rep._get_verbose_word_with_markup( + config, word_markup + ) + word = tw.markup(verbose_word, **verbose_markup) + node = _get_node_id_with_markup(tw, config, rep) + + line = f"{word} {node}" + line_width = wcswidth(line) + + msg: str | None + try: + if isinstance(rep.longrepr, str): + msg = rep.longrepr + else: + # Type ignored intentionally -- possible AttributeError expected. + msg = rep.longrepr.reprcrash.message # type: ignore[union-attr] + except AttributeError: + pass + else: + if ( + running_on_ci() or config.option.verbose >= 2 + ) and not config.option.force_short_summary: + msg = f" - {msg}" + else: + available_width = tw.fullwidth - line_width + msg = _format_trimmed(" - {}", msg, available_width) + if msg is not None: + line += msg + + return line + + +def _folded_skips( + startpath: Path, + skipped: Sequence[CollectReport], +) -> list[tuple[int, str, int | None, str]]: + d: dict[tuple[str, int | None, str], list[CollectReport]] = {} + for event in skipped: + assert event.longrepr is not None + assert isinstance(event.longrepr, tuple), (event, event.longrepr) + assert len(event.longrepr) == 3, (event, event.longrepr) + fspath, lineno, reason = event.longrepr + # For consistency, report all fspaths in relative form. + fspath = bestrelpath(startpath, Path(fspath)) + keywords = getattr(event, "keywords", {}) + # Folding reports with global pytestmark variable. + # This is a workaround, because for now we cannot identify the scope of a skip marker + # TODO: Revisit after marks scope would be fixed. + if ( + event.when == "setup" + and "skip" in keywords + and "pytestmark" not in keywords + ): + key: tuple[str, int | None, str] = (fspath, None, reason) + else: + key = (fspath, lineno, reason) + d.setdefault(key, []).append(event) + values: list[tuple[int, str, int | None, str]] = [] + for key, events in d.items(): + values.append((len(events), *key)) + return values + + +_color_for_type = { + "failed": "red", + "error": "red", + "warnings": "yellow", + "passed": "green", + "subtests passed": "green", + "subtests failed": "red", +} +_color_for_type_default = "yellow" + + +def pluralize(count: int, noun: str) -> tuple[int, str]: + # No need to pluralize words such as `failed` or `passed`. + if noun not in ["error", "warnings", "test"]: + return count, noun + + # The `warnings` key is plural. To avoid API breakage, we keep it that way but + # set it to singular here so we can determine plurality in the same way as we do + # for `error`. + noun = noun.replace("warnings", "warning") + + return count, noun + "s" if count != 1 else noun + + +def _plugin_nameversions(plugininfo) -> list[str]: + values: list[str] = [] + for plugin, dist in plugininfo: + # Gets us name and version! + name = f"{dist.project_name}-{dist.version}" + # Questionable convenience, but it keeps things short. + if name.startswith("pytest-"): + name = name[7:] + # We decided to print python package names they can have more than one plugin. + if name not in values: + values.append(name) + return values + + +def format_session_duration(seconds: float) -> str: + """Format the given seconds in a human readable manner to show in the final summary.""" + if seconds < 60: + return f"{seconds:.2f}s" + else: + dt = datetime.timedelta(seconds=int(seconds)) + return f"{seconds:.2f}s ({dt})" + + +def format_node_duration(seconds: float) -> str: + """Format the given seconds in a human readable manner to show in the test progress.""" + # The formatting is designed to be compact and readable, with at most 7 characters + # for durations below 100 hours. + if seconds < 0.00001: + return f" {seconds * 1000000:.3f}us" + if seconds < 0.0001: + return f" {seconds * 1000000:.2f}us" + if seconds < 0.001: + return f" {seconds * 1000000:.1f}us" + if seconds < 0.01: + return f" {seconds * 1000:.3f}ms" + if seconds < 0.1: + return f" {seconds * 1000:.2f}ms" + if seconds < 1: + return f" {seconds * 1000:.1f}ms" + if seconds < 60: + return f" {seconds:.3f}s" + if seconds < 3600: + return f" {seconds // 60:.0f}m {seconds % 60:.0f}s" + return f" {seconds // 3600:.0f}h {(seconds % 3600) // 60:.0f}m" + + +def _get_raw_skip_reason(report: TestReport) -> str: + """Get the reason string of a skip/xfail/xpass test report. + + The string is just the part given by the user. + """ + if hasattr(report, "wasxfail"): + reason = report.wasxfail + if reason.startswith("reason: "): + reason = reason[len("reason: ") :] + return reason + else: + assert report.skipped + assert isinstance(report.longrepr, tuple) + _, _, reason = report.longrepr + if reason.startswith("Skipped: "): + reason = reason[len("Skipped: ") :] + elif reason == "Skipped": + reason = "" + return reason + + +class TerminalProgressPlugin: + """Terminal progress reporting plugin using OSC 9;4 ANSI sequences. + + Emits OSC 9;4 sequences to indicate test progress to terminal + tabs/windows/etc. + + Not all terminal emulators support this feature. + + Ref: https://conemu.github.io/en/AnsiEscapeCodes.html#ConEmu_specific_OSC + """ + + def __init__(self, tr: TerminalReporter) -> None: + self._tr = tr + self._session: Session | None = None + self._has_failures = False + + def _emit_progress( + self, + state: Literal["remove", "normal", "error", "indeterminate", "paused"], + progress: int | None = None, + ) -> None: + """Emit OSC 9;4 sequence for indicating progress to the terminal. + + :param state: + Progress state to set. + :param progress: + Progress value 0-100. Required for "normal", optional for "error" + and "paused", otherwise ignored. + """ + assert progress is None or 0 <= progress <= 100 + + # OSC 9;4 sequence: ESC ] 9 ; 4 ; state ; progress ST + # ST can be ESC \ or BEL. ESC \ seems better supported. + match state: + case "remove": + sequence = "\x1b]9;4;0;\x1b\\" + case "normal": + assert progress is not None + sequence = f"\x1b]9;4;1;{progress}\x1b\\" + case "error": + if progress is not None: + sequence = f"\x1b]9;4;2;{progress}\x1b\\" + else: + sequence = "\x1b]9;4;2;\x1b\\" + case "indeterminate": + sequence = "\x1b]9;4;3;\x1b\\" + case "paused": + if progress is not None: + sequence = f"\x1b]9;4;4;{progress}\x1b\\" + else: + sequence = "\x1b]9;4;4;\x1b\\" + + self._tr.write_raw(sequence, flush=True) + + @hookimpl + def pytest_sessionstart(self, session: Session) -> None: + self._session = session + # Show indeterminate progress during collection. + self._emit_progress("indeterminate") + + @hookimpl + def pytest_collection_finish(self) -> None: + assert self._session is not None + if self._session.testscollected > 0: + # Switch from indeterminate to 0% progress. + self._emit_progress("normal", 0) + + @hookimpl + def pytest_runtest_logreport(self, report: TestReport) -> None: + if report.failed: + self._has_failures = True + + # Let's consider the "call" phase for progress. + if report.when != "call": + return + + # Calculate and emit progress. + assert self._session is not None + collected = self._session.testscollected + if collected > 0: + reported = self._tr.reported_progress + progress = min(reported * 100 // collected, 100) + self._emit_progress("error" if self._has_failures else "normal", progress) + + @hookimpl + def pytest_sessionfinish(self) -> None: + self._emit_progress("remove") diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/terminalprogress.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/terminalprogress.py new file mode 100644 index 0000000000000000000000000000000000000000..287f0d569ffdd0714b2e3997c52ef101d34a8066 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/terminalprogress.py @@ -0,0 +1,30 @@ +# A plugin to register the TerminalProgressPlugin plugin. +# +# This plugin is not loaded by default due to compatibility issues (#13896), +# but can be enabled in one of these ways: +# - The terminal plugin enables it in a few cases where it's safe, and not +# blocked by the user (using e.g. `-p no:terminalprogress`). +# - The user explicitly requests it, e.g. using `-p terminalprogress`. +# +# In a few years, if it's safe, we can consider enabling it by default. Then, +# this file will become unnecessary and can be inlined into terminal.py. + +from __future__ import annotations + +import os + +from _pytest.config import Config +from _pytest.config import hookimpl +from _pytest.terminal import TerminalProgressPlugin +from _pytest.terminal import TerminalReporter + + +@hookimpl(trylast=True) +def pytest_configure(config: Config) -> None: + reporter: TerminalReporter | None = config.pluginmanager.get_plugin( + "terminalreporter" + ) + + if reporter is not None and reporter.isatty() and os.environ.get("TERM") != "dumb": + plugin = TerminalProgressPlugin(reporter) + config.pluginmanager.register(plugin, name="terminalprogress-plugin") diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/threadexception.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/threadexception.py new file mode 100644 index 0000000000000000000000000000000000000000..eb57783be261ebf30f1c03a04cab471f5ec6f063 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/threadexception.py @@ -0,0 +1,152 @@ +from __future__ import annotations + +import collections +from collections.abc import Callable +import functools +import sys +import threading +import traceback +from typing import NamedTuple +from typing import TYPE_CHECKING +import warnings + +from _pytest.config import Config +from _pytest.nodes import Item +from _pytest.stash import StashKey +from _pytest.tracemalloc import tracemalloc_message +import pytest + + +if TYPE_CHECKING: + pass + +if sys.version_info < (3, 11): + from exceptiongroup import ExceptionGroup + + +class ThreadExceptionMeta(NamedTuple): + msg: str + cause_msg: str + exc_value: BaseException | None + + +thread_exceptions: StashKey[collections.deque[ThreadExceptionMeta | BaseException]] = ( + StashKey() +) + + +def collect_thread_exception(config: Config) -> None: + pop_thread_exception = config.stash[thread_exceptions].pop + errors: list[pytest.PytestUnhandledThreadExceptionWarning | RuntimeError] = [] + meta = None + hook_error = None + try: + while True: + try: + meta = pop_thread_exception() + except IndexError: + break + + if isinstance(meta, BaseException): + hook_error = RuntimeError("Failed to process thread exception") + hook_error.__cause__ = meta + errors.append(hook_error) + continue + + msg = meta.msg + try: + warnings.warn(pytest.PytestUnhandledThreadExceptionWarning(msg)) + except pytest.PytestUnhandledThreadExceptionWarning as e: + # This except happens when the warning is treated as an error (e.g. `-Werror`). + if meta.exc_value is not None: + # Exceptions have a better way to show the traceback, but + # warnings do not, so hide the traceback from the msg and + # set the cause so the traceback shows up in the right place. + e.args = (meta.cause_msg,) + e.__cause__ = meta.exc_value + errors.append(e) + + if len(errors) == 1: + raise errors[0] + if errors: + raise ExceptionGroup("multiple thread exception warnings", errors) + finally: + del errors, meta, hook_error + + +def cleanup( + *, config: Config, prev_hook: Callable[[threading.ExceptHookArgs], object] +) -> None: + try: + try: + # We don't join threads here, so exceptions raised from any + # threads still running by the time _threading_atexits joins them + # do not get captured (see #13027). + collect_thread_exception(config) + finally: + threading.excepthook = prev_hook + finally: + del config.stash[thread_exceptions] + + +def thread_exception_hook( + args: threading.ExceptHookArgs, + /, + *, + append: Callable[[ThreadExceptionMeta | BaseException], object], +) -> None: + try: + # we need to compute these strings here as they might change after + # the excepthook finishes and before the metadata object is + # collected by a pytest hook + thread_name = "<unknown>" if args.thread is None else args.thread.name + summary = f"Exception in thread {thread_name}" + traceback_message = "\n\n" + "".join( + traceback.format_exception( + args.exc_type, + args.exc_value, + args.exc_traceback, + ) + ) + tracemalloc_tb = "\n" + tracemalloc_message(args.thread) + msg = summary + traceback_message + tracemalloc_tb + cause_msg = summary + tracemalloc_tb + + append( + ThreadExceptionMeta( + # Compute these strings here as they might change later + msg=msg, + cause_msg=cause_msg, + exc_value=args.exc_value, + ) + ) + except BaseException as e: + append(e) + # Raising this will cause the exception to be logged twice, once in our + # collect_thread_exception and once by sys.excepthook + # which is fine - this should never happen anyway and if it does + # it should probably be reported as a pytest bug. + raise + + +def pytest_configure(config: Config) -> None: + prev_hook = threading.excepthook + deque: collections.deque[ThreadExceptionMeta | BaseException] = collections.deque() + config.stash[thread_exceptions] = deque + config.add_cleanup(functools.partial(cleanup, config=config, prev_hook=prev_hook)) + threading.excepthook = functools.partial(thread_exception_hook, append=deque.append) + + +@pytest.hookimpl(trylast=True) +def pytest_runtest_setup(item: Item) -> None: + collect_thread_exception(item.config) + + +@pytest.hookimpl(trylast=True) +def pytest_runtest_call(item: Item) -> None: + collect_thread_exception(item.config) + + +@pytest.hookimpl(trylast=True) +def pytest_runtest_teardown(item: Item) -> None: + collect_thread_exception(item.config) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/timing.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/timing.py new file mode 100644 index 0000000000000000000000000000000000000000..51c3db23f6fa51a33a00567f0f0e9af99cad949b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/timing.py @@ -0,0 +1,95 @@ +"""Indirection for time functions. + +We intentionally grab some "time" functions internally to avoid tests mocking "time" to affect +pytest runtime information (issue #185). + +Fixture "mock_timing" also interacts with this module for pytest's own tests. +""" + +from __future__ import annotations + +import dataclasses +from datetime import datetime +from datetime import timezone +from time import perf_counter +from time import sleep +from time import time +from typing import TYPE_CHECKING + + +if TYPE_CHECKING: + from pytest import MonkeyPatch + + +@dataclasses.dataclass(frozen=True) +class Instant: + """ + Represents an instant in time, used to both get the timestamp value and to measure + the duration of a time span. + + Inspired by Rust's `std::time::Instant`. + """ + + # Creation time of this instant, using time.time(), to measure actual time. + # Note: using a `lambda` to correctly get the mocked time via `MockTiming`. + time: float = dataclasses.field(default_factory=lambda: time(), init=False) + + # Performance counter tick of the instant, used to measure precise elapsed time. + # Note: using a `lambda` to correctly get the mocked time via `MockTiming`. + perf_count: float = dataclasses.field( + default_factory=lambda: perf_counter(), init=False + ) + + def elapsed(self) -> Duration: + """Measure the duration since `Instant` was created.""" + return Duration(start=self, stop=Instant()) + + def as_utc(self) -> datetime: + """Instant as UTC datetime.""" + return datetime.fromtimestamp(self.time, timezone.utc) + + +@dataclasses.dataclass(frozen=True) +class Duration: + """A span of time as measured by `Instant.elapsed()`.""" + + start: Instant + stop: Instant + + @property + def seconds(self) -> float: + """Elapsed time of the duration in seconds, measured using a performance counter for precise timing.""" + return self.stop.perf_count - self.start.perf_count + + +@dataclasses.dataclass +class MockTiming: + """Mocks _pytest.timing with a known object that can be used to control timing in tests + deterministically. + + pytest itself should always use functions from `_pytest.timing` instead of `time` directly. + + This then allows us more control over time during testing, if testing code also + uses `_pytest.timing` functions. + + Time is static, and only advances through `sleep` calls, thus tests might sleep over large + numbers and obtain accurate time() calls at the end, making tests reliable and instant.""" + + _current_time: float = datetime(2020, 5, 22, 14, 20, 50).timestamp() + + def sleep(self, seconds: float) -> None: + self._current_time += seconds + + def time(self) -> float: + return self._current_time + + def patch(self, monkeypatch: MonkeyPatch) -> None: + # pylint: disable-next=import-self + from _pytest import timing # noqa: PLW0406 + + monkeypatch.setattr(timing, "sleep", self.sleep) + monkeypatch.setattr(timing, "time", self.time) + monkeypatch.setattr(timing, "perf_counter", self.time) + + +__all__ = ["perf_counter", "sleep", "time"] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/tmpdir.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/tmpdir.py new file mode 100644 index 0000000000000000000000000000000000000000..66ca9f190e38ed95995f0ded13d9d401a0517c93 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/tmpdir.py @@ -0,0 +1,337 @@ +# mypy: allow-untyped-defs +"""Support for providing temporary directories to test functions.""" + +from __future__ import annotations + +from collections.abc import Generator +import dataclasses +import os +from pathlib import Path +import re +from shutil import rmtree +import stat +import tempfile +from typing import Any +from typing import final +from typing import Literal + +from .pathlib import cleanup_dead_symlinks +from .pathlib import LOCK_TIMEOUT +from .pathlib import make_numbered_dir +from .pathlib import make_numbered_dir_with_cleanup +from .pathlib import rm_rf +from _pytest.compat import get_user_id +from _pytest.config import Config +from _pytest.config import ExitCode +from _pytest.config import hookimpl +from _pytest.config.argparsing import Parser +from _pytest.deprecated import check_ispytest +from _pytest.fixtures import fixture +from _pytest.fixtures import FixtureRequest +from _pytest.monkeypatch import MonkeyPatch +from _pytest.nodes import Item +from _pytest.reports import TestReport +from _pytest.stash import StashKey + + +tmppath_result_key = StashKey[dict[str, bool]]() +RetentionType = Literal["all", "failed", "none"] + + +@final +@dataclasses.dataclass +class TempPathFactory: + """Factory for temporary directories under the common base temp directory, + as discussed at :ref:`temporary directory location and retention`. + """ + + _given_basetemp: Path | None + # pluggy TagTracerSub, not currently exposed, so Any. + _trace: Any + _basetemp: Path | None + _retention_count: int + _retention_policy: RetentionType + + def __init__( + self, + given_basetemp: Path | None, + retention_count: int, + retention_policy: RetentionType, + trace, + basetemp: Path | None = None, + *, + _ispytest: bool = False, + ) -> None: + check_ispytest(_ispytest) + if given_basetemp is None: + self._given_basetemp = None + else: + # Use os.path.abspath() to get absolute path instead of resolve() as it + # does not work the same in all platforms (see #4427). + # Path.absolute() exists, but it is not public (see https://bugs.python.org/issue25012). + self._given_basetemp = Path(os.path.abspath(str(given_basetemp))) + self._trace = trace + self._retention_count = retention_count + self._retention_policy = retention_policy + self._basetemp = basetemp + + @classmethod + def from_config( + cls, + config: Config, + *, + _ispytest: bool = False, + ) -> TempPathFactory: + """Create a factory according to pytest configuration. + + :meta private: + """ + check_ispytest(_ispytest) + count = int(config.getini("tmp_path_retention_count")) + if count < 0: + raise ValueError( + f"tmp_path_retention_count must be >= 0. Current input: {count}." + ) + + policy = config.getini("tmp_path_retention_policy") + if policy not in ("all", "failed", "none"): + raise ValueError( + f"tmp_path_retention_policy must be either all, failed, none. Current input: {policy}." + ) + + return cls( + given_basetemp=config.option.basetemp, + trace=config.trace.get("tmpdir"), + retention_count=count, + retention_policy=policy, + _ispytest=True, + ) + + def _ensure_relative_to_basetemp(self, basename: str) -> str: + basename = os.path.normpath(basename) + if (self.getbasetemp() / basename).resolve().parent != self.getbasetemp(): + raise ValueError(f"{basename} is not a normalized and relative path") + return basename + + def mktemp(self, basename: str, numbered: bool = True) -> Path: + """Create a new temporary directory managed by the factory. + + :param basename: + Directory base name, must be a relative path. + + :param numbered: + If ``True``, ensure the directory is unique by adding a numbered + suffix greater than any existing one: ``basename="foo-"`` and ``numbered=True`` + means that this function will create directories named ``"foo-0"``, + ``"foo-1"``, ``"foo-2"`` and so on. + + :returns: + The path to the new directory. + """ + basename = self._ensure_relative_to_basetemp(basename) + if not numbered: + p = self.getbasetemp().joinpath(basename) + p.mkdir(mode=0o700) + else: + p = make_numbered_dir(root=self.getbasetemp(), prefix=basename, mode=0o700) + self._trace("mktemp", p) + return p + + def getbasetemp(self) -> Path: + """Return the base temporary directory, creating it if needed. + + :returns: + The base temporary directory. + """ + if self._basetemp is not None: + return self._basetemp + + if self._given_basetemp is not None: + basetemp = self._given_basetemp + if basetemp.exists(): + rm_rf(basetemp) + basetemp.mkdir(mode=0o700) + basetemp = basetemp.resolve() + else: + from_env = os.environ.get("PYTEST_DEBUG_TEMPROOT") + temproot = Path(from_env or tempfile.gettempdir()).resolve() + user = get_user() or "unknown" + # use a sub-directory in the temproot to speed-up + # make_numbered_dir() call + rootdir = temproot.joinpath(f"pytest-of-{user}") + try: + rootdir.mkdir(mode=0o700, exist_ok=True) + except OSError: + # getuser() likely returned illegal characters for the platform, use unknown back off mechanism + rootdir = temproot.joinpath("pytest-of-unknown") + rootdir.mkdir(mode=0o700, exist_ok=True) + # Because we use exist_ok=True with a predictable name, make sure + # we are the owners, to prevent any funny business (on unix, where + # temproot is usually shared). + # Also, to keep things private, fixup any world-readable temp + # rootdir's permissions. Historically 0o755 was used, so we can't + # just error out on this, at least for a while. + # Don't follow symlinks, otherwise we're open to symlink-swapping + # TOCTOU vulnerability. + # This check makes us vulnerable to a DoS - a user can `mkdir + # /tmp/pytest-of-otheruser` and then `otheruser` will fail this + # check. For now we don't consider it a real problem. otheruser can + # change their TMPDIR or --basetemp, and maybe give the prankster a + # good scolding. + uid = get_user_id() + if uid is not None: + stat_follow_symlinks = ( + False if os.stat in os.supports_follow_symlinks else True + ) + rootdir_stat = rootdir.stat(follow_symlinks=stat_follow_symlinks) + if stat.S_ISLNK(rootdir_stat.st_mode): + raise OSError( + f"The temporary directory {rootdir} is a symbolic link. " + "Fix this and try again." + ) + if rootdir_stat.st_uid != uid: + raise OSError( + f"The temporary directory {rootdir} is not owned by the current user. " + "Fix this and try again." + ) + if (rootdir_stat.st_mode & 0o077) != 0: + chmod_follow_symlinks = ( + False if os.chmod in os.supports_follow_symlinks else True + ) + rootdir.chmod( + rootdir_stat.st_mode & ~0o077, + follow_symlinks=chmod_follow_symlinks, + ) + keep = self._retention_count + if self._retention_policy == "none": + keep = 0 + basetemp = make_numbered_dir_with_cleanup( + prefix="pytest-", + root=rootdir, + keep=keep, + lock_timeout=LOCK_TIMEOUT, + mode=0o700, + ) + assert basetemp is not None, basetemp + self._basetemp = basetemp + self._trace("new basetemp", basetemp) + return basetemp + + +def get_user() -> str | None: + """Return the current user name, or None if getuser() does not work + in the current environment (see #1010).""" + try: + # In some exotic environments, getpass may not be importable. + import getpass + + return getpass.getuser() + except (ImportError, OSError, KeyError): + return None + + +def pytest_configure(config: Config) -> None: + """Create a TempPathFactory and attach it to the config object. + + This is to comply with existing plugins which expect the handler to be + available at pytest_configure time, but ideally should be moved entirely + to the tmp_path_factory session fixture. + """ + mp = MonkeyPatch() + config.add_cleanup(mp.undo) + _tmp_path_factory = TempPathFactory.from_config(config, _ispytest=True) + mp.setattr(config, "_tmp_path_factory", _tmp_path_factory, raising=False) + + +def pytest_addoption(parser: Parser) -> None: + parser.addini( + "tmp_path_retention_count", + help="How many sessions should we keep the `tmp_path` directories, according to `tmp_path_retention_policy`.", + default="3", + # NOTE: Would have been better as an `int` but can't change it now. + type="string", + ) + + parser.addini( + "tmp_path_retention_policy", + help="Controls which directories created by the `tmp_path` fixture are kept around, based on test outcome. " + "(all/failed/none)", + type="string", + default="all", + ) + + +@fixture(scope="session") +def tmp_path_factory(request: FixtureRequest) -> TempPathFactory: + """Return a :class:`pytest.TempPathFactory` instance for the test session.""" + # Set dynamically by pytest_configure() above. + return request.config._tmp_path_factory # type: ignore + + +def _mk_tmp(request: FixtureRequest, factory: TempPathFactory) -> Path: + name = request.node.name + name = re.sub(r"[\W]", "_", name) + MAXVAL = 30 + name = name[:MAXVAL] + return factory.mktemp(name, numbered=True) + + +@fixture +def tmp_path( + request: FixtureRequest, tmp_path_factory: TempPathFactory +) -> Generator[Path]: + """Return a temporary directory (as :class:`pathlib.Path` object) + which is unique to each test function invocation. + The temporary directory is created as a subdirectory + of the base temporary directory, with configurable retention, + as discussed in :ref:`temporary directory location and retention`. + """ + path = _mk_tmp(request, tmp_path_factory) + yield path + + # Remove the tmpdir if the policy is "failed" and the test passed. + policy = tmp_path_factory._retention_policy + result_dict = request.node.stash[tmppath_result_key] + + if policy == "failed" and result_dict.get("call", True): + # We do a "best effort" to remove files, but it might not be possible due to some leaked resource, + # permissions, etc, in which case we ignore it. + rmtree(path, ignore_errors=True) + + del request.node.stash[tmppath_result_key] + + +def pytest_sessionfinish(session, exitstatus: int | ExitCode): + """After each session, remove base directory if all the tests passed, + the policy is "failed", and the basetemp is not specified by a user. + """ + tmp_path_factory: TempPathFactory = session.config._tmp_path_factory + basetemp = tmp_path_factory._basetemp + if basetemp is None: + return + + policy = tmp_path_factory._retention_policy + if ( + exitstatus == 0 + and policy == "failed" + and tmp_path_factory._given_basetemp is None + ): + if basetemp.is_dir(): + # We do a "best effort" to remove files, but it might not be possible due to some leaked resource, + # permissions, etc, in which case we ignore it. + rmtree(basetemp, ignore_errors=True) + + # Remove dead symlinks. + if basetemp.is_dir(): + cleanup_dead_symlinks(basetemp) + + +@hookimpl(wrapper=True, tryfirst=True) +def pytest_runtest_makereport( + item: Item, call +) -> Generator[None, TestReport, TestReport]: + rep = yield + assert rep.when is not None + empty: dict[str, bool] = {} + item.stash.setdefault(tmppath_result_key, empty)[rep.when] = rep.passed + return rep diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/tracemalloc.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/tracemalloc.py new file mode 100644 index 0000000000000000000000000000000000000000..5d0b19855c734ed8885c1ceb7bec20b34ac66b52 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/tracemalloc.py @@ -0,0 +1,24 @@ +from __future__ import annotations + + +def tracemalloc_message(source: object) -> str: + if source is None: + return "" + + try: + import tracemalloc + except ImportError: + return "" + + tb = tracemalloc.get_object_traceback(source) + if tb is not None: + formatted_tb = "\n".join(tb.format()) + # Use a leading new line to better separate the (large) output + # from the traceback to the previous warning text. + return f"\nObject allocated at:\n{formatted_tb}" + # No need for a leading new line. + url = "https://docs.pytest.org/en/stable/how-to/capture-warnings.html#resource-warnings" + return ( + "Enable tracemalloc to get traceback where the object was allocated.\n" + f"See {url} for more info." + ) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/unittest.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/unittest.py new file mode 100644 index 0000000000000000000000000000000000000000..31be8847821c9f8547b9e7d2fb3ce55406e87ab4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/unittest.py @@ -0,0 +1,632 @@ +# mypy: allow-untyped-defs +"""Discover and run std-library "unittest" style tests.""" + +from __future__ import annotations + +from collections.abc import Callable +from collections.abc import Generator +from collections.abc import Iterable +from collections.abc import Iterator +from enum import auto +from enum import Enum +import inspect +import sys +import traceback +import types +from typing import Any +from typing import TYPE_CHECKING +from unittest import TestCase + +import _pytest._code +from _pytest._code import ExceptionInfo +from _pytest.compat import assert_never +from _pytest.compat import is_async_function +from _pytest.config import hookimpl +from _pytest.fixtures import FixtureRequest +from _pytest.monkeypatch import MonkeyPatch +from _pytest.nodes import Collector +from _pytest.nodes import Item +from _pytest.outcomes import exit +from _pytest.outcomes import fail +from _pytest.outcomes import skip +from _pytest.outcomes import xfail +from _pytest.python import Class +from _pytest.python import Function +from _pytest.python import Module +from _pytest.runner import CallInfo +from _pytest.runner import check_interactive_exception +from _pytest.subtests import SubtestContext +from _pytest.subtests import SubtestReport + + +if sys.version_info[:2] < (3, 11): + from exceptiongroup import ExceptionGroup + +if TYPE_CHECKING: + from types import TracebackType + import unittest + + import twisted.trial.unittest + + +_SysExcInfoType = ( + tuple[type[BaseException], BaseException, types.TracebackType] + | tuple[None, None, None] +) + + +def pytest_pycollect_makeitem( + collector: Module | Class, name: str, obj: object +) -> UnitTestCase | None: + try: + # Has unittest been imported? + ut = sys.modules["unittest"] + # Is obj a subclass of unittest.TestCase? + # Type ignored because `ut` is an opaque module. + if not issubclass(obj, ut.TestCase): # type: ignore + return None + except Exception: + return None + # Is obj a concrete class? + # Abstract classes can't be instantiated so no point collecting them. + if inspect.isabstract(obj): + return None + # Yes, so let's collect it. + return UnitTestCase.from_parent(collector, name=name, obj=obj) + + +class UnitTestCase(Class): + # Marker for fixturemanger.getfixtureinfo() + # to declare that our children do not support funcargs. + nofuncargs = True + + def newinstance(self): + # TestCase __init__ takes the method (test) name. The TestCase + # constructor treats the name "runTest" as a special no-op, so it can be + # used when a dummy instance is needed. While unittest.TestCase has a + # default, some subclasses omit the default (#9610), so always supply + # it. + return self.obj("runTest") + + def collect(self) -> Iterable[Item | Collector]: + from unittest import TestLoader + + cls = self.obj + if not getattr(cls, "__test__", True): + return + + skipped = _is_skipped(cls) + if not skipped: + self._register_unittest_setup_method_fixture(cls) + self._register_unittest_setup_class_fixture(cls) + self._register_setup_class_fixture() + + self.session._fixturemanager.parsefactories(self.newinstance(), self.nodeid) + + loader = TestLoader() + foundsomething = False + for name in loader.getTestCaseNames(self.obj): + x = getattr(self.obj, name) + if not getattr(x, "__test__", True): + continue + yield TestCaseFunction.from_parent(self, name=name) + foundsomething = True + + if not foundsomething: + runtest = getattr(self.obj, "runTest", None) + if runtest is not None: + ut = sys.modules.get("twisted.trial.unittest", None) + if ut is None or runtest != ut.TestCase.runTest: + yield TestCaseFunction.from_parent(self, name="runTest") + + def _register_unittest_setup_class_fixture(self, cls: type) -> None: + """Register an auto-use fixture to invoke setUpClass and + tearDownClass (#517).""" + setup = getattr(cls, "setUpClass", None) + teardown = getattr(cls, "tearDownClass", None) + if setup is None and teardown is None: + return None + cleanup = getattr(cls, "doClassCleanups", lambda: None) + + def process_teardown_exceptions() -> None: + # tearDown_exceptions is a list set in the class containing exc_infos for errors during + # teardown for the class. + exc_infos = getattr(cls, "tearDown_exceptions", None) + if not exc_infos: + return + exceptions = [exc for (_, exc, _) in exc_infos] + # If a single exception, raise it directly as this provides a more readable + # error (hopefully this will improve in #12255). + if len(exceptions) == 1: + raise exceptions[0] + else: + raise ExceptionGroup("Unittest class cleanup errors", exceptions) + + def unittest_setup_class_fixture( + request: FixtureRequest, + ) -> Generator[None]: + cls = request.cls + if _is_skipped(cls): + reason = cls.__unittest_skip_why__ + raise skip.Exception(reason, _use_item_location=True) + if setup is not None: + try: + setup() + # unittest does not call the cleanup function for every BaseException, so we + # follow this here. + except Exception: + cleanup() + process_teardown_exceptions() + raise + yield + try: + if teardown is not None: + teardown() + finally: + cleanup() + process_teardown_exceptions() + + self.session._fixturemanager._register_fixture( + # Use a unique name to speed up lookup. + name=f"_unittest_setUpClass_fixture_{cls.__qualname__}", + func=unittest_setup_class_fixture, + nodeid=self.nodeid, + scope="class", + autouse=True, + ) + + def _register_unittest_setup_method_fixture(self, cls: type) -> None: + """Register an auto-use fixture to invoke setup_method and + teardown_method (#517).""" + setup = getattr(cls, "setup_method", None) + teardown = getattr(cls, "teardown_method", None) + if setup is None and teardown is None: + return None + + def unittest_setup_method_fixture( + request: FixtureRequest, + ) -> Generator[None]: + self = request.instance + if _is_skipped(self): + reason = self.__unittest_skip_why__ + raise skip.Exception(reason, _use_item_location=True) + if setup is not None: + setup(self, request.function) + yield + if teardown is not None: + teardown(self, request.function) + + self.session._fixturemanager._register_fixture( + # Use a unique name to speed up lookup. + name=f"_unittest_setup_method_fixture_{cls.__qualname__}", + func=unittest_setup_method_fixture, + nodeid=self.nodeid, + scope="function", + autouse=True, + ) + + +class TestCaseFunction(Function): + nofuncargs = True + failfast = False + _excinfo: list[_pytest._code.ExceptionInfo[BaseException]] | None = None + + def _getinstance(self): + assert isinstance(self.parent, UnitTestCase) + return self.parent.obj(self.name) + + # Backward compat for pytest-django; can be removed after pytest-django + # updates + some slack. + @property + def _testcase(self): + return self.instance + + def setup(self) -> None: + # A bound method to be called during teardown() if set (see 'runtest()'). + self._explicit_tearDown: Callable[[], None] | None = None + super().setup() + if sys.version_info < (3, 11): + # A cache of the subTest errors and non-subtest skips in self._outcome. + # Compute and cache these lists once, instead of computing them again and again for each subtest (#13965). + self._cached_errors_and_skips: tuple[list[Any], list[Any]] | None = None + + def teardown(self) -> None: + if self._explicit_tearDown is not None: + self._explicit_tearDown() + self._explicit_tearDown = None + self._obj = None + del self._instance + super().teardown() + + def startTest(self, testcase: unittest.TestCase) -> None: + pass + + def _addexcinfo(self, rawexcinfo: _SysExcInfoType) -> None: + rawexcinfo = _handle_twisted_exc_info(rawexcinfo) + try: + excinfo = _pytest._code.ExceptionInfo[BaseException].from_exc_info( + rawexcinfo # type: ignore[arg-type] + ) + # Invoke the attributes to trigger storing the traceback + # trial causes some issue there. + _ = excinfo.value + _ = excinfo.traceback + except TypeError: + try: + try: + values = traceback.format_exception(*rawexcinfo) + values.insert( + 0, + "NOTE: Incompatible Exception Representation, " + "displaying natively:\n\n", + ) + fail("".join(values), pytrace=False) + except (fail.Exception, KeyboardInterrupt): + raise + except BaseException: + fail( + "ERROR: Unknown Incompatible Exception " + f"representation:\n{rawexcinfo!r}", + pytrace=False, + ) + except KeyboardInterrupt: + raise + except fail.Exception: + excinfo = _pytest._code.ExceptionInfo.from_current() + self.__dict__.setdefault("_excinfo", []).append(excinfo) + + def addError( + self, testcase: unittest.TestCase, rawexcinfo: _SysExcInfoType + ) -> None: + try: + if isinstance(rawexcinfo[1], exit.Exception): + exit(rawexcinfo[1].msg) + except TypeError: + pass + self._addexcinfo(rawexcinfo) + + def addFailure( + self, testcase: unittest.TestCase, rawexcinfo: _SysExcInfoType + ) -> None: + self._addexcinfo(rawexcinfo) + + def addSkip( + self, testcase: unittest.TestCase, reason: str, *, handle_subtests: bool = True + ) -> None: + from unittest.case import _SubTest # type: ignore[attr-defined] + + def add_skip() -> None: + try: + raise skip.Exception(reason, _use_item_location=True) + except skip.Exception: + self._addexcinfo(sys.exc_info()) + + if not handle_subtests: + add_skip() + return + + if isinstance(testcase, _SubTest): + add_skip() + if self._excinfo is not None: + exc_info = self._excinfo[-1] + self.addSubTest(testcase.test_case, testcase, exc_info) + else: + # For python < 3.11: the non-subtest skips have to be added by `add_skip` only after all subtest + # failures are processed by `_addSubTest`: `self.instance._outcome` has no attribute + # `skipped/errors` anymore. + # We also need to check if `self.instance._outcome` is `None` (this happens if the test + # class/method is decorated with `unittest.skip`, see pytest-dev/pytest-subtests#173). + if sys.version_info < (3, 11) and self.instance._outcome is not None: + subtest_errors, _ = self._obtain_errors_and_skips() + if len(subtest_errors) == 0: + add_skip() + else: + add_skip() + + def addExpectedFailure( + self, + testcase: unittest.TestCase, + rawexcinfo: _SysExcInfoType, + reason: str = "", + ) -> None: + try: + xfail(str(reason)) + except xfail.Exception: + self._addexcinfo(sys.exc_info()) + + def addUnexpectedSuccess( + self, + testcase: unittest.TestCase, + reason: twisted.trial.unittest.Todo | None = None, + ) -> None: + msg = "Unexpected success" + if reason: + msg += f": {reason.reason}" + # Preserve unittest behaviour - fail the test. Explicitly not an XPASS. + try: + fail(msg, pytrace=False) + except fail.Exception: + self._addexcinfo(sys.exc_info()) + + def addSuccess(self, testcase: unittest.TestCase) -> None: + pass + + def stopTest(self, testcase: unittest.TestCase) -> None: + pass + + def addDuration(self, testcase: unittest.TestCase, elapsed: float) -> None: + pass + + def runtest(self) -> None: + from _pytest.debugging import maybe_wrap_pytest_function_for_tracing + + testcase = self.instance + assert testcase is not None + + maybe_wrap_pytest_function_for_tracing(self) + + # Let the unittest framework handle async functions. + if is_async_function(self.obj): + testcase(result=self) + else: + # When --pdb is given, we want to postpone calling tearDown() otherwise + # when entering the pdb prompt, tearDown() would have probably cleaned up + # instance variables, which makes it difficult to debug. + # Arguably we could always postpone tearDown(), but this changes the moment where the + # TestCase instance interacts with the results object, so better to only do it + # when absolutely needed. + # We need to consider if the test itself is skipped, or the whole class. + assert isinstance(self.parent, UnitTestCase) + skipped = _is_skipped(self.obj) or _is_skipped(self.parent.obj) + if self.config.getoption("usepdb") and not skipped: + self._explicit_tearDown = testcase.tearDown + setattr(testcase, "tearDown", lambda *args: None) + + # We need to update the actual bound method with self.obj, because + # wrap_pytest_function_for_tracing replaces self.obj by a wrapper. + setattr(testcase, self.name, self.obj) + try: + testcase(result=self) + finally: + delattr(testcase, self.name) + + def _traceback_filter( + self, excinfo: _pytest._code.ExceptionInfo[BaseException] + ) -> _pytest._code.Traceback: + traceback = super()._traceback_filter(excinfo) + ntraceback = traceback.filter( + lambda x: not x.frame.f_globals.get("__unittest"), + ) + if not ntraceback: + ntraceback = traceback + return ntraceback + + def addSubTest( + self, + test_case: Any, + test: TestCase, + exc_info: ExceptionInfo[BaseException] + | tuple[type[BaseException], BaseException, TracebackType] + | None, + ) -> None: + # Importing this private symbol locally in case this symbol is renamed/removed in the future; importing + # it globally would break pytest entirely, importing it locally only will break unittests using `addSubTest`. + from unittest.case import _subtest_msg_sentinel # type: ignore[attr-defined] + + exception_info: ExceptionInfo[BaseException] | None + match exc_info: + case tuple(): + exception_info = ExceptionInfo(exc_info, _ispytest=True) + case ExceptionInfo() | None: + exception_info = exc_info + case unreachable: + assert_never(unreachable) + + call_info = CallInfo[None]( + None, + exception_info, + start=0, + stop=0, + duration=0, + when="call", + _ispytest=True, + ) + msg = None if test._message is _subtest_msg_sentinel else str(test._message) # type: ignore[attr-defined] + report = self.ihook.pytest_runtest_makereport(item=self, call=call_info) + sub_report = SubtestReport._new( + report, + SubtestContext(msg=msg, kwargs=dict(test.params)), # type: ignore[attr-defined] + captured_output=None, + captured_logs=None, + ) + self.ihook.pytest_runtest_logreport(report=sub_report) + if check_interactive_exception(call_info, sub_report): + self.ihook.pytest_exception_interact( + node=self, call=call_info, report=sub_report + ) + + # For python < 3.11: add non-subtest skips once all subtest failures are processed by # `_addSubTest`. + if sys.version_info < (3, 11): + subtest_errors, non_subtest_skip = self._obtain_errors_and_skips() + + # Check if we have non-subtest skips: if there are also sub failures, non-subtest skips are not treated in + # `_addSubTest` and have to be added using `add_skip` after all subtest failures are processed. + if len(non_subtest_skip) > 0 and len(subtest_errors) > 0: + # Make sure we have processed the last subtest failure + last_subset_error = subtest_errors[-1] + if exc_info is last_subset_error[-1]: + # Add non-subtest skips (as they could not be treated in `_addSkip`) + for testcase, reason in non_subtest_skip: + self.addSkip(testcase, reason, handle_subtests=False) + + def _obtain_errors_and_skips(self) -> tuple[list[Any], list[Any]]: + """Compute or obtain the cached values for subtest errors and non-subtest skips.""" + from unittest.case import _SubTest # type: ignore[attr-defined] + + assert sys.version_info < (3, 11), ( + "This workaround only should be used in Python 3.10" + ) + if self._cached_errors_and_skips is not None: + return self._cached_errors_and_skips + + subtest_errors = [ + (x, y) + for x, y in self.instance._outcome.errors + if isinstance(x, _SubTest) and y is not None + ] + + non_subtest_skips = [ + (x, y) + for x, y in self.instance._outcome.skipped + if not isinstance(x, _SubTest) + ] + self._cached_errors_and_skips = (subtest_errors, non_subtest_skips) + return subtest_errors, non_subtest_skips + + +@hookimpl(tryfirst=True) +def pytest_runtest_makereport(item: Item, call: CallInfo[None]) -> None: + if isinstance(item, TestCaseFunction): + if item._excinfo: + call.excinfo = item._excinfo.pop(0) + try: + del call.result + except AttributeError: + pass + + # Convert unittest.SkipTest to pytest.skip. + # This covers explicit `raise unittest.SkipTest`. + unittest = sys.modules.get("unittest") + if unittest and call.excinfo and isinstance(call.excinfo.value, unittest.SkipTest): + excinfo = call.excinfo + call2 = CallInfo[None].from_call(lambda: skip(str(excinfo.value)), call.when) + call.excinfo = call2.excinfo + + +def _is_skipped(obj) -> bool: + """Return True if the given object has been marked with @unittest.skip.""" + return bool(getattr(obj, "__unittest_skip__", False)) + + +def pytest_configure() -> None: + """Register the TestCaseFunction class as an IReporter if twisted.trial is available.""" + if _get_twisted_version() is not TwistedVersion.NotInstalled: + from twisted.trial.itrial import IReporter + from zope.interface import classImplements + + classImplements(TestCaseFunction, IReporter) + + +class TwistedVersion(Enum): + """ + The Twisted version installed in the environment. + + We have different workarounds in place for different versions of Twisted. + """ + + # Twisted version 24 or prior. + Version24 = auto() + # Twisted version 25 or later. + Version25 = auto() + # Twisted version is not available. + NotInstalled = auto() + + +def _get_twisted_version() -> TwistedVersion: + # We need to check if "twisted.trial.unittest" is specifically present in sys.modules. + # This is because we intend to integrate with Trial only when it's actively running + # the test suite, but not needed when only other Twisted components are in use. + if "twisted.trial.unittest" not in sys.modules: + return TwistedVersion.NotInstalled + + import importlib.metadata + + import packaging.version + + version_str = importlib.metadata.version("twisted") + version = packaging.version.parse(version_str) + if version.major <= 24: + return TwistedVersion.Version24 + else: + return TwistedVersion.Version25 + + +# Name of the attribute in `twisted.python.Failure` instances that stores +# the `sys.exc_info()` tuple. +# See twisted.trial support in `pytest_runtest_protocol`. +TWISTED_RAW_EXCINFO_ATTR = "_twisted_raw_excinfo" + + +@hookimpl(wrapper=True) +def pytest_runtest_protocol(item: Item) -> Iterator[None]: + if _get_twisted_version() is TwistedVersion.Version24: + import twisted.python.failure as ut + + # Monkeypatch `Failure.__init__` to store the raw exception info. + original__init__ = ut.Failure.__init__ + + def store_raw_exception_info( + self, exc_value=None, exc_type=None, exc_tb=None, captureVars=None + ): # pragma: no cover + if exc_value is None: + raw_exc_info = sys.exc_info() + else: + if exc_type is None: + exc_type = type(exc_value) + if exc_tb is None: + exc_tb = sys.exc_info()[2] + raw_exc_info = (exc_type, exc_value, exc_tb) + setattr(self, TWISTED_RAW_EXCINFO_ATTR, tuple(raw_exc_info)) + try: + original__init__( + self, exc_value, exc_type, exc_tb, captureVars=captureVars + ) + except TypeError: # pragma: no cover + original__init__(self, exc_value, exc_type, exc_tb) + + with MonkeyPatch.context() as patcher: + patcher.setattr(ut.Failure, "__init__", store_raw_exception_info) + return (yield) + else: + return (yield) + + +def _handle_twisted_exc_info( + rawexcinfo: _SysExcInfoType | BaseException, +) -> _SysExcInfoType: + """ + Twisted passes a custom Failure instance to `addError()` instead of using `sys.exc_info()`. + Therefore, if `rawexcinfo` is a `Failure` instance, convert it into the equivalent `sys.exc_info()` tuple + as expected by pytest. + """ + twisted_version = _get_twisted_version() + if twisted_version is TwistedVersion.NotInstalled: + # Unfortunately, because we cannot import `twisted.python.failure` at the top of the file + # and use it in the signature, we need to use `type:ignore` here because we cannot narrow + # the type properly in the `if` statement above. + return rawexcinfo # type:ignore[return-value] + elif twisted_version is TwistedVersion.Version24: + # Twisted calls addError() passing its own classes (like `twisted.python.Failure`), which violates + # the `addError()` signature, so we extract the original `sys.exc_info()` tuple which is stored + # in the object. + if hasattr(rawexcinfo, TWISTED_RAW_EXCINFO_ATTR): + saved_exc_info = getattr(rawexcinfo, TWISTED_RAW_EXCINFO_ATTR) + # Delete the attribute from the original object to avoid leaks. + delattr(rawexcinfo, TWISTED_RAW_EXCINFO_ATTR) + return saved_exc_info # type:ignore[no-any-return] + return rawexcinfo # type:ignore[return-value] + elif twisted_version is TwistedVersion.Version25: + if isinstance(rawexcinfo, BaseException): + import twisted.python.failure + + if isinstance(rawexcinfo, twisted.python.failure.Failure): + tb = rawexcinfo.__traceback__ + if tb is None: + tb = sys.exc_info()[2] + return type(rawexcinfo.value), rawexcinfo.value, tb + + return rawexcinfo # type:ignore[return-value] + else: + # Ideally we would use assert_never() here, but it is not available in all Python versions + # we support, plus we do not require `type_extensions` currently. + assert False, f"Unexpected Twisted version: {twisted_version}" diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/unraisableexception.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/unraisableexception.py new file mode 100644 index 0000000000000000000000000000000000000000..0faca36aa00e5fe793fb4ff4d1c630eeff540770 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/unraisableexception.py @@ -0,0 +1,163 @@ +from __future__ import annotations + +import collections +from collections.abc import Callable +import functools +import gc +import sys +import traceback +from typing import NamedTuple +from typing import TYPE_CHECKING +import warnings + +from _pytest.config import Config +from _pytest.nodes import Item +from _pytest.stash import StashKey +from _pytest.tracemalloc import tracemalloc_message +import pytest + + +if TYPE_CHECKING: + pass + +if sys.version_info < (3, 11): + from exceptiongroup import ExceptionGroup + + +# This is a stash item and not a simple constant to allow pytester to override it. +gc_collect_iterations_key = StashKey[int]() + + +def gc_collect_harder(iterations: int) -> None: + for _ in range(iterations): + gc.collect() + + +class UnraisableMeta(NamedTuple): + msg: str + cause_msg: str + exc_value: BaseException | None + + +unraisable_exceptions: StashKey[collections.deque[UnraisableMeta | BaseException]] = ( + StashKey() +) + + +def collect_unraisable(config: Config) -> None: + pop_unraisable = config.stash[unraisable_exceptions].pop + errors: list[pytest.PytestUnraisableExceptionWarning | RuntimeError] = [] + meta = None + hook_error = None + try: + while True: + try: + meta = pop_unraisable() + except IndexError: + break + + if isinstance(meta, BaseException): + hook_error = RuntimeError("Failed to process unraisable exception") + hook_error.__cause__ = meta + errors.append(hook_error) + continue + + msg = meta.msg + try: + warnings.warn(pytest.PytestUnraisableExceptionWarning(msg)) + except pytest.PytestUnraisableExceptionWarning as e: + # This except happens when the warning is treated as an error (e.g. `-Werror`). + if meta.exc_value is not None: + # Exceptions have a better way to show the traceback, but + # warnings do not, so hide the traceback from the msg and + # set the cause so the traceback shows up in the right place. + e.args = (meta.cause_msg,) + e.__cause__ = meta.exc_value + errors.append(e) + + if len(errors) == 1: + raise errors[0] + if errors: + raise ExceptionGroup("multiple unraisable exception warnings", errors) + finally: + del errors, meta, hook_error + + +def cleanup( + *, config: Config, prev_hook: Callable[[sys.UnraisableHookArgs], object] +) -> None: + # A single collection doesn't necessarily collect everything. + # Constant determined experimentally by the Trio project. + gc_collect_iterations = config.stash.get(gc_collect_iterations_key, 5) + try: + try: + gc_collect_harder(gc_collect_iterations) + collect_unraisable(config) + finally: + sys.unraisablehook = prev_hook + finally: + del config.stash[unraisable_exceptions] + + +def unraisable_hook( + unraisable: sys.UnraisableHookArgs, + /, + *, + append: Callable[[UnraisableMeta | BaseException], object], +) -> None: + try: + # we need to compute these strings here as they might change after + # the unraisablehook finishes and before the metadata object is + # collected by a pytest hook + err_msg = ( + "Exception ignored in" if unraisable.err_msg is None else unraisable.err_msg + ) + summary = f"{err_msg}: {unraisable.object!r}" + traceback_message = "\n\n" + "".join( + traceback.format_exception( + unraisable.exc_type, + unraisable.exc_value, + unraisable.exc_traceback, + ) + ) + tracemalloc_tb = "\n" + tracemalloc_message(unraisable.object) + msg = summary + traceback_message + tracemalloc_tb + cause_msg = summary + tracemalloc_tb + + append( + UnraisableMeta( + msg=msg, + cause_msg=cause_msg, + exc_value=unraisable.exc_value, + ) + ) + except BaseException as e: + append(e) + # Raising this will cause the exception to be logged twice, once in our + # collect_unraisable and once by the unraisablehook calling machinery + # which is fine - this should never happen anyway and if it does + # it should probably be reported as a pytest bug. + raise + + +def pytest_configure(config: Config) -> None: + prev_hook = sys.unraisablehook + deque: collections.deque[UnraisableMeta | BaseException] = collections.deque() + config.stash[unraisable_exceptions] = deque + config.add_cleanup(functools.partial(cleanup, config=config, prev_hook=prev_hook)) + sys.unraisablehook = functools.partial(unraisable_hook, append=deque.append) + + +@pytest.hookimpl(trylast=True) +def pytest_runtest_setup(item: Item) -> None: + collect_unraisable(item.config) + + +@pytest.hookimpl(trylast=True) +def pytest_runtest_call(item: Item) -> None: + collect_unraisable(item.config) + + +@pytest.hookimpl(trylast=True) +def pytest_runtest_teardown(item: Item) -> None: + collect_unraisable(item.config) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/warning_types.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/warning_types.py new file mode 100644 index 0000000000000000000000000000000000000000..93071b4a1b2d3bd2d556d926829728562ad9fd11 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/warning_types.py @@ -0,0 +1,172 @@ +from __future__ import annotations + +import dataclasses +import inspect +from types import FunctionType +from typing import Any +from typing import final +from typing import Generic +from typing import TypeVar +import warnings + + +class PytestWarning(UserWarning): + """Base class for all warnings emitted by pytest.""" + + __module__ = "pytest" + + +@final +class PytestAssertRewriteWarning(PytestWarning): + """Warning emitted by the pytest assert rewrite module.""" + + __module__ = "pytest" + + +@final +class PytestCacheWarning(PytestWarning): + """Warning emitted by the cache plugin in various situations.""" + + __module__ = "pytest" + + +@final +class PytestConfigWarning(PytestWarning): + """Warning emitted for configuration issues.""" + + __module__ = "pytest" + + +@final +class PytestCollectionWarning(PytestWarning): + """Warning emitted when pytest is not able to collect a file or symbol in a module.""" + + __module__ = "pytest" + + +class PytestDeprecationWarning(PytestWarning, DeprecationWarning): + """Warning class for features that will be removed in a future version.""" + + __module__ = "pytest" + + +class PytestRemovedIn9Warning(PytestDeprecationWarning): + """Warning class for features that will be removed in pytest 9.""" + + __module__ = "pytest" + + +class PytestRemovedIn10Warning(PytestDeprecationWarning): + """Warning class for features that will be removed in pytest 10.""" + + __module__ = "pytest" + + +@final +class PytestExperimentalApiWarning(PytestWarning, FutureWarning): + """Warning category used to denote experiments in pytest. + + Use sparingly as the API might change or even be removed completely in a + future version. + """ + + __module__ = "pytest" + + @classmethod + def simple(cls, apiname: str) -> PytestExperimentalApiWarning: + return cls(f"{apiname} is an experimental api that may change over time") + + +@final +class PytestReturnNotNoneWarning(PytestWarning): + """ + Warning emitted when a test function returns a value other than ``None``. + + See :ref:`return-not-none` for details. + """ + + __module__ = "pytest" + + +@final +class PytestUnknownMarkWarning(PytestWarning): + """Warning emitted on use of unknown markers. + + See :ref:`mark` for details. + """ + + __module__ = "pytest" + + +@final +class PytestUnraisableExceptionWarning(PytestWarning): + """An unraisable exception was reported. + + Unraisable exceptions are exceptions raised in :meth:`__del__ <object.__del__>` + implementations and similar situations when the exception cannot be raised + as normal. + """ + + __module__ = "pytest" + + +@final +class PytestUnhandledThreadExceptionWarning(PytestWarning): + """An unhandled exception occurred in a :class:`~threading.Thread`. + + Such exceptions don't propagate normally. + """ + + __module__ = "pytest" + + +_W = TypeVar("_W", bound=PytestWarning) + + +@final +@dataclasses.dataclass +class UnformattedWarning(Generic[_W]): + """A warning meant to be formatted during runtime. + + This is used to hold warnings that need to format their message at runtime, + as opposed to a direct message. + """ + + category: type[_W] + template: str + + def format(self, **kwargs: Any) -> _W: + """Return an instance of the warning category, formatted with given kwargs.""" + return self.category(self.template.format(**kwargs)) + + +@final +class PytestFDWarning(PytestWarning): + """When the lsof plugin finds leaked fds.""" + + __module__ = "pytest" + + +def warn_explicit_for(method: FunctionType, message: PytestWarning) -> None: + """ + Issue the warning :param:`message` for the definition of the given :param:`method` + + this helps to log warnings for functions defined prior to finding an issue with them + (like hook wrappers being marked in a legacy mechanism) + """ + lineno = method.__code__.co_firstlineno + filename = inspect.getfile(method) + module = method.__module__ + mod_globals = method.__globals__ + try: + warnings.warn_explicit( + message, + type(message), + filename=filename, + module=module, + registry=mod_globals.setdefault("__warningregistry__", {}), + lineno=lineno, + ) + except Warning as w: + # If warnings are errors (e.g. -Werror), location information gets lost, so we add it to the message. + raise type(w)(f"{w}\n at {filename}:{lineno}") from None diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/warnings.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/warnings.py new file mode 100644 index 0000000000000000000000000000000000000000..1dbf0025a3188b892d245fbf04dafe6af1c2b39e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/_pytest/warnings.py @@ -0,0 +1,151 @@ +# mypy: allow-untyped-defs +from __future__ import annotations + +from collections.abc import Generator +from contextlib import contextmanager +from contextlib import ExitStack +import sys +from typing import Literal +import warnings + +from _pytest.config import apply_warning_filters +from _pytest.config import Config +from _pytest.config import parse_warning_filter +from _pytest.main import Session +from _pytest.nodes import Item +from _pytest.terminal import TerminalReporter +from _pytest.tracemalloc import tracemalloc_message +import pytest + + +@contextmanager +def catch_warnings_for_item( + config: Config, + ihook, + when: Literal["config", "collect", "runtest"], + item: Item | None, + *, + record: bool = True, +) -> Generator[None]: + """Context manager that catches warnings generated in the contained execution block. + + ``item`` can be None if we are not in the context of an item execution. + + Each warning captured triggers the ``pytest_warning_recorded`` hook. + """ + config_filters = config.getini("filterwarnings") + cmdline_filters = config.known_args_namespace.pythonwarnings or [] + with warnings.catch_warnings(record=record) as log: + if not sys.warnoptions: + # If user is not explicitly configuring warning filters, show deprecation warnings by default (#2908). + warnings.filterwarnings("always", category=DeprecationWarning) + warnings.filterwarnings("always", category=PendingDeprecationWarning) + + warnings.filterwarnings("error", category=pytest.PytestRemovedIn9Warning) + + apply_warning_filters(config_filters, cmdline_filters) + + # apply filters from "filterwarnings" marks + nodeid = "" if item is None else item.nodeid + if item is not None: + for mark in item.iter_markers(name="filterwarnings"): + for arg in mark.args: + warnings.filterwarnings(*parse_warning_filter(arg, escape=False)) + + try: + yield + finally: + if record: + # mypy can't infer that record=True means log is not None; help it. + assert log is not None + + for warning_message in log: + ihook.pytest_warning_recorded.call_historic( + kwargs=dict( + warning_message=warning_message, + nodeid=nodeid, + when=when, + location=None, + ) + ) + + +def warning_record_to_str(warning_message: warnings.WarningMessage) -> str: + """Convert a warnings.WarningMessage to a string.""" + return warnings.formatwarning( + str(warning_message.message), + warning_message.category, + warning_message.filename, + warning_message.lineno, + warning_message.line, + ) + tracemalloc_message(warning_message.source) + + +@pytest.hookimpl(wrapper=True, tryfirst=True) +def pytest_runtest_protocol(item: Item) -> Generator[None, object, object]: + with catch_warnings_for_item( + config=item.config, ihook=item.ihook, when="runtest", item=item + ): + return (yield) + + +@pytest.hookimpl(wrapper=True, tryfirst=True) +def pytest_collection(session: Session) -> Generator[None, object, object]: + config = session.config + with catch_warnings_for_item( + config=config, ihook=config.hook, when="collect", item=None + ): + return (yield) + + +@pytest.hookimpl(wrapper=True) +def pytest_terminal_summary( + terminalreporter: TerminalReporter, +) -> Generator[None]: + config = terminalreporter.config + with catch_warnings_for_item( + config=config, ihook=config.hook, when="config", item=None + ): + return (yield) + + +@pytest.hookimpl(wrapper=True) +def pytest_sessionfinish(session: Session) -> Generator[None]: + config = session.config + with catch_warnings_for_item( + config=config, ihook=config.hook, when="config", item=None + ): + return (yield) + + +@pytest.hookimpl(wrapper=True) +def pytest_load_initial_conftests( + early_config: Config, +) -> Generator[None]: + with catch_warnings_for_item( + config=early_config, ihook=early_config.hook, when="config", item=None + ): + return (yield) + + +def pytest_configure(config: Config) -> None: + with ExitStack() as stack: + stack.enter_context( + catch_warnings_for_item( + config=config, + ihook=config.hook, + when="config", + item=None, + # this disables recording because the terminalreporter has + # finished by the time it comes to reporting logged warnings + # from the end of config cleanup. So for now, this is only + # useful for setting a warning filter with an 'error' action. + record=False, + ) + ) + config.addinivalue_line( + "markers", + "filterwarnings(warning): add a warning filter to the given test. " + "see https://docs.pytest.org/en/stable/how-to/capture-warnings.html#pytest-mark-filterwarnings ", + ) + config.add_cleanup(stack.pop_all().close) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/py.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/py.py new file mode 100644 index 0000000000000000000000000000000000000000..5c661e66c1fa1c66721b3a330a5bc583937d08c9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/py.py @@ -0,0 +1,15 @@ +# shim for pylib going away +# if pylib is installed this file will get skipped +# (`py/__init__.py` has higher precedence) +from __future__ import annotations + +import sys + +import _pytest._py.error as error +import _pytest._py.path as path + + +sys.modules["py.error"] = error +sys.modules["py.path"] = path + +__all__ = ["error", "path"] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/INSTALLER b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/INSTALLER new file mode 100644 index 0000000000000000000000000000000000000000..a34a7e56db35cc4c85bfa166244b3d63a6a240d4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/INSTALLER @@ -0,0 +1 @@ +conda diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/METADATA b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/METADATA new file mode 100644 index 0000000000000000000000000000000000000000..1ef61364dda7d86ff893af6f9327f9522e4ac733 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/METADATA @@ -0,0 +1,212 @@ +Metadata-Version: 2.4 +Name: pytest +Version: 9.0.3 +Summary: pytest: simple powerful testing with Python +Author: Holger Krekel, Bruno Oliveira, Ronny Pfannschmidt, Floris Bruynooghe, Brianna Laugher, Freya Bruhin, Others (See AUTHORS) +License-Expression: MIT +Project-URL: Changelog, https://docs.pytest.org/en/stable/changelog.html +Project-URL: Contact, https://docs.pytest.org/en/stable/contact.html +Project-URL: Funding, https://docs.pytest.org/en/stable/sponsor.html +Project-URL: Homepage, https://docs.pytest.org/en/latest/ +Project-URL: Source, https://github.com/pytest-dev/pytest +Project-URL: Tracker, https://github.com/pytest-dev/pytest/issues +Keywords: test,unittest +Classifier: Development Status :: 6 - Mature +Classifier: Intended Audience :: Developers +Classifier: Operating System :: MacOS +Classifier: Operating System :: Microsoft :: Windows +Classifier: Operating System :: POSIX +Classifier: Operating System :: Unix +Classifier: Programming Language :: Python :: 3 :: Only +Classifier: Programming Language :: Python :: 3.10 +Classifier: Programming Language :: Python :: 3.11 +Classifier: Programming Language :: Python :: 3.12 +Classifier: Programming Language :: Python :: 3.13 +Classifier: Programming Language :: Python :: 3.14 +Classifier: Topic :: Software Development :: Libraries +Classifier: Topic :: Software Development :: Testing +Classifier: Topic :: Utilities +Requires-Python: >=3.10 +Description-Content-Type: text/x-rst +License-File: LICENSE +Requires-Dist: colorama>=0.4; sys_platform == "win32" +Requires-Dist: exceptiongroup>=1; python_version < "3.11" +Requires-Dist: iniconfig>=1.0.1 +Requires-Dist: packaging>=22 +Requires-Dist: pluggy<2,>=1.5 +Requires-Dist: pygments>=2.7.2 +Requires-Dist: tomli>=1; python_version < "3.11" +Provides-Extra: dev +Requires-Dist: argcomplete; extra == "dev" +Requires-Dist: attrs>=19.2; extra == "dev" +Requires-Dist: hypothesis>=3.56; extra == "dev" +Requires-Dist: mock; extra == "dev" +Requires-Dist: requests; extra == "dev" +Requires-Dist: setuptools; extra == "dev" +Requires-Dist: xmlschema; extra == "dev" +Dynamic: license-file + +.. image:: https://github.com/pytest-dev/pytest/raw/main/doc/en/img/pytest_logo_curves.svg + :target: https://docs.pytest.org/en/stable/ + :align: center + :height: 200 + :alt: pytest + + +------ + +.. image:: https://img.shields.io/pypi/v/pytest.svg + :target: https://pypi.org/project/pytest/ + +.. image:: https://img.shields.io/conda/vn/conda-forge/pytest.svg + :target: https://anaconda.org/conda-forge/pytest + +.. image:: https://img.shields.io/pypi/pyversions/pytest.svg + :target: https://pypi.org/project/pytest/ + +.. image:: https://codecov.io/gh/pytest-dev/pytest/branch/main/graph/badge.svg + :target: https://codecov.io/gh/pytest-dev/pytest + :alt: Code coverage Status + +.. image:: https://github.com/pytest-dev/pytest/actions/workflows/test.yml/badge.svg + :target: https://github.com/pytest-dev/pytest/actions?query=workflow%3Atest + +.. image:: https://results.pre-commit.ci/badge/github/pytest-dev/pytest/main.svg + :target: https://results.pre-commit.ci/latest/github/pytest-dev/pytest/main + :alt: pre-commit.ci status + +.. image:: https://www.codetriage.com/pytest-dev/pytest/badges/users.svg + :target: https://www.codetriage.com/pytest-dev/pytest + +.. image:: https://readthedocs.org/projects/pytest/badge/?version=latest + :target: https://pytest.readthedocs.io/en/latest/?badge=latest + :alt: Documentation Status + +.. image:: https://img.shields.io/badge/Discord-pytest--dev-blue + :target: https://discord.com/invite/pytest-dev + :alt: Discord + +.. image:: https://img.shields.io/badge/Libera%20chat-%23pytest-orange + :target: https://web.libera.chat/#pytest + :alt: Libera chat + + +The ``pytest`` framework makes it easy to write small tests, yet +scales to support complex functional testing for applications and libraries. + +An example of a simple test: + +.. code-block:: python + + # content of test_sample.py + def inc(x): + return x + 1 + + + def test_answer(): + assert inc(3) == 5 + + +To execute it:: + + $ pytest + ============================= test session starts ============================= + collected 1 items + + test_sample.py F + + ================================== FAILURES =================================== + _________________________________ test_answer _________________________________ + + def test_answer(): + > assert inc(3) == 5 + E assert 4 == 5 + E + where 4 = inc(3) + + test_sample.py:5: AssertionError + ========================== 1 failed in 0.04 seconds =========================== + + +Thanks to ``pytest``'s detailed assertion introspection, you can simply use plain ``assert`` statements. See `getting-started <https://docs.pytest.org/en/stable/getting-started.html#our-first-test-run>`_ for more examples. + + +Features +-------- + +- Detailed info on failing `assert statements <https://docs.pytest.org/en/stable/how-to/assert.html>`_ (no need to remember ``self.assert*`` names) + +- `Auto-discovery + <https://docs.pytest.org/en/stable/explanation/goodpractices.html#python-test-discovery>`_ + of test modules and functions + +- `Modular fixtures <https://docs.pytest.org/en/stable/explanation/fixtures.html>`_ for + managing small or parametrized long-lived test resources + +- Can run `unittest <https://docs.pytest.org/en/stable/how-to/unittest.html>`_ (or trial) + test suites out of the box + +- Python 3.10+ or PyPy3 + +- Rich plugin architecture, with over 1300+ `external plugins <https://docs.pytest.org/en/latest/reference/plugin_list.html>`_ and thriving community + + +Documentation +------------- + +For full documentation, including installation, tutorials and PDF documents, please see https://docs.pytest.org/en/stable/. + + +Bugs/Requests +------------- + +Please use the `GitHub issue tracker <https://github.com/pytest-dev/pytest/issues>`_ to submit bugs or request features. + + +Changelog +--------- + +Consult the `Changelog <https://docs.pytest.org/en/stable/changelog.html>`__ page for fixes and enhancements of each version. + + +Support pytest +-------------- + +`Open Collective`_ is an online funding platform for open and transparent communities. +It provides tools to raise money and share your finances in full transparency. + +It is the platform of choice for individuals and companies that want to make one-time or +monthly donations directly to the project. + +See more details in the `pytest collective`_. + +.. _Open Collective: https://opencollective.com +.. _pytest collective: https://opencollective.com/pytest + + +pytest for enterprise +--------------------- + +Available as part of the Tidelift Subscription. + +The maintainers of pytest and thousands of other packages are working with Tidelift to deliver commercial support and +maintenance for the open source dependencies you use to build your applications. +Save time, reduce risk, and improve code health, while paying the maintainers of the exact dependencies you use. + +`Learn more. <https://tidelift.com/subscription/pkg/pypi-pytest?utm_source=pypi-pytest&utm_medium=referral&utm_campaign=enterprise&utm_term=repo>`_ + +Security +^^^^^^^^ + +pytest has never been associated with a security vulnerability, but in any case, to report a +security vulnerability please use the `Tidelift security contact <https://tidelift.com/security>`_. +Tidelift will coordinate the fix and disclosure. + + +License +------- + +Copyright Holger Krekel and others, 2004. + +Distributed under the terms of the `MIT`_ license, pytest is free and open source software. + +.. _`MIT`: https://github.com/pytest-dev/pytest/blob/main/LICENSE diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/RECORD b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/RECORD new file mode 100644 index 0000000000000000000000000000000000000000..0dc8db0f087214c99f77eaf6f708fedb86d6ee2a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/RECORD @@ -0,0 +1,161 @@ +../../../bin/py.test,sha256=TP953k42-SVpKIvPyqkMTTWOtYbWR6Gq85FaYgy19pw,452 +../../../bin/pytest,sha256=TP953k42-SVpKIvPyqkMTTWOtYbWR6Gq85FaYgy19pw,452 +__pycache__/py.cpython-310.pyc,, +_pytest/__init__.py,sha256=4IdRJhnW5XG2KlaJkOxn5_TC9WeQ5tXDSF7tbb4vEso,391 +_pytest/__pycache__/__init__.cpython-310.pyc,, +_pytest/__pycache__/_argcomplete.cpython-310.pyc,, +_pytest/__pycache__/_version.cpython-310.pyc,, +_pytest/__pycache__/cacheprovider.cpython-310.pyc,, +_pytest/__pycache__/capture.cpython-310.pyc,, +_pytest/__pycache__/compat.cpython-310.pyc,, +_pytest/__pycache__/debugging.cpython-310.pyc,, +_pytest/__pycache__/deprecated.cpython-310.pyc,, +_pytest/__pycache__/doctest.cpython-310.pyc,, +_pytest/__pycache__/faulthandler.cpython-310.pyc,, +_pytest/__pycache__/fixtures.cpython-310.pyc,, +_pytest/__pycache__/freeze_support.cpython-310.pyc,, +_pytest/__pycache__/helpconfig.cpython-310.pyc,, +_pytest/__pycache__/hookspec.cpython-310.pyc,, +_pytest/__pycache__/junitxml.cpython-310.pyc,, +_pytest/__pycache__/legacypath.cpython-310.pyc,, +_pytest/__pycache__/logging.cpython-310.pyc,, +_pytest/__pycache__/main.cpython-310.pyc,, +_pytest/__pycache__/monkeypatch.cpython-310.pyc,, +_pytest/__pycache__/nodes.cpython-310.pyc,, +_pytest/__pycache__/outcomes.cpython-310.pyc,, +_pytest/__pycache__/pastebin.cpython-310.pyc,, +_pytest/__pycache__/pathlib.cpython-310.pyc,, +_pytest/__pycache__/pytester.cpython-310.pyc,, +_pytest/__pycache__/pytester_assertions.cpython-310.pyc,, +_pytest/__pycache__/python.cpython-310.pyc,, +_pytest/__pycache__/python_api.cpython-310.pyc,, +_pytest/__pycache__/raises.cpython-310.pyc,, +_pytest/__pycache__/recwarn.cpython-310.pyc,, +_pytest/__pycache__/reports.cpython-310.pyc,, +_pytest/__pycache__/runner.cpython-310.pyc,, +_pytest/__pycache__/scope.cpython-310.pyc,, +_pytest/__pycache__/setuponly.cpython-310.pyc,, +_pytest/__pycache__/setupplan.cpython-310.pyc,, +_pytest/__pycache__/skipping.cpython-310.pyc,, +_pytest/__pycache__/stash.cpython-310.pyc,, +_pytest/__pycache__/stepwise.cpython-310.pyc,, +_pytest/__pycache__/subtests.cpython-310.pyc,, +_pytest/__pycache__/terminal.cpython-310.pyc,, +_pytest/__pycache__/terminalprogress.cpython-310.pyc,, +_pytest/__pycache__/threadexception.cpython-310.pyc,, +_pytest/__pycache__/timing.cpython-310.pyc,, +_pytest/__pycache__/tmpdir.cpython-310.pyc,, +_pytest/__pycache__/tracemalloc.cpython-310.pyc,, +_pytest/__pycache__/unittest.cpython-310.pyc,, +_pytest/__pycache__/unraisableexception.cpython-310.pyc,, +_pytest/__pycache__/warning_types.cpython-310.pyc,, +_pytest/__pycache__/warnings.cpython-310.pyc,, +_pytest/_argcomplete.py,sha256=gh0pna66p4LVb2D8ST4568WGxvdInGT43m6slYhqNqU,3776 +_pytest/_code/__init__.py,sha256=BKbowoYQADKjAJmTWdQ8SSQLbBBsh0-dZj3TGjtn6yM,521 +_pytest/_code/__pycache__/__init__.cpython-310.pyc,, +_pytest/_code/__pycache__/code.cpython-310.pyc,, +_pytest/_code/__pycache__/source.cpython-310.pyc,, +_pytest/_code/code.py,sha256=KWjr6ZcF8iBryOHA1dyRgyBrfDSpTLxxOvjN1H3Enx4,56126 +_pytest/_code/source.py,sha256=VvNzWHYfT96SO128m7tfIdagZ35yug46bWfgXH_5Vp8,7772 +_pytest/_io/__init__.py,sha256=pkLF29VEFr6Dlr3eOtJL8sf47RLFt1Jf4X1DZBPlYmc,190 +_pytest/_io/__pycache__/__init__.cpython-310.pyc,, +_pytest/_io/__pycache__/pprint.cpython-310.pyc,, +_pytest/_io/__pycache__/saferepr.cpython-310.pyc,, +_pytest/_io/__pycache__/terminalwriter.cpython-310.pyc,, +_pytest/_io/__pycache__/wcwidth.cpython-310.pyc,, +_pytest/_io/pprint.py,sha256=GLBKL6dmnRr92GnVMkNzMkKqx08Op7tdJSeh3AewonY,19622 +_pytest/_io/saferepr.py,sha256=Hhx5F-75iz03hdk-WO86Bmy9RBuRHsuJj-YUzozfrgo,4082 +_pytest/_io/terminalwriter.py,sha256=K0pB1pfAvrKBWFARKSobQ4wWi0pdmiBaGb3a_v_AAjQ,8994 +_pytest/_io/wcwidth.py,sha256=cUEJ74UhweICwbKvU2q6noZcNgD0QlBEB9CfakGYaqA,1289 +_pytest/_py/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +_pytest/_py/__pycache__/__init__.cpython-310.pyc,, +_pytest/_py/__pycache__/error.cpython-310.pyc,, +_pytest/_py/__pycache__/path.cpython-310.pyc,, +_pytest/_py/error.py,sha256=kGQ7F8_fZ6YVBhAx-u9mkTQBTx0qIxxnVMC0CgiOd70,3475 +_pytest/_py/path.py,sha256=cqCn0amzKhqSqiW1Wzt4KqvFI2ncKBzGnwERUsWpC_0,49229 +_pytest/_version.py,sha256=k2-_mebD9I3QrKiHYzmNlkdwhc4vy7pBzYy-do5yOU4,704 +_pytest/assertion/__init__.py,sha256=OjnJm4j6VHgwYjKvW8d-KFefjEdOSONFF4z10o9r7eg,7120 +_pytest/assertion/__pycache__/__init__.cpython-310.pyc,, +_pytest/assertion/__pycache__/rewrite.cpython-310.pyc,, +_pytest/assertion/__pycache__/truncate.cpython-310.pyc,, +_pytest/assertion/__pycache__/util.cpython-310.pyc,, +_pytest/assertion/rewrite.py,sha256=N2rauTZyAmVShY_6ygCcvvVT8ILy5N7oes5155ZtSxA,48206 +_pytest/assertion/truncate.py,sha256=2vOU3kS4hUZhDDL0Xaz1pM7oW_10wMc0J3b_lEbSzQI,5438 +_pytest/assertion/util.py,sha256=YQLyQ7nYHQu0ui5SeB62KB0KjuueFyHwghGT_p1dfmM,20561 +_pytest/cacheprovider.py,sha256=QCKdiepUSkuPNEx5DlhIQHbA413MwNUld4LIpV16FW8,23149 +_pytest/capture.py,sha256=kulumJdRdHu7zoosOr4lfHR0ce6LsOthau9Byrw8xV4,36829 +_pytest/compat.py,sha256=qcHcZHQyEA6TO3C0qGEgO0b_YxNu23ok0mTZ0sah6kk,10254 +_pytest/config/__init__.py,sha256=LqRPFTnta3LrYUAtRjO5Lp_vmYlcQaxjR4YGkFFuRs8,79300 +_pytest/config/__pycache__/__init__.cpython-310.pyc,, +_pytest/config/__pycache__/argparsing.cpython-310.pyc,, +_pytest/config/__pycache__/compat.cpython-310.pyc,, +_pytest/config/__pycache__/exceptions.cpython-310.pyc,, +_pytest/config/__pycache__/findpaths.cpython-310.pyc,, +_pytest/config/argparsing.py,sha256=dDjwtY9nhTQ9Q14ZbdU-EGwoQKZFuVZB1Ps0wclg5_o,20439 +_pytest/config/compat.py,sha256=djDt_XTPwXDIgnnopti2ZVrqtwzO5hFWiMhgU5dgIM4,2947 +_pytest/config/exceptions.py,sha256=6Vm9yzwUOxJGm17ZMGbw69v_i07mT1KmBwENM2scKhk,315 +_pytest/config/findpaths.py,sha256=0iq92sR6c6gVBFacwMNW-gFFzlfvWNO46dX9x39gnIg,12878 +_pytest/debugging.py,sha256=JkV7Ob7wQ53TFGkQ0Ta96jAMYGubgdXiEs39T7FPzHQ,13947 +_pytest/deprecated.py,sha256=EikoYjqdlLTZgbBNTmFdPqiP5DdZpzAyKwRbO2hA0VE,3611 +_pytest/doctest.py,sha256=GgjdWOxH-fV9eQoWQ7puKejcFdA1HPtG-Y7qbp-5L8c,25478 +_pytest/faulthandler.py,sha256=1c7DpRtP0_C3zpFUSw1BORpAG8GsiDtJ9zCuWdEiLc0,4250 +_pytest/fixtures.py,sha256=7_gKoVUCpfo4sCLy3T07p2Dv_xa5x2HnKDKZu884DeY,78681 +_pytest/freeze_support.py,sha256=X94IxipqebeA_HgzJh8dbjqGnrtEQFuMIC5hK7SGWXw,1300 +_pytest/helpconfig.py,sha256=6iy21oUDURGedZpB3emSzaFCxeNT_ERSkSIZLIxMJvU,10019 +_pytest/hookspec.py,sha256=EEkjhv3tWsIXzPS-LyvXsFx5mar3AMm4POBCePIHCMQ,43019 +_pytest/junitxml.py,sha256=1xGYlQzzO9HH3HghZ5hu4TBCf8V-IhBG5kVdx6W2PVo,25522 +_pytest/legacypath.py,sha256=_l6v8akNMfTc5TAjvbc6M-_t157p9QE6-118WM0DRt8,16588 +_pytest/logging.py,sha256=TZ67JQP_3Ylt0p11D2J68L_os9glsuggMvec0Hljtb8,35234 +_pytest/main.py,sha256=fKKyDMQfv8J2G8sjHuyyaWfVU2UQNcQAAPRNcOF0tpM,42435 +_pytest/mark/__init__.py,sha256=38H7wh2k3SZMZNZwAhPbHBxpPxYbn-wzmVtGUYigvzc,9870 +_pytest/mark/__pycache__/__init__.cpython-310.pyc,, +_pytest/mark/__pycache__/expression.cpython-310.pyc,, +_pytest/mark/__pycache__/structures.cpython-310.pyc,, +_pytest/mark/expression.py,sha256=30rS65yMCdfn1UWiCP_4imfzSeWEtP_qz4_2JV3Y1-U,11244 +_pytest/mark/structures.py,sha256=krlQ7sEUUUmFjy3yjoXA0BciTgUpklMtLqTlKOsEwac,23073 +_pytest/monkeypatch.py,sha256=WX3_6czULhvc3wSF-0N8Vesbv9wGN3dwliYcDvT8Efs,15500 +_pytest/nodes.py,sha256=aTsDhbLEVkZ2cgC8UXQW53bBDD5Y7l7ZNwB0kb5Nho4,26540 +_pytest/outcomes.py,sha256=qbgHRCERDRK8W8ZAfanQf4Dp4_W7vNoc2vv3pm3HtKo,10108 +_pytest/pastebin.py,sha256=p92zJtSNz9-xDEFzqQ3zemYggXRaDnxD6X4IyitevbA,4155 +_pytest/pathlib.py,sha256=xIOYa8ElyypD2BTuS2_8bh6OyD4DjPfBOulkFxQ5b1Q,37879 +_pytest/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +_pytest/pytester.py,sha256=x0am9bXHz3QPBTPXPylcYmfP8sGhVi5RC_KPj6g3Hn4,62389 +_pytest/pytester_assertions.py,sha256=xX_HbFPB-Rz_NNDttTY39ft7_wZLvPgQQBVevSCeVmA,2253 +_pytest/python.py,sha256=_SgxiiPnr7jPgXlKs8sCjdsBSN-AoUZmzIvJMgMkVh4,68754 +_pytest/python_api.py,sha256=LzTjh4Pz25Z7wIVFDdxTQ6umqYSC5B_8GtKxu4Cvkaw,31707 +_pytest/raises.py,sha256=86V-hoY5hYba69npyrH7r4kQNb8QjouYb8SydGLmjVc,60082 +_pytest/recwarn.py,sha256=4a6s8WWqn-yCCHyqgnB_ffc_zkwXBGPCuvC-03L65c4,13386 +_pytest/reports.py,sha256=LpJypnzeOLkl66JKKIsu9390HA2qItpvvOU-5uWPpB0,23230 +_pytest/runner.py,sha256=jXhLKz4jsF9MTt0_UmPrEZZOhrbhbSyBTF_LISXcTqQ,19785 +_pytest/scope.py,sha256=pB7jsiisth16PBFacV1Yxd3Pj3YAx2dmlSmGbG4mw6A,2738 +_pytest/setuponly.py,sha256=BsRrC4ERDVr42-2G_L0AxhNU4XVwbMsy5S0lOvKr8wA,3167 +_pytest/setupplan.py,sha256=l-ycFNxDZPyY52wh4f7yaqhzZ7SW1ijSKnQLmqzDZWA,1184 +_pytest/skipping.py,sha256=WCRzHVoxF4D0GOrJoJTnzx_WOoLTsM1enlSYzG7NEnw,10810 +_pytest/stash.py,sha256=5pE3kDx4q855TW9aVvYTdrkkKlMDU6-xiX4luKpJEgI,3090 +_pytest/stepwise.py,sha256=kD81DrnhnclKBmMfauwQmbeMbYUvuw07w5WnNkmIdEQ,7689 +_pytest/subtests.py,sha256=-OzOpE0j98vDWMAsI-xMJ0FcYb6inLq6YPH_0tEyU44,13241 +_pytest/terminal.py,sha256=4v5Ab5MOeV0JAmdG6CCamnFCrHBPwKAgCvnk900hBNA,64444 +_pytest/terminalprogress.py,sha256=_IO3vRGVATz3RkkacqIAaCUC4-Rq2pTEANUAY66dEwQ,1153 +_pytest/threadexception.py,sha256=hTccpzZUrrQkDROVFAqHgXwAU481ca4Mq4CA4YB7my4,4953 +_pytest/timing.py,sha256=lPcKHaM1eKHv1_2ZgUaPK9h3FhtqGvZAYucx_LSdZw0,3108 +_pytest/tmpdir.py,sha256=slqA2yVHbP2dWOfIDolirJ45ymKDaaHbeJqcgaImHdk,12526 +_pytest/tracemalloc.py,sha256=lCUB_YUAb6R1vqq_b-LSYSXy-Tidbn2m7tfzmWAUrjk,778 +_pytest/unittest.py,sha256=lF52zcPqb931FoWCWC7Yi78kAWABDRkqb60VZpI1Hl4,24485 +_pytest/unraisableexception.py,sha256=dNaBpBHkOB4pOISoaMdau2ojrGoc_i4ux76DVXLLT-w,5179 +_pytest/warning_types.py,sha256=Vm6nG0sPUCyC3MBqHHroZXDlkU-Vvi0QTJQaaMryGJA,4398 +_pytest/warnings.py,sha256=yJMDr7vSeij-nyTuldE7wL25ZL_LumQGY6PJZpXiQ-I,5194 +py.py,sha256=txZ1tdmEW6CBTp6Idn-I2sOzzA0xKNoCi9Re27Uj6HE,329 +pytest-9.0.3.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +pytest-9.0.3.dist-info/METADATA,sha256=w5ZvKHkWhkd7rjXlGHNtTL6ltibTp5ARIVhU4rxnAgc,7556 +pytest-9.0.3.dist-info/RECORD,, +pytest-9.0.3.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pytest-9.0.3.dist-info/WHEEL,sha256=aeYiig01lYGDzBgS8HxWXOg3uV61G9ijOsup-k9o1sk,91 +pytest-9.0.3.dist-info/direct_url.json,sha256=Dn_pekIBw4xlmjWsKJVdGzuvURg0BQVOS8BXIQImOyc,117 +pytest-9.0.3.dist-info/entry_points.txt,sha256=8IPrHPH3LNZQ7v5tNEOcNTZYk_SheNg64jsTM9erqL4,77 +pytest-9.0.3.dist-info/licenses/LICENSE,sha256=yoNqX57Mo7LzUCMPqiCkj7ixRWU7VWjXhIYt-GRwa5s,1091 +pytest-9.0.3.dist-info/top_level.txt,sha256=yyhjvmXH7-JOaoQIdmNQHPuoBCxOyXS3jIths_6C8A4,18 +pytest/__init__.py,sha256=e-eh4iGNxZoZ0a0THkq-IRcqKVCH78comJOCSHguh2Y,5582 +pytest/__main__.py,sha256=oVDrGGo7N0TNyzXntUblcgTKbhHGWtivcX5TC7tEcKo,154 +pytest/__pycache__/__init__.cpython-310.pyc,, +pytest/__pycache__/__main__.cpython-310.pyc,, +pytest/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/REQUESTED b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/REQUESTED new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/WHEEL b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/WHEEL new file mode 100644 index 0000000000000000000000000000000000000000..14a883f292bc96b20c2b76a3081991f2676523a9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/WHEEL @@ -0,0 +1,5 @@ +Wheel-Version: 1.0 +Generator: setuptools (82.0.1) +Root-Is-Purelib: true +Tag: py3-none-any + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/direct_url.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/direct_url.json new file mode 100644 index 0000000000000000000000000000000000000000..a9e1704004cfbcfe3093fd6dcf9e689c7b64f947 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/direct_url.json @@ -0,0 +1 @@ +{"dir_info": {}, "url": "file:///home/conda/feedstock_root/build_artifacts/bld/rattler-build_pytest_1775644472/work"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/entry_points.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/entry_points.txt new file mode 100644 index 0000000000000000000000000000000000000000..192205dfa5fda066e479ba073379747ae0abbba5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/entry_points.txt @@ -0,0 +1,3 @@ +[console_scripts] +py.test = pytest:console_main +pytest = pytest:console_main diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..c3f1657fce94589bd1ec7cead810639047f3d359 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/licenses/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2004 Holger Krekel and others + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/top_level.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/top_level.txt new file mode 100644 index 0000000000000000000000000000000000000000..3084ae51ecc94b5979ae9075ebb0e08fbda8bdbd --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest-9.0.3.dist-info/top_level.txt @@ -0,0 +1,3 @@ +_pytest +py +pytest diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..3e6281ac38841a8f9bac1f4ab7cd236cc5df26a3 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest/__init__.py @@ -0,0 +1,186 @@ +# PYTHON_ARGCOMPLETE_OK +"""pytest: unit and functional testing with Python.""" + +from __future__ import annotations + +from _pytest import __version__ +from _pytest import version_tuple +from _pytest._code import ExceptionInfo +from _pytest.assertion import register_assert_rewrite +from _pytest.cacheprovider import Cache +from _pytest.capture import CaptureFixture +from _pytest.config import cmdline +from _pytest.config import Config +from _pytest.config import console_main +from _pytest.config import ExitCode +from _pytest.config import hookimpl +from _pytest.config import hookspec +from _pytest.config import main +from _pytest.config import PytestPluginManager +from _pytest.config import UsageError +from _pytest.config.argparsing import OptionGroup +from _pytest.config.argparsing import Parser +from _pytest.debugging import pytestPDB as __pytestPDB +from _pytest.doctest import DoctestItem +from _pytest.fixtures import fixture +from _pytest.fixtures import FixtureDef +from _pytest.fixtures import FixtureLookupError +from _pytest.fixtures import FixtureRequest +from _pytest.fixtures import yield_fixture +from _pytest.freeze_support import freeze_includes +from _pytest.legacypath import TempdirFactory +from _pytest.legacypath import Testdir +from _pytest.logging import LogCaptureFixture +from _pytest.main import Dir +from _pytest.main import Session +from _pytest.mark import HIDDEN_PARAM +from _pytest.mark import Mark +from _pytest.mark import MARK_GEN as mark +from _pytest.mark import MarkDecorator +from _pytest.mark import MarkGenerator +from _pytest.mark import param +from _pytest.monkeypatch import MonkeyPatch +from _pytest.nodes import Collector +from _pytest.nodes import Directory +from _pytest.nodes import File +from _pytest.nodes import Item +from _pytest.outcomes import exit +from _pytest.outcomes import fail +from _pytest.outcomes import importorskip +from _pytest.outcomes import skip +from _pytest.outcomes import xfail +from _pytest.pytester import HookRecorder +from _pytest.pytester import LineMatcher +from _pytest.pytester import Pytester +from _pytest.pytester import RecordedHookCall +from _pytest.pytester import RunResult +from _pytest.python import Class +from _pytest.python import Function +from _pytest.python import Metafunc +from _pytest.python import Module +from _pytest.python import Package +from _pytest.python_api import approx +from _pytest.raises import raises +from _pytest.raises import RaisesExc +from _pytest.raises import RaisesGroup +from _pytest.recwarn import deprecated_call +from _pytest.recwarn import WarningsRecorder +from _pytest.recwarn import warns +from _pytest.reports import CollectReport +from _pytest.reports import TestReport +from _pytest.runner import CallInfo +from _pytest.stash import Stash +from _pytest.stash import StashKey +from _pytest.subtests import SubtestReport +from _pytest.subtests import Subtests +from _pytest.terminal import TerminalReporter +from _pytest.terminal import TestShortLogReport +from _pytest.tmpdir import TempPathFactory +from _pytest.warning_types import PytestAssertRewriteWarning +from _pytest.warning_types import PytestCacheWarning +from _pytest.warning_types import PytestCollectionWarning +from _pytest.warning_types import PytestConfigWarning +from _pytest.warning_types import PytestDeprecationWarning +from _pytest.warning_types import PytestExperimentalApiWarning +from _pytest.warning_types import PytestFDWarning +from _pytest.warning_types import PytestRemovedIn9Warning +from _pytest.warning_types import PytestRemovedIn10Warning +from _pytest.warning_types import PytestReturnNotNoneWarning +from _pytest.warning_types import PytestUnhandledThreadExceptionWarning +from _pytest.warning_types import PytestUnknownMarkWarning +from _pytest.warning_types import PytestUnraisableExceptionWarning +from _pytest.warning_types import PytestWarning + + +set_trace = __pytestPDB.set_trace + + +__all__ = [ + "HIDDEN_PARAM", + "Cache", + "CallInfo", + "CaptureFixture", + "Class", + "CollectReport", + "Collector", + "Config", + "Dir", + "Directory", + "DoctestItem", + "ExceptionInfo", + "ExitCode", + "File", + "FixtureDef", + "FixtureLookupError", + "FixtureRequest", + "Function", + "HookRecorder", + "Item", + "LineMatcher", + "LogCaptureFixture", + "Mark", + "MarkDecorator", + "MarkGenerator", + "Metafunc", + "Module", + "MonkeyPatch", + "OptionGroup", + "Package", + "Parser", + "PytestAssertRewriteWarning", + "PytestCacheWarning", + "PytestCollectionWarning", + "PytestConfigWarning", + "PytestDeprecationWarning", + "PytestExperimentalApiWarning", + "PytestFDWarning", + "PytestPluginManager", + "PytestRemovedIn9Warning", + "PytestRemovedIn10Warning", + "PytestReturnNotNoneWarning", + "PytestUnhandledThreadExceptionWarning", + "PytestUnknownMarkWarning", + "PytestUnraisableExceptionWarning", + "PytestWarning", + "Pytester", + "RaisesExc", + "RaisesGroup", + "RecordedHookCall", + "RunResult", + "Session", + "Stash", + "StashKey", + "SubtestReport", + "Subtests", + "TempPathFactory", + "TempdirFactory", + "TerminalReporter", + "TestReport", + "TestShortLogReport", + "Testdir", + "UsageError", + "WarningsRecorder", + "__version__", + "approx", + "cmdline", + "console_main", + "deprecated_call", + "exit", + "fail", + "fixture", + "freeze_includes", + "hookimpl", + "hookspec", + "importorskip", + "main", + "mark", + "param", + "raises", + "register_assert_rewrite", + "set_trace", + "skip", + "version_tuple", + "warns", + "xfail", + "yield_fixture", +] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest/__main__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest/__main__.py new file mode 100644 index 0000000000000000000000000000000000000000..cccab5d57b86352e51cb59df8b023c42a9304d65 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest/__main__.py @@ -0,0 +1,9 @@ +"""The pytest entry point.""" + +from __future__ import annotations + +import pytest + + +if __name__ == "__main__": + raise SystemExit(pytest.console_main()) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest/py.typed b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytest-9.0.3-pyhc364b38_1/site-packages/pytest/py.typed new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/about.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/about.json new file mode 100644 index 0000000000000000000000000000000000000000..5a6700ca4cd6f3e856ca09637b2ef145db21354c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/about.json @@ -0,0 +1,16 @@ +{ + "channels": [ + "https://conda.anaconda.org/conda-forge/" + ], + "description": "The dateutil module provides powerful extensions to the standard datetime\nmodule, available in Python.", + "dev_url": "https://github.com/dateutil/dateutil/", + "doc_url": "https://dateutil.readthedocs.org/en/latest/", + "extra": { + "flow_run_id": "azure_20250628.1.1", + "remote_url": "https://github.com/conda-forge/python-dateutil-feedstock", + "sha": "335bbadf18bbf088eadbe18b4710df751e1aaef3" + }, + "home": "https://dateutil.readthedocs.org/", + "license": "Apache-2.0", + "summary": "Extensions to the standard Python datetime module." +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/hash_input.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/hash_input.json new file mode 100644 index 0000000000000000000000000000000000000000..9b13afb5494add5f6c3f8ce5a992b015842fdaba --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/hash_input.json @@ -0,0 +1 @@ +{"channel_sources": "conda-forge", "channel_targets": "conda-forge main", "python_min": "3.9", "target_platform": "noarch"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/index.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/index.json new file mode 100644 index 0000000000000000000000000000000000000000..2c45fb7917ecbd020139ad8bc724f3924923d1a4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/index.json @@ -0,0 +1,15 @@ +{ + "build": "pyhe01879c_2", + "build_number": 2, + "depends": [ + "python >=3.9", + "six >=1.5", + "python" + ], + "license": "Apache-2.0", + "name": "python-dateutil", + "noarch": "python", + "subdir": "noarch", + "timestamp": 1751104122689, + "version": "2.9.0.post0" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..1e65815cf0b3132689485874a93034ede7206bf4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/licenses/LICENSE @@ -0,0 +1,54 @@ +Copyright 2017- Paul Ganssle <paul@ganssle.io> +Copyright 2017- dateutil contributors (see AUTHORS file) + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +The above license applies to all contributions after 2017-12-01, as well as +all contributions that have been re-licensed (see AUTHORS file for the list of +contributors who have re-licensed their code). +-------------------------------------------------------------------------------- +dateutil - Extensions to the standard Python datetime module. + +Copyright (c) 2003-2011 - Gustavo Niemeyer <gustavo@niemeyer.net> +Copyright (c) 2012-2014 - Tomi Pieviläinen <tomi.pievilainen@iki.fi> +Copyright (c) 2014-2016 - Yaron de Leeuw <me@jarondl.net> +Copyright (c) 2015- - Paul Ganssle <paul@ganssle.io> +Copyright (c) 2015- - dateutil contributors (see AUTHORS file) + +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + * Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + * Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR +CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, +EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +The above BSD License Applies to all code, even that also covered by Apache 2.0. \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/link.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/link.json new file mode 100644 index 0000000000000000000000000000000000000000..ec6589c68a1bf1aedb3f856ab584e80f5302f2cb --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/link.json @@ -0,0 +1,6 @@ +{ + "noarch": { + "type": "python" + }, + "package_metadata_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/paths.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/paths.json new file mode 100644 index 0000000000000000000000000000000000000000..d9c2e7a05d894a4bf3a82c7c484a0f64204eb3eb --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/paths.json @@ -0,0 +1,173 @@ +{ + "paths": [ + { + "_path": "site-packages/dateutil/__init__.py", + "path_type": "hardlink", + "sha256": "32a6a6ebb58ef4891399417223aeaf4ba2284974e9f46dfcf0369d1f62c230b6", + "size_in_bytes": 620 + }, + { + "_path": "site-packages/dateutil/_common.py", + "path_type": "hardlink", + "sha256": "efbc34cb2b64af19586d29fefa50d53d431a6d45d147d237941bffbd0454a946", + "size_in_bytes": 932 + }, + { + "_path": "site-packages/dateutil/_version.py", + "path_type": "hardlink", + "sha256": "d9ca0d40dfbee3a56d284dd265ee23f9130c3dcbe94c31e02ed7af047498cf26", + "size_in_bytes": 526 + }, + { + "_path": "site-packages/dateutil/easter.py", + "path_type": "hardlink", + "sha256": "772062fa52af8a61f5bbf93aa7b6742492bbd9086a56d541b2a072be910f2af7", + "size_in_bytes": 2678 + }, + { + "_path": "site-packages/dateutil/parser/__init__.py", + "path_type": "hardlink", + "sha256": "c1693a185bb14e98e8820086b6091c789a2d8b8a558e5e3f7c7417a4d39a4988", + "size_in_bytes": 1766 + }, + { + "_path": "site-packages/dateutil/parser/_parser.py", + "path_type": "hardlink", + "sha256": "ee494377289c92c401fd7825fb7500981c33098a2bd40219aa4948713e9d1fff", + "size_in_bytes": 58796 + }, + { + "_path": "site-packages/dateutil/parser/isoparser.py", + "path_type": "hardlink", + "sha256": "f05cbdf7d6e709dd5fad274e62e3ab6967c94ed7795bba90e7537036e1ff8573", + "size_in_bytes": 13233 + }, + { + "_path": "site-packages/dateutil/relativedelta.py", + "path_type": "hardlink", + "sha256": "218fe6825323a196d87ebbe5a1363671ed366a25633c892265faa03536517ee0", + "size_in_bytes": 24903 + }, + { + "_path": "site-packages/dateutil/rrule.py", + "path_type": "hardlink", + "sha256": "289cca95a09dd6311bbb8037f1996db256a801487d9d26dd6ce15d8e9ef429ec", + "size_in_bytes": 66557 + }, + { + "_path": "site-packages/dateutil/tz/__init__.py", + "path_type": "hardlink", + "sha256": "17e333d77bfa8d8b1e92541ff537bd27a9f370b0e6ab8ee03916bad4adf9fc50", + "size_in_bytes": 444 + }, + { + "_path": "site-packages/dateutil/tz/_common.py", + "path_type": "hardlink", + "sha256": "720cc34c036c397bc473ce9c605efb12c962b9269bf0fbb0a6c979f9b5f7fd2e", + "size_in_bytes": 12977 + }, + { + "_path": "site-packages/dateutil/tz/_factories.py", + "path_type": "hardlink", + "sha256": "ba76fa5d0357acf32f7a4b13094f8083c8e6559b384a88e83d47001e95a7aef5", + "size_in_bytes": 2569 + }, + { + "_path": "site-packages/dateutil/tz/tz.py", + "path_type": "hardlink", + "sha256": "1149c474c7de4e15e263a978b21f7205a6d9eb7fcf3b3cb4d734ac87db619f5a", + "size_in_bytes": 62855 + }, + { + "_path": "site-packages/dateutil/tz/win.py", + "path_type": "hardlink", + "sha256": "c49b335a04b0135c4fc7f1c98f86647a9cae902fe1372d35e9631c5e16d1681f", + "size_in_bytes": 12935 + }, + { + "_path": "site-packages/dateutil/tzwin.py", + "path_type": "hardlink", + "sha256": "ec0af8bdd4029e733498a4773148db20ab19ac155f1e0770b0965cfe619845ec", + "size_in_bytes": 59 + }, + { + "_path": "site-packages/dateutil/utils.py", + "path_type": "hardlink", + "sha256": "74a09c844c3c78e6e2d25a064f1f75ba70719bfed41a5537bff16314c76ac183", + "size_in_bytes": 1965 + }, + { + "_path": "site-packages/dateutil/zoneinfo/__init__.py", + "path_type": "hardlink", + "sha256": "298834a6d842323729e4c5d21220499f79cc8d978d65abfbae5270e7eb73d52e", + "size_in_bytes": 5889 + }, + { + "_path": "site-packages/dateutil/zoneinfo/dateutil-zoneinfo.tar.gz", + "path_type": "hardlink", + "sha256": "d3ea52e7b6e968de0d884df1288193596fa95b803db4f92a18279a7398004475", + "size_in_bytes": 156400 + }, + { + "_path": "site-packages/dateutil/zoneinfo/rebuild.py", + "path_type": "hardlink", + "sha256": "322a98cc2207bcd6cc1fe2dd4582effb84f410803b8432ade462d1d084532dd2", + "size_in_bytes": 2392 + }, + { + "_path": "site-packages/python_dateutil-2.9.0.post0.dist-info/INSTALLER", + "path_type": "hardlink", + "sha256": "bc33022edcb7639ff53355b4e91dade50a0bbf0299efeb6171d1ec0ba5029cfc", + "size_in_bytes": 6 + }, + { + "_path": "site-packages/python_dateutil-2.9.0.post0.dist-info/METADATA", + "path_type": "hardlink", + "sha256": "a461c53a71beba01525f93b8d839e132364fc52d635eb265ab4a9b61565f2b5c", + "size_in_bytes": 8396 + }, + { + "_path": "site-packages/python_dateutil-2.9.0.post0.dist-info/RECORD", + "path_type": "hardlink", + "sha256": "8a903cd079b940f28280bd0fd69c3d3b3c7b1f02dd3b089290ca0d5b93cbaeb9", + "size_in_bytes": 3328 + }, + { + "_path": "site-packages/python_dateutil-2.9.0.post0.dist-info/REQUESTED", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/python_dateutil-2.9.0.post0.dist-info/WHEEL", + "path_type": "hardlink", + "sha256": "24d5a1d459b551dc08415d3be609429f8315b8246cd2ca2d248abe27aadbc425", + "size_in_bytes": 109 + }, + { + "_path": "site-packages/python_dateutil-2.9.0.post0.dist-info/direct_url.json", + "path_type": "hardlink", + "sha256": "720e23d6bad238152bc4b57e3e9114cdc881d9cc3716f76863b38d429c503579", + "size_in_bytes": 126 + }, + { + "_path": "site-packages/python_dateutil-2.9.0.post0.dist-info/licenses/LICENSE", + "path_type": "hardlink", + "sha256": "ba00f51a0d92823b5a1cde27d8b5b9d2321e67ed8da9bc163eff96d5e17e577e", + "size_in_bytes": 2889 + }, + { + "_path": "site-packages/python_dateutil-2.9.0.post0.dist-info/top_level.txt", + "path_type": "hardlink", + "sha256": "e2d8dd5a485166f17b2c0fc161efcbf60076c3fa766becf9cba02b8da464a2df", + "size_in_bytes": 9 + }, + { + "_path": "site-packages/python_dateutil-2.9.0.post0.dist-info/zip-safe", + "path_type": "hardlink", + "sha256": "01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b", + "size_in_bytes": 1 + } + ], + "paths_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/recipe/recipe-scripts-license.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/recipe/recipe-scripts-license.txt new file mode 100644 index 0000000000000000000000000000000000000000..2ec51d75f362bc4327a3cfe1c515c16bb3c57367 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/recipe/recipe-scripts-license.txt @@ -0,0 +1,27 @@ +BSD-3-Clause license +Copyright (c) 2015-2022, conda-forge contributors +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + 3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/recipe/recipe.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/recipe/recipe.yaml new file mode 100644 index 0000000000000000000000000000000000000000..5ed0ec49af511ad991712562d5cae7fc6632ae4a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/recipe/recipe.yaml @@ -0,0 +1,62 @@ +# yaml-language-server: $schema=https://raw.githubusercontent.com/prefix-dev/recipe-format/main/schema.json +schema_version: 1 + +context: + version: 2.9.0.post0 + +package: + name: python-dateutil + version: ${{ version }} + +source: + url: https://pypi.org/packages/source/p/python-dateutil/python-dateutil-${{ version }}.tar.gz + sha256: 37dd54208da7e1cd875388217d5e00ebd4179249f90fb72437e91a35459a0ad3 + +build: + number: 2 + noarch: python + script: + - ${{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation --disable-pip-version-check + +requirements: + host: + - pip + - python ${{ python_min }}.* + - setuptools + - setuptools-scm + run: + - python >=${{ python_min }} + - six >=1.5 + +tests: + - python: + imports: + - dateutil + - dateutil.parser + pip_check: true + python_version: + - ${{ python_min }}.* + - 3.13.* + - requirements: + run: + - python ${{ python_min }}.* + script: + file: run_test.py + +about: + license: Apache-2.0 + license_file: LICENSE + summary: Extensions to the standard Python datetime module. + description: | + The dateutil module provides powerful extensions to the standard datetime + module, available in Python. + homepage: https://dateutil.readthedocs.org/ + repository: https://github.com/dateutil/dateutil/ + documentation: https://dateutil.readthedocs.org/en/latest/ + +extra: + recipe-maintainers: + - pganssle + - msarahan + - ocefpaf + - thewchan diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/recipe/rendered_recipe.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/recipe/rendered_recipe.yaml new file mode 100644 index 0000000000000000000000000000000000000000..e8658cb58642c61239cb18cb0c4168ab1dd3c84e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/recipe/rendered_recipe.yaml @@ -0,0 +1,742 @@ +recipe: + schema_version: 1 + context: + version: 2.9.0.post0 + package: + name: python-dateutil + version: 2.9.0.post0 + source: + - url: https://pypi.org/packages/source/p/python-dateutil/python-dateutil-2.9.0.post0.tar.gz + sha256: 37dd54208da7e1cd875388217d5e00ebd4179249f90fb72437e91a35459a0ad3 + build: + number: 2 + string: pyhe01879c_2 + script: ${{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation --disable-pip-version-check + noarch: python + requirements: + host: + - pip + - python 3.9.* + - setuptools + - setuptools-scm + run: + - python >=3.9 + - six >=1.5 + tests: + - python: + imports: + - dateutil + - dateutil.parser + python_version: + - 3.9.* + - 3.13.* + - script: + interpreter: python + file: run_test.py + requirements: + run: + - python 3.9.* + about: + homepage: https://dateutil.readthedocs.org/ + repository: https://github.com/dateutil/dateutil/ + documentation: https://dateutil.readthedocs.org/en/latest/ + license: Apache-2.0 + license_file: + - LICENSE + summary: Extensions to the standard Python datetime module. + description: |- + The dateutil module provides powerful extensions to the standard datetime + module, available in Python. + extra: + recipe-maintainers: + - pganssle + - msarahan + - ocefpaf + - thewchan +build_configuration: + target_platform: noarch + host_platform: + platform: linux-64 + virtual_packages: + - __unix=0=0 + - __linux=6.11.0=0 + - __glibc=2.34=0 + - __archspec=1=zen2 + build_platform: + platform: linux-64 + virtual_packages: + - __unix=0=0 + - __linux=6.11.0=0 + - __glibc=2.34=0 + - __archspec=1=zen2 + variant: + channel_sources: conda-forge + channel_targets: conda-forge main + python_min: '3.9' + target_platform: noarch + hash: + hash: e01879c + prefix: py + directories: + host_prefix: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_python-dateutil_1751104122/host_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehol + build_prefix: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_python-dateutil_1751104122/build_env + work_dir: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_python-dateutil_1751104122/work + build_dir: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_python-dateutil_1751104122 + channels: + - https://conda.anaconda.org/conda-forge + channel_priority: strict + solve_strategy: highest + timestamp: 2025-06-28T09:48:42.689060878Z + subpackages: + python-dateutil: + name: python-dateutil + version: 2.9.0.post0 + build_string: pyhe01879c_2 + packaging_settings: + archive_type: conda + compression_level: 15 +finalized_dependencies: + build: null + host: + specs: + - source: pip + - source: python 3.9.* + - source: setuptools + - source: setuptools-scm + resolved: + - build: pyh8b19718_0 + build_number: 0 + depends: + - python >=3.9,<3.13.0a0 + - setuptools + - wheel + license: MIT + license_family: MIT + md5: 32d0781ace05105cc99af55d36cbec7c + name: pip + noarch: python + sha256: ebfa591d39092b111b9ebb3210eb42251be6da89e26c823ee03e5e838655a43e + size: 1242995 + subdir: noarch + timestamp: 1746249983238 + version: 25.1.1 + fn: pip-25.1.1-pyh8b19718_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/pip-25.1.1-pyh8b19718_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hc30ae73_0_cpython + build_number: 0 + constrains: + - python_abi 3.9.* *_cp39 + depends: + - __glibc >=2.17,<3.0.a0 + - bzip2 >=1.0.8,<2.0a0 + - ld_impl_linux-64 >=2.36.1 + - libexpat >=2.7.0,<3.0a0 + - libffi >=3.4,<4.0a0 + - libgcc >=13 + - liblzma >=5.8.1,<6.0a0 + - libnsl >=2.0.1,<2.1.0a0 + - libsqlite >=3.50.0,<4.0a0 + - libuuid >=2.38.1,<3.0a0 + - libxcrypt >=4.4.36 + - libzlib >=1.3.1,<2.0a0 + - ncurses >=6.5,<7.0a0 + - openssl >=3.5.0,<4.0a0 + - readline >=8.2,<9.0a0 + - tk >=8.6.13,<8.7.0a0 + - tzdata + license: Python-2.0 + md5: 624ab0484356d86a54297919352d52b6 + name: python + run_exports: + weak: + - python_abi 3.9.* *_cp39 + noarch: + - python + sha256: dcfc417424b21ffca70dddf7a86ef69270b3e8d2040c748b7356a615470d5298 + size: 23677900 + subdir: linux-64 + timestamp: 1749060753022 + version: 3.9.23 + fn: python-3.9.23-hc30ae73_0_cpython.conda + url: https://conda.anaconda.org/conda-forge/linux-64/python-3.9.23-hc30ae73_0_cpython.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h0b41bf4_0 + build_number: 0 + depends: + - libgcc-ng >=12 + license: BSD-3-Clause + license_family: BSD + md5: 40b61aab5c7ba9ff276c41cfffe6b80b + name: libuuid + run_exports: + weak: + - libuuid >=2.38.1,<3.0a0 + sha256: 787eb542f055a2b3de553614b25f09eefb0a0931b0c87dbcce6efdfd92f04f18 + size: 33601 + subdir: linux-64 + timestamp: 1680112270483 + version: 2.38.1 + fn: libuuid-2.38.1-h0b41bf4_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libuuid-2.38.1-h0b41bf4_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h5888daf_0 + build_number: 0 + constrains: + - expat 2.7.0.* + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: MIT + license_family: MIT + md5: db0bfbe7dd197b68ad5f30333bae6ce0 + name: libexpat + sha256: 33ab03438aee65d6aa667cf7d90c91e5e7d734c19a67aa4c7040742c0a13d505 + size: 74427 + subdir: linux-64 + timestamp: 1743431794976 + version: 2.7.0 + fn: libexpat-2.7.0-h5888daf_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libexpat-2.7.0-h5888daf_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhff2d567_0 + build_number: 0 + depends: + - python >=3.9 + license: MIT + license_family: MIT + md5: 4de79c071274a53dcaf2a8c749d1499e + name: setuptools + noarch: python + sha256: 972560fcf9657058e3e1f97186cc94389144b46dbdf58c807ce62e83f977e863 + size: 748788 + subdir: noarch + timestamp: 1748804951958 + version: 80.9.0 + fn: setuptools-80.9.0-pyhff2d567_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/setuptools-80.9.0-pyhff2d567_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_0 + build_number: 0 + depends: + - importlib-metadata + - packaging >=20.0 + - python >=3.9 + - setuptools >=45 + - tomli >=1.0.0 + - typing-extensions + license: MIT + license_family: MIT + md5: 996376098e3648237b3efb0e0ad460c1 + name: setuptools-scm + noarch: python + sha256: f2c94e01f7998aab77edd996afc63482556b1d935e23fc14361889ee89424d16 + size: 38426 + subdir: noarch + timestamp: 1745450953205 + version: 8.3.1 + fn: setuptools-scm-8.3.1-pyhd8ed1ab_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/setuptools-scm-8.3.1-pyhd8ed1ab_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_1 + build_number: 1 + depends: + - python >=3.9 + license: MIT + license_family: MIT + md5: 75cb7132eb58d97896e173ef12ac9986 + name: wheel + noarch: python + sha256: 1b34021e815ff89a4d902d879c3bd2040bc1bd6169b32e9427497fa05c55f1ce + size: 62931 + subdir: noarch + timestamp: 1733130309598 + version: 0.45.1 + fn: wheel-0.45.1-pyhd8ed1ab_1.conda + url: https://conda.anaconda.org/conda-forge/noarch/wheel-0.45.1-pyhd8ed1ab_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h4bc722e_7 + build_number: 7 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc-ng >=12 + license: bzip2-1.0.6 + license_family: BSD + md5: 62ee74e96c5ebb0af99386de58cf9553 + name: bzip2 + run_exports: + weak: + - bzip2 >=1.0.8,<2.0a0 + sha256: 5ced96500d945fb286c9c838e54fa759aa04a7129c59800f0846b4335cee770d + size: 252783 + subdir: linux-64 + timestamp: 1720974456583 + version: 1.0.8 + fn: bzip2-1.0.8-h4bc722e_7.conda + url: https://conda.anaconda.org/conda-forge/linux-64/bzip2-1.0.8-h4bc722e_7.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h1423503_5 + build_number: 5 + constrains: + - binutils_impl_linux-64 2.43 + depends: + - __glibc >=2.17,<3.0.a0 + license: GPL-3.0-only + license_family: GPL + md5: 6dc9e1305e7d3129af4ad0dabda30e56 + name: ld_impl_linux-64 + sha256: dcd2b1a065bbf5c54004ddf6551c775a8eb6993c8298ca8a6b92041ed413f785 + size: 670635 + subdir: linux-64 + timestamp: 1749858327854 + version: '2.43' + fn: ld_impl_linux-64-2.43-h1423503_5.conda + url: https://conda.anaconda.org/conda-forge/linux-64/ld_impl_linux-64-2.43-h1423503_5.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h2dba641_1 + build_number: 1 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: MIT + license_family: MIT + md5: ede4673863426c0883c0063d853bbd85 + name: libffi + run_exports: + weak: + - libffi >=3.4.6,<3.5.0a0 + sha256: 764432d32db45466e87f10621db5b74363a9f847d2b8b1f9743746cd160f06ab + size: 57433 + subdir: linux-64 + timestamp: 1743434498161 + version: 3.4.6 + fn: libffi-3.4.6-h2dba641_1.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libffi-3.4.6-h2dba641_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h767d61c_3 + build_number: 3 + constrains: + - libgcc-ng ==15.1.0=*_3 + - libgomp 15.1.0 h767d61c_3 + depends: + - __glibc >=2.17,<3.0.a0 + - _openmp_mutex >=4.5 + license: GPL-3.0-only WITH GCC-exception-3.1 + md5: 9e60c55e725c20d23125a5f0dd69af5d + name: libgcc + sha256: 59a87161212abe8acc57d318b0cc8636eb834cdfdfddcf1f588b5493644b39a3 + size: 824921 + subdir: linux-64 + timestamp: 1750808216066 + version: 15.1.0 + fn: libgcc-15.1.0-h767d61c_3.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgcc-15.1.0-h767d61c_3.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h69a702a_3 + build_number: 3 + depends: + - libgcc 15.1.0 h767d61c_3 + license: GPL-3.0-only WITH GCC-exception-3.1 + md5: e66f2b8ad787e7beb0f846e4bd7e8493 + name: libgcc-ng + run_exports: + strong: + - libgcc + sha256: b0b0a5ee6ce645a09578fc1cb70c180723346f8a45fdb6d23b3520591c6d6996 + size: 29033 + subdir: linux-64 + timestamp: 1750808224854 + version: 15.1.0 + fn: libgcc-ng-15.1.0-h69a702a_3.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgcc-ng-15.1.0-h69a702a_3.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb9d3cd8_2 + build_number: 2 + constrains: + - xz 5.8.1.* + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: 0BSD + md5: 1a580f7796c7bf6393fddb8bbbde58dc + name: liblzma + run_exports: + weak: + - liblzma >=5.8.1,<6.0a0 + sha256: f2591c0069447bbe28d4d696b7fcb0c5bd0b4ac582769b89addbcf26fb3430d8 + size: 112894 + subdir: linux-64 + timestamp: 1749230047870 + version: 5.8.1 + fn: liblzma-5.8.1-hb9d3cd8_2.conda + url: https://conda.anaconda.org/conda-forge/linux-64/liblzma-5.8.1-hb9d3cd8_2.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb9d3cd8_1 + build_number: 1 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: LGPL-2.1-only + license_family: GPL + md5: d864d34357c3b65a4b731f78c0801dc4 + name: libnsl + run_exports: + weak: + - libnsl >=2.0.1,<2.1.0a0 + sha256: 927fe72b054277cde6cb82597d0fcf6baf127dcbce2e0a9d8925a68f1265eef5 + size: 33731 + subdir: linux-64 + timestamp: 1750274110928 + version: 2.0.1 + fn: libnsl-2.0.1-hb9d3cd8_1.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libnsl-2.0.1-hb9d3cd8_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h6cd9bfd_7 + build_number: 7 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + - libzlib >=1.3.1,<2.0a0 + license: Unlicense + md5: c7c4888059a8324e52de475d1e7bdc53 + name: libsqlite + run_exports: + weak: + - libsqlite >=3.50.1,<4.0a0 + sha256: 9a9e5bf30178f821d4f8de25eac0ae848915bfde6a78a66ae8b77d9c33d9d0e5 + size: 919723 + subdir: linux-64 + timestamp: 1750925531920 + version: 3.50.1 + fn: libsqlite-3.50.1-h6cd9bfd_7.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libsqlite-3.50.1-h6cd9bfd_7.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hd590300_1 + build_number: 1 + depends: + - libgcc-ng >=12 + license: LGPL-2.1-or-later + md5: 5aa797f8787fe7a17d1b0821485b5adc + name: libxcrypt + run_exports: + weak: + - libxcrypt >=4.4.36 + sha256: 6ae68e0b86423ef188196fff6207ed0c8195dd84273cb5623b85aa08033a410c + size: 100393 + subdir: linux-64 + timestamp: 1702724383534 + version: 4.4.36 + fn: libxcrypt-4.4.36-hd590300_1.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libxcrypt-4.4.36-hd590300_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb9d3cd8_2 + build_number: 2 + constrains: + - zlib 1.3.1 *_2 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: Zlib + license_family: Other + md5: edb0dca6bc32e4f4789199455a1dbeb8 + name: libzlib + run_exports: + weak: + - libzlib >=1.3.1,<2.0a0 + sha256: d4bfe88d7cb447768e31650f06257995601f89076080e76df55e3112d4e47dc4 + size: 60963 + subdir: linux-64 + timestamp: 1727963148474 + version: 1.3.1 + fn: libzlib-1.3.1-hb9d3cd8_2.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libzlib-1.3.1-hb9d3cd8_2.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h2d0b736_3 + build_number: 3 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: X11 AND BSD-3-Clause + md5: 47e340acb35de30501a76c7c799c41d7 + name: ncurses + run_exports: + weak: + - ncurses >=6.5,<7.0a0 + sha256: 3fde293232fa3fca98635e1167de6b7c7fda83caf24b9d6c91ec9eefb4f4d586 + size: 891641 + subdir: linux-64 + timestamp: 1738195959188 + version: '6.5' + fn: ncurses-6.5-h2d0b736_3.conda + url: https://conda.anaconda.org/conda-forge/linux-64/ncurses-6.5-h2d0b736_3.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h7b32b05_1 + build_number: 1 + depends: + - __glibc >=2.17,<3.0.a0 + - ca-certificates + - libgcc >=13 + license: Apache-2.0 + license_family: Apache + md5: de356753cfdbffcde5bb1e86e3aa6cd0 + name: openssl + run_exports: + weak: + - openssl >=3.5.0,<4.0a0 + sha256: b4491077c494dbf0b5eaa6d87738c22f2154e9277e5293175ec187634bd808a0 + size: 3117410 + subdir: linux-64 + timestamp: 1746223723843 + version: 3.5.0 + fn: openssl-3.5.0-h7b32b05_1.conda + url: https://conda.anaconda.org/conda-forge/linux-64/openssl-3.5.0-h7b32b05_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h8c095d6_2 + build_number: 2 + depends: + - libgcc >=13 + - ncurses >=6.5,<7.0a0 + license: GPL-3.0-only + license_family: GPL + md5: 283b96675859b20a825f8fa30f311446 + name: readline + run_exports: + weak: + - readline >=8.2,<9.0a0 + sha256: 2d6d0c026902561ed77cd646b5021aef2d4db22e57a5b0178dfc669231e06d2c + size: 282480 + subdir: linux-64 + timestamp: 1740379431762 + version: '8.2' + fn: readline-8.2-h8c095d6_2.conda + url: https://conda.anaconda.org/conda-forge/linux-64/readline-8.2-h8c095d6_2.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: noxft_hd72426e_102 + build_number: 102 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + - libzlib >=1.3.1,<2.0a0 + license: TCL + license_family: BSD + md5: a0116df4f4ed05c303811a837d5b39d8 + name: tk + run_exports: + weak: + - tk >=8.6.13,<8.7.0a0 + sha256: a84ff687119e6d8752346d1d408d5cf360dee0badd487a472aa8ddedfdc219e1 + size: 3285204 + subdir: linux-64 + timestamp: 1748387766691 + version: 8.6.13 + fn: tk-8.6.13-noxft_hd72426e_102.conda + url: https://conda.anaconda.org/conda-forge/linux-64/tk-8.6.13-noxft_hd72426e_102.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h78e105d_0 + build_number: 0 + depends: [] + license: LicenseRef-Public-Domain + md5: 4222072737ccff51314b5ece9c7d6f5a + name: tzdata + noarch: generic + sha256: 5aaa366385d716557e365f0a4e9c3fca43ba196872abbbe3d56bb610d131e192 + size: 122968 + subdir: noarch + timestamp: 1742727099393 + version: 2025b + fn: tzdata-2025b-h78e105d_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/tzdata-2025b-h78e105d_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhe01879c_1 + build_number: 1 + depends: + - python >=3.9 + - zipp >=3.20 + - python + license: Apache-2.0 + license_family: APACHE + md5: 63ccfdc3a3ce25b027b8767eb722fca8 + name: importlib-metadata + noarch: python + sha256: c18ab120a0613ada4391b15981d86ff777b5690ca461ea7e9e49531e8f374745 + size: 34641 + subdir: noarch + timestamp: 1747934053147 + version: 8.7.0 + fn: importlib-metadata-8.7.0-pyhe01879c_1.conda + url: https://conda.anaconda.org/conda-forge/noarch/importlib-metadata-8.7.0-pyhe01879c_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyh29332c3_1 + build_number: 1 + depends: + - python >=3.8 + - python + license: Apache-2.0 + license_family: APACHE + md5: 58335b26c38bf4a20f399384c33cbcf9 + name: packaging + noarch: python + sha256: 289861ed0c13a15d7bbb408796af4de72c2fe67e2bcb0de98f4c3fce259d7991 + size: 62477 + subdir: noarch + timestamp: 1745345660407 + version: '25.0' + fn: packaging-25.0-pyh29332c3_1.conda + url: https://conda.anaconda.org/conda-forge/noarch/packaging-25.0-pyh29332c3_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_1 + build_number: 1 + depends: + - python >=3.9 + license: MIT + license_family: MIT + md5: ac944244f1fed2eb49bae07193ae8215 + name: tomli + noarch: python + sha256: 18636339a79656962723077df9a56c0ac7b8a864329eb8f847ee3d38495b863e + size: 19167 + subdir: noarch + timestamp: 1733256819729 + version: 2.2.1 + fn: tomli-2.2.1-pyhd8ed1ab_1.conda + url: https://conda.anaconda.org/conda-forge/noarch/tomli-2.2.1-pyhd8ed1ab_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h32cad80_0 + build_number: 0 + depends: + - typing_extensions ==4.14.0 pyhe01879c_0 + license: PSF-2.0 + license_family: PSF + md5: a1cdd40fc962e2f7944bc19e01c7e584 + name: typing-extensions + noarch: generic + sha256: b8cabfa54432b0f124c0af6b6facdf8110892914fa841ac2e80ab65ac52c1ba4 + size: 90310 + subdir: noarch + timestamp: 1748959427551 + version: 4.14.0 + fn: typing-extensions-4.14.0-h32cad80_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/typing-extensions-4.14.0-h32cad80_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhe01879c_0 + build_number: 0 + depends: + - python >=3.9 + - python + license: PSF-2.0 + license_family: PSF + md5: 2adcd9bb86f656d3d43bf84af59a1faf + name: typing_extensions + noarch: python + sha256: 8561db52f278c5716b436da6d4ee5521712a49e8f3c70fcae5350f5ebb4be41c + size: 50978 + subdir: noarch + timestamp: 1748959427551 + version: 4.14.0 + fn: typing_extensions-4.14.0-pyhe01879c_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/typing_extensions-4.14.0-pyhe01879c_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: 2_gnu + build_number: 16 + constrains: + - openmp_impl 9999 + depends: + - _libgcc_mutex 0.1 conda_forge + - libgomp >=7.5.0 + license: BSD-3-Clause + license_family: BSD + md5: 73aaf86a425cc6e73fcf236a5a46396d + name: _openmp_mutex + run_exports: + strong: + - _openmp_mutex >=4.5 + sha256: fbe2c5e56a653bebb982eda4876a9178aedfc2b545f25d0ce9c4c0b508253d22 + size: 23621 + subdir: linux-64 + timestamp: 1650670423406 + version: '4.5' + fn: _openmp_mutex-4.5-2_gnu.tar.bz2 + url: https://conda.anaconda.org/conda-forge/linux-64/_openmp_mutex-4.5-2_gnu.tar.bz2 + channel: https://conda.anaconda.org/conda-forge/ + - build: h767d61c_3 + build_number: 3 + depends: + - __glibc >=2.17,<3.0.a0 + license: GPL-3.0-only WITH GCC-exception-3.1 + md5: 3cd1a7238a0dd3d0860fdefc496cc854 + name: libgomp + run_exports: + strong: + - _openmp_mutex >=4.5 + sha256: 43710ab4de0cd7ff8467abff8d11e7bb0e36569df04ce1c099d48601818f11d1 + size: 447068 + subdir: linux-64 + timestamp: 1750808138400 + version: 15.1.0 + fn: libgomp-15.1.0-h767d61c_3.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgomp-15.1.0-h767d61c_3.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: conda_forge + build_number: 0 + depends: [] + license: None + md5: d7c89558ba9fa0495403155b64376d81 + name: _libgcc_mutex + sha256: fe51de6107f9edc7aa4f786a70f4a883943bc9d39b3bb7307c04c41410990726 + size: 2562 + subdir: linux-64 + timestamp: 1578324546067 + version: '0.1' + fn: _libgcc_mutex-0.1-conda_forge.tar.bz2 + url: https://conda.anaconda.org/conda-forge/linux-64/_libgcc_mutex-0.1-conda_forge.tar.bz2 + channel: https://conda.anaconda.org/conda-forge/ + - build: hbd8a1cb_0 + build_number: 0 + depends: + - __unix + license: ISC + md5: 72525f07d72806e3b639ad4504c30ce5 + name: ca-certificates + noarch: generic + sha256: 7cfec9804c84844ea544d98bda1d9121672b66ff7149141b8415ca42dfcd44f6 + size: 151069 + subdir: noarch + timestamp: 1749990087500 + version: 2025.6.15 + fn: ca-certificates-2025.6.15-hbd8a1cb_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/ca-certificates-2025.6.15-hbd8a1cb_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_0 + build_number: 0 + depends: + - python >=3.9 + license: MIT + license_family: MIT + md5: df5e78d904988eb55042c0c97446079f + name: zipp + noarch: python + sha256: 7560d21e1b021fd40b65bfb72f67945a3fcb83d78ad7ccf37b8b3165ec3b68ad + size: 22963 + subdir: noarch + timestamp: 1749421737203 + version: 3.23.0 + fn: zipp-3.23.0-pyhd8ed1ab_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/zipp-3.23.0-pyhd8ed1ab_0.conda + channel: https://conda.anaconda.org/conda-forge/ + run: + depends: + - source: python >=3.9 + - source: six >=1.5 + - spec: python + from: host + run_export: python + constraints: [] +finalized_sources: +- url: https://pypi.org/packages/source/p/python-dateutil/python-dateutil-2.9.0.post0.tar.gz + sha256: 37dd54208da7e1cd875388217d5e00ebd4179249f90fb72437e91a35459a0ad3 +system_tools: + rattler-build: 0.44.0 +extra_meta: + flow_run_id: azure_20250628.1.1 + remote_url: https://github.com/conda-forge/python-dateutil-feedstock + sha: 335bbadf18bbf088eadbe18b4710df751e1aaef3 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/recipe/run_test.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/recipe/run_test.py new file mode 100644 index 0000000000000000000000000000000000000000..27efc2856d46354b41449d87f2631cf2cc54defb --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/recipe/run_test.py @@ -0,0 +1,20 @@ +from dateutil.relativedelta import relativedelta +from dateutil.easter import easter +from dateutil.rrule import rrule, YEARLY, FR +from dateutil.parser import parse + +now = parse("Sat Oct 11 17:13:46 UTC 2003") +today = now.date() +print("Today is: %s" % today) +assert str(today) == '2003-10-11' + +year = rrule(YEARLY, dtstart=now, bymonth=8, + bymonthday=13, byweekday=FR)[0].year +rdelta = relativedelta(easter(year), today) + +print("Year with next Aug 13th on a Friday is: %s" % year) +assert str(year) == '2004' +print("How far is the Easter of that year: %s" % rdelta) +assert str(rdelta) == 'relativedelta(months=+6)' +print("And the Easter of that year is: %s" % (today+rdelta)) +assert str(today+rdelta) == '2004-04-11' diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/recipe/variant_config.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/recipe/variant_config.yaml new file mode 100644 index 0000000000000000000000000000000000000000..1863a2111ff040c4d7ffcba04fd18a869cb65644 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/recipe/variant_config.yaml @@ -0,0 +1,4 @@ +channel_sources: conda-forge +channel_targets: conda-forge main +python_min: '3.9' +target_platform: noarch diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/repodata_record.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/repodata_record.json new file mode 100644 index 0000000000000000000000000000000000000000..32ededbed459de20be79e91e0ed692a889f22994 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/repodata_record.json @@ -0,0 +1,23 @@ +{ + "build": "pyhe01879c_2", + "build_number": 2, + "build_string": "pyhe01879c_2", + "channel": "conda-forge", + "constrains": [], + "depends": [ + "python >=3.9", + "six >=1.5", + "python" + ], + "fn": "python-dateutil-2.9.0.post0-pyhe01879c_2.conda", + "license": "Apache-2.0", + "md5": "5b8d21249ff20967101ffa321cab24e8", + "name": "python-dateutil", + "noarch": "python", + "sha256": "d6a17ece93bbd5139e02d2bd7dbfa80bee1a4261dced63f65f679121686bf664", + "size": 233310, + "subdir": "noarch", + "timestamp": 1751104122, + "url": "https://conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2.conda", + "version": "2.9.0.post0" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/tests/tests.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/tests/tests.yaml new file mode 100644 index 0000000000000000000000000000000000000000..641a835a3a296ddb950560de70b6519006228004 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/info/tests/tests.yaml @@ -0,0 +1,33 @@ +- python: + imports: + - dateutil + - dateutil.parser + python_version: + - 3.9.* + - 3.13.* +- script: + interpreter: python + content: | + from dateutil.relativedelta import relativedelta + from dateutil.easter import easter + from dateutil.rrule import rrule, YEARLY, FR + from dateutil.parser import parse + + now = parse("Sat Oct 11 17:13:46 UTC 2003") + today = now.date() + print("Today is: %s" % today) + assert str(today) == '2003-10-11' + + year = rrule(YEARLY, dtstart=now, bymonth=8, + bymonthday=13, byweekday=FR)[0].year + rdelta = relativedelta(easter(year), today) + + print("Year with next Aug 13th on a Friday is: %s" % year) + assert str(year) == '2004' + print("How far is the Easter of that year: %s" % rdelta) + assert str(rdelta) == 'relativedelta(months=+6)' + print("And the Easter of that year is: %s" % (today+rdelta)) + assert str(today+rdelta) == '2004-04-11' + requirements: + run: + - python 3.9.* diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..a2c19c06fe14476a9bfa4f1f60de7a997a41191c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/__init__.py @@ -0,0 +1,24 @@ +# -*- coding: utf-8 -*- +import sys + +try: + from ._version import version as __version__ +except ImportError: + __version__ = 'unknown' + +__all__ = ['easter', 'parser', 'relativedelta', 'rrule', 'tz', + 'utils', 'zoneinfo'] + +def __getattr__(name): + import importlib + + if name in __all__: + return importlib.import_module("." + name, __name__) + raise AttributeError( + "module {!r} has not attribute {!r}".format(__name__, name) + ) + + +def __dir__(): + # __dir__ should include all the lazy-importable modules as well. + return [x for x in globals() if x not in sys.modules] + __all__ diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/_common.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/_common.py new file mode 100644 index 0000000000000000000000000000000000000000..4eb2659bd2986125fcfb4afea5bae9efc2dcd1a0 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/_common.py @@ -0,0 +1,43 @@ +""" +Common code used in multiple modules. +""" + + +class weekday(object): + __slots__ = ["weekday", "n"] + + def __init__(self, weekday, n=None): + self.weekday = weekday + self.n = n + + def __call__(self, n): + if n == self.n: + return self + else: + return self.__class__(self.weekday, n) + + def __eq__(self, other): + try: + if self.weekday != other.weekday or self.n != other.n: + return False + except AttributeError: + return False + return True + + def __hash__(self): + return hash(( + self.weekday, + self.n, + )) + + def __ne__(self, other): + return not (self == other) + + def __repr__(self): + s = ("MO", "TU", "WE", "TH", "FR", "SA", "SU")[self.weekday] + if not self.n: + return s + else: + return "%s(%+d)" % (s, self.n) + +# vim:ts=4:sw=4:et diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/_version.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/_version.py new file mode 100644 index 0000000000000000000000000000000000000000..dbbceb70beb24714aecd6e6abd098bd36e8e40f2 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/_version.py @@ -0,0 +1,21 @@ +# file generated by setuptools-scm +# don't change, don't track in version control + +__all__ = ["__version__", "__version_tuple__", "version", "version_tuple"] + +TYPE_CHECKING = False +if TYPE_CHECKING: + from typing import Tuple + from typing import Union + + VERSION_TUPLE = Tuple[Union[int, str], ...] +else: + VERSION_TUPLE = object + +version: str +__version__: str +__version_tuple__: VERSION_TUPLE +version_tuple: VERSION_TUPLE + +__version__ = version = '2.9.0.post0' +__version_tuple__ = version_tuple = (2, 9, 0, 'post0') diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/easter.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/easter.py new file mode 100644 index 0000000000000000000000000000000000000000..f74d1f7442473997245ac683b8a269a3574d1ba4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/easter.py @@ -0,0 +1,89 @@ +# -*- coding: utf-8 -*- +""" +This module offers a generic Easter computing method for any given year, using +Western, Orthodox or Julian algorithms. +""" + +import datetime + +__all__ = ["easter", "EASTER_JULIAN", "EASTER_ORTHODOX", "EASTER_WESTERN"] + +EASTER_JULIAN = 1 +EASTER_ORTHODOX = 2 +EASTER_WESTERN = 3 + + +def easter(year, method=EASTER_WESTERN): + """ + This method was ported from the work done by GM Arts, + on top of the algorithm by Claus Tondering, which was + based in part on the algorithm of Ouding (1940), as + quoted in "Explanatory Supplement to the Astronomical + Almanac", P. Kenneth Seidelmann, editor. + + This algorithm implements three different Easter + calculation methods: + + 1. Original calculation in Julian calendar, valid in + dates after 326 AD + 2. Original method, with date converted to Gregorian + calendar, valid in years 1583 to 4099 + 3. Revised method, in Gregorian calendar, valid in + years 1583 to 4099 as well + + These methods are represented by the constants: + + * ``EASTER_JULIAN = 1`` + * ``EASTER_ORTHODOX = 2`` + * ``EASTER_WESTERN = 3`` + + The default method is method 3. + + More about the algorithm may be found at: + + `GM Arts: Easter Algorithms <http://www.gmarts.org/index.php?go=415>`_ + + and + + `The Calendar FAQ: Easter <https://www.tondering.dk/claus/cal/easter.php>`_ + + """ + + if not (1 <= method <= 3): + raise ValueError("invalid method") + + # g - Golden year - 1 + # c - Century + # h - (23 - Epact) mod 30 + # i - Number of days from March 21 to Paschal Full Moon + # j - Weekday for PFM (0=Sunday, etc) + # p - Number of days from March 21 to Sunday on or before PFM + # (-6 to 28 methods 1 & 3, to 56 for method 2) + # e - Extra days to add for method 2 (converting Julian + # date to Gregorian date) + + y = year + g = y % 19 + e = 0 + if method < 3: + # Old method + i = (19*g + 15) % 30 + j = (y + y//4 + i) % 7 + if method == 2: + # Extra dates to convert Julian to Gregorian date + e = 10 + if y > 1600: + e = e + y//100 - 16 - (y//100 - 16)//4 + else: + # New method + c = y//100 + h = (c - c//4 - (8*c + 13)//25 + 19*g + 15) % 30 + i = h - (h//28)*(1 - (h//28)*(29//(h + 1))*((21 - g)//11)) + j = (y + y//4 + i + 2 - c + c//4) % 7 + + # p can be from -6 to 56 corresponding to dates 22 March to 23 May + # (later dates apply to method 2, although 23 May never actually occurs) + p = i - j + e + d = 1 + (p + 27 + (p + 6)//40) % 31 + m = 3 + (p + 26)//30 + return datetime.date(int(y), int(m), int(d)) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/parser/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/parser/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..d174b0e4dcc472999b75e55ebb88af320ae38081 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/parser/__init__.py @@ -0,0 +1,61 @@ +# -*- coding: utf-8 -*- +from ._parser import parse, parser, parserinfo, ParserError +from ._parser import DEFAULTPARSER, DEFAULTTZPARSER +from ._parser import UnknownTimezoneWarning + +from ._parser import __doc__ + +from .isoparser import isoparser, isoparse + +__all__ = ['parse', 'parser', 'parserinfo', + 'isoparse', 'isoparser', + 'ParserError', + 'UnknownTimezoneWarning'] + + +### +# Deprecate portions of the private interface so that downstream code that +# is improperly relying on it is given *some* notice. + + +def __deprecated_private_func(f): + from functools import wraps + import warnings + + msg = ('{name} is a private function and may break without warning, ' + 'it will be moved and or renamed in future versions.') + msg = msg.format(name=f.__name__) + + @wraps(f) + def deprecated_func(*args, **kwargs): + warnings.warn(msg, DeprecationWarning) + return f(*args, **kwargs) + + return deprecated_func + +def __deprecate_private_class(c): + import warnings + + msg = ('{name} is a private class and may break without warning, ' + 'it will be moved and or renamed in future versions.') + msg = msg.format(name=c.__name__) + + class private_class(c): + __doc__ = c.__doc__ + + def __init__(self, *args, **kwargs): + warnings.warn(msg, DeprecationWarning) + super(private_class, self).__init__(*args, **kwargs) + + private_class.__name__ = c.__name__ + + return private_class + + +from ._parser import _timelex, _resultbase +from ._parser import _tzparser, _parsetz + +_timelex = __deprecate_private_class(_timelex) +_tzparser = __deprecate_private_class(_tzparser) +_resultbase = __deprecate_private_class(_resultbase) +_parsetz = __deprecated_private_func(_parsetz) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/parser/_parser.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/parser/_parser.py new file mode 100644 index 0000000000000000000000000000000000000000..37d1663b2f72447800d9a553929e3de932244289 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/parser/_parser.py @@ -0,0 +1,1613 @@ +# -*- coding: utf-8 -*- +""" +This module offers a generic date/time string parser which is able to parse +most known formats to represent a date and/or time. + +This module attempts to be forgiving with regards to unlikely input formats, +returning a datetime object even for dates which are ambiguous. If an element +of a date/time stamp is omitted, the following rules are applied: + +- If AM or PM is left unspecified, a 24-hour clock is assumed, however, an hour + on a 12-hour clock (``0 <= hour <= 12``) *must* be specified if AM or PM is + specified. +- If a time zone is omitted, a timezone-naive datetime is returned. + +If any other elements are missing, they are taken from the +:class:`datetime.datetime` object passed to the parameter ``default``. If this +results in a day number exceeding the valid number of days per month, the +value falls back to the end of the month. + +Additional resources about date/time string formats can be found below: + +- `A summary of the international standard date and time notation + <https://www.cl.cam.ac.uk/~mgk25/iso-time.html>`_ +- `W3C Date and Time Formats <https://www.w3.org/TR/NOTE-datetime>`_ +- `Time Formats (Planetary Rings Node) <https://pds-rings.seti.org:443/tools/time_formats.html>`_ +- `CPAN ParseDate module + <https://metacpan.org/pod/release/MUIR/Time-modules-2013.0912/lib/Time/ParseDate.pm>`_ +- `Java SimpleDateFormat Class + <https://docs.oracle.com/javase/6/docs/api/java/text/SimpleDateFormat.html>`_ +""" +from __future__ import unicode_literals + +import datetime +import re +import string +import time +import warnings + +from calendar import monthrange +from io import StringIO + +import six +from six import integer_types, text_type + +from decimal import Decimal + +from warnings import warn + +from .. import relativedelta +from .. import tz + +__all__ = ["parse", "parserinfo", "ParserError"] + + +# TODO: pandas.core.tools.datetimes imports this explicitly. Might be worth +# making public and/or figuring out if there is something we can +# take off their plate. +class _timelex(object): + # Fractional seconds are sometimes split by a comma + _split_decimal = re.compile("([.,])") + + def __init__(self, instream): + if isinstance(instream, (bytes, bytearray)): + instream = instream.decode() + + if isinstance(instream, text_type): + instream = StringIO(instream) + elif getattr(instream, 'read', None) is None: + raise TypeError('Parser must be a string or character stream, not ' + '{itype}'.format(itype=instream.__class__.__name__)) + + self.instream = instream + self.charstack = [] + self.tokenstack = [] + self.eof = False + + def get_token(self): + """ + This function breaks the time string into lexical units (tokens), which + can be parsed by the parser. Lexical units are demarcated by changes in + the character set, so any continuous string of letters is considered + one unit, any continuous string of numbers is considered one unit. + + The main complication arises from the fact that dots ('.') can be used + both as separators (e.g. "Sep.20.2009") or decimal points (e.g. + "4:30:21.447"). As such, it is necessary to read the full context of + any dot-separated strings before breaking it into tokens; as such, this + function maintains a "token stack", for when the ambiguous context + demands that multiple tokens be parsed at once. + """ + if self.tokenstack: + return self.tokenstack.pop(0) + + seenletters = False + token = None + state = None + + while not self.eof: + # We only realize that we've reached the end of a token when we + # find a character that's not part of the current token - since + # that character may be part of the next token, it's stored in the + # charstack. + if self.charstack: + nextchar = self.charstack.pop(0) + else: + nextchar = self.instream.read(1) + while nextchar == '\x00': + nextchar = self.instream.read(1) + + if not nextchar: + self.eof = True + break + elif not state: + # First character of the token - determines if we're starting + # to parse a word, a number or something else. + token = nextchar + if self.isword(nextchar): + state = 'a' + elif self.isnum(nextchar): + state = '0' + elif self.isspace(nextchar): + token = ' ' + break # emit token + else: + break # emit token + elif state == 'a': + # If we've already started reading a word, we keep reading + # letters until we find something that's not part of a word. + seenletters = True + if self.isword(nextchar): + token += nextchar + elif nextchar == '.': + token += nextchar + state = 'a.' + else: + self.charstack.append(nextchar) + break # emit token + elif state == '0': + # If we've already started reading a number, we keep reading + # numbers until we find something that doesn't fit. + if self.isnum(nextchar): + token += nextchar + elif nextchar == '.' or (nextchar == ',' and len(token) >= 2): + token += nextchar + state = '0.' + else: + self.charstack.append(nextchar) + break # emit token + elif state == 'a.': + # If we've seen some letters and a dot separator, continue + # parsing, and the tokens will be broken up later. + seenletters = True + if nextchar == '.' or self.isword(nextchar): + token += nextchar + elif self.isnum(nextchar) and token[-1] == '.': + token += nextchar + state = '0.' + else: + self.charstack.append(nextchar) + break # emit token + elif state == '0.': + # If we've seen at least one dot separator, keep going, we'll + # break up the tokens later. + if nextchar == '.' or self.isnum(nextchar): + token += nextchar + elif self.isword(nextchar) and token[-1] == '.': + token += nextchar + state = 'a.' + else: + self.charstack.append(nextchar) + break # emit token + + if (state in ('a.', '0.') and (seenletters or token.count('.') > 1 or + token[-1] in '.,')): + l = self._split_decimal.split(token) + token = l[0] + for tok in l[1:]: + if tok: + self.tokenstack.append(tok) + + if state == '0.' and token.count('.') == 0: + token = token.replace(',', '.') + + return token + + def __iter__(self): + return self + + def __next__(self): + token = self.get_token() + if token is None: + raise StopIteration + + return token + + def next(self): + return self.__next__() # Python 2.x support + + @classmethod + def split(cls, s): + return list(cls(s)) + + @classmethod + def isword(cls, nextchar): + """ Whether or not the next character is part of a word """ + return nextchar.isalpha() + + @classmethod + def isnum(cls, nextchar): + """ Whether the next character is part of a number """ + return nextchar.isdigit() + + @classmethod + def isspace(cls, nextchar): + """ Whether the next character is whitespace """ + return nextchar.isspace() + + +class _resultbase(object): + + def __init__(self): + for attr in self.__slots__: + setattr(self, attr, None) + + def _repr(self, classname): + l = [] + for attr in self.__slots__: + value = getattr(self, attr) + if value is not None: + l.append("%s=%s" % (attr, repr(value))) + return "%s(%s)" % (classname, ", ".join(l)) + + def __len__(self): + return (sum(getattr(self, attr) is not None + for attr in self.__slots__)) + + def __repr__(self): + return self._repr(self.__class__.__name__) + + +class parserinfo(object): + """ + Class which handles what inputs are accepted. Subclass this to customize + the language and acceptable values for each parameter. + + :param dayfirst: + Whether to interpret the first value in an ambiguous 3-integer date + (e.g. 01/05/09) as the day (``True``) or month (``False``). If + ``yearfirst`` is set to ``True``, this distinguishes between YDM + and YMD. Default is ``False``. + + :param yearfirst: + Whether to interpret the first value in an ambiguous 3-integer date + (e.g. 01/05/09) as the year. If ``True``, the first number is taken + to be the year, otherwise the last number is taken to be the year. + Default is ``False``. + """ + + # m from a.m/p.m, t from ISO T separator + JUMP = [" ", ".", ",", ";", "-", "/", "'", + "at", "on", "and", "ad", "m", "t", "of", + "st", "nd", "rd", "th"] + + WEEKDAYS = [("Mon", "Monday"), + ("Tue", "Tuesday"), # TODO: "Tues" + ("Wed", "Wednesday"), + ("Thu", "Thursday"), # TODO: "Thurs" + ("Fri", "Friday"), + ("Sat", "Saturday"), + ("Sun", "Sunday")] + MONTHS = [("Jan", "January"), + ("Feb", "February"), # TODO: "Febr" + ("Mar", "March"), + ("Apr", "April"), + ("May", "May"), + ("Jun", "June"), + ("Jul", "July"), + ("Aug", "August"), + ("Sep", "Sept", "September"), + ("Oct", "October"), + ("Nov", "November"), + ("Dec", "December")] + HMS = [("h", "hour", "hours"), + ("m", "minute", "minutes"), + ("s", "second", "seconds")] + AMPM = [("am", "a"), + ("pm", "p")] + UTCZONE = ["UTC", "GMT", "Z", "z"] + PERTAIN = ["of"] + TZOFFSET = {} + # TODO: ERA = ["AD", "BC", "CE", "BCE", "Stardate", + # "Anno Domini", "Year of Our Lord"] + + def __init__(self, dayfirst=False, yearfirst=False): + self._jump = self._convert(self.JUMP) + self._weekdays = self._convert(self.WEEKDAYS) + self._months = self._convert(self.MONTHS) + self._hms = self._convert(self.HMS) + self._ampm = self._convert(self.AMPM) + self._utczone = self._convert(self.UTCZONE) + self._pertain = self._convert(self.PERTAIN) + + self.dayfirst = dayfirst + self.yearfirst = yearfirst + + self._year = time.localtime().tm_year + self._century = self._year // 100 * 100 + + def _convert(self, lst): + dct = {} + for i, v in enumerate(lst): + if isinstance(v, tuple): + for v in v: + dct[v.lower()] = i + else: + dct[v.lower()] = i + return dct + + def jump(self, name): + return name.lower() in self._jump + + def weekday(self, name): + try: + return self._weekdays[name.lower()] + except KeyError: + pass + return None + + def month(self, name): + try: + return self._months[name.lower()] + 1 + except KeyError: + pass + return None + + def hms(self, name): + try: + return self._hms[name.lower()] + except KeyError: + return None + + def ampm(self, name): + try: + return self._ampm[name.lower()] + except KeyError: + return None + + def pertain(self, name): + return name.lower() in self._pertain + + def utczone(self, name): + return name.lower() in self._utczone + + def tzoffset(self, name): + if name in self._utczone: + return 0 + + return self.TZOFFSET.get(name) + + def convertyear(self, year, century_specified=False): + """ + Converts two-digit years to year within [-50, 49] + range of self._year (current local time) + """ + + # Function contract is that the year is always positive + assert year >= 0 + + if year < 100 and not century_specified: + # assume current century to start + year += self._century + + if year >= self._year + 50: # if too far in future + year -= 100 + elif year < self._year - 50: # if too far in past + year += 100 + + return year + + def validate(self, res): + # move to info + if res.year is not None: + res.year = self.convertyear(res.year, res.century_specified) + + if ((res.tzoffset == 0 and not res.tzname) or + (res.tzname == 'Z' or res.tzname == 'z')): + res.tzname = "UTC" + res.tzoffset = 0 + elif res.tzoffset != 0 and res.tzname and self.utczone(res.tzname): + res.tzoffset = 0 + return True + + +class _ymd(list): + def __init__(self, *args, **kwargs): + super(self.__class__, self).__init__(*args, **kwargs) + self.century_specified = False + self.dstridx = None + self.mstridx = None + self.ystridx = None + + @property + def has_year(self): + return self.ystridx is not None + + @property + def has_month(self): + return self.mstridx is not None + + @property + def has_day(self): + return self.dstridx is not None + + def could_be_day(self, value): + if self.has_day: + return False + elif not self.has_month: + return 1 <= value <= 31 + elif not self.has_year: + # Be permissive, assume leap year + month = self[self.mstridx] + return 1 <= value <= monthrange(2000, month)[1] + else: + month = self[self.mstridx] + year = self[self.ystridx] + return 1 <= value <= monthrange(year, month)[1] + + def append(self, val, label=None): + if hasattr(val, '__len__'): + if val.isdigit() and len(val) > 2: + self.century_specified = True + if label not in [None, 'Y']: # pragma: no cover + raise ValueError(label) + label = 'Y' + elif val > 100: + self.century_specified = True + if label not in [None, 'Y']: # pragma: no cover + raise ValueError(label) + label = 'Y' + + super(self.__class__, self).append(int(val)) + + if label == 'M': + if self.has_month: + raise ValueError('Month is already set') + self.mstridx = len(self) - 1 + elif label == 'D': + if self.has_day: + raise ValueError('Day is already set') + self.dstridx = len(self) - 1 + elif label == 'Y': + if self.has_year: + raise ValueError('Year is already set') + self.ystridx = len(self) - 1 + + def _resolve_from_stridxs(self, strids): + """ + Try to resolve the identities of year/month/day elements using + ystridx, mstridx, and dstridx, if enough of these are specified. + """ + if len(self) == 3 and len(strids) == 2: + # we can back out the remaining stridx value + missing = [x for x in range(3) if x not in strids.values()] + key = [x for x in ['y', 'm', 'd'] if x not in strids] + assert len(missing) == len(key) == 1 + key = key[0] + val = missing[0] + strids[key] = val + + assert len(self) == len(strids) # otherwise this should not be called + out = {key: self[strids[key]] for key in strids} + return (out.get('y'), out.get('m'), out.get('d')) + + def resolve_ymd(self, yearfirst, dayfirst): + len_ymd = len(self) + year, month, day = (None, None, None) + + strids = (('y', self.ystridx), + ('m', self.mstridx), + ('d', self.dstridx)) + + strids = {key: val for key, val in strids if val is not None} + if (len(self) == len(strids) > 0 or + (len(self) == 3 and len(strids) == 2)): + return self._resolve_from_stridxs(strids) + + mstridx = self.mstridx + + if len_ymd > 3: + raise ValueError("More than three YMD values") + elif len_ymd == 1 or (mstridx is not None and len_ymd == 2): + # One member, or two members with a month string + if mstridx is not None: + month = self[mstridx] + # since mstridx is 0 or 1, self[mstridx-1] always + # looks up the other element + other = self[mstridx - 1] + else: + other = self[0] + + if len_ymd > 1 or mstridx is None: + if other > 31: + year = other + else: + day = other + + elif len_ymd == 2: + # Two members with numbers + if self[0] > 31: + # 99-01 + year, month = self + elif self[1] > 31: + # 01-99 + month, year = self + elif dayfirst and self[1] <= 12: + # 13-01 + day, month = self + else: + # 01-13 + month, day = self + + elif len_ymd == 3: + # Three members + if mstridx == 0: + if self[1] > 31: + # Apr-2003-25 + month, year, day = self + else: + month, day, year = self + elif mstridx == 1: + if self[0] > 31 or (yearfirst and self[2] <= 31): + # 99-Jan-01 + year, month, day = self + else: + # 01-Jan-01 + # Give precedence to day-first, since + # two-digit years is usually hand-written. + day, month, year = self + + elif mstridx == 2: + # WTF!? + if self[1] > 31: + # 01-99-Jan + day, year, month = self + else: + # 99-01-Jan + year, day, month = self + + else: + if (self[0] > 31 or + self.ystridx == 0 or + (yearfirst and self[1] <= 12 and self[2] <= 31)): + # 99-01-01 + if dayfirst and self[2] <= 12: + year, day, month = self + else: + year, month, day = self + elif self[0] > 12 or (dayfirst and self[1] <= 12): + # 13-01-01 + day, month, year = self + else: + # 01-13-01 + month, day, year = self + + return year, month, day + + +class parser(object): + def __init__(self, info=None): + self.info = info or parserinfo() + + def parse(self, timestr, default=None, + ignoretz=False, tzinfos=None, **kwargs): + """ + Parse the date/time string into a :class:`datetime.datetime` object. + + :param timestr: + Any date/time string using the supported formats. + + :param default: + The default datetime object, if this is a datetime object and not + ``None``, elements specified in ``timestr`` replace elements in the + default object. + + :param ignoretz: + If set ``True``, time zones in parsed strings are ignored and a + naive :class:`datetime.datetime` object is returned. + + :param tzinfos: + Additional time zone names / aliases which may be present in the + string. This argument maps time zone names (and optionally offsets + from those time zones) to time zones. This parameter can be a + dictionary with timezone aliases mapping time zone names to time + zones or a function taking two parameters (``tzname`` and + ``tzoffset``) and returning a time zone. + + The timezones to which the names are mapped can be an integer + offset from UTC in seconds or a :class:`tzinfo` object. + + .. doctest:: + :options: +NORMALIZE_WHITESPACE + + >>> from dateutil.parser import parse + >>> from dateutil.tz import gettz + >>> tzinfos = {"BRST": -7200, "CST": gettz("America/Chicago")} + >>> parse("2012-01-19 17:21:00 BRST", tzinfos=tzinfos) + datetime.datetime(2012, 1, 19, 17, 21, tzinfo=tzoffset(u'BRST', -7200)) + >>> parse("2012-01-19 17:21:00 CST", tzinfos=tzinfos) + datetime.datetime(2012, 1, 19, 17, 21, + tzinfo=tzfile('/usr/share/zoneinfo/America/Chicago')) + + This parameter is ignored if ``ignoretz`` is set. + + :param \\*\\*kwargs: + Keyword arguments as passed to ``_parse()``. + + :return: + Returns a :class:`datetime.datetime` object or, if the + ``fuzzy_with_tokens`` option is ``True``, returns a tuple, the + first element being a :class:`datetime.datetime` object, the second + a tuple containing the fuzzy tokens. + + :raises ParserError: + Raised for invalid or unknown string format, if the provided + :class:`tzinfo` is not in a valid format, or if an invalid date + would be created. + + :raises TypeError: + Raised for non-string or character stream input. + + :raises OverflowError: + Raised if the parsed date exceeds the largest valid C integer on + your system. + """ + + if default is None: + default = datetime.datetime.now().replace(hour=0, minute=0, + second=0, microsecond=0) + + res, skipped_tokens = self._parse(timestr, **kwargs) + + if res is None: + raise ParserError("Unknown string format: %s", timestr) + + if len(res) == 0: + raise ParserError("String does not contain a date: %s", timestr) + + try: + ret = self._build_naive(res, default) + except ValueError as e: + six.raise_from(ParserError(str(e) + ": %s", timestr), e) + + if not ignoretz: + ret = self._build_tzaware(ret, res, tzinfos) + + if kwargs.get('fuzzy_with_tokens', False): + return ret, skipped_tokens + else: + return ret + + class _result(_resultbase): + __slots__ = ["year", "month", "day", "weekday", + "hour", "minute", "second", "microsecond", + "tzname", "tzoffset", "ampm","any_unused_tokens"] + + def _parse(self, timestr, dayfirst=None, yearfirst=None, fuzzy=False, + fuzzy_with_tokens=False): + """ + Private method which performs the heavy lifting of parsing, called from + ``parse()``, which passes on its ``kwargs`` to this function. + + :param timestr: + The string to parse. + + :param dayfirst: + Whether to interpret the first value in an ambiguous 3-integer date + (e.g. 01/05/09) as the day (``True``) or month (``False``). If + ``yearfirst`` is set to ``True``, this distinguishes between YDM + and YMD. If set to ``None``, this value is retrieved from the + current :class:`parserinfo` object (which itself defaults to + ``False``). + + :param yearfirst: + Whether to interpret the first value in an ambiguous 3-integer date + (e.g. 01/05/09) as the year. If ``True``, the first number is taken + to be the year, otherwise the last number is taken to be the year. + If this is set to ``None``, the value is retrieved from the current + :class:`parserinfo` object (which itself defaults to ``False``). + + :param fuzzy: + Whether to allow fuzzy parsing, allowing for string like "Today is + January 1, 2047 at 8:21:00AM". + + :param fuzzy_with_tokens: + If ``True``, ``fuzzy`` is automatically set to True, and the parser + will return a tuple where the first element is the parsed + :class:`datetime.datetime` datetimestamp and the second element is + a tuple containing the portions of the string which were ignored: + + .. doctest:: + + >>> from dateutil.parser import parse + >>> parse("Today is January 1, 2047 at 8:21:00AM", fuzzy_with_tokens=True) + (datetime.datetime(2047, 1, 1, 8, 21), (u'Today is ', u' ', u'at ')) + + """ + if fuzzy_with_tokens: + fuzzy = True + + info = self.info + + if dayfirst is None: + dayfirst = info.dayfirst + + if yearfirst is None: + yearfirst = info.yearfirst + + res = self._result() + l = _timelex.split(timestr) # Splits the timestr into tokens + + skipped_idxs = [] + + # year/month/day list + ymd = _ymd() + + len_l = len(l) + i = 0 + try: + while i < len_l: + + # Check if it's a number + value_repr = l[i] + try: + value = float(value_repr) + except ValueError: + value = None + + if value is not None: + # Numeric token + i = self._parse_numeric_token(l, i, info, ymd, res, fuzzy) + + # Check weekday + elif info.weekday(l[i]) is not None: + value = info.weekday(l[i]) + res.weekday = value + + # Check month name + elif info.month(l[i]) is not None: + value = info.month(l[i]) + ymd.append(value, 'M') + + if i + 1 < len_l: + if l[i + 1] in ('-', '/'): + # Jan-01[-99] + sep = l[i + 1] + ymd.append(l[i + 2]) + + if i + 3 < len_l and l[i + 3] == sep: + # Jan-01-99 + ymd.append(l[i + 4]) + i += 2 + + i += 2 + + elif (i + 4 < len_l and l[i + 1] == l[i + 3] == ' ' and + info.pertain(l[i + 2])): + # Jan of 01 + # In this case, 01 is clearly year + if l[i + 4].isdigit(): + # Convert it here to become unambiguous + value = int(l[i + 4]) + year = str(info.convertyear(value)) + ymd.append(year, 'Y') + else: + # Wrong guess + pass + # TODO: not hit in tests + i += 4 + + # Check am/pm + elif info.ampm(l[i]) is not None: + value = info.ampm(l[i]) + val_is_ampm = self._ampm_valid(res.hour, res.ampm, fuzzy) + + if val_is_ampm: + res.hour = self._adjust_ampm(res.hour, value) + res.ampm = value + + elif fuzzy: + skipped_idxs.append(i) + + # Check for a timezone name + elif self._could_be_tzname(res.hour, res.tzname, res.tzoffset, l[i]): + res.tzname = l[i] + res.tzoffset = info.tzoffset(res.tzname) + + # Check for something like GMT+3, or BRST+3. Notice + # that it doesn't mean "I am 3 hours after GMT", but + # "my time +3 is GMT". If found, we reverse the + # logic so that timezone parsing code will get it + # right. + if i + 1 < len_l and l[i + 1] in ('+', '-'): + l[i + 1] = ('+', '-')[l[i + 1] == '+'] + res.tzoffset = None + if info.utczone(res.tzname): + # With something like GMT+3, the timezone + # is *not* GMT. + res.tzname = None + + # Check for a numbered timezone + elif res.hour is not None and l[i] in ('+', '-'): + signal = (-1, 1)[l[i] == '+'] + len_li = len(l[i + 1]) + + # TODO: check that l[i + 1] is integer? + if len_li == 4: + # -0300 + hour_offset = int(l[i + 1][:2]) + min_offset = int(l[i + 1][2:]) + elif i + 2 < len_l and l[i + 2] == ':': + # -03:00 + hour_offset = int(l[i + 1]) + min_offset = int(l[i + 3]) # TODO: Check that l[i+3] is minute-like? + i += 2 + elif len_li <= 2: + # -[0]3 + hour_offset = int(l[i + 1][:2]) + min_offset = 0 + else: + raise ValueError(timestr) + + res.tzoffset = signal * (hour_offset * 3600 + min_offset * 60) + + # Look for a timezone name between parenthesis + if (i + 5 < len_l and + info.jump(l[i + 2]) and l[i + 3] == '(' and + l[i + 5] == ')' and + 3 <= len(l[i + 4]) and + self._could_be_tzname(res.hour, res.tzname, + None, l[i + 4])): + # -0300 (BRST) + res.tzname = l[i + 4] + i += 4 + + i += 1 + + # Check jumps + elif not (info.jump(l[i]) or fuzzy): + raise ValueError(timestr) + + else: + skipped_idxs.append(i) + i += 1 + + # Process year/month/day + year, month, day = ymd.resolve_ymd(yearfirst, dayfirst) + + res.century_specified = ymd.century_specified + res.year = year + res.month = month + res.day = day + + except (IndexError, ValueError): + return None, None + + if not info.validate(res): + return None, None + + if fuzzy_with_tokens: + skipped_tokens = self._recombine_skipped(l, skipped_idxs) + return res, tuple(skipped_tokens) + else: + return res, None + + def _parse_numeric_token(self, tokens, idx, info, ymd, res, fuzzy): + # Token is a number + value_repr = tokens[idx] + try: + value = self._to_decimal(value_repr) + except Exception as e: + six.raise_from(ValueError('Unknown numeric token'), e) + + len_li = len(value_repr) + + len_l = len(tokens) + + if (len(ymd) == 3 and len_li in (2, 4) and + res.hour is None and + (idx + 1 >= len_l or + (tokens[idx + 1] != ':' and + info.hms(tokens[idx + 1]) is None))): + # 19990101T23[59] + s = tokens[idx] + res.hour = int(s[:2]) + + if len_li == 4: + res.minute = int(s[2:]) + + elif len_li == 6 or (len_li > 6 and tokens[idx].find('.') == 6): + # YYMMDD or HHMMSS[.ss] + s = tokens[idx] + + if not ymd and '.' not in tokens[idx]: + ymd.append(s[:2]) + ymd.append(s[2:4]) + ymd.append(s[4:]) + else: + # 19990101T235959[.59] + + # TODO: Check if res attributes already set. + res.hour = int(s[:2]) + res.minute = int(s[2:4]) + res.second, res.microsecond = self._parsems(s[4:]) + + elif len_li in (8, 12, 14): + # YYYYMMDD + s = tokens[idx] + ymd.append(s[:4], 'Y') + ymd.append(s[4:6]) + ymd.append(s[6:8]) + + if len_li > 8: + res.hour = int(s[8:10]) + res.minute = int(s[10:12]) + + if len_li > 12: + res.second = int(s[12:]) + + elif self._find_hms_idx(idx, tokens, info, allow_jump=True) is not None: + # HH[ ]h or MM[ ]m or SS[.ss][ ]s + hms_idx = self._find_hms_idx(idx, tokens, info, allow_jump=True) + (idx, hms) = self._parse_hms(idx, tokens, info, hms_idx) + if hms is not None: + # TODO: checking that hour/minute/second are not + # already set? + self._assign_hms(res, value_repr, hms) + + elif idx + 2 < len_l and tokens[idx + 1] == ':': + # HH:MM[:SS[.ss]] + res.hour = int(value) + value = self._to_decimal(tokens[idx + 2]) # TODO: try/except for this? + (res.minute, res.second) = self._parse_min_sec(value) + + if idx + 4 < len_l and tokens[idx + 3] == ':': + res.second, res.microsecond = self._parsems(tokens[idx + 4]) + + idx += 2 + + idx += 2 + + elif idx + 1 < len_l and tokens[idx + 1] in ('-', '/', '.'): + sep = tokens[idx + 1] + ymd.append(value_repr) + + if idx + 2 < len_l and not info.jump(tokens[idx + 2]): + if tokens[idx + 2].isdigit(): + # 01-01[-01] + ymd.append(tokens[idx + 2]) + else: + # 01-Jan[-01] + value = info.month(tokens[idx + 2]) + + if value is not None: + ymd.append(value, 'M') + else: + raise ValueError() + + if idx + 3 < len_l and tokens[idx + 3] == sep: + # We have three members + value = info.month(tokens[idx + 4]) + + if value is not None: + ymd.append(value, 'M') + else: + ymd.append(tokens[idx + 4]) + idx += 2 + + idx += 1 + idx += 1 + + elif idx + 1 >= len_l or info.jump(tokens[idx + 1]): + if idx + 2 < len_l and info.ampm(tokens[idx + 2]) is not None: + # 12 am + hour = int(value) + res.hour = self._adjust_ampm(hour, info.ampm(tokens[idx + 2])) + idx += 1 + else: + # Year, month or day + ymd.append(value) + idx += 1 + + elif info.ampm(tokens[idx + 1]) is not None and (0 <= value < 24): + # 12am + hour = int(value) + res.hour = self._adjust_ampm(hour, info.ampm(tokens[idx + 1])) + idx += 1 + + elif ymd.could_be_day(value): + ymd.append(value) + + elif not fuzzy: + raise ValueError() + + return idx + + def _find_hms_idx(self, idx, tokens, info, allow_jump): + len_l = len(tokens) + + if idx+1 < len_l and info.hms(tokens[idx+1]) is not None: + # There is an "h", "m", or "s" label following this token. We take + # assign the upcoming label to the current token. + # e.g. the "12" in 12h" + hms_idx = idx + 1 + + elif (allow_jump and idx+2 < len_l and tokens[idx+1] == ' ' and + info.hms(tokens[idx+2]) is not None): + # There is a space and then an "h", "m", or "s" label. + # e.g. the "12" in "12 h" + hms_idx = idx + 2 + + elif idx > 0 and info.hms(tokens[idx-1]) is not None: + # There is a "h", "m", or "s" preceding this token. Since neither + # of the previous cases was hit, there is no label following this + # token, so we use the previous label. + # e.g. the "04" in "12h04" + hms_idx = idx-1 + + elif (1 < idx == len_l-1 and tokens[idx-1] == ' ' and + info.hms(tokens[idx-2]) is not None): + # If we are looking at the final token, we allow for a + # backward-looking check to skip over a space. + # TODO: Are we sure this is the right condition here? + hms_idx = idx - 2 + + else: + hms_idx = None + + return hms_idx + + def _assign_hms(self, res, value_repr, hms): + # See GH issue #427, fixing float rounding + value = self._to_decimal(value_repr) + + if hms == 0: + # Hour + res.hour = int(value) + if value % 1: + res.minute = int(60*(value % 1)) + + elif hms == 1: + (res.minute, res.second) = self._parse_min_sec(value) + + elif hms == 2: + (res.second, res.microsecond) = self._parsems(value_repr) + + def _could_be_tzname(self, hour, tzname, tzoffset, token): + return (hour is not None and + tzname is None and + tzoffset is None and + len(token) <= 5 and + (all(x in string.ascii_uppercase for x in token) + or token in self.info.UTCZONE)) + + def _ampm_valid(self, hour, ampm, fuzzy): + """ + For fuzzy parsing, 'a' or 'am' (both valid English words) + may erroneously trigger the AM/PM flag. Deal with that + here. + """ + val_is_ampm = True + + # If there's already an AM/PM flag, this one isn't one. + if fuzzy and ampm is not None: + val_is_ampm = False + + # If AM/PM is found and hour is not, raise a ValueError + if hour is None: + if fuzzy: + val_is_ampm = False + else: + raise ValueError('No hour specified with AM or PM flag.') + elif not 0 <= hour <= 12: + # If AM/PM is found, it's a 12 hour clock, so raise + # an error for invalid range + if fuzzy: + val_is_ampm = False + else: + raise ValueError('Invalid hour specified for 12-hour clock.') + + return val_is_ampm + + def _adjust_ampm(self, hour, ampm): + if hour < 12 and ampm == 1: + hour += 12 + elif hour == 12 and ampm == 0: + hour = 0 + return hour + + def _parse_min_sec(self, value): + # TODO: Every usage of this function sets res.second to the return + # value. Are there any cases where second will be returned as None and + # we *don't* want to set res.second = None? + minute = int(value) + second = None + + sec_remainder = value % 1 + if sec_remainder: + second = int(60 * sec_remainder) + return (minute, second) + + def _parse_hms(self, idx, tokens, info, hms_idx): + # TODO: Is this going to admit a lot of false-positives for when we + # just happen to have digits and "h", "m" or "s" characters in non-date + # text? I guess hex hashes won't have that problem, but there's plenty + # of random junk out there. + if hms_idx is None: + hms = None + new_idx = idx + elif hms_idx > idx: + hms = info.hms(tokens[hms_idx]) + new_idx = hms_idx + else: + # Looking backwards, increment one. + hms = info.hms(tokens[hms_idx]) + 1 + new_idx = idx + + return (new_idx, hms) + + # ------------------------------------------------------------------ + # Handling for individual tokens. These are kept as methods instead + # of functions for the sake of customizability via subclassing. + + def _parsems(self, value): + """Parse a I[.F] seconds value into (seconds, microseconds).""" + if "." not in value: + return int(value), 0 + else: + i, f = value.split(".") + return int(i), int(f.ljust(6, "0")[:6]) + + def _to_decimal(self, val): + try: + decimal_value = Decimal(val) + # See GH 662, edge case, infinite value should not be converted + # via `_to_decimal` + if not decimal_value.is_finite(): + raise ValueError("Converted decimal value is infinite or NaN") + except Exception as e: + msg = "Could not convert %s to decimal" % val + six.raise_from(ValueError(msg), e) + else: + return decimal_value + + # ------------------------------------------------------------------ + # Post-Parsing construction of datetime output. These are kept as + # methods instead of functions for the sake of customizability via + # subclassing. + + def _build_tzinfo(self, tzinfos, tzname, tzoffset): + if callable(tzinfos): + tzdata = tzinfos(tzname, tzoffset) + else: + tzdata = tzinfos.get(tzname) + # handle case where tzinfo is paased an options that returns None + # eg tzinfos = {'BRST' : None} + if isinstance(tzdata, datetime.tzinfo) or tzdata is None: + tzinfo = tzdata + elif isinstance(tzdata, text_type): + tzinfo = tz.tzstr(tzdata) + elif isinstance(tzdata, integer_types): + tzinfo = tz.tzoffset(tzname, tzdata) + else: + raise TypeError("Offset must be tzinfo subclass, tz string, " + "or int offset.") + return tzinfo + + def _build_tzaware(self, naive, res, tzinfos): + if (callable(tzinfos) or (tzinfos and res.tzname in tzinfos)): + tzinfo = self._build_tzinfo(tzinfos, res.tzname, res.tzoffset) + aware = naive.replace(tzinfo=tzinfo) + aware = self._assign_tzname(aware, res.tzname) + + elif res.tzname and res.tzname in time.tzname: + aware = naive.replace(tzinfo=tz.tzlocal()) + + # Handle ambiguous local datetime + aware = self._assign_tzname(aware, res.tzname) + + # This is mostly relevant for winter GMT zones parsed in the UK + if (aware.tzname() != res.tzname and + res.tzname in self.info.UTCZONE): + aware = aware.replace(tzinfo=tz.UTC) + + elif res.tzoffset == 0: + aware = naive.replace(tzinfo=tz.UTC) + + elif res.tzoffset: + aware = naive.replace(tzinfo=tz.tzoffset(res.tzname, res.tzoffset)) + + elif not res.tzname and not res.tzoffset: + # i.e. no timezone information was found. + aware = naive + + elif res.tzname: + # tz-like string was parsed but we don't know what to do + # with it + warnings.warn("tzname {tzname} identified but not understood. " + "Pass `tzinfos` argument in order to correctly " + "return a timezone-aware datetime. In a future " + "version, this will raise an " + "exception.".format(tzname=res.tzname), + category=UnknownTimezoneWarning) + aware = naive + + return aware + + def _build_naive(self, res, default): + repl = {} + for attr in ("year", "month", "day", "hour", + "minute", "second", "microsecond"): + value = getattr(res, attr) + if value is not None: + repl[attr] = value + + if 'day' not in repl: + # If the default day exceeds the last day of the month, fall back + # to the end of the month. + cyear = default.year if res.year is None else res.year + cmonth = default.month if res.month is None else res.month + cday = default.day if res.day is None else res.day + + if cday > monthrange(cyear, cmonth)[1]: + repl['day'] = monthrange(cyear, cmonth)[1] + + naive = default.replace(**repl) + + if res.weekday is not None and not res.day: + naive = naive + relativedelta.relativedelta(weekday=res.weekday) + + return naive + + def _assign_tzname(self, dt, tzname): + if dt.tzname() != tzname: + new_dt = tz.enfold(dt, fold=1) + if new_dt.tzname() == tzname: + return new_dt + + return dt + + def _recombine_skipped(self, tokens, skipped_idxs): + """ + >>> tokens = ["foo", " ", "bar", " ", "19June2000", "baz"] + >>> skipped_idxs = [0, 1, 2, 5] + >>> _recombine_skipped(tokens, skipped_idxs) + ["foo bar", "baz"] + """ + skipped_tokens = [] + for i, idx in enumerate(sorted(skipped_idxs)): + if i > 0 and idx - 1 == skipped_idxs[i - 1]: + skipped_tokens[-1] = skipped_tokens[-1] + tokens[idx] + else: + skipped_tokens.append(tokens[idx]) + + return skipped_tokens + + +DEFAULTPARSER = parser() + + +def parse(timestr, parserinfo=None, **kwargs): + """ + + Parse a string in one of the supported formats, using the + ``parserinfo`` parameters. + + :param timestr: + A string containing a date/time stamp. + + :param parserinfo: + A :class:`parserinfo` object containing parameters for the parser. + If ``None``, the default arguments to the :class:`parserinfo` + constructor are used. + + The ``**kwargs`` parameter takes the following keyword arguments: + + :param default: + The default datetime object, if this is a datetime object and not + ``None``, elements specified in ``timestr`` replace elements in the + default object. + + :param ignoretz: + If set ``True``, time zones in parsed strings are ignored and a naive + :class:`datetime` object is returned. + + :param tzinfos: + Additional time zone names / aliases which may be present in the + string. This argument maps time zone names (and optionally offsets + from those time zones) to time zones. This parameter can be a + dictionary with timezone aliases mapping time zone names to time + zones or a function taking two parameters (``tzname`` and + ``tzoffset``) and returning a time zone. + + The timezones to which the names are mapped can be an integer + offset from UTC in seconds or a :class:`tzinfo` object. + + .. doctest:: + :options: +NORMALIZE_WHITESPACE + + >>> from dateutil.parser import parse + >>> from dateutil.tz import gettz + >>> tzinfos = {"BRST": -7200, "CST": gettz("America/Chicago")} + >>> parse("2012-01-19 17:21:00 BRST", tzinfos=tzinfos) + datetime.datetime(2012, 1, 19, 17, 21, tzinfo=tzoffset(u'BRST', -7200)) + >>> parse("2012-01-19 17:21:00 CST", tzinfos=tzinfos) + datetime.datetime(2012, 1, 19, 17, 21, + tzinfo=tzfile('/usr/share/zoneinfo/America/Chicago')) + + This parameter is ignored if ``ignoretz`` is set. + + :param dayfirst: + Whether to interpret the first value in an ambiguous 3-integer date + (e.g. 01/05/09) as the day (``True``) or month (``False``). If + ``yearfirst`` is set to ``True``, this distinguishes between YDM and + YMD. If set to ``None``, this value is retrieved from the current + :class:`parserinfo` object (which itself defaults to ``False``). + + :param yearfirst: + Whether to interpret the first value in an ambiguous 3-integer date + (e.g. 01/05/09) as the year. If ``True``, the first number is taken to + be the year, otherwise the last number is taken to be the year. If + this is set to ``None``, the value is retrieved from the current + :class:`parserinfo` object (which itself defaults to ``False``). + + :param fuzzy: + Whether to allow fuzzy parsing, allowing for string like "Today is + January 1, 2047 at 8:21:00AM". + + :param fuzzy_with_tokens: + If ``True``, ``fuzzy`` is automatically set to True, and the parser + will return a tuple where the first element is the parsed + :class:`datetime.datetime` datetimestamp and the second element is + a tuple containing the portions of the string which were ignored: + + .. doctest:: + + >>> from dateutil.parser import parse + >>> parse("Today is January 1, 2047 at 8:21:00AM", fuzzy_with_tokens=True) + (datetime.datetime(2047, 1, 1, 8, 21), (u'Today is ', u' ', u'at ')) + + :return: + Returns a :class:`datetime.datetime` object or, if the + ``fuzzy_with_tokens`` option is ``True``, returns a tuple, the + first element being a :class:`datetime.datetime` object, the second + a tuple containing the fuzzy tokens. + + :raises ParserError: + Raised for invalid or unknown string formats, if the provided + :class:`tzinfo` is not in a valid format, or if an invalid date would + be created. + + :raises OverflowError: + Raised if the parsed date exceeds the largest valid C integer on + your system. + """ + if parserinfo: + return parser(parserinfo).parse(timestr, **kwargs) + else: + return DEFAULTPARSER.parse(timestr, **kwargs) + + +class _tzparser(object): + + class _result(_resultbase): + + __slots__ = ["stdabbr", "stdoffset", "dstabbr", "dstoffset", + "start", "end"] + + class _attr(_resultbase): + __slots__ = ["month", "week", "weekday", + "yday", "jyday", "day", "time"] + + def __repr__(self): + return self._repr("") + + def __init__(self): + _resultbase.__init__(self) + self.start = self._attr() + self.end = self._attr() + + def parse(self, tzstr): + res = self._result() + l = [x for x in re.split(r'([,:.]|[a-zA-Z]+|[0-9]+)',tzstr) if x] + used_idxs = list() + try: + + len_l = len(l) + + i = 0 + while i < len_l: + # BRST+3[BRDT[+2]] + j = i + while j < len_l and not [x for x in l[j] + if x in "0123456789:,-+"]: + j += 1 + if j != i: + if not res.stdabbr: + offattr = "stdoffset" + res.stdabbr = "".join(l[i:j]) + else: + offattr = "dstoffset" + res.dstabbr = "".join(l[i:j]) + + for ii in range(j): + used_idxs.append(ii) + i = j + if (i < len_l and (l[i] in ('+', '-') or l[i][0] in + "0123456789")): + if l[i] in ('+', '-'): + # Yes, that's right. See the TZ variable + # documentation. + signal = (1, -1)[l[i] == '+'] + used_idxs.append(i) + i += 1 + else: + signal = -1 + len_li = len(l[i]) + if len_li == 4: + # -0300 + setattr(res, offattr, (int(l[i][:2]) * 3600 + + int(l[i][2:]) * 60) * signal) + elif i + 1 < len_l and l[i + 1] == ':': + # -03:00 + setattr(res, offattr, + (int(l[i]) * 3600 + + int(l[i + 2]) * 60) * signal) + used_idxs.append(i) + i += 2 + elif len_li <= 2: + # -[0]3 + setattr(res, offattr, + int(l[i][:2]) * 3600 * signal) + else: + return None + used_idxs.append(i) + i += 1 + if res.dstabbr: + break + else: + break + + + if i < len_l: + for j in range(i, len_l): + if l[j] == ';': + l[j] = ',' + + assert l[i] == ',' + + i += 1 + + if i >= len_l: + pass + elif (8 <= l.count(',') <= 9 and + not [y for x in l[i:] if x != ',' + for y in x if y not in "0123456789+-"]): + # GMT0BST,3,0,30,3600,10,0,26,7200[,3600] + for x in (res.start, res.end): + x.month = int(l[i]) + used_idxs.append(i) + i += 2 + if l[i] == '-': + value = int(l[i + 1]) * -1 + used_idxs.append(i) + i += 1 + else: + value = int(l[i]) + used_idxs.append(i) + i += 2 + if value: + x.week = value + x.weekday = (int(l[i]) - 1) % 7 + else: + x.day = int(l[i]) + used_idxs.append(i) + i += 2 + x.time = int(l[i]) + used_idxs.append(i) + i += 2 + if i < len_l: + if l[i] in ('-', '+'): + signal = (-1, 1)[l[i] == "+"] + used_idxs.append(i) + i += 1 + else: + signal = 1 + used_idxs.append(i) + res.dstoffset = (res.stdoffset + int(l[i]) * signal) + + # This was a made-up format that is not in normal use + warn(('Parsed time zone "%s"' % tzstr) + + 'is in a non-standard dateutil-specific format, which ' + + 'is now deprecated; support for parsing this format ' + + 'will be removed in future versions. It is recommended ' + + 'that you switch to a standard format like the GNU ' + + 'TZ variable format.', tz.DeprecatedTzFormatWarning) + elif (l.count(',') == 2 and l[i:].count('/') <= 2 and + not [y for x in l[i:] if x not in (',', '/', 'J', 'M', + '.', '-', ':') + for y in x if y not in "0123456789"]): + for x in (res.start, res.end): + if l[i] == 'J': + # non-leap year day (1 based) + used_idxs.append(i) + i += 1 + x.jyday = int(l[i]) + elif l[i] == 'M': + # month[-.]week[-.]weekday + used_idxs.append(i) + i += 1 + x.month = int(l[i]) + used_idxs.append(i) + i += 1 + assert l[i] in ('-', '.') + used_idxs.append(i) + i += 1 + x.week = int(l[i]) + if x.week == 5: + x.week = -1 + used_idxs.append(i) + i += 1 + assert l[i] in ('-', '.') + used_idxs.append(i) + i += 1 + x.weekday = (int(l[i]) - 1) % 7 + else: + # year day (zero based) + x.yday = int(l[i]) + 1 + + used_idxs.append(i) + i += 1 + + if i < len_l and l[i] == '/': + used_idxs.append(i) + i += 1 + # start time + len_li = len(l[i]) + if len_li == 4: + # -0300 + x.time = (int(l[i][:2]) * 3600 + + int(l[i][2:]) * 60) + elif i + 1 < len_l and l[i + 1] == ':': + # -03:00 + x.time = int(l[i]) * 3600 + int(l[i + 2]) * 60 + used_idxs.append(i) + i += 2 + if i + 1 < len_l and l[i + 1] == ':': + used_idxs.append(i) + i += 2 + x.time += int(l[i]) + elif len_li <= 2: + # -[0]3 + x.time = (int(l[i][:2]) * 3600) + else: + return None + used_idxs.append(i) + i += 1 + + assert i == len_l or l[i] == ',' + + i += 1 + + assert i >= len_l + + except (IndexError, ValueError, AssertionError): + return None + + unused_idxs = set(range(len_l)).difference(used_idxs) + res.any_unused_tokens = not {l[n] for n in unused_idxs}.issubset({",",":"}) + return res + + +DEFAULTTZPARSER = _tzparser() + + +def _parsetz(tzstr): + return DEFAULTTZPARSER.parse(tzstr) + + +class ParserError(ValueError): + """Exception subclass used for any failure to parse a datetime string. + + This is a subclass of :py:exc:`ValueError`, and should be raised any time + earlier versions of ``dateutil`` would have raised ``ValueError``. + + .. versionadded:: 2.8.1 + """ + def __str__(self): + try: + return self.args[0] % self.args[1:] + except (TypeError, IndexError): + return super(ParserError, self).__str__() + + def __repr__(self): + args = ", ".join("'%s'" % arg for arg in self.args) + return "%s(%s)" % (self.__class__.__name__, args) + + +class UnknownTimezoneWarning(RuntimeWarning): + """Raised when the parser finds a timezone it cannot parse into a tzinfo. + + .. versionadded:: 2.7.0 + """ +# vim:ts=4:sw=4:et diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/parser/isoparser.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/parser/isoparser.py new file mode 100644 index 0000000000000000000000000000000000000000..7060087df4776a07347cbb60127a70db393e3a65 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/parser/isoparser.py @@ -0,0 +1,416 @@ +# -*- coding: utf-8 -*- +""" +This module offers a parser for ISO-8601 strings + +It is intended to support all valid date, time and datetime formats per the +ISO-8601 specification. + +..versionadded:: 2.7.0 +""" +from datetime import datetime, timedelta, time, date +import calendar +from dateutil import tz + +from functools import wraps + +import re +import six + +__all__ = ["isoparse", "isoparser"] + + +def _takes_ascii(f): + @wraps(f) + def func(self, str_in, *args, **kwargs): + # If it's a stream, read the whole thing + str_in = getattr(str_in, 'read', lambda: str_in)() + + # If it's unicode, turn it into bytes, since ISO-8601 only covers ASCII + if isinstance(str_in, six.text_type): + # ASCII is the same in UTF-8 + try: + str_in = str_in.encode('ascii') + except UnicodeEncodeError as e: + msg = 'ISO-8601 strings should contain only ASCII characters' + six.raise_from(ValueError(msg), e) + + return f(self, str_in, *args, **kwargs) + + return func + + +class isoparser(object): + def __init__(self, sep=None): + """ + :param sep: + A single character that separates date and time portions. If + ``None``, the parser will accept any single character. + For strict ISO-8601 adherence, pass ``'T'``. + """ + if sep is not None: + if (len(sep) != 1 or ord(sep) >= 128 or sep in '0123456789'): + raise ValueError('Separator must be a single, non-numeric ' + + 'ASCII character') + + sep = sep.encode('ascii') + + self._sep = sep + + @_takes_ascii + def isoparse(self, dt_str): + """ + Parse an ISO-8601 datetime string into a :class:`datetime.datetime`. + + An ISO-8601 datetime string consists of a date portion, followed + optionally by a time portion - the date and time portions are separated + by a single character separator, which is ``T`` in the official + standard. Incomplete date formats (such as ``YYYY-MM``) may *not* be + combined with a time portion. + + Supported date formats are: + + Common: + + - ``YYYY`` + - ``YYYY-MM`` + - ``YYYY-MM-DD`` or ``YYYYMMDD`` + + Uncommon: + + - ``YYYY-Www`` or ``YYYYWww`` - ISO week (day defaults to 0) + - ``YYYY-Www-D`` or ``YYYYWwwD`` - ISO week and day + + The ISO week and day numbering follows the same logic as + :func:`datetime.date.isocalendar`. + + Supported time formats are: + + - ``hh`` + - ``hh:mm`` or ``hhmm`` + - ``hh:mm:ss`` or ``hhmmss`` + - ``hh:mm:ss.ssssss`` (Up to 6 sub-second digits) + + Midnight is a special case for `hh`, as the standard supports both + 00:00 and 24:00 as a representation. The decimal separator can be + either a dot or a comma. + + + .. caution:: + + Support for fractional components other than seconds is part of the + ISO-8601 standard, but is not currently implemented in this parser. + + Supported time zone offset formats are: + + - `Z` (UTC) + - `±HH:MM` + - `±HHMM` + - `±HH` + + Offsets will be represented as :class:`dateutil.tz.tzoffset` objects, + with the exception of UTC, which will be represented as + :class:`dateutil.tz.tzutc`. Time zone offsets equivalent to UTC (such + as `+00:00`) will also be represented as :class:`dateutil.tz.tzutc`. + + :param dt_str: + A string or stream containing only an ISO-8601 datetime string + + :return: + Returns a :class:`datetime.datetime` representing the string. + Unspecified components default to their lowest value. + + .. warning:: + + As of version 2.7.0, the strictness of the parser should not be + considered a stable part of the contract. Any valid ISO-8601 string + that parses correctly with the default settings will continue to + parse correctly in future versions, but invalid strings that + currently fail (e.g. ``2017-01-01T00:00+00:00:00``) are not + guaranteed to continue failing in future versions if they encode + a valid date. + + .. versionadded:: 2.7.0 + """ + components, pos = self._parse_isodate(dt_str) + + if len(dt_str) > pos: + if self._sep is None or dt_str[pos:pos + 1] == self._sep: + components += self._parse_isotime(dt_str[pos + 1:]) + else: + raise ValueError('String contains unknown ISO components') + + if len(components) > 3 and components[3] == 24: + components[3] = 0 + return datetime(*components) + timedelta(days=1) + + return datetime(*components) + + @_takes_ascii + def parse_isodate(self, datestr): + """ + Parse the date portion of an ISO string. + + :param datestr: + The string portion of an ISO string, without a separator + + :return: + Returns a :class:`datetime.date` object + """ + components, pos = self._parse_isodate(datestr) + if pos < len(datestr): + raise ValueError('String contains unknown ISO ' + + 'components: {!r}'.format(datestr.decode('ascii'))) + return date(*components) + + @_takes_ascii + def parse_isotime(self, timestr): + """ + Parse the time portion of an ISO string. + + :param timestr: + The time portion of an ISO string, without a separator + + :return: + Returns a :class:`datetime.time` object + """ + components = self._parse_isotime(timestr) + if components[0] == 24: + components[0] = 0 + return time(*components) + + @_takes_ascii + def parse_tzstr(self, tzstr, zero_as_utc=True): + """ + Parse a valid ISO time zone string. + + See :func:`isoparser.isoparse` for details on supported formats. + + :param tzstr: + A string representing an ISO time zone offset + + :param zero_as_utc: + Whether to return :class:`dateutil.tz.tzutc` for zero-offset zones + + :return: + Returns :class:`dateutil.tz.tzoffset` for offsets and + :class:`dateutil.tz.tzutc` for ``Z`` and (if ``zero_as_utc`` is + specified) offsets equivalent to UTC. + """ + return self._parse_tzstr(tzstr, zero_as_utc=zero_as_utc) + + # Constants + _DATE_SEP = b'-' + _TIME_SEP = b':' + _FRACTION_REGEX = re.compile(b'[\\.,]([0-9]+)') + + def _parse_isodate(self, dt_str): + try: + return self._parse_isodate_common(dt_str) + except ValueError: + return self._parse_isodate_uncommon(dt_str) + + def _parse_isodate_common(self, dt_str): + len_str = len(dt_str) + components = [1, 1, 1] + + if len_str < 4: + raise ValueError('ISO string too short') + + # Year + components[0] = int(dt_str[0:4]) + pos = 4 + if pos >= len_str: + return components, pos + + has_sep = dt_str[pos:pos + 1] == self._DATE_SEP + if has_sep: + pos += 1 + + # Month + if len_str - pos < 2: + raise ValueError('Invalid common month') + + components[1] = int(dt_str[pos:pos + 2]) + pos += 2 + + if pos >= len_str: + if has_sep: + return components, pos + else: + raise ValueError('Invalid ISO format') + + if has_sep: + if dt_str[pos:pos + 1] != self._DATE_SEP: + raise ValueError('Invalid separator in ISO string') + pos += 1 + + # Day + if len_str - pos < 2: + raise ValueError('Invalid common day') + components[2] = int(dt_str[pos:pos + 2]) + return components, pos + 2 + + def _parse_isodate_uncommon(self, dt_str): + if len(dt_str) < 4: + raise ValueError('ISO string too short') + + # All ISO formats start with the year + year = int(dt_str[0:4]) + + has_sep = dt_str[4:5] == self._DATE_SEP + + pos = 4 + has_sep # Skip '-' if it's there + if dt_str[pos:pos + 1] == b'W': + # YYYY-?Www-?D? + pos += 1 + weekno = int(dt_str[pos:pos + 2]) + pos += 2 + + dayno = 1 + if len(dt_str) > pos: + if (dt_str[pos:pos + 1] == self._DATE_SEP) != has_sep: + raise ValueError('Inconsistent use of dash separator') + + pos += has_sep + + dayno = int(dt_str[pos:pos + 1]) + pos += 1 + + base_date = self._calculate_weekdate(year, weekno, dayno) + else: + # YYYYDDD or YYYY-DDD + if len(dt_str) - pos < 3: + raise ValueError('Invalid ordinal day') + + ordinal_day = int(dt_str[pos:pos + 3]) + pos += 3 + + if ordinal_day < 1 or ordinal_day > (365 + calendar.isleap(year)): + raise ValueError('Invalid ordinal day' + + ' {} for year {}'.format(ordinal_day, year)) + + base_date = date(year, 1, 1) + timedelta(days=ordinal_day - 1) + + components = [base_date.year, base_date.month, base_date.day] + return components, pos + + def _calculate_weekdate(self, year, week, day): + """ + Calculate the day of corresponding to the ISO year-week-day calendar. + + This function is effectively the inverse of + :func:`datetime.date.isocalendar`. + + :param year: + The year in the ISO calendar + + :param week: + The week in the ISO calendar - range is [1, 53] + + :param day: + The day in the ISO calendar - range is [1 (MON), 7 (SUN)] + + :return: + Returns a :class:`datetime.date` + """ + if not 0 < week < 54: + raise ValueError('Invalid week: {}'.format(week)) + + if not 0 < day < 8: # Range is 1-7 + raise ValueError('Invalid weekday: {}'.format(day)) + + # Get week 1 for the specific year: + jan_4 = date(year, 1, 4) # Week 1 always has January 4th in it + week_1 = jan_4 - timedelta(days=jan_4.isocalendar()[2] - 1) + + # Now add the specific number of weeks and days to get what we want + week_offset = (week - 1) * 7 + (day - 1) + return week_1 + timedelta(days=week_offset) + + def _parse_isotime(self, timestr): + len_str = len(timestr) + components = [0, 0, 0, 0, None] + pos = 0 + comp = -1 + + if len_str < 2: + raise ValueError('ISO time too short') + + has_sep = False + + while pos < len_str and comp < 5: + comp += 1 + + if timestr[pos:pos + 1] in b'-+Zz': + # Detect time zone boundary + components[-1] = self._parse_tzstr(timestr[pos:]) + pos = len_str + break + + if comp == 1 and timestr[pos:pos+1] == self._TIME_SEP: + has_sep = True + pos += 1 + elif comp == 2 and has_sep: + if timestr[pos:pos+1] != self._TIME_SEP: + raise ValueError('Inconsistent use of colon separator') + pos += 1 + + if comp < 3: + # Hour, minute, second + components[comp] = int(timestr[pos:pos + 2]) + pos += 2 + + if comp == 3: + # Fraction of a second + frac = self._FRACTION_REGEX.match(timestr[pos:]) + if not frac: + continue + + us_str = frac.group(1)[:6] # Truncate to microseconds + components[comp] = int(us_str) * 10**(6 - len(us_str)) + pos += len(frac.group()) + + if pos < len_str: + raise ValueError('Unused components in ISO string') + + if components[0] == 24: + # Standard supports 00:00 and 24:00 as representations of midnight + if any(component != 0 for component in components[1:4]): + raise ValueError('Hour may only be 24 at 24:00:00.000') + + return components + + def _parse_tzstr(self, tzstr, zero_as_utc=True): + if tzstr == b'Z' or tzstr == b'z': + return tz.UTC + + if len(tzstr) not in {3, 5, 6}: + raise ValueError('Time zone offset must be 1, 3, 5 or 6 characters') + + if tzstr[0:1] == b'-': + mult = -1 + elif tzstr[0:1] == b'+': + mult = 1 + else: + raise ValueError('Time zone offset requires sign') + + hours = int(tzstr[1:3]) + if len(tzstr) == 3: + minutes = 0 + else: + minutes = int(tzstr[(4 if tzstr[3:4] == self._TIME_SEP else 3):]) + + if zero_as_utc and hours == 0 and minutes == 0: + return tz.UTC + else: + if minutes > 59: + raise ValueError('Invalid minutes in time zone offset') + + if hours > 23: + raise ValueError('Invalid hours in time zone offset') + + return tz.tzoffset(None, mult * (hours * 60 + minutes) * 60) + + +DEFAULT_ISOPARSER = isoparser() +isoparse = DEFAULT_ISOPARSER.isoparse diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/relativedelta.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/relativedelta.py new file mode 100644 index 0000000000000000000000000000000000000000..cd323a549e0f182541ebcde2d2ea1adfbbd9701e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/relativedelta.py @@ -0,0 +1,599 @@ +# -*- coding: utf-8 -*- +import datetime +import calendar + +import operator +from math import copysign + +from six import integer_types +from warnings import warn + +from ._common import weekday + +MO, TU, WE, TH, FR, SA, SU = weekdays = tuple(weekday(x) for x in range(7)) + +__all__ = ["relativedelta", "MO", "TU", "WE", "TH", "FR", "SA", "SU"] + + +class relativedelta(object): + """ + The relativedelta type is designed to be applied to an existing datetime and + can replace specific components of that datetime, or represents an interval + of time. + + It is based on the specification of the excellent work done by M.-A. Lemburg + in his + `mx.DateTime <https://www.egenix.com/products/python/mxBase/mxDateTime/>`_ extension. + However, notice that this type does *NOT* implement the same algorithm as + his work. Do *NOT* expect it to behave like mx.DateTime's counterpart. + + There are two different ways to build a relativedelta instance. The + first one is passing it two date/datetime classes:: + + relativedelta(datetime1, datetime2) + + The second one is passing it any number of the following keyword arguments:: + + relativedelta(arg1=x,arg2=y,arg3=z...) + + year, month, day, hour, minute, second, microsecond: + Absolute information (argument is singular); adding or subtracting a + relativedelta with absolute information does not perform an arithmetic + operation, but rather REPLACES the corresponding value in the + original datetime with the value(s) in relativedelta. + + years, months, weeks, days, hours, minutes, seconds, microseconds: + Relative information, may be negative (argument is plural); adding + or subtracting a relativedelta with relative information performs + the corresponding arithmetic operation on the original datetime value + with the information in the relativedelta. + + weekday: + One of the weekday instances (MO, TU, etc) available in the + relativedelta module. These instances may receive a parameter N, + specifying the Nth weekday, which could be positive or negative + (like MO(+1) or MO(-2)). Not specifying it is the same as specifying + +1. You can also use an integer, where 0=MO. This argument is always + relative e.g. if the calculated date is already Monday, using MO(1) + or MO(-1) won't change the day. To effectively make it absolute, use + it in combination with the day argument (e.g. day=1, MO(1) for first + Monday of the month). + + leapdays: + Will add given days to the date found, if year is a leap + year, and the date found is post 28 of february. + + yearday, nlyearday: + Set the yearday or the non-leap year day (jump leap days). + These are converted to day/month/leapdays information. + + There are relative and absolute forms of the keyword + arguments. The plural is relative, and the singular is + absolute. For each argument in the order below, the absolute form + is applied first (by setting each attribute to that value) and + then the relative form (by adding the value to the attribute). + + The order of attributes considered when this relativedelta is + added to a datetime is: + + 1. Year + 2. Month + 3. Day + 4. Hours + 5. Minutes + 6. Seconds + 7. Microseconds + + Finally, weekday is applied, using the rule described above. + + For example + + >>> from datetime import datetime + >>> from dateutil.relativedelta import relativedelta, MO + >>> dt = datetime(2018, 4, 9, 13, 37, 0) + >>> delta = relativedelta(hours=25, day=1, weekday=MO(1)) + >>> dt + delta + datetime.datetime(2018, 4, 2, 14, 37) + + First, the day is set to 1 (the first of the month), then 25 hours + are added, to get to the 2nd day and 14th hour, finally the + weekday is applied, but since the 2nd is already a Monday there is + no effect. + + """ + + def __init__(self, dt1=None, dt2=None, + years=0, months=0, days=0, leapdays=0, weeks=0, + hours=0, minutes=0, seconds=0, microseconds=0, + year=None, month=None, day=None, weekday=None, + yearday=None, nlyearday=None, + hour=None, minute=None, second=None, microsecond=None): + + if dt1 and dt2: + # datetime is a subclass of date. So both must be date + if not (isinstance(dt1, datetime.date) and + isinstance(dt2, datetime.date)): + raise TypeError("relativedelta only diffs datetime/date") + + # We allow two dates, or two datetimes, so we coerce them to be + # of the same type + if (isinstance(dt1, datetime.datetime) != + isinstance(dt2, datetime.datetime)): + if not isinstance(dt1, datetime.datetime): + dt1 = datetime.datetime.fromordinal(dt1.toordinal()) + elif not isinstance(dt2, datetime.datetime): + dt2 = datetime.datetime.fromordinal(dt2.toordinal()) + + self.years = 0 + self.months = 0 + self.days = 0 + self.leapdays = 0 + self.hours = 0 + self.minutes = 0 + self.seconds = 0 + self.microseconds = 0 + self.year = None + self.month = None + self.day = None + self.weekday = None + self.hour = None + self.minute = None + self.second = None + self.microsecond = None + self._has_time = 0 + + # Get year / month delta between the two + months = (dt1.year - dt2.year) * 12 + (dt1.month - dt2.month) + self._set_months(months) + + # Remove the year/month delta so the timedelta is just well-defined + # time units (seconds, days and microseconds) + dtm = self.__radd__(dt2) + + # If we've overshot our target, make an adjustment + if dt1 < dt2: + compare = operator.gt + increment = 1 + else: + compare = operator.lt + increment = -1 + + while compare(dt1, dtm): + months += increment + self._set_months(months) + dtm = self.__radd__(dt2) + + # Get the timedelta between the "months-adjusted" date and dt1 + delta = dt1 - dtm + self.seconds = delta.seconds + delta.days * 86400 + self.microseconds = delta.microseconds + else: + # Check for non-integer values in integer-only quantities + if any(x is not None and x != int(x) for x in (years, months)): + raise ValueError("Non-integer years and months are " + "ambiguous and not currently supported.") + + # Relative information + self.years = int(years) + self.months = int(months) + self.days = days + weeks * 7 + self.leapdays = leapdays + self.hours = hours + self.minutes = minutes + self.seconds = seconds + self.microseconds = microseconds + + # Absolute information + self.year = year + self.month = month + self.day = day + self.hour = hour + self.minute = minute + self.second = second + self.microsecond = microsecond + + if any(x is not None and int(x) != x + for x in (year, month, day, hour, + minute, second, microsecond)): + # For now we'll deprecate floats - later it'll be an error. + warn("Non-integer value passed as absolute information. " + + "This is not a well-defined condition and will raise " + + "errors in future versions.", DeprecationWarning) + + if isinstance(weekday, integer_types): + self.weekday = weekdays[weekday] + else: + self.weekday = weekday + + yday = 0 + if nlyearday: + yday = nlyearday + elif yearday: + yday = yearday + if yearday > 59: + self.leapdays = -1 + if yday: + ydayidx = [31, 59, 90, 120, 151, 181, 212, + 243, 273, 304, 334, 366] + for idx, ydays in enumerate(ydayidx): + if yday <= ydays: + self.month = idx+1 + if idx == 0: + self.day = yday + else: + self.day = yday-ydayidx[idx-1] + break + else: + raise ValueError("invalid year day (%d)" % yday) + + self._fix() + + def _fix(self): + if abs(self.microseconds) > 999999: + s = _sign(self.microseconds) + div, mod = divmod(self.microseconds * s, 1000000) + self.microseconds = mod * s + self.seconds += div * s + if abs(self.seconds) > 59: + s = _sign(self.seconds) + div, mod = divmod(self.seconds * s, 60) + self.seconds = mod * s + self.minutes += div * s + if abs(self.minutes) > 59: + s = _sign(self.minutes) + div, mod = divmod(self.minutes * s, 60) + self.minutes = mod * s + self.hours += div * s + if abs(self.hours) > 23: + s = _sign(self.hours) + div, mod = divmod(self.hours * s, 24) + self.hours = mod * s + self.days += div * s + if abs(self.months) > 11: + s = _sign(self.months) + div, mod = divmod(self.months * s, 12) + self.months = mod * s + self.years += div * s + if (self.hours or self.minutes or self.seconds or self.microseconds + or self.hour is not None or self.minute is not None or + self.second is not None or self.microsecond is not None): + self._has_time = 1 + else: + self._has_time = 0 + + @property + def weeks(self): + return int(self.days / 7.0) + + @weeks.setter + def weeks(self, value): + self.days = self.days - (self.weeks * 7) + value * 7 + + def _set_months(self, months): + self.months = months + if abs(self.months) > 11: + s = _sign(self.months) + div, mod = divmod(self.months * s, 12) + self.months = mod * s + self.years = div * s + else: + self.years = 0 + + def normalized(self): + """ + Return a version of this object represented entirely using integer + values for the relative attributes. + + >>> relativedelta(days=1.5, hours=2).normalized() + relativedelta(days=+1, hours=+14) + + :return: + Returns a :class:`dateutil.relativedelta.relativedelta` object. + """ + # Cascade remainders down (rounding each to roughly nearest microsecond) + days = int(self.days) + + hours_f = round(self.hours + 24 * (self.days - days), 11) + hours = int(hours_f) + + minutes_f = round(self.minutes + 60 * (hours_f - hours), 10) + minutes = int(minutes_f) + + seconds_f = round(self.seconds + 60 * (minutes_f - minutes), 8) + seconds = int(seconds_f) + + microseconds = round(self.microseconds + 1e6 * (seconds_f - seconds)) + + # Constructor carries overflow back up with call to _fix() + return self.__class__(years=self.years, months=self.months, + days=days, hours=hours, minutes=minutes, + seconds=seconds, microseconds=microseconds, + leapdays=self.leapdays, year=self.year, + month=self.month, day=self.day, + weekday=self.weekday, hour=self.hour, + minute=self.minute, second=self.second, + microsecond=self.microsecond) + + def __add__(self, other): + if isinstance(other, relativedelta): + return self.__class__(years=other.years + self.years, + months=other.months + self.months, + days=other.days + self.days, + hours=other.hours + self.hours, + minutes=other.minutes + self.minutes, + seconds=other.seconds + self.seconds, + microseconds=(other.microseconds + + self.microseconds), + leapdays=other.leapdays or self.leapdays, + year=(other.year if other.year is not None + else self.year), + month=(other.month if other.month is not None + else self.month), + day=(other.day if other.day is not None + else self.day), + weekday=(other.weekday if other.weekday is not None + else self.weekday), + hour=(other.hour if other.hour is not None + else self.hour), + minute=(other.minute if other.minute is not None + else self.minute), + second=(other.second if other.second is not None + else self.second), + microsecond=(other.microsecond if other.microsecond + is not None else + self.microsecond)) + if isinstance(other, datetime.timedelta): + return self.__class__(years=self.years, + months=self.months, + days=self.days + other.days, + hours=self.hours, + minutes=self.minutes, + seconds=self.seconds + other.seconds, + microseconds=self.microseconds + other.microseconds, + leapdays=self.leapdays, + year=self.year, + month=self.month, + day=self.day, + weekday=self.weekday, + hour=self.hour, + minute=self.minute, + second=self.second, + microsecond=self.microsecond) + if not isinstance(other, datetime.date): + return NotImplemented + elif self._has_time and not isinstance(other, datetime.datetime): + other = datetime.datetime.fromordinal(other.toordinal()) + year = (self.year or other.year)+self.years + month = self.month or other.month + if self.months: + assert 1 <= abs(self.months) <= 12 + month += self.months + if month > 12: + year += 1 + month -= 12 + elif month < 1: + year -= 1 + month += 12 + day = min(calendar.monthrange(year, month)[1], + self.day or other.day) + repl = {"year": year, "month": month, "day": day} + for attr in ["hour", "minute", "second", "microsecond"]: + value = getattr(self, attr) + if value is not None: + repl[attr] = value + days = self.days + if self.leapdays and month > 2 and calendar.isleap(year): + days += self.leapdays + ret = (other.replace(**repl) + + datetime.timedelta(days=days, + hours=self.hours, + minutes=self.minutes, + seconds=self.seconds, + microseconds=self.microseconds)) + if self.weekday: + weekday, nth = self.weekday.weekday, self.weekday.n or 1 + jumpdays = (abs(nth) - 1) * 7 + if nth > 0: + jumpdays += (7 - ret.weekday() + weekday) % 7 + else: + jumpdays += (ret.weekday() - weekday) % 7 + jumpdays *= -1 + ret += datetime.timedelta(days=jumpdays) + return ret + + def __radd__(self, other): + return self.__add__(other) + + def __rsub__(self, other): + return self.__neg__().__radd__(other) + + def __sub__(self, other): + if not isinstance(other, relativedelta): + return NotImplemented # In case the other object defines __rsub__ + return self.__class__(years=self.years - other.years, + months=self.months - other.months, + days=self.days - other.days, + hours=self.hours - other.hours, + minutes=self.minutes - other.minutes, + seconds=self.seconds - other.seconds, + microseconds=self.microseconds - other.microseconds, + leapdays=self.leapdays or other.leapdays, + year=(self.year if self.year is not None + else other.year), + month=(self.month if self.month is not None else + other.month), + day=(self.day if self.day is not None else + other.day), + weekday=(self.weekday if self.weekday is not None else + other.weekday), + hour=(self.hour if self.hour is not None else + other.hour), + minute=(self.minute if self.minute is not None else + other.minute), + second=(self.second if self.second is not None else + other.second), + microsecond=(self.microsecond if self.microsecond + is not None else + other.microsecond)) + + def __abs__(self): + return self.__class__(years=abs(self.years), + months=abs(self.months), + days=abs(self.days), + hours=abs(self.hours), + minutes=abs(self.minutes), + seconds=abs(self.seconds), + microseconds=abs(self.microseconds), + leapdays=self.leapdays, + year=self.year, + month=self.month, + day=self.day, + weekday=self.weekday, + hour=self.hour, + minute=self.minute, + second=self.second, + microsecond=self.microsecond) + + def __neg__(self): + return self.__class__(years=-self.years, + months=-self.months, + days=-self.days, + hours=-self.hours, + minutes=-self.minutes, + seconds=-self.seconds, + microseconds=-self.microseconds, + leapdays=self.leapdays, + year=self.year, + month=self.month, + day=self.day, + weekday=self.weekday, + hour=self.hour, + minute=self.minute, + second=self.second, + microsecond=self.microsecond) + + def __bool__(self): + return not (not self.years and + not self.months and + not self.days and + not self.hours and + not self.minutes and + not self.seconds and + not self.microseconds and + not self.leapdays and + self.year is None and + self.month is None and + self.day is None and + self.weekday is None and + self.hour is None and + self.minute is None and + self.second is None and + self.microsecond is None) + # Compatibility with Python 2.x + __nonzero__ = __bool__ + + def __mul__(self, other): + try: + f = float(other) + except TypeError: + return NotImplemented + + return self.__class__(years=int(self.years * f), + months=int(self.months * f), + days=int(self.days * f), + hours=int(self.hours * f), + minutes=int(self.minutes * f), + seconds=int(self.seconds * f), + microseconds=int(self.microseconds * f), + leapdays=self.leapdays, + year=self.year, + month=self.month, + day=self.day, + weekday=self.weekday, + hour=self.hour, + minute=self.minute, + second=self.second, + microsecond=self.microsecond) + + __rmul__ = __mul__ + + def __eq__(self, other): + if not isinstance(other, relativedelta): + return NotImplemented + if self.weekday or other.weekday: + if not self.weekday or not other.weekday: + return False + if self.weekday.weekday != other.weekday.weekday: + return False + n1, n2 = self.weekday.n, other.weekday.n + if n1 != n2 and not ((not n1 or n1 == 1) and (not n2 or n2 == 1)): + return False + return (self.years == other.years and + self.months == other.months and + self.days == other.days and + self.hours == other.hours and + self.minutes == other.minutes and + self.seconds == other.seconds and + self.microseconds == other.microseconds and + self.leapdays == other.leapdays and + self.year == other.year and + self.month == other.month and + self.day == other.day and + self.hour == other.hour and + self.minute == other.minute and + self.second == other.second and + self.microsecond == other.microsecond) + + def __hash__(self): + return hash(( + self.weekday, + self.years, + self.months, + self.days, + self.hours, + self.minutes, + self.seconds, + self.microseconds, + self.leapdays, + self.year, + self.month, + self.day, + self.hour, + self.minute, + self.second, + self.microsecond, + )) + + def __ne__(self, other): + return not self.__eq__(other) + + def __div__(self, other): + try: + reciprocal = 1 / float(other) + except TypeError: + return NotImplemented + + return self.__mul__(reciprocal) + + __truediv__ = __div__ + + def __repr__(self): + l = [] + for attr in ["years", "months", "days", "leapdays", + "hours", "minutes", "seconds", "microseconds"]: + value = getattr(self, attr) + if value: + l.append("{attr}={value:+g}".format(attr=attr, value=value)) + for attr in ["year", "month", "day", "weekday", + "hour", "minute", "second", "microsecond"]: + value = getattr(self, attr) + if value is not None: + l.append("{attr}={value}".format(attr=attr, value=repr(value))) + return "{classname}({attrs})".format(classname=self.__class__.__name__, + attrs=", ".join(l)) + + +def _sign(x): + return int(copysign(1, x)) + +# vim:ts=4:sw=4:et diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/rrule.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/rrule.py new file mode 100644 index 0000000000000000000000000000000000000000..571a0d2bc886a7ea4c06196b2f52e740c2ed6e9f --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/rrule.py @@ -0,0 +1,1737 @@ +# -*- coding: utf-8 -*- +""" +The rrule module offers a small, complete, and very fast, implementation of +the recurrence rules documented in the +`iCalendar RFC <https://tools.ietf.org/html/rfc5545>`_, +including support for caching of results. +""" +import calendar +import datetime +import heapq +import itertools +import re +import sys +from functools import wraps +# For warning about deprecation of until and count +from warnings import warn + +from six import advance_iterator, integer_types + +from six.moves import _thread, range + +from ._common import weekday as weekdaybase + +try: + from math import gcd +except ImportError: + from fractions import gcd + +__all__ = ["rrule", "rruleset", "rrulestr", + "YEARLY", "MONTHLY", "WEEKLY", "DAILY", + "HOURLY", "MINUTELY", "SECONDLY", + "MO", "TU", "WE", "TH", "FR", "SA", "SU"] + +# Every mask is 7 days longer to handle cross-year weekly periods. +M366MASK = tuple([1]*31+[2]*29+[3]*31+[4]*30+[5]*31+[6]*30 + + [7]*31+[8]*31+[9]*30+[10]*31+[11]*30+[12]*31+[1]*7) +M365MASK = list(M366MASK) +M29, M30, M31 = list(range(1, 30)), list(range(1, 31)), list(range(1, 32)) +MDAY366MASK = tuple(M31+M29+M31+M30+M31+M30+M31+M31+M30+M31+M30+M31+M31[:7]) +MDAY365MASK = list(MDAY366MASK) +M29, M30, M31 = list(range(-29, 0)), list(range(-30, 0)), list(range(-31, 0)) +NMDAY366MASK = tuple(M31+M29+M31+M30+M31+M30+M31+M31+M30+M31+M30+M31+M31[:7]) +NMDAY365MASK = list(NMDAY366MASK) +M366RANGE = (0, 31, 60, 91, 121, 152, 182, 213, 244, 274, 305, 335, 366) +M365RANGE = (0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334, 365) +WDAYMASK = [0, 1, 2, 3, 4, 5, 6]*55 +del M29, M30, M31, M365MASK[59], MDAY365MASK[59], NMDAY365MASK[31] +MDAY365MASK = tuple(MDAY365MASK) +M365MASK = tuple(M365MASK) + +FREQNAMES = ['YEARLY', 'MONTHLY', 'WEEKLY', 'DAILY', 'HOURLY', 'MINUTELY', 'SECONDLY'] + +(YEARLY, + MONTHLY, + WEEKLY, + DAILY, + HOURLY, + MINUTELY, + SECONDLY) = list(range(7)) + +# Imported on demand. +easter = None +parser = None + + +class weekday(weekdaybase): + """ + This version of weekday does not allow n = 0. + """ + def __init__(self, wkday, n=None): + if n == 0: + raise ValueError("Can't create weekday with n==0") + + super(weekday, self).__init__(wkday, n) + + +MO, TU, WE, TH, FR, SA, SU = weekdays = tuple(weekday(x) for x in range(7)) + + +def _invalidates_cache(f): + """ + Decorator for rruleset methods which may invalidate the + cached length. + """ + @wraps(f) + def inner_func(self, *args, **kwargs): + rv = f(self, *args, **kwargs) + self._invalidate_cache() + return rv + + return inner_func + + +class rrulebase(object): + def __init__(self, cache=False): + if cache: + self._cache = [] + self._cache_lock = _thread.allocate_lock() + self._invalidate_cache() + else: + self._cache = None + self._cache_complete = False + self._len = None + + def __iter__(self): + if self._cache_complete: + return iter(self._cache) + elif self._cache is None: + return self._iter() + else: + return self._iter_cached() + + def _invalidate_cache(self): + if self._cache is not None: + self._cache = [] + self._cache_complete = False + self._cache_gen = self._iter() + + if self._cache_lock.locked(): + self._cache_lock.release() + + self._len = None + + def _iter_cached(self): + i = 0 + gen = self._cache_gen + cache = self._cache + acquire = self._cache_lock.acquire + release = self._cache_lock.release + while gen: + if i == len(cache): + acquire() + if self._cache_complete: + break + try: + for j in range(10): + cache.append(advance_iterator(gen)) + except StopIteration: + self._cache_gen = gen = None + self._cache_complete = True + break + release() + yield cache[i] + i += 1 + while i < self._len: + yield cache[i] + i += 1 + + def __getitem__(self, item): + if self._cache_complete: + return self._cache[item] + elif isinstance(item, slice): + if item.step and item.step < 0: + return list(iter(self))[item] + else: + return list(itertools.islice(self, + item.start or 0, + item.stop or sys.maxsize, + item.step or 1)) + elif item >= 0: + gen = iter(self) + try: + for i in range(item+1): + res = advance_iterator(gen) + except StopIteration: + raise IndexError + return res + else: + return list(iter(self))[item] + + def __contains__(self, item): + if self._cache_complete: + return item in self._cache + else: + for i in self: + if i == item: + return True + elif i > item: + return False + return False + + # __len__() introduces a large performance penalty. + def count(self): + """ Returns the number of recurrences in this set. It will have go + through the whole recurrence, if this hasn't been done before. """ + if self._len is None: + for x in self: + pass + return self._len + + def before(self, dt, inc=False): + """ Returns the last recurrence before the given datetime instance. The + inc keyword defines what happens if dt is an occurrence. With + inc=True, if dt itself is an occurrence, it will be returned. """ + if self._cache_complete: + gen = self._cache + else: + gen = self + last = None + if inc: + for i in gen: + if i > dt: + break + last = i + else: + for i in gen: + if i >= dt: + break + last = i + return last + + def after(self, dt, inc=False): + """ Returns the first recurrence after the given datetime instance. The + inc keyword defines what happens if dt is an occurrence. With + inc=True, if dt itself is an occurrence, it will be returned. """ + if self._cache_complete: + gen = self._cache + else: + gen = self + if inc: + for i in gen: + if i >= dt: + return i + else: + for i in gen: + if i > dt: + return i + return None + + def xafter(self, dt, count=None, inc=False): + """ + Generator which yields up to `count` recurrences after the given + datetime instance, equivalent to `after`. + + :param dt: + The datetime at which to start generating recurrences. + + :param count: + The maximum number of recurrences to generate. If `None` (default), + dates are generated until the recurrence rule is exhausted. + + :param inc: + If `dt` is an instance of the rule and `inc` is `True`, it is + included in the output. + + :yields: Yields a sequence of `datetime` objects. + """ + + if self._cache_complete: + gen = self._cache + else: + gen = self + + # Select the comparison function + if inc: + comp = lambda dc, dtc: dc >= dtc + else: + comp = lambda dc, dtc: dc > dtc + + # Generate dates + n = 0 + for d in gen: + if comp(d, dt): + if count is not None: + n += 1 + if n > count: + break + + yield d + + def between(self, after, before, inc=False, count=1): + """ Returns all the occurrences of the rrule between after and before. + The inc keyword defines what happens if after and/or before are + themselves occurrences. With inc=True, they will be included in the + list, if they are found in the recurrence set. """ + if self._cache_complete: + gen = self._cache + else: + gen = self + started = False + l = [] + if inc: + for i in gen: + if i > before: + break + elif not started: + if i >= after: + started = True + l.append(i) + else: + l.append(i) + else: + for i in gen: + if i >= before: + break + elif not started: + if i > after: + started = True + l.append(i) + else: + l.append(i) + return l + + +class rrule(rrulebase): + """ + That's the base of the rrule operation. It accepts all the keywords + defined in the RFC as its constructor parameters (except byday, + which was renamed to byweekday) and more. The constructor prototype is:: + + rrule(freq) + + Where freq must be one of YEARLY, MONTHLY, WEEKLY, DAILY, HOURLY, MINUTELY, + or SECONDLY. + + .. note:: + Per RFC section 3.3.10, recurrence instances falling on invalid dates + and times are ignored rather than coerced: + + Recurrence rules may generate recurrence instances with an invalid + date (e.g., February 30) or nonexistent local time (e.g., 1:30 AM + on a day where the local time is moved forward by an hour at 1:00 + AM). Such recurrence instances MUST be ignored and MUST NOT be + counted as part of the recurrence set. + + This can lead to possibly surprising behavior when, for example, the + start date occurs at the end of the month: + + >>> from dateutil.rrule import rrule, MONTHLY + >>> from datetime import datetime + >>> start_date = datetime(2014, 12, 31) + >>> list(rrule(freq=MONTHLY, count=4, dtstart=start_date)) + ... # doctest: +NORMALIZE_WHITESPACE + [datetime.datetime(2014, 12, 31, 0, 0), + datetime.datetime(2015, 1, 31, 0, 0), + datetime.datetime(2015, 3, 31, 0, 0), + datetime.datetime(2015, 5, 31, 0, 0)] + + Additionally, it supports the following keyword arguments: + + :param dtstart: + The recurrence start. Besides being the base for the recurrence, + missing parameters in the final recurrence instances will also be + extracted from this date. If not given, datetime.now() will be used + instead. + :param interval: + The interval between each freq iteration. For example, when using + YEARLY, an interval of 2 means once every two years, but with HOURLY, + it means once every two hours. The default interval is 1. + :param wkst: + The week start day. Must be one of the MO, TU, WE constants, or an + integer, specifying the first day of the week. This will affect + recurrences based on weekly periods. The default week start is got + from calendar.firstweekday(), and may be modified by + calendar.setfirstweekday(). + :param count: + If given, this determines how many occurrences will be generated. + + .. note:: + As of version 2.5.0, the use of the keyword ``until`` in conjunction + with ``count`` is deprecated, to make sure ``dateutil`` is fully + compliant with `RFC-5545 Sec. 3.3.10 <https://tools.ietf.org/ + html/rfc5545#section-3.3.10>`_. Therefore, ``until`` and ``count`` + **must not** occur in the same call to ``rrule``. + :param until: + If given, this must be a datetime instance specifying the upper-bound + limit of the recurrence. The last recurrence in the rule is the greatest + datetime that is less than or equal to the value specified in the + ``until`` parameter. + + .. note:: + As of version 2.5.0, the use of the keyword ``until`` in conjunction + with ``count`` is deprecated, to make sure ``dateutil`` is fully + compliant with `RFC-5545 Sec. 3.3.10 <https://tools.ietf.org/ + html/rfc5545#section-3.3.10>`_. Therefore, ``until`` and ``count`` + **must not** occur in the same call to ``rrule``. + :param bysetpos: + If given, it must be either an integer, or a sequence of integers, + positive or negative. Each given integer will specify an occurrence + number, corresponding to the nth occurrence of the rule inside the + frequency period. For example, a bysetpos of -1 if combined with a + MONTHLY frequency, and a byweekday of (MO, TU, WE, TH, FR), will + result in the last work day of every month. + :param bymonth: + If given, it must be either an integer, or a sequence of integers, + meaning the months to apply the recurrence to. + :param bymonthday: + If given, it must be either an integer, or a sequence of integers, + meaning the month days to apply the recurrence to. + :param byyearday: + If given, it must be either an integer, or a sequence of integers, + meaning the year days to apply the recurrence to. + :param byeaster: + If given, it must be either an integer, or a sequence of integers, + positive or negative. Each integer will define an offset from the + Easter Sunday. Passing the offset 0 to byeaster will yield the Easter + Sunday itself. This is an extension to the RFC specification. + :param byweekno: + If given, it must be either an integer, or a sequence of integers, + meaning the week numbers to apply the recurrence to. Week numbers + have the meaning described in ISO8601, that is, the first week of + the year is that containing at least four days of the new year. + :param byweekday: + If given, it must be either an integer (0 == MO), a sequence of + integers, one of the weekday constants (MO, TU, etc), or a sequence + of these constants. When given, these variables will define the + weekdays where the recurrence will be applied. It's also possible to + use an argument n for the weekday instances, which will mean the nth + occurrence of this weekday in the period. For example, with MONTHLY, + or with YEARLY and BYMONTH, using FR(+1) in byweekday will specify the + first friday of the month where the recurrence happens. Notice that in + the RFC documentation, this is specified as BYDAY, but was renamed to + avoid the ambiguity of that keyword. + :param byhour: + If given, it must be either an integer, or a sequence of integers, + meaning the hours to apply the recurrence to. + :param byminute: + If given, it must be either an integer, or a sequence of integers, + meaning the minutes to apply the recurrence to. + :param bysecond: + If given, it must be either an integer, or a sequence of integers, + meaning the seconds to apply the recurrence to. + :param cache: + If given, it must be a boolean value specifying to enable or disable + caching of results. If you will use the same rrule instance multiple + times, enabling caching will improve the performance considerably. + """ + def __init__(self, freq, dtstart=None, + interval=1, wkst=None, count=None, until=None, bysetpos=None, + bymonth=None, bymonthday=None, byyearday=None, byeaster=None, + byweekno=None, byweekday=None, + byhour=None, byminute=None, bysecond=None, + cache=False): + super(rrule, self).__init__(cache) + global easter + if not dtstart: + if until and until.tzinfo: + dtstart = datetime.datetime.now(tz=until.tzinfo).replace(microsecond=0) + else: + dtstart = datetime.datetime.now().replace(microsecond=0) + elif not isinstance(dtstart, datetime.datetime): + dtstart = datetime.datetime.fromordinal(dtstart.toordinal()) + else: + dtstart = dtstart.replace(microsecond=0) + self._dtstart = dtstart + self._tzinfo = dtstart.tzinfo + self._freq = freq + self._interval = interval + self._count = count + + # Cache the original byxxx rules, if they are provided, as the _byxxx + # attributes do not necessarily map to the inputs, and this can be + # a problem in generating the strings. Only store things if they've + # been supplied (the string retrieval will just use .get()) + self._original_rule = {} + + if until and not isinstance(until, datetime.datetime): + until = datetime.datetime.fromordinal(until.toordinal()) + self._until = until + + if self._dtstart and self._until: + if (self._dtstart.tzinfo is not None) != (self._until.tzinfo is not None): + # According to RFC5545 Section 3.3.10: + # https://tools.ietf.org/html/rfc5545#section-3.3.10 + # + # > If the "DTSTART" property is specified as a date with UTC + # > time or a date with local time and time zone reference, + # > then the UNTIL rule part MUST be specified as a date with + # > UTC time. + raise ValueError( + 'RRULE UNTIL values must be specified in UTC when DTSTART ' + 'is timezone-aware' + ) + + if count is not None and until: + warn("Using both 'count' and 'until' is inconsistent with RFC 5545" + " and has been deprecated in dateutil. Future versions will " + "raise an error.", DeprecationWarning) + + if wkst is None: + self._wkst = calendar.firstweekday() + elif isinstance(wkst, integer_types): + self._wkst = wkst + else: + self._wkst = wkst.weekday + + if bysetpos is None: + self._bysetpos = None + elif isinstance(bysetpos, integer_types): + if bysetpos == 0 or not (-366 <= bysetpos <= 366): + raise ValueError("bysetpos must be between 1 and 366, " + "or between -366 and -1") + self._bysetpos = (bysetpos,) + else: + self._bysetpos = tuple(bysetpos) + for pos in self._bysetpos: + if pos == 0 or not (-366 <= pos <= 366): + raise ValueError("bysetpos must be between 1 and 366, " + "or between -366 and -1") + + if self._bysetpos: + self._original_rule['bysetpos'] = self._bysetpos + + if (byweekno is None and byyearday is None and bymonthday is None and + byweekday is None and byeaster is None): + if freq == YEARLY: + if bymonth is None: + bymonth = dtstart.month + self._original_rule['bymonth'] = None + bymonthday = dtstart.day + self._original_rule['bymonthday'] = None + elif freq == MONTHLY: + bymonthday = dtstart.day + self._original_rule['bymonthday'] = None + elif freq == WEEKLY: + byweekday = dtstart.weekday() + self._original_rule['byweekday'] = None + + # bymonth + if bymonth is None: + self._bymonth = None + else: + if isinstance(bymonth, integer_types): + bymonth = (bymonth,) + + self._bymonth = tuple(sorted(set(bymonth))) + + if 'bymonth' not in self._original_rule: + self._original_rule['bymonth'] = self._bymonth + + # byyearday + if byyearday is None: + self._byyearday = None + else: + if isinstance(byyearday, integer_types): + byyearday = (byyearday,) + + self._byyearday = tuple(sorted(set(byyearday))) + self._original_rule['byyearday'] = self._byyearday + + # byeaster + if byeaster is not None: + if not easter: + from dateutil import easter + if isinstance(byeaster, integer_types): + self._byeaster = (byeaster,) + else: + self._byeaster = tuple(sorted(byeaster)) + + self._original_rule['byeaster'] = self._byeaster + else: + self._byeaster = None + + # bymonthday + if bymonthday is None: + self._bymonthday = () + self._bynmonthday = () + else: + if isinstance(bymonthday, integer_types): + bymonthday = (bymonthday,) + + bymonthday = set(bymonthday) # Ensure it's unique + + self._bymonthday = tuple(sorted(x for x in bymonthday if x > 0)) + self._bynmonthday = tuple(sorted(x for x in bymonthday if x < 0)) + + # Storing positive numbers first, then negative numbers + if 'bymonthday' not in self._original_rule: + self._original_rule['bymonthday'] = tuple( + itertools.chain(self._bymonthday, self._bynmonthday)) + + # byweekno + if byweekno is None: + self._byweekno = None + else: + if isinstance(byweekno, integer_types): + byweekno = (byweekno,) + + self._byweekno = tuple(sorted(set(byweekno))) + + self._original_rule['byweekno'] = self._byweekno + + # byweekday / bynweekday + if byweekday is None: + self._byweekday = None + self._bynweekday = None + else: + # If it's one of the valid non-sequence types, convert to a + # single-element sequence before the iterator that builds the + # byweekday set. + if isinstance(byweekday, integer_types) or hasattr(byweekday, "n"): + byweekday = (byweekday,) + + self._byweekday = set() + self._bynweekday = set() + for wday in byweekday: + if isinstance(wday, integer_types): + self._byweekday.add(wday) + elif not wday.n or freq > MONTHLY: + self._byweekday.add(wday.weekday) + else: + self._bynweekday.add((wday.weekday, wday.n)) + + if not self._byweekday: + self._byweekday = None + elif not self._bynweekday: + self._bynweekday = None + + if self._byweekday is not None: + self._byweekday = tuple(sorted(self._byweekday)) + orig_byweekday = [weekday(x) for x in self._byweekday] + else: + orig_byweekday = () + + if self._bynweekday is not None: + self._bynweekday = tuple(sorted(self._bynweekday)) + orig_bynweekday = [weekday(*x) for x in self._bynweekday] + else: + orig_bynweekday = () + + if 'byweekday' not in self._original_rule: + self._original_rule['byweekday'] = tuple(itertools.chain( + orig_byweekday, orig_bynweekday)) + + # byhour + if byhour is None: + if freq < HOURLY: + self._byhour = {dtstart.hour} + else: + self._byhour = None + else: + if isinstance(byhour, integer_types): + byhour = (byhour,) + + if freq == HOURLY: + self._byhour = self.__construct_byset(start=dtstart.hour, + byxxx=byhour, + base=24) + else: + self._byhour = set(byhour) + + self._byhour = tuple(sorted(self._byhour)) + self._original_rule['byhour'] = self._byhour + + # byminute + if byminute is None: + if freq < MINUTELY: + self._byminute = {dtstart.minute} + else: + self._byminute = None + else: + if isinstance(byminute, integer_types): + byminute = (byminute,) + + if freq == MINUTELY: + self._byminute = self.__construct_byset(start=dtstart.minute, + byxxx=byminute, + base=60) + else: + self._byminute = set(byminute) + + self._byminute = tuple(sorted(self._byminute)) + self._original_rule['byminute'] = self._byminute + + # bysecond + if bysecond is None: + if freq < SECONDLY: + self._bysecond = ((dtstart.second,)) + else: + self._bysecond = None + else: + if isinstance(bysecond, integer_types): + bysecond = (bysecond,) + + self._bysecond = set(bysecond) + + if freq == SECONDLY: + self._bysecond = self.__construct_byset(start=dtstart.second, + byxxx=bysecond, + base=60) + else: + self._bysecond = set(bysecond) + + self._bysecond = tuple(sorted(self._bysecond)) + self._original_rule['bysecond'] = self._bysecond + + if self._freq >= HOURLY: + self._timeset = None + else: + self._timeset = [] + for hour in self._byhour: + for minute in self._byminute: + for second in self._bysecond: + self._timeset.append( + datetime.time(hour, minute, second, + tzinfo=self._tzinfo)) + self._timeset.sort() + self._timeset = tuple(self._timeset) + + def __str__(self): + """ + Output a string that would generate this RRULE if passed to rrulestr. + This is mostly compatible with RFC5545, except for the + dateutil-specific extension BYEASTER. + """ + + output = [] + h, m, s = [None] * 3 + if self._dtstart: + output.append(self._dtstart.strftime('DTSTART:%Y%m%dT%H%M%S')) + h, m, s = self._dtstart.timetuple()[3:6] + + parts = ['FREQ=' + FREQNAMES[self._freq]] + if self._interval != 1: + parts.append('INTERVAL=' + str(self._interval)) + + if self._wkst: + parts.append('WKST=' + repr(weekday(self._wkst))[0:2]) + + if self._count is not None: + parts.append('COUNT=' + str(self._count)) + + if self._until: + parts.append(self._until.strftime('UNTIL=%Y%m%dT%H%M%S')) + + if self._original_rule.get('byweekday') is not None: + # The str() method on weekday objects doesn't generate + # RFC5545-compliant strings, so we should modify that. + original_rule = dict(self._original_rule) + wday_strings = [] + for wday in original_rule['byweekday']: + if wday.n: + wday_strings.append('{n:+d}{wday}'.format( + n=wday.n, + wday=repr(wday)[0:2])) + else: + wday_strings.append(repr(wday)) + + original_rule['byweekday'] = wday_strings + else: + original_rule = self._original_rule + + partfmt = '{name}={vals}' + for name, key in [('BYSETPOS', 'bysetpos'), + ('BYMONTH', 'bymonth'), + ('BYMONTHDAY', 'bymonthday'), + ('BYYEARDAY', 'byyearday'), + ('BYWEEKNO', 'byweekno'), + ('BYDAY', 'byweekday'), + ('BYHOUR', 'byhour'), + ('BYMINUTE', 'byminute'), + ('BYSECOND', 'bysecond'), + ('BYEASTER', 'byeaster')]: + value = original_rule.get(key) + if value: + parts.append(partfmt.format(name=name, vals=(','.join(str(v) + for v in value)))) + + output.append('RRULE:' + ';'.join(parts)) + return '\n'.join(output) + + def replace(self, **kwargs): + """Return new rrule with same attributes except for those attributes given new + values by whichever keyword arguments are specified.""" + new_kwargs = {"interval": self._interval, + "count": self._count, + "dtstart": self._dtstart, + "freq": self._freq, + "until": self._until, + "wkst": self._wkst, + "cache": False if self._cache is None else True } + new_kwargs.update(self._original_rule) + new_kwargs.update(kwargs) + return rrule(**new_kwargs) + + def _iter(self): + year, month, day, hour, minute, second, weekday, yearday, _ = \ + self._dtstart.timetuple() + + # Some local variables to speed things up a bit + freq = self._freq + interval = self._interval + wkst = self._wkst + until = self._until + bymonth = self._bymonth + byweekno = self._byweekno + byyearday = self._byyearday + byweekday = self._byweekday + byeaster = self._byeaster + bymonthday = self._bymonthday + bynmonthday = self._bynmonthday + bysetpos = self._bysetpos + byhour = self._byhour + byminute = self._byminute + bysecond = self._bysecond + + ii = _iterinfo(self) + ii.rebuild(year, month) + + getdayset = {YEARLY: ii.ydayset, + MONTHLY: ii.mdayset, + WEEKLY: ii.wdayset, + DAILY: ii.ddayset, + HOURLY: ii.ddayset, + MINUTELY: ii.ddayset, + SECONDLY: ii.ddayset}[freq] + + if freq < HOURLY: + timeset = self._timeset + else: + gettimeset = {HOURLY: ii.htimeset, + MINUTELY: ii.mtimeset, + SECONDLY: ii.stimeset}[freq] + if ((freq >= HOURLY and + self._byhour and hour not in self._byhour) or + (freq >= MINUTELY and + self._byminute and minute not in self._byminute) or + (freq >= SECONDLY and + self._bysecond and second not in self._bysecond)): + timeset = () + else: + timeset = gettimeset(hour, minute, second) + + total = 0 + count = self._count + while True: + # Get dayset with the right frequency + dayset, start, end = getdayset(year, month, day) + + # Do the "hard" work ;-) + filtered = False + for i in dayset[start:end]: + if ((bymonth and ii.mmask[i] not in bymonth) or + (byweekno and not ii.wnomask[i]) or + (byweekday and ii.wdaymask[i] not in byweekday) or + (ii.nwdaymask and not ii.nwdaymask[i]) or + (byeaster and not ii.eastermask[i]) or + ((bymonthday or bynmonthday) and + ii.mdaymask[i] not in bymonthday and + ii.nmdaymask[i] not in bynmonthday) or + (byyearday and + ((i < ii.yearlen and i+1 not in byyearday and + -ii.yearlen+i not in byyearday) or + (i >= ii.yearlen and i+1-ii.yearlen not in byyearday and + -ii.nextyearlen+i-ii.yearlen not in byyearday)))): + dayset[i] = None + filtered = True + + # Output results + if bysetpos and timeset: + poslist = [] + for pos in bysetpos: + if pos < 0: + daypos, timepos = divmod(pos, len(timeset)) + else: + daypos, timepos = divmod(pos-1, len(timeset)) + try: + i = [x for x in dayset[start:end] + if x is not None][daypos] + time = timeset[timepos] + except IndexError: + pass + else: + date = datetime.date.fromordinal(ii.yearordinal+i) + res = datetime.datetime.combine(date, time) + if res not in poslist: + poslist.append(res) + poslist.sort() + for res in poslist: + if until and res > until: + self._len = total + return + elif res >= self._dtstart: + if count is not None: + count -= 1 + if count < 0: + self._len = total + return + total += 1 + yield res + else: + for i in dayset[start:end]: + if i is not None: + date = datetime.date.fromordinal(ii.yearordinal + i) + for time in timeset: + res = datetime.datetime.combine(date, time) + if until and res > until: + self._len = total + return + elif res >= self._dtstart: + if count is not None: + count -= 1 + if count < 0: + self._len = total + return + + total += 1 + yield res + + # Handle frequency and interval + fixday = False + if freq == YEARLY: + year += interval + if year > datetime.MAXYEAR: + self._len = total + return + ii.rebuild(year, month) + elif freq == MONTHLY: + month += interval + if month > 12: + div, mod = divmod(month, 12) + month = mod + year += div + if month == 0: + month = 12 + year -= 1 + if year > datetime.MAXYEAR: + self._len = total + return + ii.rebuild(year, month) + elif freq == WEEKLY: + if wkst > weekday: + day += -(weekday+1+(6-wkst))+self._interval*7 + else: + day += -(weekday-wkst)+self._interval*7 + weekday = wkst + fixday = True + elif freq == DAILY: + day += interval + fixday = True + elif freq == HOURLY: + if filtered: + # Jump to one iteration before next day + hour += ((23-hour)//interval)*interval + + if byhour: + ndays, hour = self.__mod_distance(value=hour, + byxxx=self._byhour, + base=24) + else: + ndays, hour = divmod(hour+interval, 24) + + if ndays: + day += ndays + fixday = True + + timeset = gettimeset(hour, minute, second) + elif freq == MINUTELY: + if filtered: + # Jump to one iteration before next day + minute += ((1439-(hour*60+minute))//interval)*interval + + valid = False + rep_rate = (24*60) + for j in range(rep_rate // gcd(interval, rep_rate)): + if byminute: + nhours, minute = \ + self.__mod_distance(value=minute, + byxxx=self._byminute, + base=60) + else: + nhours, minute = divmod(minute+interval, 60) + + div, hour = divmod(hour+nhours, 24) + if div: + day += div + fixday = True + filtered = False + + if not byhour or hour in byhour: + valid = True + break + + if not valid: + raise ValueError('Invalid combination of interval and ' + + 'byhour resulting in empty rule.') + + timeset = gettimeset(hour, minute, second) + elif freq == SECONDLY: + if filtered: + # Jump to one iteration before next day + second += (((86399 - (hour * 3600 + minute * 60 + second)) + // interval) * interval) + + rep_rate = (24 * 3600) + valid = False + for j in range(0, rep_rate // gcd(interval, rep_rate)): + if bysecond: + nminutes, second = \ + self.__mod_distance(value=second, + byxxx=self._bysecond, + base=60) + else: + nminutes, second = divmod(second+interval, 60) + + div, minute = divmod(minute+nminutes, 60) + if div: + hour += div + div, hour = divmod(hour, 24) + if div: + day += div + fixday = True + + if ((not byhour or hour in byhour) and + (not byminute or minute in byminute) and + (not bysecond or second in bysecond)): + valid = True + break + + if not valid: + raise ValueError('Invalid combination of interval, ' + + 'byhour and byminute resulting in empty' + + ' rule.') + + timeset = gettimeset(hour, minute, second) + + if fixday and day > 28: + daysinmonth = calendar.monthrange(year, month)[1] + if day > daysinmonth: + while day > daysinmonth: + day -= daysinmonth + month += 1 + if month == 13: + month = 1 + year += 1 + if year > datetime.MAXYEAR: + self._len = total + return + daysinmonth = calendar.monthrange(year, month)[1] + ii.rebuild(year, month) + + def __construct_byset(self, start, byxxx, base): + """ + If a `BYXXX` sequence is passed to the constructor at the same level as + `FREQ` (e.g. `FREQ=HOURLY,BYHOUR={2,4,7},INTERVAL=3`), there are some + specifications which cannot be reached given some starting conditions. + + This occurs whenever the interval is not coprime with the base of a + given unit and the difference between the starting position and the + ending position is not coprime with the greatest common denominator + between the interval and the base. For example, with a FREQ of hourly + starting at 17:00 and an interval of 4, the only valid values for + BYHOUR would be {21, 1, 5, 9, 13, 17}, because 4 and 24 are not + coprime. + + :param start: + Specifies the starting position. + :param byxxx: + An iterable containing the list of allowed values. + :param base: + The largest allowable value for the specified frequency (e.g. + 24 hours, 60 minutes). + + This does not preserve the type of the iterable, returning a set, since + the values should be unique and the order is irrelevant, this will + speed up later lookups. + + In the event of an empty set, raises a :exception:`ValueError`, as this + results in an empty rrule. + """ + + cset = set() + + # Support a single byxxx value. + if isinstance(byxxx, integer_types): + byxxx = (byxxx, ) + + for num in byxxx: + i_gcd = gcd(self._interval, base) + # Use divmod rather than % because we need to wrap negative nums. + if i_gcd == 1 or divmod(num - start, i_gcd)[1] == 0: + cset.add(num) + + if len(cset) == 0: + raise ValueError("Invalid rrule byxxx generates an empty set.") + + return cset + + def __mod_distance(self, value, byxxx, base): + """ + Calculates the next value in a sequence where the `FREQ` parameter is + specified along with a `BYXXX` parameter at the same "level" + (e.g. `HOURLY` specified with `BYHOUR`). + + :param value: + The old value of the component. + :param byxxx: + The `BYXXX` set, which should have been generated by + `rrule._construct_byset`, or something else which checks that a + valid rule is present. + :param base: + The largest allowable value for the specified frequency (e.g. + 24 hours, 60 minutes). + + If a valid value is not found after `base` iterations (the maximum + number before the sequence would start to repeat), this raises a + :exception:`ValueError`, as no valid values were found. + + This returns a tuple of `divmod(n*interval, base)`, where `n` is the + smallest number of `interval` repetitions until the next specified + value in `byxxx` is found. + """ + accumulator = 0 + for ii in range(1, base + 1): + # Using divmod() over % to account for negative intervals + div, value = divmod(value + self._interval, base) + accumulator += div + if value in byxxx: + return (accumulator, value) + + +class _iterinfo(object): + __slots__ = ["rrule", "lastyear", "lastmonth", + "yearlen", "nextyearlen", "yearordinal", "yearweekday", + "mmask", "mrange", "mdaymask", "nmdaymask", + "wdaymask", "wnomask", "nwdaymask", "eastermask"] + + def __init__(self, rrule): + for attr in self.__slots__: + setattr(self, attr, None) + self.rrule = rrule + + def rebuild(self, year, month): + # Every mask is 7 days longer to handle cross-year weekly periods. + rr = self.rrule + if year != self.lastyear: + self.yearlen = 365 + calendar.isleap(year) + self.nextyearlen = 365 + calendar.isleap(year + 1) + firstyday = datetime.date(year, 1, 1) + self.yearordinal = firstyday.toordinal() + self.yearweekday = firstyday.weekday() + + wday = datetime.date(year, 1, 1).weekday() + if self.yearlen == 365: + self.mmask = M365MASK + self.mdaymask = MDAY365MASK + self.nmdaymask = NMDAY365MASK + self.wdaymask = WDAYMASK[wday:] + self.mrange = M365RANGE + else: + self.mmask = M366MASK + self.mdaymask = MDAY366MASK + self.nmdaymask = NMDAY366MASK + self.wdaymask = WDAYMASK[wday:] + self.mrange = M366RANGE + + if not rr._byweekno: + self.wnomask = None + else: + self.wnomask = [0]*(self.yearlen+7) + # no1wkst = firstwkst = self.wdaymask.index(rr._wkst) + no1wkst = firstwkst = (7-self.yearweekday+rr._wkst) % 7 + if no1wkst >= 4: + no1wkst = 0 + # Number of days in the year, plus the days we got + # from last year. + wyearlen = self.yearlen+(self.yearweekday-rr._wkst) % 7 + else: + # Number of days in the year, minus the days we + # left in last year. + wyearlen = self.yearlen-no1wkst + div, mod = divmod(wyearlen, 7) + numweeks = div+mod//4 + for n in rr._byweekno: + if n < 0: + n += numweeks+1 + if not (0 < n <= numweeks): + continue + if n > 1: + i = no1wkst+(n-1)*7 + if no1wkst != firstwkst: + i -= 7-firstwkst + else: + i = no1wkst + for j in range(7): + self.wnomask[i] = 1 + i += 1 + if self.wdaymask[i] == rr._wkst: + break + if 1 in rr._byweekno: + # Check week number 1 of next year as well + # TODO: Check -numweeks for next year. + i = no1wkst+numweeks*7 + if no1wkst != firstwkst: + i -= 7-firstwkst + if i < self.yearlen: + # If week starts in next year, we + # don't care about it. + for j in range(7): + self.wnomask[i] = 1 + i += 1 + if self.wdaymask[i] == rr._wkst: + break + if no1wkst: + # Check last week number of last year as + # well. If no1wkst is 0, either the year + # started on week start, or week number 1 + # got days from last year, so there are no + # days from last year's last week number in + # this year. + if -1 not in rr._byweekno: + lyearweekday = datetime.date(year-1, 1, 1).weekday() + lno1wkst = (7-lyearweekday+rr._wkst) % 7 + lyearlen = 365+calendar.isleap(year-1) + if lno1wkst >= 4: + lno1wkst = 0 + lnumweeks = 52+(lyearlen + + (lyearweekday-rr._wkst) % 7) % 7//4 + else: + lnumweeks = 52+(self.yearlen-no1wkst) % 7//4 + else: + lnumweeks = -1 + if lnumweeks in rr._byweekno: + for i in range(no1wkst): + self.wnomask[i] = 1 + + if (rr._bynweekday and (month != self.lastmonth or + year != self.lastyear)): + ranges = [] + if rr._freq == YEARLY: + if rr._bymonth: + for month in rr._bymonth: + ranges.append(self.mrange[month-1:month+1]) + else: + ranges = [(0, self.yearlen)] + elif rr._freq == MONTHLY: + ranges = [self.mrange[month-1:month+1]] + if ranges: + # Weekly frequency won't get here, so we may not + # care about cross-year weekly periods. + self.nwdaymask = [0]*self.yearlen + for first, last in ranges: + last -= 1 + for wday, n in rr._bynweekday: + if n < 0: + i = last+(n+1)*7 + i -= (self.wdaymask[i]-wday) % 7 + else: + i = first+(n-1)*7 + i += (7-self.wdaymask[i]+wday) % 7 + if first <= i <= last: + self.nwdaymask[i] = 1 + + if rr._byeaster: + self.eastermask = [0]*(self.yearlen+7) + eyday = easter.easter(year).toordinal()-self.yearordinal + for offset in rr._byeaster: + self.eastermask[eyday+offset] = 1 + + self.lastyear = year + self.lastmonth = month + + def ydayset(self, year, month, day): + return list(range(self.yearlen)), 0, self.yearlen + + def mdayset(self, year, month, day): + dset = [None]*self.yearlen + start, end = self.mrange[month-1:month+1] + for i in range(start, end): + dset[i] = i + return dset, start, end + + def wdayset(self, year, month, day): + # We need to handle cross-year weeks here. + dset = [None]*(self.yearlen+7) + i = datetime.date(year, month, day).toordinal()-self.yearordinal + start = i + for j in range(7): + dset[i] = i + i += 1 + # if (not (0 <= i < self.yearlen) or + # self.wdaymask[i] == self.rrule._wkst): + # This will cross the year boundary, if necessary. + if self.wdaymask[i] == self.rrule._wkst: + break + return dset, start, i + + def ddayset(self, year, month, day): + dset = [None] * self.yearlen + i = datetime.date(year, month, day).toordinal() - self.yearordinal + dset[i] = i + return dset, i, i + 1 + + def htimeset(self, hour, minute, second): + tset = [] + rr = self.rrule + for minute in rr._byminute: + for second in rr._bysecond: + tset.append(datetime.time(hour, minute, second, + tzinfo=rr._tzinfo)) + tset.sort() + return tset + + def mtimeset(self, hour, minute, second): + tset = [] + rr = self.rrule + for second in rr._bysecond: + tset.append(datetime.time(hour, minute, second, tzinfo=rr._tzinfo)) + tset.sort() + return tset + + def stimeset(self, hour, minute, second): + return (datetime.time(hour, minute, second, + tzinfo=self.rrule._tzinfo),) + + +class rruleset(rrulebase): + """ The rruleset type allows more complex recurrence setups, mixing + multiple rules, dates, exclusion rules, and exclusion dates. The type + constructor takes the following keyword arguments: + + :param cache: If True, caching of results will be enabled, improving + performance of multiple queries considerably. """ + + class _genitem(object): + def __init__(self, genlist, gen): + try: + self.dt = advance_iterator(gen) + genlist.append(self) + except StopIteration: + pass + self.genlist = genlist + self.gen = gen + + def __next__(self): + try: + self.dt = advance_iterator(self.gen) + except StopIteration: + if self.genlist[0] is self: + heapq.heappop(self.genlist) + else: + self.genlist.remove(self) + heapq.heapify(self.genlist) + + next = __next__ + + def __lt__(self, other): + return self.dt < other.dt + + def __gt__(self, other): + return self.dt > other.dt + + def __eq__(self, other): + return self.dt == other.dt + + def __ne__(self, other): + return self.dt != other.dt + + def __init__(self, cache=False): + super(rruleset, self).__init__(cache) + self._rrule = [] + self._rdate = [] + self._exrule = [] + self._exdate = [] + + @_invalidates_cache + def rrule(self, rrule): + """ Include the given :py:class:`rrule` instance in the recurrence set + generation. """ + self._rrule.append(rrule) + + @_invalidates_cache + def rdate(self, rdate): + """ Include the given :py:class:`datetime` instance in the recurrence + set generation. """ + self._rdate.append(rdate) + + @_invalidates_cache + def exrule(self, exrule): + """ Include the given rrule instance in the recurrence set exclusion + list. Dates which are part of the given recurrence rules will not + be generated, even if some inclusive rrule or rdate matches them. + """ + self._exrule.append(exrule) + + @_invalidates_cache + def exdate(self, exdate): + """ Include the given datetime instance in the recurrence set + exclusion list. Dates included that way will not be generated, + even if some inclusive rrule or rdate matches them. """ + self._exdate.append(exdate) + + def _iter(self): + rlist = [] + self._rdate.sort() + self._genitem(rlist, iter(self._rdate)) + for gen in [iter(x) for x in self._rrule]: + self._genitem(rlist, gen) + exlist = [] + self._exdate.sort() + self._genitem(exlist, iter(self._exdate)) + for gen in [iter(x) for x in self._exrule]: + self._genitem(exlist, gen) + lastdt = None + total = 0 + heapq.heapify(rlist) + heapq.heapify(exlist) + while rlist: + ritem = rlist[0] + if not lastdt or lastdt != ritem.dt: + while exlist and exlist[0] < ritem: + exitem = exlist[0] + advance_iterator(exitem) + if exlist and exlist[0] is exitem: + heapq.heapreplace(exlist, exitem) + if not exlist or ritem != exlist[0]: + total += 1 + yield ritem.dt + lastdt = ritem.dt + advance_iterator(ritem) + if rlist and rlist[0] is ritem: + heapq.heapreplace(rlist, ritem) + self._len = total + + + + +class _rrulestr(object): + """ Parses a string representation of a recurrence rule or set of + recurrence rules. + + :param s: + Required, a string defining one or more recurrence rules. + + :param dtstart: + If given, used as the default recurrence start if not specified in the + rule string. + + :param cache: + If set ``True`` caching of results will be enabled, improving + performance of multiple queries considerably. + + :param unfold: + If set ``True`` indicates that a rule string is split over more + than one line and should be joined before processing. + + :param forceset: + If set ``True`` forces a :class:`dateutil.rrule.rruleset` to + be returned. + + :param compatible: + If set ``True`` forces ``unfold`` and ``forceset`` to be ``True``. + + :param ignoretz: + If set ``True``, time zones in parsed strings are ignored and a naive + :class:`datetime.datetime` object is returned. + + :param tzids: + If given, a callable or mapping used to retrieve a + :class:`datetime.tzinfo` from a string representation. + Defaults to :func:`dateutil.tz.gettz`. + + :param tzinfos: + Additional time zone names / aliases which may be present in a string + representation. See :func:`dateutil.parser.parse` for more + information. + + :return: + Returns a :class:`dateutil.rrule.rruleset` or + :class:`dateutil.rrule.rrule` + """ + + _freq_map = {"YEARLY": YEARLY, + "MONTHLY": MONTHLY, + "WEEKLY": WEEKLY, + "DAILY": DAILY, + "HOURLY": HOURLY, + "MINUTELY": MINUTELY, + "SECONDLY": SECONDLY} + + _weekday_map = {"MO": 0, "TU": 1, "WE": 2, "TH": 3, + "FR": 4, "SA": 5, "SU": 6} + + def _handle_int(self, rrkwargs, name, value, **kwargs): + rrkwargs[name.lower()] = int(value) + + def _handle_int_list(self, rrkwargs, name, value, **kwargs): + rrkwargs[name.lower()] = [int(x) for x in value.split(',')] + + _handle_INTERVAL = _handle_int + _handle_COUNT = _handle_int + _handle_BYSETPOS = _handle_int_list + _handle_BYMONTH = _handle_int_list + _handle_BYMONTHDAY = _handle_int_list + _handle_BYYEARDAY = _handle_int_list + _handle_BYEASTER = _handle_int_list + _handle_BYWEEKNO = _handle_int_list + _handle_BYHOUR = _handle_int_list + _handle_BYMINUTE = _handle_int_list + _handle_BYSECOND = _handle_int_list + + def _handle_FREQ(self, rrkwargs, name, value, **kwargs): + rrkwargs["freq"] = self._freq_map[value] + + def _handle_UNTIL(self, rrkwargs, name, value, **kwargs): + global parser + if not parser: + from dateutil import parser + try: + rrkwargs["until"] = parser.parse(value, + ignoretz=kwargs.get("ignoretz"), + tzinfos=kwargs.get("tzinfos")) + except ValueError: + raise ValueError("invalid until date") + + def _handle_WKST(self, rrkwargs, name, value, **kwargs): + rrkwargs["wkst"] = self._weekday_map[value] + + def _handle_BYWEEKDAY(self, rrkwargs, name, value, **kwargs): + """ + Two ways to specify this: +1MO or MO(+1) + """ + l = [] + for wday in value.split(','): + if '(' in wday: + # If it's of the form TH(+1), etc. + splt = wday.split('(') + w = splt[0] + n = int(splt[1][:-1]) + elif len(wday): + # If it's of the form +1MO + for i in range(len(wday)): + if wday[i] not in '+-0123456789': + break + n = wday[:i] or None + w = wday[i:] + if n: + n = int(n) + else: + raise ValueError("Invalid (empty) BYDAY specification.") + + l.append(weekdays[self._weekday_map[w]](n)) + rrkwargs["byweekday"] = l + + _handle_BYDAY = _handle_BYWEEKDAY + + def _parse_rfc_rrule(self, line, + dtstart=None, + cache=False, + ignoretz=False, + tzinfos=None): + if line.find(':') != -1: + name, value = line.split(':') + if name != "RRULE": + raise ValueError("unknown parameter name") + else: + value = line + rrkwargs = {} + for pair in value.split(';'): + name, value = pair.split('=') + name = name.upper() + value = value.upper() + try: + getattr(self, "_handle_"+name)(rrkwargs, name, value, + ignoretz=ignoretz, + tzinfos=tzinfos) + except AttributeError: + raise ValueError("unknown parameter '%s'" % name) + except (KeyError, ValueError): + raise ValueError("invalid '%s': %s" % (name, value)) + return rrule(dtstart=dtstart, cache=cache, **rrkwargs) + + def _parse_date_value(self, date_value, parms, rule_tzids, + ignoretz, tzids, tzinfos): + global parser + if not parser: + from dateutil import parser + + datevals = [] + value_found = False + TZID = None + + for parm in parms: + if parm.startswith("TZID="): + try: + tzkey = rule_tzids[parm.split('TZID=')[-1]] + except KeyError: + continue + if tzids is None: + from . import tz + tzlookup = tz.gettz + elif callable(tzids): + tzlookup = tzids + else: + tzlookup = getattr(tzids, 'get', None) + if tzlookup is None: + msg = ('tzids must be a callable, mapping, or None, ' + 'not %s' % tzids) + raise ValueError(msg) + + TZID = tzlookup(tzkey) + continue + + # RFC 5445 3.8.2.4: The VALUE parameter is optional, but may be found + # only once. + if parm not in {"VALUE=DATE-TIME", "VALUE=DATE"}: + raise ValueError("unsupported parm: " + parm) + else: + if value_found: + msg = ("Duplicate value parameter found in: " + parm) + raise ValueError(msg) + value_found = True + + for datestr in date_value.split(','): + date = parser.parse(datestr, ignoretz=ignoretz, tzinfos=tzinfos) + if TZID is not None: + if date.tzinfo is None: + date = date.replace(tzinfo=TZID) + else: + raise ValueError('DTSTART/EXDATE specifies multiple timezone') + datevals.append(date) + + return datevals + + def _parse_rfc(self, s, + dtstart=None, + cache=False, + unfold=False, + forceset=False, + compatible=False, + ignoretz=False, + tzids=None, + tzinfos=None): + global parser + if compatible: + forceset = True + unfold = True + + TZID_NAMES = dict(map( + lambda x: (x.upper(), x), + re.findall('TZID=(?P<name>[^:]+):', s) + )) + s = s.upper() + if not s.strip(): + raise ValueError("empty string") + if unfold: + lines = s.splitlines() + i = 0 + while i < len(lines): + line = lines[i].rstrip() + if not line: + del lines[i] + elif i > 0 and line[0] == " ": + lines[i-1] += line[1:] + del lines[i] + else: + i += 1 + else: + lines = s.split() + if (not forceset and len(lines) == 1 and (s.find(':') == -1 or + s.startswith('RRULE:'))): + return self._parse_rfc_rrule(lines[0], cache=cache, + dtstart=dtstart, ignoretz=ignoretz, + tzinfos=tzinfos) + else: + rrulevals = [] + rdatevals = [] + exrulevals = [] + exdatevals = [] + for line in lines: + if not line: + continue + if line.find(':') == -1: + name = "RRULE" + value = line + else: + name, value = line.split(':', 1) + parms = name.split(';') + if not parms: + raise ValueError("empty property name") + name = parms[0] + parms = parms[1:] + if name == "RRULE": + for parm in parms: + raise ValueError("unsupported RRULE parm: "+parm) + rrulevals.append(value) + elif name == "RDATE": + for parm in parms: + if parm != "VALUE=DATE-TIME": + raise ValueError("unsupported RDATE parm: "+parm) + rdatevals.append(value) + elif name == "EXRULE": + for parm in parms: + raise ValueError("unsupported EXRULE parm: "+parm) + exrulevals.append(value) + elif name == "EXDATE": + exdatevals.extend( + self._parse_date_value(value, parms, + TZID_NAMES, ignoretz, + tzids, tzinfos) + ) + elif name == "DTSTART": + dtvals = self._parse_date_value(value, parms, TZID_NAMES, + ignoretz, tzids, tzinfos) + if len(dtvals) != 1: + raise ValueError("Multiple DTSTART values specified:" + + value) + dtstart = dtvals[0] + else: + raise ValueError("unsupported property: "+name) + if (forceset or len(rrulevals) > 1 or rdatevals + or exrulevals or exdatevals): + if not parser and (rdatevals or exdatevals): + from dateutil import parser + rset = rruleset(cache=cache) + for value in rrulevals: + rset.rrule(self._parse_rfc_rrule(value, dtstart=dtstart, + ignoretz=ignoretz, + tzinfos=tzinfos)) + for value in rdatevals: + for datestr in value.split(','): + rset.rdate(parser.parse(datestr, + ignoretz=ignoretz, + tzinfos=tzinfos)) + for value in exrulevals: + rset.exrule(self._parse_rfc_rrule(value, dtstart=dtstart, + ignoretz=ignoretz, + tzinfos=tzinfos)) + for value in exdatevals: + rset.exdate(value) + if compatible and dtstart: + rset.rdate(dtstart) + return rset + else: + return self._parse_rfc_rrule(rrulevals[0], + dtstart=dtstart, + cache=cache, + ignoretz=ignoretz, + tzinfos=tzinfos) + + def __call__(self, s, **kwargs): + return self._parse_rfc(s, **kwargs) + + +rrulestr = _rrulestr() + +# vim:ts=4:sw=4:et diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tz/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tz/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..af1352c47292f4eebc5cae8da45641b5544558e3 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tz/__init__.py @@ -0,0 +1,12 @@ +# -*- coding: utf-8 -*- +from .tz import * +from .tz import __doc__ + +__all__ = ["tzutc", "tzoffset", "tzlocal", "tzfile", "tzrange", + "tzstr", "tzical", "tzwin", "tzwinlocal", "gettz", + "enfold", "datetime_ambiguous", "datetime_exists", + "resolve_imaginary", "UTC", "DeprecatedTzFormatWarning"] + + +class DeprecatedTzFormatWarning(Warning): + """Warning raised when time zones are parsed from deprecated formats.""" diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tz/_common.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tz/_common.py new file mode 100644 index 0000000000000000000000000000000000000000..e6ac11831522b266114d5b68ee1da298e3aeb14a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tz/_common.py @@ -0,0 +1,419 @@ +from six import PY2 + +from functools import wraps + +from datetime import datetime, timedelta, tzinfo + + +ZERO = timedelta(0) + +__all__ = ['tzname_in_python2', 'enfold'] + + +def tzname_in_python2(namefunc): + """Change unicode output into bytestrings in Python 2 + + tzname() API changed in Python 3. It used to return bytes, but was changed + to unicode strings + """ + if PY2: + @wraps(namefunc) + def adjust_encoding(*args, **kwargs): + name = namefunc(*args, **kwargs) + if name is not None: + name = name.encode() + + return name + + return adjust_encoding + else: + return namefunc + + +# The following is adapted from Alexander Belopolsky's tz library +# https://github.com/abalkin/tz +if hasattr(datetime, 'fold'): + # This is the pre-python 3.6 fold situation + def enfold(dt, fold=1): + """ + Provides a unified interface for assigning the ``fold`` attribute to + datetimes both before and after the implementation of PEP-495. + + :param fold: + The value for the ``fold`` attribute in the returned datetime. This + should be either 0 or 1. + + :return: + Returns an object for which ``getattr(dt, 'fold', 0)`` returns + ``fold`` for all versions of Python. In versions prior to + Python 3.6, this is a ``_DatetimeWithFold`` object, which is a + subclass of :py:class:`datetime.datetime` with the ``fold`` + attribute added, if ``fold`` is 1. + + .. versionadded:: 2.6.0 + """ + return dt.replace(fold=fold) + +else: + class _DatetimeWithFold(datetime): + """ + This is a class designed to provide a PEP 495-compliant interface for + Python versions before 3.6. It is used only for dates in a fold, so + the ``fold`` attribute is fixed at ``1``. + + .. versionadded:: 2.6.0 + """ + __slots__ = () + + def replace(self, *args, **kwargs): + """ + Return a datetime with the same attributes, except for those + attributes given new values by whichever keyword arguments are + specified. Note that tzinfo=None can be specified to create a naive + datetime from an aware datetime with no conversion of date and time + data. + + This is reimplemented in ``_DatetimeWithFold`` because pypy3 will + return a ``datetime.datetime`` even if ``fold`` is unchanged. + """ + argnames = ( + 'year', 'month', 'day', 'hour', 'minute', 'second', + 'microsecond', 'tzinfo' + ) + + for arg, argname in zip(args, argnames): + if argname in kwargs: + raise TypeError('Duplicate argument: {}'.format(argname)) + + kwargs[argname] = arg + + for argname in argnames: + if argname not in kwargs: + kwargs[argname] = getattr(self, argname) + + dt_class = self.__class__ if kwargs.get('fold', 1) else datetime + + return dt_class(**kwargs) + + @property + def fold(self): + return 1 + + def enfold(dt, fold=1): + """ + Provides a unified interface for assigning the ``fold`` attribute to + datetimes both before and after the implementation of PEP-495. + + :param fold: + The value for the ``fold`` attribute in the returned datetime. This + should be either 0 or 1. + + :return: + Returns an object for which ``getattr(dt, 'fold', 0)`` returns + ``fold`` for all versions of Python. In versions prior to + Python 3.6, this is a ``_DatetimeWithFold`` object, which is a + subclass of :py:class:`datetime.datetime` with the ``fold`` + attribute added, if ``fold`` is 1. + + .. versionadded:: 2.6.0 + """ + if getattr(dt, 'fold', 0) == fold: + return dt + + args = dt.timetuple()[:6] + args += (dt.microsecond, dt.tzinfo) + + if fold: + return _DatetimeWithFold(*args) + else: + return datetime(*args) + + +def _validate_fromutc_inputs(f): + """ + The CPython version of ``fromutc`` checks that the input is a ``datetime`` + object and that ``self`` is attached as its ``tzinfo``. + """ + @wraps(f) + def fromutc(self, dt): + if not isinstance(dt, datetime): + raise TypeError("fromutc() requires a datetime argument") + if dt.tzinfo is not self: + raise ValueError("dt.tzinfo is not self") + + return f(self, dt) + + return fromutc + + +class _tzinfo(tzinfo): + """ + Base class for all ``dateutil`` ``tzinfo`` objects. + """ + + def is_ambiguous(self, dt): + """ + Whether or not the "wall time" of a given datetime is ambiguous in this + zone. + + :param dt: + A :py:class:`datetime.datetime`, naive or time zone aware. + + + :return: + Returns ``True`` if ambiguous, ``False`` otherwise. + + .. versionadded:: 2.6.0 + """ + + dt = dt.replace(tzinfo=self) + + wall_0 = enfold(dt, fold=0) + wall_1 = enfold(dt, fold=1) + + same_offset = wall_0.utcoffset() == wall_1.utcoffset() + same_dt = wall_0.replace(tzinfo=None) == wall_1.replace(tzinfo=None) + + return same_dt and not same_offset + + def _fold_status(self, dt_utc, dt_wall): + """ + Determine the fold status of a "wall" datetime, given a representation + of the same datetime as a (naive) UTC datetime. This is calculated based + on the assumption that ``dt.utcoffset() - dt.dst()`` is constant for all + datetimes, and that this offset is the actual number of hours separating + ``dt_utc`` and ``dt_wall``. + + :param dt_utc: + Representation of the datetime as UTC + + :param dt_wall: + Representation of the datetime as "wall time". This parameter must + either have a `fold` attribute or have a fold-naive + :class:`datetime.tzinfo` attached, otherwise the calculation may + fail. + """ + if self.is_ambiguous(dt_wall): + delta_wall = dt_wall - dt_utc + _fold = int(delta_wall == (dt_utc.utcoffset() - dt_utc.dst())) + else: + _fold = 0 + + return _fold + + def _fold(self, dt): + return getattr(dt, 'fold', 0) + + def _fromutc(self, dt): + """ + Given a timezone-aware datetime in a given timezone, calculates a + timezone-aware datetime in a new timezone. + + Since this is the one time that we *know* we have an unambiguous + datetime object, we take this opportunity to determine whether the + datetime is ambiguous and in a "fold" state (e.g. if it's the first + occurrence, chronologically, of the ambiguous datetime). + + :param dt: + A timezone-aware :class:`datetime.datetime` object. + """ + + # Re-implement the algorithm from Python's datetime.py + dtoff = dt.utcoffset() + if dtoff is None: + raise ValueError("fromutc() requires a non-None utcoffset() " + "result") + + # The original datetime.py code assumes that `dst()` defaults to + # zero during ambiguous times. PEP 495 inverts this presumption, so + # for pre-PEP 495 versions of python, we need to tweak the algorithm. + dtdst = dt.dst() + if dtdst is None: + raise ValueError("fromutc() requires a non-None dst() result") + delta = dtoff - dtdst + + dt += delta + # Set fold=1 so we can default to being in the fold for + # ambiguous dates. + dtdst = enfold(dt, fold=1).dst() + if dtdst is None: + raise ValueError("fromutc(): dt.dst gave inconsistent " + "results; cannot convert") + return dt + dtdst + + @_validate_fromutc_inputs + def fromutc(self, dt): + """ + Given a timezone-aware datetime in a given timezone, calculates a + timezone-aware datetime in a new timezone. + + Since this is the one time that we *know* we have an unambiguous + datetime object, we take this opportunity to determine whether the + datetime is ambiguous and in a "fold" state (e.g. if it's the first + occurrence, chronologically, of the ambiguous datetime). + + :param dt: + A timezone-aware :class:`datetime.datetime` object. + """ + dt_wall = self._fromutc(dt) + + # Calculate the fold status given the two datetimes. + _fold = self._fold_status(dt, dt_wall) + + # Set the default fold value for ambiguous dates + return enfold(dt_wall, fold=_fold) + + +class tzrangebase(_tzinfo): + """ + This is an abstract base class for time zones represented by an annual + transition into and out of DST. Child classes should implement the following + methods: + + * ``__init__(self, *args, **kwargs)`` + * ``transitions(self, year)`` - this is expected to return a tuple of + datetimes representing the DST on and off transitions in standard + time. + + A fully initialized ``tzrangebase`` subclass should also provide the + following attributes: + * ``hasdst``: Boolean whether or not the zone uses DST. + * ``_dst_offset`` / ``_std_offset``: :class:`datetime.timedelta` objects + representing the respective UTC offsets. + * ``_dst_abbr`` / ``_std_abbr``: Strings representing the timezone short + abbreviations in DST and STD, respectively. + * ``_hasdst``: Whether or not the zone has DST. + + .. versionadded:: 2.6.0 + """ + def __init__(self): + raise NotImplementedError('tzrangebase is an abstract base class') + + def utcoffset(self, dt): + isdst = self._isdst(dt) + + if isdst is None: + return None + elif isdst: + return self._dst_offset + else: + return self._std_offset + + def dst(self, dt): + isdst = self._isdst(dt) + + if isdst is None: + return None + elif isdst: + return self._dst_base_offset + else: + return ZERO + + @tzname_in_python2 + def tzname(self, dt): + if self._isdst(dt): + return self._dst_abbr + else: + return self._std_abbr + + def fromutc(self, dt): + """ Given a datetime in UTC, return local time """ + if not isinstance(dt, datetime): + raise TypeError("fromutc() requires a datetime argument") + + if dt.tzinfo is not self: + raise ValueError("dt.tzinfo is not self") + + # Get transitions - if there are none, fixed offset + transitions = self.transitions(dt.year) + if transitions is None: + return dt + self.utcoffset(dt) + + # Get the transition times in UTC + dston, dstoff = transitions + + dston -= self._std_offset + dstoff -= self._std_offset + + utc_transitions = (dston, dstoff) + dt_utc = dt.replace(tzinfo=None) + + isdst = self._naive_isdst(dt_utc, utc_transitions) + + if isdst: + dt_wall = dt + self._dst_offset + else: + dt_wall = dt + self._std_offset + + _fold = int(not isdst and self.is_ambiguous(dt_wall)) + + return enfold(dt_wall, fold=_fold) + + def is_ambiguous(self, dt): + """ + Whether or not the "wall time" of a given datetime is ambiguous in this + zone. + + :param dt: + A :py:class:`datetime.datetime`, naive or time zone aware. + + + :return: + Returns ``True`` if ambiguous, ``False`` otherwise. + + .. versionadded:: 2.6.0 + """ + if not self.hasdst: + return False + + start, end = self.transitions(dt.year) + + dt = dt.replace(tzinfo=None) + return (end <= dt < end + self._dst_base_offset) + + def _isdst(self, dt): + if not self.hasdst: + return False + elif dt is None: + return None + + transitions = self.transitions(dt.year) + + if transitions is None: + return False + + dt = dt.replace(tzinfo=None) + + isdst = self._naive_isdst(dt, transitions) + + # Handle ambiguous dates + if not isdst and self.is_ambiguous(dt): + return not self._fold(dt) + else: + return isdst + + def _naive_isdst(self, dt, transitions): + dston, dstoff = transitions + + dt = dt.replace(tzinfo=None) + + if dston < dstoff: + isdst = dston <= dt < dstoff + else: + isdst = not dstoff <= dt < dston + + return isdst + + @property + def _dst_base_offset(self): + return self._dst_offset - self._std_offset + + __hash__ = None + + def __ne__(self, other): + return not (self == other) + + def __repr__(self): + return "%s(...)" % self.__class__.__name__ + + __reduce__ = object.__reduce__ diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tz/_factories.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tz/_factories.py new file mode 100644 index 0000000000000000000000000000000000000000..f8a65891a023ebf9eb0c24d391ba67541b7133f1 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tz/_factories.py @@ -0,0 +1,80 @@ +from datetime import timedelta +import weakref +from collections import OrderedDict + +from six.moves import _thread + + +class _TzSingleton(type): + def __init__(cls, *args, **kwargs): + cls.__instance = None + super(_TzSingleton, cls).__init__(*args, **kwargs) + + def __call__(cls): + if cls.__instance is None: + cls.__instance = super(_TzSingleton, cls).__call__() + return cls.__instance + + +class _TzFactory(type): + def instance(cls, *args, **kwargs): + """Alternate constructor that returns a fresh instance""" + return type.__call__(cls, *args, **kwargs) + + +class _TzOffsetFactory(_TzFactory): + def __init__(cls, *args, **kwargs): + cls.__instances = weakref.WeakValueDictionary() + cls.__strong_cache = OrderedDict() + cls.__strong_cache_size = 8 + + cls._cache_lock = _thread.allocate_lock() + + def __call__(cls, name, offset): + if isinstance(offset, timedelta): + key = (name, offset.total_seconds()) + else: + key = (name, offset) + + instance = cls.__instances.get(key, None) + if instance is None: + instance = cls.__instances.setdefault(key, + cls.instance(name, offset)) + + # This lock may not be necessary in Python 3. See GH issue #901 + with cls._cache_lock: + cls.__strong_cache[key] = cls.__strong_cache.pop(key, instance) + + # Remove an item if the strong cache is overpopulated + if len(cls.__strong_cache) > cls.__strong_cache_size: + cls.__strong_cache.popitem(last=False) + + return instance + + +class _TzStrFactory(_TzFactory): + def __init__(cls, *args, **kwargs): + cls.__instances = weakref.WeakValueDictionary() + cls.__strong_cache = OrderedDict() + cls.__strong_cache_size = 8 + + cls.__cache_lock = _thread.allocate_lock() + + def __call__(cls, s, posix_offset=False): + key = (s, posix_offset) + instance = cls.__instances.get(key, None) + + if instance is None: + instance = cls.__instances.setdefault(key, + cls.instance(s, posix_offset)) + + # This lock may not be necessary in Python 3. See GH issue #901 + with cls.__cache_lock: + cls.__strong_cache[key] = cls.__strong_cache.pop(key, instance) + + # Remove an item if the strong cache is overpopulated + if len(cls.__strong_cache) > cls.__strong_cache_size: + cls.__strong_cache.popitem(last=False) + + return instance + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tz/tz.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tz/tz.py new file mode 100644 index 0000000000000000000000000000000000000000..617591446bd92eb1cc7b7d67fa3f17435e691cdd --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tz/tz.py @@ -0,0 +1,1849 @@ +# -*- coding: utf-8 -*- +""" +This module offers timezone implementations subclassing the abstract +:py:class:`datetime.tzinfo` type. There are classes to handle tzfile format +files (usually are in :file:`/etc/localtime`, :file:`/usr/share/zoneinfo`, +etc), TZ environment string (in all known formats), given ranges (with help +from relative deltas), local machine timezone, fixed offset timezone, and UTC +timezone. +""" +import datetime +import struct +import time +import sys +import os +import bisect +import weakref +from collections import OrderedDict + +import six +from six import string_types +from six.moves import _thread +from ._common import tzname_in_python2, _tzinfo +from ._common import tzrangebase, enfold +from ._common import _validate_fromutc_inputs + +from ._factories import _TzSingleton, _TzOffsetFactory +from ._factories import _TzStrFactory +try: + from .win import tzwin, tzwinlocal +except ImportError: + tzwin = tzwinlocal = None + +# For warning about rounding tzinfo +from warnings import warn + +ZERO = datetime.timedelta(0) +EPOCH = datetime.datetime(1970, 1, 1, 0, 0) +EPOCHORDINAL = EPOCH.toordinal() + + +@six.add_metaclass(_TzSingleton) +class tzutc(datetime.tzinfo): + """ + This is a tzinfo object that represents the UTC time zone. + + **Examples:** + + .. doctest:: + + >>> from datetime import * + >>> from dateutil.tz import * + + >>> datetime.now() + datetime.datetime(2003, 9, 27, 9, 40, 1, 521290) + + >>> datetime.now(tzutc()) + datetime.datetime(2003, 9, 27, 12, 40, 12, 156379, tzinfo=tzutc()) + + >>> datetime.now(tzutc()).tzname() + 'UTC' + + .. versionchanged:: 2.7.0 + ``tzutc()`` is now a singleton, so the result of ``tzutc()`` will + always return the same object. + + .. doctest:: + + >>> from dateutil.tz import tzutc, UTC + >>> tzutc() is tzutc() + True + >>> tzutc() is UTC + True + """ + def utcoffset(self, dt): + return ZERO + + def dst(self, dt): + return ZERO + + @tzname_in_python2 + def tzname(self, dt): + return "UTC" + + def is_ambiguous(self, dt): + """ + Whether or not the "wall time" of a given datetime is ambiguous in this + zone. + + :param dt: + A :py:class:`datetime.datetime`, naive or time zone aware. + + + :return: + Returns ``True`` if ambiguous, ``False`` otherwise. + + .. versionadded:: 2.6.0 + """ + return False + + @_validate_fromutc_inputs + def fromutc(self, dt): + """ + Fast track version of fromutc() returns the original ``dt`` object for + any valid :py:class:`datetime.datetime` object. + """ + return dt + + def __eq__(self, other): + if not isinstance(other, (tzutc, tzoffset)): + return NotImplemented + + return (isinstance(other, tzutc) or + (isinstance(other, tzoffset) and other._offset == ZERO)) + + __hash__ = None + + def __ne__(self, other): + return not (self == other) + + def __repr__(self): + return "%s()" % self.__class__.__name__ + + __reduce__ = object.__reduce__ + + +#: Convenience constant providing a :class:`tzutc()` instance +#: +#: .. versionadded:: 2.7.0 +UTC = tzutc() + + +@six.add_metaclass(_TzOffsetFactory) +class tzoffset(datetime.tzinfo): + """ + A simple class for representing a fixed offset from UTC. + + :param name: + The timezone name, to be returned when ``tzname()`` is called. + :param offset: + The time zone offset in seconds, or (since version 2.6.0, represented + as a :py:class:`datetime.timedelta` object). + """ + def __init__(self, name, offset): + self._name = name + + try: + # Allow a timedelta + offset = offset.total_seconds() + except (TypeError, AttributeError): + pass + + self._offset = datetime.timedelta(seconds=_get_supported_offset(offset)) + + def utcoffset(self, dt): + return self._offset + + def dst(self, dt): + return ZERO + + @tzname_in_python2 + def tzname(self, dt): + return self._name + + @_validate_fromutc_inputs + def fromutc(self, dt): + return dt + self._offset + + def is_ambiguous(self, dt): + """ + Whether or not the "wall time" of a given datetime is ambiguous in this + zone. + + :param dt: + A :py:class:`datetime.datetime`, naive or time zone aware. + :return: + Returns ``True`` if ambiguous, ``False`` otherwise. + + .. versionadded:: 2.6.0 + """ + return False + + def __eq__(self, other): + if not isinstance(other, tzoffset): + return NotImplemented + + return self._offset == other._offset + + __hash__ = None + + def __ne__(self, other): + return not (self == other) + + def __repr__(self): + return "%s(%s, %s)" % (self.__class__.__name__, + repr(self._name), + int(self._offset.total_seconds())) + + __reduce__ = object.__reduce__ + + +class tzlocal(_tzinfo): + """ + A :class:`tzinfo` subclass built around the ``time`` timezone functions. + """ + def __init__(self): + super(tzlocal, self).__init__() + + self._std_offset = datetime.timedelta(seconds=-time.timezone) + if time.daylight: + self._dst_offset = datetime.timedelta(seconds=-time.altzone) + else: + self._dst_offset = self._std_offset + + self._dst_saved = self._dst_offset - self._std_offset + self._hasdst = bool(self._dst_saved) + self._tznames = tuple(time.tzname) + + def utcoffset(self, dt): + if dt is None and self._hasdst: + return None + + if self._isdst(dt): + return self._dst_offset + else: + return self._std_offset + + def dst(self, dt): + if dt is None and self._hasdst: + return None + + if self._isdst(dt): + return self._dst_offset - self._std_offset + else: + return ZERO + + @tzname_in_python2 + def tzname(self, dt): + return self._tznames[self._isdst(dt)] + + def is_ambiguous(self, dt): + """ + Whether or not the "wall time" of a given datetime is ambiguous in this + zone. + + :param dt: + A :py:class:`datetime.datetime`, naive or time zone aware. + + + :return: + Returns ``True`` if ambiguous, ``False`` otherwise. + + .. versionadded:: 2.6.0 + """ + naive_dst = self._naive_is_dst(dt) + return (not naive_dst and + (naive_dst != self._naive_is_dst(dt - self._dst_saved))) + + def _naive_is_dst(self, dt): + timestamp = _datetime_to_timestamp(dt) + return time.localtime(timestamp + time.timezone).tm_isdst + + def _isdst(self, dt, fold_naive=True): + # We can't use mktime here. It is unstable when deciding if + # the hour near to a change is DST or not. + # + # timestamp = time.mktime((dt.year, dt.month, dt.day, dt.hour, + # dt.minute, dt.second, dt.weekday(), 0, -1)) + # return time.localtime(timestamp).tm_isdst + # + # The code above yields the following result: + # + # >>> import tz, datetime + # >>> t = tz.tzlocal() + # >>> datetime.datetime(2003,2,15,23,tzinfo=t).tzname() + # 'BRDT' + # >>> datetime.datetime(2003,2,16,0,tzinfo=t).tzname() + # 'BRST' + # >>> datetime.datetime(2003,2,15,23,tzinfo=t).tzname() + # 'BRST' + # >>> datetime.datetime(2003,2,15,22,tzinfo=t).tzname() + # 'BRDT' + # >>> datetime.datetime(2003,2,15,23,tzinfo=t).tzname() + # 'BRDT' + # + # Here is a more stable implementation: + # + if not self._hasdst: + return False + + # Check for ambiguous times: + dstval = self._naive_is_dst(dt) + fold = getattr(dt, 'fold', None) + + if self.is_ambiguous(dt): + if fold is not None: + return not self._fold(dt) + else: + return True + + return dstval + + def __eq__(self, other): + if isinstance(other, tzlocal): + return (self._std_offset == other._std_offset and + self._dst_offset == other._dst_offset) + elif isinstance(other, tzutc): + return (not self._hasdst and + self._tznames[0] in {'UTC', 'GMT'} and + self._std_offset == ZERO) + elif isinstance(other, tzoffset): + return (not self._hasdst and + self._tznames[0] == other._name and + self._std_offset == other._offset) + else: + return NotImplemented + + __hash__ = None + + def __ne__(self, other): + return not (self == other) + + def __repr__(self): + return "%s()" % self.__class__.__name__ + + __reduce__ = object.__reduce__ + + +class _ttinfo(object): + __slots__ = ["offset", "delta", "isdst", "abbr", + "isstd", "isgmt", "dstoffset"] + + def __init__(self): + for attr in self.__slots__: + setattr(self, attr, None) + + def __repr__(self): + l = [] + for attr in self.__slots__: + value = getattr(self, attr) + if value is not None: + l.append("%s=%s" % (attr, repr(value))) + return "%s(%s)" % (self.__class__.__name__, ", ".join(l)) + + def __eq__(self, other): + if not isinstance(other, _ttinfo): + return NotImplemented + + return (self.offset == other.offset and + self.delta == other.delta and + self.isdst == other.isdst and + self.abbr == other.abbr and + self.isstd == other.isstd and + self.isgmt == other.isgmt and + self.dstoffset == other.dstoffset) + + __hash__ = None + + def __ne__(self, other): + return not (self == other) + + def __getstate__(self): + state = {} + for name in self.__slots__: + state[name] = getattr(self, name, None) + return state + + def __setstate__(self, state): + for name in self.__slots__: + if name in state: + setattr(self, name, state[name]) + + +class _tzfile(object): + """ + Lightweight class for holding the relevant transition and time zone + information read from binary tzfiles. + """ + attrs = ['trans_list', 'trans_list_utc', 'trans_idx', 'ttinfo_list', + 'ttinfo_std', 'ttinfo_dst', 'ttinfo_before', 'ttinfo_first'] + + def __init__(self, **kwargs): + for attr in self.attrs: + setattr(self, attr, kwargs.get(attr, None)) + + +class tzfile(_tzinfo): + """ + This is a ``tzinfo`` subclass that allows one to use the ``tzfile(5)`` + format timezone files to extract current and historical zone information. + + :param fileobj: + This can be an opened file stream or a file name that the time zone + information can be read from. + + :param filename: + This is an optional parameter specifying the source of the time zone + information in the event that ``fileobj`` is a file object. If omitted + and ``fileobj`` is a file stream, this parameter will be set either to + ``fileobj``'s ``name`` attribute or to ``repr(fileobj)``. + + See `Sources for Time Zone and Daylight Saving Time Data + <https://data.iana.org/time-zones/tz-link.html>`_ for more information. + Time zone files can be compiled from the `IANA Time Zone database files + <https://www.iana.org/time-zones>`_ with the `zic time zone compiler + <https://www.freebsd.org/cgi/man.cgi?query=zic&sektion=8>`_ + + .. note:: + + Only construct a ``tzfile`` directly if you have a specific timezone + file on disk that you want to read into a Python ``tzinfo`` object. + If you want to get a ``tzfile`` representing a specific IANA zone, + (e.g. ``'America/New_York'``), you should call + :func:`dateutil.tz.gettz` with the zone identifier. + + + **Examples:** + + Using the US Eastern time zone as an example, we can see that a ``tzfile`` + provides time zone information for the standard Daylight Saving offsets: + + .. testsetup:: tzfile + + from dateutil.tz import gettz + from datetime import datetime + + .. doctest:: tzfile + + >>> NYC = gettz('America/New_York') + >>> NYC + tzfile('/usr/share/zoneinfo/America/New_York') + + >>> print(datetime(2016, 1, 3, tzinfo=NYC)) # EST + 2016-01-03 00:00:00-05:00 + + >>> print(datetime(2016, 7, 7, tzinfo=NYC)) # EDT + 2016-07-07 00:00:00-04:00 + + + The ``tzfile`` structure contains a fully history of the time zone, + so historical dates will also have the right offsets. For example, before + the adoption of the UTC standards, New York used local solar mean time: + + .. doctest:: tzfile + + >>> print(datetime(1901, 4, 12, tzinfo=NYC)) # LMT + 1901-04-12 00:00:00-04:56 + + And during World War II, New York was on "Eastern War Time", which was a + state of permanent daylight saving time: + + .. doctest:: tzfile + + >>> print(datetime(1944, 2, 7, tzinfo=NYC)) # EWT + 1944-02-07 00:00:00-04:00 + + """ + + def __init__(self, fileobj, filename=None): + super(tzfile, self).__init__() + + file_opened_here = False + if isinstance(fileobj, string_types): + self._filename = fileobj + fileobj = open(fileobj, 'rb') + file_opened_here = True + elif filename is not None: + self._filename = filename + elif hasattr(fileobj, "name"): + self._filename = fileobj.name + else: + self._filename = repr(fileobj) + + if fileobj is not None: + if not file_opened_here: + fileobj = _nullcontext(fileobj) + + with fileobj as file_stream: + tzobj = self._read_tzfile(file_stream) + + self._set_tzdata(tzobj) + + def _set_tzdata(self, tzobj): + """ Set the time zone data of this object from a _tzfile object """ + # Copy the relevant attributes over as private attributes + for attr in _tzfile.attrs: + setattr(self, '_' + attr, getattr(tzobj, attr)) + + def _read_tzfile(self, fileobj): + out = _tzfile() + + # From tzfile(5): + # + # The time zone information files used by tzset(3) + # begin with the magic characters "TZif" to identify + # them as time zone information files, followed by + # sixteen bytes reserved for future use, followed by + # six four-byte values of type long, written in a + # ``standard'' byte order (the high-order byte + # of the value is written first). + if fileobj.read(4).decode() != "TZif": + raise ValueError("magic not found") + + fileobj.read(16) + + ( + # The number of UTC/local indicators stored in the file. + ttisgmtcnt, + + # The number of standard/wall indicators stored in the file. + ttisstdcnt, + + # The number of leap seconds for which data is + # stored in the file. + leapcnt, + + # The number of "transition times" for which data + # is stored in the file. + timecnt, + + # The number of "local time types" for which data + # is stored in the file (must not be zero). + typecnt, + + # The number of characters of "time zone + # abbreviation strings" stored in the file. + charcnt, + + ) = struct.unpack(">6l", fileobj.read(24)) + + # The above header is followed by tzh_timecnt four-byte + # values of type long, sorted in ascending order. + # These values are written in ``standard'' byte order. + # Each is used as a transition time (as returned by + # time(2)) at which the rules for computing local time + # change. + + if timecnt: + out.trans_list_utc = list(struct.unpack(">%dl" % timecnt, + fileobj.read(timecnt*4))) + else: + out.trans_list_utc = [] + + # Next come tzh_timecnt one-byte values of type unsigned + # char; each one tells which of the different types of + # ``local time'' types described in the file is associated + # with the same-indexed transition time. These values + # serve as indices into an array of ttinfo structures that + # appears next in the file. + + if timecnt: + out.trans_idx = struct.unpack(">%dB" % timecnt, + fileobj.read(timecnt)) + else: + out.trans_idx = [] + + # Each ttinfo structure is written as a four-byte value + # for tt_gmtoff of type long, in a standard byte + # order, followed by a one-byte value for tt_isdst + # and a one-byte value for tt_abbrind. In each + # structure, tt_gmtoff gives the number of + # seconds to be added to UTC, tt_isdst tells whether + # tm_isdst should be set by localtime(3), and + # tt_abbrind serves as an index into the array of + # time zone abbreviation characters that follow the + # ttinfo structure(s) in the file. + + ttinfo = [] + + for i in range(typecnt): + ttinfo.append(struct.unpack(">lbb", fileobj.read(6))) + + abbr = fileobj.read(charcnt).decode() + + # Then there are tzh_leapcnt pairs of four-byte + # values, written in standard byte order; the + # first value of each pair gives the time (as + # returned by time(2)) at which a leap second + # occurs; the second gives the total number of + # leap seconds to be applied after the given time. + # The pairs of values are sorted in ascending order + # by time. + + # Not used, for now (but seek for correct file position) + if leapcnt: + fileobj.seek(leapcnt * 8, os.SEEK_CUR) + + # Then there are tzh_ttisstdcnt standard/wall + # indicators, each stored as a one-byte value; + # they tell whether the transition times associated + # with local time types were specified as standard + # time or wall clock time, and are used when + # a time zone file is used in handling POSIX-style + # time zone environment variables. + + if ttisstdcnt: + isstd = struct.unpack(">%db" % ttisstdcnt, + fileobj.read(ttisstdcnt)) + + # Finally, there are tzh_ttisgmtcnt UTC/local + # indicators, each stored as a one-byte value; + # they tell whether the transition times associated + # with local time types were specified as UTC or + # local time, and are used when a time zone file + # is used in handling POSIX-style time zone envi- + # ronment variables. + + if ttisgmtcnt: + isgmt = struct.unpack(">%db" % ttisgmtcnt, + fileobj.read(ttisgmtcnt)) + + # Build ttinfo list + out.ttinfo_list = [] + for i in range(typecnt): + gmtoff, isdst, abbrind = ttinfo[i] + gmtoff = _get_supported_offset(gmtoff) + tti = _ttinfo() + tti.offset = gmtoff + tti.dstoffset = datetime.timedelta(0) + tti.delta = datetime.timedelta(seconds=gmtoff) + tti.isdst = isdst + tti.abbr = abbr[abbrind:abbr.find('\x00', abbrind)] + tti.isstd = (ttisstdcnt > i and isstd[i] != 0) + tti.isgmt = (ttisgmtcnt > i and isgmt[i] != 0) + out.ttinfo_list.append(tti) + + # Replace ttinfo indexes for ttinfo objects. + out.trans_idx = [out.ttinfo_list[idx] for idx in out.trans_idx] + + # Set standard, dst, and before ttinfos. before will be + # used when a given time is before any transitions, + # and will be set to the first non-dst ttinfo, or to + # the first dst, if all of them are dst. + out.ttinfo_std = None + out.ttinfo_dst = None + out.ttinfo_before = None + if out.ttinfo_list: + if not out.trans_list_utc: + out.ttinfo_std = out.ttinfo_first = out.ttinfo_list[0] + else: + for i in range(timecnt-1, -1, -1): + tti = out.trans_idx[i] + if not out.ttinfo_std and not tti.isdst: + out.ttinfo_std = tti + elif not out.ttinfo_dst and tti.isdst: + out.ttinfo_dst = tti + + if out.ttinfo_std and out.ttinfo_dst: + break + else: + if out.ttinfo_dst and not out.ttinfo_std: + out.ttinfo_std = out.ttinfo_dst + + for tti in out.ttinfo_list: + if not tti.isdst: + out.ttinfo_before = tti + break + else: + out.ttinfo_before = out.ttinfo_list[0] + + # Now fix transition times to become relative to wall time. + # + # I'm not sure about this. In my tests, the tz source file + # is setup to wall time, and in the binary file isstd and + # isgmt are off, so it should be in wall time. OTOH, it's + # always in gmt time. Let me know if you have comments + # about this. + lastdst = None + lastoffset = None + lastdstoffset = None + lastbaseoffset = None + out.trans_list = [] + + for i, tti in enumerate(out.trans_idx): + offset = tti.offset + dstoffset = 0 + + if lastdst is not None: + if tti.isdst: + if not lastdst: + dstoffset = offset - lastoffset + + if not dstoffset and lastdstoffset: + dstoffset = lastdstoffset + + tti.dstoffset = datetime.timedelta(seconds=dstoffset) + lastdstoffset = dstoffset + + # If a time zone changes its base offset during a DST transition, + # then you need to adjust by the previous base offset to get the + # transition time in local time. Otherwise you use the current + # base offset. Ideally, I would have some mathematical proof of + # why this is true, but I haven't really thought about it enough. + baseoffset = offset - dstoffset + adjustment = baseoffset + if (lastbaseoffset is not None and baseoffset != lastbaseoffset + and tti.isdst != lastdst): + # The base DST has changed + adjustment = lastbaseoffset + + lastdst = tti.isdst + lastoffset = offset + lastbaseoffset = baseoffset + + out.trans_list.append(out.trans_list_utc[i] + adjustment) + + out.trans_idx = tuple(out.trans_idx) + out.trans_list = tuple(out.trans_list) + out.trans_list_utc = tuple(out.trans_list_utc) + + return out + + def _find_last_transition(self, dt, in_utc=False): + # If there's no list, there are no transitions to find + if not self._trans_list: + return None + + timestamp = _datetime_to_timestamp(dt) + + # Find where the timestamp fits in the transition list - if the + # timestamp is a transition time, it's part of the "after" period. + trans_list = self._trans_list_utc if in_utc else self._trans_list + idx = bisect.bisect_right(trans_list, timestamp) + + # We want to know when the previous transition was, so subtract off 1 + return idx - 1 + + def _get_ttinfo(self, idx): + # For no list or after the last transition, default to _ttinfo_std + if idx is None or (idx + 1) >= len(self._trans_list): + return self._ttinfo_std + + # If there is a list and the time is before it, return _ttinfo_before + if idx < 0: + return self._ttinfo_before + + return self._trans_idx[idx] + + def _find_ttinfo(self, dt): + idx = self._resolve_ambiguous_time(dt) + + return self._get_ttinfo(idx) + + def fromutc(self, dt): + """ + The ``tzfile`` implementation of :py:func:`datetime.tzinfo.fromutc`. + + :param dt: + A :py:class:`datetime.datetime` object. + + :raises TypeError: + Raised if ``dt`` is not a :py:class:`datetime.datetime` object. + + :raises ValueError: + Raised if this is called with a ``dt`` which does not have this + ``tzinfo`` attached. + + :return: + Returns a :py:class:`datetime.datetime` object representing the + wall time in ``self``'s time zone. + """ + # These isinstance checks are in datetime.tzinfo, so we'll preserve + # them, even if we don't care about duck typing. + if not isinstance(dt, datetime.datetime): + raise TypeError("fromutc() requires a datetime argument") + + if dt.tzinfo is not self: + raise ValueError("dt.tzinfo is not self") + + # First treat UTC as wall time and get the transition we're in. + idx = self._find_last_transition(dt, in_utc=True) + tti = self._get_ttinfo(idx) + + dt_out = dt + datetime.timedelta(seconds=tti.offset) + + fold = self.is_ambiguous(dt_out, idx=idx) + + return enfold(dt_out, fold=int(fold)) + + def is_ambiguous(self, dt, idx=None): + """ + Whether or not the "wall time" of a given datetime is ambiguous in this + zone. + + :param dt: + A :py:class:`datetime.datetime`, naive or time zone aware. + + + :return: + Returns ``True`` if ambiguous, ``False`` otherwise. + + .. versionadded:: 2.6.0 + """ + if idx is None: + idx = self._find_last_transition(dt) + + # Calculate the difference in offsets from current to previous + timestamp = _datetime_to_timestamp(dt) + tti = self._get_ttinfo(idx) + + if idx is None or idx <= 0: + return False + + od = self._get_ttinfo(idx - 1).offset - tti.offset + tt = self._trans_list[idx] # Transition time + + return timestamp < tt + od + + def _resolve_ambiguous_time(self, dt): + idx = self._find_last_transition(dt) + + # If we have no transitions, return the index + _fold = self._fold(dt) + if idx is None or idx == 0: + return idx + + # If it's ambiguous and we're in a fold, shift to a different index. + idx_offset = int(not _fold and self.is_ambiguous(dt, idx)) + + return idx - idx_offset + + def utcoffset(self, dt): + if dt is None: + return None + + if not self._ttinfo_std: + return ZERO + + return self._find_ttinfo(dt).delta + + def dst(self, dt): + if dt is None: + return None + + if not self._ttinfo_dst: + return ZERO + + tti = self._find_ttinfo(dt) + + if not tti.isdst: + return ZERO + + # The documentation says that utcoffset()-dst() must + # be constant for every dt. + return tti.dstoffset + + @tzname_in_python2 + def tzname(self, dt): + if not self._ttinfo_std or dt is None: + return None + return self._find_ttinfo(dt).abbr + + def __eq__(self, other): + if not isinstance(other, tzfile): + return NotImplemented + return (self._trans_list == other._trans_list and + self._trans_idx == other._trans_idx and + self._ttinfo_list == other._ttinfo_list) + + __hash__ = None + + def __ne__(self, other): + return not (self == other) + + def __repr__(self): + return "%s(%s)" % (self.__class__.__name__, repr(self._filename)) + + def __reduce__(self): + return self.__reduce_ex__(None) + + def __reduce_ex__(self, protocol): + return (self.__class__, (None, self._filename), self.__dict__) + + +class tzrange(tzrangebase): + """ + The ``tzrange`` object is a time zone specified by a set of offsets and + abbreviations, equivalent to the way the ``TZ`` variable can be specified + in POSIX-like systems, but using Python delta objects to specify DST + start, end and offsets. + + :param stdabbr: + The abbreviation for standard time (e.g. ``'EST'``). + + :param stdoffset: + An integer or :class:`datetime.timedelta` object or equivalent + specifying the base offset from UTC. + + If unspecified, +00:00 is used. + + :param dstabbr: + The abbreviation for DST / "Summer" time (e.g. ``'EDT'``). + + If specified, with no other DST information, DST is assumed to occur + and the default behavior or ``dstoffset``, ``start`` and ``end`` is + used. If unspecified and no other DST information is specified, it + is assumed that this zone has no DST. + + If this is unspecified and other DST information is *is* specified, + DST occurs in the zone but the time zone abbreviation is left + unchanged. + + :param dstoffset: + A an integer or :class:`datetime.timedelta` object or equivalent + specifying the UTC offset during DST. If unspecified and any other DST + information is specified, it is assumed to be the STD offset +1 hour. + + :param start: + A :class:`relativedelta.relativedelta` object or equivalent specifying + the time and time of year that daylight savings time starts. To + specify, for example, that DST starts at 2AM on the 2nd Sunday in + March, pass: + + ``relativedelta(hours=2, month=3, day=1, weekday=SU(+2))`` + + If unspecified and any other DST information is specified, the default + value is 2 AM on the first Sunday in April. + + :param end: + A :class:`relativedelta.relativedelta` object or equivalent + representing the time and time of year that daylight savings time + ends, with the same specification method as in ``start``. One note is + that this should point to the first time in the *standard* zone, so if + a transition occurs at 2AM in the DST zone and the clocks are set back + 1 hour to 1AM, set the ``hours`` parameter to +1. + + + **Examples:** + + .. testsetup:: tzrange + + from dateutil.tz import tzrange, tzstr + + .. doctest:: tzrange + + >>> tzstr('EST5EDT') == tzrange("EST", -18000, "EDT") + True + + >>> from dateutil.relativedelta import * + >>> range1 = tzrange("EST", -18000, "EDT") + >>> range2 = tzrange("EST", -18000, "EDT", -14400, + ... relativedelta(hours=+2, month=4, day=1, + ... weekday=SU(+1)), + ... relativedelta(hours=+1, month=10, day=31, + ... weekday=SU(-1))) + >>> tzstr('EST5EDT') == range1 == range2 + True + + """ + def __init__(self, stdabbr, stdoffset=None, + dstabbr=None, dstoffset=None, + start=None, end=None): + + global relativedelta + from dateutil import relativedelta + + self._std_abbr = stdabbr + self._dst_abbr = dstabbr + + try: + stdoffset = stdoffset.total_seconds() + except (TypeError, AttributeError): + pass + + try: + dstoffset = dstoffset.total_seconds() + except (TypeError, AttributeError): + pass + + if stdoffset is not None: + self._std_offset = datetime.timedelta(seconds=stdoffset) + else: + self._std_offset = ZERO + + if dstoffset is not None: + self._dst_offset = datetime.timedelta(seconds=dstoffset) + elif dstabbr and stdoffset is not None: + self._dst_offset = self._std_offset + datetime.timedelta(hours=+1) + else: + self._dst_offset = ZERO + + if dstabbr and start is None: + self._start_delta = relativedelta.relativedelta( + hours=+2, month=4, day=1, weekday=relativedelta.SU(+1)) + else: + self._start_delta = start + + if dstabbr and end is None: + self._end_delta = relativedelta.relativedelta( + hours=+1, month=10, day=31, weekday=relativedelta.SU(-1)) + else: + self._end_delta = end + + self._dst_base_offset_ = self._dst_offset - self._std_offset + self.hasdst = bool(self._start_delta) + + def transitions(self, year): + """ + For a given year, get the DST on and off transition times, expressed + always on the standard time side. For zones with no transitions, this + function returns ``None``. + + :param year: + The year whose transitions you would like to query. + + :return: + Returns a :class:`tuple` of :class:`datetime.datetime` objects, + ``(dston, dstoff)`` for zones with an annual DST transition, or + ``None`` for fixed offset zones. + """ + if not self.hasdst: + return None + + base_year = datetime.datetime(year, 1, 1) + + start = base_year + self._start_delta + end = base_year + self._end_delta + + return (start, end) + + def __eq__(self, other): + if not isinstance(other, tzrange): + return NotImplemented + + return (self._std_abbr == other._std_abbr and + self._dst_abbr == other._dst_abbr and + self._std_offset == other._std_offset and + self._dst_offset == other._dst_offset and + self._start_delta == other._start_delta and + self._end_delta == other._end_delta) + + @property + def _dst_base_offset(self): + return self._dst_base_offset_ + + +@six.add_metaclass(_TzStrFactory) +class tzstr(tzrange): + """ + ``tzstr`` objects are time zone objects specified by a time-zone string as + it would be passed to a ``TZ`` variable on POSIX-style systems (see + the `GNU C Library: TZ Variable`_ for more details). + + There is one notable exception, which is that POSIX-style time zones use an + inverted offset format, so normally ``GMT+3`` would be parsed as an offset + 3 hours *behind* GMT. The ``tzstr`` time zone object will parse this as an + offset 3 hours *ahead* of GMT. If you would like to maintain the POSIX + behavior, pass a ``True`` value to ``posix_offset``. + + The :class:`tzrange` object provides the same functionality, but is + specified using :class:`relativedelta.relativedelta` objects. rather than + strings. + + :param s: + A time zone string in ``TZ`` variable format. This can be a + :class:`bytes` (2.x: :class:`str`), :class:`str` (2.x: + :class:`unicode`) or a stream emitting unicode characters + (e.g. :class:`StringIO`). + + :param posix_offset: + Optional. If set to ``True``, interpret strings such as ``GMT+3`` or + ``UTC+3`` as being 3 hours *behind* UTC rather than ahead, per the + POSIX standard. + + .. caution:: + + Prior to version 2.7.0, this function also supported time zones + in the format: + + * ``EST5EDT,4,0,6,7200,10,0,26,7200,3600`` + * ``EST5EDT,4,1,0,7200,10,-1,0,7200,3600`` + + This format is non-standard and has been deprecated; this function + will raise a :class:`DeprecatedTZFormatWarning` until + support is removed in a future version. + + .. _`GNU C Library: TZ Variable`: + https://www.gnu.org/software/libc/manual/html_node/TZ-Variable.html + """ + def __init__(self, s, posix_offset=False): + global parser + from dateutil.parser import _parser as parser + + self._s = s + + res = parser._parsetz(s) + if res is None or res.any_unused_tokens: + raise ValueError("unknown string format") + + # Here we break the compatibility with the TZ variable handling. + # GMT-3 actually *means* the timezone -3. + if res.stdabbr in ("GMT", "UTC") and not posix_offset: + res.stdoffset *= -1 + + # We must initialize it first, since _delta() needs + # _std_offset and _dst_offset set. Use False in start/end + # to avoid building it two times. + tzrange.__init__(self, res.stdabbr, res.stdoffset, + res.dstabbr, res.dstoffset, + start=False, end=False) + + if not res.dstabbr: + self._start_delta = None + self._end_delta = None + else: + self._start_delta = self._delta(res.start) + if self._start_delta: + self._end_delta = self._delta(res.end, isend=1) + + self.hasdst = bool(self._start_delta) + + def _delta(self, x, isend=0): + from dateutil import relativedelta + kwargs = {} + if x.month is not None: + kwargs["month"] = x.month + if x.weekday is not None: + kwargs["weekday"] = relativedelta.weekday(x.weekday, x.week) + if x.week > 0: + kwargs["day"] = 1 + else: + kwargs["day"] = 31 + elif x.day: + kwargs["day"] = x.day + elif x.yday is not None: + kwargs["yearday"] = x.yday + elif x.jyday is not None: + kwargs["nlyearday"] = x.jyday + if not kwargs: + # Default is to start on first sunday of april, and end + # on last sunday of october. + if not isend: + kwargs["month"] = 4 + kwargs["day"] = 1 + kwargs["weekday"] = relativedelta.SU(+1) + else: + kwargs["month"] = 10 + kwargs["day"] = 31 + kwargs["weekday"] = relativedelta.SU(-1) + if x.time is not None: + kwargs["seconds"] = x.time + else: + # Default is 2AM. + kwargs["seconds"] = 7200 + if isend: + # Convert to standard time, to follow the documented way + # of working with the extra hour. See the documentation + # of the tzinfo class. + delta = self._dst_offset - self._std_offset + kwargs["seconds"] -= delta.seconds + delta.days * 86400 + return relativedelta.relativedelta(**kwargs) + + def __repr__(self): + return "%s(%s)" % (self.__class__.__name__, repr(self._s)) + + +class _tzicalvtzcomp(object): + def __init__(self, tzoffsetfrom, tzoffsetto, isdst, + tzname=None, rrule=None): + self.tzoffsetfrom = datetime.timedelta(seconds=tzoffsetfrom) + self.tzoffsetto = datetime.timedelta(seconds=tzoffsetto) + self.tzoffsetdiff = self.tzoffsetto - self.tzoffsetfrom + self.isdst = isdst + self.tzname = tzname + self.rrule = rrule + + +class _tzicalvtz(_tzinfo): + def __init__(self, tzid, comps=[]): + super(_tzicalvtz, self).__init__() + + self._tzid = tzid + self._comps = comps + self._cachedate = [] + self._cachecomp = [] + self._cache_lock = _thread.allocate_lock() + + def _find_comp(self, dt): + if len(self._comps) == 1: + return self._comps[0] + + dt = dt.replace(tzinfo=None) + + try: + with self._cache_lock: + return self._cachecomp[self._cachedate.index( + (dt, self._fold(dt)))] + except ValueError: + pass + + lastcompdt = None + lastcomp = None + + for comp in self._comps: + compdt = self._find_compdt(comp, dt) + + if compdt and (not lastcompdt or lastcompdt < compdt): + lastcompdt = compdt + lastcomp = comp + + if not lastcomp: + # RFC says nothing about what to do when a given + # time is before the first onset date. We'll look for the + # first standard component, or the first component, if + # none is found. + for comp in self._comps: + if not comp.isdst: + lastcomp = comp + break + else: + lastcomp = comp[0] + + with self._cache_lock: + self._cachedate.insert(0, (dt, self._fold(dt))) + self._cachecomp.insert(0, lastcomp) + + if len(self._cachedate) > 10: + self._cachedate.pop() + self._cachecomp.pop() + + return lastcomp + + def _find_compdt(self, comp, dt): + if comp.tzoffsetdiff < ZERO and self._fold(dt): + dt -= comp.tzoffsetdiff + + compdt = comp.rrule.before(dt, inc=True) + + return compdt + + def utcoffset(self, dt): + if dt is None: + return None + + return self._find_comp(dt).tzoffsetto + + def dst(self, dt): + comp = self._find_comp(dt) + if comp.isdst: + return comp.tzoffsetdiff + else: + return ZERO + + @tzname_in_python2 + def tzname(self, dt): + return self._find_comp(dt).tzname + + def __repr__(self): + return "<tzicalvtz %s>" % repr(self._tzid) + + __reduce__ = object.__reduce__ + + +class tzical(object): + """ + This object is designed to parse an iCalendar-style ``VTIMEZONE`` structure + as set out in `RFC 5545`_ Section 4.6.5 into one or more `tzinfo` objects. + + :param `fileobj`: + A file or stream in iCalendar format, which should be UTF-8 encoded + with CRLF endings. + + .. _`RFC 5545`: https://tools.ietf.org/html/rfc5545 + """ + def __init__(self, fileobj): + global rrule + from dateutil import rrule + + if isinstance(fileobj, string_types): + self._s = fileobj + # ical should be encoded in UTF-8 with CRLF + fileobj = open(fileobj, 'r') + else: + self._s = getattr(fileobj, 'name', repr(fileobj)) + fileobj = _nullcontext(fileobj) + + self._vtz = {} + + with fileobj as fobj: + self._parse_rfc(fobj.read()) + + def keys(self): + """ + Retrieves the available time zones as a list. + """ + return list(self._vtz.keys()) + + def get(self, tzid=None): + """ + Retrieve a :py:class:`datetime.tzinfo` object by its ``tzid``. + + :param tzid: + If there is exactly one time zone available, omitting ``tzid`` + or passing :py:const:`None` value returns it. Otherwise a valid + key (which can be retrieved from :func:`keys`) is required. + + :raises ValueError: + Raised if ``tzid`` is not specified but there are either more + or fewer than 1 zone defined. + + :returns: + Returns either a :py:class:`datetime.tzinfo` object representing + the relevant time zone or :py:const:`None` if the ``tzid`` was + not found. + """ + if tzid is None: + if len(self._vtz) == 0: + raise ValueError("no timezones defined") + elif len(self._vtz) > 1: + raise ValueError("more than one timezone available") + tzid = next(iter(self._vtz)) + + return self._vtz.get(tzid) + + def _parse_offset(self, s): + s = s.strip() + if not s: + raise ValueError("empty offset") + if s[0] in ('+', '-'): + signal = (-1, +1)[s[0] == '+'] + s = s[1:] + else: + signal = +1 + if len(s) == 4: + return (int(s[:2]) * 3600 + int(s[2:]) * 60) * signal + elif len(s) == 6: + return (int(s[:2]) * 3600 + int(s[2:4]) * 60 + int(s[4:])) * signal + else: + raise ValueError("invalid offset: " + s) + + def _parse_rfc(self, s): + lines = s.splitlines() + if not lines: + raise ValueError("empty string") + + # Unfold + i = 0 + while i < len(lines): + line = lines[i].rstrip() + if not line: + del lines[i] + elif i > 0 and line[0] == " ": + lines[i-1] += line[1:] + del lines[i] + else: + i += 1 + + tzid = None + comps = [] + invtz = False + comptype = None + for line in lines: + if not line: + continue + name, value = line.split(':', 1) + parms = name.split(';') + if not parms: + raise ValueError("empty property name") + name = parms[0].upper() + parms = parms[1:] + if invtz: + if name == "BEGIN": + if value in ("STANDARD", "DAYLIGHT"): + # Process component + pass + else: + raise ValueError("unknown component: "+value) + comptype = value + founddtstart = False + tzoffsetfrom = None + tzoffsetto = None + rrulelines = [] + tzname = None + elif name == "END": + if value == "VTIMEZONE": + if comptype: + raise ValueError("component not closed: "+comptype) + if not tzid: + raise ValueError("mandatory TZID not found") + if not comps: + raise ValueError( + "at least one component is needed") + # Process vtimezone + self._vtz[tzid] = _tzicalvtz(tzid, comps) + invtz = False + elif value == comptype: + if not founddtstart: + raise ValueError("mandatory DTSTART not found") + if tzoffsetfrom is None: + raise ValueError( + "mandatory TZOFFSETFROM not found") + if tzoffsetto is None: + raise ValueError( + "mandatory TZOFFSETFROM not found") + # Process component + rr = None + if rrulelines: + rr = rrule.rrulestr("\n".join(rrulelines), + compatible=True, + ignoretz=True, + cache=True) + comp = _tzicalvtzcomp(tzoffsetfrom, tzoffsetto, + (comptype == "DAYLIGHT"), + tzname, rr) + comps.append(comp) + comptype = None + else: + raise ValueError("invalid component end: "+value) + elif comptype: + if name == "DTSTART": + # DTSTART in VTIMEZONE takes a subset of valid RRULE + # values under RFC 5545. + for parm in parms: + if parm != 'VALUE=DATE-TIME': + msg = ('Unsupported DTSTART param in ' + + 'VTIMEZONE: ' + parm) + raise ValueError(msg) + rrulelines.append(line) + founddtstart = True + elif name in ("RRULE", "RDATE", "EXRULE", "EXDATE"): + rrulelines.append(line) + elif name == "TZOFFSETFROM": + if parms: + raise ValueError( + "unsupported %s parm: %s " % (name, parms[0])) + tzoffsetfrom = self._parse_offset(value) + elif name == "TZOFFSETTO": + if parms: + raise ValueError( + "unsupported TZOFFSETTO parm: "+parms[0]) + tzoffsetto = self._parse_offset(value) + elif name == "TZNAME": + if parms: + raise ValueError( + "unsupported TZNAME parm: "+parms[0]) + tzname = value + elif name == "COMMENT": + pass + else: + raise ValueError("unsupported property: "+name) + else: + if name == "TZID": + if parms: + raise ValueError( + "unsupported TZID parm: "+parms[0]) + tzid = value + elif name in ("TZURL", "LAST-MODIFIED", "COMMENT"): + pass + else: + raise ValueError("unsupported property: "+name) + elif name == "BEGIN" and value == "VTIMEZONE": + tzid = None + comps = [] + invtz = True + + def __repr__(self): + return "%s(%s)" % (self.__class__.__name__, repr(self._s)) + + +if sys.platform != "win32": + TZFILES = ["/etc/localtime", "localtime"] + TZPATHS = ["/usr/share/zoneinfo", + "/usr/lib/zoneinfo", + "/usr/share/lib/zoneinfo", + "/etc/zoneinfo"] +else: + TZFILES = [] + TZPATHS = [] + + +def __get_gettz(): + tzlocal_classes = (tzlocal,) + if tzwinlocal is not None: + tzlocal_classes += (tzwinlocal,) + + class GettzFunc(object): + """ + Retrieve a time zone object from a string representation + + This function is intended to retrieve the :py:class:`tzinfo` subclass + that best represents the time zone that would be used if a POSIX + `TZ variable`_ were set to the same value. + + If no argument or an empty string is passed to ``gettz``, local time + is returned: + + .. code-block:: python3 + + >>> gettz() + tzfile('/etc/localtime') + + This function is also the preferred way to map IANA tz database keys + to :class:`tzfile` objects: + + .. code-block:: python3 + + >>> gettz('Pacific/Kiritimati') + tzfile('/usr/share/zoneinfo/Pacific/Kiritimati') + + On Windows, the standard is extended to include the Windows-specific + zone names provided by the operating system: + + .. code-block:: python3 + + >>> gettz('Egypt Standard Time') + tzwin('Egypt Standard Time') + + Passing a GNU ``TZ`` style string time zone specification returns a + :class:`tzstr` object: + + .. code-block:: python3 + + >>> gettz('AEST-10AEDT-11,M10.1.0/2,M4.1.0/3') + tzstr('AEST-10AEDT-11,M10.1.0/2,M4.1.0/3') + + :param name: + A time zone name (IANA, or, on Windows, Windows keys), location of + a ``tzfile(5)`` zoneinfo file or ``TZ`` variable style time zone + specifier. An empty string, no argument or ``None`` is interpreted + as local time. + + :return: + Returns an instance of one of ``dateutil``'s :py:class:`tzinfo` + subclasses. + + .. versionchanged:: 2.7.0 + + After version 2.7.0, any two calls to ``gettz`` using the same + input strings will return the same object: + + .. code-block:: python3 + + >>> tz.gettz('America/Chicago') is tz.gettz('America/Chicago') + True + + In addition to improving performance, this ensures that + `"same zone" semantics`_ are used for datetimes in the same zone. + + + .. _`TZ variable`: + https://www.gnu.org/software/libc/manual/html_node/TZ-Variable.html + + .. _`"same zone" semantics`: + https://blog.ganssle.io/articles/2018/02/aware-datetime-arithmetic.html + """ + def __init__(self): + + self.__instances = weakref.WeakValueDictionary() + self.__strong_cache_size = 8 + self.__strong_cache = OrderedDict() + self._cache_lock = _thread.allocate_lock() + + def __call__(self, name=None): + with self._cache_lock: + rv = self.__instances.get(name, None) + + if rv is None: + rv = self.nocache(name=name) + if not (name is None + or isinstance(rv, tzlocal_classes) + or rv is None): + # tzlocal is slightly more complicated than the other + # time zone providers because it depends on environment + # at construction time, so don't cache that. + # + # We also cannot store weak references to None, so we + # will also not store that. + self.__instances[name] = rv + else: + # No need for strong caching, return immediately + return rv + + self.__strong_cache[name] = self.__strong_cache.pop(name, rv) + + if len(self.__strong_cache) > self.__strong_cache_size: + self.__strong_cache.popitem(last=False) + + return rv + + def set_cache_size(self, size): + with self._cache_lock: + self.__strong_cache_size = size + while len(self.__strong_cache) > size: + self.__strong_cache.popitem(last=False) + + def cache_clear(self): + with self._cache_lock: + self.__instances = weakref.WeakValueDictionary() + self.__strong_cache.clear() + + @staticmethod + def nocache(name=None): + """A non-cached version of gettz""" + tz = None + if not name: + try: + name = os.environ["TZ"] + except KeyError: + pass + if name is None or name in ("", ":"): + for filepath in TZFILES: + if not os.path.isabs(filepath): + filename = filepath + for path in TZPATHS: + filepath = os.path.join(path, filename) + if os.path.isfile(filepath): + break + else: + continue + if os.path.isfile(filepath): + try: + tz = tzfile(filepath) + break + except (IOError, OSError, ValueError): + pass + else: + tz = tzlocal() + else: + try: + if name.startswith(":"): + name = name[1:] + except TypeError as e: + if isinstance(name, bytes): + new_msg = "gettz argument should be str, not bytes" + six.raise_from(TypeError(new_msg), e) + else: + raise + if os.path.isabs(name): + if os.path.isfile(name): + tz = tzfile(name) + else: + tz = None + else: + for path in TZPATHS: + filepath = os.path.join(path, name) + if not os.path.isfile(filepath): + filepath = filepath.replace(' ', '_') + if not os.path.isfile(filepath): + continue + try: + tz = tzfile(filepath) + break + except (IOError, OSError, ValueError): + pass + else: + tz = None + if tzwin is not None: + try: + tz = tzwin(name) + except (WindowsError, UnicodeEncodeError): + # UnicodeEncodeError is for Python 2.7 compat + tz = None + + if not tz: + from dateutil.zoneinfo import get_zonefile_instance + tz = get_zonefile_instance().get(name) + + if not tz: + for c in name: + # name is not a tzstr unless it has at least + # one offset. For short values of "name", an + # explicit for loop seems to be the fastest way + # To determine if a string contains a digit + if c in "0123456789": + try: + tz = tzstr(name) + except ValueError: + pass + break + else: + if name in ("GMT", "UTC"): + tz = UTC + elif name in time.tzname: + tz = tzlocal() + return tz + + return GettzFunc() + + +gettz = __get_gettz() +del __get_gettz + + +def datetime_exists(dt, tz=None): + """ + Given a datetime and a time zone, determine whether or not a given datetime + would fall in a gap. + + :param dt: + A :class:`datetime.datetime` (whose time zone will be ignored if ``tz`` + is provided.) + + :param tz: + A :class:`datetime.tzinfo` with support for the ``fold`` attribute. If + ``None`` or not provided, the datetime's own time zone will be used. + + :return: + Returns a boolean value whether or not the "wall time" exists in + ``tz``. + + .. versionadded:: 2.7.0 + """ + if tz is None: + if dt.tzinfo is None: + raise ValueError('Datetime is naive and no time zone provided.') + tz = dt.tzinfo + + dt = dt.replace(tzinfo=None) + + # This is essentially a test of whether or not the datetime can survive + # a round trip to UTC. + dt_rt = dt.replace(tzinfo=tz).astimezone(UTC).astimezone(tz) + dt_rt = dt_rt.replace(tzinfo=None) + + return dt == dt_rt + + +def datetime_ambiguous(dt, tz=None): + """ + Given a datetime and a time zone, determine whether or not a given datetime + is ambiguous (i.e if there are two times differentiated only by their DST + status). + + :param dt: + A :class:`datetime.datetime` (whose time zone will be ignored if ``tz`` + is provided.) + + :param tz: + A :class:`datetime.tzinfo` with support for the ``fold`` attribute. If + ``None`` or not provided, the datetime's own time zone will be used. + + :return: + Returns a boolean value whether or not the "wall time" is ambiguous in + ``tz``. + + .. versionadded:: 2.6.0 + """ + if tz is None: + if dt.tzinfo is None: + raise ValueError('Datetime is naive and no time zone provided.') + + tz = dt.tzinfo + + # If a time zone defines its own "is_ambiguous" function, we'll use that. + is_ambiguous_fn = getattr(tz, 'is_ambiguous', None) + if is_ambiguous_fn is not None: + try: + return tz.is_ambiguous(dt) + except Exception: + pass + + # If it doesn't come out and tell us it's ambiguous, we'll just check if + # the fold attribute has any effect on this particular date and time. + dt = dt.replace(tzinfo=tz) + wall_0 = enfold(dt, fold=0) + wall_1 = enfold(dt, fold=1) + + same_offset = wall_0.utcoffset() == wall_1.utcoffset() + same_dst = wall_0.dst() == wall_1.dst() + + return not (same_offset and same_dst) + + +def resolve_imaginary(dt): + """ + Given a datetime that may be imaginary, return an existing datetime. + + This function assumes that an imaginary datetime represents what the + wall time would be in a zone had the offset transition not occurred, so + it will always fall forward by the transition's change in offset. + + .. doctest:: + + >>> from dateutil import tz + >>> from datetime import datetime + >>> NYC = tz.gettz('America/New_York') + >>> print(tz.resolve_imaginary(datetime(2017, 3, 12, 2, 30, tzinfo=NYC))) + 2017-03-12 03:30:00-04:00 + + >>> KIR = tz.gettz('Pacific/Kiritimati') + >>> print(tz.resolve_imaginary(datetime(1995, 1, 1, 12, 30, tzinfo=KIR))) + 1995-01-02 12:30:00+14:00 + + As a note, :func:`datetime.astimezone` is guaranteed to produce a valid, + existing datetime, so a round-trip to and from UTC is sufficient to get + an extant datetime, however, this generally "falls back" to an earlier time + rather than falling forward to the STD side (though no guarantees are made + about this behavior). + + :param dt: + A :class:`datetime.datetime` which may or may not exist. + + :return: + Returns an existing :class:`datetime.datetime`. If ``dt`` was not + imaginary, the datetime returned is guaranteed to be the same object + passed to the function. + + .. versionadded:: 2.7.0 + """ + if dt.tzinfo is not None and not datetime_exists(dt): + + curr_offset = (dt + datetime.timedelta(hours=24)).utcoffset() + old_offset = (dt - datetime.timedelta(hours=24)).utcoffset() + + dt += curr_offset - old_offset + + return dt + + +def _datetime_to_timestamp(dt): + """ + Convert a :class:`datetime.datetime` object to an epoch timestamp in + seconds since January 1, 1970, ignoring the time zone. + """ + return (dt.replace(tzinfo=None) - EPOCH).total_seconds() + + +if sys.version_info >= (3, 6): + def _get_supported_offset(second_offset): + return second_offset +else: + def _get_supported_offset(second_offset): + # For python pre-3.6, round to full-minutes if that's not the case. + # Python's datetime doesn't accept sub-minute timezones. Check + # http://python.org/sf/1447945 or https://bugs.python.org/issue5288 + # for some information. + old_offset = second_offset + calculated_offset = 60 * ((second_offset + 30) // 60) + return calculated_offset + + +try: + # Python 3.7 feature + from contextlib import nullcontext as _nullcontext +except ImportError: + class _nullcontext(object): + """ + Class for wrapping contexts so that they are passed through in a + with statement. + """ + def __init__(self, context): + self.context = context + + def __enter__(self): + return self.context + + def __exit__(*args, **kwargs): + pass + +# vim:ts=4:sw=4:et diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tz/win.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tz/win.py new file mode 100644 index 0000000000000000000000000000000000000000..cde07ba792c40903f0c334839140173b39fd8124 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tz/win.py @@ -0,0 +1,370 @@ +# -*- coding: utf-8 -*- +""" +This module provides an interface to the native time zone data on Windows, +including :py:class:`datetime.tzinfo` implementations. + +Attempting to import this module on a non-Windows platform will raise an +:py:obj:`ImportError`. +""" +# This code was originally contributed by Jeffrey Harris. +import datetime +import struct + +from six.moves import winreg +from six import text_type + +try: + import ctypes + from ctypes import wintypes +except ValueError: + # ValueError is raised on non-Windows systems for some horrible reason. + raise ImportError("Running tzwin on non-Windows system") + +from ._common import tzrangebase + +__all__ = ["tzwin", "tzwinlocal", "tzres"] + +ONEWEEK = datetime.timedelta(7) + +TZKEYNAMENT = r"SOFTWARE\Microsoft\Windows NT\CurrentVersion\Time Zones" +TZKEYNAME9X = r"SOFTWARE\Microsoft\Windows\CurrentVersion\Time Zones" +TZLOCALKEYNAME = r"SYSTEM\CurrentControlSet\Control\TimeZoneInformation" + + +def _settzkeyname(): + handle = winreg.ConnectRegistry(None, winreg.HKEY_LOCAL_MACHINE) + try: + winreg.OpenKey(handle, TZKEYNAMENT).Close() + TZKEYNAME = TZKEYNAMENT + except WindowsError: + TZKEYNAME = TZKEYNAME9X + handle.Close() + return TZKEYNAME + + +TZKEYNAME = _settzkeyname() + + +class tzres(object): + """ + Class for accessing ``tzres.dll``, which contains timezone name related + resources. + + .. versionadded:: 2.5.0 + """ + p_wchar = ctypes.POINTER(wintypes.WCHAR) # Pointer to a wide char + + def __init__(self, tzres_loc='tzres.dll'): + # Load the user32 DLL so we can load strings from tzres + user32 = ctypes.WinDLL('user32') + + # Specify the LoadStringW function + user32.LoadStringW.argtypes = (wintypes.HINSTANCE, + wintypes.UINT, + wintypes.LPWSTR, + ctypes.c_int) + + self.LoadStringW = user32.LoadStringW + self._tzres = ctypes.WinDLL(tzres_loc) + self.tzres_loc = tzres_loc + + def load_name(self, offset): + """ + Load a timezone name from a DLL offset (integer). + + >>> from dateutil.tzwin import tzres + >>> tzr = tzres() + >>> print(tzr.load_name(112)) + 'Eastern Standard Time' + + :param offset: + A positive integer value referring to a string from the tzres dll. + + .. note:: + + Offsets found in the registry are generally of the form + ``@tzres.dll,-114``. The offset in this case is 114, not -114. + + """ + resource = self.p_wchar() + lpBuffer = ctypes.cast(ctypes.byref(resource), wintypes.LPWSTR) + nchar = self.LoadStringW(self._tzres._handle, offset, lpBuffer, 0) + return resource[:nchar] + + def name_from_string(self, tzname_str): + """ + Parse strings as returned from the Windows registry into the time zone + name as defined in the registry. + + >>> from dateutil.tzwin import tzres + >>> tzr = tzres() + >>> print(tzr.name_from_string('@tzres.dll,-251')) + 'Dateline Daylight Time' + >>> print(tzr.name_from_string('Eastern Standard Time')) + 'Eastern Standard Time' + + :param tzname_str: + A timezone name string as returned from a Windows registry key. + + :return: + Returns the localized timezone string from tzres.dll if the string + is of the form `@tzres.dll,-offset`, else returns the input string. + """ + if not tzname_str.startswith('@'): + return tzname_str + + name_splt = tzname_str.split(',-') + try: + offset = int(name_splt[1]) + except: + raise ValueError("Malformed timezone string.") + + return self.load_name(offset) + + +class tzwinbase(tzrangebase): + """tzinfo class based on win32's timezones available in the registry.""" + def __init__(self): + raise NotImplementedError('tzwinbase is an abstract base class') + + def __eq__(self, other): + # Compare on all relevant dimensions, including name. + if not isinstance(other, tzwinbase): + return NotImplemented + + return (self._std_offset == other._std_offset and + self._dst_offset == other._dst_offset and + self._stddayofweek == other._stddayofweek and + self._dstdayofweek == other._dstdayofweek and + self._stdweeknumber == other._stdweeknumber and + self._dstweeknumber == other._dstweeknumber and + self._stdhour == other._stdhour and + self._dsthour == other._dsthour and + self._stdminute == other._stdminute and + self._dstminute == other._dstminute and + self._std_abbr == other._std_abbr and + self._dst_abbr == other._dst_abbr) + + @staticmethod + def list(): + """Return a list of all time zones known to the system.""" + with winreg.ConnectRegistry(None, winreg.HKEY_LOCAL_MACHINE) as handle: + with winreg.OpenKey(handle, TZKEYNAME) as tzkey: + result = [winreg.EnumKey(tzkey, i) + for i in range(winreg.QueryInfoKey(tzkey)[0])] + return result + + def display(self): + """ + Return the display name of the time zone. + """ + return self._display + + def transitions(self, year): + """ + For a given year, get the DST on and off transition times, expressed + always on the standard time side. For zones with no transitions, this + function returns ``None``. + + :param year: + The year whose transitions you would like to query. + + :return: + Returns a :class:`tuple` of :class:`datetime.datetime` objects, + ``(dston, dstoff)`` for zones with an annual DST transition, or + ``None`` for fixed offset zones. + """ + + if not self.hasdst: + return None + + dston = picknthweekday(year, self._dstmonth, self._dstdayofweek, + self._dsthour, self._dstminute, + self._dstweeknumber) + + dstoff = picknthweekday(year, self._stdmonth, self._stddayofweek, + self._stdhour, self._stdminute, + self._stdweeknumber) + + # Ambiguous dates default to the STD side + dstoff -= self._dst_base_offset + + return dston, dstoff + + def _get_hasdst(self): + return self._dstmonth != 0 + + @property + def _dst_base_offset(self): + return self._dst_base_offset_ + + +class tzwin(tzwinbase): + """ + Time zone object created from the zone info in the Windows registry + + These are similar to :py:class:`dateutil.tz.tzrange` objects in that + the time zone data is provided in the format of a single offset rule + for either 0 or 2 time zone transitions per year. + + :param: name + The name of a Windows time zone key, e.g. "Eastern Standard Time". + The full list of keys can be retrieved with :func:`tzwin.list`. + """ + + def __init__(self, name): + self._name = name + + with winreg.ConnectRegistry(None, winreg.HKEY_LOCAL_MACHINE) as handle: + tzkeyname = text_type("{kn}\\{name}").format(kn=TZKEYNAME, name=name) + with winreg.OpenKey(handle, tzkeyname) as tzkey: + keydict = valuestodict(tzkey) + + self._std_abbr = keydict["Std"] + self._dst_abbr = keydict["Dlt"] + + self._display = keydict["Display"] + + # See http://ww_winreg.jsiinc.com/SUBA/tip0300/rh0398.htm + tup = struct.unpack("=3l16h", keydict["TZI"]) + stdoffset = -tup[0]-tup[1] # Bias + StandardBias * -1 + dstoffset = stdoffset-tup[2] # + DaylightBias * -1 + self._std_offset = datetime.timedelta(minutes=stdoffset) + self._dst_offset = datetime.timedelta(minutes=dstoffset) + + # for the meaning see the win32 TIME_ZONE_INFORMATION structure docs + # http://msdn.microsoft.com/en-us/library/windows/desktop/ms725481(v=vs.85).aspx + (self._stdmonth, + self._stddayofweek, # Sunday = 0 + self._stdweeknumber, # Last = 5 + self._stdhour, + self._stdminute) = tup[4:9] + + (self._dstmonth, + self._dstdayofweek, # Sunday = 0 + self._dstweeknumber, # Last = 5 + self._dsthour, + self._dstminute) = tup[12:17] + + self._dst_base_offset_ = self._dst_offset - self._std_offset + self.hasdst = self._get_hasdst() + + def __repr__(self): + return "tzwin(%s)" % repr(self._name) + + def __reduce__(self): + return (self.__class__, (self._name,)) + + +class tzwinlocal(tzwinbase): + """ + Class representing the local time zone information in the Windows registry + + While :class:`dateutil.tz.tzlocal` makes system calls (via the :mod:`time` + module) to retrieve time zone information, ``tzwinlocal`` retrieves the + rules directly from the Windows registry and creates an object like + :class:`dateutil.tz.tzwin`. + + Because Windows does not have an equivalent of :func:`time.tzset`, on + Windows, :class:`dateutil.tz.tzlocal` instances will always reflect the + time zone settings *at the time that the process was started*, meaning + changes to the machine's time zone settings during the run of a program + on Windows will **not** be reflected by :class:`dateutil.tz.tzlocal`. + Because ``tzwinlocal`` reads the registry directly, it is unaffected by + this issue. + """ + def __init__(self): + with winreg.ConnectRegistry(None, winreg.HKEY_LOCAL_MACHINE) as handle: + with winreg.OpenKey(handle, TZLOCALKEYNAME) as tzlocalkey: + keydict = valuestodict(tzlocalkey) + + self._std_abbr = keydict["StandardName"] + self._dst_abbr = keydict["DaylightName"] + + try: + tzkeyname = text_type('{kn}\\{sn}').format(kn=TZKEYNAME, + sn=self._std_abbr) + with winreg.OpenKey(handle, tzkeyname) as tzkey: + _keydict = valuestodict(tzkey) + self._display = _keydict["Display"] + except OSError: + self._display = None + + stdoffset = -keydict["Bias"]-keydict["StandardBias"] + dstoffset = stdoffset-keydict["DaylightBias"] + + self._std_offset = datetime.timedelta(minutes=stdoffset) + self._dst_offset = datetime.timedelta(minutes=dstoffset) + + # For reasons unclear, in this particular key, the day of week has been + # moved to the END of the SYSTEMTIME structure. + tup = struct.unpack("=8h", keydict["StandardStart"]) + + (self._stdmonth, + self._stdweeknumber, # Last = 5 + self._stdhour, + self._stdminute) = tup[1:5] + + self._stddayofweek = tup[7] + + tup = struct.unpack("=8h", keydict["DaylightStart"]) + + (self._dstmonth, + self._dstweeknumber, # Last = 5 + self._dsthour, + self._dstminute) = tup[1:5] + + self._dstdayofweek = tup[7] + + self._dst_base_offset_ = self._dst_offset - self._std_offset + self.hasdst = self._get_hasdst() + + def __repr__(self): + return "tzwinlocal()" + + def __str__(self): + # str will return the standard name, not the daylight name. + return "tzwinlocal(%s)" % repr(self._std_abbr) + + def __reduce__(self): + return (self.__class__, ()) + + +def picknthweekday(year, month, dayofweek, hour, minute, whichweek): + """ dayofweek == 0 means Sunday, whichweek 5 means last instance """ + first = datetime.datetime(year, month, 1, hour, minute) + + # This will work if dayofweek is ISO weekday (1-7) or Microsoft-style (0-6), + # Because 7 % 7 = 0 + weekdayone = first.replace(day=((dayofweek - first.isoweekday()) % 7) + 1) + wd = weekdayone + ((whichweek - 1) * ONEWEEK) + if (wd.month != month): + wd -= ONEWEEK + + return wd + + +def valuestodict(key): + """Convert a registry key's values to a dictionary.""" + dout = {} + size = winreg.QueryInfoKey(key)[1] + tz_res = None + + for i in range(size): + key_name, value, dtype = winreg.EnumValue(key, i) + if dtype == winreg.REG_DWORD or dtype == winreg.REG_DWORD_LITTLE_ENDIAN: + # If it's a DWORD (32-bit integer), it's stored as unsigned - convert + # that to a proper signed integer + if value & (1 << 31): + value = value - (1 << 32) + elif dtype == winreg.REG_SZ: + # If it's a reference to the tzres DLL, load the actual string + if value.startswith('@tzres'): + tz_res = tz_res or tzres() + value = tz_res.name_from_string(value) + + value = value.rstrip('\x00') # Remove trailing nulls + + dout[key_name] = value + + return dout diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tzwin.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tzwin.py new file mode 100644 index 0000000000000000000000000000000000000000..cebc673e40fc376653ebf037e96f0a6d0b33e906 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/tzwin.py @@ -0,0 +1,2 @@ +# tzwin has moved to dateutil.tz.win +from .tz.win import * diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/utils.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/utils.py new file mode 100644 index 0000000000000000000000000000000000000000..dd2d245a0bebcd5fc37ac20526aabbd5358dab0e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/utils.py @@ -0,0 +1,71 @@ +# -*- coding: utf-8 -*- +""" +This module offers general convenience and utility functions for dealing with +datetimes. + +.. versionadded:: 2.7.0 +""" +from __future__ import unicode_literals + +from datetime import datetime, time + + +def today(tzinfo=None): + """ + Returns a :py:class:`datetime` representing the current day at midnight + + :param tzinfo: + The time zone to attach (also used to determine the current day). + + :return: + A :py:class:`datetime.datetime` object representing the current day + at midnight. + """ + + dt = datetime.now(tzinfo) + return datetime.combine(dt.date(), time(0, tzinfo=tzinfo)) + + +def default_tzinfo(dt, tzinfo): + """ + Sets the ``tzinfo`` parameter on naive datetimes only + + This is useful for example when you are provided a datetime that may have + either an implicit or explicit time zone, such as when parsing a time zone + string. + + .. doctest:: + + >>> from dateutil.tz import tzoffset + >>> from dateutil.parser import parse + >>> from dateutil.utils import default_tzinfo + >>> dflt_tz = tzoffset("EST", -18000) + >>> print(default_tzinfo(parse('2014-01-01 12:30 UTC'), dflt_tz)) + 2014-01-01 12:30:00+00:00 + >>> print(default_tzinfo(parse('2014-01-01 12:30'), dflt_tz)) + 2014-01-01 12:30:00-05:00 + + :param dt: + The datetime on which to replace the time zone + + :param tzinfo: + The :py:class:`datetime.tzinfo` subclass instance to assign to + ``dt`` if (and only if) it is naive. + + :return: + Returns an aware :py:class:`datetime.datetime`. + """ + if dt.tzinfo is not None: + return dt + else: + return dt.replace(tzinfo=tzinfo) + + +def within_delta(dt1, dt2, delta): + """ + Useful for comparing two datetimes that may have a negligible difference + to be considered equal. + """ + delta = abs(delta) + difference = dt1 - dt2 + return -delta <= difference <= delta diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/zoneinfo/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/zoneinfo/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..34f11ad66c88047f2c049a4cdcc937b4b78ea6d6 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/zoneinfo/__init__.py @@ -0,0 +1,167 @@ +# -*- coding: utf-8 -*- +import warnings +import json + +from tarfile import TarFile +from pkgutil import get_data +from io import BytesIO + +from dateutil.tz import tzfile as _tzfile + +__all__ = ["get_zonefile_instance", "gettz", "gettz_db_metadata"] + +ZONEFILENAME = "dateutil-zoneinfo.tar.gz" +METADATA_FN = 'METADATA' + + +class tzfile(_tzfile): + def __reduce__(self): + return (gettz, (self._filename,)) + + +def getzoneinfofile_stream(): + try: + return BytesIO(get_data(__name__, ZONEFILENAME)) + except IOError as e: # TODO switch to FileNotFoundError? + warnings.warn("I/O error({0}): {1}".format(e.errno, e.strerror)) + return None + + +class ZoneInfoFile(object): + def __init__(self, zonefile_stream=None): + if zonefile_stream is not None: + with TarFile.open(fileobj=zonefile_stream) as tf: + self.zones = {zf.name: tzfile(tf.extractfile(zf), filename=zf.name) + for zf in tf.getmembers() + if zf.isfile() and zf.name != METADATA_FN} + # deal with links: They'll point to their parent object. Less + # waste of memory + links = {zl.name: self.zones[zl.linkname] + for zl in tf.getmembers() if + zl.islnk() or zl.issym()} + self.zones.update(links) + try: + metadata_json = tf.extractfile(tf.getmember(METADATA_FN)) + metadata_str = metadata_json.read().decode('UTF-8') + self.metadata = json.loads(metadata_str) + except KeyError: + # no metadata in tar file + self.metadata = None + else: + self.zones = {} + self.metadata = None + + def get(self, name, default=None): + """ + Wrapper for :func:`ZoneInfoFile.zones.get`. This is a convenience method + for retrieving zones from the zone dictionary. + + :param name: + The name of the zone to retrieve. (Generally IANA zone names) + + :param default: + The value to return in the event of a missing key. + + .. versionadded:: 2.6.0 + + """ + return self.zones.get(name, default) + + +# The current API has gettz as a module function, although in fact it taps into +# a stateful class. So as a workaround for now, without changing the API, we +# will create a new "global" class instance the first time a user requests a +# timezone. Ugly, but adheres to the api. +# +# TODO: Remove after deprecation period. +_CLASS_ZONE_INSTANCE = [] + + +def get_zonefile_instance(new_instance=False): + """ + This is a convenience function which provides a :class:`ZoneInfoFile` + instance using the data provided by the ``dateutil`` package. By default, it + caches a single instance of the ZoneInfoFile object and returns that. + + :param new_instance: + If ``True``, a new instance of :class:`ZoneInfoFile` is instantiated and + used as the cached instance for the next call. Otherwise, new instances + are created only as necessary. + + :return: + Returns a :class:`ZoneInfoFile` object. + + .. versionadded:: 2.6 + """ + if new_instance: + zif = None + else: + zif = getattr(get_zonefile_instance, '_cached_instance', None) + + if zif is None: + zif = ZoneInfoFile(getzoneinfofile_stream()) + + get_zonefile_instance._cached_instance = zif + + return zif + + +def gettz(name): + """ + This retrieves a time zone from the local zoneinfo tarball that is packaged + with dateutil. + + :param name: + An IANA-style time zone name, as found in the zoneinfo file. + + :return: + Returns a :class:`dateutil.tz.tzfile` time zone object. + + .. warning:: + It is generally inadvisable to use this function, and it is only + provided for API compatibility with earlier versions. This is *not* + equivalent to ``dateutil.tz.gettz()``, which selects an appropriate + time zone based on the inputs, favoring system zoneinfo. This is ONLY + for accessing the dateutil-specific zoneinfo (which may be out of + date compared to the system zoneinfo). + + .. deprecated:: 2.6 + If you need to use a specific zoneinfofile over the system zoneinfo, + instantiate a :class:`dateutil.zoneinfo.ZoneInfoFile` object and call + :func:`dateutil.zoneinfo.ZoneInfoFile.get(name)` instead. + + Use :func:`get_zonefile_instance` to retrieve an instance of the + dateutil-provided zoneinfo. + """ + warnings.warn("zoneinfo.gettz() will be removed in future versions, " + "to use the dateutil-provided zoneinfo files, instantiate a " + "ZoneInfoFile object and use ZoneInfoFile.zones.get() " + "instead. See the documentation for details.", + DeprecationWarning) + + if len(_CLASS_ZONE_INSTANCE) == 0: + _CLASS_ZONE_INSTANCE.append(ZoneInfoFile(getzoneinfofile_stream())) + return _CLASS_ZONE_INSTANCE[0].zones.get(name) + + +def gettz_db_metadata(): + """ Get the zonefile metadata + + See `zonefile_metadata`_ + + :returns: + A dictionary with the database metadata + + .. deprecated:: 2.6 + See deprecation warning in :func:`zoneinfo.gettz`. To get metadata, + query the attribute ``zoneinfo.ZoneInfoFile.metadata``. + """ + warnings.warn("zoneinfo.gettz_db_metadata() will be removed in future " + "versions, to use the dateutil-provided zoneinfo files, " + "ZoneInfoFile object and query the 'metadata' attribute " + "instead. See the documentation for details.", + DeprecationWarning) + + if len(_CLASS_ZONE_INSTANCE) == 0: + _CLASS_ZONE_INSTANCE.append(ZoneInfoFile(getzoneinfofile_stream())) + return _CLASS_ZONE_INSTANCE[0].metadata diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/zoneinfo/rebuild.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/zoneinfo/rebuild.py new file mode 100644 index 0000000000000000000000000000000000000000..684c6586f091350c347f2b6150935f5214ffec27 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/dateutil/zoneinfo/rebuild.py @@ -0,0 +1,75 @@ +import logging +import os +import tempfile +import shutil +import json +from subprocess import check_call, check_output +from tarfile import TarFile + +from dateutil.zoneinfo import METADATA_FN, ZONEFILENAME + + +def rebuild(filename, tag=None, format="gz", zonegroups=[], metadata=None): + """Rebuild the internal timezone info in dateutil/zoneinfo/zoneinfo*tar* + + filename is the timezone tarball from ``ftp.iana.org/tz``. + + """ + tmpdir = tempfile.mkdtemp() + zonedir = os.path.join(tmpdir, "zoneinfo") + moduledir = os.path.dirname(__file__) + try: + with TarFile.open(filename) as tf: + for name in zonegroups: + tf.extract(name, tmpdir) + filepaths = [os.path.join(tmpdir, n) for n in zonegroups] + + _run_zic(zonedir, filepaths) + + # write metadata file + with open(os.path.join(zonedir, METADATA_FN), 'w') as f: + json.dump(metadata, f, indent=4, sort_keys=True) + target = os.path.join(moduledir, ZONEFILENAME) + with TarFile.open(target, "w:%s" % format) as tf: + for entry in os.listdir(zonedir): + entrypath = os.path.join(zonedir, entry) + tf.add(entrypath, entry) + finally: + shutil.rmtree(tmpdir) + + +def _run_zic(zonedir, filepaths): + """Calls the ``zic`` compiler in a compatible way to get a "fat" binary. + + Recent versions of ``zic`` default to ``-b slim``, while older versions + don't even have the ``-b`` option (but default to "fat" binaries). The + current version of dateutil does not support Version 2+ TZif files, which + causes problems when used in conjunction with "slim" binaries, so this + function is used to ensure that we always get a "fat" binary. + """ + + try: + help_text = check_output(["zic", "--help"]) + except OSError as e: + _print_on_nosuchfile(e) + raise + + if b"-b " in help_text: + bloat_args = ["-b", "fat"] + else: + bloat_args = [] + + check_call(["zic"] + bloat_args + ["-d", zonedir] + filepaths) + + +def _print_on_nosuchfile(e): + """Print helpful troubleshooting message + + e is an exception raised by subprocess.check_call() + + """ + if e.errno == 2: + logging.error( + "Could not find zic. Perhaps you need to install " + "libc-bin or some other package that provides it, " + "or it's not in your PATH?") diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/INSTALLER b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/INSTALLER new file mode 100644 index 0000000000000000000000000000000000000000..a34a7e56db35cc4c85bfa166244b3d63a6a240d4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/INSTALLER @@ -0,0 +1 @@ +conda diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/METADATA b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/METADATA new file mode 100644 index 0000000000000000000000000000000000000000..c0f24aef12adf85421f47aa6832fe47a27796c26 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/METADATA @@ -0,0 +1,206 @@ +Metadata-Version: 2.4 +Name: python-dateutil +Version: 2.9.0.post0 +Summary: Extensions to the standard Python datetime module +Home-page: https://github.com/dateutil/dateutil +Author: Gustavo Niemeyer +Author-email: gustavo@niemeyer.net +Maintainer: Paul Ganssle +Maintainer-email: dateutil@python.org +License: Dual License +Project-URL: Documentation, https://dateutil.readthedocs.io/en/stable/ +Project-URL: Source, https://github.com/dateutil/dateutil +Classifier: Development Status :: 5 - Production/Stable +Classifier: Intended Audience :: Developers +Classifier: License :: OSI Approved :: BSD License +Classifier: License :: OSI Approved :: Apache Software License +Classifier: Programming Language :: Python +Classifier: Programming Language :: Python :: 2 +Classifier: Programming Language :: Python :: 2.7 +Classifier: Programming Language :: Python :: 3 +Classifier: Programming Language :: Python :: 3.3 +Classifier: Programming Language :: Python :: 3.4 +Classifier: Programming Language :: Python :: 3.5 +Classifier: Programming Language :: Python :: 3.6 +Classifier: Programming Language :: Python :: 3.7 +Classifier: Programming Language :: Python :: 3.8 +Classifier: Programming Language :: Python :: 3.9 +Classifier: Programming Language :: Python :: 3.10 +Classifier: Programming Language :: Python :: 3.11 +Classifier: Programming Language :: Python :: 3.12 +Classifier: Topic :: Software Development :: Libraries +Requires-Python: !=3.0.*,!=3.1.*,!=3.2.*,>=2.7 +Description-Content-Type: text/x-rst +License-File: LICENSE +Requires-Dist: six>=1.5 +Dynamic: description +Dynamic: license-file + +dateutil - powerful extensions to datetime +========================================== + +|pypi| |support| |licence| + +|gitter| |readthedocs| + +|travis| |appveyor| |pipelines| |coverage| + +.. |pypi| image:: https://img.shields.io/pypi/v/python-dateutil.svg?style=flat-square + :target: https://pypi.org/project/python-dateutil/ + :alt: pypi version + +.. |support| image:: https://img.shields.io/pypi/pyversions/python-dateutil.svg?style=flat-square + :target: https://pypi.org/project/python-dateutil/ + :alt: supported Python version + +.. |travis| image:: https://img.shields.io/travis/dateutil/dateutil/master.svg?style=flat-square&label=Travis%20Build + :target: https://travis-ci.org/dateutil/dateutil + :alt: travis build status + +.. |appveyor| image:: https://img.shields.io/appveyor/ci/dateutil/dateutil/master.svg?style=flat-square&logo=appveyor + :target: https://ci.appveyor.com/project/dateutil/dateutil + :alt: appveyor build status + +.. |pipelines| image:: https://dev.azure.com/pythondateutilazure/dateutil/_apis/build/status/dateutil.dateutil?branchName=master + :target: https://dev.azure.com/pythondateutilazure/dateutil/_build/latest?definitionId=1&branchName=master + :alt: azure pipelines build status + +.. |coverage| image:: https://codecov.io/gh/dateutil/dateutil/branch/master/graphs/badge.svg?branch=master + :target: https://codecov.io/gh/dateutil/dateutil?branch=master + :alt: Code coverage + +.. |gitter| image:: https://badges.gitter.im/dateutil/dateutil.svg + :alt: Join the chat at https://gitter.im/dateutil/dateutil + :target: https://gitter.im/dateutil/dateutil + +.. |licence| image:: https://img.shields.io/pypi/l/python-dateutil.svg?style=flat-square + :target: https://pypi.org/project/python-dateutil/ + :alt: licence + +.. |readthedocs| image:: https://img.shields.io/readthedocs/dateutil/latest.svg?style=flat-square&label=Read%20the%20Docs + :alt: Read the documentation at https://dateutil.readthedocs.io/en/latest/ + :target: https://dateutil.readthedocs.io/en/latest/ + +The `dateutil` module provides powerful extensions to +the standard `datetime` module, available in Python. + +Installation +============ +`dateutil` can be installed from PyPI using `pip` (note that the package name is +different from the importable name):: + + pip install python-dateutil + +Download +======== +dateutil is available on PyPI +https://pypi.org/project/python-dateutil/ + +The documentation is hosted at: +https://dateutil.readthedocs.io/en/stable/ + +Code +==== +The code and issue tracker are hosted on GitHub: +https://github.com/dateutil/dateutil/ + +Features +======== + +* Computing of relative deltas (next month, next year, + next Monday, last week of month, etc); +* Computing of relative deltas between two given + date and/or datetime objects; +* Computing of dates based on very flexible recurrence rules, + using a superset of the `iCalendar <https://www.ietf.org/rfc/rfc2445.txt>`_ + specification. Parsing of RFC strings is supported as well. +* Generic parsing of dates in almost any string format; +* Timezone (tzinfo) implementations for tzfile(5) format + files (/etc/localtime, /usr/share/zoneinfo, etc), TZ + environment string (in all known formats), iCalendar + format files, given ranges (with help from relative deltas), + local machine timezone, fixed offset timezone, UTC timezone, + and Windows registry-based time zones. +* Internal up-to-date world timezone information based on + Olson's database. +* Computing of Easter Sunday dates for any given year, + using Western, Orthodox or Julian algorithms; +* A comprehensive test suite. + +Quick example +============= +Here's a snapshot, just to give an idea about the power of the +package. For more examples, look at the documentation. + +Suppose you want to know how much time is left, in +years/months/days/etc, before the next easter happening on a +year with a Friday 13th in August, and you want to get today's +date out of the "date" unix system command. Here is the code: + +.. code-block:: python3 + + >>> from dateutil.relativedelta import * + >>> from dateutil.easter import * + >>> from dateutil.rrule import * + >>> from dateutil.parser import * + >>> from datetime import * + >>> now = parse("Sat Oct 11 17:13:46 UTC 2003") + >>> today = now.date() + >>> year = rrule(YEARLY,dtstart=now,bymonth=8,bymonthday=13,byweekday=FR)[0].year + >>> rdelta = relativedelta(easter(year), today) + >>> print("Today is: %s" % today) + Today is: 2003-10-11 + >>> print("Year with next Aug 13th on a Friday is: %s" % year) + Year with next Aug 13th on a Friday is: 2004 + >>> print("How far is the Easter of that year: %s" % rdelta) + How far is the Easter of that year: relativedelta(months=+6) + >>> print("And the Easter of that year is: %s" % (today+rdelta)) + And the Easter of that year is: 2004-04-11 + +Being exactly 6 months ahead was **really** a coincidence :) + +Contributing +============ + +We welcome many types of contributions - bug reports, pull requests (code, infrastructure or documentation fixes). For more information about how to contribute to the project, see the ``CONTRIBUTING.md`` file in the repository. + + +Author +====== +The dateutil module was written by Gustavo Niemeyer <gustavo@niemeyer.net> +in 2003. + +It is maintained by: + +* Gustavo Niemeyer <gustavo@niemeyer.net> 2003-2011 +* Tomi Pieviläinen <tomi.pievilainen@iki.fi> 2012-2014 +* Yaron de Leeuw <me@jarondl.net> 2014-2016 +* Paul Ganssle <paul@ganssle.io> 2015- + +Starting with version 2.4.1 and running until 2.8.2, all source and binary +distributions will be signed by a PGP key that has, at the very least, been +signed by the key which made the previous release. A table of release signing +keys can be found below: + +=========== ============================ +Releases Signing key fingerprint +=========== ============================ +2.4.1-2.8.2 `6B49 ACBA DCF6 BD1C A206 67AB CD54 FCE3 D964 BEFB`_ +=========== ============================ + +New releases *may* have signed tags, but binary and source distributions +uploaded to PyPI will no longer have GPG signatures attached. + +Contact +======= +Our mailing list is available at `dateutil@python.org <https://mail.python.org/mailman/listinfo/dateutil>`_. As it is hosted by the PSF, it is subject to the `PSF code of +conduct <https://www.python.org/psf/conduct/>`_. + +License +======= + +All contributions after December 1, 2017 released under dual license - either `Apache 2.0 License <https://www.apache.org/licenses/LICENSE-2.0>`_ or the `BSD 3-Clause License <https://opensource.org/licenses/BSD-3-Clause>`_. Contributions before December 1, 2017 - except those those explicitly relicensed - are released only under the BSD 3-Clause License. + + +.. _6B49 ACBA DCF6 BD1C A206 67AB CD54 FCE3 D964 BEFB: + https://pgp.mit.edu/pks/lookup?op=vindex&search=0xCD54FCE3D964BEFB diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/RECORD b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/RECORD new file mode 100644 index 0000000000000000000000000000000000000000..154737b0e9e23f6e79b2206a92c7db1e4f9a4182 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/RECORD @@ -0,0 +1,46 @@ +dateutil/__init__.py,sha256=Mqam67WO9IkTmUFyI66vS6IoSXTp9G388DadH2LCMLY,620 +dateutil/__pycache__/__init__.cpython-39.pyc,, +dateutil/__pycache__/_common.cpython-39.pyc,, +dateutil/__pycache__/_version.cpython-39.pyc,, +dateutil/__pycache__/easter.cpython-39.pyc,, +dateutil/__pycache__/relativedelta.cpython-39.pyc,, +dateutil/__pycache__/rrule.cpython-39.pyc,, +dateutil/__pycache__/tzwin.cpython-39.pyc,, +dateutil/__pycache__/utils.cpython-39.pyc,, +dateutil/_common.py,sha256=77w0yytkrxlYbSn--lDVPUMabUXRR9I3lBv_vQRUqUY,932 +dateutil/_version.py,sha256=2coNQN--46VtKE3SZe4j-RMMPcvpTDHgLtevBHSYzyY,526 +dateutil/easter.py,sha256=dyBi-lKvimH1u_k6p7Z0JJK72QhqVtVBsqByvpEPKvc,2678 +dateutil/parser/__init__.py,sha256=wWk6GFuxTpjoggCGtgkceJoti4pVjl4_fHQXpNOaSYg,1766 +dateutil/parser/__pycache__/__init__.cpython-39.pyc,, +dateutil/parser/__pycache__/_parser.cpython-39.pyc,, +dateutil/parser/__pycache__/isoparser.cpython-39.pyc,, +dateutil/parser/_parser.py,sha256=7klDdyicksQB_Xgl-3UAmBwzCYor1AIZqklIcT6dH_8,58796 +dateutil/parser/isoparser.py,sha256=8Fy999bnCd1frSdOYuOraWfJTtd5W7qQ51NwNuH_hXM,13233 +dateutil/relativedelta.py,sha256=IY_mglMjoZbYfrvloTY2ce02aiVjPIkiZfqgNTZRfuA,24903 +dateutil/rrule.py,sha256=KJzKlaCd1jEbu4A38ZltslaoAUh9nSbdbOFdjp70Kew,66557 +dateutil/tz/__init__.py,sha256=F-Mz13v6jYseklQf9Te9J6nzcLDmq47gORa61K35_FA,444 +dateutil/tz/__pycache__/__init__.cpython-39.pyc,, +dateutil/tz/__pycache__/_common.cpython-39.pyc,, +dateutil/tz/__pycache__/_factories.cpython-39.pyc,, +dateutil/tz/__pycache__/tz.cpython-39.pyc,, +dateutil/tz/__pycache__/win.cpython-39.pyc,, +dateutil/tz/_common.py,sha256=cgzDTANsOXvEc86cYF77EsliuSab8Puwpsl5-bX3_S4,12977 +dateutil/tz/_factories.py,sha256=unb6XQNXrPMveksTCU-Ag8jmVZs4SojoPUcAHpWnrvU,2569 +dateutil/tz/tz.py,sha256=EUnEdMfeThXiY6l4sh9yBabZ63_POzy01zSsh9thn1o,62855 +dateutil/tz/win.py,sha256=xJszWgSwE1xPx_HJj4ZkepyukC_hNy016WMcXhbRaB8,12935 +dateutil/tzwin.py,sha256=7Ar4vdQCnnM0mKR3MUjbIKsZrBVfHgdwsJZc_mGYRew,59 +dateutil/utils.py,sha256=dKCchEw8eObi0loGTx91unBxm_7UGlU3v_FjFMdqwYM,1965 +dateutil/zoneinfo/__init__.py,sha256=KYg0pthCMjcp5MXSEiBJn3nMjZeNZav7rlJw5-tz1S4,5889 +dateutil/zoneinfo/__pycache__/__init__.cpython-39.pyc,, +dateutil/zoneinfo/__pycache__/rebuild.cpython-39.pyc,, +dateutil/zoneinfo/dateutil-zoneinfo.tar.gz,sha256=0-pS57bpaN4NiE3xKIGTWW-pW4A9tPkqGCeac5gARHU,156400 +dateutil/zoneinfo/rebuild.py,sha256=MiqYzCIHvNbMH-LdRYLv-4T0EIA7hDKt5GLR0IRTLdI,2392 +python_dateutil-2.9.0.post0.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +python_dateutil-2.9.0.post0.dist-info/METADATA,sha256=pGHFOnG-ugFSX5O42DnhMjZPxS1jXrJlq0qbYVZfK1w,8396 +python_dateutil-2.9.0.post0.dist-info/RECORD,, +python_dateutil-2.9.0.post0.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +python_dateutil-2.9.0.post0.dist-info/WHEEL,sha256=JNWh1Fm1UdwIQV075glCn4MVuCRs0sotJIq-J6rbxCU,109 +python_dateutil-2.9.0.post0.dist-info/direct_url.json,sha256=cg4j1rrSOBUrxLV-PpEUzciB2cw3FvdoY7ONQpxQNXk,126 +python_dateutil-2.9.0.post0.dist-info/licenses/LICENSE,sha256=ugD1Gg2SgjtaHN4n2LW50jIeZ-2NqbwWPv-W1eF-V34,2889 +python_dateutil-2.9.0.post0.dist-info/top_level.txt,sha256=4tjdWkhRZvF7LA_BYe_L9gB2w_p2a-z5y6ArjaRkot8,9 +python_dateutil-2.9.0.post0.dist-info/zip-safe,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/REQUESTED b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/REQUESTED new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/WHEEL b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/WHEEL new file mode 100644 index 0000000000000000000000000000000000000000..5f133dbb5cfac001f2e84cda817210c03ce6484e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/WHEEL @@ -0,0 +1,6 @@ +Wheel-Version: 1.0 +Generator: setuptools (80.9.0) +Root-Is-Purelib: true +Tag: py2-none-any +Tag: py3-none-any + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/direct_url.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/direct_url.json new file mode 100644 index 0000000000000000000000000000000000000000..fac5480d05e7c6680a7b8f02a18fd94c8fce473d --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/direct_url.json @@ -0,0 +1 @@ +{"dir_info": {}, "url": "file:///home/conda/feedstock_root/build_artifacts/bld/rattler-build_python-dateutil_1751104122/work"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..1e65815cf0b3132689485874a93034ede7206bf4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/licenses/LICENSE @@ -0,0 +1,54 @@ +Copyright 2017- Paul Ganssle <paul@ganssle.io> +Copyright 2017- dateutil contributors (see AUTHORS file) + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +The above license applies to all contributions after 2017-12-01, as well as +all contributions that have been re-licensed (see AUTHORS file for the list of +contributors who have re-licensed their code). +-------------------------------------------------------------------------------- +dateutil - Extensions to the standard Python datetime module. + +Copyright (c) 2003-2011 - Gustavo Niemeyer <gustavo@niemeyer.net> +Copyright (c) 2012-2014 - Tomi Pieviläinen <tomi.pievilainen@iki.fi> +Copyright (c) 2014-2016 - Yaron de Leeuw <me@jarondl.net> +Copyright (c) 2015- - Paul Ganssle <paul@ganssle.io> +Copyright (c) 2015- - dateutil contributors (see AUTHORS file) + +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + * Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + * Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR +CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, +EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +The above BSD License Applies to all code, even that also covered by Apache 2.0. \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/top_level.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/top_level.txt new file mode 100644 index 0000000000000000000000000000000000000000..66501480ba5b63f98ee9a59c1f99e5e6917da6d9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/top_level.txt @@ -0,0 +1 @@ +dateutil diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/zip-safe b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/zip-safe new file mode 100644 index 0000000000000000000000000000000000000000..8b137891791fe96927ad78e64b0aad7bded08bdc --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python-dateutil-2.9.0.post0-pyhe01879c_2/site-packages/python_dateutil-2.9.0.post0.dist-info/zip-safe @@ -0,0 +1 @@ + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/about.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/about.json new file mode 100644 index 0000000000000000000000000000000000000000..05cf8854c60c509df58e8a7a8cfd8e97c903f26f --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/about.json @@ -0,0 +1,216 @@ +{ + "channels": [ + "https://conda.anaconda.org/conda-forge" + ], + "conda_build_version": "25.5.0", + "conda_version": "25.5.1", + "env_vars": { + "CIO_TEST": "<not set>" + }, + "extra": { + "copy_test_source_files": true, + "final": true, + "flow_run_id": "azure_20250717.3.1", + "recipe-maintainers": [ + "chrisburr", + "isuruf", + "xhochy" + ], + "remote_url": "https://github.com/conda-forge/python_abi-feedstock", + "sha": "21d54adcc66aa3497122c4fcd6fb0373aff2d0b5" + }, + "home": "https://github.com/conda-forge/python_abi-feedstock", + "identifiers": [], + "keywords": [], + "license": "BSD-3-Clause", + "license_family": "BSD", + "license_file": "LICENSE", + "root_pkgs": [ + "distro 1.9.0 pyhd8ed1ab_1", + "python 3.12.11 h9e4cc4f_0_cpython", + "libtiff 4.7.0 hf01ce69_5", + "rich 14.0.0 pyh29332c3_0", + "requests-toolbelt 1.0.0 pyhd8ed1ab_1", + "markupsafe 3.0.2 py312h178313f_1", + "nlohmann_json 3.11.3 he02047a_1", + "tomli 2.2.1 pyhd8ed1ab_1", + "liblzma 5.8.1 hb9d3cd8_2", + "hyperframe 6.1.0 pyhd8ed1ab_0", + "ncurses 6.5 h2d0b736_3", + "jsonpointer 3.0.0 py312h7900ff3_1", + "ruamel.yaml 0.18.14 py312h66e93f0_0", + "certifi 2025.6.15 pyhd8ed1ab_0", + "six 1.17.0 pyhd8ed1ab_0", + "python_abi 3.12 7_cp312", + "xz-gpl-tools 5.8.1 hbcc6ac9_2", + "frozendict 2.4.6 py312h66e93f0_0", + "_openmp_mutex 4.5 2_gnu", + "libxcb 1.17.0 h8a09558_0", + "python-fastjsonschema 2.21.1 pyhd8ed1ab_0", + "libwebp-base 1.5.0 h851e524_0", + "conda-index 0.6.1 pyhd8ed1ab_0", + "lcms2 2.17 h717163a_0", + "lerc 4.0.0 h0aef613_1", + "git 2.49.0 pl5321hc2ff736_1", + "menuinst 2.3.0 py312h7900ff3_0", + "platformdirs 4.3.8 pyhe01879c_0", + "tqdm 4.67.1 pyhd8ed1ab_1", + "markdown-it-py 3.0.0 pyhd8ed1ab_1", + "jsonschema-specifications 2025.4.1 pyh29332c3_0", + "python-dotenv 1.1.1 pyhe01879c_0", + "reproc-cpp 14.2.5.post0 h5888daf_0", + "libstdcxx-ng 15.1.0 h4852527_3", + "pluggy 1.6.0 pyhd8ed1ab_0", + "jinja2 3.1.6 pyhd8ed1ab_0", + "python-dateutil 2.9.0.post0 pyhe01879c_2", + "libpng 1.6.49 h943b412_0", + "setuptools 80.9.0 pyhff2d567_0", + "conda-package-streaming 0.11.0 pyhd8ed1ab_1", + "libssh2 1.11.1 hcf80075_0", + "typer 0.16.0 pyh167b9f4_0", + "conda-build 25.5.0 py312h7900ff3_0", + "psutil 7.0.0 py312h66e93f0_0", + "python-libarchive-c 5.3 pyhe01879c_0", + "keyutils 1.6.1 h166bdaf_0", + "zstd 1.5.7 hb8e6e7a_2", + "pybind11-abi 4 hd8ed1ab_3", + "zstandard 0.23.0 py312h66e93f0_2", + "jupyter_core 5.8.1 pyh31011fe_0", + "cffi 1.17.1 py312h06ac9bb_0", + "libexpat 2.7.0 h5888daf_0", + "wheel 0.45.1 pyhd8ed1ab_1", + "pydantic-core 2.33.2 py312h680f630_0", + "libev 4.33 hd590300_2", + "anaconda-client 1.13.0 pyh29332c3_1", + "evalidate 2.0.5 pyhe01879c_0", + "tini 0.19.0 h166bdaf_1", + "typer-slim 0.16.0 pyhe01879c_0", + "lzo 2.10 hd590300_1001", + "pcre2 10.45 hc749103_0", + "anaconda-cli-base 0.5.2 pyhd8ed1ab_0", + "xz 5.8.1 hbcc6ac9_2", + "annotated-types 0.7.0 pyhd8ed1ab_1", + "mbedtls 3.6.3.1 h5888daf_0", + "boltons 25.0.0 pyhd8ed1ab_0", + "libmambapy 2.3.0 py312hd15d01f_1", + "su-exec 0.2 h166bdaf_1003", + "liblzma-devel 5.8.1 hb9d3cd8_2", + "yaml-cpp 0.8.0 h59595ed_0", + "libfreetype6 2.13.3 h48d6fc4_1", + "c-ares 1.34.5 hb9d3cd8_0", + "libnghttp2 1.64.0 h161d5f1_0", + "typing-extensions 4.14.0 h32cad80_0", + "_libgcc_mutex 0.1 conda_forge", + "libstdcxx 15.1.0 h8f9b012_3", + "pkgutil-resolve-name 1.3.10 pyhd8ed1ab_2", + "truststore 0.10.1 pyh29332c3_0", + "urllib3 2.5.0 pyhd8ed1ab_0", + "idna 3.10 pyhd8ed1ab_1", + "libmamba 2.3.0 h44402ff_1", + "libgomp 15.1.0 h767d61c_3", + "readchar 4.2.1 pyhe01879c_0", + "pydantic 2.11.7 pyh3cfb1c2_0", + "perl 5.32.1 7_hd590300_perl5", + "libsqlite 3.50.2 h6cd9bfd_0", + "pytz 2025.2 pyhd8ed1ab_0", + "libuuid 2.38.1 h0b41bf4_0", + "soupsieve 2.7 pyhd8ed1ab_0", + "reproc 14.2.5.post0 hb9d3cd8_0", + "ld_impl_linux-64 2.43 h1423503_5", + "archspec 0.2.5 pyhd8ed1ab_0", + "beautifulsoup4 4.13.4 pyha770c72_0", + "xorg-libxdmcp 1.1.5 hb9d3cd8_0", + "ruamel.yaml.clib 0.2.8 py312h66e93f0_1", + "liblief 0.16.6 h5888daf_0", + "filelock 3.18.0 pyhd8ed1ab_0", + "h2 4.2.0 pyhd8ed1ab_0", + "colorama 0.4.6 pyhd8ed1ab_1", + "brotli-python 1.1.0 py312h2ec8cdc_3", + "attrs 25.3.0 pyh71513ae_0", + "lz4-c 1.10.0 h5888daf_1", + "openjpeg 2.5.3 h5fbd93e_0", + "tk 8.6.13 noxft_hd72426e_102", + "pygments 2.19.2 pyhd8ed1ab_0", + "chardet 5.2.0 pyhd8ed1ab_3", + "patch 2.7.6 h7f98852_1002", + "libcurl 8.14.1 h332b0f4_0", + "typing-inspection 0.4.1 pyhd8ed1ab_0", + "jsonpatch 1.33 pyhd8ed1ab_1", + "pkginfo 1.12.1.2 pyhd8ed1ab_0", + "charset-normalizer 3.4.2 pyhd8ed1ab_0", + "shellingham 1.5.4 pyhd8ed1ab_1", + "libnsl 2.0.1 hb9d3cd8_1", + "conda 25.5.1 py312h7900ff3_0", + "fmt 11.1.4 h07f6e7f_1", + "libxcrypt 4.4.36 hd590300_1", + "simdjson 3.13.0 h84d6215_0", + "libiconv 1.18 h4ce23a2_1", + "rpds-py 0.25.1 py312h680f630_0", + "mamba 2.3.0 h233bd08_1", + "pillow 11.2.1 py312h80c1187_0", + "libxml2 2.13.8 h4bc477f_0", + "libedit 3.1.20250104 pl5321h7949ede_0", + "typer-slim-standard 0.16.0 hf964461_0", + "icu 75.1 he02047a_0", + "referencing 0.36.2 pyh29332c3_0", + "yaml 0.2.5 h7f98852_2", + "pthread-stubs 0.4 hb9d3cd8_1002", + "msgpack-python 1.1.1 py312h68727a3_0", + "hpack 4.1.0 pyhd8ed1ab_0", + "pysocks 1.7.1 pyha55dd90_7", + "bzip2 1.0.8 h4bc722e_7", + "conda-package-handling 2.4.0 pyh7900ff3_2", + "cpp-expected 1.1.0 hff21bea_1", + "patchelf 0.17.2 h58526e2_0", + "libgcc-ng 15.1.0 h69a702a_3", + "xorg-libxau 1.0.12 hb9d3cd8_0", + "requests 2.32.4 pyhd8ed1ab_0", + "libzlib 1.3.1 hb9d3cd8_2", + "pip 25.1.1 pyh8b19718_0", + "packaging 25.0 pyh29332c3_1", + "libdeflate 1.24 h86f0d12_0", + "pyyaml 6.0.2 py312h178313f_2", + "pydantic-settings 2.10.1 pyh3cfb1c2_0", + "nbformat 5.10.4 pyhd8ed1ab_1", + "traitlets 5.14.3 pyhd8ed1ab_1", + "libsolv 0.7.33 h7955e40_0", + "zipp 3.23.0 pyhd8ed1ab_0", + "libffi 3.4.6 h2dba641_1", + "libjpeg-turbo 3.1.0 hb9d3cd8_0", + "conda-libmamba-solver 25.4.0 pyhd8ed1ab_0", + "typing_extensions 4.14.0 pyhe01879c_0", + "pycosat 0.6.6 py312h66e93f0_2", + "mdurl 0.1.2 pyhd8ed1ab_1", + "ripgrep 14.1.1 h8fae777_1", + "click 8.2.1 pyh707e725_0", + "readline 8.2 h8c095d6_2", + "jsonschema 4.24.0 pyhd8ed1ab_0", + "tzdata 2025b h78e105d_0", + "importlib_resources 6.5.2 pyhd8ed1ab_0", + "pycparser 2.22 pyh29332c3_1", + "xz-tools 5.8.1 hb9d3cd8_2", + "ca-certificates 2025.6.15 hbd8a1cb_0", + "krb5 1.21.3 h659f571_0", + "defusedxml 0.7.1 pyhd8ed1ab_0", + "openssl 3.5.0 h7b32b05_1", + "libfreetype 2.13.3 ha770c72_1", + "libgcc 15.1.0 h767d61c_3", + "py-lief 0.16.6 py312h2ec8cdc_0", + "libarchive 3.8.1 gpl_h98cc613_100", + "conda-env 2.6.0 1", + "jq 1.8.1 h73b1eb8_0", + "shyaml 0.6.2 pyhd3deb0d_0", + "oras-py 0.1.14 pyhd8ed1ab_0", + "deprecated 1.2.18 pyhd8ed1ab_0", + "rattler-build-conda-compat 1.4.3 pyhd8ed1ab_0", + "joblib 1.5.1 pyhd8ed1ab_0", + "conda-forge-ci-setup 4.21.2 py312hb3d6910_100", + "wrapt 1.17.2 py312h66e93f0_0", + "conda-oci-mirror 0.2.3 pyhd8ed1ab_0", + "oniguruma 6.9.10 hb9d3cd8_0", + "rattler-build 0.44.0 h2d22210_0", + "conda-forge-metadata 0.11.0 pyhd8ed1ab_1" + ], + "summary": "Metapackage to select python implementation", + "tags": [] +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/files b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/files new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/git b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/git new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/hash_input.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/hash_input.json new file mode 100644 index 0000000000000000000000000000000000000000..13d50ee321d847b554d3c6459e367e47afdcf976 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/hash_input.json @@ -0,0 +1,3 @@ +{ + "channel_targets": "conda-forge main" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/index.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/index.json new file mode 100644 index 0000000000000000000000000000000000000000..ca271c2569e7bf200a3fdb88bef86f2337fe7538 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/index.json @@ -0,0 +1,17 @@ +{ + "arch": null, + "build": "8_cp314", + "build_number": 8, + "constrains": [ + "python 3.14.* *_cp314" + ], + "depends": [], + "license": "BSD-3-Clause", + "license_family": "BSD", + "name": "python_abi", + "noarch": "generic", + "platform": null, + "subdir": "noarch", + "timestamp": 1752805904792, + "version": "3.14" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..bc9189c759dd6b737cebb9cb2bd3cfcea6b427e5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/licenses/LICENSE @@ -0,0 +1,27 @@ +Copyright (c) 2015-2018, conda-forge +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +* Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +* Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + +* Neither the name of staged-recipes nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/link.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/link.json new file mode 100644 index 0000000000000000000000000000000000000000..f072e87f8bb5634b93a0459b8b7c6b15eef0c47c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/link.json @@ -0,0 +1,6 @@ +{ + "noarch": { + "type": "generic" + }, + "package_metadata_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/paths.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/paths.json new file mode 100644 index 0000000000000000000000000000000000000000..03d81a3201aeefb71167ac453cd6d8c33bec10b9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/paths.json @@ -0,0 +1,4 @@ +{ + "paths": [], + "paths_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/recipe/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/recipe/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..bc9189c759dd6b737cebb9cb2bd3cfcea6b427e5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/recipe/LICENSE @@ -0,0 +1,27 @@ +Copyright (c) 2015-2018, conda-forge +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +* Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +* Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + +* Neither the name of staged-recipes nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/recipe/conda_build_config.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/recipe/conda_build_config.yaml new file mode 100644 index 0000000000000000000000000000000000000000..a746bc11f1262bb01363a10e2eaec603c74b7809 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/recipe/conda_build_config.yaml @@ -0,0 +1,44 @@ +CI: azure +c_compiler: '*' +cdt_name: conda +channel_sources: conda-forge +channel_targets: conda-forge main +cpu_optimization_target: nocona +cran_mirror: https://cran.r-project.org +cxx_compiler: '*' +docker_image: quay.io/condaforge/linux-anvil-x86_64:alma9 +extend_keys: +- ignore_version +- ignore_build_only_deps +- extend_keys +- pin_run_as_build +fortran_compiler: gfortran +ignore_build_only_deps: +- python +- numpy +is_python_min: 'false' +lua: '5' +numpy: '1.16' +perl: 5.26.2 +pin_run_as_build: + python: + max_pin: x.x + min_pin: x.x + r-base: + max_pin: x.x + min_pin: x.x +python: '3.8' +python_abi_tag: cp314 +python_impl: '*' +python_impl_version: '3.14' +python_implementation: cpython +python_min: '3.9' +python_version: '3.14' +r_base: '3.5' +target_platform: linux-64 +vc: '*' +zip_keys: +- - python_abi_tag + - python_version + - python_impl_version + - python_implementation diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/recipe/meta.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/recipe/meta.yaml new file mode 100644 index 0000000000000000000000000000000000000000..73b494f4ea0652e89ce7604b17abe5b0eeb731fa --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/recipe/meta.yaml @@ -0,0 +1,37 @@ +# This file created by conda-build 25.5.0 +# meta.yaml template originally from: +# /home/conda/recipe_root, last modified Fri Jul 18 02:30:49 2025 +# ------------------------------------------------ + +package: + name: python_abi + version: '3.14' +build: + number: '8' + string: 8_cp314 + noarch: generic + track_features: null +requirements: + run_constrained: + - python 3.14.* *_cp314 + build: [] + run: [] +test: + commands: + - echo "hello" +about: + home: https://github.com/conda-forge/python_abi-feedstock + summary: Metapackage to select python implementation + license: BSD-3-Clause + license_family: BSD + license_file: LICENSE +extra: + recipe-maintainers: + - chrisburr + - isuruf + - xhochy + final: true + copy_test_source_files: true + flow_run_id: azure_20250717.3.1 + remote_url: https://github.com/conda-forge/python_abi-feedstock + sha: 21d54adcc66aa3497122c4fcd6fb0373aff2d0b5 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/recipe/meta.yaml.template b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/recipe/meta.yaml.template new file mode 100644 index 0000000000000000000000000000000000000000..8e63474cfacc7d6ac5482c121de69bc19ed7f64a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/recipe/meta.yaml.template @@ -0,0 +1,50 @@ +{% set build_num = 8 %} +{% if python_impl_version is not defined %} +{% set python_impl_version = "3.8" %} +{% endif %} + +{% if python_version is not defined %} +{% set python_version = "3.8" %} +{% endif %} + +{% set python_minor = python_version.split(".")[1]|int %} + +package: + name: python_abi + version: {{ python_version }} + +build: + number: {{ build_num }} + string: {{ build_num }}_{{ python_abi_tag }} + noarch: generic + track_features: + - pypy # [python_implementation == "pypy"] + - native_graalpy # [python_implementation == "graalpy"] + - freethreading # [python_abi_tag == "cp313t"] + +requirements: + run_constrained: + {% if python_minor >= 13 %} + - python {{ python_version }}.* *_{{ python_abi_tag }} # [python_implementation == "cpython"] + {% else %} + - python {{ python_version }}.* *_cpython # [python_implementation == "cpython"] + {% endif %} + - python {{ python_version }}.* *_{{ python_impl_version.replace('.', '') }}_pypy # [python_implementation == "pypy"] + - python {{ python_version }}.* *_native{{ python_impl_version.replace('.', '') }}_graalpy # [python_implementation == "graalpy"] + +test: + commands: + - echo "hello" + +about: + home: https://github.com/conda-forge/python_abi-feedstock + summary: Metapackage to select python implementation + license: BSD-3-Clause + license_family: BSD + license_file: LICENSE + +extra: + recipe-maintainers: + - chrisburr + - isuruf + - xhochy diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/recipe/recipe-scripts-license.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/recipe/recipe-scripts-license.txt new file mode 100644 index 0000000000000000000000000000000000000000..2ec51d75f362bc4327a3cfe1c515c16bb3c57367 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/recipe/recipe-scripts-license.txt @@ -0,0 +1,27 @@ +BSD-3-Clause license +Copyright (c) 2015-2022, conda-forge contributors +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + 3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/repodata_record.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/repodata_record.json new file mode 100644 index 0000000000000000000000000000000000000000..d9c56675643952433289e11d8138b400f993531a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/repodata_record.json @@ -0,0 +1,24 @@ +{ + "arch": null, + "build": "8_cp314", + "build_number": 8, + "build_string": "8_cp314", + "channel": "conda-forge", + "constrains": [ + "python 3.14.* *_cp314" + ], + "depends": [], + "fn": "python_abi-3.14-8_cp314.conda", + "license": "BSD-3-Clause", + "license_family": "BSD", + "md5": "0539938c55b6b1a59b560e843ad864a4", + "name": "python_abi", + "noarch": "generic", + "platform": null, + "sha256": "ad6d2e9ac39751cc0529dd1566a26751a0bf2542adb0c232533d32e176e21db5", + "size": 6989, + "subdir": "noarch", + "timestamp": 1752805904, + "url": "https://conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314.conda", + "version": "3.14" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/test/run_test.bat b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/test/run_test.bat new file mode 100644 index 0000000000000000000000000000000000000000..a552aaf8340cc5fbe1e703ed1082d60d95b135bf --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/test/run_test.bat @@ -0,0 +1,7 @@ + + + + +echo "hello" +IF %ERRORLEVEL% NEQ 0 exit /B 1 +exit /B 0 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/test/run_test.sh b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/test/run_test.sh new file mode 100644 index 0000000000000000000000000000000000000000..d0d9c35801f4906fd217cb643903658d2d7867bd --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314/info/test/run_test.sh @@ -0,0 +1,8 @@ + + +set -ex + + + +echo "hello" +exit 0 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/about.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/about.json new file mode 100644 index 0000000000000000000000000000000000000000..05cf8854c60c509df58e8a7a8cfd8e97c903f26f --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/about.json @@ -0,0 +1,216 @@ +{ + "channels": [ + "https://conda.anaconda.org/conda-forge" + ], + "conda_build_version": "25.5.0", + "conda_version": "25.5.1", + "env_vars": { + "CIO_TEST": "<not set>" + }, + "extra": { + "copy_test_source_files": true, + "final": true, + "flow_run_id": "azure_20250717.3.1", + "recipe-maintainers": [ + "chrisburr", + "isuruf", + "xhochy" + ], + "remote_url": "https://github.com/conda-forge/python_abi-feedstock", + "sha": "21d54adcc66aa3497122c4fcd6fb0373aff2d0b5" + }, + "home": "https://github.com/conda-forge/python_abi-feedstock", + "identifiers": [], + "keywords": [], + "license": "BSD-3-Clause", + "license_family": "BSD", + "license_file": "LICENSE", + "root_pkgs": [ + "distro 1.9.0 pyhd8ed1ab_1", + "python 3.12.11 h9e4cc4f_0_cpython", + "libtiff 4.7.0 hf01ce69_5", + "rich 14.0.0 pyh29332c3_0", + "requests-toolbelt 1.0.0 pyhd8ed1ab_1", + "markupsafe 3.0.2 py312h178313f_1", + "nlohmann_json 3.11.3 he02047a_1", + "tomli 2.2.1 pyhd8ed1ab_1", + "liblzma 5.8.1 hb9d3cd8_2", + "hyperframe 6.1.0 pyhd8ed1ab_0", + "ncurses 6.5 h2d0b736_3", + "jsonpointer 3.0.0 py312h7900ff3_1", + "ruamel.yaml 0.18.14 py312h66e93f0_0", + "certifi 2025.6.15 pyhd8ed1ab_0", + "six 1.17.0 pyhd8ed1ab_0", + "python_abi 3.12 7_cp312", + "xz-gpl-tools 5.8.1 hbcc6ac9_2", + "frozendict 2.4.6 py312h66e93f0_0", + "_openmp_mutex 4.5 2_gnu", + "libxcb 1.17.0 h8a09558_0", + "python-fastjsonschema 2.21.1 pyhd8ed1ab_0", + "libwebp-base 1.5.0 h851e524_0", + "conda-index 0.6.1 pyhd8ed1ab_0", + "lcms2 2.17 h717163a_0", + "lerc 4.0.0 h0aef613_1", + "git 2.49.0 pl5321hc2ff736_1", + "menuinst 2.3.0 py312h7900ff3_0", + "platformdirs 4.3.8 pyhe01879c_0", + "tqdm 4.67.1 pyhd8ed1ab_1", + "markdown-it-py 3.0.0 pyhd8ed1ab_1", + "jsonschema-specifications 2025.4.1 pyh29332c3_0", + "python-dotenv 1.1.1 pyhe01879c_0", + "reproc-cpp 14.2.5.post0 h5888daf_0", + "libstdcxx-ng 15.1.0 h4852527_3", + "pluggy 1.6.0 pyhd8ed1ab_0", + "jinja2 3.1.6 pyhd8ed1ab_0", + "python-dateutil 2.9.0.post0 pyhe01879c_2", + "libpng 1.6.49 h943b412_0", + "setuptools 80.9.0 pyhff2d567_0", + "conda-package-streaming 0.11.0 pyhd8ed1ab_1", + "libssh2 1.11.1 hcf80075_0", + "typer 0.16.0 pyh167b9f4_0", + "conda-build 25.5.0 py312h7900ff3_0", + "psutil 7.0.0 py312h66e93f0_0", + "python-libarchive-c 5.3 pyhe01879c_0", + "keyutils 1.6.1 h166bdaf_0", + "zstd 1.5.7 hb8e6e7a_2", + "pybind11-abi 4 hd8ed1ab_3", + "zstandard 0.23.0 py312h66e93f0_2", + "jupyter_core 5.8.1 pyh31011fe_0", + "cffi 1.17.1 py312h06ac9bb_0", + "libexpat 2.7.0 h5888daf_0", + "wheel 0.45.1 pyhd8ed1ab_1", + "pydantic-core 2.33.2 py312h680f630_0", + "libev 4.33 hd590300_2", + "anaconda-client 1.13.0 pyh29332c3_1", + "evalidate 2.0.5 pyhe01879c_0", + "tini 0.19.0 h166bdaf_1", + "typer-slim 0.16.0 pyhe01879c_0", + "lzo 2.10 hd590300_1001", + "pcre2 10.45 hc749103_0", + "anaconda-cli-base 0.5.2 pyhd8ed1ab_0", + "xz 5.8.1 hbcc6ac9_2", + "annotated-types 0.7.0 pyhd8ed1ab_1", + "mbedtls 3.6.3.1 h5888daf_0", + "boltons 25.0.0 pyhd8ed1ab_0", + "libmambapy 2.3.0 py312hd15d01f_1", + "su-exec 0.2 h166bdaf_1003", + "liblzma-devel 5.8.1 hb9d3cd8_2", + "yaml-cpp 0.8.0 h59595ed_0", + "libfreetype6 2.13.3 h48d6fc4_1", + "c-ares 1.34.5 hb9d3cd8_0", + "libnghttp2 1.64.0 h161d5f1_0", + "typing-extensions 4.14.0 h32cad80_0", + "_libgcc_mutex 0.1 conda_forge", + "libstdcxx 15.1.0 h8f9b012_3", + "pkgutil-resolve-name 1.3.10 pyhd8ed1ab_2", + "truststore 0.10.1 pyh29332c3_0", + "urllib3 2.5.0 pyhd8ed1ab_0", + "idna 3.10 pyhd8ed1ab_1", + "libmamba 2.3.0 h44402ff_1", + "libgomp 15.1.0 h767d61c_3", + "readchar 4.2.1 pyhe01879c_0", + "pydantic 2.11.7 pyh3cfb1c2_0", + "perl 5.32.1 7_hd590300_perl5", + "libsqlite 3.50.2 h6cd9bfd_0", + "pytz 2025.2 pyhd8ed1ab_0", + "libuuid 2.38.1 h0b41bf4_0", + "soupsieve 2.7 pyhd8ed1ab_0", + "reproc 14.2.5.post0 hb9d3cd8_0", + "ld_impl_linux-64 2.43 h1423503_5", + "archspec 0.2.5 pyhd8ed1ab_0", + "beautifulsoup4 4.13.4 pyha770c72_0", + "xorg-libxdmcp 1.1.5 hb9d3cd8_0", + "ruamel.yaml.clib 0.2.8 py312h66e93f0_1", + "liblief 0.16.6 h5888daf_0", + "filelock 3.18.0 pyhd8ed1ab_0", + "h2 4.2.0 pyhd8ed1ab_0", + "colorama 0.4.6 pyhd8ed1ab_1", + "brotli-python 1.1.0 py312h2ec8cdc_3", + "attrs 25.3.0 pyh71513ae_0", + "lz4-c 1.10.0 h5888daf_1", + "openjpeg 2.5.3 h5fbd93e_0", + "tk 8.6.13 noxft_hd72426e_102", + "pygments 2.19.2 pyhd8ed1ab_0", + "chardet 5.2.0 pyhd8ed1ab_3", + "patch 2.7.6 h7f98852_1002", + "libcurl 8.14.1 h332b0f4_0", + "typing-inspection 0.4.1 pyhd8ed1ab_0", + "jsonpatch 1.33 pyhd8ed1ab_1", + "pkginfo 1.12.1.2 pyhd8ed1ab_0", + "charset-normalizer 3.4.2 pyhd8ed1ab_0", + "shellingham 1.5.4 pyhd8ed1ab_1", + "libnsl 2.0.1 hb9d3cd8_1", + "conda 25.5.1 py312h7900ff3_0", + "fmt 11.1.4 h07f6e7f_1", + "libxcrypt 4.4.36 hd590300_1", + "simdjson 3.13.0 h84d6215_0", + "libiconv 1.18 h4ce23a2_1", + "rpds-py 0.25.1 py312h680f630_0", + "mamba 2.3.0 h233bd08_1", + "pillow 11.2.1 py312h80c1187_0", + "libxml2 2.13.8 h4bc477f_0", + "libedit 3.1.20250104 pl5321h7949ede_0", + "typer-slim-standard 0.16.0 hf964461_0", + "icu 75.1 he02047a_0", + "referencing 0.36.2 pyh29332c3_0", + "yaml 0.2.5 h7f98852_2", + "pthread-stubs 0.4 hb9d3cd8_1002", + "msgpack-python 1.1.1 py312h68727a3_0", + "hpack 4.1.0 pyhd8ed1ab_0", + "pysocks 1.7.1 pyha55dd90_7", + "bzip2 1.0.8 h4bc722e_7", + "conda-package-handling 2.4.0 pyh7900ff3_2", + "cpp-expected 1.1.0 hff21bea_1", + "patchelf 0.17.2 h58526e2_0", + "libgcc-ng 15.1.0 h69a702a_3", + "xorg-libxau 1.0.12 hb9d3cd8_0", + "requests 2.32.4 pyhd8ed1ab_0", + "libzlib 1.3.1 hb9d3cd8_2", + "pip 25.1.1 pyh8b19718_0", + "packaging 25.0 pyh29332c3_1", + "libdeflate 1.24 h86f0d12_0", + "pyyaml 6.0.2 py312h178313f_2", + "pydantic-settings 2.10.1 pyh3cfb1c2_0", + "nbformat 5.10.4 pyhd8ed1ab_1", + "traitlets 5.14.3 pyhd8ed1ab_1", + "libsolv 0.7.33 h7955e40_0", + "zipp 3.23.0 pyhd8ed1ab_0", + "libffi 3.4.6 h2dba641_1", + "libjpeg-turbo 3.1.0 hb9d3cd8_0", + "conda-libmamba-solver 25.4.0 pyhd8ed1ab_0", + "typing_extensions 4.14.0 pyhe01879c_0", + "pycosat 0.6.6 py312h66e93f0_2", + "mdurl 0.1.2 pyhd8ed1ab_1", + "ripgrep 14.1.1 h8fae777_1", + "click 8.2.1 pyh707e725_0", + "readline 8.2 h8c095d6_2", + "jsonschema 4.24.0 pyhd8ed1ab_0", + "tzdata 2025b h78e105d_0", + "importlib_resources 6.5.2 pyhd8ed1ab_0", + "pycparser 2.22 pyh29332c3_1", + "xz-tools 5.8.1 hb9d3cd8_2", + "ca-certificates 2025.6.15 hbd8a1cb_0", + "krb5 1.21.3 h659f571_0", + "defusedxml 0.7.1 pyhd8ed1ab_0", + "openssl 3.5.0 h7b32b05_1", + "libfreetype 2.13.3 ha770c72_1", + "libgcc 15.1.0 h767d61c_3", + "py-lief 0.16.6 py312h2ec8cdc_0", + "libarchive 3.8.1 gpl_h98cc613_100", + "conda-env 2.6.0 1", + "jq 1.8.1 h73b1eb8_0", + "shyaml 0.6.2 pyhd3deb0d_0", + "oras-py 0.1.14 pyhd8ed1ab_0", + "deprecated 1.2.18 pyhd8ed1ab_0", + "rattler-build-conda-compat 1.4.3 pyhd8ed1ab_0", + "joblib 1.5.1 pyhd8ed1ab_0", + "conda-forge-ci-setup 4.21.2 py312hb3d6910_100", + "wrapt 1.17.2 py312h66e93f0_0", + "conda-oci-mirror 0.2.3 pyhd8ed1ab_0", + "oniguruma 6.9.10 hb9d3cd8_0", + "rattler-build 0.44.0 h2d22210_0", + "conda-forge-metadata 0.11.0 pyhd8ed1ab_1" + ], + "summary": "Metapackage to select python implementation", + "tags": [] +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/files b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/files new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/git b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/git new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/hash_input.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/hash_input.json new file mode 100644 index 0000000000000000000000000000000000000000..13d50ee321d847b554d3c6459e367e47afdcf976 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/hash_input.json @@ -0,0 +1,3 @@ +{ + "channel_targets": "conda-forge main" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/index.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/index.json new file mode 100644 index 0000000000000000000000000000000000000000..e190502bffddcf2b7639e524039f585a0c357738 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/index.json @@ -0,0 +1,17 @@ +{ + "arch": null, + "build": "8_cp314t", + "build_number": 8, + "constrains": [ + "python 3.14.* *_cp314t" + ], + "depends": [], + "license": "BSD-3-Clause", + "license_family": "BSD", + "name": "python_abi", + "noarch": "generic", + "platform": null, + "subdir": "noarch", + "timestamp": 1752805919426, + "version": "3.14" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..bc9189c759dd6b737cebb9cb2bd3cfcea6b427e5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/licenses/LICENSE @@ -0,0 +1,27 @@ +Copyright (c) 2015-2018, conda-forge +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +* Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +* Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + +* Neither the name of staged-recipes nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/link.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/link.json new file mode 100644 index 0000000000000000000000000000000000000000..f072e87f8bb5634b93a0459b8b7c6b15eef0c47c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/link.json @@ -0,0 +1,6 @@ +{ + "noarch": { + "type": "generic" + }, + "package_metadata_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/paths.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/paths.json new file mode 100644 index 0000000000000000000000000000000000000000..03d81a3201aeefb71167ac453cd6d8c33bec10b9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/paths.json @@ -0,0 +1,4 @@ +{ + "paths": [], + "paths_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/recipe/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/recipe/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..bc9189c759dd6b737cebb9cb2bd3cfcea6b427e5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/recipe/LICENSE @@ -0,0 +1,27 @@ +Copyright (c) 2015-2018, conda-forge +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +* Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +* Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + +* Neither the name of staged-recipes nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/recipe/conda_build_config.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/recipe/conda_build_config.yaml new file mode 100644 index 0000000000000000000000000000000000000000..dd62b0a7c3f729b315b2fd7f872856427d62481f --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/recipe/conda_build_config.yaml @@ -0,0 +1,44 @@ +CI: azure +c_compiler: '*' +cdt_name: conda +channel_sources: conda-forge +channel_targets: conda-forge main +cpu_optimization_target: nocona +cran_mirror: https://cran.r-project.org +cxx_compiler: '*' +docker_image: quay.io/condaforge/linux-anvil-x86_64:alma9 +extend_keys: +- ignore_version +- ignore_build_only_deps +- extend_keys +- pin_run_as_build +fortran_compiler: gfortran +ignore_build_only_deps: +- python +- numpy +is_python_min: 'false' +lua: '5' +numpy: '1.16' +perl: 5.26.2 +pin_run_as_build: + python: + max_pin: x.x + min_pin: x.x + r-base: + max_pin: x.x + min_pin: x.x +python: '3.8' +python_abi_tag: cp314t +python_impl: '*' +python_impl_version: '3.14' +python_implementation: cpython +python_min: '3.9' +python_version: '3.14' +r_base: '3.5' +target_platform: linux-64 +vc: '*' +zip_keys: +- - python_abi_tag + - python_version + - python_impl_version + - python_implementation diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/recipe/meta.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/recipe/meta.yaml new file mode 100644 index 0000000000000000000000000000000000000000..476051a0fb9d1d80ae81422bd807c7e3faafbb65 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/recipe/meta.yaml @@ -0,0 +1,37 @@ +# This file created by conda-build 25.5.0 +# meta.yaml template originally from: +# /home/conda/recipe_root, last modified Fri Jul 18 02:30:50 2025 +# ------------------------------------------------ + +package: + name: python_abi + version: '3.14' +build: + number: '8' + string: 8_cp314t + noarch: generic + track_features: null +requirements: + run_constrained: + - python 3.14.* *_cp314t + build: [] + run: [] +test: + commands: + - echo "hello" +about: + home: https://github.com/conda-forge/python_abi-feedstock + summary: Metapackage to select python implementation + license: BSD-3-Clause + license_family: BSD + license_file: LICENSE +extra: + recipe-maintainers: + - chrisburr + - isuruf + - xhochy + final: true + copy_test_source_files: true + flow_run_id: azure_20250717.3.1 + remote_url: https://github.com/conda-forge/python_abi-feedstock + sha: 21d54adcc66aa3497122c4fcd6fb0373aff2d0b5 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/recipe/meta.yaml.template b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/recipe/meta.yaml.template new file mode 100644 index 0000000000000000000000000000000000000000..8e63474cfacc7d6ac5482c121de69bc19ed7f64a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/recipe/meta.yaml.template @@ -0,0 +1,50 @@ +{% set build_num = 8 %} +{% if python_impl_version is not defined %} +{% set python_impl_version = "3.8" %} +{% endif %} + +{% if python_version is not defined %} +{% set python_version = "3.8" %} +{% endif %} + +{% set python_minor = python_version.split(".")[1]|int %} + +package: + name: python_abi + version: {{ python_version }} + +build: + number: {{ build_num }} + string: {{ build_num }}_{{ python_abi_tag }} + noarch: generic + track_features: + - pypy # [python_implementation == "pypy"] + - native_graalpy # [python_implementation == "graalpy"] + - freethreading # [python_abi_tag == "cp313t"] + +requirements: + run_constrained: + {% if python_minor >= 13 %} + - python {{ python_version }}.* *_{{ python_abi_tag }} # [python_implementation == "cpython"] + {% else %} + - python {{ python_version }}.* *_cpython # [python_implementation == "cpython"] + {% endif %} + - python {{ python_version }}.* *_{{ python_impl_version.replace('.', '') }}_pypy # [python_implementation == "pypy"] + - python {{ python_version }}.* *_native{{ python_impl_version.replace('.', '') }}_graalpy # [python_implementation == "graalpy"] + +test: + commands: + - echo "hello" + +about: + home: https://github.com/conda-forge/python_abi-feedstock + summary: Metapackage to select python implementation + license: BSD-3-Clause + license_family: BSD + license_file: LICENSE + +extra: + recipe-maintainers: + - chrisburr + - isuruf + - xhochy diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/recipe/recipe-scripts-license.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/recipe/recipe-scripts-license.txt new file mode 100644 index 0000000000000000000000000000000000000000..2ec51d75f362bc4327a3cfe1c515c16bb3c57367 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/recipe/recipe-scripts-license.txt @@ -0,0 +1,27 @@ +BSD-3-Clause license +Copyright (c) 2015-2022, conda-forge contributors +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + 3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/repodata_record.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/repodata_record.json new file mode 100644 index 0000000000000000000000000000000000000000..c2271ba9343ab5ad4fc9c25f6b1b18017886b84e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/repodata_record.json @@ -0,0 +1,24 @@ +{ + "arch": null, + "build": "8_cp314t", + "build_number": 8, + "build_string": "8_cp314t", + "channel": "conda-forge", + "constrains": [ + "python 3.14.* *_cp314t" + ], + "depends": [], + "fn": "python_abi-3.14-8_cp314t.conda", + "license": "BSD-3-Clause", + "license_family": "BSD", + "md5": "3251796e09870c978e0f69fa05e38fb6", + "name": "python_abi", + "noarch": "generic", + "platform": null, + "sha256": "d9ed2538fba61265a330ee1b1afe99a4bb23ace706172b9464546c7e01259d63", + "size": 7020, + "subdir": "noarch", + "timestamp": 1752805919, + "url": "https://conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t.conda", + "version": "3.14" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/test/run_test.bat b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/test/run_test.bat new file mode 100644 index 0000000000000000000000000000000000000000..a552aaf8340cc5fbe1e703ed1082d60d95b135bf --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/test/run_test.bat @@ -0,0 +1,7 @@ + + + + +echo "hello" +IF %ERRORLEVEL% NEQ 0 exit /B 1 +exit /B 0 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/test/run_test.sh b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/test/run_test.sh new file mode 100644 index 0000000000000000000000000000000000000000..d0d9c35801f4906fd217cb643903658d2d7867bd --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/python_abi-3.14-8_cp314t/info/test/run_test.sh @@ -0,0 +1,8 @@ + + +set -ex + + + +echo "hello" +exit 0 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/about.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/about.json new file mode 100644 index 0000000000000000000000000000000000000000..f85f7560cc6f43614dde0a3890f346ba908c9b5a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/about.json @@ -0,0 +1,13 @@ +{ + "channels": [ + "https://conda.anaconda.org/conda-forge/" + ], + "extra": { + "flow_run_id": "azure_20251208.1.1", + "remote_url": "https://github.com/conda-forge/pytokens-feedstock", + "sha": "e15dc3d90d899c9406a96dbdf21b9675fb4006ec" + }, + "home": "https://github.com/tusharsadhwani/pytokens", + "license": "MIT", + "summary": "A Fast, spec compliant Python 3.14+ tokenizer that runs on older Pythons." +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/hash_input.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/hash_input.json new file mode 100644 index 0000000000000000000000000000000000000000..8cab3e9c53cdf587ba644746533a696e1ec88e46 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/hash_input.json @@ -0,0 +1 @@ +{"channel_sources": "conda-forge", "channel_targets": "conda-forge main", "python_min": "3.10", "target_platform": "noarch"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/index.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/index.json new file mode 100644 index 0000000000000000000000000000000000000000..f2c4b3f25960757b1bdd2ccebcf815aba8f808ff --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/index.json @@ -0,0 +1,14 @@ +{ + "build": "pyhcf101f3_0", + "build_number": 0, + "depends": [ + "python >=3.10", + "python" + ], + "license": "MIT", + "name": "pytokens", + "noarch": "python", + "subdir": "noarch", + "timestamp": 1765201048624, + "version": "0.3.0" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..def1a5ad7e10107456a048eb37339e8fb527d7f7 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/licenses/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2024 Tushar Sadhwani + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/link.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/link.json new file mode 100644 index 0000000000000000000000000000000000000000..ec6589c68a1bf1aedb3f856ab584e80f5302f2cb --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/link.json @@ -0,0 +1,6 @@ +{ + "noarch": { + "type": "python" + }, + "package_metadata_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/paths.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/paths.json new file mode 100644 index 0000000000000000000000000000000000000000..13dbd0e904a2a7d2f2c9b90eb92195830a68eca0 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/paths.json @@ -0,0 +1,77 @@ +{ + "paths": [ + { + "_path": "site-packages/pytokens/__init__.py", + "path_type": "hardlink", + "sha256": "e364b27e15bc7596a7ceb72b270063d2da14746d30cb4fb952711ab40ae8d5c4", + "size_in_bytes": 39498 + }, + { + "_path": "site-packages/pytokens/__main__.py", + "path_type": "hardlink", + "sha256": "cc9da6f797f3d7e5bcc2e4c55a6afcce578e63d6543ba278fa5c4c936ba77840", + "size_in_bytes": 184 + }, + { + "_path": "site-packages/pytokens/cli.py", + "path_type": "hardlink", + "sha256": "d96e76be39808fe553b9f8f9b1a2787f850e874e00633e4cf7c9e8a8866c5c3c", + "size_in_bytes": 6174 + }, + { + "_path": "site-packages/pytokens/py.typed", + "path_type": "hardlink", + "sha256": "0ed0ac203aba28ebf634e11d4234db78c58929187a6442f613ee8c7f544b78c0", + "size_in_bytes": 59 + }, + { + "_path": "site-packages/pytokens-0.3.0.dist-info/INSTALLER", + "path_type": "hardlink", + "sha256": "bc33022edcb7639ff53355b4e91dade50a0bbf0299efeb6171d1ec0ba5029cfc", + "size_in_bytes": 6 + }, + { + "_path": "site-packages/pytokens-0.3.0.dist-info/METADATA", + "path_type": "hardlink", + "sha256": "4b434ebf9e1fd316c5485c8277b527963d05340069555346dfd1be243db42c1f", + "size_in_bytes": 1983 + }, + { + "_path": "site-packages/pytokens-0.3.0.dist-info/RECORD", + "path_type": "hardlink", + "sha256": "255cf8eda9aa2c14397f56fde376fc627037d132774aeb76d2bf4dd6f73e90d6", + "size_in_bytes": 1123 + }, + { + "_path": "site-packages/pytokens-0.3.0.dist-info/REQUESTED", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pytokens-0.3.0.dist-info/WHEEL", + "path_type": "hardlink", + "sha256": "ff309ddcdd65ebd02bc724dbf2bcc4a0ff53a5b61792a44548d383e4ebb19d3b", + "size_in_bytes": 91 + }, + { + "_path": "site-packages/pytokens-0.3.0.dist-info/direct_url.json", + "path_type": "hardlink", + "sha256": "426427e0e62540471125f68956376ee4db547798abca6584fad451f7f78c91da", + "size_in_bytes": 119 + }, + { + "_path": "site-packages/pytokens-0.3.0.dist-info/licenses/LICENSE", + "path_type": "hardlink", + "sha256": "94bf7ae4ea6833b0853a7cc1f1f28dd8579b34a31c9c162aeb8825dec23ed5dc", + "size_in_bytes": 1072 + }, + { + "_path": "site-packages/pytokens-0.3.0.dist-info/top_level.txt", + "path_type": "hardlink", + "sha256": "0fbfb7ed75b911fcf7be382e3084cb1630c324f28484e189364ef34b82147150", + "size_in_bytes": 9 + } + ], + "paths_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/recipe/recipe-scripts-license.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/recipe/recipe-scripts-license.txt new file mode 100644 index 0000000000000000000000000000000000000000..2ec51d75f362bc4327a3cfe1c515c16bb3c57367 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/recipe/recipe-scripts-license.txt @@ -0,0 +1,27 @@ +BSD-3-Clause license +Copyright (c) 2015-2022, conda-forge contributors +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + 3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/recipe/recipe.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/recipe/recipe.yaml new file mode 100644 index 0000000000000000000000000000000000000000..002fb796c3068c1eaf0c03a38ee0e52d3ee05dbd --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/recipe/recipe.yaml @@ -0,0 +1,43 @@ +schema_version: 1 + +context: + name: pytokens + version: 0.3.0 + +package: + name: ${{ name|lower }} + version: ${{ version }} + +source: + url: https://pypi.org/packages/source/${{ name[0] }}/${{ name }}/pytokens-${{ version }}.tar.gz + sha256: 2f932b14ed08de5fcf0b391ace2642f858f1394c0857202959000b68ed7a458a + +build: + number: 0 + noarch: python + script: ${{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation + +requirements: + host: + - python ${{ python_min }}.* + - pip + - setuptools + run: + - python >=${{ python_min }} + +tests: + - python: + python_version: ${{ python_min }}.* + imports: + - pytokens + pip_check: true + +about: + summary: A Fast, spec compliant Python 3.14+ tokenizer that runs on older Pythons. + license: MIT + license_file: LICENSE + homepage: https://github.com/tusharsadhwani/pytokens + +extra: + recipe-maintainers: + - xhochy diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/recipe/rendered_recipe.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/recipe/rendered_recipe.yaml new file mode 100644 index 0000000000000000000000000000000000000000..c09566d980f9328288c7dd6faba481001980141f --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/recipe/rendered_recipe.yaml @@ -0,0 +1,630 @@ +recipe: + schema_version: 1 + context: + name: pytokens + version: 0.3.0 + package: + name: pytokens + version: 0.3.0 + source: + - url: https://pypi.org/packages/source/p/pytokens/pytokens-0.3.0.tar.gz + sha256: 2f932b14ed08de5fcf0b391ace2642f858f1394c0857202959000b68ed7a458a + build: + number: 0 + string: pyhcf101f3_0 + script: ${{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation + noarch: python + requirements: + host: + - python 3.10.* + - pip + - setuptools + run: + - python >=3.10 + tests: + - python: + imports: + - pytokens + python_version: 3.10.* + about: + homepage: https://github.com/tusharsadhwani/pytokens + license: MIT + license_file: + - LICENSE + summary: A Fast, spec compliant Python 3.14+ tokenizer that runs on older Pythons. + extra: + recipe-maintainers: + - xhochy +build_configuration: + target_platform: noarch + host_platform: + platform: linux-64 + virtual_packages: + - __unix=0=0 + - __linux=6.11.0=0 + - __glibc=2.34=0 + - __archspec=1=x86_64_v4 + build_platform: + platform: linux-64 + virtual_packages: + - __unix=0=0 + - __linux=6.11.0=0 + - __glibc=2.34=0 + - __archspec=1=x86_64_v4 + variant: + channel_sources: conda-forge + channel_targets: conda-forge main + python_min: '3.10' + target_platform: noarch + hash: + hash: cf101f3 + prefix: py + directories: + host_prefix: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_pytokens_1765201048/host_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_place + build_prefix: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_pytokens_1765201048/build_env + work_dir: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_pytokens_1765201048/work + build_dir: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_pytokens_1765201048 + channels: + - https://conda.anaconda.org/conda-forge + channel_priority: strict + solve_strategy: highest + timestamp: 2025-12-08T13:37:28.624975972Z + subpackages: + pytokens: + name: pytokens + version: 0.3.0 + build_string: pyhcf101f3_0 + packaging_settings: + archive_type: conda + compression_level: 15 +finalized_dependencies: + build: null + host: + specs: + - source: python 3.10.* + - source: pip + - source: setuptools + resolved: + - build: h3c07f61_2_cpython + build_number: 2 + constrains: + - python_abi 3.10.* *_cp310 + depends: + - __glibc >=2.17,<3.0.a0 + - bzip2 >=1.0.8,<2.0a0 + - ld_impl_linux-64 >=2.36.1 + - libexpat >=2.7.1,<3.0a0 + - libffi >=3.4,<4.0a0 + - libgcc >=14 + - liblzma >=5.8.1,<6.0a0 + - libnsl >=2.0.1,<2.1.0a0 + - libsqlite >=3.50.4,<4.0a0 + - libuuid >=2.41.2,<3.0a0 + - libxcrypt >=4.4.36 + - libzlib >=1.3.1,<2.0a0 + - ncurses >=6.5,<7.0a0 + - openssl >=3.5.4,<4.0a0 + - readline >=8.2,<9.0a0 + - tk >=8.6.13,<8.7.0a0 + - tzdata + license: Python-2.0 + md5: 27ac896a8b4970f8977503a9e70dc745 + name: python + run_exports: + weak: + - python_abi 3.10.* *_cp310 + noarch: + - python + sha256: 6e3b6b69b3cacfc7610155d58407a003820eaacd50fbe039abff52b5e70b1e9b + size: 25311690 + subdir: linux-64 + timestamp: 1761173015969 + version: 3.10.19 + fn: python-3.10.19-h3c07f61_2_cpython.conda + url: https://conda.anaconda.org/conda-forge/linux-64/python-3.10.19-h3c07f61_2_cpython.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyh8b19718_0 + build_number: 0 + depends: + - python >=3.10,<3.13.0a0 + - setuptools + - wheel + license: MIT + license_family: MIT + md5: c55515ca43c6444d2572e0f0d93cb6b9 + name: pip + noarch: python + run_exports: {} + sha256: b67692da1c0084516ac1c9ada4d55eaf3c5891b54980f30f3f444541c2706f1e + size: 1177534 + subdir: noarch + timestamp: 1762776258783 + version: '25.3' + fn: pip-25.3-pyh8b19718_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/pip-25.3-pyh8b19718_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhff2d567_0 + build_number: 0 + depends: + - python >=3.9 + license: MIT + license_family: MIT + md5: 4de79c071274a53dcaf2a8c749d1499e + name: setuptools + noarch: python + run_exports: {} + sha256: 972560fcf9657058e3e1f97186cc94389144b46dbdf58c807ce62e83f977e863 + size: 748788 + subdir: noarch + timestamp: 1748804951958 + version: 80.9.0 + fn: setuptools-80.9.0-pyhff2d567_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/setuptools-80.9.0-pyhff2d567_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hda65f42_8 + build_number: 8 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: bzip2-1.0.6 + license_family: BSD + md5: 51a19bba1b8ebfb60df25cde030b7ebc + name: bzip2 + run_exports: + weak: + - bzip2 >=1.0.8,<2.0a0 + sha256: c30daba32ddebbb7ded490f0e371eae90f51e72db620554089103b4a6934b0d5 + size: 260341 + subdir: linux-64 + timestamp: 1757437258798 + version: 1.0.8 + fn: bzip2-1.0.8-hda65f42_8.conda + url: https://conda.anaconda.org/conda-forge/linux-64/bzip2-1.0.8-hda65f42_8.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: default_hbd61a6d_104 + build_number: 104 + constrains: + - binutils_impl_linux-64 2.45 + depends: + - __glibc >=2.17,<3.0.a0 + - zstd >=1.5.7,<1.6.0a0 + license: GPL-3.0-only + license_family: GPL + md5: a6abd2796fc332536735f68ba23f7901 + name: ld_impl_linux-64 + run_exports: {} + sha256: 9e191baf2426a19507f1d0a17be0fdb7aa155cdf0f61d5a09c808e0a69464312 + size: 725545 + subdir: linux-64 + timestamp: 1764007826689 + version: '2.45' + fn: ld_impl_linux-64-2.45-default_hbd61a6d_104.conda + url: https://conda.anaconda.org/conda-forge/linux-64/ld_impl_linux-64-2.45-default_hbd61a6d_104.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hecca717_0 + build_number: 0 + constrains: + - expat 2.7.3.* + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: MIT + license_family: MIT + md5: 8b09ae86839581147ef2e5c5e229d164 + name: libexpat + run_exports: {} + sha256: 1e1b08f6211629cbc2efe7a5bca5953f8f6b3cae0eeb04ca4dacee1bd4e2db2f + size: 76643 + subdir: linux-64 + timestamp: 1763549731408 + version: 2.7.3 + fn: libexpat-2.7.3-hecca717_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libexpat-2.7.3-hecca717_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h9ec8514_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: MIT + license_family: MIT + md5: 35f29eec58405aaf55e01cb470d8c26a + name: libffi + run_exports: + weak: + - libffi >=3.5.2,<3.6.0a0 + sha256: 25cbdfa65580cfab1b8d15ee90b4c9f1e0d72128f1661449c9a999d341377d54 + size: 57821 + subdir: linux-64 + timestamp: 1760295480630 + version: 3.5.2 + fn: libffi-3.5.2-h9ec8514_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libffi-3.5.2-h9ec8514_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: he0feb66_15 + build_number: 15 + constrains: + - libgomp 15.2.0 he0feb66_15 + - libgcc-ng ==15.2.0=*_15 + depends: + - __glibc >=2.17,<3.0.a0 + - _openmp_mutex >=4.5 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + md5: a5d86b0496174a412d531eac03af9174 + name: libgcc + run_exports: {} + sha256: 37f2edde2f8281672987c63f13c85a57d04d889dc929ce38204426d5eb2059cc + size: 1041379 + subdir: linux-64 + timestamp: 1764836112865 + version: 15.2.0 + fn: libgcc-15.2.0-he0feb66_15.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgcc-15.2.0-he0feb66_15.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb9d3cd8_2 + build_number: 2 + constrains: + - xz 5.8.1.* + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: 0BSD + md5: 1a580f7796c7bf6393fddb8bbbde58dc + name: liblzma + run_exports: + weak: + - liblzma >=5.8.1,<6.0a0 + sha256: f2591c0069447bbe28d4d696b7fcb0c5bd0b4ac582769b89addbcf26fb3430d8 + size: 112894 + subdir: linux-64 + timestamp: 1749230047870 + version: 5.8.1 + fn: liblzma-5.8.1-hb9d3cd8_2.conda + url: https://conda.anaconda.org/conda-forge/linux-64/liblzma-5.8.1-hb9d3cd8_2.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb9d3cd8_1 + build_number: 1 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: LGPL-2.1-only + license_family: GPL + md5: d864d34357c3b65a4b731f78c0801dc4 + name: libnsl + run_exports: + weak: + - libnsl >=2.0.1,<2.1.0a0 + sha256: 927fe72b054277cde6cb82597d0fcf6baf127dcbce2e0a9d8925a68f1265eef5 + size: 33731 + subdir: linux-64 + timestamp: 1750274110928 + version: 2.0.1 + fn: libnsl-2.0.1-hb9d3cd8_1.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libnsl-2.0.1-hb9d3cd8_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h0c1763c_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + - libzlib >=1.3.1,<2.0a0 + license: blessing + md5: 2e1b84d273b01835256e53fd938de355 + name: libsqlite + run_exports: + weak: + - libsqlite >=3.51.1,<4.0a0 + sha256: 6f0e8a812e8e33a4d8b7a0e595efe28373080d27b78ee4828aa4f6649a088454 + size: 938979 + subdir: linux-64 + timestamp: 1764359444435 + version: 3.51.1 + fn: libsqlite-3.51.1-h0c1763c_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libsqlite-3.51.1-h0c1763c_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h5347b49_1 + build_number: 1 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: BSD-3-Clause + license_family: BSD + md5: 41f5c09a211985c3ce642d60721e7c3e + name: libuuid + run_exports: + weak: + - libuuid >=2.41.2,<3.0a0 + sha256: 030447cf827c471abd37092ab9714fde82b8222106f22fde94bc7a64e2704c40 + size: 40235 + subdir: linux-64 + timestamp: 1764790744114 + version: 2.41.2 + fn: libuuid-2.41.2-h5347b49_1.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libuuid-2.41.2-h5347b49_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hd590300_1 + build_number: 1 + depends: + - libgcc-ng >=12 + license: LGPL-2.1-or-later + md5: 5aa797f8787fe7a17d1b0821485b5adc + name: libxcrypt + run_exports: + weak: + - libxcrypt >=4.4.36 + sha256: 6ae68e0b86423ef188196fff6207ed0c8195dd84273cb5623b85aa08033a410c + size: 100393 + subdir: linux-64 + timestamp: 1702724383534 + version: 4.4.36 + fn: libxcrypt-4.4.36-hd590300_1.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libxcrypt-4.4.36-hd590300_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h69a702a_15 + build_number: 15 + depends: + - libgcc 15.2.0 he0feb66_15 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + md5: 7b742943660c5173bb6a5c823021c9a0 + name: libgcc-ng + run_exports: + strong: + - libgcc + sha256: 497d8cdba0da8fa154613d1c15f585674cadc194964ed1b4fe7c2809938dc41f + size: 26834 + subdir: linux-64 + timestamp: 1764836127111 + version: 15.2.0 + fn: libgcc-ng-15.2.0-h69a702a_15.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgcc-ng-15.2.0-h69a702a_15.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb9d3cd8_2 + build_number: 2 + constrains: + - zlib 1.3.1 *_2 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: Zlib + license_family: Other + md5: edb0dca6bc32e4f4789199455a1dbeb8 + name: libzlib + run_exports: + weak: + - libzlib >=1.3.1,<2.0a0 + sha256: d4bfe88d7cb447768e31650f06257995601f89076080e76df55e3112d4e47dc4 + size: 60963 + subdir: linux-64 + timestamp: 1727963148474 + version: 1.3.1 + fn: libzlib-1.3.1-hb9d3cd8_2.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libzlib-1.3.1-hb9d3cd8_2.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h2d0b736_3 + build_number: 3 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: X11 AND BSD-3-Clause + md5: 47e340acb35de30501a76c7c799c41d7 + name: ncurses + run_exports: + weak: + - ncurses >=6.5,<7.0a0 + sha256: 3fde293232fa3fca98635e1167de6b7c7fda83caf24b9d6c91ec9eefb4f4d586 + size: 891641 + subdir: linux-64 + timestamp: 1738195959188 + version: '6.5' + fn: ncurses-6.5-h2d0b736_3.conda + url: https://conda.anaconda.org/conda-forge/linux-64/ncurses-6.5-h2d0b736_3.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h26f9b46_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - ca-certificates + - libgcc >=14 + license: Apache-2.0 + license_family: Apache + md5: 9ee58d5c534af06558933af3c845a780 + name: openssl + run_exports: + weak: + - openssl >=3.6.0,<4.0a0 + sha256: a47271202f4518a484956968335b2521409c8173e123ab381e775c358c67fe6d + size: 3165399 + subdir: linux-64 + timestamp: 1762839186699 + version: 3.6.0 + fn: openssl-3.6.0-h26f9b46_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/openssl-3.6.0-h26f9b46_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h8c095d6_2 + build_number: 2 + depends: + - libgcc >=13 + - ncurses >=6.5,<7.0a0 + license: GPL-3.0-only + license_family: GPL + md5: 283b96675859b20a825f8fa30f311446 + name: readline + run_exports: + weak: + - readline >=8.2,<9.0a0 + sha256: 2d6d0c026902561ed77cd646b5021aef2d4db22e57a5b0178dfc669231e06d2c + size: 282480 + subdir: linux-64 + timestamp: 1740379431762 + version: '8.2' + fn: readline-8.2-h8c095d6_2.conda + url: https://conda.anaconda.org/conda-forge/linux-64/readline-8.2-h8c095d6_2.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: noxft_ha0e22de_103 + build_number: 103 + constrains: + - xorg-libx11 >=1.8.12,<2.0a0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + - libzlib >=1.3.1,<2.0a0 + license: TCL + license_family: BSD + md5: 86bc20552bf46075e3d92b67f089172d + name: tk + run_exports: + weak: + - tk >=8.6.13,<8.7.0a0 + sha256: 1544760538a40bcd8ace2b1d8ebe3eb5807ac268641f8acdc18c69c5ebfeaf64 + size: 3284905 + subdir: linux-64 + timestamp: 1763054914403 + version: 8.6.13 + fn: tk-8.6.13-noxft_ha0e22de_103.conda + url: https://conda.anaconda.org/conda-forge/linux-64/tk-8.6.13-noxft_ha0e22de_103.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h78e105d_0 + build_number: 0 + depends: [] + license: LicenseRef-Public-Domain + md5: 4222072737ccff51314b5ece9c7d6f5a + name: tzdata + noarch: generic + run_exports: {} + sha256: 5aaa366385d716557e365f0a4e9c3fca43ba196872abbbe3d56bb610d131e192 + size: 122968 + subdir: noarch + timestamp: 1742727099393 + version: 2025b + fn: tzdata-2025b-h78e105d_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/tzdata-2025b-h78e105d_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_1 + build_number: 1 + depends: + - python >=3.9 + license: MIT + license_family: MIT + md5: 75cb7132eb58d97896e173ef12ac9986 + name: wheel + noarch: python + run_exports: {} + sha256: 1b34021e815ff89a4d902d879c3bd2040bc1bd6169b32e9427497fa05c55f1ce + size: 62931 + subdir: noarch + timestamp: 1733130309598 + version: 0.45.1 + fn: wheel-0.45.1-pyhd8ed1ab_1.conda + url: https://conda.anaconda.org/conda-forge/noarch/wheel-0.45.1-pyhd8ed1ab_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb78ec9c_6 + build_number: 6 + depends: + - __glibc >=2.17,<3.0.a0 + - libzlib >=1.3.1,<2.0a0 + license: BSD-3-Clause + license_family: BSD + md5: 4a13eeac0b5c8e5b8ab496e6c4ddd829 + name: zstd + run_exports: + weak: + - zstd >=1.5.7,<1.6.0a0 + sha256: 68f0206ca6e98fea941e5717cec780ed2873ffabc0e1ed34428c061e2c6268c7 + size: 601375 + subdir: linux-64 + timestamp: 1764777111296 + version: 1.5.7 + fn: zstd-1.5.7-hb78ec9c_6.conda + url: https://conda.anaconda.org/conda-forge/linux-64/zstd-1.5.7-hb78ec9c_6.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: 2_gnu + build_number: 16 + constrains: + - openmp_impl 9999 + depends: + - _libgcc_mutex 0.1 conda_forge + - libgomp >=7.5.0 + license: BSD-3-Clause + license_family: BSD + md5: 73aaf86a425cc6e73fcf236a5a46396d + name: _openmp_mutex + run_exports: + strong: + - _openmp_mutex >=4.5 + sha256: fbe2c5e56a653bebb982eda4876a9178aedfc2b545f25d0ce9c4c0b508253d22 + size: 23621 + subdir: linux-64 + timestamp: 1650670423406 + version: '4.5' + fn: _openmp_mutex-4.5-2_gnu.tar.bz2 + url: https://conda.anaconda.org/conda-forge/linux-64/_openmp_mutex-4.5-2_gnu.tar.bz2 + channel: https://conda.anaconda.org/conda-forge/ + - build: he0feb66_15 + build_number: 15 + depends: + - __glibc >=2.17,<3.0.a0 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + md5: a90d6983da0757f4c09bb8fcfaf34e71 + name: libgomp + run_exports: + strong: + - _openmp_mutex >=4.5 + sha256: b3c4e39be7aba6f5a8695d428362c5c918b96a281ce0a7037f1e889dfc340615 + size: 602978 + subdir: linux-64 + timestamp: 1764836011147 + version: 15.2.0 + fn: libgomp-15.2.0-he0feb66_15.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgomp-15.2.0-he0feb66_15.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: conda_forge + build_number: 0 + depends: [] + license: None + md5: d7c89558ba9fa0495403155b64376d81 + name: _libgcc_mutex + run_exports: {} + sha256: fe51de6107f9edc7aa4f786a70f4a883943bc9d39b3bb7307c04c41410990726 + size: 2562 + subdir: linux-64 + timestamp: 1578324546067 + version: '0.1' + fn: _libgcc_mutex-0.1-conda_forge.tar.bz2 + url: https://conda.anaconda.org/conda-forge/linux-64/_libgcc_mutex-0.1-conda_forge.tar.bz2 + channel: https://conda.anaconda.org/conda-forge/ + - build: hbd8a1cb_0 + build_number: 0 + depends: + - __unix + license: ISC + md5: f0991f0f84902f6b6009b4d2350a83aa + name: ca-certificates + noarch: generic + run_exports: {} + sha256: b986ba796d42c9d3265602bc038f6f5264095702dd546c14bc684e60c385e773 + size: 152432 + subdir: noarch + timestamp: 1762967197890 + version: 2025.11.12 + fn: ca-certificates-2025.11.12-hbd8a1cb_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/ca-certificates-2025.11.12-hbd8a1cb_0.conda + channel: https://conda.anaconda.org/conda-forge/ + run: + depends: + - source: python >=3.10 + - spec: python + from: host + run_export: python + constraints: [] +finalized_sources: +- url: https://pypi.org/packages/source/p/pytokens/pytokens-0.3.0.tar.gz + sha256: 2f932b14ed08de5fcf0b391ace2642f858f1394c0857202959000b68ed7a458a +system_tools: + rattler-build: 0.53.0 +extra_meta: + flow_run_id: azure_20251208.1.1 + remote_url: https://github.com/conda-forge/pytokens-feedstock + sha: e15dc3d90d899c9406a96dbdf21b9675fb4006ec diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/recipe/variant_config.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/recipe/variant_config.yaml new file mode 100644 index 0000000000000000000000000000000000000000..9c9555bc0715cf4927cf43dc30e6dd1e88c57b9a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/recipe/variant_config.yaml @@ -0,0 +1,4 @@ +channel_sources: conda-forge +channel_targets: conda-forge main +python_min: '3.10' +target_platform: noarch diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/repodata_record.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/repodata_record.json new file mode 100644 index 0000000000000000000000000000000000000000..ee9e3fe079bc3a3e76160e15c54ad82a011a2272 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/repodata_record.json @@ -0,0 +1,22 @@ +{ + "build": "pyhcf101f3_0", + "build_number": 0, + "build_string": "pyhcf101f3_0", + "channel": "conda-forge", + "constrains": [], + "depends": [ + "python >=3.10", + "python" + ], + "fn": "pytokens-0.3.0-pyhcf101f3_0.conda", + "license": "MIT", + "md5": "4b1812cb7a8143ee00aef43831fb0d29", + "name": "pytokens", + "noarch": "python", + "sha256": "562d54fa0717b7117ee7f6b5f832c6535bf5e44de2dfa2f7056912e53d346469", + "size": 18860, + "subdir": "noarch", + "timestamp": 1765201048, + "url": "https://conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0.conda", + "version": "0.3.0" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/tests/tests.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/tests/tests.yaml new file mode 100644 index 0000000000000000000000000000000000000000..2e593074556e2de4cb06a67b1b30b8378047c8c9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/info/tests/tests.yaml @@ -0,0 +1,4 @@ +- python: + imports: + - pytokens + python_version: 3.10.* diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/INSTALLER b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/INSTALLER new file mode 100644 index 0000000000000000000000000000000000000000..a34a7e56db35cc4c85bfa166244b3d63a6a240d4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/INSTALLER @@ -0,0 +1 @@ +conda diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/METADATA b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/METADATA new file mode 100644 index 0000000000000000000000000000000000000000..6b258157adb0eea2e637a6f92a7b895899f165db --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/METADATA @@ -0,0 +1,76 @@ +Metadata-Version: 2.4 +Name: pytokens +Version: 0.3.0 +Summary: A Fast, spec compliant Python 3.14+ tokenizer that runs on older Pythons. +Home-page: https://github.com/tusharsadhwani/pytokens +Author: Tushar Sadhwani +Author-email: tushar.sadhwani000@gmail.com +License: MIT +Classifier: License :: OSI Approved :: MIT License +Classifier: Operating System :: OS Independent +Classifier: Programming Language :: Python :: 3 +Classifier: Programming Language :: Python :: 3 :: Only +Classifier: Programming Language :: Python :: 3.8 +Classifier: Programming Language :: Python :: 3.9 +Classifier: Programming Language :: Python :: 3.10 +Classifier: Programming Language :: Python :: 3.11 +Classifier: Programming Language :: Python :: 3.12 +Classifier: Programming Language :: Python :: Implementation :: CPython +Classifier: Typing :: Typed +Requires-Python: >=3.8 +Description-Content-Type: text/markdown +License-File: LICENSE +Provides-Extra: dev +Requires-Dist: black; extra == "dev" +Requires-Dist: build; extra == "dev" +Requires-Dist: mypy; extra == "dev" +Requires-Dist: pytest; extra == "dev" +Requires-Dist: pytest-cov; extra == "dev" +Requires-Dist: setuptools; extra == "dev" +Requires-Dist: tox; extra == "dev" +Requires-Dist: twine; extra == "dev" +Requires-Dist: wheel; extra == "dev" +Dynamic: license-file + +# pytokens + +A Fast, spec compliant Python 3.14+ tokenizer that runs on older Pythons. + +## Installation + +```bash +pip install pytokens +``` + +## Usage + +```bash +python -m pytokens path/to/file.py +``` + +## Local Development / Testing + +- Create and activate a virtual environment +- Run `pip install -r requirements-dev.txt` to do an editable install +- Run `pytest` to run tests + +## Type Checking + +Run `mypy .` + +## Create and upload a package to PyPI + +Make sure to bump the version in `setup.cfg`. + +Then run the following commands: + +```bash +rm -rf dist +python -m build +``` + +Then upload it to PyPI using [twine](https://twine.readthedocs.io/en/latest/#installation): + +```bash +twine upload dist/* +``` diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/RECORD b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/RECORD new file mode 100644 index 0000000000000000000000000000000000000000..360c8782bd3a517ad92a2e36acd48cbb3d9cc801 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/RECORD @@ -0,0 +1,15 @@ +pytokens-0.3.0.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +pytokens-0.3.0.dist-info/METADATA,sha256=S0NOv54f0xbFSFyCd7Unlj0FNABpVVNG39G-JD20LB8,1983 +pytokens-0.3.0.dist-info/RECORD,, +pytokens-0.3.0.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pytokens-0.3.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91 +pytokens-0.3.0.dist-info/direct_url.json,sha256=QmQn4OYlQEcRJfaJVjdu5NtUd5irymWE-tRR9_eMkdo,119 +pytokens-0.3.0.dist-info/licenses/LICENSE,sha256=lL965OpoM7CFOnzB8fKN2FebNKMcnBYq64gl3sI-1dw,1072 +pytokens-0.3.0.dist-info/top_level.txt,sha256=D7-37XW5Efz3vjguMITLFjDDJPKEhOGJNk7zS4IUcVA,9 +pytokens/__init__.py,sha256=42SyfhW8dZanzrcrJwBj0toUdG0wy0-5UnEatAro1cQ,39498 +pytokens/__main__.py,sha256=zJ2m95fz1-W8wuTFWmr8zleOY9ZUO6J4-lxMk2uneEA,184 +pytokens/__pycache__/__init__.cpython-310.pyc,, +pytokens/__pycache__/__main__.cpython-310.pyc,, +pytokens/__pycache__/cli.cpython-310.pyc,, +pytokens/cli.py,sha256=2W52vjmAj-VTufj5saJ4f4UOh04AYz5M98noqIZsXDw,6174 +pytokens/py.typed,sha256=DtCsIDq6KOv2NOEdQjTbeMWJKRh6ZEL2E-6Mf1RLeMA,59 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/REQUESTED b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/REQUESTED new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/WHEEL b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/WHEEL new file mode 100644 index 0000000000000000000000000000000000000000..e7fa31b6f3f78deb1022c1f7927f07d4d16da822 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/WHEEL @@ -0,0 +1,5 @@ +Wheel-Version: 1.0 +Generator: setuptools (80.9.0) +Root-Is-Purelib: true +Tag: py3-none-any + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/direct_url.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/direct_url.json new file mode 100644 index 0000000000000000000000000000000000000000..baa950b4b19f567fd53ef2c1981873828b8f5b32 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/direct_url.json @@ -0,0 +1 @@ +{"dir_info": {}, "url": "file:///home/conda/feedstock_root/build_artifacts/bld/rattler-build_pytokens_1765201048/work"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..def1a5ad7e10107456a048eb37339e8fb527d7f7 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/licenses/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2024 Tushar Sadhwani + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/top_level.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/top_level.txt new file mode 100644 index 0000000000000000000000000000000000000000..8277819e703f63f605a45018d88732f60984a669 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens-0.3.0.dist-info/top_level.txt @@ -0,0 +1 @@ +pytokens diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..8ccd99b06db0d0e3f510cb9322a61ed0f1d58c7c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens/__init__.py @@ -0,0 +1,1165 @@ +"""pytokens - A Fast, spec compliant Python 3.12+ tokenizer that runs on older Pythons.""" + +from __future__ import annotations + +from dataclasses import dataclass, field +import enum +import string +from typing import Iterator, NewType + + +class TokenizeError(Exception): ... + + +class IndentationError(TokenizeError): ... + + +class InconsistentUseOfTabsAndSpaces(IndentationError): ... + + +class DedentDoesNotMatchAnyOuterIndent(IndentationError): ... + + +class UnterminatedString(TokenizeError): ... + + +class UnexpectedEOF(TokenizeError): ... + + +class UnexpectedCharacterAfterBackslash(TokenizeError): ... + + +class NotAnIndent(AssertionError): ... + + +class Underflow(AssertionError): ... + + +class TokenType(enum.IntEnum): + whitespace = 1 + indent = 2 + dedent = 3 + newline = 4 # semantically meaningful newline + nl = 5 # non meaningful newline + comment = 6 + + _op_start = 7 # marker used to check if a token is an operator + semicolon = 8 + lparen = 9 + rparen = 10 + lbracket = 11 + rbracket = 12 + lbrace = 13 + rbrace = 14 + colon = 15 + op = 16 + _op_end = 17 # marker used to check if a token is an operator + + identifier = 18 + number = 19 + string = 20 + fstring_start = 21 + fstring_middle = 22 + fstring_end = 23 + + tstring_start = 24 + tstring_middle = 25 + tstring_end = 26 + + endmarker = 27 + + errortoken = 28 + + def __repr__(self) -> str: + return f"TokenType.{self.name}" + + def to_python_token(self) -> str: + if self.name == "identifier": + return "NAME" + + if self.is_operator(): + return "OP" + + return self.name.upper() + + def is_operator(self) -> bool: + return TokenType._op_start < self < TokenType._op_end + + +@dataclass +class Token: + type: TokenType + # Byte offsets in the file + start_index: int + end_index: int + start_line: int + # 0-indexed offset from start of line + start_col: int + end_line: int + end_col: int + + def to_byte_slice(self, source: str) -> str: + # Newline at end of file may not exist in the file + if ( + (self.type == TokenType.newline or self.type == TokenType.nl) + and self.start_index == len(source) + and self.end_index == len(source) + 1 + ): + return "" + + # Dedents at end of file also may not exist in the file + if ( + self.type == TokenType.dedent + and self.start_index == len(source) + 1 + and self.end_index == len(source) + 1 + ): + return "" + + # Endmarkers are out of bound too + if self.type == TokenType.endmarker: + return "" + + return source[self.start_index : self.end_index] + + +class FStringState: + State = NewType("State", int) + + not_fstring = State(1) + at_fstring_middle = State(2) + at_fstring_lbrace = State(3) + in_fstring_expr = State(4) + in_fstring_expr_modifier = State(5) + at_fstring_end = State(6) + + def __init__(self) -> None: + self.state = FStringState.not_fstring + self.stack: list[FStringState.State] = [] + + def enter_fstring(self) -> None: + self.stack.append(self.state) + self.state = FStringState.at_fstring_middle + + def leave_fstring(self) -> None: + assert self.state == FStringState.at_fstring_end + self.state = self.stack.pop() + + def consume_fstring_middle_for_lbrace(self) -> None: + if self.state == FStringState.in_fstring_expr_modifier: + self.stack.append(self.state) + + self.state = FStringState.at_fstring_lbrace + + def consume_fstring_middle_for_end(self) -> None: + self.state = FStringState.at_fstring_end + + def consume_lbrace(self) -> None: + self.state = FStringState.in_fstring_expr + + def consume_rbrace(self) -> None: + assert ( + self.state == FStringState.in_fstring_expr + or self.state == FStringState.in_fstring_expr_modifier + ) + + if ( + len(self.stack) > 0 + and self.stack[-1] == FStringState.in_fstring_expr_modifier + ): + self.state = self.stack.pop() + else: + self.state = FStringState.at_fstring_middle + + def consume_colon(self) -> None: + assert self.state == FStringState.in_fstring_expr + self.state = FStringState.in_fstring_expr_modifier + + +@dataclass +class TokenIterator: + source: str + issue_128233_handling: bool + + current_index: int = 0 + prev_index: int = 0 + line_number: int = 1 + prev_line_number: int = 1 + byte_offset: int = 0 + prev_byte_offset: int = 0 + all_whitespace_on_this_line: bool = True + + bracket_level: int = 0 + bracket_level_stack: list[int] = field(default_factory=list) + prev_token: Token | None = None + + indent_stack: list[str] = field(default_factory=list) + dedent_counter: int = 0 + + # f-string state + fstring_state: FStringState = field(default_factory=FStringState) + fstring_prefix_quote_stack: list[tuple[str, str]] = field(default_factory=list) + fstring_prefix: str | None = None + fstring_quote: str | None = None + + # CPython has a weird bug where every time a bare \r is + # present, the next token becomes an OP. regardless of what it is. + weird_op_case: bool = False + weird_op_case_nl: bool = False + + weird_whitespace_case: bool = False + + def is_in_bounds(self) -> bool: + return self.current_index < len(self.source) + + def peek(self) -> str: + assert self.is_in_bounds() + return self.source[self.current_index] + + def peek_next(self) -> str: + assert self.current_index + 1 < len(self.source) + return self.source[self.current_index + 1] + + def advance(self) -> None: + self.current_index += 1 + self.byte_offset += 1 + + def advance_by(self, count: int) -> None: + self.current_index += count + self.byte_offset += count + + def next_line(self) -> None: + self.line_number += 1 + self.byte_offset = 0 + self.all_whitespace_on_this_line = True + + def advance_check_newline(self) -> None: + if self.source[self.current_index] == "\n": + self.current_index += 1 + self.next_line() + else: + self.advance() + + def match(self, *options: str, ignore_case: bool = False) -> bool: + for option in options: + if self.current_index + len(option) > len(self.source): + continue + snippet = self.source[self.current_index : self.current_index + len(option)] + if ignore_case: + option = option.lower() + snippet = snippet.lower() + + if option == snippet: + return True + + return False + + def make_token(self, tok_type: TokenType) -> Token: + if self.fstring_prefix is not None and "t" in self.fstring_prefix: + if tok_type == TokenType.fstring_start: + tok_type = TokenType.tstring_start + elif tok_type == TokenType.fstring_middle: + tok_type = TokenType.tstring_middle + elif tok_type == TokenType.fstring_end: + tok_type = TokenType.tstring_end + + token_type = ( + TokenType.op + if self.weird_op_case + and not tok_type.is_operator() + and tok_type not in (TokenType.number, TokenType.string) + else tok_type + ) + if self.weird_op_case: + # And we have another weird case INSIDE the weird case. + # For some reason when CPython accidentally captures a space + # as the next character, i.e. when the token is '\r ', + # It DOESN't see it as whitespace, so in that specific case, + # we shouldn't set all_whitespace_on_this_line. + # I think this is because CPython never expecte to have a + # ' ' token in it anyway so it doesn't classify it as + # whitespace. So it becomes non-whitespace. + # Removing this if stmt breaks test 1001 right now. + token_str = self.source[self.prev_index : self.current_index] + if token_str == "\r ": + self.all_whitespace_on_this_line = False + self.weird_op_case = False + + token = Token( + type=token_type, + start_index=self.prev_index, + end_index=self.current_index, + start_line=self.prev_line_number, + start_col=self.prev_byte_offset, + end_line=self.line_number, + end_col=self.byte_offset, + ) + if tok_type == TokenType.newline or tok_type == TokenType.nl: + self.next_line() + elif tok_type == TokenType.whitespace or tok_type == TokenType.comment: + pass + else: + self.all_whitespace_on_this_line = False + + self.prev_token = token + self.prev_index = self.current_index + self.prev_line_number = self.line_number + self.prev_byte_offset = self.byte_offset + self.weird_op_case = False + + return token + + def push_fstring_prefix_quote(self, prefix: str, quote: str) -> None: + if self.fstring_prefix is not None: + assert self.fstring_quote is not None + self.fstring_prefix_quote_stack.append( + (self.fstring_prefix, self.fstring_quote) + ) + + self.fstring_prefix = prefix + self.fstring_quote = quote + + def pop_fstring_quote(self) -> None: + if self.fstring_prefix is None: + assert self.fstring_quote is None + raise Underflow + + self.fstring_prefix, self.fstring_quote = ( + (None, None) + if len(self.fstring_prefix_quote_stack) == 0 + else self.fstring_prefix_quote_stack.pop() + ) + + def newline(self) -> Token: + if self.is_in_bounds() and self.source[self.current_index] == "\r": + self.advance() + self.advance() + token_type = ( + TokenType.nl + if ( + self.weird_op_case_nl + or self.bracket_level > 0 + or self.fstring_state.state == FStringState.in_fstring_expr + or self.all_whitespace_on_this_line + ) + else TokenType.newline + ) + token = self.make_token(token_type) + self.weird_op_case_nl = False + return token + + def endmarker(self) -> Token: + if self.bracket_level != 0: + raise UnexpectedEOF + + if len(self.indent_stack) > 0: + _ = self.indent_stack.pop() + return self.make_token(TokenType.dedent) + + return self.make_token(TokenType.endmarker) + + def decimal(self) -> Token: + digit_before_decimal = False + if self.source[self.current_index].isdigit(): + digit_before_decimal = True + self.advance() + + # TODO: this is too lax; 1__2 tokenizes successfully + while self.is_in_bounds() and ( + self.source[self.current_index].isdigit() + or self.source[self.current_index] == "_" + ): + self.advance() + + if self.is_in_bounds() and self.source[self.current_index] == ".": + self.advance() + + while self.is_in_bounds() and ( + self.source[self.current_index].isdigit() + or ( + self.source[self.current_index] == "_" + and self.source[self.current_index - 1].isdigit() + ) + ): + self.advance() + # Before advancing over the 'e', ensure that there has been at least 1 digit before the 'e' + if self.current_index + 1 < len(self.source) and ( + (digit_before_decimal or self.source[self.current_index - 1].isdigit()) + and ( + self.source[self.current_index] == "e" + or self.source[self.current_index] == "E" + ) + and ( + self.source[self.current_index + 1].isdigit() + or ( + self.current_index + 2 < len(self.source) + and ( + self.source[self.current_index + 1] == "+" + or self.source[self.current_index + 1] == "-" + ) + and self.source[self.current_index + 2].isdigit() + ) + ) + ): + self.advance() + self.advance() + # optional third advance not necessary as itll get advanced just below + + # TODO: this is too lax; 1__2 tokenizes successfully + while self.is_in_bounds() and ( + self.source[self.current_index].isdigit() + or ( + (digit_before_decimal or self.source[self.current_index - 1].isdigit()) + and self.source[self.current_index] == "_" + ) + ): + self.advance() + + # Complex numbers end in a `j`. But ensure at least 1 digit before it + if self.is_in_bounds() and ( + (digit_before_decimal or self.source[self.current_index - 1].isdigit()) + and ( + self.source[self.current_index] == "j" + or self.source[self.current_index] == "J" + ) + ): + self.advance() + # If all of this resulted in just a dot, return an operator + if ( + self.current_index - self.prev_index == 1 + and self.source[self.current_index - 1] == "." + ): + # Ellipsis check + if ( + self.current_index + 2 <= len(self.source) + and self.source[self.current_index : self.current_index + 2] == ".." + ): + self.advance() + self.advance() + + return self.make_token(TokenType.op) + + return self.make_token(TokenType.number) + + def binary(self) -> Token: + # jump over `0b` + self.advance() + self.advance() + while self.is_in_bounds() and ( + self.source[self.current_index] == "0" + or self.source[self.current_index] == "1" + or self.source[self.current_index] == "_" + ): + self.advance() + if self.is_in_bounds() and ( + self.source[self.current_index] == "e" + or self.source[self.current_index] == "E" + ): + self.advance() + if self.is_in_bounds() and self.source[self.current_index] == "-": + self.advance() + + while self.is_in_bounds() and ( + self.source[self.current_index] == "0" + or self.source[self.current_index] == "1" + or self.source[self.current_index] == "_" + ): + self.advance() + return self.make_token(TokenType.number) + + def octal(self) -> Token: + # jump over `0o` + self.advance() + self.advance() + while self.is_in_bounds() and ( + self.source[self.current_index] >= "0" + and self.source[self.current_index] <= "7" + or self.source[self.current_index] == "_" + ): + self.advance() + if self.is_in_bounds() and ( + self.source[self.current_index] == "e" + or self.source[self.current_index] == "E" + ): + self.advance() + if self.is_in_bounds() and self.source[self.current_index] == "-": + self.advance() + + while self.is_in_bounds() and ( + self.source[self.current_index] >= "0" + and self.source[self.current_index] <= "7" + or self.source[self.current_index] == "_" + ): + self.advance() + return self.make_token(TokenType.number) + + def hexadecimal(self) -> Token: + # jump over `0x` + self.advance() + self.advance() + while self.is_in_bounds() and ( + self.source[self.current_index] in string.hexdigits + or self.source[self.current_index] == "_" + ): + self.advance() + if self.is_in_bounds() and ( + self.source[self.current_index] == "e" + or self.source[self.current_index] == "E" + ): + self.advance() + if self.is_in_bounds() and self.source[self.current_index] == "-": + self.advance() + + while self.is_in_bounds() and ( + self.source[self.current_index] in string.hexdigits + or self.source[self.current_index] == "_" + ): + self.advance() + return self.make_token(TokenType.number) + + def find_opening_quote(self) -> int: + # Quotes should always be within 3 chars of the beginning of the string token + for offset in range(3): + char = self.source[self.current_index + offset] + if char == '"' or char == "'": + return self.current_index + offset + + raise AssertionError("Quote not found somehow") + + def string_prefix_and_quotes(self) -> tuple[str, str]: + quote_index = self.find_opening_quote() + prefix = self.source[self.current_index : quote_index] + quote_char = self.source[quote_index] + + # Check for triple quotes + quote = ( + self.source[quote_index : quote_index + 3] + if ( + quote_index + 3 <= len(self.source) + and self.source[quote_index + 1] == quote_char + and self.source[quote_index + 2] == quote_char + ) + else self.source[quote_index : quote_index + 1] + ) + return prefix, quote + + def fstring(self) -> Token: + if self.fstring_state.state in ( + FStringState.not_fstring, + FStringState.in_fstring_expr, + ): + prefix, quote = self.string_prefix_and_quotes() + + self.push_fstring_prefix_quote(prefix, quote) + for _ in range(len(prefix)): + self.advance() + for _ in range(len(quote)): + self.advance() + self.fstring_state.enter_fstring() + return self.make_token(TokenType.fstring_start) + + if self.fstring_state.state == FStringState.at_fstring_middle: + assert self.fstring_quote is not None + is_single_quote = len(self.fstring_quote) == 1 + start_index = self.current_index + while self.is_in_bounds(): + char = self.source[self.current_index] + # For single quotes, bail on newlines + if char == "\n" and is_single_quote: + raise UnterminatedString + + # Handle escapes + if char == "\\": + self.advance() + # But don't escape a `\{` or `\}` in f-strings + # but DO escape `\N{` in f-strings, that's for unicode characters + # but DON'T escape `\N{` in raw f-strings. + assert self.fstring_prefix is not None + if ( + "r" not in self.fstring_prefix.lower() + and self.current_index + 1 < len(self.source) + and self.peek() == "N" + and self.peek_next() == "{" + ): + self.advance() + self.advance() + + if self.is_in_bounds() and not ( + self.peek() == "{" or self.peek() == "}" + ): + self.advance_check_newline() + + continue + + # Find opening / closing quote + if char == "{": + if self.peek_next() == "{": + self.advance() + self.advance() + continue + else: + self.fstring_state.consume_fstring_middle_for_lbrace() + # If fstring-middle is empty, skip it by returning the next step token + if self.current_index == start_index: + return self.fstring() + + return self.make_token(TokenType.fstring_middle) + + assert self.fstring_quote is not None + if self.match(self.fstring_quote): + self.fstring_state.consume_fstring_middle_for_end() + # If fstring-middle is empty, skip it by returning the next step token + if self.current_index == start_index: + return self.fstring() + + return self.make_token(TokenType.fstring_middle) + + self.advance_check_newline() + + raise UnexpectedEOF + + if self.fstring_state.state == FStringState.at_fstring_lbrace: + self.advance() + self.bracket_level_stack.append(self.bracket_level) + self.bracket_level = 0 + self.fstring_state.consume_lbrace() + return self.make_token(TokenType.lbrace) + + if self.fstring_state.state == FStringState.at_fstring_end: + assert self.fstring_quote is not None + for _ in range(len(self.fstring_quote)): + self.advance() + token = self.make_token(TokenType.fstring_end) + self.pop_fstring_quote() + self.fstring_state.leave_fstring() + return token + + if self.fstring_state.state == FStringState.in_fstring_expr_modifier: + start_index = self.current_index + while self.is_in_bounds(): + char = self.source[self.current_index] + assert self.fstring_quote is not None + if (char == "\n" or char == "{") and len(self.fstring_quote) == 1: + if char == "{": + self.fstring_state.consume_fstring_middle_for_lbrace() + else: + # TODO: why? + self.fstring_state.state = FStringState.in_fstring_expr + + # If fstring-middle is empty, skip it by returning the next step token + if self.current_index == start_index: + return self.fstring() + + return self.make_token(TokenType.fstring_middle) + elif char == "}": + self.fstring_state.state = FStringState.in_fstring_expr + return self.make_token(TokenType.fstring_middle) + + self.advance_check_newline() + + raise UnexpectedEOF + + raise AssertionError("Unhandled f-string state") + + def string(self) -> Token: + prefix, quote = self.string_prefix_and_quotes() + if prefix and self.weird_op_case: + self.advance() + return self.make_token(tok_type=TokenType.op) + + for char in prefix: + if char in ("f", "F", "t", "T"): + return self.fstring() + + for _ in range(len(prefix)): + self.advance() + for _ in range(len(quote)): + self.advance() + + is_single_quote = len(quote) == 1 + + while self.is_in_bounds(): + char = self.source[self.current_index] + # For single quotes, bail on newlines + if char == "\n" and is_single_quote: + raise UnterminatedString + + # Handle escapes + if char == "\\": + self.advance() + self.advance_check_newline() + continue + + # Find closing quote + if self.match(quote): + for _ in range(len(quote)): + self.advance() + return self.make_token(TokenType.string) + + self.advance_check_newline() + + raise UnexpectedEOF + + def indent(self) -> Token: + start_index = self.current_index + saw_whitespace = False + saw_tab_or_space = False + while self.is_in_bounds(): + char = self.source[self.current_index] + if self.is_whitespace(): + self.advance() + saw_whitespace = True + if char == " " or char == "\t": + saw_tab_or_space = True + else: + break + + if not self.is_in_bounds(): + # File ends with no whitespace after newline, don't return indent + if self.current_index == start_index: + raise NotAnIndent + # If reached the end of the file, don't return an indent + return self.make_token(TokenType.whitespace) + + # If the line is preceded by just linefeeds/CR/etc., + # treat it as whitespace. + if saw_whitespace and not saw_tab_or_space: + self.weird_whitespace_case = True + return self.make_token(TokenType.whitespace) + + # For lines that are just leading whitespace and a slash or a comment, + # don't return indents + next_char = self.peek() + if next_char == "#" or next_char == "\\" or self.is_newline(): + return self.make_token(TokenType.whitespace) + + new_indent = self.source[start_index : self.current_index] + current_indent = "" if len(self.indent_stack) == 0 else self.indent_stack[-1] + + if len(new_indent) == len(current_indent): + if len(new_indent) == 0: + raise NotAnIndent + + if new_indent != current_indent: + raise InconsistentUseOfTabsAndSpaces + return self.make_token(TokenType.whitespace) + elif len(new_indent) > len(current_indent): + if len(current_indent) > 0 and current_indent not in new_indent: + raise InconsistentUseOfTabsAndSpaces + self.indent_stack.append(new_indent) + return self.make_token(TokenType.indent) + else: + while len(self.indent_stack) > 0: + top_indent = self.indent_stack[-1] + if len(top_indent) < len(new_indent): + raise DedentDoesNotMatchAnyOuterIndent + + if len(top_indent) == len(new_indent): + break + + _ = self.indent_stack.pop() + self.dedent_counter += 1 + + # Let the dedent counter make the dedents. They must be length zero + return self.make_token(TokenType.whitespace) + + def is_whitespace(self) -> bool: + if self.is_newline(): + return False + + char = self.source[self.current_index] + return ( + char == " " + or char == "\r" + or char == "\t" + or char == "\x0b" + or char == "\x0c" + ) + + def is_newline(self) -> bool: + if self.source[self.current_index] == "\n": + return True + if ( + self.source[self.current_index] == "\r" + and self.current_index + 1 < len(self.source) + and self.source[self.current_index + 1] == "\n" + ): + return True + + return False + + def name(self) -> Token: + if self.weird_op_case: + self.advance() + return self.make_token(TokenType.identifier) + + # According to PEP 3131, any non-ascii character is valid in a NAME token. + # But if we see any non-identifier ASCII character we should stop. + remaining = self.source[self.current_index :] + for index, char in enumerate(remaining): + if ord(char) < 128 and not str.isalnum(char) and char != "_": + length = index + break + else: + length = len(remaining) + + self.advance_by(length) + return self.make_token(TokenType.identifier) + + def __iter__(self) -> TokenIterator: + return self + + def __next__(self) -> Token: + if self.prev_token is not None and self.prev_token.type == TokenType.endmarker: + raise StopIteration + + # EOF checks + if self.current_index == len(self.source): + if self.prev_token is None: + return self.endmarker() + + if self.prev_token.type in { + TokenType.newline, + TokenType.nl, + TokenType.dedent, + }: + return self.endmarker() + else: + return self.newline() + + if self.current_index > len(self.source): + return self.endmarker() + + # f-string check + if ( + self.fstring_state.state != FStringState.not_fstring + and self.fstring_state.state != FStringState.in_fstring_expr + ): + return self.fstring() + + current_char = self.source[self.current_index] + + # \r on its own, in certain cases it gets merged with the next char. + # It's probably a bug: https://github.com/python/cpython/issues/128233 + # 'issue_128233_handling=True' works around this bug, but if it's False + # then we produce identical tokens to CPython. + if not self.issue_128233_handling and current_char == "\r": + self.advance() + if not self.is_in_bounds(): + return self.newline() + + current_char = self.source[self.current_index] + if current_char != "\n": + self.weird_op_case = True + if ( + self.prev_token is not None + and self.prev_token.type == TokenType.comment + ): + self.weird_op_case_nl = True + + # Comment check + if current_char == "#": + if self.weird_op_case: + self.advance() + return self.make_token(TokenType.comment) + + while self.is_in_bounds() and not self.is_newline(): + if ( + not self.issue_128233_handling + and self.source[self.current_index] == "\r" + ): + break + self.advance() + return self.make_token(TokenType.comment) + + # Empty the dedent counter + if self.dedent_counter > 0: + self.dedent_counter -= 1 + return self.make_token(TokenType.dedent) + + # Newline check + if self.is_newline(): + return self.newline() + + # \<newline> check + if current_char == "\\": + self.advance() + if not self.is_in_bounds(): + raise UnexpectedEOF + + # Consume all whitespace on this line and the next. + found_whitespace = False + seen_newline = False + while self.is_in_bounds(): + if self.is_whitespace(): + self.advance() + found_whitespace = True + elif not seen_newline and (self.is_newline()): + char = self.source[self.current_index] + if char == "\r": + self.advance() + self.advance() + found_whitespace = True + seen_newline = True + # Move to next line without creating a newline token. But, + # if the previous line was all whitespace, whitespace on + # the next line is still valid indentation. Avoid consuming + if self.all_whitespace_on_this_line: + self.next_line() + break + else: + self.next_line() + # Preserve this boolean, we're on the same line semantically + self.all_whitespace_on_this_line = False + + else: + break + + if not found_whitespace: + raise UnexpectedCharacterAfterBackslash + + return self.make_token(TokenType.whitespace) + + # Indent / dedent checks + if ( + (self.byte_offset == 0 or self.weird_whitespace_case) + and self.bracket_level == 0 + and self.fstring_state.state == FStringState.not_fstring + ): + self.weird_whitespace_case = False + try: + indent_token = self.indent() + except NotAnIndent: + indent_token = None + + if indent_token is not None: + return indent_token + + if self.is_whitespace(): + while self.is_in_bounds() and self.is_whitespace(): + self.advance() + return self.make_token(TokenType.whitespace) + + if current_char in ("+", "&", "|", "^", "@", "%", "=", "!", "~"): + self.advance() + if self.peek() == "=": + self.advance() + return self.make_token(TokenType.op) + + if current_char == "<": + self.advance() + if self.peek() == ">": + # Barry as FLUFL easter egg + self.advance() + return self.make_token(TokenType.op) + + if self.peek() == "<": + self.advance() + if self.peek() == "=": + self.advance() + return self.make_token(TokenType.op) + + if current_char == ">": + self.advance() + if self.peek() == ">": + self.advance() + if self.peek() == "=": + self.advance() + return self.make_token(TokenType.op) + + if current_char == "/": + self.advance() + if self.peek() == "/": + self.advance() + if self.peek() == "=": + self.advance() + return self.make_token(TokenType.op) + + if current_char == "*": + self.advance() + if self.peek() == "*": + self.advance() + if self.peek() == "=": + self.advance() + return self.make_token(TokenType.op) + + if current_char == "-": + self.advance() + # -> operator + if self.peek() == ">": + self.advance() + return self.make_token(TokenType.op) + + # -= operator + if self.peek() == "=": + self.advance() + return self.make_token(TokenType.op) + + if current_char in (",", ";"): + self.advance() + return self.make_token(TokenType.op) + + # This guy is not used in Python3, but still exists + # for backwards compatibility i guess. + if current_char == "`": + self.advance() + return self.make_token(TokenType.op) + + if current_char == "(": + self.advance() + self.bracket_level += 1 + return self.make_token(TokenType.lparen) + + if current_char == ")": + self.advance() + self.bracket_level -= 1 + if self.bracket_level < 0: + self.bracket_level = 0 + return self.make_token(TokenType.rparen) + + if current_char == "[": + self.advance() + self.bracket_level += 1 + return self.make_token(TokenType.lbracket) + + if current_char == "]": + self.advance() + self.bracket_level -= 1 + if self.bracket_level < 0: + self.bracket_level = 0 + return self.make_token(TokenType.rbracket) + + if current_char == "{": + self.advance() + self.bracket_level += 1 + return self.make_token(TokenType.lbrace) + + if current_char == "}": + self.advance() + if ( + self.bracket_level == 0 + and self.fstring_state.state == FStringState.in_fstring_expr + ): + self.fstring_state.consume_rbrace() + self.bracket_level = self.bracket_level_stack.pop() + else: + self.bracket_level -= 1 + if self.bracket_level < 0: + self.bracket_level = 0 + + return self.make_token(TokenType.rbrace) + + if current_char == ":": + self.advance() + if ( + self.bracket_level == 0 + and self.fstring_state.state == FStringState.in_fstring_expr + ): + self.fstring_state.state = FStringState.in_fstring_expr_modifier + return self.make_token(TokenType.op) + else: + if self.peek() == "=": + self.advance() + return self.make_token(TokenType.op) + + if current_char in ".0123456789": + if self.current_index + 2 <= len(self.source) and self.source[ + self.current_index : self.current_index + 2 + ] in ("0b", "0B"): + return self.binary() + elif self.current_index + 2 <= len(self.source) and self.source[ + self.current_index : self.current_index + 2 + ] in ("0o", "0O"): + return self.octal() + elif self.current_index + 2 <= len(self.source) and self.source[ + self.current_index : self.current_index + 2 + ] in ("0x", "0X"): + return self.hexadecimal() + else: + return self.decimal() + + if ( + (self.current_index + 1 <= len(self.source) and self.match('"', "'")) + or ( + self.current_index + 2 <= len(self.source) + and self.match( + 'b"', + "b'", + 'r"', + "r'", + 'f"', + "f'", + 'u"', + "u'", + "t'", + 't"', + ignore_case=True, + ) + ) + or ( + self.current_index + 3 <= len(self.source) + and self.match( + 'br"', + "br'", + 'rb"', + "rb'", + 'fr"', + "fr'", + 'rf"', + "rf'", + "tr'", + 'tr"', + "rt'", + 'rt"', + ignore_case=True, + ) + ) + ): + return self.string() + + return self.name() + + +def tokenize( + source: str, + *, + fstring_tokens: bool = True, + issue_128233_handling: bool = True, +) -> Iterator[Token]: + token_iterator = TokenIterator(source, issue_128233_handling=issue_128233_handling) + if fstring_tokens: + return iter(token_iterator) + + return merge_fstring_tokens(token_iterator) + + +def merge_fstring_tokens(token_iterator: TokenIterator) -> Iterator[Token]: + """Turn post-Python-3.12 FSTRING-* tokens back to a single STRING token.""" + for token in token_iterator: + if token.type not in (TokenType.fstring_start, TokenType.tstring_start): + yield token + continue + + start_token = token + end_token = token + + fstring_starts = 1 + fstring_ends = 0 + for token in token_iterator: + if token.type in (TokenType.fstring_start, TokenType.tstring_start): + fstring_starts += 1 + if token.type in (TokenType.fstring_end, TokenType.tstring_end): + fstring_ends += 1 + + if fstring_starts == fstring_ends: + end_token = token + break + + yield Token( + type=TokenType.string, + start_index=start_token.start_index, + start_line=start_token.start_line, + start_col=start_token.start_col, + end_index=end_token.end_index, + end_line=end_token.end_line, + end_col=end_token.end_col, + ) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens/__main__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens/__main__.py new file mode 100644 index 0000000000000000000000000000000000000000..6ae31dc4d281ae51e5f5ac6995f607c86d9c3f91 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens/__main__.py @@ -0,0 +1,7 @@ +"""Support executing the CLI by doing `python -m pytokens`.""" +from __future__ import annotations + +from pytokens.cli import cli + +if __name__ == "__main__": + raise SystemExit(cli()) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens/cli.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens/cli.py new file mode 100644 index 0000000000000000000000000000000000000000..752e5c701949a292d6b3427100112a106652f29b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens/cli.py @@ -0,0 +1,192 @@ +"""CLI interface for pytokens.""" + +from __future__ import annotations + +import argparse +import io +import os.path +import tokenize +from typing import Iterable, NamedTuple +import warnings + +import pytokens + + +class CLIArgs: + filepath: str + validate: bool + issue_128233_handling: bool + + +def cli(argv: list[str] | None = None) -> int: + """CLI interface.""" + parser = argparse.ArgumentParser() + parser.add_argument("filepath") + parser.add_argument( + "--no-128233-handling", + dest="issue_128233_handling", + action="store_false", + ) + parser.add_argument("--validate", action="store_true") + args = parser.parse_args(argv, namespace=CLIArgs()) + + if os.path.isdir(args.filepath): + files = find_all_python_files(args.filepath) + verbose = False + else: + files = [args.filepath] + verbose = True + + for filepath in sorted(files): + with open(filepath, "rb") as file: + try: + encoding, read_bytes = tokenize.detect_encoding(file.readline) + except SyntaxError: + if args.validate: + # Broken `# coding` comment, tokenizer bails, skip file + print("\033[1;33mS\033[0m", end="", flush=True) + continue + + raise + + source = b"".join(read_bytes) + file.read() + + if args.validate: + validate( + filepath, + source, + encoding, + verbose=verbose, + issue_128233_handling=args.issue_128233_handling, + ) + + else: + source_str = source.decode(encoding) + for token in pytokens.tokenize( + source_str, + issue_128233_handling=args.issue_128233_handling, + ): + token_source = source_str[token.start_index : token.end_index] + print(repr(token_source), token) + + return 0 + + +class TokenTuple(NamedTuple): + type: str + start: tuple[int, int] + end: tuple[int, int] + + +def validate( + filepath: str, + source: bytes, + encoding: str, + *, + issue_128233_handling: bool, + verbose: bool = True, +) -> None: + """Validate the source code.""" + warnings.simplefilter("ignore") + + # Ensure all line endings have newline as a valid index + if len(source) == 0 or source[-1:] != b"\n": + source = source + b"\n" + + # Same as .splitlines(keepends=True), but doesn't split on linefeeds i.e. \x0c + sourcelines = [line + b"\n" for line in source.split(b"\n")] + # For that last newline token that exists on an imaginary line sometimes + sourcelines.append(b"\n") + + source_file = io.BytesIO(source) + builtin_tokens = tokenize.tokenize(source_file.readline) + # drop the encoding token + next(builtin_tokens) + + try: + expected_tokens_unprocessed = [ + TokenTuple(tokenize.tok_name[token.type], token.start, token.end) + for token in builtin_tokens + ] + except tokenize.TokenError: + print("\033[1;33mS\033[0m", end="", flush=True) + return + + expected_tokens = [expected_tokens_unprocessed[0]] + for index, token in enumerate(expected_tokens_unprocessed[1:], start=1): + last_token = expected_tokens[-1] + + current_token = token + # Merge consecutive FSTRING_MIDDLE tokens. it's weird cpython has it like that. + if current_token.type == last_token.type == "FSTRING_MIDDLE": + expected_tokens.pop() + current_token = TokenTuple( + current_token.type, + last_token.start, + current_token.end, + ) + + if index + 1 < len(expected_tokens_unprocessed): + # When an FSTRING_MIDDLE ends with a `{{{` like f'x{{{1}', Python eats + # the last { char as well as its end index, so we get a `x{` token + # instead of the expected `x{{` token. This fixes that case. Pretty + # much always there should be no gap between an fstring-middle ending + # and the { op after it. + # Same deal for `}}}"` + next_token = expected_tokens_unprocessed[index + 1] + if ( + (current_token.type == "FSTRING_MIDDLE" and next_token.type == "OP") + or ( + current_token.type == "FSTRING_MIDDLE" + and next_token.type == "FSTRING_END" + ) + and next_token.start[0] == current_token.end[0] + and next_token.start[1] > current_token.end[1] + ): + expected_tokens.append( + TokenTuple( + current_token.type, + current_token.start, + next_token.start, + ) + ) + continue + + expected_tokens.append(current_token) + + source_string = source.decode(encoding) + our_tokens = ( + TokenTuple( + token.type.to_python_token(), + (token.start_line, token.start_col), + (token.end_line, token.end_col), + ) + for token in pytokens.tokenize( + source_string, issue_128233_handling=issue_128233_handling + ) + if token.type != pytokens.TokenType.whitespace + ) + + for builtin_token, our_token in zip(expected_tokens, our_tokens, strict=True): + mismatch = builtin_token != our_token + if mismatch or verbose: + print("EXPECTED", builtin_token) + print("---- GOT", our_token) + + if mismatch: + print("Filepath:", filepath) + print("\033[1;31mF\033[0m", end="", flush=True) + # raise AssertionError("Tokens do not match") + return + + print("\033[1;32m.\033[0m", end="", flush=True) + + +def find_all_python_files(directory: str) -> Iterable[str]: + """Recursively find all Python files in the given directory.""" + python_files = set() + for root, _, files in os.walk(directory, followlinks=False): + for file in files: + if file.endswith(".py"): + python_files.add(os.path.join(root, file)) + return python_files diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens/py.typed b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens/py.typed new file mode 100644 index 0000000000000000000000000000000000000000..d3245e747a8bc085800a555ac3ea9f4ccdafbe4b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pytokens-0.3.0-pyhcf101f3_0/site-packages/pytokens/py.typed @@ -0,0 +1 @@ +# Marker file for PEP 561. This package uses inline types. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/about.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/about.json new file mode 100644 index 0000000000000000000000000000000000000000..9c62543af054256683d16adf13e9c11560bf253b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/about.json @@ -0,0 +1,242 @@ +{ + "channels": [ + "https://conda.anaconda.org/conda-forge" + ], + "conda_build_version": "26.1.0", + "conda_version": "26.1.0", + "dev_url": "https://github.com/yaml/pyyaml", + "doc_url": "http://pyyaml.org/wiki/PyYAML", + "env_vars": { + "CIO_TEST": "<not set>" + }, + "extra": { + "copy_test_source_files": true, + "final": true, + "flow_run_id": "azure_20260204.2.1", + "recipe-maintainers": [ + "jakirkham", + "msarahan", + "pelson", + "ocefpaf" + ], + "remote_url": "https://github.com/conda-forge/pyyaml-feedstock", + "sha": "c1f16949f0edec6fd6bf694330bec45716aad0f2" + }, + "home": "http://pyyaml.org/wiki/PyYAML", + "identifiers": [], + "keywords": [], + "license": "MIT", + "license_family": "MIT", + "license_file": "LICENSE", + "root_pkgs": [ + "tzdata 2025c hc9c84f9_1", + "markupsafe 3.0.3 py312h8a5da7c_0", + "jsonschema 4.26.0 pyhcf101f3_0", + "conda-package-handling 2.4.0 pyh7900ff3_2", + "zstd 1.5.7 hb78ec9c_6", + "libfreetype 2.14.1 ha770c72_0", + "libjpeg-turbo 3.1.2 hb03c661_0", + "backports.tarfile 1.2.0 pyhcf101f3_2", + "charset-normalizer 3.4.4 pyhd8ed1ab_0", + "libxcb 1.17.0 h8a09558_0", + "libcurl 8.18.0 h4e3cde8_0", + "libfreetype6 2.14.1 h73754d4_0", + "typing_extensions 4.15.0 pyhcf101f3_0", + "jsonpatch 1.33 pyhd8ed1ab_1", + "tqdm 4.67.3 pyh8f84b5b_0", + "perl 5.32.1 7_hd590300_perl5", + "jeepney 0.9.0 pyhd8ed1ab_0", + "liblzma-devel 5.8.2 hb03c661_0", + "keyring 25.7.0 pyha804496_0", + "xorg-libxdmcp 1.1.5 hb03c661_1", + "lzo 2.10 h280c20c_1002", + "filelock 3.20.3 pyhd8ed1ab_0", + "mamba 2.5.0 h9835478_0", + "python-dateutil 2.9.0.post0 pyhe01879c_2", + "zlib-ng 2.3.3 hceb46e0_1", + "lerc 4.0.0 h0aef613_1", + "libstdcxx-ng 15.2.0 hdf11a46_16", + "urllib3 2.6.3 pyhd8ed1ab_0", + "idna 3.11 pyhd8ed1ab_0", + "typing-inspection 0.4.2 pyhd8ed1ab_1", + "backports 1.0 pyhd8ed1ab_5", + "psutil 7.2.2 py312h5253ce2_0", + "ncurses 6.5 h2d0b736_3", + "readchar 4.2.1 pyhe01879c_0", + "libtiff 4.7.1 h9d88235_1", + "hyperframe 6.1.0 pyhd8ed1ab_0", + "py-lief 0.17.1 py312h1289d80_0", + "ld_impl_linux-64 2.45 default_hbd61a6d_105", + "defusedxml 0.7.1 pyhd8ed1ab_0", + "pygments 2.19.2 pyhd8ed1ab_0", + "frozendict 2.4.7 py312h4c3975b_0", + "pkginfo 1.12.1.2 pyhd8ed1ab_0", + "ruamel.yaml.clib 0.2.15 py312h5253ce2_1", + "libwebp-base 1.6.0 hd42ef1d_0", + "python-libarchive-c 5.3 pyhe01879c_1", + "referencing 0.37.0 pyhcf101f3_0", + "jaraco.context 6.1.0 pyhcf101f3_0", + "libxcrypt 4.4.36 hd590300_1", + "more-itertools 10.8.0 pyhcf101f3_1", + "mbedtls 3.6.3.1 h5888daf_0", + "keyutils 1.6.3 hb9d3cd8_0", + "anaconda-auth 0.12.3 pyhd8ed1ab_0", + "libglib 2.86.3 h6548e54_0", + "dbus 1.16.2 h24cb091_1", + "pyyaml 6.0.3 py312h8a5da7c_0", + "libdeflate 1.25 h17f619e_0", + "cffi 2.0.0 py312h460c074_1", + "zipp 3.23.0 pyhcf101f3_1", + "git 2.52.0 pl5321h6d3cee1_1", + "traitlets 5.14.3 pyhd8ed1ab_1", + "annotated-types 0.7.0 pyhd8ed1ab_1", + "libarchive 3.8.5 gpl_hc2c16d8_100", + "tini 0.19.0 h166bdaf_1", + "readline 8.3 h853b02a_0", + "jupyter_core 5.9.1 pyhc90fa1f_0", + "evalidate 2.0.5 pyhe01879c_0", + "c-ares 1.34.6 hb03c661_0", + "libedit 3.1.20250104 pl5321h7949ede_0", + "markdown-it-py 4.0.0 pyhd8ed1ab_0", + "libgcc-ng 15.2.0 h69a702a_16", + "archspec 0.2.5 pyhd8ed1ab_0", + "reproc-cpp 14.2.5.post0 h5888daf_0", + "distro 1.9.0 pyhd8ed1ab_1", + "libev 4.33 hd590300_2", + "rpds-py 0.30.0 py312h868fb18_0", + "truststore 0.10.4 pyhcf101f3_0", + "_libgcc_mutex 0.1 conda_forge", + "h2 4.3.0 pyhcf101f3_0", + "pybind11-abi 11 hc364b38_1", + "requests-toolbelt 1.0.0 pyhd8ed1ab_1", + "requests 2.32.5 pyhcf101f3_1", + "pthread-stubs 0.4 hb9d3cd8_1002", + "backports.zstd 1.3.0 py312h90b7ffd_0", + "ripgrep 15.1.0 hdab8a38_0", + "xorg-libxau 1.0.12 hb03c661_1", + "xz-gpl-tools 5.8.2 ha02ee65_0", + "packaging 26.0 pyhcf101f3_0", + "chardet 5.2.0 pyhd8ed1ab_3", + "patchelf 0.17.2 h58526e2_0", + "libzlib 1.3.1 hb9d3cd8_2", + "patch 2.8 hb03c661_1002", + "six 1.17.0 pyhe01879c_1", + "libpng 1.6.54 h421ea60_0", + "soupsieve 2.8.3 pyhd8ed1ab_0", + "secretstorage 3.4.1 py312h7900ff3_0", + "liblief 0.17.1 hecca717_0", + "lcms2 2.18 h0c24ade_0", + "fmt 12.1.0 hff5e90c_0", + "krb5 1.21.3 h659f571_0", + "su-exec 0.2 h166bdaf_1003", + "importlib_resources 6.5.2 pyhd8ed1ab_0", + "nbformat 5.10.4 pyhd8ed1ab_1", + "libxml2 2.15.1 he237659_1", + "importlib-metadata 8.7.0 pyhe01879c_1", + "conda 26.1.0 py312h7900ff3_0", + "python-fastjsonschema 2.21.2 pyhe01879c_0", + "python-dotenv 1.2.1 pyhcf101f3_0", + "libstdcxx 15.2.0 h934c35e_16", + "libmamba 2.5.0 hd28c85e_0", + "pixi 0.63.2 ha759004_0", + "typer-slim-standard 0.21.1 h378290b_0", + "libgomp 15.2.0 he0feb66_16", + "ca-certificates 2026.1.4 hbd8a1cb_0", + "semver 3.0.4 pyhcf101f3_1", + "spdlog 1.17.0 hab81395_1", + "pip 26.0 pyh8b19718_0", + "wheel 0.46.3 pyhd8ed1ab_0", + "openssl 3.6.1 h35e630c_1", + "jsonschema-specifications 2025.9.1 pyhcf101f3_0", + "bzip2 1.0.8 hda65f42_8", + "yaml 0.2.5 h280c20c_3", + "libmambapy 2.5.0 py312h1ca65c7_0", + "typer 0.21.1 pyhf8876ea_0", + "pytz 2025.2 pyhd8ed1ab_0", + "libuuid 2.41.3 h5347b49_0", + "xz-tools 5.8.2 hb03c661_0", + "jsonpointer 3.0.0 pyhcf101f3_3", + "libgcc 15.2.0 he0feb66_16", + "openjpeg 2.5.4 h55fea9a_0", + "libsqlite 3.51.2 hf4e2dac_0", + "boltons 25.0.0 pyhd8ed1ab_0", + "reproc 14.2.5.post0 hb9d3cd8_0", + "python_abi 3.12 8_cp312", + "libnghttp2 1.67.0 had1ee68_0", + "pysocks 1.7.1 pyha55dd90_7", + "pluggy 1.6.0 pyhf9edf01_1", + "platformdirs 4.5.1 pyhcf101f3_0", + "anaconda-client 1.14.1 pyhcf101f3_0", + "tk 8.6.13 noxft_h366c992_103", + "_openmp_mutex 4.5 2_gnu", + "pyjwt 2.11.0 pyhd8ed1ab_0", + "libnsl 2.0.1 hb9d3cd8_1", + "pycosat 0.6.6 py312h4c3975b_3", + "zstandard 0.25.0 py312h5253ce2_1", + "pkce 1.0.3 pyhd8ed1ab_1", + "conda-index 0.7.0 pyhd8ed1ab_0", + "msgpack-python 1.1.2 py312hd9148b4_1", + "icu 78.2 h33c6efd_0", + "cpp-expected 1.3.1 h171cf75_0", + "conda-libmamba-solver 25.11.0 pyhd8ed1ab_1", + "hpack 4.1.0 pyhd8ed1ab_0", + "typer-slim 0.21.1 pyhcf101f3_0", + "beautifulsoup4 4.14.3 pyha770c72_0", + "conda-package-streaming 0.12.0 pyhd8ed1ab_0", + "lz4-c 1.10.0 h5888daf_1", + "libmamba-spdlog 2.5.0 h12fcf84_0", + "libffi 3.5.2 h3435931_0", + "libxml2-16 2.15.1 hca6bf5a_1", + "brotli-python 1.2.0 py312hdb49522_1", + "setuptools 80.10.2 pyh332efcf_0", + "simdjson 4.2.4 hb700be7_0", + "rich 14.3.2 pyhcf101f3_0", + "attrs 25.4.0 pyhcf101f3_1", + "pycparser 2.22 pyh29332c3_1", + "libiconv 1.18 h3b78370_2", + "libssh2 1.11.1 hcf80075_0", + "menuinst 2.4.2 py312h7900ff3_0", + "typing-extensions 4.15.0 h396c80c_0", + "pillow 12.1.0 py312h50c33e8_0", + "tomlkit 0.14.0 pyha770c72_0", + "shellingham 1.5.4 pyhd8ed1ab_2", + "cryptography 46.0.4 py312ha4b625e_0", + "pydantic-core 2.41.5 py312h868fb18_1", + "click 8.3.1 pyh8f84b5b_1", + "mdurl 0.1.2 pyhd8ed1ab_1", + "jaraco.classes 3.4.0 pyhcf101f3_3", + "anaconda-cli-base 0.8.1 pyhcf101f3_0", + "pcre2 10.47 haa7fec5_0", + "certifi 2026.1.4 pyhd8ed1ab_0", + "pydantic 2.12.5 pyhcf101f3_1", + "pydantic-settings 2.12.0 pyh3cfb1c2_0", + "libexpat 2.7.3 hecca717_0", + "jaraco.functools 4.4.0 pyhcf101f3_1", + "nlohmann_json-abi 3.12.0 h0f90c79_1", + "conda-build 26.1.0 pyh31ec981_2", + "jinja2 3.1.6 pyhcf101f3_1", + "colorama 0.4.6 pyhd8ed1ab_1", + "liblzma 5.8.2 hb03c661_0", + "libsolv 0.7.35 h9463b59_0", + "tomli 2.4.0 pyhcf101f3_0", + "yaml-cpp 0.8.0 h59595ed_0", + "python 3.12.12 hd63d673_2_cpython", + "xz 5.8.2 ha02ee65_0", + "ruamel.yaml 0.18.17 py312h5253ce2_2", + "oniguruma 6.9.10 hb9d3cd8_0", + "jq 1.8.1 h73b1eb8_0", + "rattler-build 0.55.1 he64ecbb_1", + "conda-forge-ci-setup 4.24.1 py312hef7310e_100", + "conda-oci-mirror 0.2.3 pyhd8ed1ab_0", + "conda-forge-metadata 0.12.0 pyhcf101f3_1", + "wrapt 2.1.1 py312h4c3975b_0", + "oras-py 0.1.14 pyhd8ed1ab_0", + "conda-env 2.6.0 1", + "shyaml 0.6.2 pyhd3deb0d_0", + "deprecated 1.3.1 pyhd8ed1ab_1", + "rattler-build-conda-compat 1.4.10 pyhd8ed1ab_0", + "joblib 1.5.3 pyhd8ed1ab_0" + ], + "summary": "YAML parser and emitter for Python", + "tags": [] +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/files b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/files new file mode 100644 index 0000000000000000000000000000000000000000..e8dee1d19aa9e2e680e383db7d0fc265072e18a5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/files @@ -0,0 +1,26 @@ +site-packages/_yaml/__init__.py +site-packages/pyyaml-6.0.3.dist-info/INSTALLER +site-packages/pyyaml-6.0.3.dist-info/METADATA +site-packages/pyyaml-6.0.3.dist-info/RECORD +site-packages/pyyaml-6.0.3.dist-info/REQUESTED +site-packages/pyyaml-6.0.3.dist-info/WHEEL +site-packages/pyyaml-6.0.3.dist-info/direct_url.json +site-packages/pyyaml-6.0.3.dist-info/licenses/LICENSE +site-packages/pyyaml-6.0.3.dist-info/top_level.txt +site-packages/yaml/__init__.py +site-packages/yaml/composer.py +site-packages/yaml/constructor.py +site-packages/yaml/cyaml.py +site-packages/yaml/dumper.py +site-packages/yaml/emitter.py +site-packages/yaml/error.py +site-packages/yaml/events.py +site-packages/yaml/loader.py +site-packages/yaml/nodes.py +site-packages/yaml/parser.py +site-packages/yaml/reader.py +site-packages/yaml/representer.py +site-packages/yaml/resolver.py +site-packages/yaml/scanner.py +site-packages/yaml/serializer.py +site-packages/yaml/tokens.py diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/git b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/git new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/hash_input.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/hash_input.json new file mode 100644 index 0000000000000000000000000000000000000000..85b0622efefbd16720d306c74bf5d34fba0466a8 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/hash_input.json @@ -0,0 +1,9 @@ +{ + "target_platform": "linux-64", + "c_compiler": "gcc", + "channel_targets": "conda-forge main", + "c_stdlib_version": "2.17", + "c_compiler_version": "14", + "use_noarch": "true", + "c_stdlib": "sysroot" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/index.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/index.json new file mode 100644 index 0000000000000000000000000000000000000000..4840215b888736474bbef62a3f6d5c3a79c50eb1 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/index.json @@ -0,0 +1,18 @@ +{ + "arch": null, + "build": "pyh7db6752_1", + "build_number": 1, + "depends": [ + "python >=3.10.*", + "yaml" + ], + "license": "MIT", + "license_family": "MIT", + "name": "pyyaml", + "noarch": "python", + "platform": null, + "subdir": "noarch", + "timestamp": 1770223374054, + "track_features": "pyyaml_no_compile", + "version": "6.0.3" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..2f1b8e15e5627d92f0521605c9870bc8e5505cb4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/licenses/LICENSE @@ -0,0 +1,20 @@ +Copyright (c) 2017-2021 Ingy döt Net +Copyright (c) 2006-2016 Kirill Simonov + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/link.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/link.json new file mode 100644 index 0000000000000000000000000000000000000000..ec6589c68a1bf1aedb3f856ab584e80f5302f2cb --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/link.json @@ -0,0 +1,6 @@ +{ + "noarch": { + "type": "python" + }, + "package_metadata_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/paths.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/paths.json new file mode 100644 index 0000000000000000000000000000000000000000..f1c84598dba0958c052a0f534a8b76b7eb4b3015 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/paths.json @@ -0,0 +1,161 @@ +{ + "paths": [ + { + "_path": "site-packages/_yaml/__init__.py", + "path_type": "hardlink", + "sha256": "d3801eff9a2cc5a8692476b75c165401fe308ba5d7df6811f03e97ea9eb81840", + "size_in_bytes": 1402 + }, + { + "_path": "site-packages/pyyaml-6.0.3.dist-info/INSTALLER", + "path_type": "hardlink", + "sha256": "d0edee15f91b406f3f99726e44eb990be6e34fd0345b52b910c568e0eef6a2a8", + "size_in_bytes": 5 + }, + { + "_path": "site-packages/pyyaml-6.0.3.dist-info/METADATA", + "path_type": "hardlink", + "sha256": "03c3b415ed38d09faedc49360e930769b40c58f68585e6de00e2e4916a858d34", + "size_in_bytes": 2351 + }, + { + "_path": "site-packages/pyyaml-6.0.3.dist-info/RECORD", + "path_type": "hardlink", + "sha256": "6d73c5a80171b26a74d0abfe41333844b61cf24658b0d00e7a10e78888a5d80c", + "size_in_bytes": 2784 + }, + { + "_path": "site-packages/pyyaml-6.0.3.dist-info/REQUESTED", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pyyaml-6.0.3.dist-info/WHEEL", + "path_type": "hardlink", + "sha256": "c14c80f0e6ae95195b7f032d990b2f367806af140702f90a72f466762ce5262d", + "size_in_bytes": 92 + }, + { + "_path": "site-packages/pyyaml-6.0.3.dist-info/direct_url.json", + "path_type": "hardlink", + "sha256": "a42535d5b452e7531d13b6ab317c81f9ea83a4d26f513879506316b4a1f15158", + "size_in_bytes": 102 + }, + { + "_path": "site-packages/pyyaml-6.0.3.dist-info/licenses/LICENSE", + "path_type": "hardlink", + "sha256": "8d3928f9dc4490fd635707cb88eb26bd764102a7282954307d3e5167a577e8a4", + "size_in_bytes": 1101 + }, + { + "_path": "site-packages/pyyaml-6.0.3.dist-info/top_level.txt", + "path_type": "hardlink", + "sha256": "ae98f42153138ac02387fd6f1b709c7fdbf98e9090c00cfa703d48554e597614", + "size_in_bytes": 11 + }, + { + "_path": "site-packages/yaml/__init__.py", + "path_type": "hardlink", + "sha256": "b19dfcc333d6a75dfd73073901164507252f271b41d3b5f7d85510033a0547a7", + "size_in_bytes": 12311 + }, + { + "_path": "site-packages/yaml/composer.py", + "path_type": "hardlink", + "sha256": "fcaa37d16afa783594794a5ab94193dcb720f503c19ce3d59539c8311189f453", + "size_in_bytes": 4883 + }, + { + "_path": "site-packages/yaml/constructor.py", + "path_type": "hardlink", + "sha256": "90d8247da78b524c10618fd0e857f54f3d97570fe91b5c5513d024ef3faf88b0", + "size_in_bytes": 28639 + }, + { + "_path": "site-packages/yaml/cyaml.py", + "path_type": "hardlink", + "sha256": "e99ac01bd7c062f7557b614aff0d21997a06ed962ca185306a91bc0a20bbd87d", + "size_in_bytes": 3851 + }, + { + "_path": "site-packages/yaml/dumper.py", + "path_type": "hardlink", + "sha256": "3cb72d66563064ba7b5e679477046ebf89d8399d940670c8532f3e94a7cb17ea", + "size_in_bytes": 2837 + }, + { + "_path": "site-packages/yaml/emitter.py", + "path_type": "hardlink", + "sha256": "8e086d694ede170837d5b1b407b45979aff6f40762f422a65eafd08e04290a44", + "size_in_bytes": 43006 + }, + { + "_path": "site-packages/yaml/error.py", + "path_type": "hardlink", + "sha256": "021f73fada072546c4f63f8cf18a7181244ce4280b09cc15cc980b2d1176171a", + "size_in_bytes": 2533 + }, + { + "_path": "site-packages/yaml/events.py", + "path_type": "hardlink", + "sha256": "e74fd392c810884e2ea7e94aa3f57e9c1cbeb402319083d0c58e6a0e1282787c", + "size_in_bytes": 2445 + }, + { + "_path": "site-packages/yaml/loader.py", + "path_type": "hardlink", + "sha256": "5156becc8aa6905482218abf3e04869b835226db4763645fff3438fdbd5f1cdd", + "size_in_bytes": 2061 + }, + { + "_path": "site-packages/yaml/nodes.py", + "path_type": "hardlink", + "sha256": "80f28d8fca4a09d87677882bde021820d9cf39a3b11a12405226211919cf13ce", + "size_in_bytes": 1440 + }, + { + "_path": "site-packages/yaml/parser.py", + "path_type": "hardlink", + "sha256": "8a55a9e6fbe0a07146cef3990c8b45a068c3e83e369e1959ad9ca30306b4a09a", + "size_in_bytes": 25495 + }, + { + "_path": "site-packages/yaml/reader.py", + "path_type": "hardlink", + "sha256": "d1d9b38ab3a20c6e17a38d519ee412ecaf6b918df18c78956ac7c330d4ea08dc", + "size_in_bytes": 6794 + }, + { + "_path": "site-packages/yaml/representer.py", + "path_type": "hardlink", + "sha256": "22e58ff9c016f6c1ca1274b4802a926bcf78935060e1c813c5a0f021c6d143e6", + "size_in_bytes": 14190 + }, + { + "_path": "site-packages/yaml/resolver.py", + "path_type": "hardlink", + "sha256": "f4bf9561f9b89961f1503d558385fbae30d12bfed565de9bf76c33abb63620a6", + "size_in_bytes": 9004 + }, + { + "_path": "site-packages/yaml/scanner.py", + "path_type": "hardlink", + "sha256": "60433788b652690c17710460da5d91e0c753d3318fd85f5e1e42862a71f25906", + "size_in_bytes": 51279 + }, + { + "_path": "site-packages/yaml/serializer.py", + "path_type": "hardlink", + "sha256": "0a1b85826854d35863e31808f0668abfabdf33606e8f06bd8bb7761401e3edc0", + "size_in_bytes": 4165 + }, + { + "_path": "site-packages/yaml/tokens.py", + "path_type": "hardlink", + "sha256": "953408cd2570f0c83dc2fe39f7e4e388e41eeb05738aa69196a5f6ffcf6ba79e", + "size_in_bytes": 2573 + } + ], + "paths_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/0001-Ensure-we-do-not-end-up-wih-CRLF-line-endings-on-tes.patch b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/0001-Ensure-we-do-not-end-up-wih-CRLF-line-endings-on-tes.patch new file mode 100644 index 0000000000000000000000000000000000000000..7f1fafc010dce746112bf989447f5e249ab9605d --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/0001-Ensure-we-do-not-end-up-wih-CRLF-line-endings-on-tes.patch @@ -0,0 +1,22 @@ +From b261c4da11048dadb3c185e0e803e2b3e7cc2b40 Mon Sep 17 00:00:00 2001 +From: Ray Donnelly <mingw.android@gmail.com> +Date: Wed, 2 May 2018 03:32:40 -0700 +Subject: [PATCH] Ensure we do not end up wih CRLF line endings on tests + +--- + .gitattributes | 3 +++ + 1 file changed, 3 insertions(+) + create mode 100644 .gitattributes + +diff --git a/.gitattributes b/.gitattributes +new file mode 100644 +index 0000000..f363c35 +--- /dev/null ++++ b/.gitattributes +@@ -0,0 +1,3 @@ ++# These files are opened as 'rb' and ++# compared against files not written as 'wb ++tests/data/* -text +-- +2.16.2 + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/0002-remove-setuptools-use-distutils-py38.patch b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/0002-remove-setuptools-use-distutils-py38.patch new file mode 100644 index 0000000000000000000000000000000000000000..4a452cf6a030332d24ce5f84997348d70a85c7db --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/0002-remove-setuptools-use-distutils-py38.patch @@ -0,0 +1,11 @@ +--- setup.py.orig 2021-11-02 21:27:26.000000000 -0700 ++++ setup.py 2021-11-02 21:27:45.000000000 -0700 +@@ -66,8 +66,6 @@ + + import sys, os, os.path, pathlib, platform, shutil, tempfile, warnings + +-# for newer setuptools, enable the embedded distutils before importing setuptools/distutils to avoid warnings +-os.environ['SETUPTOOLS_USE_DISTUTILS'] = 'local' + + from setuptools import setup, Command, Distribution as _Distribution, Extension as _Extension + from setuptools.command.build_ext import build_ext as _build_ext diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/bld.bat b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/bld.bat new file mode 100644 index 0000000000000000000000000000000000000000..141d10176b4b41884558df5b74eaaf327d2c6249 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/bld.bat @@ -0,0 +1 @@ +%PYTHON% -m pip install . --no-deps --no-build-isolation -vv diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/build.sh b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/build.sh new file mode 100644 index 0000000000000000000000000000000000000000..2ea7f6ae3074afaa5b82b30b4022093f934c9468 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/build.sh @@ -0,0 +1,6 @@ +#!/bin/bash -eux + +if [[ "$use_noarch" == "true" ]]; then + export PYYAML_FORCE_LIBYAML=0 +fi +${PYTHON} -m pip install . --no-deps --no-build-isolation -vv diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/conda_build_config.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/conda_build_config.yaml new file mode 100644 index 0000000000000000000000000000000000000000..5654bdad1a749fa64af34bdc3136cb67ead64460 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/conda_build_config.yaml @@ -0,0 +1,36 @@ +CI: azure +c_compiler: gcc +c_compiler_version: '14' +c_stdlib: sysroot +c_stdlib_version: '2.17' +channel_sources: conda-forge +channel_targets: conda-forge main +cpu_optimization_target: nocona +cran_mirror: https://cran.r-project.org +cxx_compiler: gxx +docker_image: quay.io/condaforge/linux-anvil-x86_64:alma9 +extend_keys: +- ignore_version +- pin_run_as_build +- extend_keys +- ignore_build_only_deps +fortran_compiler: gfortran +ignore_build_only_deps: +- numpy +- python +lua: '5' +numpy: '1.26' +perl: 5.26.2 +pin_run_as_build: + python: + max_pin: x.x + min_pin: x.x + r-base: + max_pin: x.x + min_pin: x.x +python: 3.14.* *_cp314 +python_impl: cpython +python_min: '3.10' +r_base: '3.5' +target_platform: linux-64 +use_noarch: 'true' diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/meta.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/meta.yaml new file mode 100644 index 0000000000000000000000000000000000000000..ecc75803861209a93dfa49e14f3a388dc1216f66 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/meta.yaml @@ -0,0 +1,102 @@ +# This file created by conda-build 26.1.0 +# meta.yaml template originally from: +# /home/conda/recipe_root, last modified Wed Feb 4 16:39:33 2026 +# ------------------------------------------------ + +package: + name: pyyaml + version: 6.0.3 +source: + url: https://pypi.org/packages/source/P/PyYAML/pyyaml-6.0.3.tar.gz + sha256: d76623373421df22fb4cf8817020cbb7ef15c725b9d5e45f17e189bfc384190f + patches: + - 0001-Ensure-we-do-not-end-up-wih-CRLF-line-endings-on-tes.patch +build: + number: '1' + noarch: python + track_features: + - pyyaml_no_compile + string: pyh7db6752_1 +requirements: + build: + - _libgcc_mutex 0.1 conda_forge + - _openmp_mutex 4.5 2_gnu + - binutils_impl_linux-64 2.45 default_hfdba357_105 + - binutils_linux-64 2.45 default_h4852527_105 + - gcc_impl_linux-64 14.3.0 he8b2097_16 + - gcc_linux-64 14.3.0 h298d278_17 + - kernel-headers_linux-64 3.10.0 he073ed8_18 + - ld_impl_linux-64 2.45 default_hbd61a6d_105 + - libgcc 15.2.0 he0feb66_16 + - libgcc-devel_linux-64 14.3.0 hf649bbc_116 + - libgomp 15.2.0 he0feb66_16 + - libsanitizer 14.3.0 h8f1669f_16 + - libstdcxx 15.2.0 h934c35e_16 + - libstdcxx-devel_linux-64 14.3.0 h9f08a49_116 + - libzlib 1.3.1 hb9d3cd8_2 + - sysroot_linux-64 2.17 h0157908_18 + - tzdata 2025c hc9c84f9_1 + - zstd 1.5.7 hb78ec9c_6 + host: + - _libgcc_mutex 0.1 conda_forge + - _openmp_mutex 4.5 2_gnu + - bzip2 1.0.8 hda65f42_8 + - ca-certificates 2026.1.4 hbd8a1cb_0 + - cython 3.2.4 py310ha58568a_0 + - icu 78.2 h33c6efd_0 + - ld_impl_linux-64 2.45 default_hbd61a6d_105 + - libexpat 2.7.3 hecca717_0 + - libffi 3.5.2 h3435931_0 + - libgcc 15.2.0 he0feb66_16 + - libgcc-ng 15.2.0 h69a702a_16 + - libgomp 15.2.0 he0feb66_16 + - liblzma 5.8.2 hb03c661_0 + - libnsl 2.0.1 hb9d3cd8_1 + - libsqlite 3.51.2 hf4e2dac_0 + - libstdcxx 15.2.0 h934c35e_16 + - libuuid 2.41.3 h5347b49_0 + - libxcrypt 4.4.36 hd590300_1 + - libzlib 1.3.1 hb9d3cd8_2 + - ncurses 6.5 h2d0b736_3 + - openssl 3.6.1 h35e630c_1 + - packaging 26.0 pyhcf101f3_0 + - pip 26.0 pyh8b19718_0 + - python 3.10.19 h3c07f61_3_cpython + - python_abi 3.10 8_cp310 + - readline 8.3 h853b02a_0 + - setuptools 80.10.2 pyh332efcf_0 + - tk 8.6.13 noxft_h366c992_103 + - tzdata 2025c hc9c84f9_1 + - wheel 0.46.3 pyhd8ed1ab_0 + - yaml 0.2.5 h280c20c_3 + - zstd 1.5.7 hb78ec9c_6 + run: + - python >=3.10.* + - yaml +test: + imports: + - yaml + commands: + - pip check + requires: + - pip + - python 3.10.* +about: + home: http://pyyaml.org/wiki/PyYAML + license_file: LICENSE + license: MIT + license_family: MIT + summary: YAML parser and emitter for Python + dev_url: https://github.com/yaml/pyyaml + doc_url: http://pyyaml.org/wiki/PyYAML +extra: + recipe-maintainers: + - jakirkham + - msarahan + - ocefpaf + - pelson + final: true + copy_test_source_files: true + flow_run_id: azure_20260204.2.1 + remote_url: https://github.com/conda-forge/pyyaml-feedstock + sha: c1f16949f0edec6fd6bf694330bec45716aad0f2 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/meta.yaml.template b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/meta.yaml.template new file mode 100644 index 0000000000000000000000000000000000000000..b7e6415a4af3b62f797d381cd808753b8ee73bb0 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/meta.yaml.template @@ -0,0 +1,66 @@ +{% set version = "6.0.3" %} + +package: + name: pyyaml + version: {{ version }} + +source: + url: https://pypi.org/packages/source/P/PyYAML/pyyaml-{{ version }}.tar.gz + sha256: d76623373421df22fb4cf8817020cbb7ef15c725b9d5e45f17e189bfc384190f + patches: + - 0001-Ensure-we-do-not-end-up-wih-CRLF-line-endings-on-tes.patch + - 0002-remove-setuptools-use-distutils-py38.patch # [py<39] + +build: + number: 1 + skip: true # [py<38] + noarch: python # [use_noarch] + track_features: + - pyyaml_no_compile # [use_noarch] + +requirements: + build: + - python # [build_platform != target_platform] + - cross-python_{{ target_platform }} # [build_platform != target_platform] + - cython # [build_platform != target_platform] + - {{ compiler('c') }} + - {{ stdlib("c") }} + host: + - python # [not use_noarch] + - python {{ python_min }}.* # [use_noarch] + - cython + - setuptools + - packaging + - pip + - yaml + run: + - python # [not use_noarch] + - python >={{ python_min }}.* # [use_noarch] + - yaml + +test: + imports: + - yaml + - _yaml # [python_impl == "cpython" and not use_noarch] + commands: + # temporarily skipping pip check on win and pypy build because of bizarre tqdm issue + - pip check # [not (win and python_impl == 'pypy')] + requires: + - pip + - python {{ python_min }}.* # [use_noarch] + +about: + home: http://pyyaml.org/wiki/PyYAML + license_file: LICENSE + license: MIT + license_family: MIT + summary: YAML parser and emitter for Python + dev_url: https://github.com/yaml/pyyaml + doc_url: http://pyyaml.org/wiki/PyYAML + +extra: + recipe-maintainers: + - jakirkham + - msarahan + - pelson + - ocefpaf diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/recipe-scripts-license.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/recipe-scripts-license.txt new file mode 100644 index 0000000000000000000000000000000000000000..2ec51d75f362bc4327a3cfe1c515c16bb3c57367 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/recipe/recipe-scripts-license.txt @@ -0,0 +1,27 @@ +BSD-3-Clause license +Copyright (c) 2015-2022, conda-forge contributors +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + 3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/repodata_record.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/repodata_record.json new file mode 100644 index 0000000000000000000000000000000000000000..f51aaead421bd6e918ac0d289225d0cfb2a7fade --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/repodata_record.json @@ -0,0 +1,26 @@ +{ + "arch": null, + "build": "pyh7db6752_1", + "build_number": 1, + "build_string": "pyh7db6752_1", + "channel": "conda-forge", + "constrains": [], + "depends": [ + "python >=3.10.*", + "yaml" + ], + "fn": "pyyaml-6.0.3-pyh7db6752_1.conda", + "license": "MIT", + "license_family": "MIT", + "md5": "1fd14e3bb9bd8dac4caa30da123b8a93", + "name": "pyyaml", + "noarch": "python", + "platform": null, + "sha256": "5f938d208c284cc1f910fd84f2adffe59d01de73f62d8448ae311eb4f0340bd3", + "size": 45525, + "subdir": "noarch", + "timestamp": 1770223374, + "track_features": "pyyaml_no_compile", + "url": "https://conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1.conda", + "version": "6.0.3" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/test/run_test.bat b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/test/run_test.bat new file mode 100644 index 0000000000000000000000000000000000000000..cb57b389f7b557b090ed18f633bebfbc20c744e9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/test/run_test.bat @@ -0,0 +1,7 @@ + + +@echo on + +pip check +IF %ERRORLEVEL% NEQ 0 exit /B 1 +exit /B 0 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/test/run_test.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/test/run_test.py new file mode 100644 index 0000000000000000000000000000000000000000..2017d826dca78350092ab38bc23ce09471c59a8a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/test/run_test.py @@ -0,0 +1,3 @@ +print("import: 'yaml'") +import yaml + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/test/run_test.sh b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/test/run_test.sh new file mode 100644 index 0000000000000000000000000000000000000000..1afc6b862fab8658b14cb4cc0345a4ee1f02ad0e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/test/run_test.sh @@ -0,0 +1,8 @@ + + +set -ex + + + +pip check +exit 0 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/test/test_time_dependencies.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/test/test_time_dependencies.json new file mode 100644 index 0000000000000000000000000000000000000000..e892dccb7cc105ebabcddc33a9a4f2b8e1f9fa6d --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/info/test/test_time_dependencies.json @@ -0,0 +1 @@ +["python 3.10.*", "pip"] \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/_yaml/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/_yaml/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..7baa8c4b68127d5cdf0be9a799429e61347c2694 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/_yaml/__init__.py @@ -0,0 +1,33 @@ +# This is a stub package designed to roughly emulate the _yaml +# extension module, which previously existed as a standalone module +# and has been moved into the `yaml` package namespace. +# It does not perfectly mimic its old counterpart, but should get +# close enough for anyone who's relying on it even when they shouldn't. +import yaml + +# in some circumstances, the yaml module we imoprted may be from a different version, so we need +# to tread carefully when poking at it here (it may not have the attributes we expect) +if not getattr(yaml, '__with_libyaml__', False): + from sys import version_info + + exc = ModuleNotFoundError if version_info >= (3, 6) else ImportError + raise exc("No module named '_yaml'") +else: + from yaml._yaml import * + import warnings + warnings.warn( + 'The _yaml extension module is now located at yaml._yaml' + ' and its location is subject to change. To use the' + ' LibYAML-based parser and emitter, import from `yaml`:' + ' `from yaml import CLoader as Loader, CDumper as Dumper`.', + DeprecationWarning + ) + del warnings + # Don't `del yaml` here because yaml is actually an existing + # namespace member of _yaml. + +__name__ = '_yaml' +# If the module is top-level (i.e. not a part of any specific package) +# then the attribute should be set to ''. +# https://docs.python.org/3.8/library/types.html +__package__ = '' diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/INSTALLER b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/INSTALLER new file mode 100644 index 0000000000000000000000000000000000000000..f79e4cb9aaf0b2d9e8ba78861e2071317b2384b3 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/INSTALLER @@ -0,0 +1 @@ +conda \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/METADATA b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/METADATA new file mode 100644 index 0000000000000000000000000000000000000000..702ee6da5865b50b297705b077ea7d5904fead58 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/METADATA @@ -0,0 +1,59 @@ +Metadata-Version: 2.4 +Name: PyYAML +Version: 6.0.3 +Summary: YAML parser and emitter for Python +Home-page: https://pyyaml.org/ +Download-URL: https://pypi.org/project/PyYAML/ +Author: Kirill Simonov +Author-email: xi@resolvent.net +License: MIT +Project-URL: Bug Tracker, https://github.com/yaml/pyyaml/issues +Project-URL: CI, https://github.com/yaml/pyyaml/actions +Project-URL: Documentation, https://pyyaml.org/wiki/PyYAMLDocumentation +Project-URL: Mailing lists, http://lists.sourceforge.net/lists/listinfo/yaml-core +Project-URL: Source Code, https://github.com/yaml/pyyaml +Platform: Any +Classifier: Development Status :: 5 - Production/Stable +Classifier: Intended Audience :: Developers +Classifier: License :: OSI Approved :: MIT License +Classifier: Operating System :: OS Independent +Classifier: Programming Language :: Cython +Classifier: Programming Language :: Python +Classifier: Programming Language :: Python :: 3 +Classifier: Programming Language :: Python :: 3.8 +Classifier: Programming Language :: Python :: 3.9 +Classifier: Programming Language :: Python :: 3.10 +Classifier: Programming Language :: Python :: 3.11 +Classifier: Programming Language :: Python :: 3.12 +Classifier: Programming Language :: Python :: 3.13 +Classifier: Programming Language :: Python :: 3.14 +Classifier: Programming Language :: Python :: Implementation :: CPython +Classifier: Programming Language :: Python :: Implementation :: PyPy +Classifier: Topic :: Software Development :: Libraries :: Python Modules +Classifier: Topic :: Text Processing :: Markup +Requires-Python: >=3.8 +License-File: LICENSE +Dynamic: author +Dynamic: author-email +Dynamic: classifier +Dynamic: description +Dynamic: download-url +Dynamic: home-page +Dynamic: license +Dynamic: license-file +Dynamic: platform +Dynamic: project-url +Dynamic: requires-python +Dynamic: summary + +YAML is a data serialization format designed for human readability +and interaction with scripting languages. PyYAML is a YAML parser +and emitter for Python. + +PyYAML features a complete YAML 1.1 parser, Unicode support, pickle +support, capable extension API, and sensible error messages. PyYAML +supports standard YAML tags and provides Python-specific tags that +allow to represent an arbitrary Python object. + +PyYAML is applicable for a broad range of tasks from complex +configuration files to object serialization and persistence. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/RECORD b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/RECORD new file mode 100644 index 0000000000000000000000000000000000000000..8785c6a18172357a896f0f4a8125d230d2062d0d --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/RECORD @@ -0,0 +1,44 @@ +_yaml/__init__.py,sha256=04Ae_5osxahpJHa3XBZUAf4wi6XX32gR8D6X6p64GEA,1402 +_yaml/__pycache__/__init__.cpython-310.pyc,, +pyyaml-6.0.3.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +pyyaml-6.0.3.dist-info/METADATA,sha256=A8O0Fe040J-u3Ek2DpMHabQMWPaFhebeAOLkkWqFjTQ,2351 +pyyaml-6.0.3.dist-info/RECORD,, +pyyaml-6.0.3.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pyyaml-6.0.3.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92 +pyyaml-6.0.3.dist-info/direct_url.json,sha256=pCU11bRS51MdE7arMXyB-eqDpNJvUTh5UGMWtKHxUVg,102 +pyyaml-6.0.3.dist-info/licenses/LICENSE,sha256=jTko-dxEkP1jVwfLiOsmvXZBAqcoKVQwfT5RZ6V36KQ,1101 +pyyaml-6.0.3.dist-info/top_level.txt,sha256=rpj0IVMTisAjh_1vG3Ccf9v5jpCQwAz6cD1IVU5ZdhQ,11 +yaml/__init__.py,sha256=sZ38wzPWp139cwc5ARZFByUvJxtB07X32FUQAzoFR6c,12311 +yaml/__pycache__/__init__.cpython-310.pyc,, +yaml/__pycache__/composer.cpython-310.pyc,, +yaml/__pycache__/constructor.cpython-310.pyc,, +yaml/__pycache__/cyaml.cpython-310.pyc,, +yaml/__pycache__/dumper.cpython-310.pyc,, +yaml/__pycache__/emitter.cpython-310.pyc,, +yaml/__pycache__/error.cpython-310.pyc,, +yaml/__pycache__/events.cpython-310.pyc,, +yaml/__pycache__/loader.cpython-310.pyc,, +yaml/__pycache__/nodes.cpython-310.pyc,, +yaml/__pycache__/parser.cpython-310.pyc,, +yaml/__pycache__/reader.cpython-310.pyc,, +yaml/__pycache__/representer.cpython-310.pyc,, +yaml/__pycache__/resolver.cpython-310.pyc,, +yaml/__pycache__/scanner.cpython-310.pyc,, +yaml/__pycache__/serializer.cpython-310.pyc,, +yaml/__pycache__/tokens.cpython-310.pyc,, +yaml/composer.py,sha256=_Ko30Wr6eDWUeUpauUGT3Lcg9QPBnOPVlTnIMRGJ9FM,4883 +yaml/constructor.py,sha256=kNgkfaeLUkwQYY_Q6Ff1Tz2XVw_pG1xVE9Ak7z-viLA,28639 +yaml/cyaml.py,sha256=6ZrAG9fAYvdVe2FK_w0hmXoG7ZYsoYUwapG8CiC72H0,3851 +yaml/dumper.py,sha256=PLctZlYwZLp7XmeUdwRuv4nYOZ2UBnDIUy8-lKfLF-o,2837 +yaml/emitter.py,sha256=jghtaU7eFwg31bG0B7RZea_29Adi9CKmXq_QjgQpCkQ,43006 +yaml/error.py,sha256=Ah9z-toHJUbE9j-M8YpxgSRM5CgLCcwVzJgLLRF2Fxo,2533 +yaml/events.py,sha256=50_TksgQiE4up-lKo_V-nBy-tAIxkIPQxY5qDhKCeHw,2445 +yaml/loader.py,sha256=UVa-zIqmkFSCIYq_PgSGm4NSJttHY2Rf_zQ4_b1fHN0,2061 +yaml/nodes.py,sha256=gPKNj8pKCdh2d4gr3gIYINnPOaOxGhJAUiYhGRnPE84,1440 +yaml/parser.py,sha256=ilWp5vvgoHFGzvOZDItFoGjD6D42nhlZrZyjAwa0oJo,25495 +yaml/reader.py,sha256=0dmzirOiDG4Xo41RnuQS7K9rkY3xjHiVasfDMNTqCNw,6794 +yaml/representer.py,sha256=IuWP-cAW9sHKEnS0gCqSa894k1Bg4cgTxaDwIcbRQ-Y,14190 +yaml/resolver.py,sha256=9L-VYfm4mWHxUD1Vg4X7rjDRK_7VZd6b92wzq7Y2IKY,9004 +yaml/scanner.py,sha256=YEM3iLZSaQwXcQRg2l2R4MdT0zGP2F9eHkKGKnHyWQY,51279 +yaml/serializer.py,sha256=ChuFgmhU01hj4xgI8GaKv6vfM2Bujwa9i7d2FAHj7cA,4165 +yaml/tokens.py,sha256=lTQIzSVw8Mg9wv459-TjiOQe6wVziqaRlqX2_89rp54,2573 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/REQUESTED b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/REQUESTED new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/WHEEL b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/WHEEL new file mode 100644 index 0000000000000000000000000000000000000000..0885d055554a9bce53952482316a33cebf0845e4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/WHEEL @@ -0,0 +1,5 @@ +Wheel-Version: 1.0 +Generator: setuptools (80.10.2) +Root-Is-Purelib: true +Tag: py3-none-any + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/direct_url.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/direct_url.json new file mode 100644 index 0000000000000000000000000000000000000000..d5c560b6c6ec3bbe18856002ee218b30e159c1dc --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/direct_url.json @@ -0,0 +1 @@ +{"dir_info": {}, "url": "file:///home/conda/feedstock_root/build_artifacts/pyyaml_1770223233952/work"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..2f1b8e15e5627d92f0521605c9870bc8e5505cb4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/licenses/LICENSE @@ -0,0 +1,20 @@ +Copyright (c) 2017-2021 Ingy döt Net +Copyright (c) 2006-2016 Kirill Simonov + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/top_level.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/top_level.txt new file mode 100644 index 0000000000000000000000000000000000000000..e6475e911f628412049bc4090d86f23ac403adde --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/pyyaml-6.0.3.dist-info/top_level.txt @@ -0,0 +1,2 @@ +_yaml +yaml diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..d58f0891737def7f38e5d86dde2dbf9be0c13dce --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/__init__.py @@ -0,0 +1,390 @@ + +from .error import * + +from .tokens import * +from .events import * +from .nodes import * + +from .loader import * +from .dumper import * + +__version__ = '6.0.3' +try: + from .cyaml import * + __with_libyaml__ = True +except ImportError: + __with_libyaml__ = False + +import io + +#------------------------------------------------------------------------------ +# XXX "Warnings control" is now deprecated. Leaving in the API function to not +# break code that uses it. +#------------------------------------------------------------------------------ +def warnings(settings=None): + if settings is None: + return {} + +#------------------------------------------------------------------------------ +def scan(stream, Loader=Loader): + """ + Scan a YAML stream and produce scanning tokens. + """ + loader = Loader(stream) + try: + while loader.check_token(): + yield loader.get_token() + finally: + loader.dispose() + +def parse(stream, Loader=Loader): + """ + Parse a YAML stream and produce parsing events. + """ + loader = Loader(stream) + try: + while loader.check_event(): + yield loader.get_event() + finally: + loader.dispose() + +def compose(stream, Loader=Loader): + """ + Parse the first YAML document in a stream + and produce the corresponding representation tree. + """ + loader = Loader(stream) + try: + return loader.get_single_node() + finally: + loader.dispose() + +def compose_all(stream, Loader=Loader): + """ + Parse all YAML documents in a stream + and produce corresponding representation trees. + """ + loader = Loader(stream) + try: + while loader.check_node(): + yield loader.get_node() + finally: + loader.dispose() + +def load(stream, Loader): + """ + Parse the first YAML document in a stream + and produce the corresponding Python object. + """ + loader = Loader(stream) + try: + return loader.get_single_data() + finally: + loader.dispose() + +def load_all(stream, Loader): + """ + Parse all YAML documents in a stream + and produce corresponding Python objects. + """ + loader = Loader(stream) + try: + while loader.check_data(): + yield loader.get_data() + finally: + loader.dispose() + +def full_load(stream): + """ + Parse the first YAML document in a stream + and produce the corresponding Python object. + + Resolve all tags except those known to be + unsafe on untrusted input. + """ + return load(stream, FullLoader) + +def full_load_all(stream): + """ + Parse all YAML documents in a stream + and produce corresponding Python objects. + + Resolve all tags except those known to be + unsafe on untrusted input. + """ + return load_all(stream, FullLoader) + +def safe_load(stream): + """ + Parse the first YAML document in a stream + and produce the corresponding Python object. + + Resolve only basic YAML tags. This is known + to be safe for untrusted input. + """ + return load(stream, SafeLoader) + +def safe_load_all(stream): + """ + Parse all YAML documents in a stream + and produce corresponding Python objects. + + Resolve only basic YAML tags. This is known + to be safe for untrusted input. + """ + return load_all(stream, SafeLoader) + +def unsafe_load(stream): + """ + Parse the first YAML document in a stream + and produce the corresponding Python object. + + Resolve all tags, even those known to be + unsafe on untrusted input. + """ + return load(stream, UnsafeLoader) + +def unsafe_load_all(stream): + """ + Parse all YAML documents in a stream + and produce corresponding Python objects. + + Resolve all tags, even those known to be + unsafe on untrusted input. + """ + return load_all(stream, UnsafeLoader) + +def emit(events, stream=None, Dumper=Dumper, + canonical=None, indent=None, width=None, + allow_unicode=None, line_break=None): + """ + Emit YAML parsing events into a stream. + If stream is None, return the produced string instead. + """ + getvalue = None + if stream is None: + stream = io.StringIO() + getvalue = stream.getvalue + dumper = Dumper(stream, canonical=canonical, indent=indent, width=width, + allow_unicode=allow_unicode, line_break=line_break) + try: + for event in events: + dumper.emit(event) + finally: + dumper.dispose() + if getvalue: + return getvalue() + +def serialize_all(nodes, stream=None, Dumper=Dumper, + canonical=None, indent=None, width=None, + allow_unicode=None, line_break=None, + encoding=None, explicit_start=None, explicit_end=None, + version=None, tags=None): + """ + Serialize a sequence of representation trees into a YAML stream. + If stream is None, return the produced string instead. + """ + getvalue = None + if stream is None: + if encoding is None: + stream = io.StringIO() + else: + stream = io.BytesIO() + getvalue = stream.getvalue + dumper = Dumper(stream, canonical=canonical, indent=indent, width=width, + allow_unicode=allow_unicode, line_break=line_break, + encoding=encoding, version=version, tags=tags, + explicit_start=explicit_start, explicit_end=explicit_end) + try: + dumper.open() + for node in nodes: + dumper.serialize(node) + dumper.close() + finally: + dumper.dispose() + if getvalue: + return getvalue() + +def serialize(node, stream=None, Dumper=Dumper, **kwds): + """ + Serialize a representation tree into a YAML stream. + If stream is None, return the produced string instead. + """ + return serialize_all([node], stream, Dumper=Dumper, **kwds) + +def dump_all(documents, stream=None, Dumper=Dumper, + default_style=None, default_flow_style=False, + canonical=None, indent=None, width=None, + allow_unicode=None, line_break=None, + encoding=None, explicit_start=None, explicit_end=None, + version=None, tags=None, sort_keys=True): + """ + Serialize a sequence of Python objects into a YAML stream. + If stream is None, return the produced string instead. + """ + getvalue = None + if stream is None: + if encoding is None: + stream = io.StringIO() + else: + stream = io.BytesIO() + getvalue = stream.getvalue + dumper = Dumper(stream, default_style=default_style, + default_flow_style=default_flow_style, + canonical=canonical, indent=indent, width=width, + allow_unicode=allow_unicode, line_break=line_break, + encoding=encoding, version=version, tags=tags, + explicit_start=explicit_start, explicit_end=explicit_end, sort_keys=sort_keys) + try: + dumper.open() + for data in documents: + dumper.represent(data) + dumper.close() + finally: + dumper.dispose() + if getvalue: + return getvalue() + +def dump(data, stream=None, Dumper=Dumper, **kwds): + """ + Serialize a Python object into a YAML stream. + If stream is None, return the produced string instead. + """ + return dump_all([data], stream, Dumper=Dumper, **kwds) + +def safe_dump_all(documents, stream=None, **kwds): + """ + Serialize a sequence of Python objects into a YAML stream. + Produce only basic YAML tags. + If stream is None, return the produced string instead. + """ + return dump_all(documents, stream, Dumper=SafeDumper, **kwds) + +def safe_dump(data, stream=None, **kwds): + """ + Serialize a Python object into a YAML stream. + Produce only basic YAML tags. + If stream is None, return the produced string instead. + """ + return dump_all([data], stream, Dumper=SafeDumper, **kwds) + +def add_implicit_resolver(tag, regexp, first=None, + Loader=None, Dumper=Dumper): + """ + Add an implicit scalar detector. + If an implicit scalar value matches the given regexp, + the corresponding tag is assigned to the scalar. + first is a sequence of possible initial characters or None. + """ + if Loader is None: + loader.Loader.add_implicit_resolver(tag, regexp, first) + loader.FullLoader.add_implicit_resolver(tag, regexp, first) + loader.UnsafeLoader.add_implicit_resolver(tag, regexp, first) + else: + Loader.add_implicit_resolver(tag, regexp, first) + Dumper.add_implicit_resolver(tag, regexp, first) + +def add_path_resolver(tag, path, kind=None, Loader=None, Dumper=Dumper): + """ + Add a path based resolver for the given tag. + A path is a list of keys that forms a path + to a node in the representation tree. + Keys can be string values, integers, or None. + """ + if Loader is None: + loader.Loader.add_path_resolver(tag, path, kind) + loader.FullLoader.add_path_resolver(tag, path, kind) + loader.UnsafeLoader.add_path_resolver(tag, path, kind) + else: + Loader.add_path_resolver(tag, path, kind) + Dumper.add_path_resolver(tag, path, kind) + +def add_constructor(tag, constructor, Loader=None): + """ + Add a constructor for the given tag. + Constructor is a function that accepts a Loader instance + and a node object and produces the corresponding Python object. + """ + if Loader is None: + loader.Loader.add_constructor(tag, constructor) + loader.FullLoader.add_constructor(tag, constructor) + loader.UnsafeLoader.add_constructor(tag, constructor) + else: + Loader.add_constructor(tag, constructor) + +def add_multi_constructor(tag_prefix, multi_constructor, Loader=None): + """ + Add a multi-constructor for the given tag prefix. + Multi-constructor is called for a node if its tag starts with tag_prefix. + Multi-constructor accepts a Loader instance, a tag suffix, + and a node object and produces the corresponding Python object. + """ + if Loader is None: + loader.Loader.add_multi_constructor(tag_prefix, multi_constructor) + loader.FullLoader.add_multi_constructor(tag_prefix, multi_constructor) + loader.UnsafeLoader.add_multi_constructor(tag_prefix, multi_constructor) + else: + Loader.add_multi_constructor(tag_prefix, multi_constructor) + +def add_representer(data_type, representer, Dumper=Dumper): + """ + Add a representer for the given type. + Representer is a function accepting a Dumper instance + and an instance of the given data type + and producing the corresponding representation node. + """ + Dumper.add_representer(data_type, representer) + +def add_multi_representer(data_type, multi_representer, Dumper=Dumper): + """ + Add a representer for the given type. + Multi-representer is a function accepting a Dumper instance + and an instance of the given data type or subtype + and producing the corresponding representation node. + """ + Dumper.add_multi_representer(data_type, multi_representer) + +class YAMLObjectMetaclass(type): + """ + The metaclass for YAMLObject. + """ + def __init__(cls, name, bases, kwds): + super(YAMLObjectMetaclass, cls).__init__(name, bases, kwds) + if 'yaml_tag' in kwds and kwds['yaml_tag'] is not None: + if isinstance(cls.yaml_loader, list): + for loader in cls.yaml_loader: + loader.add_constructor(cls.yaml_tag, cls.from_yaml) + else: + cls.yaml_loader.add_constructor(cls.yaml_tag, cls.from_yaml) + + cls.yaml_dumper.add_representer(cls, cls.to_yaml) + +class YAMLObject(metaclass=YAMLObjectMetaclass): + """ + An object that can dump itself to a YAML stream + and load itself from a YAML stream. + """ + + __slots__ = () # no direct instantiation, so allow immutable subclasses + + yaml_loader = [Loader, FullLoader, UnsafeLoader] + yaml_dumper = Dumper + + yaml_tag = None + yaml_flow_style = None + + @classmethod + def from_yaml(cls, loader, node): + """ + Convert a representation node to a Python object. + """ + return loader.construct_yaml_object(node, cls) + + @classmethod + def to_yaml(cls, dumper, data): + """ + Convert a Python object to a representation node. + """ + return dumper.represent_yaml_object(cls.yaml_tag, data, cls, + flow_style=cls.yaml_flow_style) + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/composer.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/composer.py new file mode 100644 index 0000000000000000000000000000000000000000..6d15cb40e3b4198819c91c6f8d8b32807fcf53b2 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/composer.py @@ -0,0 +1,139 @@ + +__all__ = ['Composer', 'ComposerError'] + +from .error import MarkedYAMLError +from .events import * +from .nodes import * + +class ComposerError(MarkedYAMLError): + pass + +class Composer: + + def __init__(self): + self.anchors = {} + + def check_node(self): + # Drop the STREAM-START event. + if self.check_event(StreamStartEvent): + self.get_event() + + # If there are more documents available? + return not self.check_event(StreamEndEvent) + + def get_node(self): + # Get the root node of the next document. + if not self.check_event(StreamEndEvent): + return self.compose_document() + + def get_single_node(self): + # Drop the STREAM-START event. + self.get_event() + + # Compose a document if the stream is not empty. + document = None + if not self.check_event(StreamEndEvent): + document = self.compose_document() + + # Ensure that the stream contains no more documents. + if not self.check_event(StreamEndEvent): + event = self.get_event() + raise ComposerError("expected a single document in the stream", + document.start_mark, "but found another document", + event.start_mark) + + # Drop the STREAM-END event. + self.get_event() + + return document + + def compose_document(self): + # Drop the DOCUMENT-START event. + self.get_event() + + # Compose the root node. + node = self.compose_node(None, None) + + # Drop the DOCUMENT-END event. + self.get_event() + + self.anchors = {} + return node + + def compose_node(self, parent, index): + if self.check_event(AliasEvent): + event = self.get_event() + anchor = event.anchor + if anchor not in self.anchors: + raise ComposerError(None, None, "found undefined alias %r" + % anchor, event.start_mark) + return self.anchors[anchor] + event = self.peek_event() + anchor = event.anchor + if anchor is not None: + if anchor in self.anchors: + raise ComposerError("found duplicate anchor %r; first occurrence" + % anchor, self.anchors[anchor].start_mark, + "second occurrence", event.start_mark) + self.descend_resolver(parent, index) + if self.check_event(ScalarEvent): + node = self.compose_scalar_node(anchor) + elif self.check_event(SequenceStartEvent): + node = self.compose_sequence_node(anchor) + elif self.check_event(MappingStartEvent): + node = self.compose_mapping_node(anchor) + self.ascend_resolver() + return node + + def compose_scalar_node(self, anchor): + event = self.get_event() + tag = event.tag + if tag is None or tag == '!': + tag = self.resolve(ScalarNode, event.value, event.implicit) + node = ScalarNode(tag, event.value, + event.start_mark, event.end_mark, style=event.style) + if anchor is not None: + self.anchors[anchor] = node + return node + + def compose_sequence_node(self, anchor): + start_event = self.get_event() + tag = start_event.tag + if tag is None or tag == '!': + tag = self.resolve(SequenceNode, None, start_event.implicit) + node = SequenceNode(tag, [], + start_event.start_mark, None, + flow_style=start_event.flow_style) + if anchor is not None: + self.anchors[anchor] = node + index = 0 + while not self.check_event(SequenceEndEvent): + node.value.append(self.compose_node(node, index)) + index += 1 + end_event = self.get_event() + node.end_mark = end_event.end_mark + return node + + def compose_mapping_node(self, anchor): + start_event = self.get_event() + tag = start_event.tag + if tag is None or tag == '!': + tag = self.resolve(MappingNode, None, start_event.implicit) + node = MappingNode(tag, [], + start_event.start_mark, None, + flow_style=start_event.flow_style) + if anchor is not None: + self.anchors[anchor] = node + while not self.check_event(MappingEndEvent): + #key_event = self.peek_event() + item_key = self.compose_node(node, None) + #if item_key in node.value: + # raise ComposerError("while composing a mapping", start_event.start_mark, + # "found duplicate key", key_event.start_mark) + item_value = self.compose_node(node, item_key) + #node.value[item_key] = item_value + node.value.append((item_key, item_value)) + end_event = self.get_event() + node.end_mark = end_event.end_mark + return node + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/constructor.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/constructor.py new file mode 100644 index 0000000000000000000000000000000000000000..619acd3070a4845c653fcf22a626e05158035bc2 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/constructor.py @@ -0,0 +1,748 @@ + +__all__ = [ + 'BaseConstructor', + 'SafeConstructor', + 'FullConstructor', + 'UnsafeConstructor', + 'Constructor', + 'ConstructorError' +] + +from .error import * +from .nodes import * + +import collections.abc, datetime, base64, binascii, re, sys, types + +class ConstructorError(MarkedYAMLError): + pass + +class BaseConstructor: + + yaml_constructors = {} + yaml_multi_constructors = {} + + def __init__(self): + self.constructed_objects = {} + self.recursive_objects = {} + self.state_generators = [] + self.deep_construct = False + + def check_data(self): + # If there are more documents available? + return self.check_node() + + def check_state_key(self, key): + """Block special attributes/methods from being set in a newly created + object, to prevent user-controlled methods from being called during + deserialization""" + if self.get_state_keys_blacklist_regexp().match(key): + raise ConstructorError(None, None, + "blacklisted key '%s' in instance state found" % (key,), None) + + def get_data(self): + # Construct and return the next document. + if self.check_node(): + return self.construct_document(self.get_node()) + + def get_single_data(self): + # Ensure that the stream contains a single document and construct it. + node = self.get_single_node() + if node is not None: + return self.construct_document(node) + return None + + def construct_document(self, node): + data = self.construct_object(node) + while self.state_generators: + state_generators = self.state_generators + self.state_generators = [] + for generator in state_generators: + for dummy in generator: + pass + self.constructed_objects = {} + self.recursive_objects = {} + self.deep_construct = False + return data + + def construct_object(self, node, deep=False): + if node in self.constructed_objects: + return self.constructed_objects[node] + if deep: + old_deep = self.deep_construct + self.deep_construct = True + if node in self.recursive_objects: + raise ConstructorError(None, None, + "found unconstructable recursive node", node.start_mark) + self.recursive_objects[node] = None + constructor = None + tag_suffix = None + if node.tag in self.yaml_constructors: + constructor = self.yaml_constructors[node.tag] + else: + for tag_prefix in self.yaml_multi_constructors: + if tag_prefix is not None and node.tag.startswith(tag_prefix): + tag_suffix = node.tag[len(tag_prefix):] + constructor = self.yaml_multi_constructors[tag_prefix] + break + else: + if None in self.yaml_multi_constructors: + tag_suffix = node.tag + constructor = self.yaml_multi_constructors[None] + elif None in self.yaml_constructors: + constructor = self.yaml_constructors[None] + elif isinstance(node, ScalarNode): + constructor = self.__class__.construct_scalar + elif isinstance(node, SequenceNode): + constructor = self.__class__.construct_sequence + elif isinstance(node, MappingNode): + constructor = self.__class__.construct_mapping + if tag_suffix is None: + data = constructor(self, node) + else: + data = constructor(self, tag_suffix, node) + if isinstance(data, types.GeneratorType): + generator = data + data = next(generator) + if self.deep_construct: + for dummy in generator: + pass + else: + self.state_generators.append(generator) + self.constructed_objects[node] = data + del self.recursive_objects[node] + if deep: + self.deep_construct = old_deep + return data + + def construct_scalar(self, node): + if not isinstance(node, ScalarNode): + raise ConstructorError(None, None, + "expected a scalar node, but found %s" % node.id, + node.start_mark) + return node.value + + def construct_sequence(self, node, deep=False): + if not isinstance(node, SequenceNode): + raise ConstructorError(None, None, + "expected a sequence node, but found %s" % node.id, + node.start_mark) + return [self.construct_object(child, deep=deep) + for child in node.value] + + def construct_mapping(self, node, deep=False): + if not isinstance(node, MappingNode): + raise ConstructorError(None, None, + "expected a mapping node, but found %s" % node.id, + node.start_mark) + mapping = {} + for key_node, value_node in node.value: + key = self.construct_object(key_node, deep=deep) + if not isinstance(key, collections.abc.Hashable): + raise ConstructorError("while constructing a mapping", node.start_mark, + "found unhashable key", key_node.start_mark) + value = self.construct_object(value_node, deep=deep) + mapping[key] = value + return mapping + + def construct_pairs(self, node, deep=False): + if not isinstance(node, MappingNode): + raise ConstructorError(None, None, + "expected a mapping node, but found %s" % node.id, + node.start_mark) + pairs = [] + for key_node, value_node in node.value: + key = self.construct_object(key_node, deep=deep) + value = self.construct_object(value_node, deep=deep) + pairs.append((key, value)) + return pairs + + @classmethod + def add_constructor(cls, tag, constructor): + if not 'yaml_constructors' in cls.__dict__: + cls.yaml_constructors = cls.yaml_constructors.copy() + cls.yaml_constructors[tag] = constructor + + @classmethod + def add_multi_constructor(cls, tag_prefix, multi_constructor): + if not 'yaml_multi_constructors' in cls.__dict__: + cls.yaml_multi_constructors = cls.yaml_multi_constructors.copy() + cls.yaml_multi_constructors[tag_prefix] = multi_constructor + +class SafeConstructor(BaseConstructor): + + def construct_scalar(self, node): + if isinstance(node, MappingNode): + for key_node, value_node in node.value: + if key_node.tag == 'tag:yaml.org,2002:value': + return self.construct_scalar(value_node) + return super().construct_scalar(node) + + def flatten_mapping(self, node): + merge = [] + index = 0 + while index < len(node.value): + key_node, value_node = node.value[index] + if key_node.tag == 'tag:yaml.org,2002:merge': + del node.value[index] + if isinstance(value_node, MappingNode): + self.flatten_mapping(value_node) + merge.extend(value_node.value) + elif isinstance(value_node, SequenceNode): + submerge = [] + for subnode in value_node.value: + if not isinstance(subnode, MappingNode): + raise ConstructorError("while constructing a mapping", + node.start_mark, + "expected a mapping for merging, but found %s" + % subnode.id, subnode.start_mark) + self.flatten_mapping(subnode) + submerge.append(subnode.value) + submerge.reverse() + for value in submerge: + merge.extend(value) + else: + raise ConstructorError("while constructing a mapping", node.start_mark, + "expected a mapping or list of mappings for merging, but found %s" + % value_node.id, value_node.start_mark) + elif key_node.tag == 'tag:yaml.org,2002:value': + key_node.tag = 'tag:yaml.org,2002:str' + index += 1 + else: + index += 1 + if merge: + node.value = merge + node.value + + def construct_mapping(self, node, deep=False): + if isinstance(node, MappingNode): + self.flatten_mapping(node) + return super().construct_mapping(node, deep=deep) + + def construct_yaml_null(self, node): + self.construct_scalar(node) + return None + + bool_values = { + 'yes': True, + 'no': False, + 'true': True, + 'false': False, + 'on': True, + 'off': False, + } + + def construct_yaml_bool(self, node): + value = self.construct_scalar(node) + return self.bool_values[value.lower()] + + def construct_yaml_int(self, node): + value = self.construct_scalar(node) + value = value.replace('_', '') + sign = +1 + if value[0] == '-': + sign = -1 + if value[0] in '+-': + value = value[1:] + if value == '0': + return 0 + elif value.startswith('0b'): + return sign*int(value[2:], 2) + elif value.startswith('0x'): + return sign*int(value[2:], 16) + elif value[0] == '0': + return sign*int(value, 8) + elif ':' in value: + digits = [int(part) for part in value.split(':')] + digits.reverse() + base = 1 + value = 0 + for digit in digits: + value += digit*base + base *= 60 + return sign*value + else: + return sign*int(value) + + inf_value = 1e300 + while inf_value != inf_value*inf_value: + inf_value *= inf_value + nan_value = -inf_value/inf_value # Trying to make a quiet NaN (like C99). + + def construct_yaml_float(self, node): + value = self.construct_scalar(node) + value = value.replace('_', '').lower() + sign = +1 + if value[0] == '-': + sign = -1 + if value[0] in '+-': + value = value[1:] + if value == '.inf': + return sign*self.inf_value + elif value == '.nan': + return self.nan_value + elif ':' in value: + digits = [float(part) for part in value.split(':')] + digits.reverse() + base = 1 + value = 0.0 + for digit in digits: + value += digit*base + base *= 60 + return sign*value + else: + return sign*float(value) + + def construct_yaml_binary(self, node): + try: + value = self.construct_scalar(node).encode('ascii') + except UnicodeEncodeError as exc: + raise ConstructorError(None, None, + "failed to convert base64 data into ascii: %s" % exc, + node.start_mark) + try: + if hasattr(base64, 'decodebytes'): + return base64.decodebytes(value) + else: + return base64.decodestring(value) + except binascii.Error as exc: + raise ConstructorError(None, None, + "failed to decode base64 data: %s" % exc, node.start_mark) + + timestamp_regexp = re.compile( + r'''^(?P<year>[0-9][0-9][0-9][0-9]) + -(?P<month>[0-9][0-9]?) + -(?P<day>[0-9][0-9]?) + (?:(?:[Tt]|[ \t]+) + (?P<hour>[0-9][0-9]?) + :(?P<minute>[0-9][0-9]) + :(?P<second>[0-9][0-9]) + (?:\.(?P<fraction>[0-9]*))? + (?:[ \t]*(?P<tz>Z|(?P<tz_sign>[-+])(?P<tz_hour>[0-9][0-9]?) + (?::(?P<tz_minute>[0-9][0-9]))?))?)?$''', re.X) + + def construct_yaml_timestamp(self, node): + value = self.construct_scalar(node) + match = self.timestamp_regexp.match(node.value) + values = match.groupdict() + year = int(values['year']) + month = int(values['month']) + day = int(values['day']) + if not values['hour']: + return datetime.date(year, month, day) + hour = int(values['hour']) + minute = int(values['minute']) + second = int(values['second']) + fraction = 0 + tzinfo = None + if values['fraction']: + fraction = values['fraction'][:6] + while len(fraction) < 6: + fraction += '0' + fraction = int(fraction) + if values['tz_sign']: + tz_hour = int(values['tz_hour']) + tz_minute = int(values['tz_minute'] or 0) + delta = datetime.timedelta(hours=tz_hour, minutes=tz_minute) + if values['tz_sign'] == '-': + delta = -delta + tzinfo = datetime.timezone(delta) + elif values['tz']: + tzinfo = datetime.timezone.utc + return datetime.datetime(year, month, day, hour, minute, second, fraction, + tzinfo=tzinfo) + + def construct_yaml_omap(self, node): + # Note: we do not check for duplicate keys, because it's too + # CPU-expensive. + omap = [] + yield omap + if not isinstance(node, SequenceNode): + raise ConstructorError("while constructing an ordered map", node.start_mark, + "expected a sequence, but found %s" % node.id, node.start_mark) + for subnode in node.value: + if not isinstance(subnode, MappingNode): + raise ConstructorError("while constructing an ordered map", node.start_mark, + "expected a mapping of length 1, but found %s" % subnode.id, + subnode.start_mark) + if len(subnode.value) != 1: + raise ConstructorError("while constructing an ordered map", node.start_mark, + "expected a single mapping item, but found %d items" % len(subnode.value), + subnode.start_mark) + key_node, value_node = subnode.value[0] + key = self.construct_object(key_node) + value = self.construct_object(value_node) + omap.append((key, value)) + + def construct_yaml_pairs(self, node): + # Note: the same code as `construct_yaml_omap`. + pairs = [] + yield pairs + if not isinstance(node, SequenceNode): + raise ConstructorError("while constructing pairs", node.start_mark, + "expected a sequence, but found %s" % node.id, node.start_mark) + for subnode in node.value: + if not isinstance(subnode, MappingNode): + raise ConstructorError("while constructing pairs", node.start_mark, + "expected a mapping of length 1, but found %s" % subnode.id, + subnode.start_mark) + if len(subnode.value) != 1: + raise ConstructorError("while constructing pairs", node.start_mark, + "expected a single mapping item, but found %d items" % len(subnode.value), + subnode.start_mark) + key_node, value_node = subnode.value[0] + key = self.construct_object(key_node) + value = self.construct_object(value_node) + pairs.append((key, value)) + + def construct_yaml_set(self, node): + data = set() + yield data + value = self.construct_mapping(node) + data.update(value) + + def construct_yaml_str(self, node): + return self.construct_scalar(node) + + def construct_yaml_seq(self, node): + data = [] + yield data + data.extend(self.construct_sequence(node)) + + def construct_yaml_map(self, node): + data = {} + yield data + value = self.construct_mapping(node) + data.update(value) + + def construct_yaml_object(self, node, cls): + data = cls.__new__(cls) + yield data + if hasattr(data, '__setstate__'): + state = self.construct_mapping(node, deep=True) + data.__setstate__(state) + else: + state = self.construct_mapping(node) + data.__dict__.update(state) + + def construct_undefined(self, node): + raise ConstructorError(None, None, + "could not determine a constructor for the tag %r" % node.tag, + node.start_mark) + +SafeConstructor.add_constructor( + 'tag:yaml.org,2002:null', + SafeConstructor.construct_yaml_null) + +SafeConstructor.add_constructor( + 'tag:yaml.org,2002:bool', + SafeConstructor.construct_yaml_bool) + +SafeConstructor.add_constructor( + 'tag:yaml.org,2002:int', + SafeConstructor.construct_yaml_int) + +SafeConstructor.add_constructor( + 'tag:yaml.org,2002:float', + SafeConstructor.construct_yaml_float) + +SafeConstructor.add_constructor( + 'tag:yaml.org,2002:binary', + SafeConstructor.construct_yaml_binary) + +SafeConstructor.add_constructor( + 'tag:yaml.org,2002:timestamp', + SafeConstructor.construct_yaml_timestamp) + +SafeConstructor.add_constructor( + 'tag:yaml.org,2002:omap', + SafeConstructor.construct_yaml_omap) + +SafeConstructor.add_constructor( + 'tag:yaml.org,2002:pairs', + SafeConstructor.construct_yaml_pairs) + +SafeConstructor.add_constructor( + 'tag:yaml.org,2002:set', + SafeConstructor.construct_yaml_set) + +SafeConstructor.add_constructor( + 'tag:yaml.org,2002:str', + SafeConstructor.construct_yaml_str) + +SafeConstructor.add_constructor( + 'tag:yaml.org,2002:seq', + SafeConstructor.construct_yaml_seq) + +SafeConstructor.add_constructor( + 'tag:yaml.org,2002:map', + SafeConstructor.construct_yaml_map) + +SafeConstructor.add_constructor(None, + SafeConstructor.construct_undefined) + +class FullConstructor(SafeConstructor): + # 'extend' is blacklisted because it is used by + # construct_python_object_apply to add `listitems` to a newly generate + # python instance + def get_state_keys_blacklist(self): + return ['^extend$', '^__.*__$'] + + def get_state_keys_blacklist_regexp(self): + if not hasattr(self, 'state_keys_blacklist_regexp'): + self.state_keys_blacklist_regexp = re.compile('(' + '|'.join(self.get_state_keys_blacklist()) + ')') + return self.state_keys_blacklist_regexp + + def construct_python_str(self, node): + return self.construct_scalar(node) + + def construct_python_unicode(self, node): + return self.construct_scalar(node) + + def construct_python_bytes(self, node): + try: + value = self.construct_scalar(node).encode('ascii') + except UnicodeEncodeError as exc: + raise ConstructorError(None, None, + "failed to convert base64 data into ascii: %s" % exc, + node.start_mark) + try: + if hasattr(base64, 'decodebytes'): + return base64.decodebytes(value) + else: + return base64.decodestring(value) + except binascii.Error as exc: + raise ConstructorError(None, None, + "failed to decode base64 data: %s" % exc, node.start_mark) + + def construct_python_long(self, node): + return self.construct_yaml_int(node) + + def construct_python_complex(self, node): + return complex(self.construct_scalar(node)) + + def construct_python_tuple(self, node): + return tuple(self.construct_sequence(node)) + + def find_python_module(self, name, mark, unsafe=False): + if not name: + raise ConstructorError("while constructing a Python module", mark, + "expected non-empty name appended to the tag", mark) + if unsafe: + try: + __import__(name) + except ImportError as exc: + raise ConstructorError("while constructing a Python module", mark, + "cannot find module %r (%s)" % (name, exc), mark) + if name not in sys.modules: + raise ConstructorError("while constructing a Python module", mark, + "module %r is not imported" % name, mark) + return sys.modules[name] + + def find_python_name(self, name, mark, unsafe=False): + if not name: + raise ConstructorError("while constructing a Python object", mark, + "expected non-empty name appended to the tag", mark) + if '.' in name: + module_name, object_name = name.rsplit('.', 1) + else: + module_name = 'builtins' + object_name = name + if unsafe: + try: + __import__(module_name) + except ImportError as exc: + raise ConstructorError("while constructing a Python object", mark, + "cannot find module %r (%s)" % (module_name, exc), mark) + if module_name not in sys.modules: + raise ConstructorError("while constructing a Python object", mark, + "module %r is not imported" % module_name, mark) + module = sys.modules[module_name] + if not hasattr(module, object_name): + raise ConstructorError("while constructing a Python object", mark, + "cannot find %r in the module %r" + % (object_name, module.__name__), mark) + return getattr(module, object_name) + + def construct_python_name(self, suffix, node): + value = self.construct_scalar(node) + if value: + raise ConstructorError("while constructing a Python name", node.start_mark, + "expected the empty value, but found %r" % value, node.start_mark) + return self.find_python_name(suffix, node.start_mark) + + def construct_python_module(self, suffix, node): + value = self.construct_scalar(node) + if value: + raise ConstructorError("while constructing a Python module", node.start_mark, + "expected the empty value, but found %r" % value, node.start_mark) + return self.find_python_module(suffix, node.start_mark) + + def make_python_instance(self, suffix, node, + args=None, kwds=None, newobj=False, unsafe=False): + if not args: + args = [] + if not kwds: + kwds = {} + cls = self.find_python_name(suffix, node.start_mark) + if not (unsafe or isinstance(cls, type)): + raise ConstructorError("while constructing a Python instance", node.start_mark, + "expected a class, but found %r" % type(cls), + node.start_mark) + if newobj and isinstance(cls, type): + return cls.__new__(cls, *args, **kwds) + else: + return cls(*args, **kwds) + + def set_python_instance_state(self, instance, state, unsafe=False): + if hasattr(instance, '__setstate__'): + instance.__setstate__(state) + else: + slotstate = {} + if isinstance(state, tuple) and len(state) == 2: + state, slotstate = state + if hasattr(instance, '__dict__'): + if not unsafe and state: + for key in state.keys(): + self.check_state_key(key) + instance.__dict__.update(state) + elif state: + slotstate.update(state) + for key, value in slotstate.items(): + if not unsafe: + self.check_state_key(key) + setattr(instance, key, value) + + def construct_python_object(self, suffix, node): + # Format: + # !!python/object:module.name { ... state ... } + instance = self.make_python_instance(suffix, node, newobj=True) + yield instance + deep = hasattr(instance, '__setstate__') + state = self.construct_mapping(node, deep=deep) + self.set_python_instance_state(instance, state) + + def construct_python_object_apply(self, suffix, node, newobj=False): + # Format: + # !!python/object/apply # (or !!python/object/new) + # args: [ ... arguments ... ] + # kwds: { ... keywords ... } + # state: ... state ... + # listitems: [ ... listitems ... ] + # dictitems: { ... dictitems ... } + # or short format: + # !!python/object/apply [ ... arguments ... ] + # The difference between !!python/object/apply and !!python/object/new + # is how an object is created, check make_python_instance for details. + if isinstance(node, SequenceNode): + args = self.construct_sequence(node, deep=True) + kwds = {} + state = {} + listitems = [] + dictitems = {} + else: + value = self.construct_mapping(node, deep=True) + args = value.get('args', []) + kwds = value.get('kwds', {}) + state = value.get('state', {}) + listitems = value.get('listitems', []) + dictitems = value.get('dictitems', {}) + instance = self.make_python_instance(suffix, node, args, kwds, newobj) + if state: + self.set_python_instance_state(instance, state) + if listitems: + instance.extend(listitems) + if dictitems: + for key in dictitems: + instance[key] = dictitems[key] + return instance + + def construct_python_object_new(self, suffix, node): + return self.construct_python_object_apply(suffix, node, newobj=True) + +FullConstructor.add_constructor( + 'tag:yaml.org,2002:python/none', + FullConstructor.construct_yaml_null) + +FullConstructor.add_constructor( + 'tag:yaml.org,2002:python/bool', + FullConstructor.construct_yaml_bool) + +FullConstructor.add_constructor( + 'tag:yaml.org,2002:python/str', + FullConstructor.construct_python_str) + +FullConstructor.add_constructor( + 'tag:yaml.org,2002:python/unicode', + FullConstructor.construct_python_unicode) + +FullConstructor.add_constructor( + 'tag:yaml.org,2002:python/bytes', + FullConstructor.construct_python_bytes) + +FullConstructor.add_constructor( + 'tag:yaml.org,2002:python/int', + FullConstructor.construct_yaml_int) + +FullConstructor.add_constructor( + 'tag:yaml.org,2002:python/long', + FullConstructor.construct_python_long) + +FullConstructor.add_constructor( + 'tag:yaml.org,2002:python/float', + FullConstructor.construct_yaml_float) + +FullConstructor.add_constructor( + 'tag:yaml.org,2002:python/complex', + FullConstructor.construct_python_complex) + +FullConstructor.add_constructor( + 'tag:yaml.org,2002:python/list', + FullConstructor.construct_yaml_seq) + +FullConstructor.add_constructor( + 'tag:yaml.org,2002:python/tuple', + FullConstructor.construct_python_tuple) + +FullConstructor.add_constructor( + 'tag:yaml.org,2002:python/dict', + FullConstructor.construct_yaml_map) + +FullConstructor.add_multi_constructor( + 'tag:yaml.org,2002:python/name:', + FullConstructor.construct_python_name) + +class UnsafeConstructor(FullConstructor): + + def find_python_module(self, name, mark): + return super(UnsafeConstructor, self).find_python_module(name, mark, unsafe=True) + + def find_python_name(self, name, mark): + return super(UnsafeConstructor, self).find_python_name(name, mark, unsafe=True) + + def make_python_instance(self, suffix, node, args=None, kwds=None, newobj=False): + return super(UnsafeConstructor, self).make_python_instance( + suffix, node, args, kwds, newobj, unsafe=True) + + def set_python_instance_state(self, instance, state): + return super(UnsafeConstructor, self).set_python_instance_state( + instance, state, unsafe=True) + +UnsafeConstructor.add_multi_constructor( + 'tag:yaml.org,2002:python/module:', + UnsafeConstructor.construct_python_module) + +UnsafeConstructor.add_multi_constructor( + 'tag:yaml.org,2002:python/object:', + UnsafeConstructor.construct_python_object) + +UnsafeConstructor.add_multi_constructor( + 'tag:yaml.org,2002:python/object/new:', + UnsafeConstructor.construct_python_object_new) + +UnsafeConstructor.add_multi_constructor( + 'tag:yaml.org,2002:python/object/apply:', + UnsafeConstructor.construct_python_object_apply) + +# Constructor is same as UnsafeConstructor. Need to leave this in place in case +# people have extended it directly. +class Constructor(UnsafeConstructor): + pass diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/cyaml.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/cyaml.py new file mode 100644 index 0000000000000000000000000000000000000000..0c21345879b298bb8668201bebe7d289586b17f9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/cyaml.py @@ -0,0 +1,101 @@ + +__all__ = [ + 'CBaseLoader', 'CSafeLoader', 'CFullLoader', 'CUnsafeLoader', 'CLoader', + 'CBaseDumper', 'CSafeDumper', 'CDumper' +] + +from yaml._yaml import CParser, CEmitter + +from .constructor import * + +from .serializer import * +from .representer import * + +from .resolver import * + +class CBaseLoader(CParser, BaseConstructor, BaseResolver): + + def __init__(self, stream): + CParser.__init__(self, stream) + BaseConstructor.__init__(self) + BaseResolver.__init__(self) + +class CSafeLoader(CParser, SafeConstructor, Resolver): + + def __init__(self, stream): + CParser.__init__(self, stream) + SafeConstructor.__init__(self) + Resolver.__init__(self) + +class CFullLoader(CParser, FullConstructor, Resolver): + + def __init__(self, stream): + CParser.__init__(self, stream) + FullConstructor.__init__(self) + Resolver.__init__(self) + +class CUnsafeLoader(CParser, UnsafeConstructor, Resolver): + + def __init__(self, stream): + CParser.__init__(self, stream) + UnsafeConstructor.__init__(self) + Resolver.__init__(self) + +class CLoader(CParser, Constructor, Resolver): + + def __init__(self, stream): + CParser.__init__(self, stream) + Constructor.__init__(self) + Resolver.__init__(self) + +class CBaseDumper(CEmitter, BaseRepresenter, BaseResolver): + + def __init__(self, stream, + default_style=None, default_flow_style=False, + canonical=None, indent=None, width=None, + allow_unicode=None, line_break=None, + encoding=None, explicit_start=None, explicit_end=None, + version=None, tags=None, sort_keys=True): + CEmitter.__init__(self, stream, canonical=canonical, + indent=indent, width=width, encoding=encoding, + allow_unicode=allow_unicode, line_break=line_break, + explicit_start=explicit_start, explicit_end=explicit_end, + version=version, tags=tags) + Representer.__init__(self, default_style=default_style, + default_flow_style=default_flow_style, sort_keys=sort_keys) + Resolver.__init__(self) + +class CSafeDumper(CEmitter, SafeRepresenter, Resolver): + + def __init__(self, stream, + default_style=None, default_flow_style=False, + canonical=None, indent=None, width=None, + allow_unicode=None, line_break=None, + encoding=None, explicit_start=None, explicit_end=None, + version=None, tags=None, sort_keys=True): + CEmitter.__init__(self, stream, canonical=canonical, + indent=indent, width=width, encoding=encoding, + allow_unicode=allow_unicode, line_break=line_break, + explicit_start=explicit_start, explicit_end=explicit_end, + version=version, tags=tags) + SafeRepresenter.__init__(self, default_style=default_style, + default_flow_style=default_flow_style, sort_keys=sort_keys) + Resolver.__init__(self) + +class CDumper(CEmitter, Serializer, Representer, Resolver): + + def __init__(self, stream, + default_style=None, default_flow_style=False, + canonical=None, indent=None, width=None, + allow_unicode=None, line_break=None, + encoding=None, explicit_start=None, explicit_end=None, + version=None, tags=None, sort_keys=True): + CEmitter.__init__(self, stream, canonical=canonical, + indent=indent, width=width, encoding=encoding, + allow_unicode=allow_unicode, line_break=line_break, + explicit_start=explicit_start, explicit_end=explicit_end, + version=version, tags=tags) + Representer.__init__(self, default_style=default_style, + default_flow_style=default_flow_style, sort_keys=sort_keys) + Resolver.__init__(self) + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/dumper.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/dumper.py new file mode 100644 index 0000000000000000000000000000000000000000..6aadba551f3836b02f4752277f4b3027073defad --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/dumper.py @@ -0,0 +1,62 @@ + +__all__ = ['BaseDumper', 'SafeDumper', 'Dumper'] + +from .emitter import * +from .serializer import * +from .representer import * +from .resolver import * + +class BaseDumper(Emitter, Serializer, BaseRepresenter, BaseResolver): + + def __init__(self, stream, + default_style=None, default_flow_style=False, + canonical=None, indent=None, width=None, + allow_unicode=None, line_break=None, + encoding=None, explicit_start=None, explicit_end=None, + version=None, tags=None, sort_keys=True): + Emitter.__init__(self, stream, canonical=canonical, + indent=indent, width=width, + allow_unicode=allow_unicode, line_break=line_break) + Serializer.__init__(self, encoding=encoding, + explicit_start=explicit_start, explicit_end=explicit_end, + version=version, tags=tags) + Representer.__init__(self, default_style=default_style, + default_flow_style=default_flow_style, sort_keys=sort_keys) + Resolver.__init__(self) + +class SafeDumper(Emitter, Serializer, SafeRepresenter, Resolver): + + def __init__(self, stream, + default_style=None, default_flow_style=False, + canonical=None, indent=None, width=None, + allow_unicode=None, line_break=None, + encoding=None, explicit_start=None, explicit_end=None, + version=None, tags=None, sort_keys=True): + Emitter.__init__(self, stream, canonical=canonical, + indent=indent, width=width, + allow_unicode=allow_unicode, line_break=line_break) + Serializer.__init__(self, encoding=encoding, + explicit_start=explicit_start, explicit_end=explicit_end, + version=version, tags=tags) + SafeRepresenter.__init__(self, default_style=default_style, + default_flow_style=default_flow_style, sort_keys=sort_keys) + Resolver.__init__(self) + +class Dumper(Emitter, Serializer, Representer, Resolver): + + def __init__(self, stream, + default_style=None, default_flow_style=False, + canonical=None, indent=None, width=None, + allow_unicode=None, line_break=None, + encoding=None, explicit_start=None, explicit_end=None, + version=None, tags=None, sort_keys=True): + Emitter.__init__(self, stream, canonical=canonical, + indent=indent, width=width, + allow_unicode=allow_unicode, line_break=line_break) + Serializer.__init__(self, encoding=encoding, + explicit_start=explicit_start, explicit_end=explicit_end, + version=version, tags=tags) + Representer.__init__(self, default_style=default_style, + default_flow_style=default_flow_style, sort_keys=sort_keys) + Resolver.__init__(self) + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/emitter.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/emitter.py new file mode 100644 index 0000000000000000000000000000000000000000..a664d011162af69184df2f8e59ab7feec818f7c7 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/emitter.py @@ -0,0 +1,1137 @@ + +# Emitter expects events obeying the following grammar: +# stream ::= STREAM-START document* STREAM-END +# document ::= DOCUMENT-START node DOCUMENT-END +# node ::= SCALAR | sequence | mapping +# sequence ::= SEQUENCE-START node* SEQUENCE-END +# mapping ::= MAPPING-START (node node)* MAPPING-END + +__all__ = ['Emitter', 'EmitterError'] + +from .error import YAMLError +from .events import * + +class EmitterError(YAMLError): + pass + +class ScalarAnalysis: + def __init__(self, scalar, empty, multiline, + allow_flow_plain, allow_block_plain, + allow_single_quoted, allow_double_quoted, + allow_block): + self.scalar = scalar + self.empty = empty + self.multiline = multiline + self.allow_flow_plain = allow_flow_plain + self.allow_block_plain = allow_block_plain + self.allow_single_quoted = allow_single_quoted + self.allow_double_quoted = allow_double_quoted + self.allow_block = allow_block + +class Emitter: + + DEFAULT_TAG_PREFIXES = { + '!' : '!', + 'tag:yaml.org,2002:' : '!!', + } + + def __init__(self, stream, canonical=None, indent=None, width=None, + allow_unicode=None, line_break=None): + + # The stream should have the methods `write` and possibly `flush`. + self.stream = stream + + # Encoding can be overridden by STREAM-START. + self.encoding = None + + # Emitter is a state machine with a stack of states to handle nested + # structures. + self.states = [] + self.state = self.expect_stream_start + + # Current event and the event queue. + self.events = [] + self.event = None + + # The current indentation level and the stack of previous indents. + self.indents = [] + self.indent = None + + # Flow level. + self.flow_level = 0 + + # Contexts. + self.root_context = False + self.sequence_context = False + self.mapping_context = False + self.simple_key_context = False + + # Characteristics of the last emitted character: + # - current position. + # - is it a whitespace? + # - is it an indention character + # (indentation space, '-', '?', or ':')? + self.line = 0 + self.column = 0 + self.whitespace = True + self.indention = True + + # Whether the document requires an explicit document indicator + self.open_ended = False + + # Formatting details. + self.canonical = canonical + self.allow_unicode = allow_unicode + self.best_indent = 2 + if indent and 1 < indent < 10: + self.best_indent = indent + self.best_width = 80 + if width and width > self.best_indent*2: + self.best_width = width + self.best_line_break = '\n' + if line_break in ['\r', '\n', '\r\n']: + self.best_line_break = line_break + + # Tag prefixes. + self.tag_prefixes = None + + # Prepared anchor and tag. + self.prepared_anchor = None + self.prepared_tag = None + + # Scalar analysis and style. + self.analysis = None + self.style = None + + def dispose(self): + # Reset the state attributes (to clear self-references) + self.states = [] + self.state = None + + def emit(self, event): + self.events.append(event) + while not self.need_more_events(): + self.event = self.events.pop(0) + self.state() + self.event = None + + # In some cases, we wait for a few next events before emitting. + + def need_more_events(self): + if not self.events: + return True + event = self.events[0] + if isinstance(event, DocumentStartEvent): + return self.need_events(1) + elif isinstance(event, SequenceStartEvent): + return self.need_events(2) + elif isinstance(event, MappingStartEvent): + return self.need_events(3) + else: + return False + + def need_events(self, count): + level = 0 + for event in self.events[1:]: + if isinstance(event, (DocumentStartEvent, CollectionStartEvent)): + level += 1 + elif isinstance(event, (DocumentEndEvent, CollectionEndEvent)): + level -= 1 + elif isinstance(event, StreamEndEvent): + level = -1 + if level < 0: + return False + return (len(self.events) < count+1) + + def increase_indent(self, flow=False, indentless=False): + self.indents.append(self.indent) + if self.indent is None: + if flow: + self.indent = self.best_indent + else: + self.indent = 0 + elif not indentless: + self.indent += self.best_indent + + # States. + + # Stream handlers. + + def expect_stream_start(self): + if isinstance(self.event, StreamStartEvent): + if self.event.encoding and not hasattr(self.stream, 'encoding'): + self.encoding = self.event.encoding + self.write_stream_start() + self.state = self.expect_first_document_start + else: + raise EmitterError("expected StreamStartEvent, but got %s" + % self.event) + + def expect_nothing(self): + raise EmitterError("expected nothing, but got %s" % self.event) + + # Document handlers. + + def expect_first_document_start(self): + return self.expect_document_start(first=True) + + def expect_document_start(self, first=False): + if isinstance(self.event, DocumentStartEvent): + if (self.event.version or self.event.tags) and self.open_ended: + self.write_indicator('...', True) + self.write_indent() + if self.event.version: + version_text = self.prepare_version(self.event.version) + self.write_version_directive(version_text) + self.tag_prefixes = self.DEFAULT_TAG_PREFIXES.copy() + if self.event.tags: + handles = sorted(self.event.tags.keys()) + for handle in handles: + prefix = self.event.tags[handle] + self.tag_prefixes[prefix] = handle + handle_text = self.prepare_tag_handle(handle) + prefix_text = self.prepare_tag_prefix(prefix) + self.write_tag_directive(handle_text, prefix_text) + implicit = (first and not self.event.explicit and not self.canonical + and not self.event.version and not self.event.tags + and not self.check_empty_document()) + if not implicit: + self.write_indent() + self.write_indicator('---', True) + if self.canonical: + self.write_indent() + self.state = self.expect_document_root + elif isinstance(self.event, StreamEndEvent): + if self.open_ended: + self.write_indicator('...', True) + self.write_indent() + self.write_stream_end() + self.state = self.expect_nothing + else: + raise EmitterError("expected DocumentStartEvent, but got %s" + % self.event) + + def expect_document_end(self): + if isinstance(self.event, DocumentEndEvent): + self.write_indent() + if self.event.explicit: + self.write_indicator('...', True) + self.write_indent() + self.flush_stream() + self.state = self.expect_document_start + else: + raise EmitterError("expected DocumentEndEvent, but got %s" + % self.event) + + def expect_document_root(self): + self.states.append(self.expect_document_end) + self.expect_node(root=True) + + # Node handlers. + + def expect_node(self, root=False, sequence=False, mapping=False, + simple_key=False): + self.root_context = root + self.sequence_context = sequence + self.mapping_context = mapping + self.simple_key_context = simple_key + if isinstance(self.event, AliasEvent): + self.expect_alias() + elif isinstance(self.event, (ScalarEvent, CollectionStartEvent)): + self.process_anchor('&') + self.process_tag() + if isinstance(self.event, ScalarEvent): + self.expect_scalar() + elif isinstance(self.event, SequenceStartEvent): + if self.flow_level or self.canonical or self.event.flow_style \ + or self.check_empty_sequence(): + self.expect_flow_sequence() + else: + self.expect_block_sequence() + elif isinstance(self.event, MappingStartEvent): + if self.flow_level or self.canonical or self.event.flow_style \ + or self.check_empty_mapping(): + self.expect_flow_mapping() + else: + self.expect_block_mapping() + else: + raise EmitterError("expected NodeEvent, but got %s" % self.event) + + def expect_alias(self): + if self.event.anchor is None: + raise EmitterError("anchor is not specified for alias") + self.process_anchor('*') + self.state = self.states.pop() + + def expect_scalar(self): + self.increase_indent(flow=True) + self.process_scalar() + self.indent = self.indents.pop() + self.state = self.states.pop() + + # Flow sequence handlers. + + def expect_flow_sequence(self): + self.write_indicator('[', True, whitespace=True) + self.flow_level += 1 + self.increase_indent(flow=True) + self.state = self.expect_first_flow_sequence_item + + def expect_first_flow_sequence_item(self): + if isinstance(self.event, SequenceEndEvent): + self.indent = self.indents.pop() + self.flow_level -= 1 + self.write_indicator(']', False) + self.state = self.states.pop() + else: + if self.canonical or self.column > self.best_width: + self.write_indent() + self.states.append(self.expect_flow_sequence_item) + self.expect_node(sequence=True) + + def expect_flow_sequence_item(self): + if isinstance(self.event, SequenceEndEvent): + self.indent = self.indents.pop() + self.flow_level -= 1 + if self.canonical: + self.write_indicator(',', False) + self.write_indent() + self.write_indicator(']', False) + self.state = self.states.pop() + else: + self.write_indicator(',', False) + if self.canonical or self.column > self.best_width: + self.write_indent() + self.states.append(self.expect_flow_sequence_item) + self.expect_node(sequence=True) + + # Flow mapping handlers. + + def expect_flow_mapping(self): + self.write_indicator('{', True, whitespace=True) + self.flow_level += 1 + self.increase_indent(flow=True) + self.state = self.expect_first_flow_mapping_key + + def expect_first_flow_mapping_key(self): + if isinstance(self.event, MappingEndEvent): + self.indent = self.indents.pop() + self.flow_level -= 1 + self.write_indicator('}', False) + self.state = self.states.pop() + else: + if self.canonical or self.column > self.best_width: + self.write_indent() + if not self.canonical and self.check_simple_key(): + self.states.append(self.expect_flow_mapping_simple_value) + self.expect_node(mapping=True, simple_key=True) + else: + self.write_indicator('?', True) + self.states.append(self.expect_flow_mapping_value) + self.expect_node(mapping=True) + + def expect_flow_mapping_key(self): + if isinstance(self.event, MappingEndEvent): + self.indent = self.indents.pop() + self.flow_level -= 1 + if self.canonical: + self.write_indicator(',', False) + self.write_indent() + self.write_indicator('}', False) + self.state = self.states.pop() + else: + self.write_indicator(',', False) + if self.canonical or self.column > self.best_width: + self.write_indent() + if not self.canonical and self.check_simple_key(): + self.states.append(self.expect_flow_mapping_simple_value) + self.expect_node(mapping=True, simple_key=True) + else: + self.write_indicator('?', True) + self.states.append(self.expect_flow_mapping_value) + self.expect_node(mapping=True) + + def expect_flow_mapping_simple_value(self): + self.write_indicator(':', False) + self.states.append(self.expect_flow_mapping_key) + self.expect_node(mapping=True) + + def expect_flow_mapping_value(self): + if self.canonical or self.column > self.best_width: + self.write_indent() + self.write_indicator(':', True) + self.states.append(self.expect_flow_mapping_key) + self.expect_node(mapping=True) + + # Block sequence handlers. + + def expect_block_sequence(self): + indentless = (self.mapping_context and not self.indention) + self.increase_indent(flow=False, indentless=indentless) + self.state = self.expect_first_block_sequence_item + + def expect_first_block_sequence_item(self): + return self.expect_block_sequence_item(first=True) + + def expect_block_sequence_item(self, first=False): + if not first and isinstance(self.event, SequenceEndEvent): + self.indent = self.indents.pop() + self.state = self.states.pop() + else: + self.write_indent() + self.write_indicator('-', True, indention=True) + self.states.append(self.expect_block_sequence_item) + self.expect_node(sequence=True) + + # Block mapping handlers. + + def expect_block_mapping(self): + self.increase_indent(flow=False) + self.state = self.expect_first_block_mapping_key + + def expect_first_block_mapping_key(self): + return self.expect_block_mapping_key(first=True) + + def expect_block_mapping_key(self, first=False): + if not first and isinstance(self.event, MappingEndEvent): + self.indent = self.indents.pop() + self.state = self.states.pop() + else: + self.write_indent() + if self.check_simple_key(): + self.states.append(self.expect_block_mapping_simple_value) + self.expect_node(mapping=True, simple_key=True) + else: + self.write_indicator('?', True, indention=True) + self.states.append(self.expect_block_mapping_value) + self.expect_node(mapping=True) + + def expect_block_mapping_simple_value(self): + self.write_indicator(':', False) + self.states.append(self.expect_block_mapping_key) + self.expect_node(mapping=True) + + def expect_block_mapping_value(self): + self.write_indent() + self.write_indicator(':', True, indention=True) + self.states.append(self.expect_block_mapping_key) + self.expect_node(mapping=True) + + # Checkers. + + def check_empty_sequence(self): + return (isinstance(self.event, SequenceStartEvent) and self.events + and isinstance(self.events[0], SequenceEndEvent)) + + def check_empty_mapping(self): + return (isinstance(self.event, MappingStartEvent) and self.events + and isinstance(self.events[0], MappingEndEvent)) + + def check_empty_document(self): + if not isinstance(self.event, DocumentStartEvent) or not self.events: + return False + event = self.events[0] + return (isinstance(event, ScalarEvent) and event.anchor is None + and event.tag is None and event.implicit and event.value == '') + + def check_simple_key(self): + length = 0 + if isinstance(self.event, NodeEvent) and self.event.anchor is not None: + if self.prepared_anchor is None: + self.prepared_anchor = self.prepare_anchor(self.event.anchor) + length += len(self.prepared_anchor) + if isinstance(self.event, (ScalarEvent, CollectionStartEvent)) \ + and self.event.tag is not None: + if self.prepared_tag is None: + self.prepared_tag = self.prepare_tag(self.event.tag) + length += len(self.prepared_tag) + if isinstance(self.event, ScalarEvent): + if self.analysis is None: + self.analysis = self.analyze_scalar(self.event.value) + length += len(self.analysis.scalar) + return (length < 128 and (isinstance(self.event, AliasEvent) + or (isinstance(self.event, ScalarEvent) + and not self.analysis.empty and not self.analysis.multiline) + or self.check_empty_sequence() or self.check_empty_mapping())) + + # Anchor, Tag, and Scalar processors. + + def process_anchor(self, indicator): + if self.event.anchor is None: + self.prepared_anchor = None + return + if self.prepared_anchor is None: + self.prepared_anchor = self.prepare_anchor(self.event.anchor) + if self.prepared_anchor: + self.write_indicator(indicator+self.prepared_anchor, True) + self.prepared_anchor = None + + def process_tag(self): + tag = self.event.tag + if isinstance(self.event, ScalarEvent): + if self.style is None: + self.style = self.choose_scalar_style() + if ((not self.canonical or tag is None) and + ((self.style == '' and self.event.implicit[0]) + or (self.style != '' and self.event.implicit[1]))): + self.prepared_tag = None + return + if self.event.implicit[0] and tag is None: + tag = '!' + self.prepared_tag = None + else: + if (not self.canonical or tag is None) and self.event.implicit: + self.prepared_tag = None + return + if tag is None: + raise EmitterError("tag is not specified") + if self.prepared_tag is None: + self.prepared_tag = self.prepare_tag(tag) + if self.prepared_tag: + self.write_indicator(self.prepared_tag, True) + self.prepared_tag = None + + def choose_scalar_style(self): + if self.analysis is None: + self.analysis = self.analyze_scalar(self.event.value) + if self.event.style == '"' or self.canonical: + return '"' + if not self.event.style and self.event.implicit[0]: + if (not (self.simple_key_context and + (self.analysis.empty or self.analysis.multiline)) + and (self.flow_level and self.analysis.allow_flow_plain + or (not self.flow_level and self.analysis.allow_block_plain))): + return '' + if self.event.style and self.event.style in '|>': + if (not self.flow_level and not self.simple_key_context + and self.analysis.allow_block): + return self.event.style + if not self.event.style or self.event.style == '\'': + if (self.analysis.allow_single_quoted and + not (self.simple_key_context and self.analysis.multiline)): + return '\'' + return '"' + + def process_scalar(self): + if self.analysis is None: + self.analysis = self.analyze_scalar(self.event.value) + if self.style is None: + self.style = self.choose_scalar_style() + split = (not self.simple_key_context) + #if self.analysis.multiline and split \ + # and (not self.style or self.style in '\'\"'): + # self.write_indent() + if self.style == '"': + self.write_double_quoted(self.analysis.scalar, split) + elif self.style == '\'': + self.write_single_quoted(self.analysis.scalar, split) + elif self.style == '>': + self.write_folded(self.analysis.scalar) + elif self.style == '|': + self.write_literal(self.analysis.scalar) + else: + self.write_plain(self.analysis.scalar, split) + self.analysis = None + self.style = None + + # Analyzers. + + def prepare_version(self, version): + major, minor = version + if major != 1: + raise EmitterError("unsupported YAML version: %d.%d" % (major, minor)) + return '%d.%d' % (major, minor) + + def prepare_tag_handle(self, handle): + if not handle: + raise EmitterError("tag handle must not be empty") + if handle[0] != '!' or handle[-1] != '!': + raise EmitterError("tag handle must start and end with '!': %r" % handle) + for ch in handle[1:-1]: + if not ('0' <= ch <= '9' or 'A' <= ch <= 'Z' or 'a' <= ch <= 'z' \ + or ch in '-_'): + raise EmitterError("invalid character %r in the tag handle: %r" + % (ch, handle)) + return handle + + def prepare_tag_prefix(self, prefix): + if not prefix: + raise EmitterError("tag prefix must not be empty") + chunks = [] + start = end = 0 + if prefix[0] == '!': + end = 1 + while end < len(prefix): + ch = prefix[end] + if '0' <= ch <= '9' or 'A' <= ch <= 'Z' or 'a' <= ch <= 'z' \ + or ch in '-;/?!:@&=+$,_.~*\'()[]': + end += 1 + else: + if start < end: + chunks.append(prefix[start:end]) + start = end = end+1 + data = ch.encode('utf-8') + for ch in data: + chunks.append('%%%02X' % ord(ch)) + if start < end: + chunks.append(prefix[start:end]) + return ''.join(chunks) + + def prepare_tag(self, tag): + if not tag: + raise EmitterError("tag must not be empty") + if tag == '!': + return tag + handle = None + suffix = tag + prefixes = sorted(self.tag_prefixes.keys()) + for prefix in prefixes: + if tag.startswith(prefix) \ + and (prefix == '!' or len(prefix) < len(tag)): + handle = self.tag_prefixes[prefix] + suffix = tag[len(prefix):] + chunks = [] + start = end = 0 + while end < len(suffix): + ch = suffix[end] + if '0' <= ch <= '9' or 'A' <= ch <= 'Z' or 'a' <= ch <= 'z' \ + or ch in '-;/?:@&=+$,_.~*\'()[]' \ + or (ch == '!' and handle != '!'): + end += 1 + else: + if start < end: + chunks.append(suffix[start:end]) + start = end = end+1 + data = ch.encode('utf-8') + for ch in data: + chunks.append('%%%02X' % ch) + if start < end: + chunks.append(suffix[start:end]) + suffix_text = ''.join(chunks) + if handle: + return '%s%s' % (handle, suffix_text) + else: + return '!<%s>' % suffix_text + + def prepare_anchor(self, anchor): + if not anchor: + raise EmitterError("anchor must not be empty") + for ch in anchor: + if not ('0' <= ch <= '9' or 'A' <= ch <= 'Z' or 'a' <= ch <= 'z' \ + or ch in '-_'): + raise EmitterError("invalid character %r in the anchor: %r" + % (ch, anchor)) + return anchor + + def analyze_scalar(self, scalar): + + # Empty scalar is a special case. + if not scalar: + return ScalarAnalysis(scalar=scalar, empty=True, multiline=False, + allow_flow_plain=False, allow_block_plain=True, + allow_single_quoted=True, allow_double_quoted=True, + allow_block=False) + + # Indicators and special characters. + block_indicators = False + flow_indicators = False + line_breaks = False + special_characters = False + + # Important whitespace combinations. + leading_space = False + leading_break = False + trailing_space = False + trailing_break = False + break_space = False + space_break = False + + # Check document indicators. + if scalar.startswith('---') or scalar.startswith('...'): + block_indicators = True + flow_indicators = True + + # First character or preceded by a whitespace. + preceded_by_whitespace = True + + # Last character or followed by a whitespace. + followed_by_whitespace = (len(scalar) == 1 or + scalar[1] in '\0 \t\r\n\x85\u2028\u2029') + + # The previous character is a space. + previous_space = False + + # The previous character is a break. + previous_break = False + + index = 0 + while index < len(scalar): + ch = scalar[index] + + # Check for indicators. + if index == 0: + # Leading indicators are special characters. + if ch in '#,[]{}&*!|>\'\"%@`': + flow_indicators = True + block_indicators = True + if ch in '?:': + flow_indicators = True + if followed_by_whitespace: + block_indicators = True + if ch == '-' and followed_by_whitespace: + flow_indicators = True + block_indicators = True + else: + # Some indicators cannot appear within a scalar as well. + if ch in ',?[]{}': + flow_indicators = True + if ch == ':': + flow_indicators = True + if followed_by_whitespace: + block_indicators = True + if ch == '#' and preceded_by_whitespace: + flow_indicators = True + block_indicators = True + + # Check for line breaks, special, and unicode characters. + if ch in '\n\x85\u2028\u2029': + line_breaks = True + if not (ch == '\n' or '\x20' <= ch <= '\x7E'): + if (ch == '\x85' or '\xA0' <= ch <= '\uD7FF' + or '\uE000' <= ch <= '\uFFFD' + or '\U00010000' <= ch < '\U0010ffff') and ch != '\uFEFF': + unicode_characters = True + if not self.allow_unicode: + special_characters = True + else: + special_characters = True + + # Detect important whitespace combinations. + if ch == ' ': + if index == 0: + leading_space = True + if index == len(scalar)-1: + trailing_space = True + if previous_break: + break_space = True + previous_space = True + previous_break = False + elif ch in '\n\x85\u2028\u2029': + if index == 0: + leading_break = True + if index == len(scalar)-1: + trailing_break = True + if previous_space: + space_break = True + previous_space = False + previous_break = True + else: + previous_space = False + previous_break = False + + # Prepare for the next character. + index += 1 + preceded_by_whitespace = (ch in '\0 \t\r\n\x85\u2028\u2029') + followed_by_whitespace = (index+1 >= len(scalar) or + scalar[index+1] in '\0 \t\r\n\x85\u2028\u2029') + + # Let's decide what styles are allowed. + allow_flow_plain = True + allow_block_plain = True + allow_single_quoted = True + allow_double_quoted = True + allow_block = True + + # Leading and trailing whitespaces are bad for plain scalars. + if (leading_space or leading_break + or trailing_space or trailing_break): + allow_flow_plain = allow_block_plain = False + + # We do not permit trailing spaces for block scalars. + if trailing_space: + allow_block = False + + # Spaces at the beginning of a new line are only acceptable for block + # scalars. + if break_space: + allow_flow_plain = allow_block_plain = allow_single_quoted = False + + # Spaces followed by breaks, as well as special character are only + # allowed for double quoted scalars. + if space_break or special_characters: + allow_flow_plain = allow_block_plain = \ + allow_single_quoted = allow_block = False + + # Although the plain scalar writer supports breaks, we never emit + # multiline plain scalars. + if line_breaks: + allow_flow_plain = allow_block_plain = False + + # Flow indicators are forbidden for flow plain scalars. + if flow_indicators: + allow_flow_plain = False + + # Block indicators are forbidden for block plain scalars. + if block_indicators: + allow_block_plain = False + + return ScalarAnalysis(scalar=scalar, + empty=False, multiline=line_breaks, + allow_flow_plain=allow_flow_plain, + allow_block_plain=allow_block_plain, + allow_single_quoted=allow_single_quoted, + allow_double_quoted=allow_double_quoted, + allow_block=allow_block) + + # Writers. + + def flush_stream(self): + if hasattr(self.stream, 'flush'): + self.stream.flush() + + def write_stream_start(self): + # Write BOM if needed. + if self.encoding and self.encoding.startswith('utf-16'): + self.stream.write('\uFEFF'.encode(self.encoding)) + + def write_stream_end(self): + self.flush_stream() + + def write_indicator(self, indicator, need_whitespace, + whitespace=False, indention=False): + if self.whitespace or not need_whitespace: + data = indicator + else: + data = ' '+indicator + self.whitespace = whitespace + self.indention = self.indention and indention + self.column += len(data) + self.open_ended = False + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + + def write_indent(self): + indent = self.indent or 0 + if not self.indention or self.column > indent \ + or (self.column == indent and not self.whitespace): + self.write_line_break() + if self.column < indent: + self.whitespace = True + data = ' '*(indent-self.column) + self.column = indent + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + + def write_line_break(self, data=None): + if data is None: + data = self.best_line_break + self.whitespace = True + self.indention = True + self.line += 1 + self.column = 0 + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + + def write_version_directive(self, version_text): + data = '%%YAML %s' % version_text + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + self.write_line_break() + + def write_tag_directive(self, handle_text, prefix_text): + data = '%%TAG %s %s' % (handle_text, prefix_text) + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + self.write_line_break() + + # Scalar streams. + + def write_single_quoted(self, text, split=True): + self.write_indicator('\'', True) + spaces = False + breaks = False + start = end = 0 + while end <= len(text): + ch = None + if end < len(text): + ch = text[end] + if spaces: + if ch is None or ch != ' ': + if start+1 == end and self.column > self.best_width and split \ + and start != 0 and end != len(text): + self.write_indent() + else: + data = text[start:end] + self.column += len(data) + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + start = end + elif breaks: + if ch is None or ch not in '\n\x85\u2028\u2029': + if text[start] == '\n': + self.write_line_break() + for br in text[start:end]: + if br == '\n': + self.write_line_break() + else: + self.write_line_break(br) + self.write_indent() + start = end + else: + if ch is None or ch in ' \n\x85\u2028\u2029' or ch == '\'': + if start < end: + data = text[start:end] + self.column += len(data) + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + start = end + if ch == '\'': + data = '\'\'' + self.column += 2 + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + start = end + 1 + if ch is not None: + spaces = (ch == ' ') + breaks = (ch in '\n\x85\u2028\u2029') + end += 1 + self.write_indicator('\'', False) + + ESCAPE_REPLACEMENTS = { + '\0': '0', + '\x07': 'a', + '\x08': 'b', + '\x09': 't', + '\x0A': 'n', + '\x0B': 'v', + '\x0C': 'f', + '\x0D': 'r', + '\x1B': 'e', + '\"': '\"', + '\\': '\\', + '\x85': 'N', + '\xA0': '_', + '\u2028': 'L', + '\u2029': 'P', + } + + def write_double_quoted(self, text, split=True): + self.write_indicator('"', True) + start = end = 0 + while end <= len(text): + ch = None + if end < len(text): + ch = text[end] + if ch is None or ch in '"\\\x85\u2028\u2029\uFEFF' \ + or not ('\x20' <= ch <= '\x7E' + or (self.allow_unicode + and ('\xA0' <= ch <= '\uD7FF' + or '\uE000' <= ch <= '\uFFFD'))): + if start < end: + data = text[start:end] + self.column += len(data) + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + start = end + if ch is not None: + if ch in self.ESCAPE_REPLACEMENTS: + data = '\\'+self.ESCAPE_REPLACEMENTS[ch] + elif ch <= '\xFF': + data = '\\x%02X' % ord(ch) + elif ch <= '\uFFFF': + data = '\\u%04X' % ord(ch) + else: + data = '\\U%08X' % ord(ch) + self.column += len(data) + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + start = end+1 + if 0 < end < len(text)-1 and (ch == ' ' or start >= end) \ + and self.column+(end-start) > self.best_width and split: + data = text[start:end]+'\\' + if start < end: + start = end + self.column += len(data) + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + self.write_indent() + self.whitespace = False + self.indention = False + if text[start] == ' ': + data = '\\' + self.column += len(data) + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + end += 1 + self.write_indicator('"', False) + + def determine_block_hints(self, text): + hints = '' + if text: + if text[0] in ' \n\x85\u2028\u2029': + hints += str(self.best_indent) + if text[-1] not in '\n\x85\u2028\u2029': + hints += '-' + elif len(text) == 1 or text[-2] in '\n\x85\u2028\u2029': + hints += '+' + return hints + + def write_folded(self, text): + hints = self.determine_block_hints(text) + self.write_indicator('>'+hints, True) + if hints[-1:] == '+': + self.open_ended = True + self.write_line_break() + leading_space = True + spaces = False + breaks = True + start = end = 0 + while end <= len(text): + ch = None + if end < len(text): + ch = text[end] + if breaks: + if ch is None or ch not in '\n\x85\u2028\u2029': + if not leading_space and ch is not None and ch != ' ' \ + and text[start] == '\n': + self.write_line_break() + leading_space = (ch == ' ') + for br in text[start:end]: + if br == '\n': + self.write_line_break() + else: + self.write_line_break(br) + if ch is not None: + self.write_indent() + start = end + elif spaces: + if ch != ' ': + if start+1 == end and self.column > self.best_width: + self.write_indent() + else: + data = text[start:end] + self.column += len(data) + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + start = end + else: + if ch is None or ch in ' \n\x85\u2028\u2029': + data = text[start:end] + self.column += len(data) + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + if ch is None: + self.write_line_break() + start = end + if ch is not None: + breaks = (ch in '\n\x85\u2028\u2029') + spaces = (ch == ' ') + end += 1 + + def write_literal(self, text): + hints = self.determine_block_hints(text) + self.write_indicator('|'+hints, True) + if hints[-1:] == '+': + self.open_ended = True + self.write_line_break() + breaks = True + start = end = 0 + while end <= len(text): + ch = None + if end < len(text): + ch = text[end] + if breaks: + if ch is None or ch not in '\n\x85\u2028\u2029': + for br in text[start:end]: + if br == '\n': + self.write_line_break() + else: + self.write_line_break(br) + if ch is not None: + self.write_indent() + start = end + else: + if ch is None or ch in '\n\x85\u2028\u2029': + data = text[start:end] + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + if ch is None: + self.write_line_break() + start = end + if ch is not None: + breaks = (ch in '\n\x85\u2028\u2029') + end += 1 + + def write_plain(self, text, split=True): + if self.root_context: + self.open_ended = True + if not text: + return + if not self.whitespace: + data = ' ' + self.column += len(data) + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + self.whitespace = False + self.indention = False + spaces = False + breaks = False + start = end = 0 + while end <= len(text): + ch = None + if end < len(text): + ch = text[end] + if spaces: + if ch != ' ': + if start+1 == end and self.column > self.best_width and split: + self.write_indent() + self.whitespace = False + self.indention = False + else: + data = text[start:end] + self.column += len(data) + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + start = end + elif breaks: + if ch not in '\n\x85\u2028\u2029': + if text[start] == '\n': + self.write_line_break() + for br in text[start:end]: + if br == '\n': + self.write_line_break() + else: + self.write_line_break(br) + self.write_indent() + self.whitespace = False + self.indention = False + start = end + else: + if ch is None or ch in ' \n\x85\u2028\u2029': + data = text[start:end] + self.column += len(data) + if self.encoding: + data = data.encode(self.encoding) + self.stream.write(data) + start = end + if ch is not None: + spaces = (ch == ' ') + breaks = (ch in '\n\x85\u2028\u2029') + end += 1 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/error.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/error.py new file mode 100644 index 0000000000000000000000000000000000000000..b796b4dc519512c4825ff539a2e6aa20f4d370d0 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/error.py @@ -0,0 +1,75 @@ + +__all__ = ['Mark', 'YAMLError', 'MarkedYAMLError'] + +class Mark: + + def __init__(self, name, index, line, column, buffer, pointer): + self.name = name + self.index = index + self.line = line + self.column = column + self.buffer = buffer + self.pointer = pointer + + def get_snippet(self, indent=4, max_length=75): + if self.buffer is None: + return None + head = '' + start = self.pointer + while start > 0 and self.buffer[start-1] not in '\0\r\n\x85\u2028\u2029': + start -= 1 + if self.pointer-start > max_length/2-1: + head = ' ... ' + start += 5 + break + tail = '' + end = self.pointer + while end < len(self.buffer) and self.buffer[end] not in '\0\r\n\x85\u2028\u2029': + end += 1 + if end-self.pointer > max_length/2-1: + tail = ' ... ' + end -= 5 + break + snippet = self.buffer[start:end] + return ' '*indent + head + snippet + tail + '\n' \ + + ' '*(indent+self.pointer-start+len(head)) + '^' + + def __str__(self): + snippet = self.get_snippet() + where = " in \"%s\", line %d, column %d" \ + % (self.name, self.line+1, self.column+1) + if snippet is not None: + where += ":\n"+snippet + return where + +class YAMLError(Exception): + pass + +class MarkedYAMLError(YAMLError): + + def __init__(self, context=None, context_mark=None, + problem=None, problem_mark=None, note=None): + self.context = context + self.context_mark = context_mark + self.problem = problem + self.problem_mark = problem_mark + self.note = note + + def __str__(self): + lines = [] + if self.context is not None: + lines.append(self.context) + if self.context_mark is not None \ + and (self.problem is None or self.problem_mark is None + or self.context_mark.name != self.problem_mark.name + or self.context_mark.line != self.problem_mark.line + or self.context_mark.column != self.problem_mark.column): + lines.append(str(self.context_mark)) + if self.problem is not None: + lines.append(self.problem) + if self.problem_mark is not None: + lines.append(str(self.problem_mark)) + if self.note is not None: + lines.append(self.note) + return '\n'.join(lines) + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/events.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/events.py new file mode 100644 index 0000000000000000000000000000000000000000..f79ad389cb6c9517e391dcd25534866bc9ccd36a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/events.py @@ -0,0 +1,86 @@ + +# Abstract classes. + +class Event(object): + def __init__(self, start_mark=None, end_mark=None): + self.start_mark = start_mark + self.end_mark = end_mark + def __repr__(self): + attributes = [key for key in ['anchor', 'tag', 'implicit', 'value'] + if hasattr(self, key)] + arguments = ', '.join(['%s=%r' % (key, getattr(self, key)) + for key in attributes]) + return '%s(%s)' % (self.__class__.__name__, arguments) + +class NodeEvent(Event): + def __init__(self, anchor, start_mark=None, end_mark=None): + self.anchor = anchor + self.start_mark = start_mark + self.end_mark = end_mark + +class CollectionStartEvent(NodeEvent): + def __init__(self, anchor, tag, implicit, start_mark=None, end_mark=None, + flow_style=None): + self.anchor = anchor + self.tag = tag + self.implicit = implicit + self.start_mark = start_mark + self.end_mark = end_mark + self.flow_style = flow_style + +class CollectionEndEvent(Event): + pass + +# Implementations. + +class StreamStartEvent(Event): + def __init__(self, start_mark=None, end_mark=None, encoding=None): + self.start_mark = start_mark + self.end_mark = end_mark + self.encoding = encoding + +class StreamEndEvent(Event): + pass + +class DocumentStartEvent(Event): + def __init__(self, start_mark=None, end_mark=None, + explicit=None, version=None, tags=None): + self.start_mark = start_mark + self.end_mark = end_mark + self.explicit = explicit + self.version = version + self.tags = tags + +class DocumentEndEvent(Event): + def __init__(self, start_mark=None, end_mark=None, + explicit=None): + self.start_mark = start_mark + self.end_mark = end_mark + self.explicit = explicit + +class AliasEvent(NodeEvent): + pass + +class ScalarEvent(NodeEvent): + def __init__(self, anchor, tag, implicit, value, + start_mark=None, end_mark=None, style=None): + self.anchor = anchor + self.tag = tag + self.implicit = implicit + self.value = value + self.start_mark = start_mark + self.end_mark = end_mark + self.style = style + +class SequenceStartEvent(CollectionStartEvent): + pass + +class SequenceEndEvent(CollectionEndEvent): + pass + +class MappingStartEvent(CollectionStartEvent): + pass + +class MappingEndEvent(CollectionEndEvent): + pass + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/loader.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/loader.py new file mode 100644 index 0000000000000000000000000000000000000000..e90c11224c38e559cdf0cb205f0692ebd4fb8681 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/loader.py @@ -0,0 +1,63 @@ + +__all__ = ['BaseLoader', 'FullLoader', 'SafeLoader', 'Loader', 'UnsafeLoader'] + +from .reader import * +from .scanner import * +from .parser import * +from .composer import * +from .constructor import * +from .resolver import * + +class BaseLoader(Reader, Scanner, Parser, Composer, BaseConstructor, BaseResolver): + + def __init__(self, stream): + Reader.__init__(self, stream) + Scanner.__init__(self) + Parser.__init__(self) + Composer.__init__(self) + BaseConstructor.__init__(self) + BaseResolver.__init__(self) + +class FullLoader(Reader, Scanner, Parser, Composer, FullConstructor, Resolver): + + def __init__(self, stream): + Reader.__init__(self, stream) + Scanner.__init__(self) + Parser.__init__(self) + Composer.__init__(self) + FullConstructor.__init__(self) + Resolver.__init__(self) + +class SafeLoader(Reader, Scanner, Parser, Composer, SafeConstructor, Resolver): + + def __init__(self, stream): + Reader.__init__(self, stream) + Scanner.__init__(self) + Parser.__init__(self) + Composer.__init__(self) + SafeConstructor.__init__(self) + Resolver.__init__(self) + +class Loader(Reader, Scanner, Parser, Composer, Constructor, Resolver): + + def __init__(self, stream): + Reader.__init__(self, stream) + Scanner.__init__(self) + Parser.__init__(self) + Composer.__init__(self) + Constructor.__init__(self) + Resolver.__init__(self) + +# UnsafeLoader is the same as Loader (which is and was always unsafe on +# untrusted input). Use of either Loader or UnsafeLoader should be rare, since +# FullLoad should be able to load almost all YAML safely. Loader is left intact +# to ensure backwards compatibility. +class UnsafeLoader(Reader, Scanner, Parser, Composer, Constructor, Resolver): + + def __init__(self, stream): + Reader.__init__(self, stream) + Scanner.__init__(self) + Parser.__init__(self) + Composer.__init__(self) + Constructor.__init__(self) + Resolver.__init__(self) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/nodes.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/nodes.py new file mode 100644 index 0000000000000000000000000000000000000000..c4f070c41e1fb1bc01af27d69329e92dded38908 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/nodes.py @@ -0,0 +1,49 @@ + +class Node(object): + def __init__(self, tag, value, start_mark, end_mark): + self.tag = tag + self.value = value + self.start_mark = start_mark + self.end_mark = end_mark + def __repr__(self): + value = self.value + #if isinstance(value, list): + # if len(value) == 0: + # value = '<empty>' + # elif len(value) == 1: + # value = '<1 item>' + # else: + # value = '<%d items>' % len(value) + #else: + # if len(value) > 75: + # value = repr(value[:70]+u' ... ') + # else: + # value = repr(value) + value = repr(value) + return '%s(tag=%r, value=%s)' % (self.__class__.__name__, self.tag, value) + +class ScalarNode(Node): + id = 'scalar' + def __init__(self, tag, value, + start_mark=None, end_mark=None, style=None): + self.tag = tag + self.value = value + self.start_mark = start_mark + self.end_mark = end_mark + self.style = style + +class CollectionNode(Node): + def __init__(self, tag, value, + start_mark=None, end_mark=None, flow_style=None): + self.tag = tag + self.value = value + self.start_mark = start_mark + self.end_mark = end_mark + self.flow_style = flow_style + +class SequenceNode(CollectionNode): + id = 'sequence' + +class MappingNode(CollectionNode): + id = 'mapping' + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/parser.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/parser.py new file mode 100644 index 0000000000000000000000000000000000000000..13a5995d292045d0f865a99abf692bd35dc87814 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/parser.py @@ -0,0 +1,589 @@ + +# The following YAML grammar is LL(1) and is parsed by a recursive descent +# parser. +# +# stream ::= STREAM-START implicit_document? explicit_document* STREAM-END +# implicit_document ::= block_node DOCUMENT-END* +# explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* +# block_node_or_indentless_sequence ::= +# ALIAS +# | properties (block_content | indentless_block_sequence)? +# | block_content +# | indentless_block_sequence +# block_node ::= ALIAS +# | properties block_content? +# | block_content +# flow_node ::= ALIAS +# | properties flow_content? +# | flow_content +# properties ::= TAG ANCHOR? | ANCHOR TAG? +# block_content ::= block_collection | flow_collection | SCALAR +# flow_content ::= flow_collection | SCALAR +# block_collection ::= block_sequence | block_mapping +# flow_collection ::= flow_sequence | flow_mapping +# block_sequence ::= BLOCK-SEQUENCE-START (BLOCK-ENTRY block_node?)* BLOCK-END +# indentless_sequence ::= (BLOCK-ENTRY block_node?)+ +# block_mapping ::= BLOCK-MAPPING_START +# ((KEY block_node_or_indentless_sequence?)? +# (VALUE block_node_or_indentless_sequence?)?)* +# BLOCK-END +# flow_sequence ::= FLOW-SEQUENCE-START +# (flow_sequence_entry FLOW-ENTRY)* +# flow_sequence_entry? +# FLOW-SEQUENCE-END +# flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? +# flow_mapping ::= FLOW-MAPPING-START +# (flow_mapping_entry FLOW-ENTRY)* +# flow_mapping_entry? +# FLOW-MAPPING-END +# flow_mapping_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? +# +# FIRST sets: +# +# stream: { STREAM-START } +# explicit_document: { DIRECTIVE DOCUMENT-START } +# implicit_document: FIRST(block_node) +# block_node: { ALIAS TAG ANCHOR SCALAR BLOCK-SEQUENCE-START BLOCK-MAPPING-START FLOW-SEQUENCE-START FLOW-MAPPING-START } +# flow_node: { ALIAS ANCHOR TAG SCALAR FLOW-SEQUENCE-START FLOW-MAPPING-START } +# block_content: { BLOCK-SEQUENCE-START BLOCK-MAPPING-START FLOW-SEQUENCE-START FLOW-MAPPING-START SCALAR } +# flow_content: { FLOW-SEQUENCE-START FLOW-MAPPING-START SCALAR } +# block_collection: { BLOCK-SEQUENCE-START BLOCK-MAPPING-START } +# flow_collection: { FLOW-SEQUENCE-START FLOW-MAPPING-START } +# block_sequence: { BLOCK-SEQUENCE-START } +# block_mapping: { BLOCK-MAPPING-START } +# block_node_or_indentless_sequence: { ALIAS ANCHOR TAG SCALAR BLOCK-SEQUENCE-START BLOCK-MAPPING-START FLOW-SEQUENCE-START FLOW-MAPPING-START BLOCK-ENTRY } +# indentless_sequence: { ENTRY } +# flow_collection: { FLOW-SEQUENCE-START FLOW-MAPPING-START } +# flow_sequence: { FLOW-SEQUENCE-START } +# flow_mapping: { FLOW-MAPPING-START } +# flow_sequence_entry: { ALIAS ANCHOR TAG SCALAR FLOW-SEQUENCE-START FLOW-MAPPING-START KEY } +# flow_mapping_entry: { ALIAS ANCHOR TAG SCALAR FLOW-SEQUENCE-START FLOW-MAPPING-START KEY } + +__all__ = ['Parser', 'ParserError'] + +from .error import MarkedYAMLError +from .tokens import * +from .events import * +from .scanner import * + +class ParserError(MarkedYAMLError): + pass + +class Parser: + # Since writing a recursive-descendant parser is a straightforward task, we + # do not give many comments here. + + DEFAULT_TAGS = { + '!': '!', + '!!': 'tag:yaml.org,2002:', + } + + def __init__(self): + self.current_event = None + self.yaml_version = None + self.tag_handles = {} + self.states = [] + self.marks = [] + self.state = self.parse_stream_start + + def dispose(self): + # Reset the state attributes (to clear self-references) + self.states = [] + self.state = None + + def check_event(self, *choices): + # Check the type of the next event. + if self.current_event is None: + if self.state: + self.current_event = self.state() + if self.current_event is not None: + if not choices: + return True + for choice in choices: + if isinstance(self.current_event, choice): + return True + return False + + def peek_event(self): + # Get the next event. + if self.current_event is None: + if self.state: + self.current_event = self.state() + return self.current_event + + def get_event(self): + # Get the next event and proceed further. + if self.current_event is None: + if self.state: + self.current_event = self.state() + value = self.current_event + self.current_event = None + return value + + # stream ::= STREAM-START implicit_document? explicit_document* STREAM-END + # implicit_document ::= block_node DOCUMENT-END* + # explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* + + def parse_stream_start(self): + + # Parse the stream start. + token = self.get_token() + event = StreamStartEvent(token.start_mark, token.end_mark, + encoding=token.encoding) + + # Prepare the next state. + self.state = self.parse_implicit_document_start + + return event + + def parse_implicit_document_start(self): + + # Parse an implicit document. + if not self.check_token(DirectiveToken, DocumentStartToken, + StreamEndToken): + self.tag_handles = self.DEFAULT_TAGS + token = self.peek_token() + start_mark = end_mark = token.start_mark + event = DocumentStartEvent(start_mark, end_mark, + explicit=False) + + # Prepare the next state. + self.states.append(self.parse_document_end) + self.state = self.parse_block_node + + return event + + else: + return self.parse_document_start() + + def parse_document_start(self): + + # Parse any extra document end indicators. + while self.check_token(DocumentEndToken): + self.get_token() + + # Parse an explicit document. + if not self.check_token(StreamEndToken): + token = self.peek_token() + start_mark = token.start_mark + version, tags = self.process_directives() + if not self.check_token(DocumentStartToken): + raise ParserError(None, None, + "expected '<document start>', but found %r" + % self.peek_token().id, + self.peek_token().start_mark) + token = self.get_token() + end_mark = token.end_mark + event = DocumentStartEvent(start_mark, end_mark, + explicit=True, version=version, tags=tags) + self.states.append(self.parse_document_end) + self.state = self.parse_document_content + else: + # Parse the end of the stream. + token = self.get_token() + event = StreamEndEvent(token.start_mark, token.end_mark) + assert not self.states + assert not self.marks + self.state = None + return event + + def parse_document_end(self): + + # Parse the document end. + token = self.peek_token() + start_mark = end_mark = token.start_mark + explicit = False + if self.check_token(DocumentEndToken): + token = self.get_token() + end_mark = token.end_mark + explicit = True + event = DocumentEndEvent(start_mark, end_mark, + explicit=explicit) + + # Prepare the next state. + self.state = self.parse_document_start + + return event + + def parse_document_content(self): + if self.check_token(DirectiveToken, + DocumentStartToken, DocumentEndToken, StreamEndToken): + event = self.process_empty_scalar(self.peek_token().start_mark) + self.state = self.states.pop() + return event + else: + return self.parse_block_node() + + def process_directives(self): + self.yaml_version = None + self.tag_handles = {} + while self.check_token(DirectiveToken): + token = self.get_token() + if token.name == 'YAML': + if self.yaml_version is not None: + raise ParserError(None, None, + "found duplicate YAML directive", token.start_mark) + major, minor = token.value + if major != 1: + raise ParserError(None, None, + "found incompatible YAML document (version 1.* is required)", + token.start_mark) + self.yaml_version = token.value + elif token.name == 'TAG': + handle, prefix = token.value + if handle in self.tag_handles: + raise ParserError(None, None, + "duplicate tag handle %r" % handle, + token.start_mark) + self.tag_handles[handle] = prefix + if self.tag_handles: + value = self.yaml_version, self.tag_handles.copy() + else: + value = self.yaml_version, None + for key in self.DEFAULT_TAGS: + if key not in self.tag_handles: + self.tag_handles[key] = self.DEFAULT_TAGS[key] + return value + + # block_node_or_indentless_sequence ::= ALIAS + # | properties (block_content | indentless_block_sequence)? + # | block_content + # | indentless_block_sequence + # block_node ::= ALIAS + # | properties block_content? + # | block_content + # flow_node ::= ALIAS + # | properties flow_content? + # | flow_content + # properties ::= TAG ANCHOR? | ANCHOR TAG? + # block_content ::= block_collection | flow_collection | SCALAR + # flow_content ::= flow_collection | SCALAR + # block_collection ::= block_sequence | block_mapping + # flow_collection ::= flow_sequence | flow_mapping + + def parse_block_node(self): + return self.parse_node(block=True) + + def parse_flow_node(self): + return self.parse_node() + + def parse_block_node_or_indentless_sequence(self): + return self.parse_node(block=True, indentless_sequence=True) + + def parse_node(self, block=False, indentless_sequence=False): + if self.check_token(AliasToken): + token = self.get_token() + event = AliasEvent(token.value, token.start_mark, token.end_mark) + self.state = self.states.pop() + else: + anchor = None + tag = None + start_mark = end_mark = tag_mark = None + if self.check_token(AnchorToken): + token = self.get_token() + start_mark = token.start_mark + end_mark = token.end_mark + anchor = token.value + if self.check_token(TagToken): + token = self.get_token() + tag_mark = token.start_mark + end_mark = token.end_mark + tag = token.value + elif self.check_token(TagToken): + token = self.get_token() + start_mark = tag_mark = token.start_mark + end_mark = token.end_mark + tag = token.value + if self.check_token(AnchorToken): + token = self.get_token() + end_mark = token.end_mark + anchor = token.value + if tag is not None: + handle, suffix = tag + if handle is not None: + if handle not in self.tag_handles: + raise ParserError("while parsing a node", start_mark, + "found undefined tag handle %r" % handle, + tag_mark) + tag = self.tag_handles[handle]+suffix + else: + tag = suffix + #if tag == '!': + # raise ParserError("while parsing a node", start_mark, + # "found non-specific tag '!'", tag_mark, + # "Please check 'http://pyyaml.org/wiki/YAMLNonSpecificTag' and share your opinion.") + if start_mark is None: + start_mark = end_mark = self.peek_token().start_mark + event = None + implicit = (tag is None or tag == '!') + if indentless_sequence and self.check_token(BlockEntryToken): + end_mark = self.peek_token().end_mark + event = SequenceStartEvent(anchor, tag, implicit, + start_mark, end_mark) + self.state = self.parse_indentless_sequence_entry + else: + if self.check_token(ScalarToken): + token = self.get_token() + end_mark = token.end_mark + if (token.plain and tag is None) or tag == '!': + implicit = (True, False) + elif tag is None: + implicit = (False, True) + else: + implicit = (False, False) + event = ScalarEvent(anchor, tag, implicit, token.value, + start_mark, end_mark, style=token.style) + self.state = self.states.pop() + elif self.check_token(FlowSequenceStartToken): + end_mark = self.peek_token().end_mark + event = SequenceStartEvent(anchor, tag, implicit, + start_mark, end_mark, flow_style=True) + self.state = self.parse_flow_sequence_first_entry + elif self.check_token(FlowMappingStartToken): + end_mark = self.peek_token().end_mark + event = MappingStartEvent(anchor, tag, implicit, + start_mark, end_mark, flow_style=True) + self.state = self.parse_flow_mapping_first_key + elif block and self.check_token(BlockSequenceStartToken): + end_mark = self.peek_token().start_mark + event = SequenceStartEvent(anchor, tag, implicit, + start_mark, end_mark, flow_style=False) + self.state = self.parse_block_sequence_first_entry + elif block and self.check_token(BlockMappingStartToken): + end_mark = self.peek_token().start_mark + event = MappingStartEvent(anchor, tag, implicit, + start_mark, end_mark, flow_style=False) + self.state = self.parse_block_mapping_first_key + elif anchor is not None or tag is not None: + # Empty scalars are allowed even if a tag or an anchor is + # specified. + event = ScalarEvent(anchor, tag, (implicit, False), '', + start_mark, end_mark) + self.state = self.states.pop() + else: + if block: + node = 'block' + else: + node = 'flow' + token = self.peek_token() + raise ParserError("while parsing a %s node" % node, start_mark, + "expected the node content, but found %r" % token.id, + token.start_mark) + return event + + # block_sequence ::= BLOCK-SEQUENCE-START (BLOCK-ENTRY block_node?)* BLOCK-END + + def parse_block_sequence_first_entry(self): + token = self.get_token() + self.marks.append(token.start_mark) + return self.parse_block_sequence_entry() + + def parse_block_sequence_entry(self): + if self.check_token(BlockEntryToken): + token = self.get_token() + if not self.check_token(BlockEntryToken, BlockEndToken): + self.states.append(self.parse_block_sequence_entry) + return self.parse_block_node() + else: + self.state = self.parse_block_sequence_entry + return self.process_empty_scalar(token.end_mark) + if not self.check_token(BlockEndToken): + token = self.peek_token() + raise ParserError("while parsing a block collection", self.marks[-1], + "expected <block end>, but found %r" % token.id, token.start_mark) + token = self.get_token() + event = SequenceEndEvent(token.start_mark, token.end_mark) + self.state = self.states.pop() + self.marks.pop() + return event + + # indentless_sequence ::= (BLOCK-ENTRY block_node?)+ + + def parse_indentless_sequence_entry(self): + if self.check_token(BlockEntryToken): + token = self.get_token() + if not self.check_token(BlockEntryToken, + KeyToken, ValueToken, BlockEndToken): + self.states.append(self.parse_indentless_sequence_entry) + return self.parse_block_node() + else: + self.state = self.parse_indentless_sequence_entry + return self.process_empty_scalar(token.end_mark) + token = self.peek_token() + event = SequenceEndEvent(token.start_mark, token.start_mark) + self.state = self.states.pop() + return event + + # block_mapping ::= BLOCK-MAPPING_START + # ((KEY block_node_or_indentless_sequence?)? + # (VALUE block_node_or_indentless_sequence?)?)* + # BLOCK-END + + def parse_block_mapping_first_key(self): + token = self.get_token() + self.marks.append(token.start_mark) + return self.parse_block_mapping_key() + + def parse_block_mapping_key(self): + if self.check_token(KeyToken): + token = self.get_token() + if not self.check_token(KeyToken, ValueToken, BlockEndToken): + self.states.append(self.parse_block_mapping_value) + return self.parse_block_node_or_indentless_sequence() + else: + self.state = self.parse_block_mapping_value + return self.process_empty_scalar(token.end_mark) + if not self.check_token(BlockEndToken): + token = self.peek_token() + raise ParserError("while parsing a block mapping", self.marks[-1], + "expected <block end>, but found %r" % token.id, token.start_mark) + token = self.get_token() + event = MappingEndEvent(token.start_mark, token.end_mark) + self.state = self.states.pop() + self.marks.pop() + return event + + def parse_block_mapping_value(self): + if self.check_token(ValueToken): + token = self.get_token() + if not self.check_token(KeyToken, ValueToken, BlockEndToken): + self.states.append(self.parse_block_mapping_key) + return self.parse_block_node_or_indentless_sequence() + else: + self.state = self.parse_block_mapping_key + return self.process_empty_scalar(token.end_mark) + else: + self.state = self.parse_block_mapping_key + token = self.peek_token() + return self.process_empty_scalar(token.start_mark) + + # flow_sequence ::= FLOW-SEQUENCE-START + # (flow_sequence_entry FLOW-ENTRY)* + # flow_sequence_entry? + # FLOW-SEQUENCE-END + # flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? + # + # Note that while production rules for both flow_sequence_entry and + # flow_mapping_entry are equal, their interpretations are different. + # For `flow_sequence_entry`, the part `KEY flow_node? (VALUE flow_node?)?` + # generate an inline mapping (set syntax). + + def parse_flow_sequence_first_entry(self): + token = self.get_token() + self.marks.append(token.start_mark) + return self.parse_flow_sequence_entry(first=True) + + def parse_flow_sequence_entry(self, first=False): + if not self.check_token(FlowSequenceEndToken): + if not first: + if self.check_token(FlowEntryToken): + self.get_token() + else: + token = self.peek_token() + raise ParserError("while parsing a flow sequence", self.marks[-1], + "expected ',' or ']', but got %r" % token.id, token.start_mark) + + if self.check_token(KeyToken): + token = self.peek_token() + event = MappingStartEvent(None, None, True, + token.start_mark, token.end_mark, + flow_style=True) + self.state = self.parse_flow_sequence_entry_mapping_key + return event + elif not self.check_token(FlowSequenceEndToken): + self.states.append(self.parse_flow_sequence_entry) + return self.parse_flow_node() + token = self.get_token() + event = SequenceEndEvent(token.start_mark, token.end_mark) + self.state = self.states.pop() + self.marks.pop() + return event + + def parse_flow_sequence_entry_mapping_key(self): + token = self.get_token() + if not self.check_token(ValueToken, + FlowEntryToken, FlowSequenceEndToken): + self.states.append(self.parse_flow_sequence_entry_mapping_value) + return self.parse_flow_node() + else: + self.state = self.parse_flow_sequence_entry_mapping_value + return self.process_empty_scalar(token.end_mark) + + def parse_flow_sequence_entry_mapping_value(self): + if self.check_token(ValueToken): + token = self.get_token() + if not self.check_token(FlowEntryToken, FlowSequenceEndToken): + self.states.append(self.parse_flow_sequence_entry_mapping_end) + return self.parse_flow_node() + else: + self.state = self.parse_flow_sequence_entry_mapping_end + return self.process_empty_scalar(token.end_mark) + else: + self.state = self.parse_flow_sequence_entry_mapping_end + token = self.peek_token() + return self.process_empty_scalar(token.start_mark) + + def parse_flow_sequence_entry_mapping_end(self): + self.state = self.parse_flow_sequence_entry + token = self.peek_token() + return MappingEndEvent(token.start_mark, token.start_mark) + + # flow_mapping ::= FLOW-MAPPING-START + # (flow_mapping_entry FLOW-ENTRY)* + # flow_mapping_entry? + # FLOW-MAPPING-END + # flow_mapping_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? + + def parse_flow_mapping_first_key(self): + token = self.get_token() + self.marks.append(token.start_mark) + return self.parse_flow_mapping_key(first=True) + + def parse_flow_mapping_key(self, first=False): + if not self.check_token(FlowMappingEndToken): + if not first: + if self.check_token(FlowEntryToken): + self.get_token() + else: + token = self.peek_token() + raise ParserError("while parsing a flow mapping", self.marks[-1], + "expected ',' or '}', but got %r" % token.id, token.start_mark) + if self.check_token(KeyToken): + token = self.get_token() + if not self.check_token(ValueToken, + FlowEntryToken, FlowMappingEndToken): + self.states.append(self.parse_flow_mapping_value) + return self.parse_flow_node() + else: + self.state = self.parse_flow_mapping_value + return self.process_empty_scalar(token.end_mark) + elif not self.check_token(FlowMappingEndToken): + self.states.append(self.parse_flow_mapping_empty_value) + return self.parse_flow_node() + token = self.get_token() + event = MappingEndEvent(token.start_mark, token.end_mark) + self.state = self.states.pop() + self.marks.pop() + return event + + def parse_flow_mapping_value(self): + if self.check_token(ValueToken): + token = self.get_token() + if not self.check_token(FlowEntryToken, FlowMappingEndToken): + self.states.append(self.parse_flow_mapping_key) + return self.parse_flow_node() + else: + self.state = self.parse_flow_mapping_key + return self.process_empty_scalar(token.end_mark) + else: + self.state = self.parse_flow_mapping_key + token = self.peek_token() + return self.process_empty_scalar(token.start_mark) + + def parse_flow_mapping_empty_value(self): + self.state = self.parse_flow_mapping_key + return self.process_empty_scalar(self.peek_token().start_mark) + + def process_empty_scalar(self, mark): + return ScalarEvent(None, None, (True, False), '', mark, mark) + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/reader.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/reader.py new file mode 100644 index 0000000000000000000000000000000000000000..774b0219b5932a0ee1c27e637371de5ba8d9cb16 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/reader.py @@ -0,0 +1,185 @@ +# This module contains abstractions for the input stream. You don't have to +# looks further, there are no pretty code. +# +# We define two classes here. +# +# Mark(source, line, column) +# It's just a record and its only use is producing nice error messages. +# Parser does not use it for any other purposes. +# +# Reader(source, data) +# Reader determines the encoding of `data` and converts it to unicode. +# Reader provides the following methods and attributes: +# reader.peek(length=1) - return the next `length` characters +# reader.forward(length=1) - move the current position to `length` characters. +# reader.index - the number of the current character. +# reader.line, stream.column - the line and the column of the current character. + +__all__ = ['Reader', 'ReaderError'] + +from .error import YAMLError, Mark + +import codecs, re + +class ReaderError(YAMLError): + + def __init__(self, name, position, character, encoding, reason): + self.name = name + self.character = character + self.position = position + self.encoding = encoding + self.reason = reason + + def __str__(self): + if isinstance(self.character, bytes): + return "'%s' codec can't decode byte #x%02x: %s\n" \ + " in \"%s\", position %d" \ + % (self.encoding, ord(self.character), self.reason, + self.name, self.position) + else: + return "unacceptable character #x%04x: %s\n" \ + " in \"%s\", position %d" \ + % (self.character, self.reason, + self.name, self.position) + +class Reader(object): + # Reader: + # - determines the data encoding and converts it to a unicode string, + # - checks if characters are in allowed range, + # - adds '\0' to the end. + + # Reader accepts + # - a `bytes` object, + # - a `str` object, + # - a file-like object with its `read` method returning `str`, + # - a file-like object with its `read` method returning `unicode`. + + # Yeah, it's ugly and slow. + + def __init__(self, stream): + self.name = None + self.stream = None + self.stream_pointer = 0 + self.eof = True + self.buffer = '' + self.pointer = 0 + self.raw_buffer = None + self.raw_decode = None + self.encoding = None + self.index = 0 + self.line = 0 + self.column = 0 + if isinstance(stream, str): + self.name = "<unicode string>" + self.check_printable(stream) + self.buffer = stream+'\0' + elif isinstance(stream, bytes): + self.name = "<byte string>" + self.raw_buffer = stream + self.determine_encoding() + else: + self.stream = stream + self.name = getattr(stream, 'name', "<file>") + self.eof = False + self.raw_buffer = None + self.determine_encoding() + + def peek(self, index=0): + try: + return self.buffer[self.pointer+index] + except IndexError: + self.update(index+1) + return self.buffer[self.pointer+index] + + def prefix(self, length=1): + if self.pointer+length >= len(self.buffer): + self.update(length) + return self.buffer[self.pointer:self.pointer+length] + + def forward(self, length=1): + if self.pointer+length+1 >= len(self.buffer): + self.update(length+1) + while length: + ch = self.buffer[self.pointer] + self.pointer += 1 + self.index += 1 + if ch in '\n\x85\u2028\u2029' \ + or (ch == '\r' and self.buffer[self.pointer] != '\n'): + self.line += 1 + self.column = 0 + elif ch != '\uFEFF': + self.column += 1 + length -= 1 + + def get_mark(self): + if self.stream is None: + return Mark(self.name, self.index, self.line, self.column, + self.buffer, self.pointer) + else: + return Mark(self.name, self.index, self.line, self.column, + None, None) + + def determine_encoding(self): + while not self.eof and (self.raw_buffer is None or len(self.raw_buffer) < 2): + self.update_raw() + if isinstance(self.raw_buffer, bytes): + if self.raw_buffer.startswith(codecs.BOM_UTF16_LE): + self.raw_decode = codecs.utf_16_le_decode + self.encoding = 'utf-16-le' + elif self.raw_buffer.startswith(codecs.BOM_UTF16_BE): + self.raw_decode = codecs.utf_16_be_decode + self.encoding = 'utf-16-be' + else: + self.raw_decode = codecs.utf_8_decode + self.encoding = 'utf-8' + self.update(1) + + NON_PRINTABLE = re.compile('[^\x09\x0A\x0D\x20-\x7E\x85\xA0-\uD7FF\uE000-\uFFFD\U00010000-\U0010ffff]') + def check_printable(self, data): + match = self.NON_PRINTABLE.search(data) + if match: + character = match.group() + position = self.index+(len(self.buffer)-self.pointer)+match.start() + raise ReaderError(self.name, position, ord(character), + 'unicode', "special characters are not allowed") + + def update(self, length): + if self.raw_buffer is None: + return + self.buffer = self.buffer[self.pointer:] + self.pointer = 0 + while len(self.buffer) < length: + if not self.eof: + self.update_raw() + if self.raw_decode is not None: + try: + data, converted = self.raw_decode(self.raw_buffer, + 'strict', self.eof) + except UnicodeDecodeError as exc: + character = self.raw_buffer[exc.start] + if self.stream is not None: + position = self.stream_pointer-len(self.raw_buffer)+exc.start + else: + position = exc.start + raise ReaderError(self.name, position, character, + exc.encoding, exc.reason) + else: + data = self.raw_buffer + converted = len(data) + self.check_printable(data) + self.buffer += data + self.raw_buffer = self.raw_buffer[converted:] + if self.eof: + self.buffer += '\0' + self.raw_buffer = None + break + + def update_raw(self, size=4096): + data = self.stream.read(size) + if self.raw_buffer is None: + self.raw_buffer = data + else: + self.raw_buffer += data + self.stream_pointer += len(data) + if not data: + self.eof = True diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/representer.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/representer.py new file mode 100644 index 0000000000000000000000000000000000000000..808ca06dfbd60c9a23eb079151b74a82ef688749 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/representer.py @@ -0,0 +1,389 @@ + +__all__ = ['BaseRepresenter', 'SafeRepresenter', 'Representer', + 'RepresenterError'] + +from .error import * +from .nodes import * + +import datetime, copyreg, types, base64, collections + +class RepresenterError(YAMLError): + pass + +class BaseRepresenter: + + yaml_representers = {} + yaml_multi_representers = {} + + def __init__(self, default_style=None, default_flow_style=False, sort_keys=True): + self.default_style = default_style + self.sort_keys = sort_keys + self.default_flow_style = default_flow_style + self.represented_objects = {} + self.object_keeper = [] + self.alias_key = None + + def represent(self, data): + node = self.represent_data(data) + self.serialize(node) + self.represented_objects = {} + self.object_keeper = [] + self.alias_key = None + + def represent_data(self, data): + if self.ignore_aliases(data): + self.alias_key = None + else: + self.alias_key = id(data) + if self.alias_key is not None: + if self.alias_key in self.represented_objects: + node = self.represented_objects[self.alias_key] + #if node is None: + # raise RepresenterError("recursive objects are not allowed: %r" % data) + return node + #self.represented_objects[alias_key] = None + self.object_keeper.append(data) + data_types = type(data).__mro__ + if data_types[0] in self.yaml_representers: + node = self.yaml_representers[data_types[0]](self, data) + else: + for data_type in data_types: + if data_type in self.yaml_multi_representers: + node = self.yaml_multi_representers[data_type](self, data) + break + else: + if None in self.yaml_multi_representers: + node = self.yaml_multi_representers[None](self, data) + elif None in self.yaml_representers: + node = self.yaml_representers[None](self, data) + else: + node = ScalarNode(None, str(data)) + #if alias_key is not None: + # self.represented_objects[alias_key] = node + return node + + @classmethod + def add_representer(cls, data_type, representer): + if not 'yaml_representers' in cls.__dict__: + cls.yaml_representers = cls.yaml_representers.copy() + cls.yaml_representers[data_type] = representer + + @classmethod + def add_multi_representer(cls, data_type, representer): + if not 'yaml_multi_representers' in cls.__dict__: + cls.yaml_multi_representers = cls.yaml_multi_representers.copy() + cls.yaml_multi_representers[data_type] = representer + + def represent_scalar(self, tag, value, style=None): + if style is None: + style = self.default_style + node = ScalarNode(tag, value, style=style) + if self.alias_key is not None: + self.represented_objects[self.alias_key] = node + return node + + def represent_sequence(self, tag, sequence, flow_style=None): + value = [] + node = SequenceNode(tag, value, flow_style=flow_style) + if self.alias_key is not None: + self.represented_objects[self.alias_key] = node + best_style = True + for item in sequence: + node_item = self.represent_data(item) + if not (isinstance(node_item, ScalarNode) and not node_item.style): + best_style = False + value.append(node_item) + if flow_style is None: + if self.default_flow_style is not None: + node.flow_style = self.default_flow_style + else: + node.flow_style = best_style + return node + + def represent_mapping(self, tag, mapping, flow_style=None): + value = [] + node = MappingNode(tag, value, flow_style=flow_style) + if self.alias_key is not None: + self.represented_objects[self.alias_key] = node + best_style = True + if hasattr(mapping, 'items'): + mapping = list(mapping.items()) + if self.sort_keys: + try: + mapping = sorted(mapping) + except TypeError: + pass + for item_key, item_value in mapping: + node_key = self.represent_data(item_key) + node_value = self.represent_data(item_value) + if not (isinstance(node_key, ScalarNode) and not node_key.style): + best_style = False + if not (isinstance(node_value, ScalarNode) and not node_value.style): + best_style = False + value.append((node_key, node_value)) + if flow_style is None: + if self.default_flow_style is not None: + node.flow_style = self.default_flow_style + else: + node.flow_style = best_style + return node + + def ignore_aliases(self, data): + return False + +class SafeRepresenter(BaseRepresenter): + + def ignore_aliases(self, data): + if data is None: + return True + if isinstance(data, tuple) and data == (): + return True + if isinstance(data, (str, bytes, bool, int, float)): + return True + + def represent_none(self, data): + return self.represent_scalar('tag:yaml.org,2002:null', 'null') + + def represent_str(self, data): + return self.represent_scalar('tag:yaml.org,2002:str', data) + + def represent_binary(self, data): + if hasattr(base64, 'encodebytes'): + data = base64.encodebytes(data).decode('ascii') + else: + data = base64.encodestring(data).decode('ascii') + return self.represent_scalar('tag:yaml.org,2002:binary', data, style='|') + + def represent_bool(self, data): + if data: + value = 'true' + else: + value = 'false' + return self.represent_scalar('tag:yaml.org,2002:bool', value) + + def represent_int(self, data): + return self.represent_scalar('tag:yaml.org,2002:int', str(data)) + + inf_value = 1e300 + while repr(inf_value) != repr(inf_value*inf_value): + inf_value *= inf_value + + def represent_float(self, data): + if data != data or (data == 0.0 and data == 1.0): + value = '.nan' + elif data == self.inf_value: + value = '.inf' + elif data == -self.inf_value: + value = '-.inf' + else: + value = repr(data).lower() + # Note that in some cases `repr(data)` represents a float number + # without the decimal parts. For instance: + # >>> repr(1e17) + # '1e17' + # Unfortunately, this is not a valid float representation according + # to the definition of the `!!float` tag. We fix this by adding + # '.0' before the 'e' symbol. + if '.' not in value and 'e' in value: + value = value.replace('e', '.0e', 1) + return self.represent_scalar('tag:yaml.org,2002:float', value) + + def represent_list(self, data): + #pairs = (len(data) > 0 and isinstance(data, list)) + #if pairs: + # for item in data: + # if not isinstance(item, tuple) or len(item) != 2: + # pairs = False + # break + #if not pairs: + return self.represent_sequence('tag:yaml.org,2002:seq', data) + #value = [] + #for item_key, item_value in data: + # value.append(self.represent_mapping(u'tag:yaml.org,2002:map', + # [(item_key, item_value)])) + #return SequenceNode(u'tag:yaml.org,2002:pairs', value) + + def represent_dict(self, data): + return self.represent_mapping('tag:yaml.org,2002:map', data) + + def represent_set(self, data): + value = {} + for key in data: + value[key] = None + return self.represent_mapping('tag:yaml.org,2002:set', value) + + def represent_date(self, data): + value = data.isoformat() + return self.represent_scalar('tag:yaml.org,2002:timestamp', value) + + def represent_datetime(self, data): + value = data.isoformat(' ') + return self.represent_scalar('tag:yaml.org,2002:timestamp', value) + + def represent_yaml_object(self, tag, data, cls, flow_style=None): + if hasattr(data, '__getstate__'): + state = data.__getstate__() + else: + state = data.__dict__.copy() + return self.represent_mapping(tag, state, flow_style=flow_style) + + def represent_undefined(self, data): + raise RepresenterError("cannot represent an object", data) + +SafeRepresenter.add_representer(type(None), + SafeRepresenter.represent_none) + +SafeRepresenter.add_representer(str, + SafeRepresenter.represent_str) + +SafeRepresenter.add_representer(bytes, + SafeRepresenter.represent_binary) + +SafeRepresenter.add_representer(bool, + SafeRepresenter.represent_bool) + +SafeRepresenter.add_representer(int, + SafeRepresenter.represent_int) + +SafeRepresenter.add_representer(float, + SafeRepresenter.represent_float) + +SafeRepresenter.add_representer(list, + SafeRepresenter.represent_list) + +SafeRepresenter.add_representer(tuple, + SafeRepresenter.represent_list) + +SafeRepresenter.add_representer(dict, + SafeRepresenter.represent_dict) + +SafeRepresenter.add_representer(set, + SafeRepresenter.represent_set) + +SafeRepresenter.add_representer(datetime.date, + SafeRepresenter.represent_date) + +SafeRepresenter.add_representer(datetime.datetime, + SafeRepresenter.represent_datetime) + +SafeRepresenter.add_representer(None, + SafeRepresenter.represent_undefined) + +class Representer(SafeRepresenter): + + def represent_complex(self, data): + if data.imag == 0.0: + data = '%r' % data.real + elif data.real == 0.0: + data = '%rj' % data.imag + elif data.imag > 0: + data = '%r+%rj' % (data.real, data.imag) + else: + data = '%r%rj' % (data.real, data.imag) + return self.represent_scalar('tag:yaml.org,2002:python/complex', data) + + def represent_tuple(self, data): + return self.represent_sequence('tag:yaml.org,2002:python/tuple', data) + + def represent_name(self, data): + name = '%s.%s' % (data.__module__, data.__name__) + return self.represent_scalar('tag:yaml.org,2002:python/name:'+name, '') + + def represent_module(self, data): + return self.represent_scalar( + 'tag:yaml.org,2002:python/module:'+data.__name__, '') + + def represent_object(self, data): + # We use __reduce__ API to save the data. data.__reduce__ returns + # a tuple of length 2-5: + # (function, args, state, listitems, dictitems) + + # For reconstructing, we calls function(*args), then set its state, + # listitems, and dictitems if they are not None. + + # A special case is when function.__name__ == '__newobj__'. In this + # case we create the object with args[0].__new__(*args). + + # Another special case is when __reduce__ returns a string - we don't + # support it. + + # We produce a !!python/object, !!python/object/new or + # !!python/object/apply node. + + cls = type(data) + if cls in copyreg.dispatch_table: + reduce = copyreg.dispatch_table[cls](data) + elif hasattr(data, '__reduce_ex__'): + reduce = data.__reduce_ex__(2) + elif hasattr(data, '__reduce__'): + reduce = data.__reduce__() + else: + raise RepresenterError("cannot represent an object", data) + reduce = (list(reduce)+[None]*5)[:5] + function, args, state, listitems, dictitems = reduce + args = list(args) + if state is None: + state = {} + if listitems is not None: + listitems = list(listitems) + if dictitems is not None: + dictitems = dict(dictitems) + if function.__name__ == '__newobj__': + function = args[0] + args = args[1:] + tag = 'tag:yaml.org,2002:python/object/new:' + newobj = True + else: + tag = 'tag:yaml.org,2002:python/object/apply:' + newobj = False + function_name = '%s.%s' % (function.__module__, function.__name__) + if not args and not listitems and not dictitems \ + and isinstance(state, dict) and newobj: + return self.represent_mapping( + 'tag:yaml.org,2002:python/object:'+function_name, state) + if not listitems and not dictitems \ + and isinstance(state, dict) and not state: + return self.represent_sequence(tag+function_name, args) + value = {} + if args: + value['args'] = args + if state or not isinstance(state, dict): + value['state'] = state + if listitems: + value['listitems'] = listitems + if dictitems: + value['dictitems'] = dictitems + return self.represent_mapping(tag+function_name, value) + + def represent_ordered_dict(self, data): + # Provide uniform representation across different Python versions. + data_type = type(data) + tag = 'tag:yaml.org,2002:python/object/apply:%s.%s' \ + % (data_type.__module__, data_type.__name__) + items = [[key, value] for key, value in data.items()] + return self.represent_sequence(tag, [items]) + +Representer.add_representer(complex, + Representer.represent_complex) + +Representer.add_representer(tuple, + Representer.represent_tuple) + +Representer.add_multi_representer(type, + Representer.represent_name) + +Representer.add_representer(collections.OrderedDict, + Representer.represent_ordered_dict) + +Representer.add_representer(types.FunctionType, + Representer.represent_name) + +Representer.add_representer(types.BuiltinFunctionType, + Representer.represent_name) + +Representer.add_representer(types.ModuleType, + Representer.represent_module) + +Representer.add_multi_representer(object, + Representer.represent_object) + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/resolver.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/resolver.py new file mode 100644 index 0000000000000000000000000000000000000000..3522bdaaf6358110b608f4e6503b9d314c82d887 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/resolver.py @@ -0,0 +1,227 @@ + +__all__ = ['BaseResolver', 'Resolver'] + +from .error import * +from .nodes import * + +import re + +class ResolverError(YAMLError): + pass + +class BaseResolver: + + DEFAULT_SCALAR_TAG = 'tag:yaml.org,2002:str' + DEFAULT_SEQUENCE_TAG = 'tag:yaml.org,2002:seq' + DEFAULT_MAPPING_TAG = 'tag:yaml.org,2002:map' + + yaml_implicit_resolvers = {} + yaml_path_resolvers = {} + + def __init__(self): + self.resolver_exact_paths = [] + self.resolver_prefix_paths = [] + + @classmethod + def add_implicit_resolver(cls, tag, regexp, first): + if not 'yaml_implicit_resolvers' in cls.__dict__: + implicit_resolvers = {} + for key in cls.yaml_implicit_resolvers: + implicit_resolvers[key] = cls.yaml_implicit_resolvers[key][:] + cls.yaml_implicit_resolvers = implicit_resolvers + if first is None: + first = [None] + for ch in first: + cls.yaml_implicit_resolvers.setdefault(ch, []).append((tag, regexp)) + + @classmethod + def add_path_resolver(cls, tag, path, kind=None): + # Note: `add_path_resolver` is experimental. The API could be changed. + # `new_path` is a pattern that is matched against the path from the + # root to the node that is being considered. `node_path` elements are + # tuples `(node_check, index_check)`. `node_check` is a node class: + # `ScalarNode`, `SequenceNode`, `MappingNode` or `None`. `None` + # matches any kind of a node. `index_check` could be `None`, a boolean + # value, a string value, or a number. `None` and `False` match against + # any _value_ of sequence and mapping nodes. `True` matches against + # any _key_ of a mapping node. A string `index_check` matches against + # a mapping value that corresponds to a scalar key which content is + # equal to the `index_check` value. An integer `index_check` matches + # against a sequence value with the index equal to `index_check`. + if not 'yaml_path_resolvers' in cls.__dict__: + cls.yaml_path_resolvers = cls.yaml_path_resolvers.copy() + new_path = [] + for element in path: + if isinstance(element, (list, tuple)): + if len(element) == 2: + node_check, index_check = element + elif len(element) == 1: + node_check = element[0] + index_check = True + else: + raise ResolverError("Invalid path element: %s" % element) + else: + node_check = None + index_check = element + if node_check is str: + node_check = ScalarNode + elif node_check is list: + node_check = SequenceNode + elif node_check is dict: + node_check = MappingNode + elif node_check not in [ScalarNode, SequenceNode, MappingNode] \ + and not isinstance(node_check, str) \ + and node_check is not None: + raise ResolverError("Invalid node checker: %s" % node_check) + if not isinstance(index_check, (str, int)) \ + and index_check is not None: + raise ResolverError("Invalid index checker: %s" % index_check) + new_path.append((node_check, index_check)) + if kind is str: + kind = ScalarNode + elif kind is list: + kind = SequenceNode + elif kind is dict: + kind = MappingNode + elif kind not in [ScalarNode, SequenceNode, MappingNode] \ + and kind is not None: + raise ResolverError("Invalid node kind: %s" % kind) + cls.yaml_path_resolvers[tuple(new_path), kind] = tag + + def descend_resolver(self, current_node, current_index): + if not self.yaml_path_resolvers: + return + exact_paths = {} + prefix_paths = [] + if current_node: + depth = len(self.resolver_prefix_paths) + for path, kind in self.resolver_prefix_paths[-1]: + if self.check_resolver_prefix(depth, path, kind, + current_node, current_index): + if len(path) > depth: + prefix_paths.append((path, kind)) + else: + exact_paths[kind] = self.yaml_path_resolvers[path, kind] + else: + for path, kind in self.yaml_path_resolvers: + if not path: + exact_paths[kind] = self.yaml_path_resolvers[path, kind] + else: + prefix_paths.append((path, kind)) + self.resolver_exact_paths.append(exact_paths) + self.resolver_prefix_paths.append(prefix_paths) + + def ascend_resolver(self): + if not self.yaml_path_resolvers: + return + self.resolver_exact_paths.pop() + self.resolver_prefix_paths.pop() + + def check_resolver_prefix(self, depth, path, kind, + current_node, current_index): + node_check, index_check = path[depth-1] + if isinstance(node_check, str): + if current_node.tag != node_check: + return + elif node_check is not None: + if not isinstance(current_node, node_check): + return + if index_check is True and current_index is not None: + return + if (index_check is False or index_check is None) \ + and current_index is None: + return + if isinstance(index_check, str): + if not (isinstance(current_index, ScalarNode) + and index_check == current_index.value): + return + elif isinstance(index_check, int) and not isinstance(index_check, bool): + if index_check != current_index: + return + return True + + def resolve(self, kind, value, implicit): + if kind is ScalarNode and implicit[0]: + if value == '': + resolvers = self.yaml_implicit_resolvers.get('', []) + else: + resolvers = self.yaml_implicit_resolvers.get(value[0], []) + wildcard_resolvers = self.yaml_implicit_resolvers.get(None, []) + for tag, regexp in resolvers + wildcard_resolvers: + if regexp.match(value): + return tag + implicit = implicit[1] + if self.yaml_path_resolvers: + exact_paths = self.resolver_exact_paths[-1] + if kind in exact_paths: + return exact_paths[kind] + if None in exact_paths: + return exact_paths[None] + if kind is ScalarNode: + return self.DEFAULT_SCALAR_TAG + elif kind is SequenceNode: + return self.DEFAULT_SEQUENCE_TAG + elif kind is MappingNode: + return self.DEFAULT_MAPPING_TAG + +class Resolver(BaseResolver): + pass + +Resolver.add_implicit_resolver( + 'tag:yaml.org,2002:bool', + re.compile(r'''^(?:yes|Yes|YES|no|No|NO + |true|True|TRUE|false|False|FALSE + |on|On|ON|off|Off|OFF)$''', re.X), + list('yYnNtTfFoO')) + +Resolver.add_implicit_resolver( + 'tag:yaml.org,2002:float', + re.compile(r'''^(?:[-+]?(?:[0-9][0-9_]*)\.[0-9_]*(?:[eE][-+][0-9]+)? + |\.[0-9][0-9_]*(?:[eE][-+][0-9]+)? + |[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]* + |[-+]?\.(?:inf|Inf|INF) + |\.(?:nan|NaN|NAN))$''', re.X), + list('-+0123456789.')) + +Resolver.add_implicit_resolver( + 'tag:yaml.org,2002:int', + re.compile(r'''^(?:[-+]?0b[0-1_]+ + |[-+]?0[0-7_]+ + |[-+]?(?:0|[1-9][0-9_]*) + |[-+]?0x[0-9a-fA-F_]+ + |[-+]?[1-9][0-9_]*(?::[0-5]?[0-9])+)$''', re.X), + list('-+0123456789')) + +Resolver.add_implicit_resolver( + 'tag:yaml.org,2002:merge', + re.compile(r'^(?:<<)$'), + ['<']) + +Resolver.add_implicit_resolver( + 'tag:yaml.org,2002:null', + re.compile(r'''^(?: ~ + |null|Null|NULL + | )$''', re.X), + ['~', 'n', 'N', '']) + +Resolver.add_implicit_resolver( + 'tag:yaml.org,2002:timestamp', + re.compile(r'''^(?:[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9] + |[0-9][0-9][0-9][0-9] -[0-9][0-9]? -[0-9][0-9]? + (?:[Tt]|[ \t]+)[0-9][0-9]? + :[0-9][0-9] :[0-9][0-9] (?:\.[0-9]*)? + (?:[ \t]*(?:Z|[-+][0-9][0-9]?(?::[0-9][0-9])?))?)$''', re.X), + list('0123456789')) + +Resolver.add_implicit_resolver( + 'tag:yaml.org,2002:value', + re.compile(r'^(?:=)$'), + ['=']) + +# The following resolver is only for documentation purposes. It cannot work +# because plain scalars cannot start with '!', '&', or '*'. +Resolver.add_implicit_resolver( + 'tag:yaml.org,2002:yaml', + re.compile(r'^(?:!|&|\*)$'), + list('!&*')) + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/scanner.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/scanner.py new file mode 100644 index 0000000000000000000000000000000000000000..de925b07f1eaec33c9c305a8a69f9eb7ac5983c5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/scanner.py @@ -0,0 +1,1435 @@ + +# Scanner produces tokens of the following types: +# STREAM-START +# STREAM-END +# DIRECTIVE(name, value) +# DOCUMENT-START +# DOCUMENT-END +# BLOCK-SEQUENCE-START +# BLOCK-MAPPING-START +# BLOCK-END +# FLOW-SEQUENCE-START +# FLOW-MAPPING-START +# FLOW-SEQUENCE-END +# FLOW-MAPPING-END +# BLOCK-ENTRY +# FLOW-ENTRY +# KEY +# VALUE +# ALIAS(value) +# ANCHOR(value) +# TAG(value) +# SCALAR(value, plain, style) +# +# Read comments in the Scanner code for more details. +# + +__all__ = ['Scanner', 'ScannerError'] + +from .error import MarkedYAMLError +from .tokens import * + +class ScannerError(MarkedYAMLError): + pass + +class SimpleKey: + # See below simple keys treatment. + + def __init__(self, token_number, required, index, line, column, mark): + self.token_number = token_number + self.required = required + self.index = index + self.line = line + self.column = column + self.mark = mark + +class Scanner: + + def __init__(self): + """Initialize the scanner.""" + # It is assumed that Scanner and Reader will have a common descendant. + # Reader do the dirty work of checking for BOM and converting the + # input data to Unicode. It also adds NUL to the end. + # + # Reader supports the following methods + # self.peek(i=0) # peek the next i-th character + # self.prefix(l=1) # peek the next l characters + # self.forward(l=1) # read the next l characters and move the pointer. + + # Had we reached the end of the stream? + self.done = False + + # The number of unclosed '{' and '['. `flow_level == 0` means block + # context. + self.flow_level = 0 + + # List of processed tokens that are not yet emitted. + self.tokens = [] + + # Add the STREAM-START token. + self.fetch_stream_start() + + # Number of tokens that were emitted through the `get_token` method. + self.tokens_taken = 0 + + # The current indentation level. + self.indent = -1 + + # Past indentation levels. + self.indents = [] + + # Variables related to simple keys treatment. + + # A simple key is a key that is not denoted by the '?' indicator. + # Example of simple keys: + # --- + # block simple key: value + # ? not a simple key: + # : { flow simple key: value } + # We emit the KEY token before all keys, so when we find a potential + # simple key, we try to locate the corresponding ':' indicator. + # Simple keys should be limited to a single line and 1024 characters. + + # Can a simple key start at the current position? A simple key may + # start: + # - at the beginning of the line, not counting indentation spaces + # (in block context), + # - after '{', '[', ',' (in the flow context), + # - after '?', ':', '-' (in the block context). + # In the block context, this flag also signifies if a block collection + # may start at the current position. + self.allow_simple_key = True + + # Keep track of possible simple keys. This is a dictionary. The key + # is `flow_level`; there can be no more that one possible simple key + # for each level. The value is a SimpleKey record: + # (token_number, required, index, line, column, mark) + # A simple key may start with ALIAS, ANCHOR, TAG, SCALAR(flow), + # '[', or '{' tokens. + self.possible_simple_keys = {} + + # Public methods. + + def check_token(self, *choices): + # Check if the next token is one of the given types. + while self.need_more_tokens(): + self.fetch_more_tokens() + if self.tokens: + if not choices: + return True + for choice in choices: + if isinstance(self.tokens[0], choice): + return True + return False + + def peek_token(self): + # Return the next token, but do not delete if from the queue. + # Return None if no more tokens. + while self.need_more_tokens(): + self.fetch_more_tokens() + if self.tokens: + return self.tokens[0] + else: + return None + + def get_token(self): + # Return the next token. + while self.need_more_tokens(): + self.fetch_more_tokens() + if self.tokens: + self.tokens_taken += 1 + return self.tokens.pop(0) + + # Private methods. + + def need_more_tokens(self): + if self.done: + return False + if not self.tokens: + return True + # The current token may be a potential simple key, so we + # need to look further. + self.stale_possible_simple_keys() + if self.next_possible_simple_key() == self.tokens_taken: + return True + + def fetch_more_tokens(self): + + # Eat whitespaces and comments until we reach the next token. + self.scan_to_next_token() + + # Remove obsolete possible simple keys. + self.stale_possible_simple_keys() + + # Compare the current indentation and column. It may add some tokens + # and decrease the current indentation level. + self.unwind_indent(self.column) + + # Peek the next character. + ch = self.peek() + + # Is it the end of stream? + if ch == '\0': + return self.fetch_stream_end() + + # Is it a directive? + if ch == '%' and self.check_directive(): + return self.fetch_directive() + + # Is it the document start? + if ch == '-' and self.check_document_start(): + return self.fetch_document_start() + + # Is it the document end? + if ch == '.' and self.check_document_end(): + return self.fetch_document_end() + + # TODO: support for BOM within a stream. + #if ch == '\uFEFF': + # return self.fetch_bom() <-- issue BOMToken + + # Note: the order of the following checks is NOT significant. + + # Is it the flow sequence start indicator? + if ch == '[': + return self.fetch_flow_sequence_start() + + # Is it the flow mapping start indicator? + if ch == '{': + return self.fetch_flow_mapping_start() + + # Is it the flow sequence end indicator? + if ch == ']': + return self.fetch_flow_sequence_end() + + # Is it the flow mapping end indicator? + if ch == '}': + return self.fetch_flow_mapping_end() + + # Is it the flow entry indicator? + if ch == ',': + return self.fetch_flow_entry() + + # Is it the block entry indicator? + if ch == '-' and self.check_block_entry(): + return self.fetch_block_entry() + + # Is it the key indicator? + if ch == '?' and self.check_key(): + return self.fetch_key() + + # Is it the value indicator? + if ch == ':' and self.check_value(): + return self.fetch_value() + + # Is it an alias? + if ch == '*': + return self.fetch_alias() + + # Is it an anchor? + if ch == '&': + return self.fetch_anchor() + + # Is it a tag? + if ch == '!': + return self.fetch_tag() + + # Is it a literal scalar? + if ch == '|' and not self.flow_level: + return self.fetch_literal() + + # Is it a folded scalar? + if ch == '>' and not self.flow_level: + return self.fetch_folded() + + # Is it a single quoted scalar? + if ch == '\'': + return self.fetch_single() + + # Is it a double quoted scalar? + if ch == '\"': + return self.fetch_double() + + # It must be a plain scalar then. + if self.check_plain(): + return self.fetch_plain() + + # No? It's an error. Let's produce a nice error message. + raise ScannerError("while scanning for the next token", None, + "found character %r that cannot start any token" % ch, + self.get_mark()) + + # Simple keys treatment. + + def next_possible_simple_key(self): + # Return the number of the nearest possible simple key. Actually we + # don't need to loop through the whole dictionary. We may replace it + # with the following code: + # if not self.possible_simple_keys: + # return None + # return self.possible_simple_keys[ + # min(self.possible_simple_keys.keys())].token_number + min_token_number = None + for level in self.possible_simple_keys: + key = self.possible_simple_keys[level] + if min_token_number is None or key.token_number < min_token_number: + min_token_number = key.token_number + return min_token_number + + def stale_possible_simple_keys(self): + # Remove entries that are no longer possible simple keys. According to + # the YAML specification, simple keys + # - should be limited to a single line, + # - should be no longer than 1024 characters. + # Disabling this procedure will allow simple keys of any length and + # height (may cause problems if indentation is broken though). + for level in list(self.possible_simple_keys): + key = self.possible_simple_keys[level] + if key.line != self.line \ + or self.index-key.index > 1024: + if key.required: + raise ScannerError("while scanning a simple key", key.mark, + "could not find expected ':'", self.get_mark()) + del self.possible_simple_keys[level] + + def save_possible_simple_key(self): + # The next token may start a simple key. We check if it's possible + # and save its position. This function is called for + # ALIAS, ANCHOR, TAG, SCALAR(flow), '[', and '{'. + + # Check if a simple key is required at the current position. + required = not self.flow_level and self.indent == self.column + + # The next token might be a simple key. Let's save it's number and + # position. + if self.allow_simple_key: + self.remove_possible_simple_key() + token_number = self.tokens_taken+len(self.tokens) + key = SimpleKey(token_number, required, + self.index, self.line, self.column, self.get_mark()) + self.possible_simple_keys[self.flow_level] = key + + def remove_possible_simple_key(self): + # Remove the saved possible key position at the current flow level. + if self.flow_level in self.possible_simple_keys: + key = self.possible_simple_keys[self.flow_level] + + if key.required: + raise ScannerError("while scanning a simple key", key.mark, + "could not find expected ':'", self.get_mark()) + + del self.possible_simple_keys[self.flow_level] + + # Indentation functions. + + def unwind_indent(self, column): + + ## In flow context, tokens should respect indentation. + ## Actually the condition should be `self.indent >= column` according to + ## the spec. But this condition will prohibit intuitively correct + ## constructions such as + ## key : { + ## } + #if self.flow_level and self.indent > column: + # raise ScannerError(None, None, + # "invalid indentation or unclosed '[' or '{'", + # self.get_mark()) + + # In the flow context, indentation is ignored. We make the scanner less + # restrictive then specification requires. + if self.flow_level: + return + + # In block context, we may need to issue the BLOCK-END tokens. + while self.indent > column: + mark = self.get_mark() + self.indent = self.indents.pop() + self.tokens.append(BlockEndToken(mark, mark)) + + def add_indent(self, column): + # Check if we need to increase indentation. + if self.indent < column: + self.indents.append(self.indent) + self.indent = column + return True + return False + + # Fetchers. + + def fetch_stream_start(self): + # We always add STREAM-START as the first token and STREAM-END as the + # last token. + + # Read the token. + mark = self.get_mark() + + # Add STREAM-START. + self.tokens.append(StreamStartToken(mark, mark, + encoding=self.encoding)) + + + def fetch_stream_end(self): + + # Set the current indentation to -1. + self.unwind_indent(-1) + + # Reset simple keys. + self.remove_possible_simple_key() + self.allow_simple_key = False + self.possible_simple_keys = {} + + # Read the token. + mark = self.get_mark() + + # Add STREAM-END. + self.tokens.append(StreamEndToken(mark, mark)) + + # The steam is finished. + self.done = True + + def fetch_directive(self): + + # Set the current indentation to -1. + self.unwind_indent(-1) + + # Reset simple keys. + self.remove_possible_simple_key() + self.allow_simple_key = False + + # Scan and add DIRECTIVE. + self.tokens.append(self.scan_directive()) + + def fetch_document_start(self): + self.fetch_document_indicator(DocumentStartToken) + + def fetch_document_end(self): + self.fetch_document_indicator(DocumentEndToken) + + def fetch_document_indicator(self, TokenClass): + + # Set the current indentation to -1. + self.unwind_indent(-1) + + # Reset simple keys. Note that there could not be a block collection + # after '---'. + self.remove_possible_simple_key() + self.allow_simple_key = False + + # Add DOCUMENT-START or DOCUMENT-END. + start_mark = self.get_mark() + self.forward(3) + end_mark = self.get_mark() + self.tokens.append(TokenClass(start_mark, end_mark)) + + def fetch_flow_sequence_start(self): + self.fetch_flow_collection_start(FlowSequenceStartToken) + + def fetch_flow_mapping_start(self): + self.fetch_flow_collection_start(FlowMappingStartToken) + + def fetch_flow_collection_start(self, TokenClass): + + # '[' and '{' may start a simple key. + self.save_possible_simple_key() + + # Increase the flow level. + self.flow_level += 1 + + # Simple keys are allowed after '[' and '{'. + self.allow_simple_key = True + + # Add FLOW-SEQUENCE-START or FLOW-MAPPING-START. + start_mark = self.get_mark() + self.forward() + end_mark = self.get_mark() + self.tokens.append(TokenClass(start_mark, end_mark)) + + def fetch_flow_sequence_end(self): + self.fetch_flow_collection_end(FlowSequenceEndToken) + + def fetch_flow_mapping_end(self): + self.fetch_flow_collection_end(FlowMappingEndToken) + + def fetch_flow_collection_end(self, TokenClass): + + # Reset possible simple key on the current level. + self.remove_possible_simple_key() + + # Decrease the flow level. + self.flow_level -= 1 + + # No simple keys after ']' or '}'. + self.allow_simple_key = False + + # Add FLOW-SEQUENCE-END or FLOW-MAPPING-END. + start_mark = self.get_mark() + self.forward() + end_mark = self.get_mark() + self.tokens.append(TokenClass(start_mark, end_mark)) + + def fetch_flow_entry(self): + + # Simple keys are allowed after ','. + self.allow_simple_key = True + + # Reset possible simple key on the current level. + self.remove_possible_simple_key() + + # Add FLOW-ENTRY. + start_mark = self.get_mark() + self.forward() + end_mark = self.get_mark() + self.tokens.append(FlowEntryToken(start_mark, end_mark)) + + def fetch_block_entry(self): + + # Block context needs additional checks. + if not self.flow_level: + + # Are we allowed to start a new entry? + if not self.allow_simple_key: + raise ScannerError(None, None, + "sequence entries are not allowed here", + self.get_mark()) + + # We may need to add BLOCK-SEQUENCE-START. + if self.add_indent(self.column): + mark = self.get_mark() + self.tokens.append(BlockSequenceStartToken(mark, mark)) + + # It's an error for the block entry to occur in the flow context, + # but we let the parser detect this. + else: + pass + + # Simple keys are allowed after '-'. + self.allow_simple_key = True + + # Reset possible simple key on the current level. + self.remove_possible_simple_key() + + # Add BLOCK-ENTRY. + start_mark = self.get_mark() + self.forward() + end_mark = self.get_mark() + self.tokens.append(BlockEntryToken(start_mark, end_mark)) + + def fetch_key(self): + + # Block context needs additional checks. + if not self.flow_level: + + # Are we allowed to start a key (not necessary a simple)? + if not self.allow_simple_key: + raise ScannerError(None, None, + "mapping keys are not allowed here", + self.get_mark()) + + # We may need to add BLOCK-MAPPING-START. + if self.add_indent(self.column): + mark = self.get_mark() + self.tokens.append(BlockMappingStartToken(mark, mark)) + + # Simple keys are allowed after '?' in the block context. + self.allow_simple_key = not self.flow_level + + # Reset possible simple key on the current level. + self.remove_possible_simple_key() + + # Add KEY. + start_mark = self.get_mark() + self.forward() + end_mark = self.get_mark() + self.tokens.append(KeyToken(start_mark, end_mark)) + + def fetch_value(self): + + # Do we determine a simple key? + if self.flow_level in self.possible_simple_keys: + + # Add KEY. + key = self.possible_simple_keys[self.flow_level] + del self.possible_simple_keys[self.flow_level] + self.tokens.insert(key.token_number-self.tokens_taken, + KeyToken(key.mark, key.mark)) + + # If this key starts a new block mapping, we need to add + # BLOCK-MAPPING-START. + if not self.flow_level: + if self.add_indent(key.column): + self.tokens.insert(key.token_number-self.tokens_taken, + BlockMappingStartToken(key.mark, key.mark)) + + # There cannot be two simple keys one after another. + self.allow_simple_key = False + + # It must be a part of a complex key. + else: + + # Block context needs additional checks. + # (Do we really need them? They will be caught by the parser + # anyway.) + if not self.flow_level: + + # We are allowed to start a complex value if and only if + # we can start a simple key. + if not self.allow_simple_key: + raise ScannerError(None, None, + "mapping values are not allowed here", + self.get_mark()) + + # If this value starts a new block mapping, we need to add + # BLOCK-MAPPING-START. It will be detected as an error later by + # the parser. + if not self.flow_level: + if self.add_indent(self.column): + mark = self.get_mark() + self.tokens.append(BlockMappingStartToken(mark, mark)) + + # Simple keys are allowed after ':' in the block context. + self.allow_simple_key = not self.flow_level + + # Reset possible simple key on the current level. + self.remove_possible_simple_key() + + # Add VALUE. + start_mark = self.get_mark() + self.forward() + end_mark = self.get_mark() + self.tokens.append(ValueToken(start_mark, end_mark)) + + def fetch_alias(self): + + # ALIAS could be a simple key. + self.save_possible_simple_key() + + # No simple keys after ALIAS. + self.allow_simple_key = False + + # Scan and add ALIAS. + self.tokens.append(self.scan_anchor(AliasToken)) + + def fetch_anchor(self): + + # ANCHOR could start a simple key. + self.save_possible_simple_key() + + # No simple keys after ANCHOR. + self.allow_simple_key = False + + # Scan and add ANCHOR. + self.tokens.append(self.scan_anchor(AnchorToken)) + + def fetch_tag(self): + + # TAG could start a simple key. + self.save_possible_simple_key() + + # No simple keys after TAG. + self.allow_simple_key = False + + # Scan and add TAG. + self.tokens.append(self.scan_tag()) + + def fetch_literal(self): + self.fetch_block_scalar(style='|') + + def fetch_folded(self): + self.fetch_block_scalar(style='>') + + def fetch_block_scalar(self, style): + + # A simple key may follow a block scalar. + self.allow_simple_key = True + + # Reset possible simple key on the current level. + self.remove_possible_simple_key() + + # Scan and add SCALAR. + self.tokens.append(self.scan_block_scalar(style)) + + def fetch_single(self): + self.fetch_flow_scalar(style='\'') + + def fetch_double(self): + self.fetch_flow_scalar(style='"') + + def fetch_flow_scalar(self, style): + + # A flow scalar could be a simple key. + self.save_possible_simple_key() + + # No simple keys after flow scalars. + self.allow_simple_key = False + + # Scan and add SCALAR. + self.tokens.append(self.scan_flow_scalar(style)) + + def fetch_plain(self): + + # A plain scalar could be a simple key. + self.save_possible_simple_key() + + # No simple keys after plain scalars. But note that `scan_plain` will + # change this flag if the scan is finished at the beginning of the + # line. + self.allow_simple_key = False + + # Scan and add SCALAR. May change `allow_simple_key`. + self.tokens.append(self.scan_plain()) + + # Checkers. + + def check_directive(self): + + # DIRECTIVE: ^ '%' ... + # The '%' indicator is already checked. + if self.column == 0: + return True + + def check_document_start(self): + + # DOCUMENT-START: ^ '---' (' '|'\n') + if self.column == 0: + if self.prefix(3) == '---' \ + and self.peek(3) in '\0 \t\r\n\x85\u2028\u2029': + return True + + def check_document_end(self): + + # DOCUMENT-END: ^ '...' (' '|'\n') + if self.column == 0: + if self.prefix(3) == '...' \ + and self.peek(3) in '\0 \t\r\n\x85\u2028\u2029': + return True + + def check_block_entry(self): + + # BLOCK-ENTRY: '-' (' '|'\n') + return self.peek(1) in '\0 \t\r\n\x85\u2028\u2029' + + def check_key(self): + + # KEY(flow context): '?' + if self.flow_level: + return True + + # KEY(block context): '?' (' '|'\n') + else: + return self.peek(1) in '\0 \t\r\n\x85\u2028\u2029' + + def check_value(self): + + # VALUE(flow context): ':' + if self.flow_level: + return True + + # VALUE(block context): ':' (' '|'\n') + else: + return self.peek(1) in '\0 \t\r\n\x85\u2028\u2029' + + def check_plain(self): + + # A plain scalar may start with any non-space character except: + # '-', '?', ':', ',', '[', ']', '{', '}', + # '#', '&', '*', '!', '|', '>', '\'', '\"', + # '%', '@', '`'. + # + # It may also start with + # '-', '?', ':' + # if it is followed by a non-space character. + # + # Note that we limit the last rule to the block context (except the + # '-' character) because we want the flow context to be space + # independent. + ch = self.peek() + return ch not in '\0 \t\r\n\x85\u2028\u2029-?:,[]{}#&*!|>\'\"%@`' \ + or (self.peek(1) not in '\0 \t\r\n\x85\u2028\u2029' + and (ch == '-' or (not self.flow_level and ch in '?:'))) + + # Scanners. + + def scan_to_next_token(self): + # We ignore spaces, line breaks and comments. + # If we find a line break in the block context, we set the flag + # `allow_simple_key` on. + # The byte order mark is stripped if it's the first character in the + # stream. We do not yet support BOM inside the stream as the + # specification requires. Any such mark will be considered as a part + # of the document. + # + # TODO: We need to make tab handling rules more sane. A good rule is + # Tabs cannot precede tokens + # BLOCK-SEQUENCE-START, BLOCK-MAPPING-START, BLOCK-END, + # KEY(block), VALUE(block), BLOCK-ENTRY + # So the checking code is + # if <TAB>: + # self.allow_simple_keys = False + # We also need to add the check for `allow_simple_keys == True` to + # `unwind_indent` before issuing BLOCK-END. + # Scanners for block, flow, and plain scalars need to be modified. + + if self.index == 0 and self.peek() == '\uFEFF': + self.forward() + found = False + while not found: + while self.peek() == ' ': + self.forward() + if self.peek() == '#': + while self.peek() not in '\0\r\n\x85\u2028\u2029': + self.forward() + if self.scan_line_break(): + if not self.flow_level: + self.allow_simple_key = True + else: + found = True + + def scan_directive(self): + # See the specification for details. + start_mark = self.get_mark() + self.forward() + name = self.scan_directive_name(start_mark) + value = None + if name == 'YAML': + value = self.scan_yaml_directive_value(start_mark) + end_mark = self.get_mark() + elif name == 'TAG': + value = self.scan_tag_directive_value(start_mark) + end_mark = self.get_mark() + else: + end_mark = self.get_mark() + while self.peek() not in '\0\r\n\x85\u2028\u2029': + self.forward() + self.scan_directive_ignored_line(start_mark) + return DirectiveToken(name, value, start_mark, end_mark) + + def scan_directive_name(self, start_mark): + # See the specification for details. + length = 0 + ch = self.peek(length) + while '0' <= ch <= '9' or 'A' <= ch <= 'Z' or 'a' <= ch <= 'z' \ + or ch in '-_': + length += 1 + ch = self.peek(length) + if not length: + raise ScannerError("while scanning a directive", start_mark, + "expected alphabetic or numeric character, but found %r" + % ch, self.get_mark()) + value = self.prefix(length) + self.forward(length) + ch = self.peek() + if ch not in '\0 \r\n\x85\u2028\u2029': + raise ScannerError("while scanning a directive", start_mark, + "expected alphabetic or numeric character, but found %r" + % ch, self.get_mark()) + return value + + def scan_yaml_directive_value(self, start_mark): + # See the specification for details. + while self.peek() == ' ': + self.forward() + major = self.scan_yaml_directive_number(start_mark) + if self.peek() != '.': + raise ScannerError("while scanning a directive", start_mark, + "expected a digit or '.', but found %r" % self.peek(), + self.get_mark()) + self.forward() + minor = self.scan_yaml_directive_number(start_mark) + if self.peek() not in '\0 \r\n\x85\u2028\u2029': + raise ScannerError("while scanning a directive", start_mark, + "expected a digit or ' ', but found %r" % self.peek(), + self.get_mark()) + return (major, minor) + + def scan_yaml_directive_number(self, start_mark): + # See the specification for details. + ch = self.peek() + if not ('0' <= ch <= '9'): + raise ScannerError("while scanning a directive", start_mark, + "expected a digit, but found %r" % ch, self.get_mark()) + length = 0 + while '0' <= self.peek(length) <= '9': + length += 1 + value = int(self.prefix(length)) + self.forward(length) + return value + + def scan_tag_directive_value(self, start_mark): + # See the specification for details. + while self.peek() == ' ': + self.forward() + handle = self.scan_tag_directive_handle(start_mark) + while self.peek() == ' ': + self.forward() + prefix = self.scan_tag_directive_prefix(start_mark) + return (handle, prefix) + + def scan_tag_directive_handle(self, start_mark): + # See the specification for details. + value = self.scan_tag_handle('directive', start_mark) + ch = self.peek() + if ch != ' ': + raise ScannerError("while scanning a directive", start_mark, + "expected ' ', but found %r" % ch, self.get_mark()) + return value + + def scan_tag_directive_prefix(self, start_mark): + # See the specification for details. + value = self.scan_tag_uri('directive', start_mark) + ch = self.peek() + if ch not in '\0 \r\n\x85\u2028\u2029': + raise ScannerError("while scanning a directive", start_mark, + "expected ' ', but found %r" % ch, self.get_mark()) + return value + + def scan_directive_ignored_line(self, start_mark): + # See the specification for details. + while self.peek() == ' ': + self.forward() + if self.peek() == '#': + while self.peek() not in '\0\r\n\x85\u2028\u2029': + self.forward() + ch = self.peek() + if ch not in '\0\r\n\x85\u2028\u2029': + raise ScannerError("while scanning a directive", start_mark, + "expected a comment or a line break, but found %r" + % ch, self.get_mark()) + self.scan_line_break() + + def scan_anchor(self, TokenClass): + # The specification does not restrict characters for anchors and + # aliases. This may lead to problems, for instance, the document: + # [ *alias, value ] + # can be interpreted in two ways, as + # [ "value" ] + # and + # [ *alias , "value" ] + # Therefore we restrict aliases to numbers and ASCII letters. + start_mark = self.get_mark() + indicator = self.peek() + if indicator == '*': + name = 'alias' + else: + name = 'anchor' + self.forward() + length = 0 + ch = self.peek(length) + while '0' <= ch <= '9' or 'A' <= ch <= 'Z' or 'a' <= ch <= 'z' \ + or ch in '-_': + length += 1 + ch = self.peek(length) + if not length: + raise ScannerError("while scanning an %s" % name, start_mark, + "expected alphabetic or numeric character, but found %r" + % ch, self.get_mark()) + value = self.prefix(length) + self.forward(length) + ch = self.peek() + if ch not in '\0 \t\r\n\x85\u2028\u2029?:,]}%@`': + raise ScannerError("while scanning an %s" % name, start_mark, + "expected alphabetic or numeric character, but found %r" + % ch, self.get_mark()) + end_mark = self.get_mark() + return TokenClass(value, start_mark, end_mark) + + def scan_tag(self): + # See the specification for details. + start_mark = self.get_mark() + ch = self.peek(1) + if ch == '<': + handle = None + self.forward(2) + suffix = self.scan_tag_uri('tag', start_mark) + if self.peek() != '>': + raise ScannerError("while parsing a tag", start_mark, + "expected '>', but found %r" % self.peek(), + self.get_mark()) + self.forward() + elif ch in '\0 \t\r\n\x85\u2028\u2029': + handle = None + suffix = '!' + self.forward() + else: + length = 1 + use_handle = False + while ch not in '\0 \r\n\x85\u2028\u2029': + if ch == '!': + use_handle = True + break + length += 1 + ch = self.peek(length) + handle = '!' + if use_handle: + handle = self.scan_tag_handle('tag', start_mark) + else: + handle = '!' + self.forward() + suffix = self.scan_tag_uri('tag', start_mark) + ch = self.peek() + if ch not in '\0 \r\n\x85\u2028\u2029': + raise ScannerError("while scanning a tag", start_mark, + "expected ' ', but found %r" % ch, self.get_mark()) + value = (handle, suffix) + end_mark = self.get_mark() + return TagToken(value, start_mark, end_mark) + + def scan_block_scalar(self, style): + # See the specification for details. + + if style == '>': + folded = True + else: + folded = False + + chunks = [] + start_mark = self.get_mark() + + # Scan the header. + self.forward() + chomping, increment = self.scan_block_scalar_indicators(start_mark) + self.scan_block_scalar_ignored_line(start_mark) + + # Determine the indentation level and go to the first non-empty line. + min_indent = self.indent+1 + if min_indent < 1: + min_indent = 1 + if increment is None: + breaks, max_indent, end_mark = self.scan_block_scalar_indentation() + indent = max(min_indent, max_indent) + else: + indent = min_indent+increment-1 + breaks, end_mark = self.scan_block_scalar_breaks(indent) + line_break = '' + + # Scan the inner part of the block scalar. + while self.column == indent and self.peek() != '\0': + chunks.extend(breaks) + leading_non_space = self.peek() not in ' \t' + length = 0 + while self.peek(length) not in '\0\r\n\x85\u2028\u2029': + length += 1 + chunks.append(self.prefix(length)) + self.forward(length) + line_break = self.scan_line_break() + breaks, end_mark = self.scan_block_scalar_breaks(indent) + if self.column == indent and self.peek() != '\0': + + # Unfortunately, folding rules are ambiguous. + # + # This is the folding according to the specification: + + if folded and line_break == '\n' \ + and leading_non_space and self.peek() not in ' \t': + if not breaks: + chunks.append(' ') + else: + chunks.append(line_break) + + # This is Clark Evans's interpretation (also in the spec + # examples): + # + #if folded and line_break == '\n': + # if not breaks: + # if self.peek() not in ' \t': + # chunks.append(' ') + # else: + # chunks.append(line_break) + #else: + # chunks.append(line_break) + else: + break + + # Chomp the tail. + if chomping is not False: + chunks.append(line_break) + if chomping is True: + chunks.extend(breaks) + + # We are done. + return ScalarToken(''.join(chunks), False, start_mark, end_mark, + style) + + def scan_block_scalar_indicators(self, start_mark): + # See the specification for details. + chomping = None + increment = None + ch = self.peek() + if ch in '+-': + if ch == '+': + chomping = True + else: + chomping = False + self.forward() + ch = self.peek() + if ch in '0123456789': + increment = int(ch) + if increment == 0: + raise ScannerError("while scanning a block scalar", start_mark, + "expected indentation indicator in the range 1-9, but found 0", + self.get_mark()) + self.forward() + elif ch in '0123456789': + increment = int(ch) + if increment == 0: + raise ScannerError("while scanning a block scalar", start_mark, + "expected indentation indicator in the range 1-9, but found 0", + self.get_mark()) + self.forward() + ch = self.peek() + if ch in '+-': + if ch == '+': + chomping = True + else: + chomping = False + self.forward() + ch = self.peek() + if ch not in '\0 \r\n\x85\u2028\u2029': + raise ScannerError("while scanning a block scalar", start_mark, + "expected chomping or indentation indicators, but found %r" + % ch, self.get_mark()) + return chomping, increment + + def scan_block_scalar_ignored_line(self, start_mark): + # See the specification for details. + while self.peek() == ' ': + self.forward() + if self.peek() == '#': + while self.peek() not in '\0\r\n\x85\u2028\u2029': + self.forward() + ch = self.peek() + if ch not in '\0\r\n\x85\u2028\u2029': + raise ScannerError("while scanning a block scalar", start_mark, + "expected a comment or a line break, but found %r" % ch, + self.get_mark()) + self.scan_line_break() + + def scan_block_scalar_indentation(self): + # See the specification for details. + chunks = [] + max_indent = 0 + end_mark = self.get_mark() + while self.peek() in ' \r\n\x85\u2028\u2029': + if self.peek() != ' ': + chunks.append(self.scan_line_break()) + end_mark = self.get_mark() + else: + self.forward() + if self.column > max_indent: + max_indent = self.column + return chunks, max_indent, end_mark + + def scan_block_scalar_breaks(self, indent): + # See the specification for details. + chunks = [] + end_mark = self.get_mark() + while self.column < indent and self.peek() == ' ': + self.forward() + while self.peek() in '\r\n\x85\u2028\u2029': + chunks.append(self.scan_line_break()) + end_mark = self.get_mark() + while self.column < indent and self.peek() == ' ': + self.forward() + return chunks, end_mark + + def scan_flow_scalar(self, style): + # See the specification for details. + # Note that we loose indentation rules for quoted scalars. Quoted + # scalars don't need to adhere indentation because " and ' clearly + # mark the beginning and the end of them. Therefore we are less + # restrictive then the specification requires. We only need to check + # that document separators are not included in scalars. + if style == '"': + double = True + else: + double = False + chunks = [] + start_mark = self.get_mark() + quote = self.peek() + self.forward() + chunks.extend(self.scan_flow_scalar_non_spaces(double, start_mark)) + while self.peek() != quote: + chunks.extend(self.scan_flow_scalar_spaces(double, start_mark)) + chunks.extend(self.scan_flow_scalar_non_spaces(double, start_mark)) + self.forward() + end_mark = self.get_mark() + return ScalarToken(''.join(chunks), False, start_mark, end_mark, + style) + + ESCAPE_REPLACEMENTS = { + '0': '\0', + 'a': '\x07', + 'b': '\x08', + 't': '\x09', + '\t': '\x09', + 'n': '\x0A', + 'v': '\x0B', + 'f': '\x0C', + 'r': '\x0D', + 'e': '\x1B', + ' ': '\x20', + '\"': '\"', + '\\': '\\', + '/': '/', + 'N': '\x85', + '_': '\xA0', + 'L': '\u2028', + 'P': '\u2029', + } + + ESCAPE_CODES = { + 'x': 2, + 'u': 4, + 'U': 8, + } + + def scan_flow_scalar_non_spaces(self, double, start_mark): + # See the specification for details. + chunks = [] + while True: + length = 0 + while self.peek(length) not in '\'\"\\\0 \t\r\n\x85\u2028\u2029': + length += 1 + if length: + chunks.append(self.prefix(length)) + self.forward(length) + ch = self.peek() + if not double and ch == '\'' and self.peek(1) == '\'': + chunks.append('\'') + self.forward(2) + elif (double and ch == '\'') or (not double and ch in '\"\\'): + chunks.append(ch) + self.forward() + elif double and ch == '\\': + self.forward() + ch = self.peek() + if ch in self.ESCAPE_REPLACEMENTS: + chunks.append(self.ESCAPE_REPLACEMENTS[ch]) + self.forward() + elif ch in self.ESCAPE_CODES: + length = self.ESCAPE_CODES[ch] + self.forward() + for k in range(length): + if self.peek(k) not in '0123456789ABCDEFabcdef': + raise ScannerError("while scanning a double-quoted scalar", start_mark, + "expected escape sequence of %d hexadecimal numbers, but found %r" % + (length, self.peek(k)), self.get_mark()) + code = int(self.prefix(length), 16) + chunks.append(chr(code)) + self.forward(length) + elif ch in '\r\n\x85\u2028\u2029': + self.scan_line_break() + chunks.extend(self.scan_flow_scalar_breaks(double, start_mark)) + else: + raise ScannerError("while scanning a double-quoted scalar", start_mark, + "found unknown escape character %r" % ch, self.get_mark()) + else: + return chunks + + def scan_flow_scalar_spaces(self, double, start_mark): + # See the specification for details. + chunks = [] + length = 0 + while self.peek(length) in ' \t': + length += 1 + whitespaces = self.prefix(length) + self.forward(length) + ch = self.peek() + if ch == '\0': + raise ScannerError("while scanning a quoted scalar", start_mark, + "found unexpected end of stream", self.get_mark()) + elif ch in '\r\n\x85\u2028\u2029': + line_break = self.scan_line_break() + breaks = self.scan_flow_scalar_breaks(double, start_mark) + if line_break != '\n': + chunks.append(line_break) + elif not breaks: + chunks.append(' ') + chunks.extend(breaks) + else: + chunks.append(whitespaces) + return chunks + + def scan_flow_scalar_breaks(self, double, start_mark): + # See the specification for details. + chunks = [] + while True: + # Instead of checking indentation, we check for document + # separators. + prefix = self.prefix(3) + if (prefix == '---' or prefix == '...') \ + and self.peek(3) in '\0 \t\r\n\x85\u2028\u2029': + raise ScannerError("while scanning a quoted scalar", start_mark, + "found unexpected document separator", self.get_mark()) + while self.peek() in ' \t': + self.forward() + if self.peek() in '\r\n\x85\u2028\u2029': + chunks.append(self.scan_line_break()) + else: + return chunks + + def scan_plain(self): + # See the specification for details. + # We add an additional restriction for the flow context: + # plain scalars in the flow context cannot contain ',' or '?'. + # We also keep track of the `allow_simple_key` flag here. + # Indentation rules are loosed for the flow context. + chunks = [] + start_mark = self.get_mark() + end_mark = start_mark + indent = self.indent+1 + # We allow zero indentation for scalars, but then we need to check for + # document separators at the beginning of the line. + #if indent == 0: + # indent = 1 + spaces = [] + while True: + length = 0 + if self.peek() == '#': + break + while True: + ch = self.peek(length) + if ch in '\0 \t\r\n\x85\u2028\u2029' \ + or (ch == ':' and + self.peek(length+1) in '\0 \t\r\n\x85\u2028\u2029' + + (u',[]{}' if self.flow_level else u''))\ + or (self.flow_level and ch in ',?[]{}'): + break + length += 1 + if length == 0: + break + self.allow_simple_key = False + chunks.extend(spaces) + chunks.append(self.prefix(length)) + self.forward(length) + end_mark = self.get_mark() + spaces = self.scan_plain_spaces(indent, start_mark) + if not spaces or self.peek() == '#' \ + or (not self.flow_level and self.column < indent): + break + return ScalarToken(''.join(chunks), True, start_mark, end_mark) + + def scan_plain_spaces(self, indent, start_mark): + # See the specification for details. + # The specification is really confusing about tabs in plain scalars. + # We just forbid them completely. Do not use tabs in YAML! + chunks = [] + length = 0 + while self.peek(length) in ' ': + length += 1 + whitespaces = self.prefix(length) + self.forward(length) + ch = self.peek() + if ch in '\r\n\x85\u2028\u2029': + line_break = self.scan_line_break() + self.allow_simple_key = True + prefix = self.prefix(3) + if (prefix == '---' or prefix == '...') \ + and self.peek(3) in '\0 \t\r\n\x85\u2028\u2029': + return + breaks = [] + while self.peek() in ' \r\n\x85\u2028\u2029': + if self.peek() == ' ': + self.forward() + else: + breaks.append(self.scan_line_break()) + prefix = self.prefix(3) + if (prefix == '---' or prefix == '...') \ + and self.peek(3) in '\0 \t\r\n\x85\u2028\u2029': + return + if line_break != '\n': + chunks.append(line_break) + elif not breaks: + chunks.append(' ') + chunks.extend(breaks) + elif whitespaces: + chunks.append(whitespaces) + return chunks + + def scan_tag_handle(self, name, start_mark): + # See the specification for details. + # For some strange reasons, the specification does not allow '_' in + # tag handles. I have allowed it anyway. + ch = self.peek() + if ch != '!': + raise ScannerError("while scanning a %s" % name, start_mark, + "expected '!', but found %r" % ch, self.get_mark()) + length = 1 + ch = self.peek(length) + if ch != ' ': + while '0' <= ch <= '9' or 'A' <= ch <= 'Z' or 'a' <= ch <= 'z' \ + or ch in '-_': + length += 1 + ch = self.peek(length) + if ch != '!': + self.forward(length) + raise ScannerError("while scanning a %s" % name, start_mark, + "expected '!', but found %r" % ch, self.get_mark()) + length += 1 + value = self.prefix(length) + self.forward(length) + return value + + def scan_tag_uri(self, name, start_mark): + # See the specification for details. + # Note: we do not check if URI is well-formed. + chunks = [] + length = 0 + ch = self.peek(length) + while '0' <= ch <= '9' or 'A' <= ch <= 'Z' or 'a' <= ch <= 'z' \ + or ch in '-;/?:@&=+$,_.!~*\'()[]%': + if ch == '%': + chunks.append(self.prefix(length)) + self.forward(length) + length = 0 + chunks.append(self.scan_uri_escapes(name, start_mark)) + else: + length += 1 + ch = self.peek(length) + if length: + chunks.append(self.prefix(length)) + self.forward(length) + length = 0 + if not chunks: + raise ScannerError("while parsing a %s" % name, start_mark, + "expected URI, but found %r" % ch, self.get_mark()) + return ''.join(chunks) + + def scan_uri_escapes(self, name, start_mark): + # See the specification for details. + codes = [] + mark = self.get_mark() + while self.peek() == '%': + self.forward() + for k in range(2): + if self.peek(k) not in '0123456789ABCDEFabcdef': + raise ScannerError("while scanning a %s" % name, start_mark, + "expected URI escape sequence of 2 hexadecimal numbers, but found %r" + % self.peek(k), self.get_mark()) + codes.append(int(self.prefix(2), 16)) + self.forward(2) + try: + value = bytes(codes).decode('utf-8') + except UnicodeDecodeError as exc: + raise ScannerError("while scanning a %s" % name, start_mark, str(exc), mark) + return value + + def scan_line_break(self): + # Transforms: + # '\r\n' : '\n' + # '\r' : '\n' + # '\n' : '\n' + # '\x85' : '\n' + # '\u2028' : '\u2028' + # '\u2029 : '\u2029' + # default : '' + ch = self.peek() + if ch in '\r\n\x85': + if self.prefix(2) == '\r\n': + self.forward(2) + else: + self.forward() + return '\n' + elif ch in '\u2028\u2029': + self.forward() + return ch + return '' diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/serializer.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/serializer.py new file mode 100644 index 0000000000000000000000000000000000000000..fe911e67ae7a739abb491fbbc6834b9c37bbda4b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/serializer.py @@ -0,0 +1,111 @@ + +__all__ = ['Serializer', 'SerializerError'] + +from .error import YAMLError +from .events import * +from .nodes import * + +class SerializerError(YAMLError): + pass + +class Serializer: + + ANCHOR_TEMPLATE = 'id%03d' + + def __init__(self, encoding=None, + explicit_start=None, explicit_end=None, version=None, tags=None): + self.use_encoding = encoding + self.use_explicit_start = explicit_start + self.use_explicit_end = explicit_end + self.use_version = version + self.use_tags = tags + self.serialized_nodes = {} + self.anchors = {} + self.last_anchor_id = 0 + self.closed = None + + def open(self): + if self.closed is None: + self.emit(StreamStartEvent(encoding=self.use_encoding)) + self.closed = False + elif self.closed: + raise SerializerError("serializer is closed") + else: + raise SerializerError("serializer is already opened") + + def close(self): + if self.closed is None: + raise SerializerError("serializer is not opened") + elif not self.closed: + self.emit(StreamEndEvent()) + self.closed = True + + #def __del__(self): + # self.close() + + def serialize(self, node): + if self.closed is None: + raise SerializerError("serializer is not opened") + elif self.closed: + raise SerializerError("serializer is closed") + self.emit(DocumentStartEvent(explicit=self.use_explicit_start, + version=self.use_version, tags=self.use_tags)) + self.anchor_node(node) + self.serialize_node(node, None, None) + self.emit(DocumentEndEvent(explicit=self.use_explicit_end)) + self.serialized_nodes = {} + self.anchors = {} + self.last_anchor_id = 0 + + def anchor_node(self, node): + if node in self.anchors: + if self.anchors[node] is None: + self.anchors[node] = self.generate_anchor(node) + else: + self.anchors[node] = None + if isinstance(node, SequenceNode): + for item in node.value: + self.anchor_node(item) + elif isinstance(node, MappingNode): + for key, value in node.value: + self.anchor_node(key) + self.anchor_node(value) + + def generate_anchor(self, node): + self.last_anchor_id += 1 + return self.ANCHOR_TEMPLATE % self.last_anchor_id + + def serialize_node(self, node, parent, index): + alias = self.anchors[node] + if node in self.serialized_nodes: + self.emit(AliasEvent(alias)) + else: + self.serialized_nodes[node] = True + self.descend_resolver(parent, index) + if isinstance(node, ScalarNode): + detected_tag = self.resolve(ScalarNode, node.value, (True, False)) + default_tag = self.resolve(ScalarNode, node.value, (False, True)) + implicit = (node.tag == detected_tag), (node.tag == default_tag) + self.emit(ScalarEvent(alias, node.tag, implicit, node.value, + style=node.style)) + elif isinstance(node, SequenceNode): + implicit = (node.tag + == self.resolve(SequenceNode, node.value, True)) + self.emit(SequenceStartEvent(alias, node.tag, implicit, + flow_style=node.flow_style)) + index = 0 + for item in node.value: + self.serialize_node(item, node, index) + index += 1 + self.emit(SequenceEndEvent()) + elif isinstance(node, MappingNode): + implicit = (node.tag + == self.resolve(MappingNode, node.value, True)) + self.emit(MappingStartEvent(alias, node.tag, implicit, + flow_style=node.flow_style)) + for key, value in node.value: + self.serialize_node(key, node, None) + self.serialize_node(value, node, key) + self.emit(MappingEndEvent()) + self.ascend_resolver() + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/tokens.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/tokens.py new file mode 100644 index 0000000000000000000000000000000000000000..4d0b48a394ac8c019b401516a12f688df361cf90 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-6.0.3-pyh7db6752_1/site-packages/yaml/tokens.py @@ -0,0 +1,104 @@ + +class Token(object): + def __init__(self, start_mark, end_mark): + self.start_mark = start_mark + self.end_mark = end_mark + def __repr__(self): + attributes = [key for key in self.__dict__ + if not key.endswith('_mark')] + attributes.sort() + arguments = ', '.join(['%s=%r' % (key, getattr(self, key)) + for key in attributes]) + return '%s(%s)' % (self.__class__.__name__, arguments) + +#class BOMToken(Token): +# id = '<byte order mark>' + +class DirectiveToken(Token): + id = '<directive>' + def __init__(self, name, value, start_mark, end_mark): + self.name = name + self.value = value + self.start_mark = start_mark + self.end_mark = end_mark + +class DocumentStartToken(Token): + id = '<document start>' + +class DocumentEndToken(Token): + id = '<document end>' + +class StreamStartToken(Token): + id = '<stream start>' + def __init__(self, start_mark=None, end_mark=None, + encoding=None): + self.start_mark = start_mark + self.end_mark = end_mark + self.encoding = encoding + +class StreamEndToken(Token): + id = '<stream end>' + +class BlockSequenceStartToken(Token): + id = '<block sequence start>' + +class BlockMappingStartToken(Token): + id = '<block mapping start>' + +class BlockEndToken(Token): + id = '<block end>' + +class FlowSequenceStartToken(Token): + id = '[' + +class FlowMappingStartToken(Token): + id = '{' + +class FlowSequenceEndToken(Token): + id = ']' + +class FlowMappingEndToken(Token): + id = '}' + +class KeyToken(Token): + id = '?' + +class ValueToken(Token): + id = ':' + +class BlockEntryToken(Token): + id = '-' + +class FlowEntryToken(Token): + id = ',' + +class AliasToken(Token): + id = '<alias>' + def __init__(self, value, start_mark, end_mark): + self.value = value + self.start_mark = start_mark + self.end_mark = end_mark + +class AnchorToken(Token): + id = '<anchor>' + def __init__(self, value, start_mark, end_mark): + self.value = value + self.start_mark = start_mark + self.end_mark = end_mark + +class TagToken(Token): + id = '<tag>' + def __init__(self, value, start_mark, end_mark): + self.value = value + self.start_mark = start_mark + self.end_mark = end_mark + +class ScalarToken(Token): + id = '<scalar>' + def __init__(self, value, plain, start_mark, end_mark, style=None): + self.value = value + self.plain = plain + self.start_mark = start_mark + self.end_mark = end_mark + self.style = style + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/about.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/about.json new file mode 100644 index 0000000000000000000000000000000000000000..c1a4f6209f08a0220d7c6987d32b02ec76a8292e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/about.json @@ -0,0 +1,214 @@ +{ + "channels": [ + "https://conda.anaconda.org/conda-forge" + ], + "conda_build_version": "25.4.2", + "conda_version": "25.3.1", + "env_vars": { + "CIO_TEST": "<not set>" + }, + "extra": { + "copy_test_source_files": true, + "final": true, + "flow_run_id": "azure_20250514.1.1", + "recipe-maintainers": [ + "ocefpaf" + ], + "remote_url": "https://github.com/conda-forge/pyyaml-env-tag-feedstock", + "sha": "0fb0debbc36ed2767f019c7d1e97c8412494e89e" + }, + "home": "https://github.com/waylan/pyyaml-env-tag", + "identifiers": [], + "keywords": [], + "license": "MIT", + "license_file": "LICENSE", + "root_pkgs": [ + "wheel 0.45.1 pyhd8ed1ab_1", + "krb5 1.21.3 h659f571_0", + "pkginfo 1.12.1.2 pyhd8ed1ab_0", + "requests 2.32.3 pyhd8ed1ab_1", + "libdeflate 1.23 h86f0d12_0", + "pyyaml 6.0.2 py312h178313f_2", + "libxcrypt 4.4.36 hd590300_1", + "su-exec 0.2 h166bdaf_1003", + "typer 0.15.3 pyhf21524f_0", + "libarchive 3.7.7 h75ea233_4", + "python 3.12.10 h9e4cc4f_0_cpython", + "python-libarchive-c 5.2 pyh29332c3_0", + "libgcc 15.1.0 h767d61c_2", + "nlohmann_json 3.11.3 he02047a_1", + "annotated-types 0.7.0 pyhd8ed1ab_1", + "reproc-cpp 14.2.5.post0 h5888daf_0", + "charset-normalizer 3.4.2 pyhd8ed1ab_0", + "soupsieve 2.7 pyhd8ed1ab_0", + "pytz 2025.2 pyhd8ed1ab_0", + "pydantic-settings 2.9.1 pyh3cfb1c2_0", + "traitlets 5.14.3 pyhd8ed1ab_1", + "pydantic 2.11.4 pyh3cfb1c2_0", + "conda 25.3.1 py312h7900ff3_1", + "anaconda-client 1.13.0 pyh29332c3_1", + "libexpat 2.7.0 h5888daf_0", + "truststore 0.10.1 pyh29332c3_0", + "pkgutil-resolve-name 1.3.10 pyhd8ed1ab_2", + "conda-index 0.6.0 pyhd8ed1ab_0", + "setuptools 80.1.0 pyhff2d567_0", + "requests-toolbelt 1.0.0 pyhd8ed1ab_1", + "yaml 0.2.5 h7f98852_2", + "conda-package-streaming 0.11.0 pyhd8ed1ab_1", + "tk 8.6.13 noxft_h4845f30_101", + "nbformat 5.10.4 pyhd8ed1ab_1", + "anaconda-cli-base 0.5.2 pyhd8ed1ab_0", + "psutil 7.0.0 py312h66e93f0_0", + "importlib_resources 6.5.2 pyhd8ed1ab_0", + "mbedtls 3.5.1 h5888daf_1", + "menuinst 2.2.0 py312h7900ff3_0", + "libmambapy 2.1.1 py312h07448e0_0", + "idna 3.10 pyhd8ed1ab_1", + "xorg-libxau 1.0.12 hb9d3cd8_0", + "zstd 1.5.7 hb8e6e7a_2", + "xz-tools 5.8.1 hb9d3cd8_1", + "icu 75.1 he02047a_0", + "hpack 4.1.0 pyhd8ed1ab_0", + "pthread-stubs 0.4 hb9d3cd8_1002", + "python-dotenv 1.1.0 pyh29332c3_1", + "pycosat 0.6.6 py312h66e93f0_2", + "archspec 0.2.5 pyhd8ed1ab_0", + "colorama 0.4.6 pyhd8ed1ab_1", + "beautifulsoup4 4.13.4 pyha770c72_0", + "patch 2.7.6 h7f98852_1002", + "ncurses 6.5 h2d0b736_3", + "liblzma-devel 5.8.1 hb9d3cd8_1", + "python-dateutil 2.9.0.post0 pyhff2d567_1", + "conda-build 25.4.2 py312h7900ff3_0", + "mdurl 0.1.2 pyhd8ed1ab_1", + "lzo 2.10 hd590300_1001", + "evalidate 2.0.5 pyhe01879c_0", + "ruamel.yaml.clib 0.2.8 py312h66e93f0_1", + "frozendict 2.4.6 py312h66e93f0_0", + "perl 5.32.1 7_hd590300_perl5", + "libstdcxx-ng 15.1.0 h4852527_2", + "typer-slim 0.15.3 pyh29332c3_0", + "referencing 0.36.2 pyh29332c3_0", + "libffi 3.4.6 h2dba641_1", + "libnsl 2.0.1 hd590300_0", + "jsonschema-specifications 2025.4.1 pyh29332c3_0", + "zipp 3.21.0 pyhd8ed1ab_1", + "lcms2 2.17 h717163a_0", + "cpp-expected 1.1.0 hff21bea_1", + "typer-slim-standard 0.15.3 h1a15894_0", + "certifi 2025.4.26 pyhd8ed1ab_0", + "libpng 1.6.47 h943b412_0", + "libnghttp2 1.64.0 h161d5f1_0", + "reproc 14.2.5.post0 hb9d3cd8_0", + "conda-libmamba-solver 25.4.0 pyhd8ed1ab_0", + "libgomp 15.1.0 h767d61c_2", + "markupsafe 3.0.2 py312h178313f_1", + "keyutils 1.6.1 h166bdaf_0", + "brotli-python 1.1.0 py312h2ec8cdc_2", + "shellingham 1.5.4 pyhd8ed1ab_1", + "more-itertools 10.7.0 pyhd8ed1ab_0", + "pcre2 10.44 hc749103_2", + "xorg-libxdmcp 1.1.5 hb9d3cd8_0", + "pydantic-core 2.33.2 py312h680f630_0", + "six 1.17.0 pyhd8ed1ab_0", + "libssh2 1.11.1 hcf80075_0", + "fmt 11.1.4 h07f6e7f_1", + "rpds-py 0.24.0 py312h3b7be25_0", + "c-ares 1.34.5 hb9d3cd8_0", + "libmamba 2.1.1 h430c389_0", + "python-fastjsonschema 2.21.1 pyhd8ed1ab_0", + "click 8.1.8 pyh707e725_0", + "libgcc-ng 15.1.0 h69a702a_2", + "pybind11-abi 4 hd8ed1ab_3", + "msgpack-python 1.1.0 py312h68727a3_0", + "jsonschema 4.23.0 pyhd8ed1ab_1", + "ld_impl_linux-64 2.43 h712a8e2_4", + "_libgcc_mutex 0.1 conda_forge", + "pysocks 1.7.1 pyha55dd90_7", + "h2 4.2.0 pyhd8ed1ab_0", + "conda-package-handling 2.4.0 pyh7900ff3_2", + "libfreetype6 2.13.3 h48d6fc4_1", + "typing_extensions 4.13.2 pyh29332c3_0", + "tqdm 4.67.1 pyhd8ed1ab_1", + "boltons 24.0.0 pyhd8ed1ab_1", + "libcurl 8.13.0 h332b0f4_0", + "_openmp_mutex 4.5 2_gnu", + "ripgrep 14.1.1 h8fae777_1", + "libwebp-base 1.5.0 h851e524_0", + "jupyter_core 5.7.2 pyh31011fe_1", + "packaging 25.0 pyh29332c3_1", + "python_abi 3.12 7_cp312", + "typing-inspection 0.4.0 pyhd8ed1ab_0", + "jinja2 3.1.6 pyhd8ed1ab_0", + "libfreetype 2.13.3 ha770c72_1", + "simdjson 3.12.3 h84d6215_0", + "libstdcxx 15.1.0 h8f9b012_2", + "urllib3 2.4.0 pyhd8ed1ab_0", + "libxml2 2.13.8 h4bc477f_0", + "libiconv 1.18 h4ce23a2_1", + "typing-extensions 4.13.2 h0e9735f_0", + "libuuid 2.38.1 h0b41bf4_0", + "libtiff 4.7.0 hd9ff511_4", + "ca-certificates 2025.4.26 hbd8a1cb_0", + "zstandard 0.23.0 py312h66e93f0_2", + "openssl 3.5.0 h7b32b05_1", + "patchelf 0.17.2 h58526e2_0", + "attrs 25.3.0 pyh71513ae_0", + "liblief 0.16.4 h5888daf_0", + "ruamel.yaml 0.18.10 py312h66e93f0_0", + "lz4-c 1.10.0 h5888daf_1", + "tini 0.19.0 h166bdaf_1", + "libev 4.33 hd590300_2", + "rich 14.0.0 pyh29332c3_0", + "jsonpatch 1.33 pyhd8ed1ab_1", + "bzip2 1.0.8 h4bc722e_7", + "readline 8.2 h8c095d6_2", + "readchar 4.2.0 pyhd8ed1ab_1", + "filelock 3.18.0 pyhd8ed1ab_0", + "py-lief 0.16.4 py312h2ec8cdc_0", + "jsonpointer 3.0.0 py312h7900ff3_1", + "libsqlite 3.49.2 hee588c1_0", + "git 2.49.0 pl5321h59d505e_0", + "cffi 1.17.1 py312h06ac9bb_0", + "pip 25.1.1 pyh8b19718_0", + "xz 5.8.1 hbcc6ac9_1", + "libxcb 1.17.0 h8a09558_0", + "tomli 2.2.1 pyhd8ed1ab_1", + "platformdirs 4.3.8 pyhe01879c_0", + "distro 1.9.0 pyhd8ed1ab_1", + "xz-gpl-tools 5.8.1 hbcc6ac9_1", + "libsolv 0.7.32 h7955e40_2", + "markdown-it-py 3.0.0 pyhd8ed1ab_1", + "lerc 4.0.0 h0aef613_1", + "hyperframe 6.1.0 pyhd8ed1ab_0", + "defusedxml 0.7.1 pyhd8ed1ab_0", + "mamba 2.1.1 had4a41a_0", + "openjpeg 2.5.3 h5fbd93e_0", + "chardet 5.2.0 pyhd8ed1ab_3", + "tzdata 2025b h78e105d_0", + "liblzma 5.8.1 hb9d3cd8_1", + "pygments 2.19.1 pyhd8ed1ab_0", + "libzlib 1.3.1 hb9d3cd8_2", + "pycparser 2.22 pyh29332c3_1", + "yaml-cpp 0.8.0 h59595ed_0", + "libjpeg-turbo 3.1.0 hb9d3cd8_0", + "pillow 11.2.1 py312h80c1187_0", + "libedit 3.1.20250104 pl5321h7949ede_0", + "pluggy 1.5.0 pyhd8ed1ab_1", + "rattler-build-conda-compat 1.4.3 pyhd8ed1ab_0", + "conda-forge-ci-setup 4.18.0 py312hb3d6910_100", + "wrapt 1.17.2 py312h66e93f0_0", + "rattler-build 0.41.0 h159367c_0", + "oras-py 0.1.14 pyhd8ed1ab_0", + "jq 1.7.1 hd590300_0", + "conda-env 2.6.0 1", + "conda-forge-metadata 0.11.0 pyhd8ed1ab_1", + "oniguruma 6.9.10 hb9d3cd8_0", + "shyaml 0.6.2 pyhd3deb0d_0", + "deprecated 1.2.18 pyhd8ed1ab_0", + "joblib 1.5.0 pyhd8ed1ab_0", + "conda-oci-mirror 0.2.3 pyhd8ed1ab_0" + ], + "summary": "A custom YAML tag for referencing environment variables in YAML files.", + "tags": [] +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/files b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/files new file mode 100644 index 0000000000000000000000000000000000000000..c392380fe65f58048c1c129ba7c764d3357a5704 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/files @@ -0,0 +1,9 @@ +site-packages/pyyaml_env_tag-1.1.dist-info/INSTALLER +site-packages/pyyaml_env_tag-1.1.dist-info/METADATA +site-packages/pyyaml_env_tag-1.1.dist-info/RECORD +site-packages/pyyaml_env_tag-1.1.dist-info/REQUESTED +site-packages/pyyaml_env_tag-1.1.dist-info/WHEEL +site-packages/pyyaml_env_tag-1.1.dist-info/direct_url.json +site-packages/pyyaml_env_tag-1.1.dist-info/licenses/LICENSE +site-packages/pyyaml_env_tag-1.1.dist-info/top_level.txt +site-packages/yaml_env_tag.py diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/git b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/git new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/hash_input.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/hash_input.json new file mode 100644 index 0000000000000000000000000000000000000000..13d50ee321d847b554d3c6459e367e47afdcf976 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/hash_input.json @@ -0,0 +1,3 @@ +{ + "channel_targets": "conda-forge main" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/index.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/index.json new file mode 100644 index 0000000000000000000000000000000000000000..3070077293a9f9cbbb72a2caf39f82e764747b7b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/index.json @@ -0,0 +1,16 @@ +{ + "arch": null, + "build": "pyhd8ed1ab_0", + "build_number": 0, + "depends": [ + "python >=3.9", + "pyyaml" + ], + "license": "MIT", + "name": "pyyaml-env-tag", + "noarch": "python", + "platform": null, + "subdir": "noarch", + "timestamp": 1747237061448, + "version": "1.1" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..861fbe21564fbea9e0d520f84d0379aed02f1231 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/licenses/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2020 Waylan Limberg + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/link.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/link.json new file mode 100644 index 0000000000000000000000000000000000000000..ec6589c68a1bf1aedb3f856ab584e80f5302f2cb --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/link.json @@ -0,0 +1,6 @@ +{ + "noarch": { + "type": "python" + }, + "package_metadata_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/paths.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/paths.json new file mode 100644 index 0000000000000000000000000000000000000000..90b6c1ada79ab52b54c56227713d3d23ac4233fa --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/paths.json @@ -0,0 +1,59 @@ +{ + "paths": [ + { + "_path": "site-packages/pyyaml_env_tag-1.1.dist-info/INSTALLER", + "path_type": "hardlink", + "sha256": "d0edee15f91b406f3f99726e44eb990be6e34fd0345b52b910c568e0eef6a2a8", + "size_in_bytes": 5 + }, + { + "_path": "site-packages/pyyaml_env_tag-1.1.dist-info/METADATA", + "path_type": "hardlink", + "sha256": "ac57cea03088ce5f4a0e1eb6d4668fa49745492daa228d046e98b1a9813c7872", + "size_in_bytes": 5541 + }, + { + "_path": "site-packages/pyyaml_env_tag-1.1.dist-info/RECORD", + "path_type": "hardlink", + "sha256": "909798cbc74869149ea5c5ee447fea232764e901a77b098c0ae69528a73a6b9f", + "size_in_bytes": 828 + }, + { + "_path": "site-packages/pyyaml_env_tag-1.1.dist-info/REQUESTED", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/pyyaml_env_tag-1.1.dist-info/WHEEL", + "path_type": "hardlink", + "sha256": "c17c53cdc1039e3ad3c056232cf72c5bfeff5e286e7c1c26a6205e8973411840", + "size_in_bytes": 91 + }, + { + "_path": "site-packages/pyyaml_env_tag-1.1.dist-info/direct_url.json", + "path_type": "hardlink", + "sha256": "394bb1a31708f75eddd267811c96b1737dacbb8d77e2056e2a368eb38e83db74", + "size_in_bytes": 110 + }, + { + "_path": "site-packages/pyyaml_env_tag-1.1.dist-info/licenses/LICENSE", + "path_type": "hardlink", + "sha256": "75a5994afa284b67e6e66d7f83d2d39e729736511491b3d309ea7a064cbde3ce", + "size_in_bytes": 1070 + }, + { + "_path": "site-packages/pyyaml_env_tag-1.1.dist-info/top_level.txt", + "path_type": "hardlink", + "sha256": "afd81416076d037d2adc4847ddbe361c2a5361c4bdf7639199598edd669f3472", + "size_in_bytes": 13 + }, + { + "_path": "site-packages/yaml_env_tag.py", + "path_type": "hardlink", + "sha256": "b6973dd310d334f82caf6a0020ee42437ecb33135d7deca732417cf7a25617a3", + "size_in_bytes": 1545 + } + ], + "paths_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/recipe/conda_build_config.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/recipe/conda_build_config.yaml new file mode 100644 index 0000000000000000000000000000000000000000..660517209ada7a42033f8251e59d3de564afac6a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/recipe/conda_build_config.yaml @@ -0,0 +1,32 @@ +CI: azure +c_compiler: gcc +cdt_name: conda +channel_sources: conda-forge +channel_targets: conda-forge main +cpu_optimization_target: nocona +cran_mirror: https://cran.r-project.org +cxx_compiler: gxx +docker_image: quay.io/condaforge/linux-anvil-x86_64:alma9 +extend_keys: +- extend_keys +- pin_run_as_build +- ignore_version +- ignore_build_only_deps +fortran_compiler: gfortran +ignore_build_only_deps: +- python +- numpy +lua: '5' +numpy: '1.26' +perl: 5.26.2 +pin_run_as_build: + python: + max_pin: x.x + min_pin: x.x + r-base: + max_pin: x.x + min_pin: x.x +python: '3.12' +python_min: '3.9' +r_base: '3.5' +target_platform: linux-64 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/recipe/meta.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/recipe/meta.yaml new file mode 100644 index 0000000000000000000000000000000000000000..cb96db226039217e5c9fed5b769b106e3c409d62 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/recipe/meta.yaml @@ -0,0 +1,69 @@ +# This file created by conda-build 25.4.2 +# meta.yaml template originally from: +# /home/conda/recipe_root, last modified Wed May 14 15:34:43 2025 +# ------------------------------------------------ + +package: + name: pyyaml-env-tag + version: '1.1' +source: + sha256: 2eb38b75a2d21ee0475d6d97ec19c63287a7e140231e4214969d0eac923cd7ff + url: https://pypi.org/packages/source/p/pyyaml-env-tag/pyyaml_env_tag-1.1.tar.gz +build: + noarch: python + number: '0' + script: /home/conda/feedstock_root/build_artifacts/pyyaml-env-tag_1747236954314/_h_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placeh/bin/python + -m pip install . -vv --no-deps --no-build-isolation + string: pyhd8ed1ab_0 +requirements: + host: + - _libgcc_mutex 0.1 conda_forge + - _openmp_mutex 4.5 2_gnu + - bzip2 1.0.8 h4bc722e_7 + - ca-certificates 2025.4.26 hbd8a1cb_0 + - flit-core 3.12.0 pyhd8ed1ab_0 + - ld_impl_linux-64 2.43 h712a8e2_4 + - libexpat 2.7.0 h5888daf_0 + - libffi 3.4.6 h2dba641_1 + - libgcc 15.1.0 h767d61c_2 + - libgcc-ng 15.1.0 h69a702a_2 + - libgomp 15.1.0 h767d61c_2 + - liblzma 5.8.1 hb9d3cd8_1 + - libnsl 2.0.1 hd590300_0 + - libsqlite 3.49.2 hee588c1_0 + - libuuid 2.38.1 h0b41bf4_0 + - libxcrypt 4.4.36 hd590300_1 + - libzlib 1.3.1 hb9d3cd8_2 + - ncurses 6.5 h2d0b736_3 + - openssl 3.5.0 h7b32b05_1 + - pip 25.1.1 pyh8b19718_0 + - python 3.9.22 h85ef794_1_cpython + - readline 8.2 h8c095d6_2 + - setuptools 80.1.0 pyhff2d567_0 + - tk 8.6.13 noxft_h4845f30_101 + - tzdata 2025b h78e105d_0 + - wheel 0.45.1 pyhd8ed1ab_1 + run: + - python >=3.9 + - pyyaml +test: + commands: + - pip check + imports: + - yaml_env_tag + requires: + - pip + - python 3.9.* +about: + home: https://github.com/waylan/pyyaml-env-tag + license: MIT + license_file: LICENSE + summary: A custom YAML tag for referencing environment variables in YAML files. +extra: + copy_test_source_files: true + final: true + flow_run_id: azure_20250514.1.1 + recipe-maintainers: + - ocefpaf + remote_url: https://github.com/conda-forge/pyyaml-env-tag-feedstock + sha: 0fb0debbc36ed2767f019c7d1e97c8412494e89e diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/recipe/meta.yaml.template b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/recipe/meta.yaml.template new file mode 100644 index 0000000000000000000000000000000000000000..0a223d64a597681e8d84676c67122dc042067154 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/recipe/meta.yaml.template @@ -0,0 +1,44 @@ +{% set name = "pyyaml-env-tag" %} +{% set version = "1.1" %} + + +package: + name: {{ name|lower }} + version: {{ version }} + +source: + url: https://pypi.org/packages/source/{{ name[0] }}/{{ name }}/pyyaml_env_tag-{{ version }}.tar.gz + sha256: 2eb38b75a2d21ee0475d6d97ec19c63287a7e140231e4214969d0eac923cd7ff + +build: + number: 0 + noarch: python + script: {{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation + +requirements: + host: + - python {{ python_min }} + - pip + - flit-core + run: + - python >={{ python_min }} + - pyyaml + +test: + imports: + - yaml_env_tag + commands: + - pip check + requires: + - pip + - python {{ python_min }} + +about: + home: https://github.com/waylan/pyyaml-env-tag + summary: A custom YAML tag for referencing environment variables in YAML files. + license: MIT + license_file: LICENSE + +extra: + recipe-maintainers: + - ocefpaf diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/recipe/recipe-scripts-license.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/recipe/recipe-scripts-license.txt new file mode 100644 index 0000000000000000000000000000000000000000..2ec51d75f362bc4327a3cfe1c515c16bb3c57367 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/recipe/recipe-scripts-license.txt @@ -0,0 +1,27 @@ +BSD-3-Clause license +Copyright (c) 2015-2022, conda-forge contributors +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + 3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/repodata_record.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/repodata_record.json new file mode 100644 index 0000000000000000000000000000000000000000..11b70ba5fa975b9a21fb47529534d1c70dedb669 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/repodata_record.json @@ -0,0 +1,24 @@ +{ + "arch": null, + "build": "pyhd8ed1ab_0", + "build_number": 0, + "build_string": "pyhd8ed1ab_0", + "channel": "conda-forge", + "constrains": [], + "depends": [ + "python >=3.9", + "pyyaml" + ], + "fn": "pyyaml-env-tag-1.1-pyhd8ed1ab_0.conda", + "license": "MIT", + "md5": "e8e53c4150a1bba3b160eacf9d53a51b", + "name": "pyyaml-env-tag", + "noarch": "python", + "platform": null, + "sha256": "69ab63bd45587406ae911811fc4d4c1bf972d643fa57a009de7c01ac978c4edd", + "size": 11137, + "subdir": "noarch", + "timestamp": 1747237061, + "url": "https://conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0.conda", + "version": "1.1" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/test/run_test.bat b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/test/run_test.bat new file mode 100644 index 0000000000000000000000000000000000000000..f99764037905cf72e1bd8677e68c4553a77d0557 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/test/run_test.bat @@ -0,0 +1,7 @@ + + + + +pip check +IF %ERRORLEVEL% NEQ 0 exit /B 1 +exit /B 0 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/test/run_test.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/test/run_test.py new file mode 100644 index 0000000000000000000000000000000000000000..b969d7c58ad30ced1aa03a9b9c321f2a99b96358 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/test/run_test.py @@ -0,0 +1,3 @@ +print("import: 'yaml_env_tag'") +import yaml_env_tag + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/test/run_test.sh b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/test/run_test.sh new file mode 100644 index 0000000000000000000000000000000000000000..1afc6b862fab8658b14cb4cc0345a4ee1f02ad0e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/test/run_test.sh @@ -0,0 +1,8 @@ + + +set -ex + + + +pip check +exit 0 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/test/test_time_dependencies.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/test/test_time_dependencies.json new file mode 100644 index 0000000000000000000000000000000000000000..a8f956583208ac1ec1f8137bfefb6ba869dd5dab --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/info/test/test_time_dependencies.json @@ -0,0 +1 @@ +["python 3.9.*", "pip"] \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/INSTALLER b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/INSTALLER new file mode 100644 index 0000000000000000000000000000000000000000..f79e4cb9aaf0b2d9e8ba78861e2071317b2384b3 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/INSTALLER @@ -0,0 +1 @@ +conda \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/METADATA b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/METADATA new file mode 100644 index 0000000000000000000000000000000000000000..d816342453878e64a28929f274367e0483236aa9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/METADATA @@ -0,0 +1,172 @@ +Metadata-Version: 2.4 +Name: pyyaml_env_tag +Version: 1.1 +Summary: A custom YAML tag for referencing environment variables in YAML files. +Author-email: Waylan Limberg <waylan.limberg@icloud.com> +License-Expression: MIT +Project-URL: Homepage, https://github.com/waylan/pyyaml-env-tag +Project-URL: Repository, https://github.com/waylan/pyyaml-env-tag +Project-URL: Bug Tracker, https://github.com/waylan/pyyaml-env-tag/issues +Classifier: Development Status :: 5 - Production/Stable +Classifier: Intended Audience :: Developers +Classifier: Operating System :: OS Independent +Classifier: Programming Language :: Python :: 3 +Classifier: Programming Language :: Python :: 3.9 +Classifier: Programming Language :: Python :: 3.10 +Classifier: Programming Language :: Python :: 3.11 +Classifier: Programming Language :: Python :: 3.12 +Classifier: Programming Language :: Python :: 3.13 +Classifier: Topic :: Software Development :: Libraries :: Python Modules +Classifier: Topic :: Text Processing :: Markup +Requires-Python: >=3.9 +Description-Content-Type: text/markdown +License-File: LICENSE +Requires-Dist: pyyaml +Dynamic: license-file + +# pyyaml_env_tag + +A custom YAML tag for referencing environment variables in YAML files. + +[![PyPI Version][pypi-image]][pypi-link] +[![Build Status][GHAction-image]][GHAction-link] +[![Coverage Status][codecov-image]][codecov-link] + +[pypi-image]: https://img.shields.io/pypi/v/pyyaml-env-tag.svg +[pypi-link]: https://pypi.org/project/pyyaml-env-tag/ +[GHAction-image]: https://github.com/waylan/pyyaml-env-tag/workflows/CI/badge.svg?branch=master&event=push +[GHAction-link]: https://github.com/waylan/pyyaml-env-tag/actions?query=event%3Apush+branch%3Amaster +[codecov-image]: https://codecov.io/github/waylan/pyyaml-env-tag/coverage.svg?branch=master +[codecov-link]: https://codecov.io/github/waylan/pyyaml-env-tag?branch=master + +## Installation + +Install the `pyyaml_env_tag` package with pip: + +```bash +pip install pyyaml_env_tag +``` + +### Enabling the tag + +To enable the tag, pass your loader of choice into the `add_env_tag` function, which will +return the loader with the construstor added to it. + +```python +import yaml +from yaml_env_tag import add_env_tag + +myLoader = add_env_tag(yaml.Loader) +``` + +Then you may use the loader as per usual. For example: + +```python +yaml.load(data, Loader=myLoader) +``` + +The `add_env_tag` is a high level helper function. If you need lower level access, you may +add the constructor (`yaml_env_tag.construct_env_tag`) to the loader directly using the +`add_constructor` method of the loader. Note that this requires that the tag (`!ENV`) be +defined as well. + +```python +from yaml_env_tag import construct_env_tag + +Loader.add_constructor('!ENV', construct_env_tag) +``` + +## Using the tag + +Include the tag `!ENV` followed by the name of an environment variable in a YAML +file and the value of the environment variable will be used in its place. + +```yaml +key: !ENV SOME_VARIABLE +``` + +If `SOME_VARIABLE` is set to `A string!`, then the above YAML would result in the +following Python object: + +```python +{'key': 'A string!'} +``` + +The content of the variable is parsed using YAML's implicit scalar types, such as +string, bool, integer, float, datestamp and null. More complex types are not +recognized and simply passed through as a string. For example, if `SOME_VARIABLE` +was set to the string `true`, then the above YAML would result in the following: + +```python +{'key': True} +``` + +If the variable specified is not set, then a `null` value is assigned as a default. +You may define your own default as the last item in a sequence. + +```yaml +key: !ENV [SOME_VARIABLE, default] +``` + +In the above example, if `SOME_VARIABLE` is not defined, the string `default` would +be used instead, as follows: + +```python +{'key': 'default'} +``` + +You may list multiple variables as fallbacks. The first variable which is set is +used. In any sequance with more than one item, the last item must always be a +default value and will not be resolved as an environment variable. + +```yaml +key: !ENV [SOME_VARIABLE, FALLBACK, default] +``` + +As with variable contents, the default is resolved to a Python object of the +implied type (string, bool, integer, float, datestamp and null). + +When `SOME_VARIABLE` is not set, all four of the following items will resolve to +the same value (`None`): + +```yaml +- !ENV SOME_VARIABLE +- !ENV [SOME_VARIABLE] +- !ENV [SOME_VARIABLE, ~] +- !ENV [SOME_VARIABLE, null] +``` + +## Related + +pyyaml_env_tag was inspired by the Ruby package [yaml-env-tag]. + +An alternate method of referencing environment variables in YAML files is +implemented by [pyyaml-tags] and [python_yaml_environment_variables]. +Each of those libraries use a template string and replace the template tag with +the content of the variable. While this allows a single value to reference +multiple variables and to contain additional content, it restricts all values +to strings only and does not provide a way to define defaults. + +[yaml-env-tag]: https://github.com/jirutka/yaml-env-tag +[pyyaml-tags]: https://github.com/meiblorn/pyyaml-tags +[python_yaml_environment_variables]: https://gist.github.com/mkaranasou/ba83e25c835a8f7629e34dd7ede01931 + +## License + +pyyaml_env_tag is licensed under the [MIT License] as defined in `LICENSE`. + +[MIT License]: https://opensource.org/licenses/MIT + +## Changelog + +### [1.1] - 2025-05-13 + +- Ensure tests get included with distribution (#9). + +### [1.0] - 2025-05-09 + +- Add the `add_env_tag` helper function as a higher level way of modifying the loader. + +### [0.1] - 2020-11-11 + +The initial release. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/RECORD b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/RECORD new file mode 100644 index 0000000000000000000000000000000000000000..bcb6d3c16505a162c8a66e01a0d77b6da2f788f9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/RECORD @@ -0,0 +1,10 @@ +__pycache__/yaml_env_tag.cpython-39.pyc,, +pyyaml_env_tag-1.1.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +pyyaml_env_tag-1.1.dist-info/METADATA,sha256=rFfOoDCIzl9KDh621GaPpJdFSS2qIo0EbpixqYE8eHI,5541 +pyyaml_env_tag-1.1.dist-info/RECORD,, +pyyaml_env_tag-1.1.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pyyaml_env_tag-1.1.dist-info/WHEEL,sha256=wXxTzcEDnjrTwFYjLPcsW_7_XihufBwmpiBeiXNBGEA,91 +pyyaml_env_tag-1.1.dist-info/direct_url.json,sha256=OUuxoxcI917d0meBHJaxc32su4134gVuKjaOs46D23Q,110 +pyyaml_env_tag-1.1.dist-info/licenses/LICENSE,sha256=daWZSvooS2fm5m1_g9LTnnKXNlEUkbPTCep6Bky9484,1070 +pyyaml_env_tag-1.1.dist-info/top_level.txt,sha256=r9gUFgdtA30q3EhH3b42HCpTYcS992ORmVmO3WafNHI,13 +yaml_env_tag.py,sha256=tpc90xDTNPgsr2oAIO5CQ37LMxNdfeynMkF896JWF6M,1545 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/REQUESTED b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/REQUESTED new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/WHEEL b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/WHEEL new file mode 100644 index 0000000000000000000000000000000000000000..8b9e2d3072660a2d4956b059dd2093da0b9d5dbf --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/WHEEL @@ -0,0 +1,5 @@ +Wheel-Version: 1.0 +Generator: setuptools (80.1.0) +Root-Is-Purelib: true +Tag: py3-none-any + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/direct_url.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/direct_url.json new file mode 100644 index 0000000000000000000000000000000000000000..902affac544f8ddafed14adf5bce1ca4fd271824 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/direct_url.json @@ -0,0 +1 @@ +{"dir_info": {}, "url": "file:///home/conda/feedstock_root/build_artifacts/pyyaml-env-tag_1747236954314/work"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..861fbe21564fbea9e0d520f84d0379aed02f1231 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/licenses/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2020 Waylan Limberg + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/top_level.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/top_level.txt new file mode 100644 index 0000000000000000000000000000000000000000..fce34124e3b39d86da20004864840a67438305af --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/pyyaml_env_tag-1.1.dist-info/top_level.txt @@ -0,0 +1 @@ +yaml_env_tag diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/yaml_env_tag.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/yaml_env_tag.py new file mode 100644 index 0000000000000000000000000000000000000000..3b61490069b850f823204c209c5875c791af2373 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/pyyaml-env-tag-1.1-pyhd8ed1ab_0/site-packages/yaml_env_tag.py @@ -0,0 +1,42 @@ +""" A custom YAML tag for referencing environment variables in YAML files. """ +__version__ = '1.1' + +import os +import yaml +from typing import Any + + +def construct_env_tag(loader: yaml.Loader, node: yaml.Node) -> Any: + """Assign value of ENV variable referenced at node.""" + default = None + if isinstance(node, yaml.nodes.ScalarNode): + vars = [loader.construct_scalar(node)] + elif isinstance(node, yaml.nodes.SequenceNode): + child_nodes = node.value + if len(child_nodes) > 1: + # default is resolved using YAML's (implicit) types. + default = loader.construct_object(child_nodes[-1]) + child_nodes = child_nodes[:-1] + # Env Vars are resolved as string values, ignoring (implicit) types. + vars = [loader.construct_scalar(child) for child in child_nodes] + else: + raise yaml.constructor.ConstructorError( + None, None, + f'expected a scalar or sequence node, but found {node.id}', + node.start_mark + ) + + for var in vars: + if var in os.environ: + value = os.environ[var] + # Resolve value to Python type using YAML's implicit resolvers + tag = loader.resolve(yaml.nodes.ScalarNode, value, (True, False)) + return loader.construct_object(yaml.nodes.ScalarNode(tag, value)) + + return default + + +def add_env_tag(loader: yaml.Loader) -> yaml.Loader: + """ Modify and return Loader with env tag support. """ + loader.add_constructor('!ENV', construct_env_tag) + return loader diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/about.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/about.json new file mode 100644 index 0000000000000000000000000000000000000000..3fe41fb298f51311fb0aa0817e3200605c6bf4bb --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/about.json @@ -0,0 +1,25 @@ +{ + "channels": [ + "https://conda.anaconda.org/conda-forge/" + ], + "dev_url": "https://github.com/psf/requests", + "extra": { + "flow_run_id": "github_25697660708", + "recipe-maintainers": [ + "jakirkham", + "kalefranz", + "mcg1969", + "mingwandroid", + "msarahan", + "pelson", + "sigmavirus24", + "ocefpaf", + "carlodri" + ], + "remote_url": "https://github.com/conda-forge/requests-feedstock", + "sha": "b3a09a06bfc1ca0bb82abbfdc105531340a8d689" + }, + "home": "http://python-requests.org/", + "license": "Apache-2.0", + "summary": "Requests is an elegant and simple HTTP library for Python, built with ♥." +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/hash_input.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/hash_input.json new file mode 100644 index 0000000000000000000000000000000000000000..8cab3e9c53cdf587ba644746533a696e1ec88e46 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/hash_input.json @@ -0,0 +1 @@ +{"channel_sources": "conda-forge", "channel_targets": "conda-forge main", "python_min": "3.10", "target_platform": "noarch"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/index.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/index.json new file mode 100644 index 0000000000000000000000000000000000000000..e170d40f6a03183dff96689ccc08518f157a26af --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/index.json @@ -0,0 +1,21 @@ +{ + "build": "pyhcf101f3_0", + "build_number": 0, + "constrains": [ + "chardet >=3.0.2,<8" + ], + "depends": [ + "python >=3.10", + "certifi >=2023.5.7", + "charset-normalizer >=2,<4", + "idna >=2.5,<4", + "urllib3 >=1.26,<3", + "python" + ], + "license": "Apache-2.0", + "name": "requests", + "noarch": "python", + "subdir": "noarch", + "timestamp": 1778534036810, + "version": "2.34.0" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..67db8588217f266eb561f75fae738656325deac9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/licenses/LICENSE @@ -0,0 +1,175 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/link.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/link.json new file mode 100644 index 0000000000000000000000000000000000000000..ec6589c68a1bf1aedb3f856ab584e80f5302f2cb --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/link.json @@ -0,0 +1,6 @@ +{ + "noarch": { + "type": "python" + }, + "package_metadata_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/paths.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/paths.json new file mode 100644 index 0000000000000000000000000000000000000000..7781bf913807ec0a5cb0c67462ad884723574cd5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/paths.json @@ -0,0 +1,179 @@ +{ + "paths": [ + { + "_path": "site-packages/requests/__init__.py", + "path_type": "hardlink", + "sha256": "311157e7fa4aa9166c827d5237e6fd694eeb5ca549ee40e2e90f89f21abcd56e", + "size_in_bytes": 5922 + }, + { + "_path": "site-packages/requests/__version__.py", + "path_type": "hardlink", + "sha256": "530ea4d61cc9364159cb30176151c4f9073f26224e18395933a02cc4ba4c0326", + "size_in_bytes": 435 + }, + { + "_path": "site-packages/requests/_internal_utils.py", + "path_type": "hardlink", + "sha256": "4c7d8d132c9898fc7d715e473f3ac74785ddc4ab96d2c9240f87835dc6d981ff", + "size_in_bytes": 1542 + }, + { + "_path": "site-packages/requests/_types.py", + "path_type": "hardlink", + "sha256": "677b839721a4b2532b374ab96f459082a68bf4a13e8cbf988baa793f2f76e9e7", + "size_in_bytes": 5882 + }, + { + "_path": "site-packages/requests/adapters.py", + "path_type": "hardlink", + "sha256": "647eabd4453de232aa40b55ff033d6f19778910b7e7069c51fdf63076fc77493", + "size_in_bytes": 28064 + }, + { + "_path": "site-packages/requests/api.py", + "path_type": "hardlink", + "sha256": "4d15480ac046f089209798e8650476ef4a28ebe6f81b400758f8ef42ec6b5509", + "size_in_bytes": 7152 + }, + { + "_path": "site-packages/requests/auth.py", + "path_type": "hardlink", + "sha256": "e93951a552d4c3c5fd9b84a5e1d49b03caaba4723c4ff112da6053600ec85a65", + "size_in_bytes": 12233 + }, + { + "_path": "site-packages/requests/certs.py", + "path_type": "hardlink", + "sha256": "fd9c6b83359cef90ff6c4eeeab8dcc2388da382ebca7d00a499b3c0b434a87e4", + "size_in_bytes": 430 + }, + { + "_path": "site-packages/requests/compat.py", + "path_type": "hardlink", + "sha256": "5d79ba289690b5015044341a1f7bc7d24134fc13a2db3efcf852515bf9aa18b4", + "size_in_bytes": 2465 + }, + { + "_path": "site-packages/requests/cookies.py", + "path_type": "hardlink", + "sha256": "0a1ce6140f2b9420522c5080e356e689fa796c2522f55ca10826f5ed8e0a723c", + "size_in_bytes": 21549 + }, + { + "_path": "site-packages/requests/exceptions.py", + "path_type": "hardlink", + "sha256": "c5e18f3352454968e337bb3056f0867df2f37c0a0d2c1a77dc05e7e0b3c0411b", + "size_in_bytes": 4564 + }, + { + "_path": "site-packages/requests/help.py", + "path_type": "hardlink", + "sha256": "723519bb1884da18d84f6b2fb78f7ebf7fb57f732070b6025ae071dac6a2d179", + "size_in_bytes": 4210 + }, + { + "_path": "site-packages/requests/hooks.py", + "path_type": "hardlink", + "sha256": "ebd8a02475d31a0e473a8f553e9501ff43645b9563885ad52844e7a63f0d76ab", + "size_in_bytes": 1138 + }, + { + "_path": "site-packages/requests/models.py", + "path_type": "hardlink", + "sha256": "3e1a988ed7be0506d463f28918c1f88585ed666d50d256e85848349301cbefec", + "size_in_bytes": 41698 + }, + { + "_path": "site-packages/requests/packages.py", + "path_type": "hardlink", + "sha256": "fe0d2067af355320252874631fa91a9db6a8c71d9e01beaacdc5e2383c932287", + "size_in_bytes": 904 + }, + { + "_path": "site-packages/requests/py.typed", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/requests/sessions.py", + "path_type": "hardlink", + "sha256": "8ae1614176e41b1f8c3fbb868930b577462a666452a7479e959e36e29dfb55af", + "size_in_bytes": 34266 + }, + { + "_path": "site-packages/requests/status_codes.py", + "path_type": "hardlink", + "sha256": "1950f47c89cf18019787e07d8ce48f66d6b38e622f7d94d70a90247fee6c040e", + "size_in_bytes": 4351 + }, + { + "_path": "site-packages/requests/structures.py", + "path_type": "hardlink", + "sha256": "ba9460c39078f25e6f1d2a24ac941ac6f8d2ee97197fa8c8d0c262d8a1e67a02", + "size_in_bytes": 4134 + }, + { + "_path": "site-packages/requests/utils.py", + "path_type": "hardlink", + "sha256": "657fd02343b2586bbd138a4ec0f03ceeb7610c2712f96ac54f28a708bf7d079c", + "size_in_bytes": 36322 + }, + { + "_path": "site-packages/requests-2.34.0.dist-info/INSTALLER", + "path_type": "hardlink", + "sha256": "bc33022edcb7639ff53355b4e91dade50a0bbf0299efeb6171d1ec0ba5029cfc", + "size_in_bytes": 6 + }, + { + "_path": "site-packages/requests-2.34.0.dist-info/METADATA", + "path_type": "hardlink", + "sha256": "eb8c3ec579b67270205eb72c109ea0eb8f7c771dd5660a92f134484d99e87ab9", + "size_in_bytes": 4806 + }, + { + "_path": "site-packages/requests-2.34.0.dist-info/RECORD", + "path_type": "hardlink", + "sha256": "06794a0a06004fe777fe02b4838e58f48791ccca64a273c838c3fd61b9ee4ef6", + "size_in_bytes": 3251 + }, + { + "_path": "site-packages/requests-2.34.0.dist-info/REQUESTED", + "path_type": "hardlink", + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", + "size_in_bytes": 0 + }, + { + "_path": "site-packages/requests-2.34.0.dist-info/WHEEL", + "path_type": "hardlink", + "sha256": "69e6228a0d35958183cc1812f07c565ce837b95eb51bd8a33acba9fa4f68d6c9", + "size_in_bytes": 91 + }, + { + "_path": "site-packages/requests-2.34.0.dist-info/direct_url.json", + "path_type": "hardlink", + "sha256": "e37c3f2a41bd36a7894bdfdd55714c7e7e985acc9a9ec622b10dea7602011ed6", + "size_in_bytes": 119 + }, + { + "_path": "site-packages/requests-2.34.0.dist-info/licenses/LICENSE", + "path_type": "hardlink", + "sha256": "09e8a9bcec8067104652c168685ab0931e7868f9c8284b66f5ae6edae5f1130b", + "size_in_bytes": 10142 + }, + { + "_path": "site-packages/requests-2.34.0.dist-info/licenses/NOTICE", + "path_type": "hardlink", + "sha256": "f5110972dedad2b4e9d314518daf3b7d72d6e02e499acd802181de6f74571dcc", + "size_in_bytes": 38 + }, + { + "_path": "site-packages/requests-2.34.0.dist-info/top_level.txt", + "path_type": "hardlink", + "sha256": "7cc4959877dbe6b6c63a8eb1bfe3bfb545fa8fe5b28b1b2c13e4a7c1c0d1c4d4", + "size_in_bytes": 9 + } + ], + "paths_version": 1 +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/recipe/recipe-scripts-license.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/recipe/recipe-scripts-license.txt new file mode 100644 index 0000000000000000000000000000000000000000..c5aa738f1bd246658c9da9e1bbe2502df6d0e173 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/recipe/recipe-scripts-license.txt @@ -0,0 +1,26 @@ +BSD-3-Clause license +Copyright (c) 2015-2026, conda-forge contributors + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + 3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/recipe/recipe.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/recipe/recipe.yaml new file mode 100644 index 0000000000000000000000000000000000000000..db9d0da79677dcd058db92cb3317e2ab9b8e3525 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/recipe/recipe.yaml @@ -0,0 +1,62 @@ +schema_version: 1 + +context: + name: requests + version: "2.34.0" + +package: + name: ${{ name|lower }} + version: ${{ version }} + +source: + url: https://pypi.org/packages/source/${{ name[0] }}/${{ name }}/requests-${{ version }}.tar.gz + sha256: 7d62fe92f50eb82c529b0916bb445afa1531a566fc8f35ffdc64446e771b856a + +build: + number: 0 + noarch: python + script: ${{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation + +requirements: + host: + - python ${{ python_min }}.* + - setuptools + - wheel + - pip + run: + - python >=${{ python_min }} + - certifi >=2023.5.7 + - charset-normalizer >=2,<4 + - idna >=2.5,<4 + - urllib3 >=1.26,<3 + run_constraints: + # requests >=2.33.0 has a run time constraint in its __init__.py: chardet >=3.0.2,<8 + # https://github.com/psf/requests/blob/v2.33.1/src/requests/__init__.py#L79 + # https://github.com/psf/requests/blob/111d2b77790bf49943c0dfa09b365371c24aec7e/src/requests/__init__.py#L79 + - chardet >=3.0.2,<8 + +tests: + - python: + python_version: ${{ python_min }}.* + imports: + - requests + pip_check: true + +about: + homepage: http://python-requests.org + license: Apache-2.0 + license_file: LICENSE + summary: Requests is an elegant and simple HTTP library for Python, built with ♥. + repository: https://github.com/psf/requests + +extra: + recipe-maintainers: + - jakirkham + - kalefranz + - mcg1969 + - mingwandroid + - msarahan + - pelson + - sigmavirus24 + - ocefpaf + - carlodri diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/recipe/rendered_recipe.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/recipe/rendered_recipe.yaml new file mode 100644 index 0000000000000000000000000000000000000000..4b884fc9d1baa44391742ff91b580081f90dd16b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/recipe/rendered_recipe.yaml @@ -0,0 +1,657 @@ +recipe: + schema_version: 1 + context: + name: requests + version: 2.34.0 + package: + name: requests + version: 2.34.0 + source: + - url: https://pypi.org/packages/source/r/requests/requests-2.34.0.tar.gz + sha256: 7d62fe92f50eb82c529b0916bb445afa1531a566fc8f35ffdc64446e771b856a + build: + number: 0 + string: pyhcf101f3_0 + script: ${{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation + noarch: python + requirements: + host: + - python 3.10.* + - setuptools + - wheel + - pip + run: + - python >=3.10 + - certifi >=2023.5.7 + - charset-normalizer >=2,<4 + - idna >=2.5,<4 + - urllib3 >=1.26,<3 + run_constraints: + - chardet >=3.0.2,<8 + tests: + - python: + imports: + - requests + python_version: 3.10.* + about: + homepage: http://python-requests.org/ + repository: https://github.com/psf/requests + license: Apache-2.0 + license_file: + - LICENSE + summary: Requests is an elegant and simple HTTP library for Python, built with ♥. + extra: + recipe-maintainers: + - jakirkham + - kalefranz + - mcg1969 + - mingwandroid + - msarahan + - pelson + - sigmavirus24 + - ocefpaf + - carlodri +build_configuration: + target_platform: noarch + host_platform: + platform: linux-64 + virtual_packages: + - __unix=0=0 + - __linux=6.17.0=0 + - __glibc=2.34=0 + - __archspec=1=zen2 + build_platform: + platform: linux-64 + virtual_packages: + - __unix=0=0 + - __linux=6.17.0=0 + - __glibc=2.34=0 + - __archspec=1=zen2 + variant: + channel_sources: conda-forge + channel_targets: conda-forge main + python_min: '3.10' + target_platform: noarch + hash: + hash: cf101f3 + prefix: py + directories: + host_prefix: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_requests_1778534036/host_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_place + build_prefix: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_requests_1778534036/build_env + work_dir: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_requests_1778534036/work + build_dir: /home/conda/feedstock_root/build_artifacts/bld/rattler-build_requests_1778534036 + channels: + - https://conda.anaconda.org/conda-forge + channel_priority: strict + solve_strategy: highest + timestamp: 2026-05-11T21:13:56.810957635Z + subpackages: + requests: + name: requests + version: 2.34.0 + build_string: pyhcf101f3_0 + packaging_settings: + archive_type: conda + compression_level: 15 +finalized_dependencies: + build: null + host: + specs: + - source: python 3.10.* + - source: setuptools + - source: wheel + - source: pip + resolved: + - build: h3c07f61_0_cpython + build_number: 0 + constrains: + - python_abi 3.10.* *_cp310 + depends: + - __glibc >=2.17,<3.0.a0 + - bzip2 >=1.0.8,<2.0a0 + - ld_impl_linux-64 >=2.36.1 + - libexpat >=2.7.4,<3.0a0 + - libffi >=3.4,<4.0a0 + - libgcc >=14 + - liblzma >=5.8.2,<6.0a0 + - libnsl >=2.0.1,<2.1.0a0 + - libsqlite >=3.51.2,<4.0a0 + - libuuid >=2.41.3,<3.0a0 + - libxcrypt >=4.4.36 + - libzlib >=1.3.1,<2.0a0 + - ncurses >=6.5,<7.0a0 + - openssl >=3.5.5,<4.0a0 + - readline >=8.3,<9.0a0 + - tk >=8.6.13,<8.7.0a0 + - tzdata + license: Python-2.0 + md5: 5d4e2b00d99feacd026859b7fa239dc0 + name: python + run_exports: + weak: + - python_abi 3.10.* *_cp310 + noarch: + - python + sha256: 8ff2ce308faf2588b69c65b120293f59a8f2577b772b34df4e817d220b09e081 + size: 25455342 + subdir: linux-64 + timestamp: 1772729810280 + version: 3.10.20 + fn: python-3.10.20-h3c07f61_0_cpython.conda + url: https://conda.anaconda.org/conda-forge/linux-64/python-3.10.20-h3c07f61_0_cpython.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h853b02a_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + - ncurses >=6.5,<7.0a0 + license: GPL-3.0-only + license_family: GPL + md5: d7d95fc8287ea7bf33e0e7116d2b95ec + name: readline + run_exports: + weak: + - readline >=8.3,<9.0a0 + sha256: 12ffde5a6f958e285aa22c191ca01bbd3d6e710aa852e00618fa6ddc59149002 + size: 345073 + subdir: linux-64 + timestamp: 1765813471974 + version: '8.3' + fn: readline-8.3-h853b02a_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/readline-8.3-h853b02a_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyh332efcf_0 + build_number: 0 + depends: + - python >=3.10 + license: MIT + license_family: MIT + md5: 8e194e7b992f99a5015edbd4ebd38efd + name: setuptools + noarch: python + run_exports: {} + sha256: 82088a6e4daa33329a30bc26dc19a98c7c1d3f05c0f73ce9845d4eab4924e9e1 + size: 639697 + subdir: noarch + timestamp: 1773074868565 + version: 82.0.1 + fn: setuptools-82.0.1-pyh332efcf_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhd8ed1ab_0 + build_number: 0 + depends: + - packaging >=24.0 + - python >=3.10 + license: MIT + license_family: MIT + md5: d0e3b2f0030cf4fca58bde71d246e94c + name: wheel + noarch: python + run_exports: {} + sha256: 9e156ffaefb8463437144326ada4b85d1de17961b9997ac5f1cbbaf747bd8bed + size: 33491 + subdir: noarch + timestamp: 1776878563806 + version: 0.47.0 + fn: wheel-0.47.0-pyhd8ed1ab_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/wheel-0.47.0-pyhd8ed1ab_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyh8b19718_0 + build_number: 0 + depends: + - python >=3.10,<3.13.0a0 + - setuptools + - wheel + license: MIT + license_family: MIT + md5: 35870d32aed92041d31cbb15e822dca3 + name: pip + noarch: python + run_exports: {} + sha256: 1bd94ef1ae08fd811ef3b26857e46ba460c7430bf1f3ccd94a4d6614fd619bd5 + size: 1201616 + subdir: noarch + timestamp: 1777924080196 + version: 26.1.1 + fn: pip-26.1.1-pyh8b19718_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/pip-26.1.1-pyh8b19718_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hda65f42_9 + build_number: 9 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: bzip2-1.0.6 + license_family: BSD + md5: d2ffd7602c02f2b316fd921d39876885 + name: bzip2 + run_exports: + weak: + - bzip2 >=1.0.8,<2.0a0 + sha256: 0b75d45f0bba3e95dc693336fa51f40ea28c980131fec438afb7ce6118ed05f6 + size: 260182 + subdir: linux-64 + timestamp: 1771350215188 + version: 1.0.8 + fn: bzip2-1.0.8-hda65f42_9.conda + url: https://conda.anaconda.org/conda-forge/linux-64/bzip2-1.0.8-hda65f42_9.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: default_hbd61a6d_102 + build_number: 102 + constrains: + - binutils_impl_linux-64 2.45.1 + depends: + - __glibc >=2.17,<3.0.a0 + - zstd >=1.5.7,<1.6.0a0 + license: GPL-3.0-only + license_family: GPL + md5: 18335a698559cdbcd86150a48bf54ba6 + name: ld_impl_linux-64 + run_exports: {} + sha256: 3d584956604909ff5df353767f3a2a2f60e07d070b328d109f30ac40cd62df6c + size: 728002 + subdir: linux-64 + timestamp: 1774197446916 + version: 2.45.1 + fn: ld_impl_linux-64-2.45.1-default_hbd61a6d_102.conda + url: https://conda.anaconda.org/conda-forge/linux-64/ld_impl_linux-64-2.45.1-default_hbd61a6d_102.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hecca717_0 + build_number: 0 + constrains: + - expat 2.8.0.* + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: MIT + license_family: MIT + md5: a3b390520c563d78cc58974de95a03e5 + name: libexpat + run_exports: {} + sha256: ea33c40977ea7a2c3658c522230058395bc2ee0d89d99f0711390b6a1ee80d12 + size: 77241 + subdir: linux-64 + timestamp: 1777846112704 + version: 2.8.0 + fn: libexpat-2.8.0-hecca717_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libexpat-2.8.0-hecca717_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h3435931_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: MIT + license_family: MIT + md5: a360c33a5abe61c07959e449fa1453eb + name: libffi + run_exports: + weak: + - libffi >=3.5.2,<3.6.0a0 + sha256: 31f19b6a88ce40ebc0d5a992c131f57d919f73c0b92cd1617a5bec83f6e961e6 + size: 58592 + subdir: linux-64 + timestamp: 1769456073053 + version: 3.5.2 + fn: libffi-3.5.2-h3435931_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libffi-3.5.2-h3435931_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: he0feb66_19 + build_number: 19 + constrains: + - libgcc-ng ==15.2.0=*_19 + - libgomp 15.2.0 he0feb66_19 + depends: + - __glibc >=2.17,<3.0.a0 + - _openmp_mutex >=4.5 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + md5: 57736f29cc2b0ec0b6c2952d3f101b6a + name: libgcc + run_exports: {} + sha256: 8e0a3b5e41272e5678499b5dfc4cddb673f9e935de01eb0767ce857001229f46 + size: 1041084 + subdir: linux-64 + timestamp: 1778269013026 + version: 15.2.0 + fn: libgcc-15.2.0-he0feb66_19.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgcc-15.2.0-he0feb66_19.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb03c661_0 + build_number: 0 + constrains: + - xz 5.8.3.* + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: 0BSD + md5: b88d90cad08e6bc8ad540cb310a761fb + name: liblzma + run_exports: + weak: + - liblzma >=5.8.3,<6.0a0 + sha256: ec30e52a3c1bf7d0425380a189d209a52baa03f22fb66dd3eb587acaa765bd6d + size: 113478 + subdir: linux-64 + timestamp: 1775825492909 + version: 5.8.3 + fn: liblzma-5.8.3-hb03c661_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/liblzma-5.8.3-hb03c661_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb9d3cd8_1 + build_number: 1 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + license: LGPL-2.1-only + license_family: GPL + md5: d864d34357c3b65a4b731f78c0801dc4 + name: libnsl + run_exports: + weak: + - libnsl >=2.0.1,<2.1.0a0 + sha256: 927fe72b054277cde6cb82597d0fcf6baf127dcbce2e0a9d8925a68f1265eef5 + size: 33731 + subdir: linux-64 + timestamp: 1750274110928 + version: 2.0.1 + fn: libnsl-2.0.1-hb9d3cd8_1.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libnsl-2.0.1-hb9d3cd8_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h0c1763c_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + - libzlib >=1.3.2,<2.0a0 + license: blessing + md5: 7dc38adcbf71e6b38748e919e16e0dce + name: libsqlite + run_exports: + weak: + - libsqlite >=3.53.1,<4.0a0 + sha256: 54cdcd3214313b62c2a8ee277e6f42150d9b748264c1b70d958bf735e420ef8d + size: 954962 + subdir: linux-64 + timestamp: 1777986471789 + version: 3.53.1 + fn: libsqlite-3.53.1-h0c1763c_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libsqlite-3.53.1-h0c1763c_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h25fd6f3_2 + build_number: 2 + constrains: + - zlib 1.3.2 *_2 + depends: + - __glibc >=2.17,<3.0.a0 + license: Zlib + license_family: Other + md5: d87ff7921124eccd67248aa483c23fec + name: libzlib + run_exports: + weak: + - libzlib >=1.3.2,<2.0a0 + sha256: 55044c403570f0dc26e6364de4dc5368e5f3fc7ff103e867c487e2b5ab2bcda9 + size: 63629 + subdir: linux-64 + timestamp: 1774072609062 + version: 1.3.2 + fn: libzlib-1.3.2-h25fd6f3_2.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libzlib-1.3.2-h25fd6f3_2.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h5347b49_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: BSD-3-Clause + license_family: BSD + md5: 38ffe67b78c9d4de527be8315e5ada2c + name: libuuid + run_exports: + weak: + - libuuid >=2.42,<3.0a0 + sha256: bc1b08c92626c91500fd9f26f2c797f3eb153b627d53e9c13cd167f1e12b2829 + size: 40297 + subdir: linux-64 + timestamp: 1775052476770 + version: '2.42' + fn: libuuid-2.42-h5347b49_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libuuid-2.42-h5347b49_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hd590300_1 + build_number: 1 + depends: + - libgcc-ng >=12 + license: LGPL-2.1-or-later + md5: 5aa797f8787fe7a17d1b0821485b5adc + name: libxcrypt + run_exports: + weak: + - libxcrypt >=4.4.36 + sha256: 6ae68e0b86423ef188196fff6207ed0c8195dd84273cb5623b85aa08033a410c + size: 100393 + subdir: linux-64 + timestamp: 1702724383534 + version: 4.4.36 + fn: libxcrypt-4.4.36-hd590300_1.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libxcrypt-4.4.36-hd590300_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h69a702a_19 + build_number: 19 + depends: + - libgcc 15.2.0 he0feb66_19 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + md5: 331ee9b72b9dff570d56b1302c5ab37d + name: libgcc-ng + run_exports: + strong: + - libgcc + sha256: 9dcf54adfaa5e861123c2da4f2f0451a685464ea7e5a41ad91cf67b31d658d98 + size: 27694 + subdir: linux-64 + timestamp: 1778269016987 + version: 15.2.0 + fn: libgcc-ng-15.2.0-h69a702a_19.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgcc-ng-15.2.0-h69a702a_19.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hdb14827_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + license: X11 AND BSD-3-Clause + md5: fc21868a1a5aacc937e7a18747acb8a5 + name: ncurses + run_exports: + weak: + - ncurses >=6.6,<7.0a0 + sha256: fc89f74bbe362fb29fa3c037697a89bec140b346a2469a90f7936d1d7ea4d8a3 + size: 918956 + subdir: linux-64 + timestamp: 1777422145199 + version: '6.6' + fn: ncurses-6.6-hdb14827_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/ncurses-6.6-hdb14827_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: h35e630c_0 + build_number: 0 + depends: + - __glibc >=2.17,<3.0.a0 + - ca-certificates + - libgcc >=14 + license: Apache-2.0 + license_family: Apache + md5: da1b85b6a87e141f5140bb9924cecab0 + name: openssl + run_exports: + weak: + - openssl >=3.6.2,<4.0a0 + sha256: c0ef482280e38c71a08ad6d71448194b719630345b0c9c60744a2010e8a8e0cb + size: 3167099 + subdir: linux-64 + timestamp: 1775587756857 + version: 3.6.2 + fn: openssl-3.6.2-h35e630c_0.conda + url: https://conda.anaconda.org/conda-forge/linux-64/openssl-3.6.2-h35e630c_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: noxft_h366c992_103 + build_number: 103 + constrains: + - xorg-libx11 >=1.8.12,<2.0a0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=14 + - libzlib >=1.3.1,<2.0a0 + license: TCL + license_family: BSD + md5: cffd3bdd58090148f4cfcd831f4b26ab + name: tk + run_exports: + weak: + - tk >=8.6.13,<8.7.0a0 + sha256: cafeec44494f842ffeca27e9c8b0c27ed714f93ac77ddadc6aaf726b5554ebac + size: 3301196 + subdir: linux-64 + timestamp: 1769460227866 + version: 8.6.13 + fn: tk-8.6.13-noxft_h366c992_103.conda + url: https://conda.anaconda.org/conda-forge/linux-64/tk-8.6.13-noxft_h366c992_103.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hc9c84f9_1 + build_number: 1 + depends: [] + license: LicenseRef-Public-Domain + md5: ad659d0a2b3e47e38d829aa8cad2d610 + name: tzdata + noarch: generic + run_exports: {} + sha256: 1d30098909076af33a35017eed6f2953af1c769e273a0626a04722ac4acaba3c + size: 119135 + subdir: noarch + timestamp: 1767016325805 + version: 2025c + fn: tzdata-2025c-hc9c84f9_1.conda + url: https://conda.anaconda.org/conda-forge/noarch/tzdata-2025c-hc9c84f9_1.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: pyhc364b38_0 + build_number: 0 + depends: + - python >=3.8 + - python + license: Apache-2.0 + license_family: APACHE + md5: 4c06a92e74452cfa53623a81592e8934 + name: packaging + noarch: python + run_exports: {} + sha256: 3906abfb6511a3bb309e39b9b1b7bc38f50a723971de2395489fd1f379255890 + size: 91574 + subdir: noarch + timestamp: 1777103621679 + version: '26.2' + fn: packaging-26.2-pyhc364b38_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/packaging-26.2-pyhc364b38_0.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hb78ec9c_6 + build_number: 6 + depends: + - __glibc >=2.17,<3.0.a0 + - libzlib >=1.3.1,<2.0a0 + license: BSD-3-Clause + license_family: BSD + md5: 4a13eeac0b5c8e5b8ab496e6c4ddd829 + name: zstd + run_exports: + weak: + - zstd >=1.5.7,<1.6.0a0 + sha256: 68f0206ca6e98fea941e5717cec780ed2873ffabc0e1ed34428c061e2c6268c7 + size: 601375 + subdir: linux-64 + timestamp: 1764777111296 + version: 1.5.7 + fn: zstd-1.5.7-hb78ec9c_6.conda + url: https://conda.anaconda.org/conda-forge/linux-64/zstd-1.5.7-hb78ec9c_6.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: 20_gnu + build_number: 20 + constrains: + - openmp_impl <0.0a0 + depends: + - __glibc >=2.17,<3.0.a0 + - libgomp >=7.5.0 + license: BSD-3-Clause + license_family: BSD + md5: a9f577daf3de00bca7c3c76c0ecbd1de + name: _openmp_mutex + run_exports: + strong: + - _openmp_mutex >=4.5 + sha256: 1dd3fffd892081df9726d7eb7e0dea6198962ba775bd88842135a4ddb4deb3c9 + size: 28948 + subdir: linux-64 + timestamp: 1770939786096 + version: '4.5' + fn: _openmp_mutex-4.5-20_gnu.conda + url: https://conda.anaconda.org/conda-forge/linux-64/_openmp_mutex-4.5-20_gnu.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: he0feb66_19 + build_number: 19 + depends: + - __glibc >=2.17,<3.0.a0 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + md5: faac990cb7aedc7f3a2224f2c9b0c26c + name: libgomp + run_exports: + strong: + - _openmp_mutex >=4.5 + sha256: 5abe4ab9d93f6c9757d654f1969ae2267d4505315c1f2f8fe705fd60af084f1b + size: 603817 + subdir: linux-64 + timestamp: 1778268942614 + version: 15.2.0 + fn: libgomp-15.2.0-he0feb66_19.conda + url: https://conda.anaconda.org/conda-forge/linux-64/libgomp-15.2.0-he0feb66_19.conda + channel: https://conda.anaconda.org/conda-forge/ + - build: hbd8a1cb_0 + build_number: 0 + depends: + - __unix + license: ISC + md5: e18ad67cf881dcadee8b8d9e2f8e5f73 + name: ca-certificates + noarch: generic + run_exports: {} + sha256: c9dbcc8039a52023660d6d1bbf87594a93dd69c6ac5a2a44323af2c92976728d + size: 131039 + subdir: noarch + timestamp: 1776865545798 + version: 2026.4.22 + fn: ca-certificates-2026.4.22-hbd8a1cb_0.conda + url: https://conda.anaconda.org/conda-forge/noarch/ca-certificates-2026.4.22-hbd8a1cb_0.conda + channel: https://conda.anaconda.org/conda-forge/ + run: + depends: + - source: python >=3.10 + - source: certifi >=2023.5.7 + - source: charset-normalizer >=2,<4 + - source: idna >=2.5,<4 + - source: urllib3 >=1.26,<3 + - spec: python + from: host + run_export: python + constraints: + - source: chardet >=3.0.2,<8 +finalized_sources: +- url: https://pypi.org/packages/source/r/requests/requests-2.34.0.tar.gz + sha256: 7d62fe92f50eb82c529b0916bb445afa1531a566fc8f35ffdc64446e771b856a +system_tools: + rattler-build: 0.64.1 +extra_meta: + flow_run_id: github_25697660708 + remote_url: https://github.com/conda-forge/requests-feedstock + sha: b3a09a06bfc1ca0bb82abbfdc105531340a8d689 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/recipe/variant_config.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/recipe/variant_config.yaml new file mode 100644 index 0000000000000000000000000000000000000000..9c9555bc0715cf4927cf43dc30e6dd1e88c57b9a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/recipe/variant_config.yaml @@ -0,0 +1,4 @@ +channel_sources: conda-forge +channel_targets: conda-forge main +python_min: '3.10' +target_platform: noarch diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/repodata_record.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/repodata_record.json new file mode 100644 index 0000000000000000000000000000000000000000..a5a3b17ef417d3d3380caedd36c822cf1a7760f1 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/repodata_record.json @@ -0,0 +1,28 @@ +{ + "build": "pyhcf101f3_0", + "build_number": 0, + "build_string": "pyhcf101f3_0", + "channel": "conda-forge", + "constrains": [ + "chardet >=3.0.2,<8" + ], + "depends": [ + "python >=3.10", + "certifi >=2023.5.7", + "charset-normalizer >=2,<4", + "idna >=2.5,<4", + "urllib3 >=1.26,<3", + "python" + ], + "fn": "requests-2.34.0-pyhcf101f3_0.conda", + "license": "Apache-2.0", + "md5": "a5985537dab1ba7034b5ff4ea22e2fa9", + "name": "requests", + "noarch": "python", + "sha256": "4487fdb341537e2df47159ed8e546add99080974c52d5b2dc2a710910619115a", + "size": 68658, + "subdir": "noarch", + "timestamp": 1778534036, + "url": "https://conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0.conda", + "version": "2.34.0" +} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/tests/tests.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/tests/tests.yaml new file mode 100644 index 0000000000000000000000000000000000000000..808c49dc10adf10f6e5b619c75c5d4292bd097bd --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/info/tests/tests.yaml @@ -0,0 +1,4 @@ +- python: + imports: + - requests + python_version: 3.10.* diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/INSTALLER b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/INSTALLER new file mode 100644 index 0000000000000000000000000000000000000000..a34a7e56db35cc4c85bfa166244b3d63a6a240d4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/INSTALLER @@ -0,0 +1 @@ +conda diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/METADATA b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/METADATA new file mode 100644 index 0000000000000000000000000000000000000000..42eec28815385631d549cfb3edb71c4e5cbfa725 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/METADATA @@ -0,0 +1,120 @@ +Metadata-Version: 2.4 +Name: requests +Version: 2.34.0 +Summary: Python HTTP for Humans. +Author-email: Kenneth Reitz <me@kennethreitz.org> +Maintainer-email: Ian Stapleton Cordasco <graffatcolmingov@gmail.com>, Nate Prewitt <nate.prewitt@gmail.com> +License: Apache-2.0 +Project-URL: Documentation, https://requests.readthedocs.io +Project-URL: Source, https://github.com/psf/requests +Classifier: Development Status :: 5 - Production/Stable +Classifier: Environment :: Web Environment +Classifier: Intended Audience :: Developers +Classifier: License :: OSI Approved :: Apache Software License +Classifier: Natural Language :: English +Classifier: Operating System :: OS Independent +Classifier: Programming Language :: Python +Classifier: Programming Language :: Python :: 3 +Classifier: Programming Language :: Python :: 3.10 +Classifier: Programming Language :: Python :: 3.11 +Classifier: Programming Language :: Python :: 3.12 +Classifier: Programming Language :: Python :: 3.13 +Classifier: Programming Language :: Python :: 3.14 +Classifier: Programming Language :: Python :: 3.15 +Classifier: Programming Language :: Python :: 3 :: Only +Classifier: Programming Language :: Python :: Implementation :: CPython +Classifier: Programming Language :: Python :: Implementation :: PyPy +Classifier: Programming Language :: Python :: Free Threading :: 2 - Beta +Classifier: Topic :: Internet :: WWW/HTTP +Classifier: Topic :: Software Development :: Libraries +Requires-Python: >=3.10 +Description-Content-Type: text/markdown +License-File: LICENSE +License-File: NOTICE +Requires-Dist: charset_normalizer<4,>=2 +Requires-Dist: idna<4,>=2.5 +Requires-Dist: urllib3<3,>=1.26 +Requires-Dist: certifi>=2023.5.7 +Provides-Extra: security +Provides-Extra: socks +Requires-Dist: PySocks!=1.5.7,>=1.5.6; extra == "socks" +Provides-Extra: use-chardet-on-py3 +Requires-Dist: chardet<8,>=3.0.2; extra == "use-chardet-on-py3" +Dynamic: license-file + +# Requests + +[![Version](https://img.shields.io/pypi/v/requests.svg?maxAge=86400)](https://pypi.org/project/requests/) +[![Supported Versions](https://img.shields.io/pypi/pyversions/requests.svg)](https://pypi.org/project/requests) +[![Downloads](https://static.pepy.tech/badge/requests/month)](https://pepy.tech/project/requests) +[![Contributors](https://img.shields.io/github/contributors/psf/requests.svg)](https://github.com/psf/requests/graphs/contributors) +[![Documentation](https://readthedocs.org/projects/requests/badge/?version=latest)](https://requests.readthedocs.io) + +**Requests** is a simple, yet elegant, HTTP library. + +```python +>>> import requests +>>> r = requests.get('https://httpbin.org/basic-auth/user/pass', auth=('user', 'pass')) +>>> r.status_code +200 +>>> r.headers['content-type'] +'application/json; charset=utf8' +>>> r.encoding +'utf-8' +>>> r.text +'{"authenticated": true, ...' +>>> r.json() +{'authenticated': True, ...} +``` + +Requests allows you to send HTTP/1.1 requests extremely easily. There’s no need to manually add query strings to your URLs, or to form-encode your `PUT` & `POST` data — but nowadays, just use the `json` method! + +Requests is one of the most downloaded Python packages today, pulling in around `300M downloads / week` — according to GitHub, Requests is currently [depended upon](https://github.com/psf/requests/network/dependents?package_id=UGFja2FnZS01NzA4OTExNg%3D%3D) by `4,000,000+` repositories. + +## Installing Requests and Supported Versions + +Requests is available on PyPI: + +```console +$ python -m pip install requests +``` + +Requests officially supports Python 3.10+. + +## Supported Features & Best–Practices + +Requests is ready for the demands of building robust and reliable HTTP–speaking applications, for the needs of today. + +- Keep-Alive & Connection Pooling +- International Domains and URLs +- Sessions with Cookie Persistence +- Browser-style TLS/SSL Verification +- Basic & Digest Authentication +- Familiar `dict`–like Cookies +- Automatic Content Decompression and Decoding +- Multi-part File Uploads +- SOCKS Proxy Support +- Connection Timeouts +- Streaming Downloads +- Automatic honoring of `.netrc` +- Chunked HTTP Requests + +## Cloning the repository + +When cloning the Requests repository, you may need to add the `-c +fetch.fsck.badTimezone=ignore` flag to avoid an error about a bad commit timestamp (see +[this issue](https://github.com/psf/requests/issues/2690) for more background): + +```shell +git clone -c fetch.fsck.badTimezone=ignore https://github.com/psf/requests.git +``` + +You can also apply this setting to your global Git config: + +```shell +git config --global fetch.fsck.badTimezone ignore +``` + +--- + +[![Kenneth Reitz](https://raw.githubusercontent.com/psf/requests/main/ext/kr.png)](https://kennethreitz.org) [![Python Software Foundation](https://raw.githubusercontent.com/psf/requests/main/ext/psf.png)](https://www.python.org/psf) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/RECORD b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/RECORD new file mode 100644 index 0000000000000000000000000000000000000000..435d76a9d5a534a9e77ce7fb873c132a97c0a7be --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/RECORD @@ -0,0 +1,48 @@ +requests-2.34.0.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +requests-2.34.0.dist-info/METADATA,sha256=64w-xXm2cnAgXrcsEJ6g6498dx3VZgqS8TRITZnoerk,4806 +requests-2.34.0.dist-info/RECORD,, +requests-2.34.0.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +requests-2.34.0.dist-info/WHEEL,sha256=aeYiig01lYGDzBgS8HxWXOg3uV61G9ijOsup-k9o1sk,91 +requests-2.34.0.dist-info/direct_url.json,sha256=43w_KkG9NqeJS9_dVXFMfn6YWsyansYisQ3qdgIBHtY,119 +requests-2.34.0.dist-info/licenses/LICENSE,sha256=CeipvOyAZxBGUsFoaFqwkx54aPnIKEtm9a5u2uXxEws,10142 +requests-2.34.0.dist-info/licenses/NOTICE,sha256=9REJct7a0rTp0xRRja87fXLW4C5Jms2AIYHeb3RXHcw,38 +requests-2.34.0.dist-info/top_level.txt,sha256=fMSVmHfb5rbGOo6xv-O_tUX6j-WyixssE-SnwcDRxNQ,9 +requests/__init__.py,sha256=MRFX5_pKqRZsgn1SN-b9aU7rXKVJ7kDi6Q-J8hq81W4,5922 +requests/__pycache__/__init__.cpython-310.pyc,, +requests/__pycache__/__version__.cpython-310.pyc,, +requests/__pycache__/_internal_utils.cpython-310.pyc,, +requests/__pycache__/_types.cpython-310.pyc,, +requests/__pycache__/adapters.cpython-310.pyc,, +requests/__pycache__/api.cpython-310.pyc,, +requests/__pycache__/auth.cpython-310.pyc,, +requests/__pycache__/certs.cpython-310.pyc,, +requests/__pycache__/compat.cpython-310.pyc,, +requests/__pycache__/cookies.cpython-310.pyc,, +requests/__pycache__/exceptions.cpython-310.pyc,, +requests/__pycache__/help.cpython-310.pyc,, +requests/__pycache__/hooks.cpython-310.pyc,, +requests/__pycache__/models.cpython-310.pyc,, +requests/__pycache__/packages.cpython-310.pyc,, +requests/__pycache__/sessions.cpython-310.pyc,, +requests/__pycache__/status_codes.cpython-310.pyc,, +requests/__pycache__/structures.cpython-310.pyc,, +requests/__pycache__/utils.cpython-310.pyc,, +requests/__version__.py,sha256=Uw6k1hzJNkFZyzAXYVHE-Qc_JiJOGDlZM6AsxLpMAyY,435 +requests/_internal_utils.py,sha256=TH2NEyyYmPx9cV5HPzrHR4XdxKuW0skkD4eDXcbZgf8,1542 +requests/_types.py,sha256=Z3uDlyGkslMrN0q5b0WQgqaL9KE-jL-Yi6p5Py926ec,5882 +requests/adapters.py,sha256=ZH6r1EU94jKqQLVf8DPW8Zd4kQt-cGnFH99jB2_HdJM,28064 +requests/api.py,sha256=TRVICsBG8Ikgl5joZQR270oo6-b4G0AHWPjvQuxrVQk,7152 +requests/auth.py,sha256=6TlRpVLUw8X9m4Sl4dSbA8qrpHI8T_ES2mBTYA7IWmU,12233 +requests/certs.py,sha256=_ZxrgzWc75D_bE7uq43MI4jaOC68p9AKSZs8C0NKh-Q,430 +requests/compat.py,sha256=XXm6KJaQtQFQRDQaH3vH0kE0_BOi2z78-FJRW_mqGLQ,2465 +requests/cookies.py,sha256=ChzmFA8rlCBSLFCA41bmifp5bCUi9VyhCCb17Y4Kcjw,21549 +requests/exceptions.py,sha256=xeGPM1JFSWjjN7swVvCGffLzfAoNLBp33AXn4LPAQRs,4564 +requests/help.py,sha256=cjUZuxiE2hjYT2svt49-v3-1f3MgcLYCWuBx2sai0Xk,4210 +requests/hooks.py,sha256=69igJHXTGg5HOo9VPpUB_0NkW5VjiFrVKETnpj8Ndqs,1138 +requests/models.py,sha256=PhqYjte-BQbUY_KJGMH4hYXtZm1Q0lboWEg0kwHL7-w,41698 +requests/packages.py,sha256=_g0gZ681UyAlKHRjH6kanbaoxx2eAb6qzcXiODyTIoc,904 +requests/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +requests/sessions.py,sha256=iuFhQXbkGx-MP7uGiTC1d0YqZmRSp0eelZ424p37Va8,34266 +requests/status_codes.py,sha256=GVD0fInPGAGXh-B9jOSPZtazjmIvfZTXCpAkf-5sBA4,4351 +requests/structures.py,sha256=upRgw5B48l5vHSokrJQaxvjS7pcZf6jI0MJi2KHmegI,4134 +requests/utils.py,sha256=ZX_QI0OyWGu9E4pOwPA87rdhDCcS-WrFTyinCL99B5w,36322 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/REQUESTED b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/REQUESTED new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/WHEEL b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/WHEEL new file mode 100644 index 0000000000000000000000000000000000000000..14a883f292bc96b20c2b76a3081991f2676523a9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/WHEEL @@ -0,0 +1,5 @@ +Wheel-Version: 1.0 +Generator: setuptools (82.0.1) +Root-Is-Purelib: true +Tag: py3-none-any + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/direct_url.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/direct_url.json new file mode 100644 index 0000000000000000000000000000000000000000..6aa5517e9c398242d744aa4b10611e6c1381685e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/direct_url.json @@ -0,0 +1 @@ +{"dir_info": {}, "url": "file:///home/conda/feedstock_root/build_artifacts/bld/rattler-build_requests_1778534036/work"} \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..67db8588217f266eb561f75fae738656325deac9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/licenses/LICENSE @@ -0,0 +1,175 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/licenses/NOTICE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/licenses/NOTICE new file mode 100644 index 0000000000000000000000000000000000000000..1ff62db688277b77c83c1766dac7f165364d3528 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/licenses/NOTICE @@ -0,0 +1,2 @@ +Requests +Copyright 2019 Kenneth Reitz diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/top_level.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/top_level.txt new file mode 100644 index 0000000000000000000000000000000000000000..f2293605cf1b01dca72aad0a15c45b72ed5429a2 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests-2.34.0.dist-info/top_level.txt @@ -0,0 +1 @@ +requests diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..ad842400b99c65c91988579e76419cf48224a680 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/__init__.py @@ -0,0 +1,219 @@ +# __ +# /__) _ _ _ _ _/ _ +# / ( (- (/ (/ (- _) / _) +# / + +""" +Requests HTTP Library +~~~~~~~~~~~~~~~~~~~~~ + +Requests is an HTTP library, written in Python, for human beings. +Basic GET usage: + + >>> import requests + >>> r = requests.get('https://www.python.org') + >>> r.status_code + 200 + >>> b'Python is a programming language' in r.content + True + +... or POST: + + >>> payload = dict(key1='value1', key2='value2') + >>> r = requests.post('https://httpbin.org/post', data=payload) + >>> print(r.text) + { + ... + "form": { + "key1": "value1", + "key2": "value2" + }, + ... + } + +The other HTTP methods are supported - see `requests.api`. Full documentation +is at <https://requests.readthedocs.io>. + +:copyright: (c) 2017 by Kenneth Reitz. +:license: Apache 2.0, see LICENSE for more details. +""" + +from __future__ import annotations + +import warnings + +import urllib3 + +from .exceptions import RequestsDependencyWarning + +try: + from charset_normalizer import __version__ as charset_normalizer_version +except ImportError: + charset_normalizer_version = None + +try: + from chardet import __version__ as chardet_version # type: ignore[import-not-found] +except ImportError: + chardet_version = None + + +def check_compatibility( + urllib3_version: str, + chardet_version: str | None, + charset_normalizer_version: str | None, +) -> None: + urllib3_version_list = urllib3_version.split(".")[:3] + assert urllib3_version_list != ["dev"] # Verify urllib3 isn't installed from git. + + # Sometimes, urllib3 only reports its version as 16.1. + if len(urllib3_version_list) == 2: + urllib3_version_list.append("0") + + # Check urllib3 for compatibility. + major, minor, patch = urllib3_version_list # noqa: F811 + major, minor, patch = int(major), int(minor), int(patch) + # urllib3 >= 1.21.1 + assert major >= 1 + if major == 1: + assert minor >= 21 + + # Check charset_normalizer for compatibility. + if chardet_version: + major, minor, patch = chardet_version.split(".")[:3] + major, minor, patch = int(major), int(minor), int(patch) + # chardet_version >= 3.0.2, < 8.0.0 + assert (3, 0, 2) <= (major, minor, patch) < (8, 0, 0) + elif charset_normalizer_version: + major, minor, patch = charset_normalizer_version.split(".")[:3] + major, minor, patch = int(major), int(minor), int(patch) + # charset_normalizer >= 2.0.0 < 4.0.0 + assert (2, 0, 0) <= (major, minor, patch) < (4, 0, 0) + else: + warnings.warn( + "Unable to find acceptable character detection dependency " + "(chardet or charset_normalizer).", + RequestsDependencyWarning, + ) + + +def _check_cryptography(cryptography_version: str) -> None: + # cryptography < 1.3.4 + try: + cryptography_version_list = list(map(int, cryptography_version.split("."))) + except ValueError: + return + + if cryptography_version_list < [1, 3, 4]: + warning = f"Old version of cryptography ({cryptography_version_list}) may cause slowdown." + warnings.warn(warning, RequestsDependencyWarning) + + +# Check imported dependencies for compatibility. +try: + check_compatibility( + urllib3.__version__, # type: ignore[reportPrivateImportUsage] + chardet_version, # type: ignore[reportUnknownArgumentType] + charset_normalizer_version, + ) +except (AssertionError, ValueError): + warnings.warn( + f"urllib3 ({urllib3.__version__}) or chardet " # type: ignore[reportPrivateImportUsage] + f"({chardet_version})/charset_normalizer ({charset_normalizer_version}) " + "doesn't match a supported version!", + RequestsDependencyWarning, + ) + +# Attempt to enable urllib3's fallback for SNI support +# if the standard library doesn't support SNI or the +# 'ssl' library isn't available. +try: + try: + import ssl + except ImportError: + ssl = None + + if not getattr(ssl, "HAS_SNI", False): + from urllib3.contrib import pyopenssl + + pyopenssl.inject_into_urllib3() + + # Check cryptography version + from cryptography import ( # type: ignore[reportMissingImports] + __version__ as cryptography_version, # type: ignore[reportUnknownVariableType] + ) + + _check_cryptography(cryptography_version) # type: ignore[reportUnknownArgumentType] +except ImportError: + pass + +# urllib3's DependencyWarnings should be silenced. +from urllib3.exceptions import DependencyWarning + +warnings.simplefilter("ignore", DependencyWarning) + +# Set default logging handler to avoid "No handler found" warnings. +import logging +from logging import NullHandler + +from . import packages, utils +from .__version__ import ( + __author__, + __author_email__, + __build__, + __cake__, + __copyright__, + __description__, + __license__, + __title__, + __url__, + __version__, +) +from .api import delete, get, head, options, patch, post, put, request +from .exceptions import ( + ConnectionError, + ConnectTimeout, + FileModeWarning, + HTTPError, + JSONDecodeError, + ReadTimeout, + RequestException, + Timeout, + TooManyRedirects, + URLRequired, +) +from .models import PreparedRequest, Request, Response +from .sessions import Session, session +from .status_codes import codes + +__all__ = ( + "ConnectionError", + "ConnectTimeout", + "HTTPError", + "JSONDecodeError", + "PreparedRequest", + "ReadTimeout", + "Request", + "RequestException", + "Response", + "Session", + "Timeout", + "TooManyRedirects", + "URLRequired", + "codes", + "delete", + "get", + "head", + "options", + "packages", + "patch", + "post", + "put", + "request", + "session", + "utils", +) + +logging.getLogger(__name__).addHandler(NullHandler()) + +# FileModeWarnings go off per the default. +warnings.simplefilter("default", FileModeWarning, append=True) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/__version__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/__version__.py new file mode 100644 index 0000000000000000000000000000000000000000..872a8aaa227c3b6a38008d06c4c433c80e30a3e9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/__version__.py @@ -0,0 +1,14 @@ +# .-. .-. .-. . . .-. .-. .-. .-. +# |( |- |.| | | |- `-. | `-. +# ' ' `-' `-`.`-' `-' `-' ' `-' + +__title__ = "requests" +__description__ = "Python HTTP for Humans." +__url__ = "https://requests.readthedocs.io" +__version__ = "2.34.0" +__build__ = 0x023400 +__author__ = "Kenneth Reitz" +__author_email__ = "me@kennethreitz.org" +__license__ = "Apache-2.0" +__copyright__ = "Copyright Kenneth Reitz" +__cake__ = "\u2728 \U0001f370 \u2728" diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/_internal_utils.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/_internal_utils.py new file mode 100644 index 0000000000000000000000000000000000000000..0466a7d347db4ed34a37db51b75fc8e80bc06055 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/_internal_utils.py @@ -0,0 +1,51 @@ +""" +requests._internal_utils +~~~~~~~~~~~~~~ + +Provides utility functions that are consumed internally by Requests +which depend on extremely few external helpers (such as compat) +""" + +import re + +from .compat import builtin_str + +_VALID_HEADER_NAME_RE_BYTE = re.compile(rb"^[^:\s][^:\r\n]*\Z") +_VALID_HEADER_NAME_RE_STR = re.compile(r"^[^:\s][^:\r\n]*\Z") +_VALID_HEADER_VALUE_RE_BYTE = re.compile(rb"^\S[^\r\n]*\Z|^\Z") +_VALID_HEADER_VALUE_RE_STR = re.compile(r"^\S[^\r\n]*\Z|^\Z") + +_HEADER_VALIDATORS_STR = (_VALID_HEADER_NAME_RE_STR, _VALID_HEADER_VALUE_RE_STR) +_HEADER_VALIDATORS_BYTE = (_VALID_HEADER_NAME_RE_BYTE, _VALID_HEADER_VALUE_RE_BYTE) +HEADER_VALIDATORS = { + bytes: _HEADER_VALIDATORS_BYTE, + str: _HEADER_VALIDATORS_STR, +} + + +def to_native_string(string: str | bytes, encoding: str = "ascii") -> str: + """Given a string object, regardless of type, returns a representation of + that string in the native string type, encoding and decoding where + necessary. This assumes ASCII unless told otherwise. + """ + if isinstance(string, builtin_str): + out = string + else: + out = string.decode(encoding) + + return out + + +def unicode_is_ascii(u_string: str) -> bool: + """Determine if unicode string only contains ASCII characters. + + :param str u_string: unicode string to check. Must be unicode + and not Python 2 `str`. + :rtype: bool + """ + assert isinstance(u_string, str) + try: + u_string.encode("ascii") + return True + except UnicodeEncodeError: + return False diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/_types.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/_types.py new file mode 100644 index 0000000000000000000000000000000000000000..963867b0126c72d73f9c4edca94f5bd4d78d9515 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/_types.py @@ -0,0 +1,178 @@ +""" +requests._types +~~~~~~~~~~~~~~~ + +This module contains type aliases used internally by the Requests library. +These types are not part of the public API and must not be relied upon +by external code. +""" + +from __future__ import annotations + +from collections.abc import Callable, Iterable, Mapping, MutableMapping +from typing import ( + TYPE_CHECKING, + Any, + Protocol, + TypeAlias, + TypeVar, + runtime_checkable, +) + +_T_co = TypeVar("_T_co", covariant=True) +_KT_co = TypeVar("_KT_co", covariant=True) +_VT_co = TypeVar("_VT_co", covariant=True) + + +@runtime_checkable +class SupportsRead(Protocol[_T_co]): + def read(self, length: int = ..., /) -> _T_co: ... + + +@runtime_checkable +class SupportsItems(Protocol[_KT_co, _VT_co]): + def items(self) -> Iterable[tuple[_KT_co, _VT_co]]: ... + + +# These are needed at runtime for default_hooks() return type +HookType: TypeAlias = Callable[["Response"], Any] +HooksInputType: TypeAlias = Mapping[str, Iterable[HookType] | HookType] + + +def is_prepared(request: PreparedRequest) -> TypeIs[_ValidatedRequest]: + """Verify a PreparedRequest has been fully prepared.""" + if TYPE_CHECKING: + return request.url is not None and request.method is not None + # noop at runtime to avoid AssertionError + return True + + +if TYPE_CHECKING: + from http.cookiejar import CookieJar + from typing import TypeAlias, TypedDict + + from typing_extensions import ( + Buffer, # TODO: move to collections.abc when Python >= 3.12 + TypeIs, # TODO: move to typing when Python >= 3.13 + ) + + from .auth import AuthBase + from .cookies import RequestsCookieJar + from .models import PreparedRequest, Response + from .structures import CaseInsensitiveDict + + class _ValidatedRequest(PreparedRequest): + """Subtype asserting a PreparedRequest has been fully prepared before calling. + + The override suppression is required because mutable attribute types are + invariant (Liskov), but we only narrow after preparation is complete. This + is the explicit contract for Requests but Python's typing doesn't have a + better way to represent the requirement. + """ + + url: str # type: ignore[reportIncompatibleVariableOverride] + method: str # type: ignore[reportIncompatibleVariableOverride] + + # Type aliases for core API concepts (ordered by request() signature) + UriType: TypeAlias = str | bytes + + _ParamsMappingKeyType: TypeAlias = str | bytes | int | float + _ParamsMappingValueType: TypeAlias = ( + str | bytes | int | float | Iterable[str | bytes | int | float] | None + ) + ParamsType: TypeAlias = ( + SupportsItems[_ParamsMappingKeyType, _ParamsMappingValueType] + | tuple[tuple[_ParamsMappingKeyType, _ParamsMappingValueType], ...] + | Iterable[tuple[_ParamsMappingKeyType, _ParamsMappingValueType]] + | str + | bytes + | None + ) + + KVDataType: TypeAlias = Iterable[tuple[Any, Any]] | SupportsItems[Any, Any] + + RawDataType: TypeAlias = KVDataType | str | bytes + StreamDataType: TypeAlias = SupportsRead[str | bytes] + EncodableDataType: TypeAlias = RawDataType | StreamDataType + + DataType: TypeAlias = ( + KVDataType + | Iterable[bytes | str] + | str + | bytes + | Buffer + | SupportsRead[str | bytes] + | None + ) + + BodyType: TypeAlias = ( + bytes | str | Iterable[bytes | str] | SupportsRead[bytes | str] | None + ) + + HeadersType: TypeAlias = CaseInsensitiveDict[str] | Mapping[str, str | bytes] + HeadersUpdateType: TypeAlias = Mapping[str, str | bytes | None] + + CookiesType: TypeAlias = RequestsCookieJar | Mapping[str, str] + + # Building blocks for FilesType + _FileName: TypeAlias = str | None + _FileContent: TypeAlias = SupportsRead[str | bytes] | str | bytes + _FileSpecBasic: TypeAlias = tuple[_FileName, _FileContent] + _FileSpecWithContentType: TypeAlias = tuple[_FileName, _FileContent, str] + _FileSpecWithHeaders: TypeAlias = tuple[ + _FileName, _FileContent, str, CaseInsensitiveDict[str] | Mapping[str, str] + ] + _FileSpec: TypeAlias = ( + _FileContent | _FileSpecBasic | _FileSpecWithContentType | _FileSpecWithHeaders + ) + FilesType: TypeAlias = ( + Mapping[str, _FileSpec] | Iterable[tuple[str, _FileSpec]] | None + ) + + AuthType: TypeAlias = ( + tuple[str, str] | AuthBase | Callable[[PreparedRequest], PreparedRequest] | None + ) + + TimeoutType: TypeAlias = float | tuple[float | None, float | None] | None + ProxiesType: TypeAlias = MutableMapping[str, str] + HooksType: TypeAlias = dict[str, list[HookType]] | None + VerifyType: TypeAlias = bool | str + CertType: TypeAlias = str | tuple[str, str] | None + JsonType: TypeAlias = ( + None | bool | int | float | str | list["JsonType"] | dict[str, "JsonType"] + ) + + # TypedDicts for Unpack kwargs (PEP 692) + + class BaseRequestKwargs(TypedDict, total=False): + headers: Mapping[str, str | bytes] | None + cookies: RequestsCookieJar | CookieJar | dict[str, str] | None + files: FilesType + auth: AuthType + timeout: TimeoutType + allow_redirects: bool + proxies: dict[str, str] | None + hooks: HooksInputType | None + stream: bool | None + verify: VerifyType | None + cert: CertType + + class RequestKwargs(BaseRequestKwargs, total=False): + """kwargs for request(), options(), head(), delete().""" + + params: ParamsType + data: DataType + json: JsonType + + class GetKwargs(BaseRequestKwargs, total=False): + data: DataType + json: JsonType + + class PostKwargs(BaseRequestKwargs, total=False): + params: ParamsType + + class DataKwargs(BaseRequestKwargs, total=False): + """kwargs for put(), patch().""" + + params: ParamsType + json: JsonType diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/adapters.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/adapters.py new file mode 100644 index 0000000000000000000000000000000000000000..40fe8a6d5a6168ba7303b91477af925db0aa3914 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/adapters.py @@ -0,0 +1,748 @@ +""" +requests.adapters +~~~~~~~~~~~~~~~~~ + +This module contains the transport adapters that Requests uses to define +and maintain connections. +""" + +from __future__ import annotations + +import os.path +import socket # noqa: F401 # type: ignore[reportUnusedImport] +import typing +import warnings +from typing import Any + +from urllib3.exceptions import ( + ClosedPoolError, + ConnectTimeoutError, + LocationValueError, + MaxRetryError, + NewConnectionError, + ProtocolError, + ReadTimeoutError, + ResponseError, +) +from urllib3.exceptions import HTTPError as _HTTPError +from urllib3.exceptions import InvalidHeader as _InvalidHeader +from urllib3.exceptions import ProxyError as _ProxyError +from urllib3.exceptions import SSLError as _SSLError +from urllib3.poolmanager import PoolManager, proxy_from_url +from urllib3.util import Timeout as TimeoutSauce +from urllib3.util import parse_url +from urllib3.util.retry import Retry + +from .auth import _basic_auth_str # type: ignore[reportPrivateUsage] +from .compat import basestring, urlparse +from .cookies import extract_cookies_to_jar +from .exceptions import ( + ConnectionError, + ConnectTimeout, + InvalidHeader, + InvalidProxyURL, + InvalidSchema, + InvalidURL, + ProxyError, + ReadTimeout, + RetryError, + SSLError, +) +from .models import Response +from .structures import CaseInsensitiveDict +from .utils import ( + DEFAULT_CA_BUNDLE_PATH, + get_auth_from_url, + get_encoding_from_headers, + prepend_scheme_if_needed, + select_proxy, + urldefragauth, +) + +try: + from urllib3.contrib.socks import SOCKSProxyManager # type: ignore[assignment] +except ImportError: + + def SOCKSProxyManager(*args: Any, **kwargs: Any) -> None: + raise InvalidSchema("Missing dependencies for SOCKS support.") + + +if typing.TYPE_CHECKING: + from urllib3.connectionpool import HTTPConnectionPool + from urllib3.poolmanager import PoolManager as _PoolManager + + from . import _types as _t + from .models import PreparedRequest + +from ._types import is_prepared as _is_prepared + +DEFAULT_POOLBLOCK = False +DEFAULT_POOLSIZE = 10 +DEFAULT_RETRIES = 0 +DEFAULT_POOL_TIMEOUT = None + + +def _urllib3_request_context( + request: PreparedRequest, + verify: bool | str | None, + client_cert: tuple[str, str] | str | None, + poolmanager: PoolManager, +) -> tuple[dict[str, Any], dict[str, Any]]: + host_params: dict[str, Any] = {} + pool_kwargs: dict[str, Any] = {} + parsed_request_url = urlparse(request.url) + scheme = parsed_request_url.scheme.lower() + port = parsed_request_url.port + + cert_reqs = "CERT_REQUIRED" + if verify is False: + cert_reqs = "CERT_NONE" + elif isinstance(verify, str): + if not os.path.isdir(verify): + pool_kwargs["ca_certs"] = verify + else: + pool_kwargs["ca_cert_dir"] = verify + pool_kwargs["cert_reqs"] = cert_reqs + if client_cert is not None: + if isinstance(client_cert, tuple) and len(client_cert) == 2: + pool_kwargs["cert_file"] = client_cert[0] + pool_kwargs["key_file"] = client_cert[1] + else: + # According to our docs, we allow users to specify just the client + # cert path + pool_kwargs["cert_file"] = client_cert + host_params = { + "scheme": scheme, + "host": parsed_request_url.hostname, + "port": port, + } + return host_params, pool_kwargs + + +class BaseAdapter: + """The Base Transport Adapter""" + + def __init__(self) -> None: + super().__init__() + + def send( + self, + request: PreparedRequest, + stream: bool = False, + timeout: _t.TimeoutType = None, + verify: _t.VerifyType = True, + cert: _t.CertType = None, + proxies: dict[str, str] | None = None, + ) -> Response: + """Sends PreparedRequest object. Returns Response object. + + :param request: The :class:`PreparedRequest <PreparedRequest>` being sent. + :param stream: (optional) Whether to stream the request content. + :param timeout: (optional) How long to wait for the server to send + data before giving up, as a float, or a :ref:`(connect timeout, + read timeout) <timeouts>` tuple. + :type timeout: float or tuple + :param verify: (optional) Either a boolean, in which case it controls whether we verify + the server's TLS certificate, or a string, in which case it must be a path + to a CA bundle to use + :param cert: (optional) Any user-provided SSL certificate to be trusted. + :param proxies: (optional) The proxies dictionary to apply to the request. + """ + raise NotImplementedError + + def close(self) -> None: + """Cleans up adapter specific items.""" + raise NotImplementedError + + +class HTTPAdapter(BaseAdapter): + """The built-in HTTP Adapter for urllib3. + + Provides a general-case interface for Requests sessions to contact HTTP and + HTTPS urls by implementing the Transport Adapter interface. This class will + usually be created by the :class:`Session <Session>` class under the + covers. + + :param pool_connections: The number of urllib3 connection pools to cache. + :param pool_maxsize: The maximum number of connections to save in the pool. + :param max_retries: The maximum number of retries each connection + should attempt. Note, this applies only to failed DNS lookups, socket + connections and connection timeouts, never to requests where data has + made it to the server. By default, Requests does not retry failed + connections. If you need granular control over the conditions under + which we retry a request, import urllib3's ``Retry`` class and pass + that instead. + :param pool_block: Whether the connection pool should block for connections. + + Usage:: + + >>> import requests + >>> s = requests.Session() + >>> a = requests.adapters.HTTPAdapter(max_retries=3) + >>> s.mount('http://', a) + """ + + __attrs__: list[str] = [ + "max_retries", + "config", + "_pool_connections", + "_pool_maxsize", + "_pool_block", + ] + + max_retries: Retry + config: dict[str, Any] + proxy_manager: dict[str, Any] + _pool_connections: int + _pool_maxsize: int + _pool_block: bool + poolmanager: _PoolManager + + def __init__( + self, + pool_connections: int = DEFAULT_POOLSIZE, + pool_maxsize: int = DEFAULT_POOLSIZE, + max_retries: int | Retry = DEFAULT_RETRIES, + pool_block: bool = DEFAULT_POOLBLOCK, + ) -> None: + if max_retries == DEFAULT_RETRIES: + self.max_retries = Retry(0, read=False) + else: + self.max_retries = Retry.from_int(max_retries) + self.config = {} + self.proxy_manager = {} + + super().__init__() + + self._pool_connections = pool_connections + self._pool_maxsize = pool_maxsize + self._pool_block = pool_block + + self.init_poolmanager(pool_connections, pool_maxsize, block=pool_block) + + def __getstate__(self) -> dict[str, Any]: + return {attr: getattr(self, attr, None) for attr in self.__attrs__} + + def __setstate__(self, state: dict[str, Any]) -> None: + # Can't handle by adding 'proxy_manager' to self.__attrs__ because + # self.poolmanager uses a lambda function, which isn't pickleable. + self.proxy_manager = {} + self.config = {} + + for attr, value in state.items(): + setattr(self, attr, value) + + self.init_poolmanager( + self._pool_connections, self._pool_maxsize, block=self._pool_block + ) + + def init_poolmanager( + self, + connections: int, + maxsize: int, + block: bool = DEFAULT_POOLBLOCK, + **pool_kwargs: Any, + ) -> None: + """Initializes a urllib3 PoolManager. + + This method should not be called from user code, and is only + exposed for use when subclassing the + :class:`HTTPAdapter <requests.adapters.HTTPAdapter>`. + + :param connections: The number of urllib3 connection pools to cache. + :param maxsize: The maximum number of connections to save in the pool. + :param block: Block when no free connections are available. + :param pool_kwargs: Extra keyword arguments used to initialize the Pool Manager. + """ + # save these values for pickling + self._pool_connections = connections + self._pool_maxsize = maxsize + self._pool_block = block + + self.poolmanager = PoolManager( + num_pools=connections, + maxsize=maxsize, + block=block, + **pool_kwargs, + ) + + def proxy_manager_for(self, proxy: str, **proxy_kwargs: Any) -> Any: + """Return urllib3 ProxyManager for the given proxy. + + This method should not be called from user code, and is only + exposed for use when subclassing the + :class:`HTTPAdapter <requests.adapters.HTTPAdapter>`. + + :param proxy: The proxy to return a urllib3 ProxyManager for. + :param proxy_kwargs: Extra keyword arguments used to configure the Proxy Manager. + :returns: ProxyManager + :rtype: urllib3.ProxyManager + """ + if proxy in self.proxy_manager: + manager = self.proxy_manager[proxy] + elif proxy.lower().startswith("socks"): + username, password = get_auth_from_url(proxy) + manager = self.proxy_manager[proxy] = SOCKSProxyManager( + proxy, + username=username, + password=password, + num_pools=self._pool_connections, + maxsize=self._pool_maxsize, + block=self._pool_block, + **proxy_kwargs, + ) + else: + proxy_headers = self.proxy_headers(proxy) + manager = self.proxy_manager[proxy] = proxy_from_url( + proxy, + proxy_headers=proxy_headers, + num_pools=self._pool_connections, + maxsize=self._pool_maxsize, + block=self._pool_block, + **proxy_kwargs, + ) + + return manager + + def cert_verify( + self, conn: Any, url: str, verify: _t.VerifyType, cert: _t.CertType + ) -> None: + """Verify a SSL certificate. This method should not be called from user + code, and is only exposed for use when subclassing the + :class:`HTTPAdapter <requests.adapters.HTTPAdapter>`. + + :param conn: The urllib3 connection object associated with the cert. + :param url: The requested URL. + :param verify: Either a boolean, in which case it controls whether we verify + the server's TLS certificate, or a string, in which case it must be a path + to a CA bundle to use + :param cert: The SSL certificate to verify. + """ + if url.lower().startswith("https") and verify: + cert_loc = None + + # Allow self-specified cert location. + if verify is not True: + cert_loc = verify + + if not cert_loc: + cert_loc = DEFAULT_CA_BUNDLE_PATH + + if not cert_loc or not os.path.exists(cert_loc): + raise OSError( + f"Could not find a suitable TLS CA certificate bundle, " + f"invalid path: {cert_loc}" + ) + + conn.cert_reqs = "CERT_REQUIRED" + + if not os.path.isdir(cert_loc): + conn.ca_certs = cert_loc + else: + conn.ca_cert_dir = cert_loc + else: + conn.cert_reqs = "CERT_NONE" + conn.ca_certs = None + conn.ca_cert_dir = None + + if cert: + if not isinstance(cert, basestring): + conn.cert_file = cert[0] + conn.key_file = cert[1] + else: + conn.cert_file = cert + conn.key_file = None + if conn.cert_file and not os.path.exists(conn.cert_file): + raise OSError( + f"Could not find the TLS certificate file, " + f"invalid path: {conn.cert_file}" + ) + if conn.key_file and not os.path.exists(conn.key_file): + raise OSError( + f"Could not find the TLS key file, invalid path: {conn.key_file}" + ) + + def build_response(self, req: PreparedRequest, resp: Any) -> Response: + """Builds a :class:`Response <requests.Response>` object from a urllib3 + response. This should not be called from user code, and is only exposed + for use when subclassing the + :class:`HTTPAdapter <requests.adapters.HTTPAdapter>` + + :param req: The :class:`PreparedRequest <PreparedRequest>` used to generate the response. + :param resp: The urllib3 response object. + :rtype: requests.Response + """ + assert _is_prepared(req) + response = Response() + + # Fallback to None if there's no status_code, for whatever reason. + response.status_code = getattr(resp, "status", None) # type: ignore[assignment] + + # Make headers case-insensitive. + response.headers = CaseInsensitiveDict(getattr(resp, "headers", {})) + + # Set encoding. + response.encoding = get_encoding_from_headers(response.headers) + response.raw = resp + response.reason = response.raw.reason + + if isinstance(req.url, bytes): + response.url = req.url.decode("utf-8") + else: + response.url = req.url + + # Add new cookies from the server. + extract_cookies_to_jar(response.cookies, req, resp) + + # Give the Response some context. + response.request = req + response.connection = self + + return response + + def build_connection_pool_key_attributes( + self, request: PreparedRequest, verify: _t.VerifyType, cert: _t.CertType = None + ) -> tuple[dict[str, Any], dict[str, Any]]: + """Build the PoolKey attributes used by urllib3 to return a connection. + + This looks at the PreparedRequest, the user-specified verify value, + and the value of the cert parameter to determine what PoolKey values + to use to select a connection from a given urllib3 Connection Pool. + + The SSL related pool key arguments are not consistently set. As of + this writing, use the following to determine what keys may be in that + dictionary: + + * If ``verify`` is ``True``, ``"ssl_context"`` will be set and will be the + default Requests SSL Context + * If ``verify`` is ``False``, ``"ssl_context"`` will not be set but + ``"cert_reqs"`` will be set + * If ``verify`` is a string, (i.e., it is a user-specified trust bundle) + ``"ca_certs"`` will be set if the string is not a directory recognized + by :py:func:`os.path.isdir`, otherwise ``"ca_cert_dir"`` will be + set. + * If ``"cert"`` is specified, ``"cert_file"`` will always be set. If + ``"cert"`` is a tuple with a second item, ``"key_file"`` will also + be present + + To override these settings, one may subclass this class, call this + method and use the above logic to change parameters as desired. For + example, if one wishes to use a custom :py:class:`ssl.SSLContext` one + must both set ``"ssl_context"`` and based on what else they require, + alter the other keys to ensure the desired behaviour. + + :param request: + The PreparedRequest being sent over the connection. + :type request: + :class:`~requests.models.PreparedRequest` + :param verify: + Either a boolean, in which case it controls whether + we verify the server's TLS certificate, or a string, in which case it + must be a path to a CA bundle to use. + :param cert: + (optional) Any user-provided SSL certificate for client + authentication (a.k.a., mTLS). This may be a string (i.e., just + the path to a file which holds both certificate and key) or a + tuple of length 2 with the certificate file path and key file + path. + :returns: + A tuple of two dictionaries. The first is the "host parameters" + portion of the Pool Key including scheme, hostname, and port. The + second is a dictionary of SSLContext related parameters. + """ + return _urllib3_request_context(request, verify, cert, self.poolmanager) + + def get_connection_with_tls_context( + self, + request: PreparedRequest, + verify: _t.VerifyType, + proxies: dict[str, str] | None = None, + cert: _t.CertType = None, + ) -> HTTPConnectionPool: + """Returns a urllib3 connection for the given request and TLS settings. + This should not be called from user code, and is only exposed for use + when subclassing the :class:`HTTPAdapter <requests.adapters.HTTPAdapter>`. + + :param request: + The :class:`PreparedRequest <PreparedRequest>` object to be sent + over the connection. + :param verify: + Either a boolean, in which case it controls whether we verify the + server's TLS certificate, or a string, in which case it must be a + path to a CA bundle to use. + :param proxies: + (optional) The proxies dictionary to apply to the request. + :param cert: + (optional) Any user-provided SSL certificate to be used for client + authentication (a.k.a., mTLS). + :rtype: + urllib3.HTTPConnectionPool + """ + assert _is_prepared(request) + + proxy = select_proxy(request.url, proxies) + try: + host_params, pool_kwargs = self.build_connection_pool_key_attributes( + request, + verify, + cert, + ) + except ValueError as e: + raise InvalidURL(e, request=request) + if proxy: + proxy = prepend_scheme_if_needed(proxy, "http") + proxy_url = parse_url(proxy) + if not proxy_url.host: + raise InvalidProxyURL( + "Please check proxy URL. It is malformed " + "and could be missing the host." + ) + proxy_manager = self.proxy_manager_for(proxy) + conn = proxy_manager.connection_from_host( + **host_params, pool_kwargs=pool_kwargs + ) + else: + # Only scheme should be lower case + conn = self.poolmanager.connection_from_host( + **host_params, pool_kwargs=pool_kwargs + ) + + return conn + + def get_connection( + self, url: str, proxies: dict[str, str] | None = None + ) -> HTTPConnectionPool: + """DEPRECATED: Users should move to `get_connection_with_tls_context` + for all subclasses of HTTPAdapter using Requests>=2.32.2. + + Returns a urllib3 connection for the given URL. This should not be + called from user code, and is only exposed for use when subclassing the + :class:`HTTPAdapter <requests.adapters.HTTPAdapter>`. + + :param url: The URL to connect to. + :param proxies: (optional) A Requests-style dictionary of proxies used on this request. + :rtype: urllib3.HTTPConnectionPool + """ + warnings.warn( + ( + "`get_connection` has been deprecated in favor of " + "`get_connection_with_tls_context`. Custom HTTPAdapter subclasses " + "will need to migrate for Requests>=2.32.2. Please see " + "https://github.com/psf/requests/pull/6710 for more details." + ), + DeprecationWarning, + ) + proxy = select_proxy(url, proxies) + + if proxy: + proxy = prepend_scheme_if_needed(proxy, "http") + proxy_url = parse_url(proxy) + if not proxy_url.host: + raise InvalidProxyURL( + "Please check proxy URL. It is malformed " + "and could be missing the host." + ) + proxy_manager = self.proxy_manager_for(proxy) + conn = proxy_manager.connection_from_url(url) + else: + # Only scheme should be lower case + parsed = urlparse(url) + url = parsed.geturl() + conn = self.poolmanager.connection_from_url(url) + + return conn + + def close(self) -> None: + """Disposes of any internal state. + + Currently, this closes the PoolManager and any active ProxyManager, + which closes any pooled connections. + """ + self.poolmanager.clear() + for proxy in self.proxy_manager.values(): + proxy.clear() + + def request_url( + self, request: PreparedRequest, proxies: dict[str, str] | None + ) -> str: + """Obtain the url to use when making the final request. + + If the message is being sent through a HTTP proxy, the full URL has to + be used. Otherwise, we should only use the path portion of the URL. + + This should not be called from user code, and is only exposed for use + when subclassing the + :class:`HTTPAdapter <requests.adapters.HTTPAdapter>`. + + :param request: The :class:`PreparedRequest <PreparedRequest>` being sent. + :param proxies: A dictionary of schemes or schemes and hosts to proxy URLs. + :rtype: str + """ + assert _is_prepared(request) + + proxy = select_proxy(request.url, proxies) + scheme = urlparse(request.url).scheme + + is_proxied_http_request = proxy and scheme != "https" + using_socks_proxy = False + if proxy: + proxy_scheme = urlparse(proxy).scheme.lower() + using_socks_proxy = proxy_scheme.startswith("socks") + + url = request.path_url + + if is_proxied_http_request and not using_socks_proxy: + url = urldefragauth(request.url) + + return url + + def add_headers(self, request: PreparedRequest, **kwargs: Any) -> None: + """Add any headers needed by the connection. As of v2.0 this does + nothing by default, but is left for overriding by users that subclass + the :class:`HTTPAdapter <requests.adapters.HTTPAdapter>`. + + This should not be called from user code, and is only exposed for use + when subclassing the + :class:`HTTPAdapter <requests.adapters.HTTPAdapter>`. + + :param request: The :class:`PreparedRequest <PreparedRequest>` to add headers to. + :param kwargs: The keyword arguments from the call to send(). + """ + pass + + def proxy_headers(self, proxy: str) -> dict[str, str]: + """Returns a dictionary of the headers to add to any request sent + through a proxy. This works with urllib3 magic to ensure that they are + correctly sent to the proxy, rather than in a tunnelled request if + CONNECT is being used. + + This should not be called from user code, and is only exposed for use + when subclassing the + :class:`HTTPAdapter <requests.adapters.HTTPAdapter>`. + + :param proxy: The url of the proxy being used for this request. + :rtype: dict + """ + headers: dict[str, str] = {} + username, password = get_auth_from_url(proxy) + + if username: + headers["Proxy-Authorization"] = _basic_auth_str(username, password) + + return headers + + def send( + self, + request: PreparedRequest, + stream: bool = False, + timeout: _t.TimeoutType = None, + verify: _t.VerifyType = True, + cert: _t.CertType = None, + proxies: dict[str, str] | None = None, + ) -> Response: + """Sends PreparedRequest object. Returns Response object. + + :param request: The :class:`PreparedRequest <PreparedRequest>` being sent. + :param stream: (optional) Whether to stream the request content. + :param timeout: (optional) How long to wait for the server to send + data before giving up, as a float, or a :ref:`(connect timeout, + read timeout) <timeouts>` tuple. + :type timeout: float or tuple or urllib3 Timeout object + :param verify: (optional) Either a boolean, in which case it controls whether + we verify the server's TLS certificate, or a string, in which case it + must be a path to a CA bundle to use + :param cert: (optional) Any user-provided SSL certificate to be trusted. + :param proxies: (optional) The proxies dictionary to apply to the request. + :rtype: requests.Response + """ + + assert _is_prepared(request) + + try: + conn = self.get_connection_with_tls_context( + request, verify, proxies=proxies, cert=cert + ) + except LocationValueError as e: + raise InvalidURL(e, request=request) + + self.cert_verify(conn, request.url, verify, cert) + url = self.request_url(request, proxies) + self.add_headers( + request, + stream=stream, + timeout=timeout, + verify=verify, + cert=cert, + proxies=proxies, + ) + + chunked = not (request.body is None or "Content-Length" in request.headers) + + if isinstance(timeout, tuple): + try: + connect, read = timeout + resolved_timeout = TimeoutSauce(connect=connect, read=read) + except ValueError: + raise ValueError( + f"Invalid timeout {timeout}. Pass a (connect, read) timeout tuple, " + f"or a single float to set both timeouts to the same value." + ) + elif isinstance(timeout, TimeoutSauce): + resolved_timeout = timeout + else: + resolved_timeout = TimeoutSauce(connect=timeout, read=timeout) + + try: + resp = conn.urlopen( + method=request.method, + url=url, + body=request.body, # type: ignore[arg-type] # urllib3 stubs don't accept Iterable[bytes | str] + headers=request.headers, # type: ignore[arg-type] # urllib3#3072 + redirect=False, + assert_same_host=False, + preload_content=False, + decode_content=False, + retries=self.max_retries, + timeout=resolved_timeout, + chunked=chunked, + ) + + except (ProtocolError, OSError) as err: + raise ConnectionError(err, request=request) + + except MaxRetryError as e: + if isinstance(e.reason, ConnectTimeoutError): + # TODO: Remove this in 3.0.0: see #2811 + if not isinstance(e.reason, NewConnectionError): + raise ConnectTimeout(e, request=request) + + if isinstance(e.reason, ResponseError): + raise RetryError(e, request=request) + + if isinstance(e.reason, _ProxyError): + raise ProxyError(e, request=request) + + if isinstance(e.reason, _SSLError): + # This branch is for urllib3 v1.22 and later. + raise SSLError(e, request=request) + + raise ConnectionError(e, request=request) + + except ClosedPoolError as e: + raise ConnectionError(e, request=request) + + except _ProxyError as e: + raise ProxyError(e) + + except (_SSLError, _HTTPError) as e: + if isinstance(e, _SSLError): + # This branch is for urllib3 versions earlier than v1.22 + raise SSLError(e, request=request) + elif isinstance(e, ReadTimeoutError): + raise ReadTimeout(e, request=request) + elif isinstance(e, _InvalidHeader): + raise InvalidHeader(e, request=request) + else: + raise + + return self.build_response(request, resp) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/api.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/api.py new file mode 100644 index 0000000000000000000000000000000000000000..eeb3b54d7f27e2c843080dfe81dfdb0d460c2b31 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/api.py @@ -0,0 +1,180 @@ +""" +requests.api +~~~~~~~~~~~~ + +This module implements the Requests API. + +:copyright: (c) 2012 by Kenneth Reitz. +:license: Apache2, see LICENSE for more details. +""" + +from __future__ import annotations + +from typing import TYPE_CHECKING + +from . import sessions +from .models import Response + +if TYPE_CHECKING: + from typing_extensions import Unpack + + from . import _types as _t + + +def request( + method: str, url: _t.UriType, **kwargs: Unpack[_t.RequestKwargs] +) -> Response: + """Constructs and sends a :class:`Request <Request>`. + + :param method: method for the new :class:`Request` object: ``GET``, ``OPTIONS``, ``HEAD``, ``POST``, ``PUT``, ``PATCH``, or ``DELETE``. + :param url: URL for the new :class:`Request` object. + :param params: (optional) Dictionary, list of tuples or bytes to send + in the query string for the :class:`Request`. + :param data: (optional) Dictionary, list of tuples, bytes, or file-like + object to send in the body of the :class:`Request`. + :param json: (optional) A JSON serializable Python object to send in the body of the :class:`Request`. + :param headers: (optional) Dictionary of HTTP Headers to send with the :class:`Request`. + :param cookies: (optional) Dict or CookieJar object to send with the :class:`Request`. + :param files: (optional) Dictionary of ``'name': file-like-objects`` (or ``{'name': file-tuple}``) for multipart encoding upload. + ``file-tuple`` can be a 2-tuple ``('filename', fileobj)``, 3-tuple ``('filename', fileobj, 'content_type')`` + or a 4-tuple ``('filename', fileobj, 'content_type', custom_headers)``, where ``'content_type'`` is a string + defining the content type of the given file and ``custom_headers`` a dict-like object containing additional headers + to add for the file. + :param auth: (optional) Auth tuple to enable Basic/Digest/Custom HTTP Auth. + :param timeout: (optional) How many seconds to wait for the server to send data + before giving up, as a float, or a :ref:`(connect timeout, read + timeout) <timeouts>` tuple. + :type timeout: float or tuple + :param allow_redirects: (optional) Boolean. Enable/disable GET/OPTIONS/POST/PUT/PATCH/DELETE/HEAD redirection. Defaults to ``True``. + :type allow_redirects: bool + :param proxies: (optional) Dictionary mapping protocol to the URL of the proxy. + :param verify: (optional) Either a boolean, in which case it controls whether we verify + the server's TLS certificate, or a string, in which case it must be a path + to a CA bundle to use. Defaults to ``True``. + :param stream: (optional) if ``False``, the response content will be immediately downloaded. + :param cert: (optional) if String, path to ssl client cert file (.pem). If Tuple, ('cert', 'key') pair. + :return: :class:`Response <Response>` object + :rtype: requests.Response + + Usage:: + + >>> import requests + >>> req = requests.request('GET', 'https://httpbin.org/get') + >>> req + <Response [200]> + """ + + # By using the 'with' statement we are sure the session is closed, thus we + # avoid leaving sockets open which can trigger a ResourceWarning in some + # cases, and look like a memory leak in others. + with sessions.Session() as session: + return session.request(method=method, url=url, **kwargs) + + +def get( + url: _t.UriType, params: _t.ParamsType = None, **kwargs: Unpack[_t.GetKwargs] +) -> Response: + r"""Sends a GET request. + + :param url: URL for the new :class:`Request` object. + :param params: (optional) Dictionary, list of tuples or bytes to send + in the query string for the :class:`Request`. + :param \*\*kwargs: Optional arguments that ``request`` takes. + :return: :class:`Response <Response>` object + :rtype: requests.Response + """ + + return request("get", url, params=params, **kwargs) + + +def options(url: _t.UriType, **kwargs: Unpack[_t.RequestKwargs]) -> Response: + r"""Sends an OPTIONS request. + + :param url: URL for the new :class:`Request` object. + :param \*\*kwargs: Optional arguments that ``request`` takes. + :return: :class:`Response <Response>` object + :rtype: requests.Response + """ + + return request("options", url, **kwargs) + + +def head(url: _t.UriType, **kwargs: Unpack[_t.RequestKwargs]) -> Response: + r"""Sends a HEAD request. + + :param url: URL for the new :class:`Request` object. + :param \*\*kwargs: Optional arguments that ``request`` takes. If + `allow_redirects` is not provided, it will be set to `False` (as + opposed to the default :meth:`request` behavior). + :return: :class:`Response <Response>` object + :rtype: requests.Response + """ + + kwargs.setdefault("allow_redirects", False) + return request("head", url, **kwargs) + + +def post( + url: _t.UriType, + data: _t.DataType = None, + json: _t.JsonType = None, + **kwargs: Unpack[_t.PostKwargs], +) -> Response: + r"""Sends a POST request. + + :param url: URL for the new :class:`Request` object. + :param data: (optional) Dictionary, list of tuples, bytes, or file-like + object to send in the body of the :class:`Request`. + :param json: (optional) A JSON serializable Python object to send in the body of the :class:`Request`. + :param \*\*kwargs: Optional arguments that ``request`` takes. + :return: :class:`Response <Response>` object + :rtype: requests.Response + """ + + return request("post", url, data=data, json=json, **kwargs) + + +def put( + url: _t.UriType, data: _t.DataType = None, **kwargs: Unpack[_t.DataKwargs] +) -> Response: + r"""Sends a PUT request. + + :param url: URL for the new :class:`Request` object. + :param data: (optional) Dictionary, list of tuples, bytes, or file-like + object to send in the body of the :class:`Request`. + :param json: (optional) A JSON serializable Python object to send in the body of the :class:`Request`. + :param \*\*kwargs: Optional arguments that ``request`` takes. + :return: :class:`Response <Response>` object + :rtype: requests.Response + """ + + return request("put", url, data=data, **kwargs) + + +def patch( + url: _t.UriType, data: _t.DataType = None, **kwargs: Unpack[_t.DataKwargs] +) -> Response: + r"""Sends a PATCH request. + + :param url: URL for the new :class:`Request` object. + :param data: (optional) Dictionary, list of tuples, bytes, or file-like + object to send in the body of the :class:`Request`. + :param json: (optional) A JSON serializable Python object to send in the body of the :class:`Request`. + :param \*\*kwargs: Optional arguments that ``request`` takes. + :return: :class:`Response <Response>` object + :rtype: requests.Response + """ + + return request("patch", url, data=data, **kwargs) + + +def delete(url: _t.UriType, **kwargs: Unpack[_t.RequestKwargs]) -> Response: + r"""Sends a DELETE request. + + :param url: URL for the new :class:`Request` object. + :param \*\*kwargs: Optional arguments that ``request`` takes. + :return: :class:`Response <Response>` object + :rtype: requests.Response + """ + + return request("delete", url, **kwargs) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/auth.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/auth.py new file mode 100644 index 0000000000000000000000000000000000000000..2af481dbf59e31965bde74c2e27d73517a39d7ac --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/auth.py @@ -0,0 +1,354 @@ +""" +requests.auth +~~~~~~~~~~~~~ + +This module contains the authentication handlers for Requests. +""" + +from __future__ import annotations + +import hashlib +import os +import re +import threading +import time +import warnings +from base64 import b64encode +from typing import TYPE_CHECKING, Any, Final, cast, overload + +from ._internal_utils import to_native_string +from .compat import basestring, str, urlparse +from .cookies import extract_cookies_to_jar +from .utils import parse_dict_header + +if TYPE_CHECKING: + from http.cookiejar import CookieJar + from typing import Any + + from .models import PreparedRequest, Response + +CONTENT_TYPE_FORM_URLENCODED: Final = "application/x-www-form-urlencoded" +CONTENT_TYPE_MULTI_PART: Final = "multipart/form-data" + + +def _basic_auth_str(username: bytes | str, password: bytes | str) -> str: + """Returns a Basic Auth string.""" + + # "I want us to put a big-ol' comment on top of it that + # says that this behaviour is dumb but we need to preserve + # it because people are relying on it." + # - Lukasa + # + # These are here solely to maintain backwards compatibility + # for things like ints. This will be removed in 3.0.0. + if not isinstance(username, basestring): # type: ignore[reportUnnecessaryIsInstance] # runtime guard for non-str/bytes + warnings.warn( + "Non-string usernames will no longer be supported in Requests " + f"3.0.0. Please convert the object you've passed in ({username!r}) to " + "a string or bytes object in the near future to avoid " + "problems.", + category=DeprecationWarning, + ) + username = str(username) + + if not isinstance(password, basestring): # type: ignore[reportUnnecessaryIsInstance] # runtime guard for non-str/bytes + warnings.warn( + "Non-string passwords will no longer be supported in Requests " + f"3.0.0. Please convert the object you've passed in ({type(password)!r}) to " + "a string or bytes object in the near future to avoid " + "problems.", + category=DeprecationWarning, + ) + password = str(password) + # -- End Removal -- + + if isinstance(username, str): + username = username.encode("latin1") + + if isinstance(password, str): + password = password.encode("latin1") + + authstr = "Basic " + to_native_string( + b64encode(b":".join((username, password))).strip() + ) + + return authstr + + +class AuthBase: + """Base class that all auth implementations derive from""" + + def __call__(self, r: PreparedRequest) -> PreparedRequest: + raise NotImplementedError("Auth hooks must be callable.") + + +class HTTPBasicAuth(AuthBase): + """Attaches HTTP Basic Authentication to the given Request object.""" + + username: bytes | str + password: bytes | str + + @overload + def __init__(self, username: str, password: str) -> None: ... + @overload + def __init__(self, username: bytes, password: bytes) -> None: ... + + def __init__(self, username: bytes | str, password: bytes | str) -> None: + self.username = username + self.password = password + + def __eq__(self, other: object) -> bool: + return all( + [ + self.username == getattr(other, "username", None), + self.password == getattr(other, "password", None), + ] + ) + + def __ne__(self, other: Any) -> bool: + return not self == other + + def __call__(self, r: PreparedRequest) -> PreparedRequest: + r.headers["Authorization"] = _basic_auth_str(self.username, self.password) + return r + + +class HTTPProxyAuth(HTTPBasicAuth): + """Attaches HTTP Proxy Authentication to a given Request object.""" + + def __call__(self, r: PreparedRequest) -> PreparedRequest: + r.headers["Proxy-Authorization"] = _basic_auth_str(self.username, self.password) + return r + + +class HTTPDigestAuth(AuthBase): + """Attaches HTTP Digest Authentication to the given Request object.""" + + username: bytes | str + password: bytes | str + _thread_local: threading.local + last_nonce: str + nonce_count: int + chal: dict[str, str] + pos: int | None + num_401_calls: int | None + + @overload + def __init__(self, username: str, password: str) -> None: ... + @overload + def __init__(self, username: bytes, password: bytes) -> None: ... + + def __init__(self, username: bytes | str, password: bytes | str) -> None: + self.username = username + self.password = password + # Keep state in per-thread local storage + self._thread_local = threading.local() + + def init_per_thread_state(self) -> None: + # Ensure state is initialized just once per-thread + if not hasattr(self._thread_local, "init"): + self._thread_local.init = True + self._thread_local.last_nonce = "" + self._thread_local.nonce_count = 0 + self._thread_local.chal = {} + self._thread_local.pos = None + self._thread_local.num_401_calls = None + + def build_digest_header(self, method: str, url: str) -> str | None: + """ + :rtype: str + """ + + realm = self._thread_local.chal["realm"] + nonce = self._thread_local.chal["nonce"] + qop = self._thread_local.chal.get("qop") + algorithm = self._thread_local.chal.get("algorithm") + opaque = self._thread_local.chal.get("opaque") + hash_utf8 = None + + if algorithm is None: + _algorithm = "MD5" + else: + _algorithm = algorithm.upper() + # lambdas assume digest modules are imported at the top level + if _algorithm == "MD5" or _algorithm == "MD5-SESS": + + def md5_utf8(x: str | bytes) -> str: + if isinstance(x, str): + x = x.encode("utf-8") + return hashlib.md5(x, usedforsecurity=False).hexdigest() + + hash_utf8 = md5_utf8 + elif _algorithm == "SHA": + + def sha_utf8(x: str | bytes) -> str: + if isinstance(x, str): + x = x.encode("utf-8") + return hashlib.sha1(x, usedforsecurity=False).hexdigest() + + hash_utf8 = sha_utf8 + elif _algorithm == "SHA-256": + + def sha256_utf8(x: str | bytes) -> str: + if isinstance(x, str): + x = x.encode("utf-8") + return hashlib.sha256(x, usedforsecurity=False).hexdigest() + + hash_utf8 = sha256_utf8 + elif _algorithm == "SHA-512": + + def sha512_utf8(x: str | bytes) -> str: + if isinstance(x, str): + x = x.encode("utf-8") + return hashlib.sha512(x, usedforsecurity=False).hexdigest() + + hash_utf8 = sha512_utf8 + + if hash_utf8 is None: + return None + + def KD(s: str, d: str) -> str: + return hash_utf8(f"{s}:{d}") + + # XXX not implemented yet + entdig = None + p_parsed = urlparse(url) + #: path is request-uri defined in RFC 2616 which should not be empty + path = p_parsed.path or "/" + if p_parsed.query: + path += f"?{p_parsed.query}" + + A1 = f"{self.username}:{realm}:{self.password}" + A2 = f"{method}:{path}" + + HA1 = hash_utf8(A1) + HA2 = hash_utf8(A2) + + if nonce == self._thread_local.last_nonce: + self._thread_local.nonce_count += 1 + else: + self._thread_local.nonce_count = 1 + ncvalue = f"{self._thread_local.nonce_count:08x}" + s = str(self._thread_local.nonce_count).encode("utf-8") + s += nonce.encode("utf-8") + s += time.ctime().encode("utf-8") + s += os.urandom(8) + + cnonce = hashlib.sha1(s, usedforsecurity=False).hexdigest()[:16] + if _algorithm == "MD5-SESS": + HA1 = hash_utf8(f"{HA1}:{nonce}:{cnonce}") # type: ignore[reportConstantRedefinition] # RFC 2617 terminology + + if not qop: + respdig = KD(HA1, f"{nonce}:{HA2}") + elif qop == "auth" or "auth" in qop.split(","): + noncebit = f"{nonce}:{ncvalue}:{cnonce}:auth:{HA2}" + respdig = KD(HA1, noncebit) + else: + # XXX handle auth-int. + return None + + self._thread_local.last_nonce = nonce + + # XXX should the partial digests be encoded too? + base = ( + f'username="{self.username}", realm="{realm}", nonce="{nonce}", ' + f'uri="{path}", response="{respdig}"' + ) + if opaque: + base += f', opaque="{opaque}"' + if algorithm: + base += f', algorithm="{algorithm}"' + if entdig: + base += f', digest="{entdig}"' + if qop: + base += f', qop="auth", nc={ncvalue}, cnonce="{cnonce}"' + + return f"Digest {base}" + + def handle_redirect(self, r: Response, **kwargs: Any) -> None: + """Reset num_401_calls counter on redirects.""" + if r.is_redirect: + self._thread_local.num_401_calls = 1 + + def handle_401(self, r: Response, **kwargs: Any) -> Response: + """ + Takes the given response and tries digest-auth, if needed. + + :rtype: requests.Response + """ + + # If response is not 4xx, do not auth + # See https://github.com/psf/requests/issues/3772 + if not 400 <= r.status_code < 500: + self._thread_local.num_401_calls = 1 + return r + + if self._thread_local.pos is not None: + # Rewind the file position indicator of the body to where + # it was to resend the request. + if (seek := getattr(r.request.body, "seek", None)) is not None: + seek(self._thread_local.pos) + s_auth = r.headers.get("www-authenticate", "") + + if "digest" in s_auth.lower() and self._thread_local.num_401_calls < 2: + self._thread_local.num_401_calls += 1 + pat = re.compile(r"digest ", flags=re.IGNORECASE) + self._thread_local.chal = parse_dict_header(pat.sub("", s_auth, count=1)) + + # Consume content and release the original connection + # to allow our new request to reuse the same one. + r.content + r.close() + prep = r.request.copy() + cookie_jar = cast("CookieJar", prep._cookies) # type: ignore[reportPrivateUsage] + extract_cookies_to_jar(cookie_jar, r.request, r.raw) + prep.prepare_cookies(cookie_jar) + + _digest_auth = self.build_digest_header( + cast(str, prep.method), cast(str, prep.url) + ) + if _digest_auth: + prep.headers["Authorization"] = _digest_auth + _r = r.connection.send(prep, **kwargs) + _r.history.append(r) + _r.request = prep + + return _r + + self._thread_local.num_401_calls = 1 + return r + + def __call__(self, r: PreparedRequest) -> PreparedRequest: + # Initialize per-thread state, if needed + self.init_per_thread_state() + # If we have a saved nonce, skip the 401 + if self._thread_local.last_nonce: + _digest_auth = self.build_digest_header( + cast(str, r.method), cast(str, r.url) + ) + if _digest_auth: + r.headers["Authorization"] = _digest_auth + if (tell := getattr(r.body, "tell", None)) is not None: + self._thread_local.pos = tell() + else: + # In the case of HTTPDigestAuth being reused and the body of + # the previous request was a file-like object, pos has the + # file position of the previous body. Ensure it's set to + # None. + self._thread_local.pos = None + r.register_hook("response", self.handle_401) + r.register_hook("response", self.handle_redirect) + self._thread_local.num_401_calls = 1 + + return r + + def __eq__(self, other: object) -> bool: + return all( + [ + self.username == getattr(other, "username", None), + self.password == getattr(other, "password", None), + ] + ) + + def __ne__(self, other: Any) -> bool: + return not self == other diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/certs.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/certs.py new file mode 100644 index 0000000000000000000000000000000000000000..4f85ac070bc0230af8155bcadfaa96165268cede --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/certs.py @@ -0,0 +1,18 @@ +#!/usr/bin/env python + +""" +requests.certs +~~~~~~~~~~~~~~ + +This module returns the preferred default CA certificate bundle. There is +only one — the one from the certifi package. + +If you are packaging Requests, e.g., for a Linux distribution or a managed +environment, you can change the definition of where() to return a separately +packaged CA bundle. +""" + +from certifi import where + +if __name__ == "__main__": + print(where()) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/compat.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/compat.py new file mode 100644 index 0000000000000000000000000000000000000000..deab3c091fed207315c5af60fb415d7407a08b48 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/compat.py @@ -0,0 +1,113 @@ +""" +requests.compat +~~~~~~~~~~~~~~~ + +This module previously handled import compatibility issues +between Python 2 and Python 3. It remains for backwards +compatibility until the next major version. +""" + +# pyright: reportUnusedImport=false + +from __future__ import annotations + +import importlib +import sys +from types import ModuleType + +# ------- +# urllib3 +# ------- +from urllib3 import ( + __version__ as urllib3_version, # type: ignore[reportPrivateImportUsage] +) + +# Detect which major version of urllib3 is being used. +try: + is_urllib3_1 = int(urllib3_version.split(".")[0]) == 1 +except (TypeError, AttributeError): + # If we can't discern a version, prefer old functionality. + is_urllib3_1 = True + +# ------------------- +# Character Detection +# ------------------- + + +def _resolve_char_detection() -> ModuleType | None: + """Find supported character detection libraries.""" + chardet = None + for lib in ("chardet", "charset_normalizer"): + if chardet is None: + try: + chardet = importlib.import_module(lib) + except ImportError: + pass + return chardet + + +chardet = _resolve_char_detection() + +# ------- +# Pythons +# ------- + +# Syntax sugar. +_ver = sys.version_info + +#: Python 2.x? +is_py2 = _ver[0] == 2 + +#: Python 3.x? +is_py3 = _ver[0] == 3 + +# json/simplejson module import resolution +has_simplejson = False +try: + import simplejson as json # type: ignore[import-not-found] + + has_simplejson = True +except ImportError: + import json + +if has_simplejson: + from simplejson import JSONDecodeError # type: ignore[import-not-found] +else: + from json import JSONDecodeError + +# Keep OrderedDict for backwards compatibility. +from collections import OrderedDict +from collections.abc import Callable, Mapping, MutableMapping +from http import cookiejar as cookielib +from http.cookies import Morsel +from io import StringIO + +# -------------- +# Legacy Imports +# -------------- +from urllib.parse import ( + quote, + quote_plus, + unquote, + unquote_plus, + urldefrag, + urlencode, + urljoin, + urlparse, + urlsplit, + urlunparse, +) +from urllib.request import ( + getproxies, + getproxies_environment, + parse_http_list, + proxy_bypass, + proxy_bypass_environment, # type: ignore[attr-defined] # https://github.com/python/cpython/issues/145331 +) + +builtin_str = str +str = str +bytes = bytes +basestring = (str, bytes) +numeric_types = (int, float) +integer_types = (int,) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/cookies.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/cookies.py new file mode 100644 index 0000000000000000000000000000000000000000..2e3fc215095fad13817562bbaee871cba57eec08 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/cookies.py @@ -0,0 +1,625 @@ +""" +requests.cookies +~~~~~~~~~~~~~~~~ + +Compatibility code to be able to use `http.cookiejar.CookieJar` with requests. + +requests.utils imports from here, so be careful with imports. +""" + +from __future__ import annotations + +import calendar +import copy +import time +from collections.abc import Iterator, MutableMapping +from http.cookiejar import Cookie, CookieJar, CookiePolicy +from typing import TYPE_CHECKING, Any, TypeVar, overload + +from ._internal_utils import to_native_string +from ._types import is_prepared as _is_prepared +from .compat import Morsel, cookielib, urlparse, urlunparse + +if TYPE_CHECKING: + from _typeshed import SupportsKeysAndGetItem + + from .models import PreparedRequest + +import threading + + +class MockRequest: + """Wraps a `requests.PreparedRequest` to mimic a `urllib2.Request`. + + The code in `http.cookiejar.CookieJar` expects this interface in order to correctly + manage cookie policies, i.e., determine whether a cookie can be set, given the + domains of the request and the cookie. + + The original request object is read-only. The client is responsible for collecting + the new headers via `get_new_headers()` and interpreting them appropriately. You + probably want `get_cookie_header`, defined below. + """ + + type: str + + def __init__(self, request: PreparedRequest) -> None: + assert _is_prepared(request) + self._r = request + self._new_headers: dict[str, str] = {} + self.type = urlparse(self._r.url).scheme + + def get_type(self) -> str: + return self.type + + def get_host(self) -> str: + return urlparse(self._r.url).netloc + + def get_origin_req_host(self) -> str: + return self.get_host() + + def get_full_url(self) -> str: + # Only return the response's URL if the user hadn't set the Host + # header + if not self._r.headers.get("Host"): + return self._r.url + # If they did set it, retrieve it and reconstruct the expected domain + host = to_native_string(self._r.headers["Host"], encoding="utf-8") + parsed = urlparse(self._r.url) + # Reconstruct the URL as we expect it + return urlunparse( + [ + parsed.scheme, + host, + parsed.path, + parsed.params, + parsed.query, + parsed.fragment, + ] + ) + + def is_unverifiable(self) -> bool: + return True + + def has_header(self, name: str) -> bool: + return name in self._r.headers or name in self._new_headers + + def get_header(self, name: str, default: str | None = None) -> str | None: + return self._r.headers.get(name, self._new_headers.get(name, default)) # type: ignore[return-value] + + def add_header(self, key: str, val: str) -> None: + """cookiejar has no legitimate use for this method; add it back if you find one.""" + raise NotImplementedError( + "Cookie headers should be added with add_unredirected_header()" + ) + + def add_unredirected_header(self, name: str, value: str) -> None: + self._new_headers[name] = value + + def get_new_headers(self) -> dict[str, str]: + return self._new_headers + + @property + def unverifiable(self) -> bool: + return self.is_unverifiable() + + @property + def origin_req_host(self) -> str: + return self.get_origin_req_host() + + @property + def host(self) -> str: + return self.get_host() + + +class MockResponse: + """Wraps a `httplib.HTTPMessage` to mimic a `urllib.addinfourl`. + + ...what? Basically, expose the parsed HTTP headers from the server response + the way `http.cookiejar` expects to see them. + """ + + def __init__(self, headers: Any) -> None: + """Make a MockResponse for `cookiejar` to read. + + :param headers: a httplib.HTTPMessage or analogous carrying the headers + """ + self._headers = headers + + def info(self) -> Any: + return self._headers + + def getheaders(self, name: str) -> Any: + self._headers.getheaders(name) + + +def extract_cookies_to_jar( + jar: CookieJar, request: PreparedRequest, response: Any +) -> None: + """Extract the cookies from the response into a CookieJar. + + :param jar: http.cookiejar.CookieJar (not necessarily a RequestsCookieJar) + :param request: our own requests.Request object + :param response: urllib3.HTTPResponse object + """ + if not (hasattr(response, "_original_response") and response._original_response): + return + # the _original_response field is the wrapped httplib.HTTPResponse object, + req = MockRequest(request) + # pull out the HTTPMessage with the headers and put it in the mock: + res = MockResponse(response._original_response.msg) + jar.extract_cookies(res, req) # type: ignore[arg-type] + + +def get_cookie_header(jar: CookieJar, request: PreparedRequest) -> str | None: + """ + Produce an appropriate Cookie header string to be sent with `request`, or None. + + :rtype: str + """ + r = MockRequest(request) + jar.add_cookie_header(r) # type: ignore[arg-type] + return r.get_new_headers().get("Cookie") + + +def remove_cookie_by_name( + cookiejar: CookieJar, name: str, domain: str | None = None, path: str | None = None +) -> None: + """Unsets a cookie by name, by default over all domains and paths. + + Wraps CookieJar.clear(), is O(n). + """ + clearables: list[tuple[str, str, str]] = [] + for cookie in cookiejar: + if cookie.name != name: + continue + if domain is not None and domain != cookie.domain: + continue + if path is not None and path != cookie.path: + continue + clearables.append((cookie.domain, cookie.path, cookie.name)) + + for domain, path, name in clearables: + cookiejar.clear(domain, path, name) + + +class CookieConflictError(RuntimeError): + """There are two cookies that meet the criteria specified in the cookie jar. + Use .get and .set and include domain and path args in order to be more specific. + """ + + +class RequestsCookieJar(CookieJar, MutableMapping[str, str | None]): # type: ignore[misc] + """Compatibility class; is a http.cookiejar.CookieJar, but exposes a dict + interface. + + This is the CookieJar we create by default for requests and sessions that + don't specify one, since some clients may expect response.cookies and + session.cookies to support dict operations. + + Requests does not use the dict interface internally; it's just for + compatibility with external client code. All requests code should work + out of the box with externally provided instances of ``CookieJar``, e.g. + ``LWPCookieJar`` and ``FileCookieJar``. + + Unlike a regular CookieJar, this class is pickleable. + + .. warning:: dictionary operations that are normally O(1) may be O(n). + """ + + _policy: CookiePolicy + + def get( # type: ignore[override] + self, + name: str, + default: str | None = None, + domain: str | None = None, + path: str | None = None, + ) -> str | None: + """Dict-like get() that also supports optional domain and path args in + order to resolve naming collisions from using one cookie jar over + multiple domains. + + .. warning:: operation is O(n), not O(1). + """ + try: + return self._find_no_duplicates(name, domain, path) + except KeyError: + return default + + def set( + self, name: str, value: str | Morsel[dict[str, str]] | None, **kwargs: Any + ) -> Cookie | None: + """Dict-like set() that also supports optional domain and path args in + order to resolve naming collisions from using one cookie jar over + multiple domains. + """ + # support client code that unsets cookies by assignment of a None value: + if value is None: + remove_cookie_by_name( + self, name, domain=kwargs.get("domain"), path=kwargs.get("path") + ) + return + + if isinstance(value, Morsel): + c = morsel_to_cookie(value) + else: + c = create_cookie(name, value, **kwargs) + self.set_cookie(c) + return c + + def iterkeys(self) -> Iterator[str]: + """Dict-like iterkeys() that returns an iterator of names of cookies + from the jar. + + .. seealso:: itervalues() and iteritems(). + """ + for cookie in iter(self): + yield cookie.name + + def keys(self) -> list[str]: # type: ignore[override] + """Dict-like keys() that returns a list of names of cookies from the + jar. + + .. seealso:: values() and items(). + """ + return list(self.iterkeys()) + + def itervalues(self) -> Iterator[str | None]: + """Dict-like itervalues() that returns an iterator of values of cookies + from the jar. + + .. seealso:: iterkeys() and iteritems(). + """ + for cookie in iter(self): + yield cookie.value + + def values(self) -> list[str | None]: # type: ignore[override] + """Dict-like values() that returns a list of values of cookies from the + jar. + + .. seealso:: keys() and items(). + """ + return list(self.itervalues()) + + def iteritems(self) -> Iterator[tuple[str, str | None]]: + """Dict-like iteritems() that returns an iterator of name-value tuples + from the jar. + + .. seealso:: iterkeys() and itervalues(). + """ + for cookie in iter(self): + yield cookie.name, cookie.value + + def items(self) -> list[tuple[str, str | None]]: # type: ignore[override] + """Dict-like items() that returns a list of name-value tuples from the + jar. Allows client-code to call ``dict(RequestsCookieJar)`` and get a + vanilla python dict of key value pairs. + + .. seealso:: keys() and values(). + """ + return list(self.iteritems()) + + def list_domains(self) -> list[str]: + """Utility method to list all the domains in the jar.""" + domains: list[str] = [] + for cookie in iter(self): + if cookie.domain not in domains: + domains.append(cookie.domain) + return domains + + def list_paths(self) -> list[str]: + """Utility method to list all the paths in the jar.""" + paths: list[str] = [] + for cookie in iter(self): + if cookie.path not in paths: + paths.append(cookie.path) + return paths + + def multiple_domains(self) -> bool: + """Returns True if there are multiple domains in the jar. + Returns False otherwise. + + :rtype: bool + """ + domains: list[str] = [] + for cookie in iter(self): + if cookie.domain is not None and cookie.domain in domains: # type: ignore[reportUnnecessaryComparison] # defensive check + return True + domains.append(cookie.domain) + return False # there is only one domain in jar + + def get_dict( + self, domain: str | None = None, path: str | None = None + ) -> dict[str, str | None]: + """Takes as an argument an optional domain and path and returns a plain + old Python dict of name-value pairs of cookies that meet the + requirements. + + :rtype: dict + """ + dictionary: dict[str, str | None] = {} + for cookie in iter(self): + if (domain is None or cookie.domain == domain) and ( + path is None or cookie.path == path + ): + dictionary[cookie.name] = cookie.value + return dictionary + + def __iter__(self) -> Iterator[Cookie]: # type: ignore[override] + """RequestCookieJar's __iter__ comes from CookieJar not MutableMapping.""" + return super().__iter__() + + def __contains__(self, name: object) -> bool: + try: + return super().__contains__(name) + except CookieConflictError: + return True + + def __getitem__(self, name: str) -> str | None: + """Dict-like __getitem__() for compatibility with client code. Throws + exception if there are more than one cookie with name. In that case, + use the more explicit get() method instead. + + .. warning:: operation is O(n), not O(1). + """ + return self._find_no_duplicates(name) + + def __setitem__( + self, name: str, value: str | Morsel[dict[str, str]] | None + ) -> None: + """Dict-like __setitem__ for compatibility with client code. Throws + exception if there is already a cookie of that name in the jar. In that + case, use the more explicit set() method instead. + """ + self.set(name, value) + + def __delitem__(self, name: str) -> None: + """Deletes a cookie given a name. Wraps ``http.cookiejar.CookieJar``'s + ``remove_cookie_by_name()``. + """ + remove_cookie_by_name(self, name) + + def set_cookie(self, cookie: Cookie, *args: Any, **kwargs: Any) -> None: + if ( + (value := cookie.value) is not None + and value.startswith('"') + and value.endswith('"') + ): + cookie.value = value.replace('\\"', "") + return super().set_cookie(cookie, *args, **kwargs) + + def update( # type: ignore[override] + self, other: CookieJar | SupportsKeysAndGetItem[str, str] + ) -> None: + """Updates this jar with cookies from another CookieJar or dict-like""" + if isinstance(other, cookielib.CookieJar): + for cookie in other: + self.set_cookie(copy.copy(cookie)) + else: + super().update(other) + + def _find( + self, name: str, domain: str | None = None, path: str | None = None + ) -> str | None: + """Requests uses this method internally to get cookie values. + + If there are conflicting cookies, _find arbitrarily chooses one. + See _find_no_duplicates if you want an exception thrown if there are + conflicting cookies. + + :param name: a string containing name of cookie + :param domain: (optional) string containing domain of cookie + :param path: (optional) string containing path of cookie + :return: cookie.value + """ + for cookie in iter(self): + if cookie.name == name: + if domain is None or cookie.domain == domain: + if path is None or cookie.path == path: + return cookie.value + + raise KeyError(f"name={name!r}, domain={domain!r}, path={path!r}") + + def _find_no_duplicates( + self, name: str, domain: str | None = None, path: str | None = None + ) -> str: + """Both ``__get_item__`` and ``get`` call this function: it's never + used elsewhere in Requests. + + :param name: a string containing name of cookie + :param domain: (optional) string containing domain of cookie + :param path: (optional) string containing path of cookie + :raises KeyError: if cookie is not found + :raises CookieConflictError: if there are multiple cookies + that match name and optionally domain and path + :return: cookie.value + """ + toReturn = None + for cookie in iter(self): + if cookie.name == name: + if domain is None or cookie.domain == domain: + if path is None or cookie.path == path: + if toReturn is not None: + # if there are multiple cookies that meet passed in criteria + raise CookieConflictError( + f"There are multiple cookies with name, {name!r}" + ) + # we will eventually return this as long as no cookie conflict + toReturn = cookie.value + + if toReturn is not None: + return toReturn + raise KeyError(f"name={name!r}, domain={domain!r}, path={path!r}") + + def __getstate__(self) -> dict[str, Any]: + """Unlike a normal CookieJar, this class is pickleable.""" + state = self.__dict__.copy() + # remove the unpickleable RLock object + state.pop("_cookies_lock") + return state + + def __setstate__(self, state: dict[str, Any]) -> None: + """Unlike a normal CookieJar, this class is pickleable.""" + self.__dict__.update(state) + if "_cookies_lock" not in self.__dict__: + self._cookies_lock = threading.RLock() + + def copy(self) -> RequestsCookieJar: + """Return a copy of this RequestsCookieJar.""" + new_cj = RequestsCookieJar() + new_cj.set_policy(self.get_policy()) + new_cj.update(self) + return new_cj + + def get_policy(self) -> CookiePolicy: + """Return the CookiePolicy instance used.""" + return self._policy + + +def _copy_cookie_jar(jar: CookieJar | None) -> CookieJar | None: # type: ignore[reportUnusedFunction] # cross-module usage in models.py + if jar is None: + return None + + if copy_method := getattr(jar, "copy", None): + # We're dealing with an instance of RequestsCookieJar + return copy_method() + # We're dealing with a generic CookieJar instance + new_jar = copy.copy(jar) + new_jar.clear() + for cookie in jar: + new_jar.set_cookie(copy.copy(cookie)) + return new_jar + + +def create_cookie(name: str, value: str, **kwargs: Any) -> Cookie: + """Make a cookie from underspecified parameters. + + By default, the pair of `name` and `value` will be set for the domain '' + and sent on every request (this is sometimes called a "supercookie"). + """ + result: dict[str, Any] = { + "version": 0, + "name": name, + "value": value, + "port": None, + "domain": "", + "path": "/", + "secure": False, + "expires": None, + "discard": True, + "comment": None, + "comment_url": None, + "rest": {"HttpOnly": None}, + "rfc2109": False, + } + + badargs = set(kwargs) - set(result) + if badargs: + raise TypeError( + f"create_cookie() got unexpected keyword arguments: {list(badargs)}" + ) + + result.update(kwargs) + result["port_specified"] = bool(result["port"]) + result["domain_specified"] = bool(result["domain"]) + result["domain_initial_dot"] = result["domain"].startswith(".") + result["path_specified"] = bool(result["path"]) + + return cookielib.Cookie(**result) + + +def morsel_to_cookie(morsel: Morsel[Any]) -> Cookie: + """Convert a Morsel object into a Cookie containing the one k/v pair.""" + + expires: int | None = None + if morsel["max-age"]: + try: + expires = int(time.time() + int(morsel["max-age"])) + except ValueError: + raise TypeError(f"max-age: {morsel['max-age']} must be integer") + elif morsel["expires"]: + time_template = "%a, %d-%b-%Y %H:%M:%S GMT" + expires = calendar.timegm(time.strptime(morsel["expires"], time_template)) + return create_cookie( + comment=morsel["comment"], + comment_url=bool(morsel["comment"]), + discard=False, + domain=morsel["domain"], + expires=expires, + name=morsel.key, + path=morsel["path"], + port=None, + rest={"HttpOnly": morsel["httponly"]}, + rfc2109=False, + secure=bool(morsel["secure"]), + value=morsel.value, + version=morsel["version"] or 0, + ) + + +_CookieJarT = TypeVar("_CookieJarT", bound=CookieJar) + + +@overload +def cookiejar_from_dict( + cookie_dict: dict[str, str] | None, + cookiejar: None = None, + overwrite: bool = True, +) -> RequestsCookieJar: ... + + +@overload +def cookiejar_from_dict( + cookie_dict: dict[str, str] | None, + cookiejar: _CookieJarT, + overwrite: bool = True, +) -> _CookieJarT: ... + + +def cookiejar_from_dict( + cookie_dict: dict[str, str] | None, + cookiejar: CookieJar | None = None, + overwrite: bool = True, +) -> CookieJar: + """Returns a CookieJar from a key/value dictionary. + + :param cookie_dict: Dict of key/values to insert into CookieJar. + :param cookiejar: (optional) A cookiejar to add the cookies to. + :param overwrite: (optional) If False, will not replace cookies + already in the jar with new ones. + :rtype: CookieJar + """ + if cookiejar is None: + cookiejar = RequestsCookieJar() + + if cookie_dict is not None: + names_from_jar = [cookie.name for cookie in cookiejar] + for name in cookie_dict: + if overwrite or (name not in names_from_jar): + cookiejar.set_cookie(create_cookie(name, cookie_dict[name])) + + return cookiejar + + +def merge_cookies( + cookiejar: CookieJar, cookies: dict[str, str] | CookieJar | None +) -> CookieJar: + """Add cookies to cookiejar and returns a merged CookieJar. + + :param cookiejar: CookieJar object to add the cookies to. + :param cookies: Dictionary or CookieJar object to be added. + :rtype: CookieJar + """ + if not isinstance(cookiejar, cookielib.CookieJar): # type: ignore[reportUnnecessaryIsInstance] # runtime guard + raise ValueError("You can only merge into CookieJar") + + if isinstance(cookies, dict): + cookiejar = cookiejar_from_dict(cookies, cookiejar=cookiejar, overwrite=False) + elif isinstance(cookies, cookielib.CookieJar): + if update_method := getattr(cookiejar, "update", None): + update_method(cookies) + else: + for cookie_in_jar in cookies: + cookiejar.set_cookie(cookie_in_jar) + + return cookiejar diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/exceptions.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/exceptions.py new file mode 100644 index 0000000000000000000000000000000000000000..cb5e9510e3b1cf4804ac6091fd7fdb55e9f2745b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/exceptions.py @@ -0,0 +1,162 @@ +""" +requests.exceptions +~~~~~~~~~~~~~~~~~~~ + +This module contains the set of Requests' exceptions. +""" + +from __future__ import annotations + +from typing import TYPE_CHECKING, Any + +from urllib3.exceptions import HTTPError as BaseHTTPError + +from .compat import JSONDecodeError as CompatJSONDecodeError + +if TYPE_CHECKING: + from .models import PreparedRequest, Request, Response + + +class RequestException(IOError): + """There was an ambiguous exception that occurred while handling your + request. + """ + + response: Response | None + request: Request | PreparedRequest | None + + def __init__(self, *args: Any, **kwargs: Any) -> None: + """Initialize RequestException with `request` and `response` objects.""" + response: Response | None = kwargs.pop("response", None) + self.response = response + self.request = kwargs.pop("request", None) + if response is not None and not self.request and hasattr(response, "request"): + self.request = response.request + super().__init__(*args, **kwargs) + + +class InvalidJSONError(RequestException): + """A JSON error occurred.""" + + +class JSONDecodeError(InvalidJSONError, CompatJSONDecodeError): + """Couldn't decode the text into json""" + + def __init__(self, *args: Any, **kwargs: Any) -> None: + """ + Construct the JSONDecodeError instance first with all + args. Then use it's args to construct the IOError so that + the json specific args aren't used as IOError specific args + and the error message from JSONDecodeError is preserved. + """ + CompatJSONDecodeError.__init__(self, *args) + InvalidJSONError.__init__(self, *self.args, **kwargs) + + def __reduce__(self) -> tuple[Any, ...] | str: + """ + The __reduce__ method called when pickling the object must + be the one from the JSONDecodeError (be it json/simplejson) + as it expects all the arguments for instantiation, not just + one like the IOError, and the MRO would by default call the + __reduce__ method from the IOError due to the inheritance order. + """ + return CompatJSONDecodeError.__reduce__(self) + + +class HTTPError(RequestException): + """An HTTP error occurred.""" + + +class ConnectionError(RequestException): + """A Connection error occurred.""" + + +class ProxyError(ConnectionError): + """A proxy error occurred.""" + + +class SSLError(ConnectionError): + """An SSL error occurred.""" + + +class Timeout(RequestException): + """The request timed out. + + Catching this error will catch both + :exc:`~requests.exceptions.ConnectTimeout` and + :exc:`~requests.exceptions.ReadTimeout` errors. + """ + + +class ConnectTimeout(ConnectionError, Timeout): + """The request timed out while trying to connect to the remote server. + + Requests that produced this error are safe to retry. + """ + + +class ReadTimeout(Timeout): + """The server did not send any data in the allotted amount of time.""" + + +class URLRequired(RequestException): + """A valid URL is required to make a request.""" + + +class TooManyRedirects(RequestException): + """Too many redirects.""" + + +class MissingSchema(RequestException, ValueError): + """The URL scheme (e.g. http or https) is missing.""" + + +class InvalidSchema(RequestException, ValueError): + """The URL scheme provided is either invalid or unsupported.""" + + +class InvalidURL(RequestException, ValueError): + """The URL provided was somehow invalid.""" + + +class InvalidHeader(RequestException, ValueError): + """The header value provided was somehow invalid.""" + + +class InvalidProxyURL(InvalidURL): + """The proxy URL provided is invalid.""" + + +class ChunkedEncodingError(RequestException): + """The server declared chunked encoding but sent an invalid chunk.""" + + +class ContentDecodingError(RequestException, BaseHTTPError): + """Failed to decode response content.""" + + +class StreamConsumedError(RequestException, TypeError): + """The content for this response was already consumed.""" + + +class RetryError(RequestException): + """Custom retries logic failed""" + + +class UnrewindableBodyError(RequestException): + """Requests encountered an error when trying to rewind a body.""" + + +# Warnings + + +class RequestsWarning(Warning): + """Base warning for Requests.""" + + +class FileModeWarning(RequestsWarning, DeprecationWarning): + """A file was opened in text mode, but Requests determined its binary length.""" + + +class RequestsDependencyWarning(RequestsWarning): + """An imported dependency doesn't match the expected version range.""" diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/help.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/help.py new file mode 100644 index 0000000000000000000000000000000000000000..9269cc71263e3f5938a89a9d6c2fed5a4274cc14 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/help.py @@ -0,0 +1,134 @@ +"""Module containing bug report helper(s).""" + +# pyright: reportUnknownMemberType=false + +import json +import platform +import ssl +import sys +from typing import Any + +import idna +import urllib3 + +from . import __version__ as requests_version + +try: + import charset_normalizer +except ImportError: + charset_normalizer = None + +try: + import chardet # type: ignore[import-not-found] +except ImportError: + chardet = None + +try: + from urllib3.contrib import pyopenssl +except ImportError: + pyopenssl = None + OpenSSL = None + cryptography = None +else: + import cryptography # type: ignore[import-not-found] + import OpenSSL # type: ignore[import-not-found] + + +def _implementation(): + """Return a dict with the Python implementation and version. + + Provide both the name and the version of the Python implementation + currently running. For example, on CPython 3.10.3 it will return + {'name': 'CPython', 'version': '3.10.3'}. + + This function works best on CPython and PyPy: in particular, it probably + doesn't work for Jython or IronPython. Future investigation should be done + to work out the correct shape of the code for those platforms. + """ + implementation = platform.python_implementation() + + if implementation == "CPython": + implementation_version = platform.python_version() + elif implementation == "PyPy": + pypy = sys.pypy_version_info # type: ignore[attr-defined] + implementation_version = f"{pypy.major}.{pypy.minor}.{pypy.micro}" + if sys.pypy_version_info.releaselevel != "final": # type: ignore[attr-defined] + implementation_version = "".join( + [implementation_version, sys.pypy_version_info.releaselevel] # type: ignore[attr-defined] + ) + elif implementation == "Jython": + implementation_version = platform.python_version() # Complete Guess + elif implementation == "IronPython": + implementation_version = platform.python_version() # Complete Guess + else: + implementation_version = "Unknown" + + return {"name": implementation, "version": implementation_version} + + +def info() -> dict[str, Any]: + """Generate information for a bug report.""" + try: + platform_info = { + "system": platform.system(), + "release": platform.release(), + } + except OSError: + platform_info = { + "system": "Unknown", + "release": "Unknown", + } + + implementation_info = _implementation() + urllib3_info = {"version": urllib3.__version__} # type: ignore[reportPrivateImportUsage] + charset_normalizer_info = {"version": None} + chardet_info: dict[str, str | None] = {"version": None} + if charset_normalizer: + charset_normalizer_info = {"version": charset_normalizer.__version__} + if chardet: + chardet_info = {"version": chardet.__version__} + + pyopenssl_info: dict[str, str | None] = { + "version": None, + "openssl_version": "", + } + if OpenSSL: + pyopenssl_info = { + "version": OpenSSL.__version__, + "openssl_version": f"{OpenSSL.SSL.OPENSSL_VERSION_NUMBER:x}", + } + cryptography_info = { + "version": getattr(cryptography, "__version__", ""), + } + idna_info = { + "version": getattr(idna, "__version__", ""), + } + + system_ssl = ssl.OPENSSL_VERSION_NUMBER + system_ssl_info = {"version": f"{system_ssl:x}" if system_ssl is not None else ""} # type: ignore[reportUnnecessaryComparison] + + return { + "platform": platform_info, + "implementation": implementation_info, + "system_ssl": system_ssl_info, + "using_pyopenssl": pyopenssl is not None, + "using_charset_normalizer": chardet is None, + "pyOpenSSL": pyopenssl_info, + "urllib3": urllib3_info, + "chardet": chardet_info, + "charset_normalizer": charset_normalizer_info, + "cryptography": cryptography_info, + "idna": idna_info, + "requests": { + "version": requests_version, + }, + } + + +def main(): + """Pretty-print the bug information as JSON.""" + print(json.dumps(info(), sort_keys=True, indent=2)) + + +if __name__ == "__main__": + main() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/hooks.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/hooks.py new file mode 100644 index 0000000000000000000000000000000000000000..11ff9e9f27e76f5ef6b9b609e88c2f418d655e16 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/hooks.py @@ -0,0 +1,48 @@ +""" +requests.hooks +~~~~~~~~~~~~~~ + +This module provides the capabilities for the Requests hooks system. + +Available hooks: + +``response``: + The response generated from a Request. +""" + +from __future__ import annotations + +from collections.abc import Callable, Iterable +from typing import TYPE_CHECKING, Any + +if TYPE_CHECKING: + from . import _types as _t + from .models import Response + +HOOKS: list[str] = ["response"] + + +def default_hooks() -> dict[str, list[_t.HookType]]: + return {event: [] for event in HOOKS} + + +# TODO: response is the only one + + +def dispatch_hook( + key: str, + hooks: _t.HooksInputType | None, + hook_data: Response, + **kwargs: Any, +) -> Response: + """Dispatches a hook dictionary on a given piece of data.""" + hooks_dict = hooks or {} + hook_list: Iterable[_t.HookType] | _t.HookType | None = hooks_dict.get(key) + if hook_list: + if isinstance(hook_list, Callable): + hook_list = [hook_list] + for hook in hook_list: + _hook_data = hook(hook_data, **kwargs) + if _hook_data is not None: + hook_data = _hook_data + return hook_data diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/models.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/models.py new file mode 100644 index 0000000000000000000000000000000000000000..4142f2a4bbf39820b46b414a15af805a34b1a013 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/models.py @@ -0,0 +1,1180 @@ +""" +requests.models +~~~~~~~~~~~~~~~ + +This module contains the primary objects that power Requests. +""" + +from __future__ import annotations + +import datetime + +# Import encoding now, to avoid implicit import later. +# Implicit import within threads may cause LookupError when standard library is in a ZIP, +# such as in Embedded Python. See https://github.com/psf/requests/issues/3578. +import encodings.idna # noqa: F401 # type: ignore[reportUnusedImport] +from collections.abc import Callable, Generator, Iterable, Iterator, Mapping +from io import UnsupportedOperation +from typing import ( + TYPE_CHECKING, + Any, + Final, + Literal, + cast, + overload, +) + +from urllib3.exceptions import ( + DecodeError, + LocationParseError, + ProtocolError, + ReadTimeoutError, + SSLError, +) +from urllib3.fields import RequestField +from urllib3.filepost import encode_multipart_formdata +from urllib3.util import parse_url + +from ._internal_utils import to_native_string, unicode_is_ascii +from ._types import SupportsRead as _SupportsRead +from .auth import HTTPBasicAuth +from .compat import ( + JSONDecodeError, + basestring, + builtin_str, + chardet, + cookielib, + urlencode, + urlsplit, + urlunparse, +) +from .compat import json as complexjson +from .cookies import ( + _copy_cookie_jar, # type: ignore[reportPrivateUsage] + cookiejar_from_dict, + get_cookie_header, +) +from .exceptions import ( + ChunkedEncodingError, + ConnectionError, + ContentDecodingError, + HTTPError, + InvalidJSONError, + InvalidURL, + MissingSchema, + StreamConsumedError, +) +from .exceptions import JSONDecodeError as RequestsJSONDecodeError +from .exceptions import SSLError as RequestsSSLError +from .hooks import default_hooks +from .status_codes import codes +from .structures import CaseInsensitiveDict +from .utils import ( + check_header_validity, + get_auth_from_url, + guess_filename, + guess_json_utf, + iter_slices, + parse_header_links, + requote_uri, + stream_decode_response_unicode, + super_len, + to_key_val_list, +) + +if TYPE_CHECKING: + from http.cookiejar import CookieJar + + from typing_extensions import Self + + from . import _types as _t + from .adapters import HTTPAdapter + from .cookies import RequestsCookieJar + +#: The set of HTTP status codes that indicate an automatically +#: processable redirect. +REDIRECT_STATI: Final[tuple[int, ...]] = ( # type: ignore[assignment] + codes.moved, # 301 + codes.found, # 302 + codes.other, # 303 + codes.temporary_redirect, # 307 + codes.permanent_redirect, # 308 +) + +DEFAULT_REDIRECT_LIMIT: int = 30 +CONTENT_CHUNK_SIZE: int = 10 * 1024 +ITER_CHUNK_SIZE: int = 512 + + +class RequestEncodingMixin: + url: str | None + + @property + def path_url(self) -> str: + """Build the path URL to use.""" + + url: list[str] = [] + + p = urlsplit(cast(str, self.url)) + + path = p.path + if not path: + path = "/" + + url.append(path) + + query = p.query + if query: + url.append("?") + url.append(query) + + return "".join(url) + + @overload + @staticmethod + def _encode_params(data: str) -> str: ... + + @overload + @staticmethod + def _encode_params(data: bytes) -> bytes: ... + + @overload + @staticmethod + def _encode_params( + data: _t.SupportsRead[str | bytes], + ) -> _t.SupportsRead[str | bytes]: ... + + @overload + @staticmethod + def _encode_params(data: _t.KVDataType) -> str: ... + + @staticmethod + def _encode_params( + data: _t.EncodableDataType, + ) -> str | bytes | _t.SupportsRead[str | bytes]: + """Encode parameters in a piece of data. + + Will successfully encode parameters when passed as a dict or a list of + 2-tuples. Order is retained if data is a list of 2-tuples but arbitrary + if parameters are supplied as a dict. + """ + + if isinstance(data, (str, bytes)): + return data + elif isinstance(data, _SupportsRead): + return data + elif hasattr(data, "__iter__"): + result: list[tuple[bytes, bytes]] = [] + for k, vs in to_key_val_list(data): + if isinstance(vs, basestring) or not hasattr(vs, "__iter__"): + vs = [vs] + for v in vs: + if v is not None: + result.append( + ( + k.encode("utf-8") if isinstance(k, str) else k, + v.encode("utf-8") if isinstance(v, str) else v, + ) + ) + return urlencode(result, doseq=True) + else: + return data # type: ignore[return-value] # unreachable for valid _t.DataType + + @staticmethod + def _encode_files( + files: _t.FilesType, data: _t.RawDataType | None + ) -> tuple[bytes, str]: + """Build the body for a multipart/form-data request. + + Will successfully encode files when passed as a dict or a list of + tuples. Order is retained if data is a list of tuples but arbitrary + if parameters are supplied as a dict. + The tuples may be 2-tuples (filename, fileobj), 3-tuples (filename, fileobj, contentype) + or 4-tuples (filename, fileobj, contentype, custom_headers). + """ + if not files: + raise ValueError("Files must be provided.") + elif isinstance(data, basestring): + raise ValueError("Data must not be a string.") + + new_fields: list[RequestField | tuple[str, bytes]] = [] + fields = to_key_val_list(data or {}) + files = to_key_val_list(files or {}) + + for field, val in fields: + if isinstance(val, basestring) or not hasattr(val, "__iter__"): + val = [val] + for v in val: + if v is not None: + # Don't call str() on bytestrings: in Py3 it all goes wrong. + if not isinstance(v, bytes): + v = str(v) + + new_fields.append( + ( + field.decode("utf-8") + if isinstance(field, bytes) + else field, + v.encode("utf-8") if isinstance(v, str) else v, + ) + ) + + for k, v in files: + # support for explicit filename + ft = None + fh = None + if isinstance(v, (tuple, list)): + if len(v) == 2: + fn, fp = v + elif len(v) == 3: + fn, fp, ft = v + else: + fn, fp, ft, fh = v + else: + fn = guess_filename(v) or k + fp = v + + if isinstance(fp, (str, bytes, bytearray)): + fdata = fp + elif isinstance(fp, _SupportsRead): # type: ignore[reportUnnecessaryIsInstance] # defensive check for untyped callers + fdata = fp.read() + elif fp is None: # type: ignore[reportUnnecessaryComparison] # defensive check for untyped callers + continue + else: + fdata = fp + + rf = RequestField(name=k, data=fdata, filename=fn, headers=fh) + rf.make_multipart(content_type=ft) + new_fields.append(rf) + + body, content_type = encode_multipart_formdata(new_fields) + + return body, content_type + + +class RequestHooksMixin: + hooks: dict[str, list[_t.HookType]] + + def register_hook( + self, event: str, hook: Iterable[_t.HookType] | _t.HookType + ) -> None: + """Properly register a hook.""" + + if event not in self.hooks: + raise ValueError(f'Unsupported event specified, with event name "{event}"') + + if isinstance(hook, Callable): + self.hooks[event].append(hook) + elif hasattr(hook, "__iter__"): + self.hooks[event].extend(h for h in hook if isinstance(h, Callable)) # type: ignore[reportUnnecessaryIsInstance] # defensive runtime filter + + def deregister_hook(self, event: str, hook: _t.HookType) -> bool: + """Deregister a previously registered hook. + Returns True if the hook existed, False if not. + """ + + try: + self.hooks[event].remove(hook) + return True + except ValueError: + return False + + +class Request(RequestHooksMixin): + """A user-created :class:`Request <Request>` object. + + Used to prepare a :class:`PreparedRequest <PreparedRequest>`, which is sent to the server. + + :param method: HTTP method to use. + :param url: URL to send. + :param headers: dictionary of headers to send. + :param files: dictionary of {filename: fileobject} files to multipart upload. + :param data: the body to attach to the request. If a dictionary or + list of tuples ``[(key, value)]`` is provided, form-encoding will + take place. + :param json: json for the body to attach to the request (if files or data is not specified). + :param params: URL parameters to append to the URL. If a dictionary or + list of tuples ``[(key, value)]`` is provided, form-encoding will + take place. + :param auth: Auth handler or (user, pass) tuple. + :param cookies: dictionary or CookieJar of cookies to attach to this request. + :param hooks: dictionary of callback hooks, for internal usage. + + Usage:: + + >>> import requests + >>> req = requests.Request('GET', 'https://httpbin.org/get') + >>> req.prepare() + <PreparedRequest [GET]> + """ + + method: str | None + url: _t.UriType | None + headers: CaseInsensitiveDict[str] | Mapping[str, str | bytes] | None + files: _t.FilesType + data: _t.DataType + json: _t.JsonType + params: _t.ParamsType + auth: _t.AuthType + cookies: RequestsCookieJar | CookieJar | dict[str, str] | None + + def __init__( + self, + method: str | None = None, + url: _t.UriType | None = None, + headers: Mapping[str, str | bytes] | None = None, + files: _t.FilesType = None, + data: _t.DataType = None, + params: _t.ParamsType = None, + auth: _t.AuthType = None, + cookies: RequestsCookieJar | CookieJar | dict[str, str] | None = None, + hooks: _t.HooksInputType | None = None, + json: _t.JsonType = None, + ) -> None: + # Default empty dicts for dict params. + data = [] if data is None else data + files = [] if files is None else files + headers = {} if headers is None else headers + params = {} if params is None else params + hooks = {} if hooks is None else hooks + + self.hooks = default_hooks() + for k, v in list(hooks.items()): + self.register_hook(event=k, hook=v) + + self.method = method + self.url = url + self.headers = headers + self.files = files + self.data = data + self.json = json + self.params = params + self.auth = auth + self.cookies = cookies + + def __repr__(self) -> str: + return f"<Request [{self.method}]>" + + def prepare(self) -> PreparedRequest: + """Constructs a :class:`PreparedRequest <PreparedRequest>` for transmission and returns it.""" + p = PreparedRequest() + p.prepare( + method=self.method, + url=self.url, + headers=self.headers, + files=self.files, + data=self.data, + json=self.json, + params=self.params, + auth=self.auth, + cookies=self.cookies, + hooks=self.hooks, + ) + return p + + +class PreparedRequest(RequestEncodingMixin, RequestHooksMixin): + """The fully mutable :class:`PreparedRequest <PreparedRequest>` object, + containing the exact bytes that will be sent to the server. + + Instances are generated from a :class:`Request <Request>` object, and + should not be instantiated manually; doing so may produce undesirable + effects. + + Usage:: + + >>> import requests + >>> req = requests.Request('GET', 'https://httpbin.org/get') + >>> r = req.prepare() + >>> r + <PreparedRequest [GET]> + + >>> s = requests.Session() + >>> s.send(r) + <Response [200]> + """ + + method: str | None + url: str | None + headers: CaseInsensitiveDict[str | bytes] + _cookies: RequestsCookieJar | CookieJar | None + body: _t.BodyType + hooks: dict[str, list[_t.HookType]] + _body_position: int | object | None + + def __init__(self) -> None: + #: HTTP verb to send to the server. + self.method = None + #: HTTP URL to send the request to. + self.url = None + #: dictionary of HTTP headers. + self.headers = None # type: ignore[assignment] + # The `CookieJar` used to create the Cookie header will be stored here + # after prepare_cookies is called + self._cookies = None + #: request body to send to the server. + self.body = None + #: dictionary of callback hooks, for internal usage. + self.hooks = default_hooks() + #: integer denoting starting position of a readable file-like body. + self._body_position = None + + def prepare( + self, + method: str | None = None, + url: _t.UriType | None = None, + headers: Mapping[str, str | bytes] | None = None, + files: _t.FilesType = None, + data: _t.DataType = None, + params: _t.ParamsType = None, + auth: _t.AuthType = None, + cookies: RequestsCookieJar | CookieJar | dict[str, str] | None = None, + hooks: _t.HooksInputType | None = None, + json: _t.JsonType = None, + ) -> None: + """Prepares the entire request with the given parameters.""" + + url = cast("_t.UriType", url) + self.prepare_method(method) + self.prepare_url(url, params) + self.prepare_headers(headers) + self.prepare_cookies(cookies) + self.prepare_body(data, files, json) + self.prepare_auth(auth, url) + + # Note that prepare_auth must be last to enable authentication schemes + # such as OAuth to work on a fully prepared request. + + # This MUST go after prepare_auth. Authenticators could add a hook + self.prepare_hooks(hooks) + + def __repr__(self) -> str: + return f"<PreparedRequest [{self.method}]>" + + def copy(self) -> PreparedRequest: + p = PreparedRequest() + p.method = self.method + p.url = self.url + p.headers = self.headers.copy() if self.headers is not None else None # type: ignore[assignment] + p._cookies = _copy_cookie_jar(self._cookies) + p.body = self.body + p.hooks = self.hooks + p._body_position = self._body_position + return p + + def prepare_method(self, method: str | None) -> None: + """Prepares the given HTTP method.""" + self.method = method + if self.method is not None: + self.method = to_native_string(self.method.upper()) + + @staticmethod + def _get_idna_encoded_host(host: str) -> str: + import idna + + try: + host = idna.encode(host, uts46=True).decode("utf-8") + except idna.IDNAError: + raise UnicodeError + return host + + def prepare_url( + self, + url: _t.UriType, + params: _t.ParamsType, + ) -> None: + """Prepares the given HTTP URL.""" + #: Accept objects that have string representations. + #: We're unable to blindly call unicode/str functions + #: as this will include the bytestring indicator (b'') + #: on python 3.x. + #: https://github.com/psf/requests/pull/2238 + if isinstance(url, bytes): + url = url.decode("utf8") + else: + url = str(url) + + # Remove leading whitespaces from url + url = url.lstrip() + + # Don't do any URL preparation for non-HTTP schemes like `mailto`, + # `data` etc to work around exceptions from `url_parse`, which + # handles RFC 3986 only. + if ":" in url and not url.lower().startswith("http"): + self.url = url + return + + # Support for unicode domain names and paths. + try: + scheme, auth, host, port, path, query, fragment = parse_url(url) + except LocationParseError as e: + raise InvalidURL(*e.args) + + if not scheme: + raise MissingSchema( + f"Invalid URL {url!r}: No scheme supplied. " + f"Perhaps you meant https://{url}?" + ) + + if not host: + raise InvalidURL(f"Invalid URL {url!r}: No host supplied") + + # In general, we want to try IDNA encoding the hostname if the string contains + # non-ASCII characters. This allows users to automatically get the correct IDNA + # behaviour. For strings containing only ASCII characters, we need to also verify + # it doesn't start with a wildcard (*), before allowing the unencoded hostname. + if not unicode_is_ascii(host): + try: + host = self._get_idna_encoded_host(host) + except UnicodeError: + raise InvalidURL("URL has an invalid label.") + elif host.startswith(("*", ".")): + raise InvalidURL("URL has an invalid label.") + + # Carefully reconstruct the network location + netloc = auth or "" + if netloc: + netloc += "@" + netloc += host + if port: + netloc += f":{port}" + + # Bare domains aren't valid URLs. + if not path: + path = "/" + + if isinstance(params, (str, bytes)): + params = to_native_string(params) + + if params is not None: + enc_params = self._encode_params(params) + else: + enc_params = "" + + if enc_params: + if query: + query = f"{query}&{enc_params}" + else: + query = enc_params + + url = requote_uri(urlunparse((scheme, netloc, path, "", query, fragment))) + self.url = url + + def prepare_headers(self, headers: Mapping[str, str | bytes] | None) -> None: + """Prepares the given HTTP headers.""" + + self.headers = CaseInsensitiveDict() + if headers: + for header in headers.items(): + # Raise exception on invalid header value. + check_header_validity(header) + name, value = header + self.headers[to_native_string(name)] = value + + def prepare_body( + self, data: _t.DataType, files: _t.FilesType, json: _t.JsonType = None + ) -> None: + """Prepares the given HTTP body data.""" + + # Check if file, fo, generator, iterator. + # If not, run through normal process. + + # Nottin' on you. + body = None + content_type = None + + if not data and json is not None: + # urllib3 requires a bytes-like body. Python 2's json.dumps + # provides this natively, but Python 3 gives a Unicode string. + content_type = "application/json" + + try: + body = complexjson.dumps(json, allow_nan=False) + except ValueError as ve: + raise InvalidJSONError(ve, request=self) + + if not isinstance(body, bytes): + body = body.encode("utf-8") + + if isinstance(data, Iterable) and not isinstance( + data, (str, bytes, list, tuple, Mapping) + ): + try: + length = super_len(data) + except (TypeError, AttributeError, UnsupportedOperation): + length = None + + body = data + + if getattr(body, "tell", None) is not None: + # Record the current file position before reading. + # This will allow us to rewind a file in the event + # of a redirect. + try: + self._body_position = body.tell() # type: ignore[union-attr] # guarded by getattr check + except OSError: + # This differentiates from None, allowing us to catch + # a failed `tell()` later when trying to rewind the body + self._body_position = object() + + if files: + raise NotImplementedError( + "Streamed bodies and files are mutually exclusive." + ) + + if length: + self.headers["Content-Length"] = builtin_str(length) + else: + self.headers["Transfer-Encoding"] = "chunked" + else: + # After is_stream filtering, remaining data is raw (not streamed) + raw_data = cast("_t.RawDataType | None", data) + + # Multi-part file uploads. + if files: + (body, content_type) = self._encode_files(files, raw_data) + else: + if raw_data: + body = self._encode_params(raw_data) + if isinstance(data, basestring) or isinstance(data, _SupportsRead): + content_type = None + else: + content_type = "application/x-www-form-urlencoded" + + self.prepare_content_length(body) + + # Add content-type if it wasn't explicitly provided. + if content_type and ("content-type" not in self.headers): + self.headers["Content-Type"] = content_type + + self.body = body # type: ignore[assignment] # body transforms from DataType to BodyType + + def prepare_content_length(self, body: _t.BodyType) -> None: + """Prepare Content-Length header based on request method and body""" + if body is not None: + length = super_len(body) + if length: + # If length exists, set it. Otherwise, we fallback + # to Transfer-Encoding: chunked. + self.headers["Content-Length"] = builtin_str(length) + elif ( + self.method not in ("GET", "HEAD") + and self.headers.get("Content-Length") is None + ): + # Set Content-Length to 0 for methods that can have a body + # but don't provide one. (i.e. not GET or HEAD) + self.headers["Content-Length"] = "0" + + def prepare_auth( + self, + auth: _t.AuthType, + url: _t.UriType = "", + ) -> None: + """Prepares the given HTTP auth data.""" + + # If no Auth is explicitly provided, extract it from the URL first. + if auth is None: + url_auth = get_auth_from_url(cast(str, self.url)) + auth = url_auth if any(url_auth) else None + + if auth: + if isinstance(auth, tuple) and len(auth) == 2: # type: ignore[arg-type] # pyright widens tuple from Callable in AuthType + # special-case basic HTTP auth + auth_handler = HTTPBasicAuth(*auth) # type: ignore[arg-type] # pyright widens tuple from Callable in AuthType + else: + # TODO: can be fixed by flipping the conditionals + auth_handler = cast("Callable[..., PreparedRequest]", auth) + + # Allow auth to make its changes. + r = auth_handler(self) + + # Update self to reflect the auth changes. + self.__dict__.update(r.__dict__) + + # Recompute Content-Length + self.prepare_content_length(self.body) + + def prepare_cookies( + self, cookies: RequestsCookieJar | CookieJar | dict[str, str] | None + ) -> None: + """Prepares the given HTTP cookie data. + + This function eventually generates a ``Cookie`` header from the + given cookies using cookielib. Due to cookielib's design, the header + will not be regenerated if it already exists, meaning this function + can only be called once for the life of the + :class:`PreparedRequest <PreparedRequest>` object. Any subsequent calls + to ``prepare_cookies`` will have no actual effect, unless the "Cookie" + header is removed beforehand. + """ + if isinstance(cookies, cookielib.CookieJar): + self._cookies = cookies + else: + self._cookies = cookiejar_from_dict(cookies) + + cookies_jar = cast("CookieJar", self._cookies) + cookie_header = get_cookie_header(cookies_jar, self) + if cookie_header is not None: + self.headers["Cookie"] = cookie_header + + def prepare_hooks(self, hooks: _t.HooksInputType | None) -> None: + """Prepares the given hooks.""" + # hooks can be passed as None to the prepare method and to this + # method. To prevent iterating over None, simply use an empty list + # if hooks is False-y + hooks = hooks or {} + for event in hooks: + self.register_hook(event, hooks[event]) + + +class Response: + """The :class:`Response <Response>` object, which contains a + server's response to an HTTP request. + """ + + _content: bytes | Literal[False] | None + _content_consumed: bool + _next: PreparedRequest | None + status_code: int + headers: CaseInsensitiveDict[str] + raw: Any + url: str + encoding: str | None + history: list[Response] + reason: str | None + cookies: RequestsCookieJar + elapsed: datetime.timedelta + request: PreparedRequest + connection: HTTPAdapter + + __attrs__: list[str] = [ + "_content", + "status_code", + "headers", + "url", + "history", + "encoding", + "reason", + "cookies", + "elapsed", + "request", + ] + + def __init__(self) -> None: + self._content = False + self._content_consumed = False + self._next = None + + #: Integer Code of responded HTTP Status, e.g. 404 or 200. + self.status_code = None # type: ignore[assignment] + + #: Case-insensitive Dictionary of Response Headers. + #: For example, ``headers['content-encoding']`` will return the + #: value of a ``'Content-Encoding'`` response header. + self.headers = CaseInsensitiveDict() + + #: File-like object representation of response (for advanced usage). + #: Use of ``raw`` requires that ``stream=True`` be set on the request. + #: This requirement does not apply for use internally to Requests. + self.raw = None + + #: Final URL location of Response. + self.url = None # type: ignore[assignment] + + #: Encoding to decode with when accessing r.text. + self.encoding = None + + #: A list of :class:`Response <Response>` objects from + #: the history of the Request. Any redirect responses will end + #: up here. The list is sorted from the oldest to the most recent request. + self.history = [] + + #: Textual reason of responded HTTP Status, e.g. "Not Found" or "OK". + self.reason = None + + #: A CookieJar of Cookies the server sent back. + self.cookies = cookiejar_from_dict({}) + + #: The amount of time elapsed between sending the request + #: and the arrival of the response (as a timedelta). + #: This property specifically measures the time taken between sending + #: the first byte of the request and finishing parsing the headers. It + #: is therefore unaffected by consuming the response content or the + #: value of the ``stream`` keyword argument. + self.elapsed = datetime.timedelta(0) + + #: The :class:`PreparedRequest <PreparedRequest>` object to which this + #: is a response. + self.request = None # type: ignore[assignment] + + def __enter__(self) -> Self: + return self + + def __exit__(self, *args: Any) -> None: + self.close() + + def __getstate__(self) -> dict[str, Any]: + # Consume everything; accessing the content attribute makes + # sure the content has been fully read. + if not self._content_consumed: + self.content + + return {attr: getattr(self, attr, None) for attr in self.__attrs__} + + def __setstate__(self, state: dict[str, Any]) -> None: + for name, value in state.items(): + setattr(self, name, value) + + # pickled objects do not have .raw + setattr(self, "_content_consumed", True) + setattr(self, "raw", None) + + def __repr__(self) -> str: + return f"<Response [{self.status_code}]>" + + def __bool__(self) -> bool: + """Returns True if :attr:`status_code` is less than 400. + + This attribute checks if the status code of the response is between + 400 and 600 to see if there was a client error or a server error. If + the status code, is between 200 and 400, this will return True. This + is **not** a check to see if the response code is ``200 OK``. + """ + return self.ok + + def __nonzero__(self) -> bool: + """Returns True if :attr:`status_code` is less than 400. + + This attribute checks if the status code of the response is between + 400 and 600 to see if there was a client error or a server error. If + the status code, is between 200 and 400, this will return True. This + is **not** a check to see if the response code is ``200 OK``. + """ + return self.ok + + def __iter__(self) -> Iterator[bytes]: + """Allows you to use a response as an iterator.""" + return self.iter_content(128) + + @property + def ok(self) -> bool: + """Returns True if :attr:`status_code` is less than 400, False if not. + + This attribute checks if the status code of the response is between + 400 and 600 to see if there was a client error or a server error. If + the status code is between 200 and 400, this will return True. This + is **not** a check to see if the response code is ``200 OK``. + """ + try: + self.raise_for_status() + except HTTPError: + return False + return True + + @property + def is_redirect(self) -> bool: + """True if this Response is a well-formed HTTP redirect that could have + been processed automatically (by :meth:`Session.resolve_redirects`). + """ + return "location" in self.headers and self.status_code in REDIRECT_STATI + + @property + def is_permanent_redirect(self) -> bool: + """True if this Response one of the permanent versions of redirect.""" + return "location" in self.headers and self.status_code in ( + codes.moved_permanently, + codes.permanent_redirect, + ) + + @property + def next(self) -> PreparedRequest | None: + """Returns a PreparedRequest for the next request in a redirect chain, if there is one.""" + return self._next + + @property + def apparent_encoding(self) -> str | None: + """The apparent encoding, provided by the charset_normalizer or chardet libraries.""" + if chardet is not None: + return chardet.detect(self.content)["encoding"] + else: + # If no character detection library is available, we'll fall back + # to a standard Python utf-8 str. + return "utf-8" + + @overload + def iter_content( + self, chunk_size: int | None = 1, decode_unicode: Literal[False] = False + ) -> Iterator[bytes]: ... + @overload + def iter_content( + self, chunk_size: int | None = 1, *, decode_unicode: Literal[True] + ) -> Iterator[str | bytes]: ... + def iter_content( + self, chunk_size: int | None = 1, decode_unicode: bool = False + ) -> Iterator[str | bytes]: + """Iterates over the response data. When stream=True is set on the + request, this avoids reading the content at once into memory for + large responses. The chunk size is the number of bytes it should + read into memory. This is not necessarily the length of each item + returned as decoding can take place. + + chunk_size must be of type int or None. A value of None will + function differently depending on the value of `stream`. + stream=True will read data as it arrives in whatever size the + chunks are received. If stream=False, data is returned as + a single chunk. + + If decode_unicode is True, content will be decoded using encoding + information from the response. If no encoding information is available, + bytes will be returned. This can be bypassed by manually setting + `encoding` on the response. + """ + + def generate() -> Generator[bytes, None, None]: + # Special case for urllib3. + if hasattr(self.raw, "stream"): + try: + yield from self.raw.stream(chunk_size, decode_content=True) + except ProtocolError as e: + raise ChunkedEncodingError(e) + except DecodeError as e: + raise ContentDecodingError(e) + except ReadTimeoutError as e: + raise ConnectionError(e) + except SSLError as e: + raise RequestsSSLError(e) + else: + # Standard file-like object. + while True: + chunk = self.raw.read(chunk_size) + if not chunk: + break + yield chunk + + self._content_consumed = True + + if self._content_consumed and isinstance(self._content, bool): + raise StreamConsumedError() + elif chunk_size is not None and not isinstance(chunk_size, int): # type: ignore[reportUnnecessaryIsInstance] # runtime guard for untyped callers + raise TypeError( + f"chunk_size must be an int, it is instead a {type(chunk_size)}." + ) + + if self._content_consumed: + # simulate reading small chunks of the content + content = cast(bytes, self._content) + chunks = iter_slices(content, chunk_size) + else: + chunks = generate() + + if decode_unicode: + chunks = stream_decode_response_unicode(chunks, self) + + return chunks + + @overload + def iter_lines( + self, + chunk_size: int = ITER_CHUNK_SIZE, + decode_unicode: Literal[False] = False, + delimiter: bytes | None = None, + ) -> Iterator[bytes]: ... + @overload + def iter_lines( + self, + chunk_size: int = ITER_CHUNK_SIZE, + *, + decode_unicode: Literal[True], + delimiter: str | bytes | None = None, + ) -> Iterator[str | bytes]: ... + def iter_lines( + self, + chunk_size: int = ITER_CHUNK_SIZE, + decode_unicode: bool = False, + delimiter: str | bytes | None = None, + ) -> Iterator[str | bytes]: + """Iterates over the response data, one line at a time. When + stream=True is set on the request, this avoids reading the + content at once into memory for large responses. + + The decode_unicode param works the same as in `iter_content`, with the + same caveats. + + .. note:: This method is not reentrant safe. + """ + + pending: str | bytes | None = None + + for chunk in self.iter_content( + chunk_size=chunk_size, decode_unicode=decode_unicode + ): + if pending is not None: + # TODO: remove cast after iter_lines rewrite + chunk = cast("str | bytes", pending + chunk) # type: ignore[operator] + + if delimiter: + lines = chunk.split(delimiter) # type: ignore[arg-type] + else: + lines = chunk.splitlines() + + if lines and lines[-1] and chunk and lines[-1][-1] == chunk[-1]: + pending = lines.pop() + else: + pending = None + + yield from lines + + if pending is not None: + yield pending + + @property + def content(self) -> bytes: + """Content of the response, in bytes.""" + + if self._content is False: + # Read the contents. + if self._content_consumed: + raise RuntimeError("The content for this response was already consumed") + + if self.status_code == 0 or self.raw is None: + self._content = None + else: + self._content = b"".join(self.iter_content(CONTENT_CHUNK_SIZE)) or b"" + + self._content_consumed = True + # don't need to release the connection; that's been handled by urllib3 + # since we exhausted the data. + return self._content # type: ignore[return-value] + + @property + def text(self) -> str: + """Content of the response, in unicode. + + If Response.encoding is None, encoding will be guessed using + ``charset_normalizer`` or ``chardet``. + + The encoding of the response content is determined based solely on HTTP + headers, following RFC 2616 to the letter. If you can take advantage of + non-HTTP knowledge to make a better guess at the encoding, you should + set ``r.encoding`` appropriately before accessing this property. + """ + + # Try charset from content-type + content = None + encoding = self.encoding + + if not self.content: + return "" + + # Fallback to auto-detected encoding. + if self.encoding is None: + encoding = self.apparent_encoding + + # Decode unicode from given encoding. + try: + content = str(self.content, encoding or "utf-8", errors="replace") + except (LookupError, TypeError): + # A LookupError is raised if the encoding was not found which could + # indicate a misspelling or similar mistake. + # + # A TypeError can be raised if encoding is None + # + # So we try blindly encoding. + content = str(self.content, errors="replace") + + return content + + def json(self, **kwargs: Any) -> Any: + r"""Decodes the JSON response body (if any) as a Python object. + + This may return a dictionary, list, etc. depending on what is in the response. + + :param \*\*kwargs: Optional arguments that ``json.loads`` takes. + :raises requests.exceptions.JSONDecodeError: If the response body does not + contain valid json. + """ + + if not self.encoding and self.content and len(self.content) > 3: + # No encoding set. JSON RFC 4627 section 3 states we should expect + # UTF-8, -16 or -32. Detect which one to use; If the detection or + # decoding fails, fall back to `self.text` (using charset_normalizer to make + # a best guess). + encoding = guess_json_utf(self.content) + if encoding is not None: + try: + return complexjson.loads(self.content.decode(encoding), **kwargs) + except UnicodeDecodeError: + # Wrong UTF codec detected; usually because it's not UTF-8 + # but some other 8-bit codec. This is an RFC violation, + # and the server didn't bother to tell us what codec *was* + # used. + pass + except JSONDecodeError as e: + raise RequestsJSONDecodeError(e.msg, e.doc, e.pos) + + try: + return complexjson.loads(self.text, **kwargs) + except JSONDecodeError as e: + # Catch JSON-related errors and raise as requests.JSONDecodeError + # This aliases json.JSONDecodeError and simplejson.JSONDecodeError + raise RequestsJSONDecodeError(e.msg, e.doc, e.pos) + + @property + def links(self) -> dict[str, dict[str, str]]: + """Returns the parsed header links of the response, if any.""" + + header = self.headers.get("link") + + resolved_links: dict[str, dict[str, str]] = {} + + if header: + links = parse_header_links(header) + + for link in links: + key = link.get("rel") or link.get("url") + if key is not None: + resolved_links[key] = link + + return resolved_links + + def raise_for_status(self) -> None: + """Raises :class:`HTTPError`, if one occurred.""" + + http_error_msg = "" + if isinstance(self.reason, bytes): + # We attempt to decode utf-8 first because some servers + # choose to localize their reason strings. If the string + # isn't utf-8, we fall back to iso-8859-1 for all other + # encodings. (See PR #3538) + try: + reason = self.reason.decode("utf-8") + except UnicodeDecodeError: + reason = self.reason.decode("iso-8859-1") + else: + reason = self.reason + + if 400 <= self.status_code < 500: + http_error_msg = ( + f"{self.status_code} Client Error: {reason} for url: {self.url}" + ) + + elif 500 <= self.status_code < 600: + http_error_msg = ( + f"{self.status_code} Server Error: {reason} for url: {self.url}" + ) + + if http_error_msg: + raise HTTPError(http_error_msg, response=self) + + def close(self) -> None: + """Releases the connection back to the pool. Once this method has been + called the underlying ``raw`` object must not be accessed again. + + *Note: Should not normally need to be called explicitly.* + """ + if not self._content_consumed: + self.raw.close() + + release_conn = getattr(self.raw, "release_conn", None) + if release_conn is not None: + release_conn() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/packages.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/packages.py new file mode 100644 index 0000000000000000000000000000000000000000..5ab3d8e250de8475cb22553f564e5444e02c7460 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/packages.py @@ -0,0 +1,23 @@ +import sys + +from .compat import chardet + +# This code exists for backwards compatibility reasons. +# I don't like it either. Just look the other way. :) + +for package in ("urllib3", "idna"): + locals()[package] = __import__(package) + # This traversal is apparently necessary such that the identities are + # preserved (requests.packages.urllib3.* is urllib3.*) + for mod in list(sys.modules): + if mod == package or mod.startswith(f"{package}."): + sys.modules[f"requests.packages.{mod}"] = sys.modules[mod] + +if chardet is not None: + target = chardet.__name__ + for mod in list(sys.modules): + if mod == target or mod.startswith(f"{target}."): + imported_mod = sys.modules[mod] + sys.modules[f"requests.packages.{mod}"] = imported_mod + mod = mod.replace(target, "chardet") + sys.modules[f"requests.packages.{mod}"] = imported_mod diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/py.typed b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/py.typed new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/sessions.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/sessions.py new file mode 100644 index 0000000000000000000000000000000000000000..8f13887d187deda256e08f305950a56a9c145ea5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/sessions.py @@ -0,0 +1,920 @@ +""" +requests.sessions +~~~~~~~~~~~~~~~~~ + +This module provides a Session object to manage and persist settings across +requests (cookies, auth, proxies). +""" + +from __future__ import annotations + +import os +import sys +import time +from collections import OrderedDict +from collections.abc import Generator, Mapping, MutableMapping +from datetime import timedelta +from typing import TYPE_CHECKING, Any, cast + +from ._internal_utils import to_native_string +from ._types import is_prepared as _is_prepared +from .adapters import HTTPAdapter +from .auth import _basic_auth_str # type: ignore[reportPrivateUsage] +from .compat import cookielib, urljoin, urlparse +from .cookies import ( + RequestsCookieJar, + cookiejar_from_dict, + extract_cookies_to_jar, + merge_cookies, +) +from .exceptions import ( + ChunkedEncodingError, + ContentDecodingError, + InvalidSchema, + TooManyRedirects, +) +from .hooks import default_hooks, dispatch_hook + +# formerly defined here, reexposed here for backward compatibility +from .models import ( # noqa: F401 + DEFAULT_REDIRECT_LIMIT, + REDIRECT_STATI, # type: ignore[reportUnusedImport] + PreparedRequest, + Request, + Response, +) +from .status_codes import codes +from .structures import CaseInsensitiveDict +from .utils import ( # noqa: F401 + DEFAULT_PORTS, + default_headers, + get_auth_from_url, + get_environ_proxies, + get_netrc_auth, + requote_uri, + resolve_proxies, + rewind_body, + should_bypass_proxies, # type: ignore[reportUnusedImport] # re-export for external consumers + to_key_val_list, +) + +if TYPE_CHECKING: + from http.cookiejar import CookieJar + + from typing_extensions import Self, Unpack + + from . import _types as _t + from .adapters import BaseAdapter + +# Preferred clock, based on which one is more accurate on a given system. +if sys.platform == "win32": + preferred_clock = time.perf_counter +else: + preferred_clock = time.time + + +def merge_setting( + request_setting: Any, session_setting: Any, dict_class: type = OrderedDict +) -> Any: + """Determines appropriate setting for a given request, taking into account + the explicit setting on that request, and the setting in the session. If a + setting is a dictionary, they will be merged together using `dict_class` + """ + + if session_setting is None: + return request_setting + + if request_setting is None: + return session_setting + + # Bypass if not a dictionary (e.g. verify) + if not ( + isinstance(session_setting, Mapping) and isinstance(request_setting, Mapping) + ): + return request_setting + + merged_setting = dict_class(to_key_val_list(session_setting)) # type: ignore[arg-type] # isinstance narrows Any to Mapping[Unknown] + merged_setting.update(to_key_val_list(request_setting)) # type: ignore[arg-type] + + # Remove keys that are set to None. Extract keys first to avoid altering + # the dictionary during iteration. + none_keys = [k for (k, v) in merged_setting.items() if v is None] + for key in none_keys: + del merged_setting[key] + + return merged_setting + + +def merge_hooks( + request_hooks: _t.HooksType, + session_hooks: _t.HooksType, + dict_class: type = OrderedDict, +) -> _t.HooksType: + """Properly merges both requests and session hooks. + + This is necessary because when request_hooks == {'response': []}, the + merge breaks Session hooks entirely. + """ + if session_hooks is None or session_hooks.get("response") == []: + return request_hooks + + if request_hooks is None or request_hooks.get("response") == []: + return session_hooks + + return merge_setting(request_hooks, session_hooks, dict_class) + + +class SessionRedirectMixin: + max_redirects: int + trust_env: bool + cookies: RequestsCookieJar + + def send(self, request: PreparedRequest, **kwargs: Any) -> Response: ... + + def get_redirect_target(self, resp: Response) -> str | None: + """Receives a Response. Returns a redirect URI or ``None``""" + # Due to the nature of how requests processes redirects this method will + # be called at least once upon the original response and at least twice + # on each subsequent redirect response (if any). + # If a custom mixin is used to handle this logic, it may be advantageous + # to cache the redirect location onto the response object as a private + # attribute. + if resp.is_redirect: + location = resp.headers["location"] + # Currently the underlying http module on py3 decode headers + # in latin1, but empirical evidence suggests that latin1 is very + # rarely used with non-ASCII characters in HTTP headers. + # It is more likely to get UTF8 header rather than latin1. + # This causes incorrect handling of UTF8 encoded location headers. + # To solve this, we re-encode the location in latin1. + location = location.encode("latin1") + return to_native_string(location, "utf8") + return None + + def should_strip_auth(self, old_url: str, new_url: str) -> bool: + """Decide whether Authorization header should be removed when redirecting""" + old_parsed = urlparse(old_url) + new_parsed = urlparse(new_url) + if old_parsed.hostname != new_parsed.hostname: + return True + # Special case: allow http -> https redirect when using the standard + # ports. This isn't specified by RFC 7235, but is kept to avoid + # breaking backwards compatibility with older versions of requests + # that allowed any redirects on the same host. + if ( + old_parsed.scheme == "http" + and old_parsed.port in (80, None) + and new_parsed.scheme == "https" + and new_parsed.port in (443, None) + ): + return False + + # Handle default port usage corresponding to scheme. + changed_port = old_parsed.port != new_parsed.port + changed_scheme = old_parsed.scheme != new_parsed.scheme + default_port = (DEFAULT_PORTS.get(old_parsed.scheme, None), None) + if ( + not changed_scheme + and old_parsed.port in default_port + and new_parsed.port in default_port + ): + return False + + # Standard case: root URI must match + return changed_port or changed_scheme + + def resolve_redirects( + self, + resp: Response, + req: PreparedRequest, + stream: bool = False, + timeout: _t.TimeoutType = None, + verify: _t.VerifyType = True, + cert: _t.CertType = None, + proxies: dict[str, str] | None = None, + yield_requests: bool = False, + **adapter_kwargs: Any, + ) -> Generator[Response, None, None]: + """Receives a Response. Returns a generator of Responses or Requests.""" + + hist: list[Response] = [] # keep track of history + + url = self.get_redirect_target(resp) + previous_fragment = urlparse(req.url).fragment + while url: + prepared_request = req.copy() + + # Update history and keep track of redirects. + resp.history = hist[:] + hist.append(resp) + + try: + resp.content # Consume socket so it can be released + except (ChunkedEncodingError, ContentDecodingError, RuntimeError): + resp.raw.read(decode_content=False) + + if len(resp.history) >= self.max_redirects: + raise TooManyRedirects( + f"Exceeded {self.max_redirects} redirects.", response=resp + ) + + # Release the connection back into the pool. + resp.close() + + # Handle redirection without scheme (see: RFC 1808 Section 4) + if url.startswith("//"): + parsed_rurl = urlparse(resp.url) + url = ":".join([to_native_string(parsed_rurl.scheme), url]) + + # Normalize url case and attach previous fragment if needed (RFC 7231 7.1.2) + parsed = urlparse(url) + if parsed.fragment == "" and previous_fragment: + parsed = parsed._replace(fragment=previous_fragment) + elif parsed.fragment: + previous_fragment = parsed.fragment + url = parsed.geturl() + + # Facilitate relative 'location' headers, as allowed by RFC 7231. + # (e.g. '/path/to/resource' instead of 'http://domain.tld/path/to/resource') + # Compliant with RFC3986, we percent encode the url. + if not parsed.netloc: + url = urljoin(resp.url, requote_uri(url)) + else: + url = requote_uri(url) + + prepared_request.url = to_native_string(url) + + self.rebuild_method(prepared_request, resp) + + # https://github.com/psf/requests/issues/1084 + if resp.status_code not in ( + codes.temporary_redirect, + codes.permanent_redirect, + ): + # https://github.com/psf/requests/issues/3490 + purged_headers = ("Content-Length", "Content-Type", "Transfer-Encoding") + for header in purged_headers: + prepared_request.headers.pop(header, None) + prepared_request.body = None + + headers = prepared_request.headers + headers.pop("Cookie", None) + + # Extract any cookies sent on the response to the cookiejar + # in the new request. Because we've mutated our copied prepared + # request, use the old one that we haven't yet touched. + cookie_jar = cast("CookieJar", prepared_request._cookies) # type: ignore[reportPrivateUsage] + extract_cookies_to_jar(cookie_jar, req, resp.raw) + merge_cookies(cookie_jar, self.cookies) + prepared_request.prepare_cookies(cookie_jar) + + # Rebuild auth and proxy information. + proxies = self.rebuild_proxies(prepared_request, proxies) + self.rebuild_auth(prepared_request, resp) + + # A failed tell() sets `_body_position` to `object()`. This non-None + # value ensures `rewindable` will be True, allowing us to raise an + # UnrewindableBodyError, instead of hanging the connection. + rewindable = prepared_request._body_position is not None and ( # type: ignore[reportPrivateUsage] + "Content-Length" in headers or "Transfer-Encoding" in headers + ) + + # Attempt to rewind consumed file-like object. + if rewindable: + rewind_body(prepared_request) + + # Override the original request. + req = prepared_request + + if yield_requests: + yield req # type: ignore[misc] # Internal use only, returns PreparedRequest + else: + resp = self.send( + req, + stream=stream, + timeout=timeout, + verify=verify, + cert=cert, + proxies=proxies, + allow_redirects=False, + **adapter_kwargs, + ) + + extract_cookies_to_jar(self.cookies, prepared_request, resp.raw) + + # extract redirect url, if any, for the next loop + url = self.get_redirect_target(resp) + yield resp + + def rebuild_auth( + self, prepared_request: PreparedRequest, response: Response + ) -> None: + """When being redirected we may want to strip authentication from the + request to avoid leaking credentials. This method intelligently removes + and reapplies authentication where possible to avoid credential loss. + """ + original_request = response.request + assert _is_prepared(original_request) + assert _is_prepared(prepared_request) + + headers = prepared_request.headers + original_url = original_request.url + url = prepared_request.url + + if "Authorization" in headers and self.should_strip_auth(original_url, url): + # If we get redirected to a new host, we should strip out any + # authentication headers. + del headers["Authorization"] + + # .netrc might have more auth for us on our new host. + new_auth = get_netrc_auth(url) if self.trust_env else None + if new_auth is not None: + prepared_request.prepare_auth(new_auth) + + def rebuild_proxies( + self, + prepared_request: PreparedRequest, + proxies: dict[str, str] | None, + ) -> dict[str, str]: + """This method re-evaluates the proxy configuration by considering the + environment variables. If we are redirected to a URL covered by + NO_PROXY, we strip the proxy configuration. Otherwise, we set missing + proxy keys for this URL (in case they were stripped by a previous + redirect). + + This method also replaces the Proxy-Authorization header where + necessary. + + :rtype: dict + """ + assert _is_prepared(prepared_request) + headers = prepared_request.headers + scheme = urlparse(prepared_request.url).scheme + new_proxies = resolve_proxies(prepared_request, proxies, self.trust_env) + + if "Proxy-Authorization" in headers: + del headers["Proxy-Authorization"] + + try: + username, password = get_auth_from_url(new_proxies[scheme]) + except KeyError: + username, password = None, None + + # urllib3 handles proxy authorization for us in the standard adapter. + # Avoid appending this to TLS tunneled requests where it may be leaked. + if not scheme.startswith("https") and username and password: + headers["Proxy-Authorization"] = _basic_auth_str(username, password) + + return new_proxies + + def rebuild_method( + self, prepared_request: PreparedRequest, response: Response + ) -> None: + """When being redirected we may want to change the method of the request + based on certain specs or browser behavior. + """ + method = prepared_request.method + + # https://tools.ietf.org/html/rfc7231#section-6.4.4 + if response.status_code == codes.see_other and method != "HEAD": + method = "GET" + + # Do what the browsers do, despite standards... + # First, turn 302s into GETs. + if response.status_code == codes.found and method != "HEAD": + method = "GET" + + # Second, if a POST is responded to with a 301, turn it into a GET. + # This bizarre behaviour is explained in Issue 1704. + if response.status_code == codes.moved and method == "POST": + method = "GET" + + prepared_request.method = method + + +class Session(SessionRedirectMixin): + """A Requests session. + + Provides cookie persistence, connection-pooling, and configuration. + + Basic Usage:: + + >>> import requests + >>> s = requests.Session() + >>> s.get('https://httpbin.org/get') + <Response [200]> + + Or as a context manager:: + + >>> with requests.Session() as s: + ... s.get('https://httpbin.org/get') + <Response [200]> + """ + + headers: CaseInsensitiveDict[str] + auth: _t.AuthType + proxies: dict[str, str] + hooks: dict[str, list[_t.HookType]] + params: MutableMapping[str, Any] + stream: bool + verify: _t.VerifyType + cert: _t.CertType + max_redirects: int + trust_env: bool + cookies: RequestsCookieJar + adapters: MutableMapping[str, BaseAdapter] + + __attrs__: list[str] = [ + "headers", + "cookies", + "auth", + "proxies", + "hooks", + "params", + "verify", + "cert", + "adapters", + "stream", + "trust_env", + "max_redirects", + ] + + def __init__(self) -> None: + #: A case-insensitive dictionary of headers to be sent on each + #: :class:`Request <Request>` sent from this + #: :class:`Session <Session>`. + self.headers = default_headers() + + #: Default Authentication tuple or object to attach to + #: :class:`Request <Request>`. + self.auth = None + + #: Dictionary mapping protocol or protocol and host to the URL of the proxy + #: (e.g. {'http': 'foo.bar:3128', 'http://host.name': 'foo.bar:4012'}) to + #: be used on each :class:`Request <Request>`. + self.proxies = {} + + #: Event-handling hooks. + self.hooks = default_hooks() + + #: Dictionary of querystring data to attach to each + #: :class:`Request <Request>`. The dictionary values may be lists for + #: representing multivalued query parameters. + self.params = {} + + #: Stream response content default. + self.stream = False + + #: SSL Verification default. + #: Defaults to `True`, requiring requests to verify the TLS certificate at the + #: remote end. + #: If verify is set to `False`, requests will accept any TLS certificate + #: presented by the server, and will ignore hostname mismatches and/or + #: expired certificates, which will make your application vulnerable to + #: man-in-the-middle (MitM) attacks. + #: Only set this to `False` for testing. + #: If verify is set to a string, it must be the path to a CA bundle file + #: that will be used to verify the TLS certificate. + self.verify = True + + #: SSL client certificate default, if String, path to ssl client + #: cert file (.pem). If Tuple, ('cert', 'key') pair. + self.cert = None + + #: Maximum number of redirects allowed. If the request exceeds this + #: limit, a :class:`TooManyRedirects` exception is raised. + #: This defaults to requests.models.DEFAULT_REDIRECT_LIMIT, which is + #: 30. + self.max_redirects = DEFAULT_REDIRECT_LIMIT + + #: Trust environment settings for proxy configuration, default + #: authentication and similar. + self.trust_env = True + + #: A CookieJar containing all currently outstanding cookies set on this + #: session. By default it is a + #: :class:`RequestsCookieJar <requests.cookies.RequestsCookieJar>`, but + #: may be any other ``cookielib.CookieJar`` compatible object. + self.cookies = cookiejar_from_dict({}) + + # Default connection adapters. + self.adapters = OrderedDict() + self.mount("https://", HTTPAdapter()) + self.mount("http://", HTTPAdapter()) + + def __enter__(self) -> Self: + return self + + def __exit__(self, *args: Any) -> None: + self.close() + + def prepare_request(self, request: Request) -> PreparedRequest: + """Constructs a :class:`PreparedRequest <PreparedRequest>` for + transmission and returns it. The :class:`PreparedRequest` has settings + merged from the :class:`Request <Request>` instance and those of the + :class:`Session`. + + :param request: :class:`Request` instance to prepare with this + session's settings. + :rtype: requests.PreparedRequest + """ + url = cast("_t.UriType", request.url) + method = cast(str, request.method) + + cookies = request.cookies or {} + + # Bootstrap CookieJar. + if not isinstance(cookies, cookielib.CookieJar): + cookies = cookiejar_from_dict(cookies) + + # Merge with session cookies + merged_cookies = merge_cookies( + merge_cookies(RequestsCookieJar(), self.cookies), cookies + ) + + # Set environment's basic authentication if not explicitly set. + auth = request.auth + if self.trust_env and not auth and not self.auth: + auth = get_netrc_auth(url) + + p = PreparedRequest() + p.prepare( + method=method.upper(), + url=url, + files=request.files, + data=request.data, + json=request.json, + headers=merge_setting( + request.headers, self.headers, dict_class=CaseInsensitiveDict + ), + params=merge_setting(request.params, self.params), + auth=merge_setting(auth, self.auth), + cookies=merged_cookies, + hooks=merge_hooks(request.hooks, self.hooks), + ) + return p + + def request( + self, + method: str, + url: _t.UriType, + params: _t.ParamsType = None, + data: _t.DataType = None, + headers: Mapping[str, str | bytes] | None = None, + cookies: RequestsCookieJar | CookieJar | dict[str, str] | None = None, + files: _t.FilesType = None, + auth: _t.AuthType = None, + timeout: _t.TimeoutType = None, + allow_redirects: bool = True, + proxies: dict[str, str] | None = None, + hooks: _t.HooksInputType | None = None, + stream: bool | None = None, + verify: _t.VerifyType | None = None, + cert: _t.CertType = None, + json: _t.JsonType = None, + ) -> Response: + """Constructs a :class:`Request <Request>`, prepares it and sends it. + Returns :class:`Response <Response>` object. + + :param method: method for the new :class:`Request` object. + :param url: URL for the new :class:`Request` object. + :param params: (optional) Dictionary or bytes to be sent in the query + string for the :class:`Request`. + :param data: (optional) Dictionary, list of tuples, bytes, or file-like + object to send in the body of the :class:`Request`. + :param json: (optional) json to send in the body of the + :class:`Request`. + :param headers: (optional) Dictionary of HTTP Headers to send with the + :class:`Request`. + :param cookies: (optional) Dict or CookieJar object to send with the + :class:`Request`. + :param files: (optional) Dictionary of ``'filename': file-like-objects`` + for multipart encoding upload. + :param auth: (optional) Auth tuple or callable to enable + Basic/Digest/Custom HTTP Auth. + :param timeout: (optional) How many seconds to wait for the server to send + data before giving up, as a float, or a :ref:`(connect timeout, + read timeout) <timeouts>` tuple. + :type timeout: float or tuple + :param allow_redirects: (optional) Set to True by default. + :type allow_redirects: bool + :param proxies: (optional) Dictionary mapping protocol or protocol and + hostname to the URL of the proxy. + :param hooks: (optional) Dictionary mapping hook name to one event or + list of events, event must be callable. + :param stream: (optional) whether to immediately download the response + content. Defaults to ``False``. + :param verify: (optional) Either a boolean, in which case it controls whether we verify + the server's TLS certificate, or a string, in which case it must be a path + to a CA bundle to use. Defaults to ``True``. When set to + ``False``, requests will accept any TLS certificate presented by + the server, and will ignore hostname mismatches and/or expired + certificates, which will make your application vulnerable to + man-in-the-middle (MitM) attacks. Setting verify to ``False`` + may be useful during local development or testing. + :param cert: (optional) if String, path to ssl client cert file (.pem). + If Tuple, ('cert', 'key') pair. + :rtype: requests.Response + """ + if isinstance(url, bytes): + url = url.decode("utf-8") + + # Create the Request. + req = Request( + method=method.upper(), + url=url, + headers=headers, + files=files, + data=data or {}, + json=json, + params=params or {}, + auth=auth, + cookies=cookies, + hooks=hooks, + ) + prep = self.prepare_request(req) + + assert _is_prepared(prep) + + proxies = proxies or {} + + settings = self.merge_environment_settings( + prep.url, proxies, stream, verify, cert + ) + + # Send the request. + send_kwargs = { + "timeout": timeout, + "allow_redirects": allow_redirects, + } + send_kwargs.update(settings) + resp = self.send(prep, **send_kwargs) + + return resp + + def get( + self, + url: _t.UriType, + params: _t.ParamsType = None, + **kwargs: Unpack[_t.GetKwargs], + ) -> Response: + r"""Sends a GET request. Returns :class:`Response` object. + + :param url: URL for the new :class:`Request` object. + :param params: (optional) Dictionary, list of tuples or bytes to send + in the query string for the :class:`Request`. + :param \*\*kwargs: Optional arguments that ``request`` takes. + :rtype: requests.Response + """ + + kwargs.setdefault("allow_redirects", True) + return self.request("GET", url, params=params, **kwargs) + + def options(self, url: _t.UriType, **kwargs: Unpack[_t.RequestKwargs]) -> Response: + r"""Sends a OPTIONS request. Returns :class:`Response` object. + + :param url: URL for the new :class:`Request` object. + :param \*\*kwargs: Optional arguments that ``request`` takes. + :rtype: requests.Response + """ + + kwargs.setdefault("allow_redirects", True) + return self.request("OPTIONS", url, **kwargs) + + def head(self, url: _t.UriType, **kwargs: Unpack[_t.RequestKwargs]) -> Response: + r"""Sends a HEAD request. Returns :class:`Response` object. + + :param url: URL for the new :class:`Request` object. + :param \*\*kwargs: Optional arguments that ``request`` takes. + :rtype: requests.Response + """ + + kwargs.setdefault("allow_redirects", False) + return self.request("HEAD", url, **kwargs) + + def post( + self, + url: _t.UriType, + data: _t.DataType = None, + json: _t.JsonType = None, + **kwargs: Unpack[_t.PostKwargs], + ) -> Response: + r"""Sends a POST request. Returns :class:`Response` object. + + :param url: URL for the new :class:`Request` object. + :param data: (optional) Dictionary, list of tuples, bytes, or file-like + object to send in the body of the :class:`Request`. + :param json: (optional) json to send in the body of the :class:`Request`. + :param \*\*kwargs: Optional arguments that ``request`` takes. + :rtype: requests.Response + """ + + return self.request("POST", url, data=data, json=json, **kwargs) + + def put( + self, url: _t.UriType, data: _t.DataType = None, **kwargs: Unpack[_t.DataKwargs] + ) -> Response: + r"""Sends a PUT request. Returns :class:`Response` object. + + :param url: URL for the new :class:`Request` object. + :param data: (optional) Dictionary, list of tuples, bytes, or file-like + object to send in the body of the :class:`Request`. + :param \*\*kwargs: Optional arguments that ``request`` takes. + :rtype: requests.Response + """ + + return self.request("PUT", url, data=data, **kwargs) + + def patch( + self, url: _t.UriType, data: _t.DataType = None, **kwargs: Unpack[_t.DataKwargs] + ) -> Response: + r"""Sends a PATCH request. Returns :class:`Response` object. + + :param url: URL for the new :class:`Request` object. + :param data: (optional) Dictionary, list of tuples, bytes, or file-like + object to send in the body of the :class:`Request`. + :param \*\*kwargs: Optional arguments that ``request`` takes. + :rtype: requests.Response + """ + + return self.request("PATCH", url, data=data, **kwargs) + + def delete(self, url: _t.UriType, **kwargs: Unpack[_t.RequestKwargs]) -> Response: + r"""Sends a DELETE request. Returns :class:`Response` object. + + :param url: URL for the new :class:`Request` object. + :param \*\*kwargs: Optional arguments that ``request`` takes. + :rtype: requests.Response + """ + + return self.request("DELETE", url, **kwargs) + + def send(self, request: PreparedRequest, **kwargs: Any) -> Response: + """Send a given PreparedRequest. + + :rtype: requests.Response + """ + # Set defaults that the hooks can utilize to ensure they always have + # the correct parameters to reproduce the previous request. + kwargs.setdefault("stream", self.stream) + kwargs.setdefault("verify", self.verify) + kwargs.setdefault("cert", self.cert) + if "proxies" not in kwargs: + kwargs["proxies"] = resolve_proxies(request, self.proxies, self.trust_env) + + # It's possible that users might accidentally send a Request object. + # Guard against that specific failure case. + if isinstance(request, Request): + raise ValueError("You can only send PreparedRequests.") + + assert _is_prepared(request) + + # Set up variables needed for resolve_redirects and dispatching of hooks + allow_redirects = kwargs.pop("allow_redirects", True) + stream = kwargs.get("stream") + hooks = request.hooks + + # Get the appropriate adapter to use + adapter = self.get_adapter(url=request.url) + + # Start time (approximately) of the request + start = preferred_clock() + + # Send the request + r = adapter.send(request, **kwargs) + + # Total elapsed time of the request (approximately) + elapsed = preferred_clock() - start + r.elapsed = timedelta(seconds=elapsed) + + # Response manipulation hooks + r = dispatch_hook("response", hooks, r, **kwargs) + + # Persist cookies + if r.history: + # If the hooks create history then we want those cookies too + for resp in r.history: + extract_cookies_to_jar(self.cookies, resp.request, resp.raw) + + extract_cookies_to_jar(self.cookies, request, r.raw) + + # Resolve redirects if allowed. + if allow_redirects: + # Redirect resolving generator. + gen = self.resolve_redirects(r, request, **kwargs) + history = [resp for resp in gen] + else: + history = [] + + # Shuffle things around if there's history. + if history: + # Insert the first (original) request at the start + history.insert(0, r) + # Get the last request made + r = history.pop() + r.history = history + + # If redirects aren't being followed, store the response on the Request for Response.next(). + if not allow_redirects: + try: + r._next = next( # type: ignore[assignment] # yield_requests=True returns PreparedRequest + self.resolve_redirects(r, request, yield_requests=True, **kwargs) + ) + except StopIteration: + pass + + if not stream: + r.content + + return r + + def merge_environment_settings( + self, + url: str, + proxies: dict[str, str] | None, + stream: bool | None, + verify: _t.VerifyType | None, + cert: _t.CertType, + ) -> dict[str, Any]: + """ + Check the environment and merge it with some settings. + + :rtype: dict + """ + # Gather clues from the surrounding environment. + if self.trust_env: + # Set environment's proxies. + no_proxy = proxies.get("no_proxy") if proxies is not None else None + env_proxies = get_environ_proxies(url, no_proxy=no_proxy) + if proxies is not None: + for k, v in env_proxies.items(): + proxies.setdefault(k, v) + + # Look for requests environment configuration + # and be compatible with cURL. + if verify is True or verify is None: + verify = ( + os.environ.get("REQUESTS_CA_BUNDLE") + or os.environ.get("CURL_CA_BUNDLE") + or verify + ) + + # Merge all the kwargs. + proxies = merge_setting(proxies, self.proxies) + stream = merge_setting(stream, self.stream) + verify = merge_setting(verify, self.verify) + cert = merge_setting(cert, self.cert) + + return {"proxies": proxies, "stream": stream, "verify": verify, "cert": cert} + + def get_adapter(self, url: str) -> BaseAdapter: + """ + Returns the appropriate connection adapter for the given URL. + + :rtype: requests.adapters.BaseAdapter + """ + for prefix, adapter in self.adapters.items(): + if url.lower().startswith(prefix.lower()): + return adapter + + # Nothing matches :-/ + raise InvalidSchema(f"No connection adapters were found for {url!r}") + + def close(self) -> None: + """Closes all adapters and as such the session""" + for v in self.adapters.values(): + v.close() + + def mount(self, prefix: str, adapter: BaseAdapter) -> None: + """Registers a connection adapter to a prefix. + + Adapters are sorted in descending order by prefix length. + """ + self.adapters[prefix] = adapter + keys_to_move = [k for k in self.adapters if len(k) < len(prefix)] + + for key in keys_to_move: + self.adapters[key] = self.adapters.pop(key) + + def __getstate__(self) -> dict[str, Any]: + state = {attr: getattr(self, attr, None) for attr in self.__attrs__} + return state + + def __setstate__(self, state: dict[str, Any]) -> None: + for attr, value in state.items(): + setattr(self, attr, value) + + +def session() -> Session: + """ + Returns a :class:`Session` for context-management. + + .. deprecated:: 1.0.0 + + This method has been deprecated since version 1.0.0 and is only kept for + backwards compatibility. New code should use :class:`~requests.sessions.Session` + to create a session. This may be removed at a future date. + + :rtype: Session + """ + return Session() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/status_codes.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/status_codes.py new file mode 100644 index 0000000000000000000000000000000000000000..6c59d6baec83bd82055106a5d2cea08fa1195274 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/status_codes.py @@ -0,0 +1,128 @@ +r""" +The ``codes`` object defines a mapping from common names for HTTP statuses +to their numerical codes, accessible either as attributes or as dictionary +items. + +Example:: + + >>> import requests + >>> requests.codes['temporary_redirect'] + 307 + >>> requests.codes.teapot + 418 + >>> requests.codes['\o/'] + 200 + +Some codes have multiple names, and both upper- and lower-case versions of +the names are allowed. For example, ``codes.ok``, ``codes.OK``, and +``codes.okay`` all correspond to the HTTP status code 200. +""" + +from .structures import LookupDict + +_codes = { + # Informational. + 100: ("continue",), + 101: ("switching_protocols",), + 102: ("processing", "early-hints"), + 103: ("checkpoint",), + 122: ("uri_too_long", "request_uri_too_long"), + 200: ("ok", "okay", "all_ok", "all_okay", "all_good", "\\o/", "✓"), + 201: ("created",), + 202: ("accepted",), + 203: ("non_authoritative_info", "non_authoritative_information"), + 204: ("no_content",), + 205: ("reset_content", "reset"), + 206: ("partial_content", "partial"), + 207: ("multi_status", "multiple_status", "multi_stati", "multiple_stati"), + 208: ("already_reported",), + 226: ("im_used",), + # Redirection. + 300: ("multiple_choices",), + 301: ("moved_permanently", "moved", "\\o-"), + 302: ("found",), + 303: ("see_other", "other"), + 304: ("not_modified",), + 305: ("use_proxy",), + 306: ("switch_proxy",), + 307: ("temporary_redirect", "temporary_moved", "temporary"), + 308: ( + "permanent_redirect", + "resume_incomplete", + "resume", + ), # "resume" and "resume_incomplete" to be removed in 3.0 + # Client Error. + 400: ("bad_request", "bad"), + 401: ("unauthorized",), + 402: ("payment_required", "payment"), + 403: ("forbidden",), + 404: ("not_found", "-o-"), + 405: ("method_not_allowed", "not_allowed"), + 406: ("not_acceptable",), + 407: ("proxy_authentication_required", "proxy_auth", "proxy_authentication"), + 408: ("request_timeout", "timeout"), + 409: ("conflict",), + 410: ("gone",), + 411: ("length_required",), + 412: ("precondition_failed", "precondition"), + 413: ("request_entity_too_large", "content_too_large"), + 414: ("request_uri_too_large", "uri_too_long"), + 415: ("unsupported_media_type", "unsupported_media", "media_type"), + 416: ( + "requested_range_not_satisfiable", + "requested_range", + "range_not_satisfiable", + ), + 417: ("expectation_failed",), + 418: ("im_a_teapot", "teapot", "i_am_a_teapot"), + 421: ("misdirected_request",), + 422: ("unprocessable_entity", "unprocessable", "unprocessable_content"), + 423: ("locked",), + 424: ("failed_dependency", "dependency"), + 425: ("unordered_collection", "unordered", "too_early"), + 426: ("upgrade_required", "upgrade"), + 428: ("precondition_required", "precondition"), + 429: ("too_many_requests", "too_many"), + 431: ("header_fields_too_large", "fields_too_large"), + 444: ("no_response", "none"), + 449: ("retry_with", "retry"), + 450: ("blocked_by_windows_parental_controls", "parental_controls"), + 451: ("unavailable_for_legal_reasons", "legal_reasons"), + 499: ("client_closed_request",), + # Server Error. + 500: ("internal_server_error", "server_error", "/o\\", "✗"), + 501: ("not_implemented",), + 502: ("bad_gateway",), + 503: ("service_unavailable", "unavailable"), + 504: ("gateway_timeout",), + 505: ("http_version_not_supported", "http_version"), + 506: ("variant_also_negotiates",), + 507: ("insufficient_storage",), + 509: ("bandwidth_limit_exceeded", "bandwidth"), + 510: ("not_extended",), + 511: ("network_authentication_required", "network_auth", "network_authentication"), +} + +codes: LookupDict[int] = LookupDict(name="status_codes") + + +def _init(): + for code, titles in _codes.items(): + for title in titles: + setattr(codes, title, code) + if not title.startswith(("\\", "/")): + setattr(codes, title.upper(), code) + + def doc(code: int) -> str: + names = ", ".join(f"``{n}``" for n in _codes[code]) + return "* %d: %s" % (code, names) + + global __doc__ + __doc__ = ( + __doc__ + "\n" + "\n".join(doc(code) for code in sorted(_codes)) + if __doc__ is not None + else None + ) + + +_init() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/structures.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/structures.py new file mode 100644 index 0000000000000000000000000000000000000000..7675eaf15a181dada66c02bb0468dc00d6f523b3 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/structures.py @@ -0,0 +1,130 @@ +""" +requests.structures +~~~~~~~~~~~~~~~~~~~ + +Data structures that power Requests. +""" + +from __future__ import annotations + +from collections import OrderedDict +from collections.abc import Iterable, Iterator, Mapping +from typing import Any, Generic, TypeVar, overload + +from .compat import MutableMapping + +_VT = TypeVar("_VT") +_D = TypeVar("_D") + + +class CaseInsensitiveDict(MutableMapping[str, _VT], Generic[_VT]): + """A case-insensitive ``dict``-like object. + + Implements all methods and operations of + ``MutableMapping`` as well as dict's ``copy``. Also + provides ``lower_items``. + + All keys are expected to be strings. The structure remembers the + case of the last key to be set, and ``iter(instance)``, + ``keys()``, ``items()``, ``iterkeys()``, and ``iteritems()`` + will contain case-sensitive keys. However, querying and contains + testing is case insensitive:: + + cid = CaseInsensitiveDict() + cid['Accept'] = 'application/json' + cid['aCCEPT'] == 'application/json' # True + list(cid) == ['Accept'] # True + + For example, ``headers['content-encoding']`` will return the + value of a ``'Content-Encoding'`` response header, regardless + of how the header name was originally stored. + + If the constructor, ``.update``, or equality comparison + operations are given keys that have equal ``.lower()``s, the + behavior is undefined. + """ + + _store: OrderedDict[str, tuple[str, _VT]] + + def __init__( + self, + data: Mapping[str, _VT] | Iterable[tuple[str, _VT]] | None = None, + **kwargs: _VT, + ) -> None: + self._store = OrderedDict() + if data is None: + data = {} + self.update(data, **kwargs) + + def __setitem__(self, key: str, value: _VT) -> None: + # Use the lowercased key for lookups, but store the actual + # key alongside the value. + self._store[key.lower()] = (key, value) + + def __getitem__(self, key: str) -> _VT: + return self._store[key.lower()][1] + + def __delitem__(self, key: str) -> None: + del self._store[key.lower()] + + def __iter__(self) -> Iterator[str]: + return (casedkey for casedkey, _ in self._store.values()) + + def __len__(self) -> int: + return len(self._store) + + def lower_items(self) -> Iterator[tuple[str, _VT]]: + """Like iteritems(), but with all lowercase keys.""" + return ((lowerkey, keyval[1]) for (lowerkey, keyval) in self._store.items()) + + def __eq__(self, other: object) -> bool: + if isinstance(other, Mapping): + other_dict: CaseInsensitiveDict[Any] = CaseInsensitiveDict(other) # type: ignore[reportUnknownArgumentType] + else: + return NotImplemented + # Compare insensitively + return dict(self.lower_items()) == dict(other_dict.lower_items()) + + # Copy is required + def copy(self) -> CaseInsensitiveDict[_VT]: + return CaseInsensitiveDict(self._store.values()) + + def __repr__(self) -> str: + return str(dict(self.items())) + + +class LookupDict(dict[str, _VT]): + """Dictionary lookup object.""" + + name: Any + + def __init__(self, name: Any = None) -> None: + self.name = name + super().__init__() + + def __repr__(self) -> str: + return f"<lookup '{self.name}'>" + + def __getattr__(self, key: str) -> _VT | None: + # We need this for type checkers to infer typing + # on attribute access with status_codes.py + if key in self.__dict__: + return self.__dict__[key] + else: + raise AttributeError( + f"'{type(self).__name__}' object has no attribute '{key}'" + ) + + def __getitem__(self, key: str) -> _VT | None: # type: ignore[override] + # We allow fall-through here, so values default to None + + return self.__dict__.get(key, None) + + @overload + def get(self, key: str, default: None = None) -> _VT | None: ... + + @overload + def get(self, key: str, default: _D | _VT) -> _D | _VT: ... + + def get(self, key: str, default: _D | None = None) -> _VT | _D | None: + return self.__dict__.get(key, default) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/utils.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/utils.py new file mode 100644 index 0000000000000000000000000000000000000000..120336ddc6ed5d802735685349c3c3cd42e0c597 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/requests-2.34.0-pyhcf101f3_0/site-packages/requests/utils.py @@ -0,0 +1,1155 @@ +""" +requests.utils +~~~~~~~~~~~~~~ + +This module provides utility functions that are used within Requests +that are also useful for external consumption. +""" + +from __future__ import annotations + +import codecs +import contextlib +import io +import os +import re +import socket +import struct +import sys +import tempfile +import warnings +import zipfile +from collections import OrderedDict +from collections.abc import Generator, Iterable +from typing import ( + TYPE_CHECKING, + Any, + Final, + TypeVar, + cast, + overload, +) + +from urllib3.util import make_headers, parse_url + +from . import certs +from .__version__ import __version__ + +# to_native_string is unused here, but imported here for backwards compatibility +from ._internal_utils import ( # noqa: F401 + _HEADER_VALIDATORS_BYTE, # type: ignore[reportPrivateUsage] + _HEADER_VALIDATORS_STR, # type: ignore[reportPrivateUsage] + HEADER_VALIDATORS, # type: ignore[reportUnusedImport] + to_native_string, # type: ignore[reportUnusedImport] +) +from ._types import SupportsItems as _SupportsItems +from .compat import ( + Mapping, + bytes, + getproxies, + getproxies_environment, + integer_types, + is_urllib3_1, + proxy_bypass, + proxy_bypass_environment, # type: ignore[attr-defined] # https://github.com/python/cpython/issues/145331 + quote, + str, + unquote, + urlparse, + urlunparse, +) +from .compat import parse_http_list as _parse_list_header +from .cookies import cookiejar_from_dict +from .exceptions import ( + FileModeWarning, + InvalidHeader, + InvalidURL, + UnrewindableBodyError, +) +from .structures import CaseInsensitiveDict + +if TYPE_CHECKING: + from http.cookiejar import CookieJar + from io import BufferedWriter + + from . import _types as _t + from .models import PreparedRequest, Request, Response + +NETRC_FILES: Final = (".netrc", "_netrc") + + +# Certificate is extracted by certifi when needed. +DEFAULT_CA_BUNDLE_PATH: str = certs.where() + + +DEFAULT_PORTS: Final = {"http": 80, "https": 443} + +_KT = TypeVar("_KT") +_VT = TypeVar("_VT") + +# Ensure that ', ' is used to preserve previous delimiter behavior. +DEFAULT_ACCEPT_ENCODING: Final = ", ".join( + re.split(r",\s*", make_headers(accept_encoding=True)["accept-encoding"]) +) + + +if sys.platform == "win32": + # provide a proxy_bypass version on Windows without DNS lookups + + def proxy_bypass_registry(host: str) -> bool: + try: + import winreg + except ImportError: + return False + + try: + internetSettings = winreg.OpenKey( + winreg.HKEY_CURRENT_USER, + r"Software\Microsoft\Windows\CurrentVersion\Internet Settings", + ) + # ProxyEnable could be REG_SZ or REG_DWORD, normalizing it + proxyEnable = int(winreg.QueryValueEx(internetSettings, "ProxyEnable")[0]) + # ProxyOverride is almost always a string + proxyOverride = winreg.QueryValueEx(internetSettings, "ProxyOverride")[0] + except (OSError, ValueError): + return False + if not proxyEnable or not proxyOverride: + return False + + # make a check value list from the registry entry: replace the + # '<local>' string by the localhost entry and the corresponding + # canonical entry. + proxyOverride = proxyOverride.split(";") + # filter out empty strings to avoid re.match return true in the following code. + proxyOverride = filter(None, proxyOverride) + # now check if we match one of the registry values. + for test in proxyOverride: + if test == "<local>": + if "." not in host: + return True + test = test.replace(".", r"\.") # mask dots + test = test.replace("*", r".*") # change glob sequence + test = test.replace("?", r".") # change glob char + if re.match(test, host, re.I): + return True + return False + + def proxy_bypass(host: str) -> bool: # noqa + """Return True, if the host should be bypassed. + + Checks proxy settings gathered from the environment, if specified, + or the registry. + """ + if getproxies_environment(): + return proxy_bypass_environment(host) + else: + return proxy_bypass_registry(host) + + +def dict_to_sequence( + d: _t.SupportsItems[Any, Any] | Iterable[tuple[Any, Any]], +) -> Iterable[tuple[Any, Any]]: + """Returns an internal sequence dictionary update.""" + + if isinstance(d, _SupportsItems): + return d.items() + + return d + + +def super_len(o: Any) -> int: + total_length = None + current_position = 0 + + if not is_urllib3_1 and isinstance(o, str): + # urllib3 2.x+ treats all strings as utf-8 instead + # of latin-1 (iso-8859-1) like http.client. + o = o.encode("utf-8") + + if hasattr(o, "__len__"): + total_length = len(o) + + elif hasattr(o, "len"): + total_length = o.len + + elif hasattr(o, "fileno"): + try: + fileno = o.fileno() + except (io.UnsupportedOperation, AttributeError): + # AttributeError is a surprising exception, seeing as how we've just checked + # that `hasattr(o, 'fileno')`. It happens for objects obtained via + # `Tarfile.extractfile()`, per issue 5229. + pass + else: + total_length = os.fstat(fileno).st_size + + # Having used fstat to determine the file length, we need to + # confirm that this file was opened up in binary mode. + if "b" not in o.mode: + warnings.warn( + ( + "Requests has determined the content-length for this " + "request using the binary size of the file: however, the " + "file has been opened in text mode (i.e. without the 'b' " + "flag in the mode). This may lead to an incorrect " + "content-length. In Requests 3.0, support will be removed " + "for files in text mode." + ), + FileModeWarning, + ) + + if hasattr(o, "tell"): + try: + current_position = o.tell() + except OSError: + # This can happen in some weird situations, such as when the file + # is actually a special file descriptor like stdin. In this + # instance, we don't know what the length is, so set it to zero and + # let requests chunk it instead. + if total_length is not None: + current_position = total_length + else: + if hasattr(o, "seek") and total_length is None: + # StringIO and BytesIO have seek but no usable fileno + try: + # seek to end of file + o.seek(0, 2) + total_length = o.tell() + + # seek back to current position to support + # partially read file-like objects + o.seek(current_position or 0) + except OSError: + total_length = 0 + + if total_length is None: + total_length = 0 + + return max(0, total_length - current_position) + + +def get_netrc_auth( + url: _t.UriType, raise_errors: bool = False +) -> tuple[str, str] | None: + """Returns the Requests tuple auth for a given url from netrc.""" + + if isinstance(url, bytes): + url = url.decode("utf-8") + + netrc_file = os.environ.get("NETRC") + if netrc_file is not None: + netrc_locations = (netrc_file,) + else: + netrc_locations = (f"~/{f}" for f in NETRC_FILES) + + try: + from netrc import NetrcParseError, netrc + + netrc_path = None + + for f in netrc_locations: + loc = os.path.expanduser(f) + if os.path.exists(loc): + netrc_path = loc + break + + # Abort early if there isn't one. + if netrc_path is None: + return + + ri = urlparse(url) + host = ri.hostname + + if host is None: + return + + try: + _netrc = netrc(netrc_path).authenticators(host) + if _netrc and any(_netrc): + # Return with login / password + login_i = 0 if _netrc[0] else 1 + return (_netrc[login_i] or "", _netrc[2] or "") + except (NetrcParseError, OSError): + # If there was a parsing error or a permissions issue reading the file, + # we'll just skip netrc auth unless explicitly asked to raise errors. + if raise_errors: + raise + + # App Engine hackiness. + except (ImportError, AttributeError): + pass + + +def guess_filename(obj: Any) -> str | None: + """Tries to guess the filename of the given object.""" + name = getattr(obj, "name", None) + if name and isinstance(name, (str, bytes)) and name[0] != "<" and name[-1] != ">": + return os.path.basename(name) # type: ignore[return-value] # urllib3 accepts bytes but types str only + + +def extract_zipped_paths(path: str) -> str: + """Replace nonexistent paths that look like they refer to a member of a zip + archive with the location of an extracted copy of the target, or else + just return the provided path unchanged. + """ + if os.path.exists(path): + # this is already a valid path, no need to do anything further + return path + + # find the first valid part of the provided path and treat that as a zip archive + # assume the rest of the path is the name of a member in the archive + archive, member = os.path.split(path) + while archive and not os.path.exists(archive): + archive, prefix = os.path.split(archive) + if not prefix: + # If we don't check for an empty prefix after the split (in other words, archive remains unchanged after the split), + # we _can_ end up in an infinite loop on a rare corner case affecting a small number of users + break + member = "/".join([prefix, member]) + + if not zipfile.is_zipfile(archive): + return path + + zip_file = zipfile.ZipFile(archive) + if member not in zip_file.namelist(): + return path + + # we have a valid zip archive and a valid member of that archive + suffix = os.path.splitext(member.split("/")[-1])[-1] + fd, extracted_path = tempfile.mkstemp(suffix=suffix) + try: + os.write(fd, zip_file.read(member)) + finally: + os.close(fd) + + return extracted_path + + +@contextlib.contextmanager +def atomic_open(filename: str) -> Generator[BufferedWriter, None, None]: + """Write a file to the disk in an atomic fashion""" + tmp_descriptor, tmp_name = tempfile.mkstemp(dir=os.path.dirname(filename)) + try: + with os.fdopen(tmp_descriptor, "wb") as tmp_handler: + yield tmp_handler + os.replace(tmp_name, filename) + except BaseException: + os.remove(tmp_name) + raise + + +def from_key_val_list( + value: Mapping[Any, Any] | Iterable[tuple[Any, Any]] | None, +) -> dict[Any, Any] | None: + """Take an object and test to see if it can be represented as a + dictionary. Unless it can not be represented as such, return an + OrderedDict, e.g., + + :: + + >>> from_key_val_list([('key', 'val')]) + OrderedDict([('key', 'val')]) + >>> from_key_val_list('string') + Traceback (most recent call last): + ... + ValueError: cannot encode objects that are not 2-tuples + >>> from_key_val_list({'key': 'val'}) + OrderedDict([('key', 'val')]) + + :rtype: OrderedDict + """ + if value is None: + return None + + if isinstance(value, (str, bytes, bool, int)): + raise ValueError("cannot encode objects that are not 2-tuples") + + return OrderedDict(value) + + +@overload +def to_key_val_list(value: None) -> None: ... +@overload +def to_key_val_list( + value: _t.SupportsItems[_KT, _VT] | Iterable[tuple[_KT, _VT]], +) -> list[tuple[_KT, _VT]]: ... +def to_key_val_list( + value: _t.SupportsItems[_KT, _VT] | Iterable[tuple[_KT, _VT]] | None, +) -> list[tuple[_KT, _VT]] | None: + """Take an object and test to see if it can be represented as a + dictionary. If it can be, return a list of tuples, e.g., + + :: + + >>> to_key_val_list([('key', 'val')]) + [('key', 'val')] + >>> to_key_val_list({'key': 'val'}) + [('key', 'val')] + >>> to_key_val_list('string') + Traceback (most recent call last): + ... + ValueError: cannot encode objects that are not 2-tuples + + :rtype: list + """ + if value is None: + return None + + if isinstance(value, (str, bytes, bool, int)): + raise ValueError("cannot encode objects that are not 2-tuples") + + if isinstance(value, _SupportsItems): + return list(value.items()) + + return list(value) + + +# From mitsuhiko/werkzeug (used with permission). +def parse_list_header(value: str) -> list[str]: + """Parse lists as described by RFC 2068 Section 2. + + In particular, parse comma-separated lists where the elements of + the list may include quoted-strings. A quoted-string could + contain a comma. A non-quoted string could have quotes in the + middle. Quotes are removed automatically after parsing. + + It basically works like :func:`parse_set_header` just that items + may appear multiple times and case sensitivity is preserved. + + The return value is a standard :class:`list`: + + >>> parse_list_header('token, "quoted value"') + ['token', 'quoted value'] + + To create a header from the :class:`list` again, use the + :func:`dump_header` function. + + :param value: a string with a list header. + :return: :class:`list` + :rtype: list + """ + result: list[str] = [] + for item in _parse_list_header(value): + if item[:1] == item[-1:] == '"': + item = unquote_header_value(item[1:-1]) + result.append(item) + return result + + +# From mitsuhiko/werkzeug (used with permission). +def parse_dict_header(value: str) -> dict[str, str | None]: + """Parse lists of key, value pairs as described by RFC 2068 Section 2 and + convert them into a python dict: + + >>> d = parse_dict_header('foo="is a fish", bar="as well"') + >>> type(d) is dict + True + >>> sorted(d.items()) + [('bar', 'as well'), ('foo', 'is a fish')] + + If there is no value for a key it will be `None`: + + >>> parse_dict_header('key_without_value') + {'key_without_value': None} + + To create a header from the :class:`dict` again, use the + :func:`dump_header` function. + + :param value: a string with a dict header. + :return: :class:`dict` + :rtype: dict + """ + result: dict[str, str | None] = {} + for item in _parse_list_header(value): + if "=" not in item: + result[item] = None + continue + name, value = item.split("=", 1) + if value[:1] == value[-1:] == '"': + value = unquote_header_value(value[1:-1]) + result[name] = value + return result + + +# From mitsuhiko/werkzeug (used with permission). +def unquote_header_value(value: str, is_filename: bool = False) -> str: + r"""Unquotes a header value. (Reversal of :func:`quote_header_value`). + This does not use the real unquoting but what browsers are actually + using for quoting. + + :param value: the header value to unquote. + :rtype: str + """ + if value and value[0] == value[-1] == '"': + # this is not the real unquoting, but fixing this so that the + # RFC is met will result in bugs with internet explorer and + # probably some other browsers as well. IE for example is + # uploading files with "C:\foo\bar.txt" as filename + value = value[1:-1] + + # if this is a filename and the starting characters look like + # a UNC path, then just return the value without quotes. Using the + # replace sequence below on a UNC path has the effect of turning + # the leading double slash into a single slash and then + # _fix_ie_filename() doesn't work correctly. See #458. + if not is_filename or value[:2] != "\\\\": + return value.replace("\\\\", "\\").replace('\\"', '"') + return value + + +def dict_from_cookiejar(cj: CookieJar) -> dict[str, str | None]: + """Returns a key/value dictionary from a CookieJar. + + :param cj: CookieJar object to extract cookies from. + :rtype: dict + """ + + cookie_dict = {cookie.name: cookie.value for cookie in cj} + return cookie_dict + + +def add_dict_to_cookiejar(cj: CookieJar, cookie_dict: dict[str, str]) -> CookieJar: + """Returns a CookieJar from a key/value dictionary. + + :param cj: CookieJar to insert cookies into. + :param cookie_dict: Dict of key/values to insert into CookieJar. + :rtype: CookieJar + """ + + return cookiejar_from_dict(cookie_dict, cj) + + +def get_encodings_from_content(content: str) -> list[str]: + """Returns encodings from given content string. + + :param content: bytestring to extract encodings from. + """ + warnings.warn( + ( + "In requests 3.0, get_encodings_from_content will be removed. For " + "more information, please see the discussion on issue #2266. (This" + " warning should only appear once.)" + ), + DeprecationWarning, + ) + + charset_re = re.compile(r'<meta.*?charset=["\']*(.+?)["\'>]', flags=re.I) + pragma_re = re.compile(r'<meta.*?content=["\']*;?charset=(.+?)["\'>]', flags=re.I) + xml_re = re.compile(r'^<\?xml.*?encoding=["\']*(.+?)["\'>]') + + return ( + charset_re.findall(content) + + pragma_re.findall(content) + + xml_re.findall(content) + ) + + +def _parse_content_type_header(header: str) -> tuple[str, dict[str, Any]]: + """Returns content type and parameters from given header. + + :param header: string + :return: tuple containing content type and dictionary of + parameters. + """ + + tokens = header.split(";") + content_type, params = tokens[0].strip(), tokens[1:] + params_dict: dict[str, str | bool] = {} + strip_chars = "\"' " + + for param in params: + param = param.strip() + if param and (idx := param.find("=")) != -1: + key = param[:idx].strip(strip_chars) + value = param[idx + 1 :].strip(strip_chars) + params_dict[key.lower()] = value + return content_type, params_dict + + +def get_encoding_from_headers(headers: CaseInsensitiveDict[str]) -> str | None: + """Returns encodings from given HTTP Header Dict. + + :param headers: dictionary to extract encoding from. + :rtype: str + """ + + content_type = headers.get("content-type") + + if not content_type: + return None + + content_type, params = _parse_content_type_header(content_type) + + if "charset" in params: + return params["charset"].strip("'\"") + + if "text" in content_type: + return "ISO-8859-1" + + if "application/json" in content_type: + # Assume UTF-8 based on RFC 4627: https://www.ietf.org/rfc/rfc4627.txt since the charset was unset + return "utf-8" + + +def stream_decode_response_unicode( + iterator: Iterable[bytes], r: Response +) -> Generator[str | bytes, None, None]: + """Stream decodes an iterator.""" + + if r.encoding is None: + yield from iterator + return + + decoder = codecs.getincrementaldecoder(r.encoding)(errors="replace") + for chunk in iterator: + rv = decoder.decode(chunk) + if rv: + yield rv + rv = decoder.decode(b"", final=True) + if rv: + yield rv + + +@overload +def iter_slices( + string: bytes, slice_length: int | None +) -> Generator[bytes, None, None]: ... +@overload +def iter_slices( + string: str, slice_length: int | None +) -> Generator[str, None, None]: ... +def iter_slices( + string: bytes | str, slice_length: int | None +) -> Generator[bytes | str, None, None]: + """Iterate over slices of a string.""" + pos = 0 + if slice_length is None or slice_length <= 0: + slice_length = len(string) + while pos < len(string): + yield string[pos : pos + slice_length] + pos += slice_length + + +def get_unicode_from_response(r: Response) -> str | bytes | None: + """Returns the requested content back in unicode. + + :param r: Response object to get unicode content from. + + Tried: + + 1. charset from content-type + 2. fall back and replace all unicode characters + + :rtype: str + """ + warnings.warn( + ( + "In requests 3.0, get_unicode_from_response will be removed. For " + "more information, please see the discussion on issue #2266. (This" + " warning should only appear once.)" + ), + DeprecationWarning, + ) + if r.content is None: # type: ignore[reportUnnecessaryComparison] + return None + + tried_encodings: list[str] = [] + + # Try charset from content-type + encoding = get_encoding_from_headers(r.headers) + + if encoding: + try: + return str(r.content, encoding) + except UnicodeError: + tried_encodings.append(encoding) + + # Fall back: + try: + return str(r.content, encoding or "utf-8", errors="replace") + except TypeError: + return r.content + + +# The unreserved URI characters (RFC 3986) +UNRESERVED_SET: Final = frozenset( + "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz" + "0123456789-._~" +) + + +def unquote_unreserved(uri: str) -> str: + """Un-escape any percent-escape sequences in a URI that are unreserved + characters. This leaves all reserved, illegal and non-ASCII bytes encoded. + + :rtype: str + """ + parts = uri.split("%") + for i in range(1, len(parts)): + h = parts[i][0:2] + if len(h) == 2 and h.isalnum(): + try: + c = chr(int(h, 16)) + except ValueError: + raise InvalidURL(f"Invalid percent-escape sequence: '{h}'") + + if c in UNRESERVED_SET: + parts[i] = c + parts[i][2:] + else: + parts[i] = f"%{parts[i]}" + else: + parts[i] = f"%{parts[i]}" + return "".join(parts) + + +def requote_uri(uri: str) -> str: + """Re-quote the given URI. + + This function passes the given URI through an unquote/quote cycle to + ensure that it is fully and consistently quoted. + + :rtype: str + """ + safe_with_percent = "!#$%&'()*+,/:;=?@[]~" + safe_without_percent = "!#$&'()*+,/:;=?@[]~" + try: + # Unquote only the unreserved characters + # Then quote only illegal characters (do not quote reserved, + # unreserved, or '%') + return quote(unquote_unreserved(uri), safe=safe_with_percent) + except InvalidURL: + # We couldn't unquote the given URI, so let's try quoting it, but + # there may be unquoted '%'s in the URI. We need to make sure they're + # properly quoted so they do not cause issues elsewhere. + return quote(uri, safe=safe_without_percent) + + +def address_in_network(ip: str, net: str) -> bool: + """This function allows you to check if an IP belongs to a network subnet + + Example: returns True if ip = 192.168.1.1 and net = 192.168.1.0/24 + returns False if ip = 192.168.1.1 and net = 192.168.100.0/24 + + :rtype: bool + """ + ipaddr = struct.unpack("=L", socket.inet_aton(ip))[0] + netaddr, bits = net.split("/") + netmask = struct.unpack("=L", socket.inet_aton(dotted_netmask(int(bits))))[0] + network = struct.unpack("=L", socket.inet_aton(netaddr))[0] & netmask + return (ipaddr & netmask) == (network & netmask) + + +def dotted_netmask(mask: int) -> str: + """Converts mask from /xx format to xxx.xxx.xxx.xxx + + Example: if mask is 24 function returns 255.255.255.0 + + :rtype: str + """ + bits = 0xFFFFFFFF ^ (1 << 32 - mask) - 1 + return socket.inet_ntoa(struct.pack(">I", bits)) + + +def is_ipv4_address(string_ip: str) -> bool: + """ + :rtype: bool + """ + try: + socket.inet_aton(string_ip) + except OSError: + return False + return True + + +def is_valid_cidr(string_network: str) -> bool: + """ + Very simple check of the cidr format in no_proxy variable. + + :rtype: bool + """ + if string_network.count("/") == 1: + try: + mask = int(string_network.split("/")[1]) + except ValueError: + return False + + if mask < 1 or mask > 32: + return False + + try: + socket.inet_aton(string_network.split("/")[0]) + except OSError: + return False + else: + return False + return True + + +@contextlib.contextmanager +def set_environ(env_name: str, value: str | None) -> Generator[None, None, None]: + """Set the environment variable 'env_name' to 'value' + + Save previous value, yield, and then restore the previous value stored in + the environment variable 'env_name'. + + If 'value' is None, do nothing""" + value_changed = value is not None + old_value: str | None = None + if value_changed: + old_value = os.environ.get(env_name) + os.environ[env_name] = value + try: + yield + finally: + if value_changed: + if old_value is None: + del os.environ[env_name] + else: + os.environ[env_name] = old_value + + +def should_bypass_proxies(url: str, no_proxy: str | None) -> bool: + """ + Returns whether we should bypass proxies or not. + + :rtype: bool + """ + + # Prioritize lowercase environment variables over uppercase + # to keep a consistent behaviour with other http projects (curl, wget). + def get_proxy(key: str) -> str | None: + return os.environ.get(key) or os.environ.get(key.upper()) + + # First check whether no_proxy is defined. If it is, check that the URL + # we're getting isn't in the no_proxy list. + no_proxy_arg = no_proxy + if no_proxy is None: + no_proxy = get_proxy("no_proxy") + parsed = urlparse(url) + hostname = parsed.hostname + + if hostname is None: + # URLs don't always have hostnames, e.g. file:/// urls. + return True + + if no_proxy: + # We need to check whether we match here. We need to see if we match + # the end of the hostname, both with and without the port. + no_proxy_hosts = (host for host in no_proxy.replace(" ", "").split(",") if host) + + if is_ipv4_address(hostname): + for proxy_ip in no_proxy_hosts: + if is_valid_cidr(proxy_ip): + if address_in_network(hostname, proxy_ip): + return True + elif hostname == proxy_ip: + # If no_proxy ip was defined in plain IP notation instead of cidr notation & + # matches the IP of the index + return True + else: + host_with_port = hostname + if parsed.port: + host_with_port += f":{parsed.port}" + + for host in no_proxy_hosts: + host = host.lstrip(".") + if hostname == host or host_with_port == host: + return True + host = "." + host + if hostname.endswith(host) or host_with_port.endswith(host): + return True + + with set_environ("no_proxy", no_proxy_arg): + try: + bypass = proxy_bypass(hostname) + except (TypeError, socket.gaierror): + bypass = False + + if bypass: + return True + + return False + + +def get_environ_proxies(url: str, no_proxy: str | None = None) -> dict[str, str]: + """ + Return a dict of environment proxies. + + :rtype: dict + """ + if should_bypass_proxies(url, no_proxy=no_proxy): + return {} + else: + return getproxies() + + +def select_proxy(url: str, proxies: dict[str, str] | None) -> str | None: + """Select a proxy for the url, if applicable. + + :param url: The url being for the request + :param proxies: A dictionary of schemes or schemes and hosts to proxy URLs + """ + proxies = proxies or {} + urlparts = urlparse(url) + if urlparts.hostname is None: + return proxies.get(urlparts.scheme, proxies.get("all")) + + proxy_keys = [ + urlparts.scheme + "://" + urlparts.hostname, + urlparts.scheme, + "all://" + urlparts.hostname, + "all", + ] + proxy = None + for proxy_key in proxy_keys: + if proxy_key in proxies: + proxy = proxies[proxy_key] + break + + return proxy + + +def resolve_proxies( + request: Request | PreparedRequest, + proxies: dict[str, str] | None, + trust_env: bool = True, +) -> dict[str, str]: + """This method takes proxy information from a request and configuration + input to resolve a mapping of target proxies. This will consider settings + such as NO_PROXY to strip proxy configurations. + + :param request: Request or PreparedRequest + :param proxies: A dictionary of schemes or schemes and hosts to proxy URLs + :param trust_env: Boolean declaring whether to trust environment configs + + :rtype: dict + """ + proxies = proxies if proxies is not None else {} + url = cast(str, request.url) + scheme = urlparse(url).scheme + no_proxy = proxies.get("no_proxy") + new_proxies = proxies.copy() + + if trust_env and not should_bypass_proxies(url, no_proxy=no_proxy): + environ_proxies = get_environ_proxies(url, no_proxy=no_proxy) + + proxy = environ_proxies.get(scheme, environ_proxies.get("all")) + + if proxy: + new_proxies.setdefault(scheme, proxy) + return new_proxies + + +def default_user_agent(name: str = "python-requests") -> str: + """ + Return a string representing the default user agent. + + :rtype: str + """ + return f"{name}/{__version__}" + + +def default_headers() -> CaseInsensitiveDict[str]: + """ + :rtype: requests.structures.CaseInsensitiveDict + """ + return CaseInsensitiveDict( + { + "User-Agent": default_user_agent(), + "Accept-Encoding": DEFAULT_ACCEPT_ENCODING, + "Accept": "*/*", + "Connection": "keep-alive", + } + ) + + +def parse_header_links(value: str) -> list[dict[str, str]]: + """Return a list of parsed link headers proxies. + + i.e. Link: <http:/.../front.jpeg>; rel=front; type="image/jpeg",<http://.../back.jpeg>; rel=back;type="image/jpeg" + + :rtype: list + """ + + links: list[dict[str, str]] = [] + + replace_chars = " '\"" + + value = value.strip(replace_chars) + if not value: + return links + + for val in re.split(", *<", value): + try: + url, params = val.split(";", 1) + except ValueError: + url, params = val, "" + + link: dict[str, str] = {"url": url.strip("<> '\"")} + + for param in params.split(";"): + try: + key, value = param.split("=") + except ValueError: + break + + link[key.strip(replace_chars)] = value.strip(replace_chars) + + links.append(link) + + return links + + +# Null bytes; no need to recreate these on each call to guess_json_utf +_null = "\x00".encode("ascii") # encoding to ASCII for Python 3 +_null2 = _null * 2 +_null3 = _null * 3 + + +def guess_json_utf(data: bytes) -> str | None: + """ + :rtype: str + """ + # JSON always starts with two ASCII characters, so detection is as + # easy as counting the nulls and from their location and count + # determine the encoding. Also detect a BOM, if present. + sample = data[:4] + if sample in (codecs.BOM_UTF32_LE, codecs.BOM_UTF32_BE): + return "utf-32" # BOM included + if sample[:3] == codecs.BOM_UTF8: + return "utf-8-sig" # BOM included, MS style (discouraged) + if sample[:2] in (codecs.BOM_UTF16_LE, codecs.BOM_UTF16_BE): + return "utf-16" # BOM included + nullcount = sample.count(_null) + if nullcount == 0: + return "utf-8" + if nullcount == 2: + if sample[::2] == _null2: # 1st and 3rd are null + return "utf-16-be" + if sample[1::2] == _null2: # 2nd and 4th are null + return "utf-16-le" + # Did not detect 2 valid UTF-16 ascii-range characters + if nullcount == 3: + if sample[:3] == _null3: + return "utf-32-be" + if sample[1:] == _null3: + return "utf-32-le" + # Did not detect a valid UTF-32 ascii-range character + return None + + +def prepend_scheme_if_needed(url: str, new_scheme: str) -> str: + """Given a URL that may or may not have a scheme, prepend the given scheme. + Does not replace a present scheme with the one provided as an argument. + + :rtype: str + """ + parsed = parse_url(url) + scheme, auth, _host, _port, path, query, fragment = parsed + + # A defect in urlparse determines that there isn't a netloc present in some + # urls. We previously assumed parsing was overly cautious, and swapped the + # netloc and path. Due to a lack of tests on the original defect, this is + # maintained with parse_url for backwards compatibility. + netloc = parsed.netloc + if not netloc: + netloc, path = path, netloc + + if auth: + # parse_url doesn't provide the netloc with auth + # so we'll add it ourselves. + netloc = cast(str, netloc) + netloc = "@".join([auth, netloc]) + if scheme is None: + scheme = new_scheme + if path is None: + path = "" + + return urlunparse((scheme, netloc, path, "", query, fragment)) + + +def get_auth_from_url(url: str) -> tuple[str, str]: + """Given a url with authentication components, extract them into a tuple of + username,password. + + :rtype: (str,str) + """ + parsed = urlparse(url) + + try: + # except handles parsed.username/password being None + auth = (unquote(parsed.username), unquote(parsed.password)) # type: ignore[arg-type] + except (AttributeError, TypeError): + auth = ("", "") + + return auth + + +def check_header_validity(header: tuple[str | bytes, str | bytes]) -> None: + """Verifies that header parts don't contain leading whitespace + reserved characters, or return characters. + + :param header: tuple, in the format (name, value). + """ + name, value = header + _validate_header_part(header, name, 0) + _validate_header_part(header, value, 1) + + +def _validate_header_part( + header: tuple[str | bytes, str | bytes], + header_part: str | bytes, + header_validator_index: int, +) -> None: + if isinstance(header_part, str): + validator = _HEADER_VALIDATORS_STR[header_validator_index] + elif isinstance(header_part, bytes): # type: ignore[reportUnnecessaryIsInstance] + # runtime guard for non-str/bytes input + validator = _HEADER_VALIDATORS_BYTE[header_validator_index] + else: + raise InvalidHeader( + f"Header part ({header_part!r}) from {header} " + f"must be of type str or bytes, not {type(header_part)}" + ) + + if not validator.match(header_part): # type: ignore[arg-type] + header_kind = "name" if header_validator_index == 0 else "value" + raise InvalidHeader( + f"Invalid leading whitespace, reserved character(s), or return " + f"character(s) in header {header_kind}: {header_part!r}" + ) + + +def urldefragauth(url: str) -> str: + """ + Given a url remove the fragment and the authentication part. + + :rtype: str + """ + scheme, netloc, path, params, query, _fragment = urlparse(url) + + # see func:`prepend_scheme_if_needed` + if not netloc: + netloc, path = path, netloc + + netloc = netloc.rsplit("@", 1)[-1] + + return urlunparse((scheme, netloc, path, params, query, "")) + + +def rewind_body(prepared_request: PreparedRequest) -> None: + """Move file pointer back to its recorded starting position + so it can be read again on redirect. + """ + body_seek = getattr(prepared_request.body, "seek", None) + if body_seek is not None and isinstance( + prepared_request._body_position, # type: ignore[reportPrivateUsage] + integer_types, + ): + try: + body_seek(prepared_request._body_position) # type: ignore[reportPrivateUsage] + except OSError: + raise UnrewindableBodyError( + "An error occurred when rewinding request body for redirect." + ) + else: + raise UnrewindableBodyError("Unable to rewind request body for redirect.") diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..1bb5a44356f00884a71ceeefd24ded6caaba2418 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/licenses/LICENSE @@ -0,0 +1,17 @@ +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to +deal in the Software without restriction, including without limitation the +rights to use, copy, modify, merge, publish, distribute, sublicense, and/or +sell copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS +IN THE SOFTWARE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/bld.bat b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/bld.bat new file mode 100644 index 0000000000000000000000000000000000000000..eb97b5f6b32ed6da2e4c9ac62afbf603ae125272 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/bld.bat @@ -0,0 +1,6 @@ +set SETUPTOOLS_INSTALL_WINDOWS_SPECIFIC_FILES=0 +set SETUPTOOLS_DISABLE_VERSIONED_EASY_INSTALL_SCRIPT=1 +set DISTRIBUTE_DISABLE_VERSIONED_EASY_INSTALL_SCRIPT=1 + +%PYTHON% setup.py install --single-version-externally-managed --record=record.txt +if errorlevel 1 exit 1 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/build.sh b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/build.sh new file mode 100644 index 0000000000000000000000000000000000000000..6bd3a0ab60c8a5759b699c6f5947d7560787f4f8 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/build.sh @@ -0,0 +1,6 @@ +#!/bin/bash + +export SETUPTOOLS_DISABLE_VERSIONED_EASY_INSTALL_SCRIPT=1 +export DISTRIBUTE_DISABLE_VERSIONED_EASY_INSTALL_SCRIPT=1 + +$PYTHON setup.py install --single-version-externally-managed --record=record.txt diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/conda_build_config.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/conda_build_config.yaml new file mode 100644 index 0000000000000000000000000000000000000000..8e9c67f87c2db89df44b5d210601a26c15952852 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/conda_build_config.yaml @@ -0,0 +1,31 @@ +CI: azure +c_compiler: gcc +channel_sources: conda-forge +channel_targets: conda-forge main +cpu_optimization_target: nocona +cran_mirror: https://cran.r-project.org +cxx_compiler: gxx +docker_image: quay.io/condaforge/linux-anvil-x86_64:alma9 +extend_keys: +- ignore_version +- extend_keys +- ignore_build_only_deps +- pin_run_as_build +fortran_compiler: gfortran +ignore_build_only_deps: +- python +- numpy +lua: '5' +numpy: '1.26' +perl: 5.26.2 +pin_run_as_build: + python: + max_pin: x.x + min_pin: x.x + r-base: + max_pin: x.x + min_pin: x.x +python: 3.13.* *_cp313 +python_min: '3.10' +r_base: '3.5' +target_platform: linux-64 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/meta.yaml b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/meta.yaml new file mode 100644 index 0000000000000000000000000000000000000000..36b3a4e7b383dc99cdca858c12e64f15e43b6c3d --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/meta.yaml @@ -0,0 +1,78 @@ +# This file created by conda-build 26.1.0 +# meta.yaml template originally from: +# /home/conda/recipe_root, last modified Mon Mar 9 16:44:51 2026 +# ------------------------------------------------ + +package: + name: setuptools + version: 82.0.1 +source: + url: https://pypi.org/packages/source/s/setuptools/setuptools-82.0.1.tar.gz + sha256: 7d872682c5d01cfde07da7bccc7b65469d3dca203318515ada1de5eda35efbf9 + patches: + - patches/0021-Add-d1trimfile-SRC_DIR-to-make-pdbs-more-relocatable.patch +build: + number: '0' + noarch: python + string: pyh332efcf_0 +requirements: + host: + - _openmp_mutex 4.5 20_gnu + - bzip2 1.0.8 hda65f42_9 + - ca-certificates 2026.2.25 hbd8a1cb_0 + - icu 78.2 h33c6efd_0 + - ld_impl_linux-64 2.45.1 default_hbd61a6d_101 + - libexpat 2.7.4 hecca717_0 + - libffi 3.5.2 h3435931_0 + - libgcc 15.2.0 he0feb66_18 + - libgcc-ng 15.2.0 h69a702a_18 + - libgomp 15.2.0 he0feb66_18 + - liblzma 5.8.2 hb03c661_0 + - libnsl 2.0.1 hb9d3cd8_1 + - libsqlite 3.52.0 hf4e2dac_0 + - libstdcxx 15.2.0 h934c35e_18 + - libuuid 2.41.3 h5347b49_0 + - libxcrypt 4.4.36 hd590300_1 + - libzlib 1.3.1 hb9d3cd8_2 + - ncurses 6.5 h2d0b736_3 + - openssl 3.6.1 h35e630c_1 + - python 3.10.20 h3c07f61_0_cpython + - readline 8.3 h853b02a_0 + - tk 8.6.13 noxft_h366c992_103 + - tzdata 2025c hc9c84f9_1 + - zstd 1.5.7 hb78ec9c_6 + run: + - python >=3.10 +test: + requires: + - python + imports: + - setuptools +about: + home: https://github.com/pypa/setuptools + license: MIT + license_file: LICENSE + license_family: MIT + summary: Download, build, install, upgrade, and uninstall Python packages + description: 'Setuptools is a fully-featured, actively-maintained, and stable library + + designed to facilitate packaging Python projects. + + ' + doc_url: http://pythonhosted.org/setuptools/ + dev_url: https://github.com/pypa/setuptools + doc_source_url: https://github.com/pypa/setuptools/tree/master/docs +extra: + recipe-maintainers: + - isuruf + - jakirkham + - msarahan + - nicoddemus + - ocefpaf + - rgommers + - xhochy + final: true + copy_test_source_files: true + flow_run_id: azure_20260309.2.1 + remote_url: https://github.com/conda-forge/setuptools-feedstock + sha: f5d57673366c72887df498499e979b688f5eb6aa diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/meta.yaml.template b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/meta.yaml.template new file mode 100644 index 0000000000000000000000000000000000000000..7464242caf4e2dd30b96f4bad6f28552e23610ce --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/meta.yaml.template @@ -0,0 +1,56 @@ +{% set version = "82.0.1" %} + + +package: + name: setuptools + version: {{ version }} + +source: + url: https://pypi.org/packages/source/s/setuptools/setuptools-{{ version }}.tar.gz + sha256: 7d872682c5d01cfde07da7bccc7b65469d3dca203318515ada1de5eda35efbf9 + patches: + # distutils patches from python-feedstock + - patches/0021-Add-d1trimfile-SRC_DIR-to-make-pdbs-more-relocatable.patch + +build: + number: 0 + noarch: python + +requirements: + host: + - python {{ python_min }} + run: + - python >={{ python_min }} + +test: + requires: + # The linter will complain about the missing python_min, but we need + # this unpinned to allow setuptools to be used in the downstream tests + # of the python-feedstock. + # See also https://github.com/conda-forge/conda-forge.github.io/pull/2387 + - python + imports: + - setuptools + +about: + home: https://github.com/pypa/setuptools + license: MIT + license_file: LICENSE + license_family: MIT + summary: Download, build, install, upgrade, and uninstall Python packages + description: | + Setuptools is a fully-featured, actively-maintained, and stable library + designed to facilitate packaging Python projects. + doc_url: http://pythonhosted.org/setuptools/ + dev_url: https://github.com/pypa/setuptools + doc_source_url: https://github.com/pypa/setuptools/tree/master/docs + +extra: + recipe-maintainers: + - xhochy + - rgommers + - jakirkham + - msarahan + - ocefpaf + - nicoddemus + - isuruf diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/patches/0021-Add-d1trimfile-SRC_DIR-to-make-pdbs-more-relocatable.patch b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/patches/0021-Add-d1trimfile-SRC_DIR-to-make-pdbs-more-relocatable.patch new file mode 100644 index 0000000000000000000000000000000000000000..67a67bc2d076803b74ed55dddbb5a382e76d44dc --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/patches/0021-Add-d1trimfile-SRC_DIR-to-make-pdbs-more-relocatable.patch @@ -0,0 +1,41 @@ +From e19fc817312a0a053f0c23aaffffcd068df0f113 Mon Sep 17 00:00:00 2001 +From: Ray Donnelly <mingw.android@gmail.com> +Date: Tue, 31 Dec 2019 20:46:36 +0100 +Subject: [PATCH] Add /d1trimfile:%SRC_DIR% to make pdbs more relocatable + +Co-authored-by: Uwe L. Korn <mail@uwekorn.com> +--- + setuptools/_distutils/compilers/C/msvc.py | 10 +++++++++- + 1 file changed, 9 insertions(+), 1 deletion(-) + +diff --git a/setuptools/_distutils/compilers/C/msvc.py b/setuptools/_distutils/compilers/C/msvc.py +index 795a47f..a44a370 100644 +--- a/setuptools/_distutils/compilers/C/msvc.py ++++ b/setuptools/_distutils/compilers/C/msvc.py +@@ -407,6 +407,14 @@ class Compiler(base.Compiler): + # without asking the user to browse for it + src = os.path.abspath(src) + ++ # Anaconda/conda-forge customisation, we want our pdbs to be ++ # relocatable: ++ # https://developercommunity.visualstudio.com/comments/623156/view.html ++ d1trimfile_opts = [] ++ if 'SRC_DIR' in os.environ and os.path.basename(self.cc) == "cl.exe": ++ d1trimfile_opts.append("/d1trimfile:" + os.environ['SRC_DIR']) ++ ++ + if ext in self._c_extensions: + input_opt = f"/Tc{src}" + elif ext in self._cpp_extensions: +@@ -450,7 +458,7 @@ class Compiler(base.Compiler): + # how to handle this file? + raise CompileError(f"Don't know how to compile {src} to {obj}") + +- args = [self.cc] + compile_opts + pp_opts ++ args = [self.cc] + compile_opts + pp_opts + d1trimfile_opts + if add_cpp_opts: + args.append('/EHsc') + args.extend((input_opt, "/Fo" + obj)) +-- +2.39.5 (Apple Git-154) + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/recipe-scripts-license.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/recipe-scripts-license.txt new file mode 100644 index 0000000000000000000000000000000000000000..c5aa738f1bd246658c9da9e1bbe2502df6d0e173 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/recipe/recipe-scripts-license.txt @@ -0,0 +1,26 @@ +BSD-3-Clause license +Copyright (c) 2015-2026, conda-forge contributors + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + 3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/test/run_test.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/test/run_test.py new file mode 100644 index 0000000000000000000000000000000000000000..9c711232990736d4e8a897b120cfbd5eb156f33f --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/test/run_test.py @@ -0,0 +1,3 @@ +print("import: 'setuptools'") +import setuptools + diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/test/test_time_dependencies.json b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/test/test_time_dependencies.json new file mode 100644 index 0000000000000000000000000000000000000000..052454a5ab13ba6ee4458196b27c1a069f723b32 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/info/test/test_time_dependencies.json @@ -0,0 +1 @@ +["python"] \ No newline at end of file diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..0f8a1692ba96f5e03167e7307c1c2ff5776b74d6 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/__init__.py @@ -0,0 +1,23 @@ +"""distutils.command + +Package containing implementation of all the standard Distutils +commands.""" + +__all__ = [ + 'build', + 'build_py', + 'build_ext', + 'build_clib', + 'build_scripts', + 'clean', + 'install', + 'install_lib', + 'install_headers', + 'install_scripts', + 'install_data', + 'sdist', + 'bdist', + 'bdist_dumb', + 'bdist_rpm', + 'check', +] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/_framework_compat.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/_framework_compat.py new file mode 100644 index 0000000000000000000000000000000000000000..00d34bc7d8c85126dbae716ebfa48e35b0833222 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/_framework_compat.py @@ -0,0 +1,54 @@ +""" +Backward compatibility for homebrew builds on macOS. +""" + +import functools +import os +import subprocess +import sys +import sysconfig + + +@functools.lru_cache +def enabled(): + """ + Only enabled for Python 3.9 framework homebrew builds + except ensurepip and venv. + """ + PY39 = (3, 9) < sys.version_info < (3, 10) + framework = sys.platform == 'darwin' and sys._framework + homebrew = "Cellar" in sysconfig.get_config_var('projectbase') + venv = sys.prefix != sys.base_prefix + ensurepip = os.environ.get("ENSUREPIP_OPTIONS") + return PY39 and framework and homebrew and not venv and not ensurepip + + +schemes = dict( + osx_framework_library=dict( + stdlib='{installed_base}/{platlibdir}/python{py_version_short}', + platstdlib='{platbase}/{platlibdir}/python{py_version_short}', + purelib='{homebrew_prefix}/lib/python{py_version_short}/site-packages', + platlib='{homebrew_prefix}/{platlibdir}/python{py_version_short}/site-packages', + include='{installed_base}/include/python{py_version_short}{abiflags}', + platinclude='{installed_platbase}/include/python{py_version_short}{abiflags}', + scripts='{homebrew_prefix}/bin', + data='{homebrew_prefix}', + ) +) + + +@functools.lru_cache +def vars(): + if not enabled(): + return {} + homebrew_prefix = subprocess.check_output(['brew', '--prefix'], text=True).strip() + return locals() + + +def scheme(name): + """ + Override the selected scheme for posix_prefix. + """ + if not enabled() or not name.endswith('_prefix'): + return name + return 'osx_framework_library' diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/bdist.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/bdist.py new file mode 100644 index 0000000000000000000000000000000000000000..07811aab27ad7fcd2303883024243e2f52c2bbcb --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/bdist.py @@ -0,0 +1,167 @@ +"""distutils.command.bdist + +Implements the Distutils 'bdist' command (create a built [binary] +distribution).""" + +from __future__ import annotations + +import os +import warnings +from collections.abc import Callable +from typing import TYPE_CHECKING, ClassVar + +from ..core import Command +from ..errors import DistutilsOptionError, DistutilsPlatformError +from ..util import get_platform + +if TYPE_CHECKING: + from typing_extensions import deprecated +else: + + def deprecated(message): + return lambda fn: fn + + +def show_formats(): + """Print list of available formats (arguments to "--format" option).""" + from ..fancy_getopt import FancyGetopt + + formats = [ + ("formats=" + format, None, bdist.format_commands[format][1]) + for format in bdist.format_commands + ] + pretty_printer = FancyGetopt(formats) + pretty_printer.print_help("List of available distribution formats:") + + +class ListCompat(dict[str, tuple[str, str]]): + # adapter to allow for Setuptools compatibility in format_commands + @deprecated("format_commands is now a dict. append is deprecated.") + def append(self, item: object) -> None: + warnings.warn( + "format_commands is now a dict. append is deprecated.", + DeprecationWarning, + stacklevel=2, + ) + + +class bdist(Command): + description = "create a built (binary) distribution" + + user_options = [ + ('bdist-base=', 'b', "temporary directory for creating built distributions"), + ( + 'plat-name=', + 'p', + "platform name to embed in generated filenames " + f"[default: {get_platform()}]", + ), + ('formats=', None, "formats for distribution (comma-separated list)"), + ( + 'dist-dir=', + 'd', + "directory to put final built distributions in [default: dist]", + ), + ('skip-build', None, "skip rebuilding everything (for testing/debugging)"), + ( + 'owner=', + 'u', + "Owner name used when creating a tar file [default: current user]", + ), + ( + 'group=', + 'g', + "Group name used when creating a tar file [default: current group]", + ), + ] + + boolean_options: ClassVar[list[str]] = ['skip-build'] + + help_options: ClassVar[list[tuple[str, str | None, str, Callable[[], object]]]] = [ + ('help-formats', None, "lists available distribution formats", show_formats), + ] + + # The following commands do not take a format option from bdist + no_format_option: ClassVar[tuple[str, ...]] = ('bdist_rpm',) + + # This won't do in reality: will need to distinguish RPM-ish Linux, + # Debian-ish Linux, Solaris, FreeBSD, ..., Windows, Mac OS. + default_format: ClassVar[dict[str, str]] = {'posix': 'gztar', 'nt': 'zip'} + + # Define commands in preferred order for the --help-formats option + format_commands = ListCompat({ + 'rpm': ('bdist_rpm', "RPM distribution"), + 'gztar': ('bdist_dumb', "gzip'ed tar file"), + 'bztar': ('bdist_dumb', "bzip2'ed tar file"), + 'xztar': ('bdist_dumb', "xz'ed tar file"), + 'ztar': ('bdist_dumb', "compressed tar file"), + 'tar': ('bdist_dumb', "tar file"), + 'zip': ('bdist_dumb', "ZIP file"), + }) + + # for compatibility until consumers only reference format_commands + format_command = format_commands + + def initialize_options(self): + self.bdist_base = None + self.plat_name = None + self.formats = None + self.dist_dir = None + self.skip_build = False + self.group = None + self.owner = None + + def finalize_options(self) -> None: + # have to finalize 'plat_name' before 'bdist_base' + if self.plat_name is None: + if self.skip_build: + self.plat_name = get_platform() + else: + self.plat_name = self.get_finalized_command('build').plat_name + + # 'bdist_base' -- parent of per-built-distribution-format + # temporary directories (eg. we'll probably have + # "build/bdist.<plat>/dumb", "build/bdist.<plat>/rpm", etc.) + if self.bdist_base is None: + build_base = self.get_finalized_command('build').build_base + self.bdist_base = os.path.join(build_base, 'bdist.' + self.plat_name) + + self.ensure_string_list('formats') + if self.formats is None: + try: + self.formats = [self.default_format[os.name]] + except KeyError: + raise DistutilsPlatformError( + "don't know how to create built distributions " + f"on platform {os.name}" + ) + + if self.dist_dir is None: + self.dist_dir = "dist" + + def run(self) -> None: + # Figure out which sub-commands we need to run. + commands = [] + for format in self.formats: + try: + commands.append(self.format_commands[format][0]) + except KeyError: + raise DistutilsOptionError(f"invalid format '{format}'") + + # Reinitialize and run each command. + for i in range(len(self.formats)): + cmd_name = commands[i] + sub_cmd = self.reinitialize_command(cmd_name) + if cmd_name not in self.no_format_option: + sub_cmd.format = self.formats[i] + + # passing the owner and group names for tar archiving + if cmd_name == 'bdist_dumb': + sub_cmd.owner = self.owner + sub_cmd.group = self.group + + # If we're going to need to run this command again, tell it to + # keep its temporary files around so subsequent runs go faster. + if cmd_name in commands[i + 1 :]: + sub_cmd.keep_temp = True + self.run_command(cmd_name) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/bdist_dumb.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/bdist_dumb.py new file mode 100644 index 0000000000000000000000000000000000000000..c49ef253b47cd0791aae1fc65c005c668cb1e97b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/bdist_dumb.py @@ -0,0 +1,141 @@ +"""distutils.command.bdist_dumb + +Implements the Distutils 'bdist_dumb' command (create a "dumb" built +distribution -- i.e., just an archive to be unpacked under $prefix or +$exec_prefix).""" + +import os +from distutils._log import log +from typing import ClassVar + +from ..core import Command +from ..dir_util import ensure_relative, remove_tree +from ..errors import DistutilsPlatformError +from ..sysconfig import get_python_version +from ..util import get_platform + + +class bdist_dumb(Command): + description = "create a \"dumb\" built distribution" + + user_options = [ + ('bdist-dir=', 'd', "temporary directory for creating the distribution"), + ( + 'plat-name=', + 'p', + "platform name to embed in generated filenames " + f"[default: {get_platform()}]", + ), + ( + 'format=', + 'f', + "archive format to create (tar, gztar, bztar, xztar, ztar, zip)", + ), + ( + 'keep-temp', + 'k', + "keep the pseudo-installation tree around after creating the distribution archive", + ), + ('dist-dir=', 'd', "directory to put final built distributions in"), + ('skip-build', None, "skip rebuilding everything (for testing/debugging)"), + ( + 'relative', + None, + "build the archive using relative paths [default: false]", + ), + ( + 'owner=', + 'u', + "Owner name used when creating a tar file [default: current user]", + ), + ( + 'group=', + 'g', + "Group name used when creating a tar file [default: current group]", + ), + ] + + boolean_options: ClassVar[list[str]] = ['keep-temp', 'skip-build', 'relative'] + + default_format = {'posix': 'gztar', 'nt': 'zip'} + + def initialize_options(self): + self.bdist_dir = None + self.plat_name = None + self.format = None + self.keep_temp = False + self.dist_dir = None + self.skip_build = None + self.relative = False + self.owner = None + self.group = None + + def finalize_options(self): + if self.bdist_dir is None: + bdist_base = self.get_finalized_command('bdist').bdist_base + self.bdist_dir = os.path.join(bdist_base, 'dumb') + + if self.format is None: + try: + self.format = self.default_format[os.name] + except KeyError: + raise DistutilsPlatformError( + "don't know how to create dumb built distributions " + f"on platform {os.name}" + ) + + self.set_undefined_options( + 'bdist', + ('dist_dir', 'dist_dir'), + ('plat_name', 'plat_name'), + ('skip_build', 'skip_build'), + ) + + def run(self): + if not self.skip_build: + self.run_command('build') + + install = self.reinitialize_command('install', reinit_subcommands=True) + install.root = self.bdist_dir + install.skip_build = self.skip_build + install.warn_dir = False + + log.info("installing to %s", self.bdist_dir) + self.run_command('install') + + # And make an archive relative to the root of the + # pseudo-installation tree. + archive_basename = f"{self.distribution.get_fullname()}.{self.plat_name}" + + pseudoinstall_root = os.path.join(self.dist_dir, archive_basename) + if not self.relative: + archive_root = self.bdist_dir + else: + if self.distribution.has_ext_modules() and ( + install.install_base != install.install_platbase + ): + raise DistutilsPlatformError( + "can't make a dumb built distribution where " + f"base and platbase are different ({install.install_base!r}, {install.install_platbase!r})" + ) + else: + archive_root = os.path.join( + self.bdist_dir, ensure_relative(install.install_base) + ) + + # Make the archive + filename = self.make_archive( + pseudoinstall_root, + self.format, + root_dir=archive_root, + owner=self.owner, + group=self.group, + ) + if self.distribution.has_ext_modules(): + pyversion = get_python_version() + else: + pyversion = 'any' + self.distribution.dist_files.append(('bdist_dumb', pyversion, filename)) + + if not self.keep_temp: + remove_tree(self.bdist_dir) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/bdist_rpm.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/bdist_rpm.py new file mode 100644 index 0000000000000000000000000000000000000000..dfa5f99dda095af76d8ffac33e1dd8bfd6aad931 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/bdist_rpm.py @@ -0,0 +1,597 @@ +"""distutils.command.bdist_rpm + +Implements the Distutils 'bdist_rpm' command (create RPM source and binary +distributions).""" + +import os +import subprocess +import sys +from distutils._log import log +from typing import ClassVar + +from ..core import Command +from ..debug import DEBUG +from ..errors import ( + DistutilsExecError, + DistutilsFileError, + DistutilsOptionError, + DistutilsPlatformError, +) +from ..file_util import write_file +from ..sysconfig import get_python_version + + +class bdist_rpm(Command): + description = "create an RPM distribution" + + user_options = [ + ('bdist-base=', None, "base directory for creating built distributions"), + ( + 'rpm-base=', + None, + "base directory for creating RPMs (defaults to \"rpm\" under " + "--bdist-base; must be specified for RPM 2)", + ), + ( + 'dist-dir=', + 'd', + "directory to put final RPM files in (and .spec files if --spec-only)", + ), + ( + 'python=', + None, + "path to Python interpreter to hard-code in the .spec file " + "[default: \"python\"]", + ), + ( + 'fix-python', + None, + "hard-code the exact path to the current Python interpreter in " + "the .spec file", + ), + ('spec-only', None, "only regenerate spec file"), + ('source-only', None, "only generate source RPM"), + ('binary-only', None, "only generate binary RPM"), + ('use-bzip2', None, "use bzip2 instead of gzip to create source distribution"), + # More meta-data: too RPM-specific to put in the setup script, + # but needs to go in the .spec file -- so we make these options + # to "bdist_rpm". The idea is that packagers would put this + # info in setup.cfg, although they are of course free to + # supply it on the command line. + ( + 'distribution-name=', + None, + "name of the (Linux) distribution to which this " + "RPM applies (*not* the name of the module distribution!)", + ), + ('group=', None, "package classification [default: \"Development/Libraries\"]"), + ('release=', None, "RPM release number"), + ('serial=', None, "RPM serial number"), + ( + 'vendor=', + None, + "RPM \"vendor\" (eg. \"Joe Blow <joe@example.com>\") " + "[default: maintainer or author from setup script]", + ), + ( + 'packager=', + None, + "RPM packager (eg. \"Jane Doe <jane@example.net>\") [default: vendor]", + ), + ('doc-files=', None, "list of documentation files (space or comma-separated)"), + ('changelog=', None, "RPM changelog"), + ('icon=', None, "name of icon file"), + ('provides=', None, "capabilities provided by this package"), + ('requires=', None, "capabilities required by this package"), + ('conflicts=', None, "capabilities which conflict with this package"), + ('build-requires=', None, "capabilities required to build this package"), + ('obsoletes=', None, "capabilities made obsolete by this package"), + ('no-autoreq', None, "do not automatically calculate dependencies"), + # Actions to take when building RPM + ('keep-temp', 'k', "don't clean up RPM build directory"), + ('no-keep-temp', None, "clean up RPM build directory [default]"), + ( + 'use-rpm-opt-flags', + None, + "compile with RPM_OPT_FLAGS when building from source RPM", + ), + ('no-rpm-opt-flags', None, "do not pass any RPM CFLAGS to compiler"), + ('rpm3-mode', None, "RPM 3 compatibility mode (default)"), + ('rpm2-mode', None, "RPM 2 compatibility mode"), + # Add the hooks necessary for specifying custom scripts + ('prep-script=', None, "Specify a script for the PREP phase of RPM building"), + ('build-script=', None, "Specify a script for the BUILD phase of RPM building"), + ( + 'pre-install=', + None, + "Specify a script for the pre-INSTALL phase of RPM building", + ), + ( + 'install-script=', + None, + "Specify a script for the INSTALL phase of RPM building", + ), + ( + 'post-install=', + None, + "Specify a script for the post-INSTALL phase of RPM building", + ), + ( + 'pre-uninstall=', + None, + "Specify a script for the pre-UNINSTALL phase of RPM building", + ), + ( + 'post-uninstall=', + None, + "Specify a script for the post-UNINSTALL phase of RPM building", + ), + ('clean-script=', None, "Specify a script for the CLEAN phase of RPM building"), + ( + 'verify-script=', + None, + "Specify a script for the VERIFY phase of the RPM build", + ), + # Allow a packager to explicitly force an architecture + ('force-arch=', None, "Force an architecture onto the RPM build process"), + ('quiet', 'q', "Run the INSTALL phase of RPM building in quiet mode"), + ] + + boolean_options: ClassVar[list[str]] = [ + 'keep-temp', + 'use-rpm-opt-flags', + 'rpm3-mode', + 'no-autoreq', + 'quiet', + ] + + negative_opt: ClassVar[dict[str, str]] = { + 'no-keep-temp': 'keep-temp', + 'no-rpm-opt-flags': 'use-rpm-opt-flags', + 'rpm2-mode': 'rpm3-mode', + } + + def initialize_options(self): + self.bdist_base = None + self.rpm_base = None + self.dist_dir = None + self.python = None + self.fix_python = None + self.spec_only = None + self.binary_only = None + self.source_only = None + self.use_bzip2 = None + + self.distribution_name = None + self.group = None + self.release = None + self.serial = None + self.vendor = None + self.packager = None + self.doc_files = None + self.changelog = None + self.icon = None + + self.prep_script = None + self.build_script = None + self.install_script = None + self.clean_script = None + self.verify_script = None + self.pre_install = None + self.post_install = None + self.pre_uninstall = None + self.post_uninstall = None + self.prep = None + self.provides = None + self.requires = None + self.conflicts = None + self.build_requires = None + self.obsoletes = None + + self.keep_temp = False + self.use_rpm_opt_flags = True + self.rpm3_mode = True + self.no_autoreq = False + + self.force_arch = None + self.quiet = False + + def finalize_options(self) -> None: + self.set_undefined_options('bdist', ('bdist_base', 'bdist_base')) + if self.rpm_base is None: + if not self.rpm3_mode: + raise DistutilsOptionError("you must specify --rpm-base in RPM 2 mode") + self.rpm_base = os.path.join(self.bdist_base, "rpm") + + if self.python is None: + if self.fix_python: + self.python = sys.executable + else: + self.python = "python3" + elif self.fix_python: + raise DistutilsOptionError( + "--python and --fix-python are mutually exclusive options" + ) + + if os.name != 'posix': + raise DistutilsPlatformError( + f"don't know how to create RPM distributions on platform {os.name}" + ) + if self.binary_only and self.source_only: + raise DistutilsOptionError( + "cannot supply both '--source-only' and '--binary-only'" + ) + + # don't pass CFLAGS to pure python distributions + if not self.distribution.has_ext_modules(): + self.use_rpm_opt_flags = False + + self.set_undefined_options('bdist', ('dist_dir', 'dist_dir')) + self.finalize_package_data() + + def finalize_package_data(self) -> None: + self.ensure_string('group', "Development/Libraries") + self.ensure_string( + 'vendor', + f"{self.distribution.get_contact()} <{self.distribution.get_contact_email()}>", + ) + self.ensure_string('packager') + self.ensure_string_list('doc_files') + if isinstance(self.doc_files, list): + for readme in ('README', 'README.txt'): + if os.path.exists(readme) and readme not in self.doc_files: + self.doc_files.append(readme) + + self.ensure_string('release', "1") + self.ensure_string('serial') # should it be an int? + + self.ensure_string('distribution_name') + + self.ensure_string('changelog') + # Format changelog correctly + self.changelog = self._format_changelog(self.changelog) + + self.ensure_filename('icon') + + self.ensure_filename('prep_script') + self.ensure_filename('build_script') + self.ensure_filename('install_script') + self.ensure_filename('clean_script') + self.ensure_filename('verify_script') + self.ensure_filename('pre_install') + self.ensure_filename('post_install') + self.ensure_filename('pre_uninstall') + self.ensure_filename('post_uninstall') + + # XXX don't forget we punted on summaries and descriptions -- they + # should be handled here eventually! + + # Now *this* is some meta-data that belongs in the setup script... + self.ensure_string_list('provides') + self.ensure_string_list('requires') + self.ensure_string_list('conflicts') + self.ensure_string_list('build_requires') + self.ensure_string_list('obsoletes') + + self.ensure_string('force_arch') + + def run(self) -> None: # noqa: C901 + if DEBUG: + print("before _get_package_data():") + print("vendor =", self.vendor) + print("packager =", self.packager) + print("doc_files =", self.doc_files) + print("changelog =", self.changelog) + + # make directories + if self.spec_only: + spec_dir = self.dist_dir + self.mkpath(spec_dir) + else: + rpm_dir = {} + for d in ('SOURCES', 'SPECS', 'BUILD', 'RPMS', 'SRPMS'): + rpm_dir[d] = os.path.join(self.rpm_base, d) + self.mkpath(rpm_dir[d]) + spec_dir = rpm_dir['SPECS'] + + # Spec file goes into 'dist_dir' if '--spec-only specified', + # build/rpm.<plat> otherwise. + spec_path = os.path.join(spec_dir, f"{self.distribution.get_name()}.spec") + self.execute( + write_file, (spec_path, self._make_spec_file()), f"writing '{spec_path}'" + ) + + if self.spec_only: # stop if requested + return + + # Make a source distribution and copy to SOURCES directory with + # optional icon. + saved_dist_files = self.distribution.dist_files[:] + sdist = self.reinitialize_command('sdist') + if self.use_bzip2: + sdist.formats = ['bztar'] + else: + sdist.formats = ['gztar'] + self.run_command('sdist') + self.distribution.dist_files = saved_dist_files + + source = sdist.get_archive_files()[0] + source_dir = rpm_dir['SOURCES'] + self.copy_file(source, source_dir) + + if self.icon: + if os.path.exists(self.icon): + self.copy_file(self.icon, source_dir) + else: + raise DistutilsFileError(f"icon file '{self.icon}' does not exist") + + # build package + log.info("building RPMs") + rpm_cmd = ['rpmbuild'] + + if self.source_only: # what kind of RPMs? + rpm_cmd.append('-bs') + elif self.binary_only: + rpm_cmd.append('-bb') + else: + rpm_cmd.append('-ba') + rpm_cmd.extend(['--define', f'__python {self.python}']) + if self.rpm3_mode: + rpm_cmd.extend(['--define', f'_topdir {os.path.abspath(self.rpm_base)}']) + if not self.keep_temp: + rpm_cmd.append('--clean') + + if self.quiet: + rpm_cmd.append('--quiet') + + rpm_cmd.append(spec_path) + # Determine the binary rpm names that should be built out of this spec + # file + # Note that some of these may not be really built (if the file + # list is empty) + nvr_string = "%{name}-%{version}-%{release}" + src_rpm = nvr_string + ".src.rpm" + non_src_rpm = "%{arch}/" + nvr_string + ".%{arch}.rpm" + q_cmd = rf"rpm -q --qf '{src_rpm} {non_src_rpm}\n' --specfile '{spec_path}'" + + out = os.popen(q_cmd) + try: + binary_rpms = [] + source_rpm = None + while True: + line = out.readline() + if not line: + break + ell = line.strip().split() + assert len(ell) == 2 + binary_rpms.append(ell[1]) + # The source rpm is named after the first entry in the spec file + if source_rpm is None: + source_rpm = ell[0] + + status = out.close() + if status: + raise DistutilsExecError(f"Failed to execute: {q_cmd!r}") + + finally: + out.close() + + self.spawn(rpm_cmd) + + if self.distribution.has_ext_modules(): + pyversion = get_python_version() + else: + pyversion = 'any' + + if not self.binary_only: + srpm = os.path.join(rpm_dir['SRPMS'], source_rpm) + assert os.path.exists(srpm) + self.move_file(srpm, self.dist_dir) + filename = os.path.join(self.dist_dir, source_rpm) + self.distribution.dist_files.append(('bdist_rpm', pyversion, filename)) + + if not self.source_only: + for rpm in binary_rpms: + rpm = os.path.join(rpm_dir['RPMS'], rpm) + if os.path.exists(rpm): + self.move_file(rpm, self.dist_dir) + filename = os.path.join(self.dist_dir, os.path.basename(rpm)) + self.distribution.dist_files.append(( + 'bdist_rpm', + pyversion, + filename, + )) + + def _dist_path(self, path): + return os.path.join(self.dist_dir, os.path.basename(path)) + + def _make_spec_file(self): # noqa: C901 + """Generate the text of an RPM spec file and return it as a + list of strings (one per line). + """ + # definitions and headers + spec_file = [ + '%define name ' + self.distribution.get_name(), + '%define version ' + self.distribution.get_version().replace('-', '_'), + '%define unmangled_version ' + self.distribution.get_version(), + '%define release ' + self.release.replace('-', '_'), + '', + 'Summary: ' + (self.distribution.get_description() or "UNKNOWN"), + ] + + # Workaround for #14443 which affects some RPM based systems such as + # RHEL6 (and probably derivatives) + vendor_hook = subprocess.getoutput('rpm --eval %{__os_install_post}') + # Generate a potential replacement value for __os_install_post (whilst + # normalizing the whitespace to simplify the test for whether the + # invocation of brp-python-bytecompile passes in __python): + vendor_hook = '\n'.join([ + f' {line.strip()} \\' for line in vendor_hook.splitlines() + ]) + problem = "brp-python-bytecompile \\\n" + fixed = "brp-python-bytecompile %{__python} \\\n" + fixed_hook = vendor_hook.replace(problem, fixed) + if fixed_hook != vendor_hook: + spec_file.append('# Workaround for https://bugs.python.org/issue14443') + spec_file.append('%define __os_install_post ' + fixed_hook + '\n') + + # put locale summaries into spec file + # XXX not supported for now (hard to put a dictionary + # in a config file -- arg!) + # for locale in self.summaries.keys(): + # spec_file.append('Summary(%s): %s' % (locale, + # self.summaries[locale])) + + spec_file.extend([ + 'Name: %{name}', + 'Version: %{version}', + 'Release: %{release}', + ]) + + # XXX yuck! this filename is available from the "sdist" command, + # but only after it has run: and we create the spec file before + # running "sdist", in case of --spec-only. + if self.use_bzip2: + spec_file.append('Source0: %{name}-%{unmangled_version}.tar.bz2') + else: + spec_file.append('Source0: %{name}-%{unmangled_version}.tar.gz') + + spec_file.extend([ + 'License: ' + (self.distribution.get_license() or "UNKNOWN"), + 'Group: ' + self.group, + 'BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot', + 'Prefix: %{_prefix}', + ]) + + if not self.force_arch: + # noarch if no extension modules + if not self.distribution.has_ext_modules(): + spec_file.append('BuildArch: noarch') + else: + spec_file.append(f'BuildArch: {self.force_arch}') + + for field in ( + 'Vendor', + 'Packager', + 'Provides', + 'Requires', + 'Conflicts', + 'Obsoletes', + ): + val = getattr(self, field.lower()) + if isinstance(val, list): + spec_file.append('{}: {}'.format(field, ' '.join(val))) + elif val is not None: + spec_file.append(f'{field}: {val}') + + if self.distribution.get_url(): + spec_file.append('Url: ' + self.distribution.get_url()) + + if self.distribution_name: + spec_file.append('Distribution: ' + self.distribution_name) + + if self.build_requires: + spec_file.append('BuildRequires: ' + ' '.join(self.build_requires)) + + if self.icon: + spec_file.append('Icon: ' + os.path.basename(self.icon)) + + if self.no_autoreq: + spec_file.append('AutoReq: 0') + + spec_file.extend([ + '', + '%description', + self.distribution.get_long_description() or "", + ]) + + # put locale descriptions into spec file + # XXX again, suppressed because config file syntax doesn't + # easily support this ;-( + # for locale in self.descriptions.keys(): + # spec_file.extend([ + # '', + # '%description -l ' + locale, + # self.descriptions[locale], + # ]) + + # rpm scripts + # figure out default build script + def_setup_call = f"{self.python} {os.path.basename(sys.argv[0])}" + def_build = f"{def_setup_call} build" + if self.use_rpm_opt_flags: + def_build = 'env CFLAGS="$RPM_OPT_FLAGS" ' + def_build + + # insert contents of files + + # XXX this is kind of misleading: user-supplied options are files + # that we open and interpolate into the spec file, but the defaults + # are just text that we drop in as-is. Hmmm. + + install_cmd = f'{def_setup_call} install -O1 --root=$RPM_BUILD_ROOT --record=INSTALLED_FILES' + + script_options = [ + ('prep', 'prep_script', "%setup -n %{name}-%{unmangled_version}"), + ('build', 'build_script', def_build), + ('install', 'install_script', install_cmd), + ('clean', 'clean_script', "rm -rf $RPM_BUILD_ROOT"), + ('verifyscript', 'verify_script', None), + ('pre', 'pre_install', None), + ('post', 'post_install', None), + ('preun', 'pre_uninstall', None), + ('postun', 'post_uninstall', None), + ] + + for rpm_opt, attr, default in script_options: + # Insert contents of file referred to, if no file is referred to + # use 'default' as contents of script + val = getattr(self, attr) + if val or default: + spec_file.extend([ + '', + '%' + rpm_opt, + ]) + if val: + with open(val) as f: + spec_file.extend(f.read().split('\n')) + else: + spec_file.append(default) + + # files section + spec_file.extend([ + '', + '%files -f INSTALLED_FILES', + '%defattr(-,root,root)', + ]) + + if self.doc_files: + spec_file.append('%doc ' + ' '.join(self.doc_files)) + + if self.changelog: + spec_file.extend([ + '', + '%changelog', + ]) + spec_file.extend(self.changelog) + + return spec_file + + def _format_changelog(self, changelog): + """Format the changelog correctly and convert it to a list of strings""" + if not changelog: + return changelog + new_changelog = [] + for line in changelog.strip().split('\n'): + line = line.strip() + if line[0] == '*': + new_changelog.extend(['', line]) + elif line[0] == '-': + new_changelog.append(line) + else: + new_changelog.append(' ' + line) + + # strip trailing newline inserted by first changelog entry + if not new_changelog[0]: + del new_changelog[0] + + return new_changelog diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/build.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/build.py new file mode 100644 index 0000000000000000000000000000000000000000..6a8303a954ea705c547e2014dc6b51d9d987a532 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/build.py @@ -0,0 +1,156 @@ +"""distutils.command.build + +Implements the Distutils 'build' command.""" + +from __future__ import annotations + +import os +import sys +import sysconfig +from collections.abc import Callable +from typing import ClassVar + +from ..ccompiler import show_compilers +from ..core import Command +from ..errors import DistutilsOptionError +from ..util import get_platform + + +class build(Command): + description = "build everything needed to install" + + user_options = [ + ('build-base=', 'b', "base directory for build library"), + ('build-purelib=', None, "build directory for platform-neutral distributions"), + ('build-platlib=', None, "build directory for platform-specific distributions"), + ( + 'build-lib=', + None, + "build directory for all distribution (defaults to either build-purelib or build-platlib", + ), + ('build-scripts=', None, "build directory for scripts"), + ('build-temp=', 't', "temporary build directory"), + ( + 'plat-name=', + 'p', + f"platform name to build for, if supported [default: {get_platform()}]", + ), + ('compiler=', 'c', "specify the compiler type"), + ('parallel=', 'j', "number of parallel build jobs"), + ('debug', 'g', "compile extensions and libraries with debugging information"), + ('force', 'f', "forcibly build everything (ignore file timestamps)"), + ('executable=', 'e', "specify final destination interpreter path (build.py)"), + ] + + boolean_options: ClassVar[list[str]] = ['debug', 'force'] + + help_options: ClassVar[list[tuple[str, str | None, str, Callable[[], object]]]] = [ + ('help-compiler', None, "list available compilers", show_compilers), + ] + + def initialize_options(self): + self.build_base = 'build' + # these are decided only after 'build_base' has its final value + # (unless overridden by the user or client) + self.build_purelib = None + self.build_platlib = None + self.build_lib = None + self.build_temp = None + self.build_scripts = None + self.compiler = None + self.plat_name = None + self.debug = None + self.force = False + self.executable = None + self.parallel = None + + def finalize_options(self) -> None: # noqa: C901 + if self.plat_name is None: + self.plat_name = get_platform() + else: + # plat-name only supported for windows (other platforms are + # supported via ./configure flags, if at all). Avoid misleading + # other platforms. + if os.name != 'nt': + raise DistutilsOptionError( + "--plat-name only supported on Windows (try " + "using './configure --help' on your platform)" + ) + + plat_specifier = f".{self.plat_name}-{sys.implementation.cache_tag}" + + # Python 3.13+ with --disable-gil shouldn't share build directories + if sysconfig.get_config_var('Py_GIL_DISABLED'): + plat_specifier += 't' + + # Make it so Python 2.x and Python 2.x with --with-pydebug don't + # share the same build directories. Doing so confuses the build + # process for C modules + if hasattr(sys, 'gettotalrefcount'): + plat_specifier += '-pydebug' + + # 'build_purelib' and 'build_platlib' just default to 'lib' and + # 'lib.<plat>' under the base build directory. We only use one of + # them for a given distribution, though -- + if self.build_purelib is None: + self.build_purelib = os.path.join(self.build_base, 'lib') + if self.build_platlib is None: + self.build_platlib = os.path.join(self.build_base, 'lib' + plat_specifier) + + # 'build_lib' is the actual directory that we will use for this + # particular module distribution -- if user didn't supply it, pick + # one of 'build_purelib' or 'build_platlib'. + if self.build_lib is None: + if self.distribution.has_ext_modules(): + self.build_lib = self.build_platlib + else: + self.build_lib = self.build_purelib + + # 'build_temp' -- temporary directory for compiler turds, + # "build/temp.<plat>" + if self.build_temp is None: + self.build_temp = os.path.join(self.build_base, 'temp' + plat_specifier) + if self.build_scripts is None: + self.build_scripts = os.path.join( + self.build_base, + f'scripts-{sys.version_info.major}.{sys.version_info.minor}', + ) + + if self.executable is None and sys.executable: + self.executable = os.path.normpath(sys.executable) + + if isinstance(self.parallel, str): + try: + self.parallel = int(self.parallel) + except ValueError: + raise DistutilsOptionError("parallel should be an integer") + + def run(self) -> None: + # Run all relevant sub-commands. This will be some subset of: + # - build_py - pure Python modules + # - build_clib - standalone C libraries + # - build_ext - Python extensions + # - build_scripts - (Python) scripts + for cmd_name in self.get_sub_commands(): + self.run_command(cmd_name) + + # -- Predicates for the sub-command list --------------------------- + + def has_pure_modules(self): + return self.distribution.has_pure_modules() + + def has_c_libraries(self): + return self.distribution.has_c_libraries() + + def has_ext_modules(self): + return self.distribution.has_ext_modules() + + def has_scripts(self): + return self.distribution.has_scripts() + + sub_commands = [ + ('build_py', has_pure_modules), + ('build_clib', has_c_libraries), + ('build_ext', has_ext_modules), + ('build_scripts', has_scripts), + ] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/build_clib.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/build_clib.py new file mode 100644 index 0000000000000000000000000000000000000000..8de5df239c793ac74265d5aac6b113c99b1934fd --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/build_clib.py @@ -0,0 +1,199 @@ +"""distutils.command.build_clib + +Implements the Distutils 'build_clib' command, to build a C/C++ library +that is included in the module distribution and needed by an extension +module.""" + +# XXX this module has *lots* of code ripped-off quite transparently from +# build_ext.py -- not surprisingly really, as the work required to build +# a static library from a collection of C source files is not really all +# that different from what's required to build a shared object file from +# a collection of C source files. Nevertheless, I haven't done the +# necessary refactoring to account for the overlap in code between the +# two modules, mainly because a number of subtle details changed in the +# cut 'n paste. Sigh. +from __future__ import annotations + +import os +from collections.abc import Callable +from distutils._log import log +from typing import ClassVar + +from ..ccompiler import new_compiler, show_compilers +from ..core import Command +from ..errors import DistutilsSetupError +from ..sysconfig import customize_compiler + + +class build_clib(Command): + description = "build C/C++ libraries used by Python extensions" + + user_options: ClassVar[list[tuple[str, str, str]]] = [ + ('build-clib=', 'b', "directory to build C/C++ libraries to"), + ('build-temp=', 't', "directory to put temporary build by-products"), + ('debug', 'g', "compile with debugging information"), + ('force', 'f', "forcibly build everything (ignore file timestamps)"), + ('compiler=', 'c', "specify the compiler type"), + ] + + boolean_options: ClassVar[list[str]] = ['debug', 'force'] + + help_options: ClassVar[list[tuple[str, str | None, str, Callable[[], object]]]] = [ + ('help-compiler', None, "list available compilers", show_compilers), + ] + + def initialize_options(self): + self.build_clib = None + self.build_temp = None + + # List of libraries to build + self.libraries = None + + # Compilation options for all libraries + self.include_dirs = None + self.define = None + self.undef = None + self.debug = None + self.force = False + self.compiler = None + + def finalize_options(self) -> None: + # This might be confusing: both build-clib and build-temp default + # to build-temp as defined by the "build" command. This is because + # I think that C libraries are really just temporary build + # by-products, at least from the point of view of building Python + # extensions -- but I want to keep my options open. + self.set_undefined_options( + 'build', + ('build_temp', 'build_clib'), + ('build_temp', 'build_temp'), + ('compiler', 'compiler'), + ('debug', 'debug'), + ('force', 'force'), + ) + + self.libraries = self.distribution.libraries + if self.libraries: + self.check_library_list(self.libraries) + + if self.include_dirs is None: + self.include_dirs = self.distribution.include_dirs or [] + if isinstance(self.include_dirs, str): + self.include_dirs = self.include_dirs.split(os.pathsep) + + # XXX same as for build_ext -- what about 'self.define' and + # 'self.undef' ? + + def run(self) -> None: + if not self.libraries: + return + + self.compiler = new_compiler(compiler=self.compiler, force=self.force) + customize_compiler(self.compiler) + + if self.include_dirs is not None: + self.compiler.set_include_dirs(self.include_dirs) + if self.define is not None: + # 'define' option is a list of (name,value) tuples + for name, value in self.define: + self.compiler.define_macro(name, value) + if self.undef is not None: + for macro in self.undef: + self.compiler.undefine_macro(macro) + + self.build_libraries(self.libraries) + + def check_library_list(self, libraries) -> None: + """Ensure that the list of libraries is valid. + + `library` is presumably provided as a command option 'libraries'. + This method checks that it is a list of 2-tuples, where the tuples + are (library_name, build_info_dict). + + Raise DistutilsSetupError if the structure is invalid anywhere; + just returns otherwise. + """ + if not isinstance(libraries, list): + raise DistutilsSetupError("'libraries' option must be a list of tuples") + + for lib in libraries: + if not isinstance(lib, tuple) and len(lib) != 2: + raise DistutilsSetupError("each element of 'libraries' must a 2-tuple") + + name, build_info = lib + + if not isinstance(name, str): + raise DistutilsSetupError( + "first element of each tuple in 'libraries' " + "must be a string (the library name)" + ) + + if '/' in name or (os.sep != '/' and os.sep in name): + raise DistutilsSetupError( + f"bad library name '{lib[0]}': may not contain directory separators" + ) + + if not isinstance(build_info, dict): + raise DistutilsSetupError( + "second element of each tuple in 'libraries' " + "must be a dictionary (build info)" + ) + + def get_library_names(self): + # Assume the library list is valid -- 'check_library_list()' is + # called from 'finalize_options()', so it should be! + if not self.libraries: + return None + + lib_names = [] + for lib_name, _build_info in self.libraries: + lib_names.append(lib_name) + return lib_names + + def get_source_files(self): + self.check_library_list(self.libraries) + filenames = [] + for lib_name, build_info in self.libraries: + sources = build_info.get('sources') + if sources is None or not isinstance(sources, (list, tuple)): + raise DistutilsSetupError( + f"in 'libraries' option (library '{lib_name}'), " + "'sources' must be present and must be " + "a list of source filenames" + ) + + filenames.extend(sources) + return filenames + + def build_libraries(self, libraries) -> None: + for lib_name, build_info in libraries: + sources = build_info.get('sources') + if sources is None or not isinstance(sources, (list, tuple)): + raise DistutilsSetupError( + f"in 'libraries' option (library '{lib_name}'), " + "'sources' must be present and must be " + "a list of source filenames" + ) + sources = list(sources) + + log.info("building '%s' library", lib_name) + + # First, compile the source code to object files in the library + # directory. (This should probably change to putting object + # files in a temporary build directory.) + macros = build_info.get('macros') + include_dirs = build_info.get('include_dirs') + objects = self.compiler.compile( + sources, + output_dir=self.build_temp, + macros=macros, + include_dirs=include_dirs, + debug=self.debug, + ) + + # Now "link" the object files together into a static library. + # (On Unix at least, this isn't really linking -- it just + # builds an archive. Whatever.) + self.compiler.create_static_lib( + objects, lib_name, output_dir=self.build_clib, debug=self.debug + ) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/build_ext.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/build_ext.py new file mode 100644 index 0000000000000000000000000000000000000000..df623d7e0ef2f667bfce329283256513621eacf7 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/build_ext.py @@ -0,0 +1,811 @@ +"""distutils.command.build_ext + +Implements the Distutils 'build_ext' command, for building extension +modules (currently limited to C extensions, should accommodate C++ +extensions ASAP).""" + +from __future__ import annotations + +import contextlib +import os +import re +import sys +from collections.abc import Callable +from distutils._log import log +from site import USER_BASE +from typing import ClassVar + +from .._modified import newer_group +from ..ccompiler import new_compiler, show_compilers +from ..core import Command +from ..errors import ( + CCompilerError, + CompileError, + DistutilsError, + DistutilsOptionError, + DistutilsPlatformError, + DistutilsSetupError, +) +from ..extension import Extension +from ..sysconfig import customize_compiler, get_config_h_filename, get_python_version +from ..util import get_platform, is_freethreaded, is_mingw + +# An extension name is just a dot-separated list of Python NAMEs (ie. +# the same as a fully-qualified module name). +extension_name_re = re.compile(r'^[a-zA-Z_][a-zA-Z_0-9]*(\.[a-zA-Z_][a-zA-Z_0-9]*)*$') + + +class build_ext(Command): + description = "build C/C++ extensions (compile/link to build directory)" + + # XXX thoughts on how to deal with complex command-line options like + # these, i.e. how to make it so fancy_getopt can suck them off the + # command line and make it look like setup.py defined the appropriate + # lists of tuples of what-have-you. + # - each command needs a callback to process its command-line options + # - Command.__init__() needs access to its share of the whole + # command line (must ultimately come from + # Distribution.parse_command_line()) + # - it then calls the current command class' option-parsing + # callback to deal with weird options like -D, which have to + # parse the option text and churn out some custom data + # structure + # - that data structure (in this case, a list of 2-tuples) + # will then be present in the command object by the time + # we get to finalize_options() (i.e. the constructor + # takes care of both command-line and client options + # in between initialize_options() and finalize_options()) + + sep_by = f" (separated by '{os.pathsep}')" + user_options = [ + ('build-lib=', 'b', "directory for compiled extension modules"), + ('build-temp=', 't', "directory for temporary files (build by-products)"), + ( + 'plat-name=', + 'p', + "platform name to cross-compile for, if supported " + f"[default: {get_platform()}]", + ), + ( + 'inplace', + 'i', + "ignore build-lib and put compiled extensions into the source " + "directory alongside your pure Python modules", + ), + ( + 'include-dirs=', + 'I', + "list of directories to search for header files" + sep_by, + ), + ('define=', 'D', "C preprocessor macros to define"), + ('undef=', 'U', "C preprocessor macros to undefine"), + ('libraries=', 'l', "external C libraries to link with"), + ( + 'library-dirs=', + 'L', + "directories to search for external C libraries" + sep_by, + ), + ('rpath=', 'R', "directories to search for shared C libraries at runtime"), + ('link-objects=', 'O', "extra explicit link objects to include in the link"), + ('debug', 'g', "compile/link with debugging information"), + ('force', 'f', "forcibly build everything (ignore file timestamps)"), + ('compiler=', 'c', "specify the compiler type"), + ('parallel=', 'j', "number of parallel build jobs"), + ('swig-cpp', None, "make SWIG create C++ files (default is C)"), + ('swig-opts=', None, "list of SWIG command line options"), + ('swig=', None, "path to the SWIG executable"), + ('user', None, "add user include, library and rpath"), + ] + + boolean_options: ClassVar[list[str]] = [ + 'inplace', + 'debug', + 'force', + 'swig-cpp', + 'user', + ] + + help_options: ClassVar[list[tuple[str, str | None, str, Callable[[], object]]]] = [ + ('help-compiler', None, "list available compilers", show_compilers), + ] + + def initialize_options(self): + self.extensions = None + self.build_lib = None + self.plat_name = None + self.build_temp = None + self.inplace = False + self.package = None + + self.include_dirs = None + self.define = None + self.undef = None + self.libraries = None + self.library_dirs = None + self.rpath = None + self.link_objects = None + self.debug = None + self.force = None + self.compiler = None + self.swig = None + self.swig_cpp = None + self.swig_opts = None + self.user = None + self.parallel = None + + @staticmethod + def _python_lib_dir(sysconfig): + """ + Resolve Python's library directory for building extensions + that rely on a shared Python library. + + See python/cpython#44264 and python/cpython#48686 + """ + if not sysconfig.get_config_var('Py_ENABLE_SHARED'): + return + + if sysconfig.python_build: + yield '.' + return + + if sys.platform == 'zos': + # On z/OS, a user is not required to install Python to + # a predetermined path, but can use Python portably + installed_dir = sysconfig.get_config_var('base') + lib_dir = sysconfig.get_config_var('platlibdir') + yield os.path.join(installed_dir, lib_dir) + else: + # building third party extensions + yield sysconfig.get_config_var('LIBDIR') + + def finalize_options(self) -> None: # noqa: C901 + from distutils import sysconfig + + self.set_undefined_options( + 'build', + ('build_lib', 'build_lib'), + ('build_temp', 'build_temp'), + ('compiler', 'compiler'), + ('debug', 'debug'), + ('force', 'force'), + ('parallel', 'parallel'), + ('plat_name', 'plat_name'), + ) + + if self.package is None: + self.package = self.distribution.ext_package + + self.extensions = self.distribution.ext_modules + + # Make sure Python's include directories (for Python.h, pyconfig.h, + # etc.) are in the include search path. + py_include = sysconfig.get_python_inc() + plat_py_include = sysconfig.get_python_inc(plat_specific=True) + if self.include_dirs is None: + self.include_dirs = self.distribution.include_dirs or [] + if isinstance(self.include_dirs, str): + self.include_dirs = self.include_dirs.split(os.pathsep) + + # If in a virtualenv, add its include directory + # Issue 16116 + if sys.exec_prefix != sys.base_exec_prefix: + self.include_dirs.append(os.path.join(sys.exec_prefix, 'include')) + + # Put the Python "system" include dir at the end, so that + # any local include dirs take precedence. + self.include_dirs.extend(py_include.split(os.path.pathsep)) + if plat_py_include != py_include: + self.include_dirs.extend(plat_py_include.split(os.path.pathsep)) + + self.ensure_string_list('libraries') + self.ensure_string_list('link_objects') + + # Life is easier if we're not forever checking for None, so + # simplify these options to empty lists if unset + if self.libraries is None: + self.libraries = [] + if self.library_dirs is None: + self.library_dirs = [] + elif isinstance(self.library_dirs, str): + self.library_dirs = self.library_dirs.split(os.pathsep) + + if self.rpath is None: + self.rpath = [] + elif isinstance(self.rpath, str): + self.rpath = self.rpath.split(os.pathsep) + + # for extensions under windows use different directories + # for Release and Debug builds. + # also Python's library directory must be appended to library_dirs + if os.name == 'nt' and not is_mingw(): + # the 'libs' directory is for binary installs - we assume that + # must be the *native* platform. But we don't really support + # cross-compiling via a binary install anyway, so we let it go. + self.library_dirs.append(os.path.join(sys.exec_prefix, 'libs')) + if sys.base_exec_prefix != sys.prefix: # Issue 16116 + self.library_dirs.append(os.path.join(sys.base_exec_prefix, 'libs')) + if self.debug: + self.build_temp = os.path.join(self.build_temp, "Debug") + else: + self.build_temp = os.path.join(self.build_temp, "Release") + + # Append the source distribution include and library directories, + # this allows distutils on windows to work in the source tree + self.include_dirs.append(os.path.dirname(get_config_h_filename())) + self.library_dirs.append(sys.base_exec_prefix) + + # Use the .lib files for the correct architecture + if self.plat_name == 'win32': + suffix = 'win32' + else: + # win-amd64 + suffix = self.plat_name[4:] + new_lib = os.path.join(sys.exec_prefix, 'PCbuild') + if suffix: + new_lib = os.path.join(new_lib, suffix) + self.library_dirs.append(new_lib) + + # For extensions under Cygwin, Python's library directory must be + # appended to library_dirs + if sys.platform[:6] == 'cygwin': + if not sysconfig.python_build: + # building third party extensions + self.library_dirs.append( + os.path.join( + sys.prefix, "lib", "python" + get_python_version(), "config" + ) + ) + else: + # building python standard extensions + self.library_dirs.append('.') + + self.library_dirs.extend(self._python_lib_dir(sysconfig)) + + # The argument parsing will result in self.define being a string, but + # it has to be a list of 2-tuples. All the preprocessor symbols + # specified by the 'define' option will be set to '1'. Multiple + # symbols can be separated with commas. + + if self.define: + defines = self.define.split(',') + self.define = [(symbol, '1') for symbol in defines] + + # The option for macros to undefine is also a string from the + # option parsing, but has to be a list. Multiple symbols can also + # be separated with commas here. + if self.undef: + self.undef = self.undef.split(',') + + if self.swig_opts is None: + self.swig_opts = [] + else: + self.swig_opts = self.swig_opts.split(' ') + + # Finally add the user include and library directories if requested + if self.user: + user_include = os.path.join(USER_BASE, "include") + user_lib = os.path.join(USER_BASE, "lib") + if os.path.isdir(user_include): + self.include_dirs.append(user_include) + if os.path.isdir(user_lib): + self.library_dirs.append(user_lib) + self.rpath.append(user_lib) + + if isinstance(self.parallel, str): + try: + self.parallel = int(self.parallel) + except ValueError: + raise DistutilsOptionError("parallel should be an integer") + + def run(self) -> None: # noqa: C901 + # 'self.extensions', as supplied by setup.py, is a list of + # Extension instances. See the documentation for Extension (in + # distutils.extension) for details. + # + # For backwards compatibility with Distutils 0.8.2 and earlier, we + # also allow the 'extensions' list to be a list of tuples: + # (ext_name, build_info) + # where build_info is a dictionary containing everything that + # Extension instances do except the name, with a few things being + # differently named. We convert these 2-tuples to Extension + # instances as needed. + + if not self.extensions: + return + + # If we were asked to build any C/C++ libraries, make sure that the + # directory where we put them is in the library search path for + # linking extensions. + if self.distribution.has_c_libraries(): + build_clib = self.get_finalized_command('build_clib') + self.libraries.extend(build_clib.get_library_names() or []) + self.library_dirs.append(build_clib.build_clib) + + # Setup the CCompiler object that we'll use to do all the + # compiling and linking + self.compiler = new_compiler( + compiler=self.compiler, + verbose=self.verbose, + force=self.force, + ) + customize_compiler(self.compiler) + # If we are cross-compiling, init the compiler now (if we are not + # cross-compiling, init would not hurt, but people may rely on + # late initialization of compiler even if they shouldn't...) + if os.name == 'nt' and self.plat_name != get_platform(): + self.compiler.initialize(self.plat_name) + + # The official Windows free threaded Python installer doesn't set + # Py_GIL_DISABLED because its pyconfig.h is shared with the + # default build, so define it here (pypa/setuptools#4662). + if os.name == 'nt' and is_freethreaded(): + self.compiler.define_macro('Py_GIL_DISABLED', '1') + + # And make sure that any compile/link-related options (which might + # come from the command-line or from the setup script) are set in + # that CCompiler object -- that way, they automatically apply to + # all compiling and linking done here. + if self.include_dirs is not None: + self.compiler.set_include_dirs(self.include_dirs) + if self.define is not None: + # 'define' option is a list of (name,value) tuples + for name, value in self.define: + self.compiler.define_macro(name, value) + if self.undef is not None: + for macro in self.undef: + self.compiler.undefine_macro(macro) + if self.libraries is not None: + self.compiler.set_libraries(self.libraries) + if self.library_dirs is not None: + self.compiler.set_library_dirs(self.library_dirs) + if self.rpath is not None: + self.compiler.set_runtime_library_dirs(self.rpath) + if self.link_objects is not None: + self.compiler.set_link_objects(self.link_objects) + + # Now actually compile and link everything. + self.build_extensions() + + def check_extensions_list(self, extensions) -> None: # noqa: C901 + """Ensure that the list of extensions (presumably provided as a + command option 'extensions') is valid, i.e. it is a list of + Extension objects. We also support the old-style list of 2-tuples, + where the tuples are (ext_name, build_info), which are converted to + Extension instances here. + + Raise DistutilsSetupError if the structure is invalid anywhere; + just returns otherwise. + """ + if not isinstance(extensions, list): + raise DistutilsSetupError( + "'ext_modules' option must be a list of Extension instances" + ) + + for i, ext in enumerate(extensions): + if isinstance(ext, Extension): + continue # OK! (assume type-checking done + # by Extension constructor) + + if not isinstance(ext, tuple) or len(ext) != 2: + raise DistutilsSetupError( + "each element of 'ext_modules' option must be an " + "Extension instance or 2-tuple" + ) + + ext_name, build_info = ext + + log.warning( + "old-style (ext_name, build_info) tuple found in " + "ext_modules for extension '%s' " + "-- please convert to Extension instance", + ext_name, + ) + + if not (isinstance(ext_name, str) and extension_name_re.match(ext_name)): + raise DistutilsSetupError( + "first element of each tuple in 'ext_modules' " + "must be the extension name (a string)" + ) + + if not isinstance(build_info, dict): + raise DistutilsSetupError( + "second element of each tuple in 'ext_modules' " + "must be a dictionary (build info)" + ) + + # OK, the (ext_name, build_info) dict is type-safe: convert it + # to an Extension instance. + ext = Extension(ext_name, build_info['sources']) + + # Easy stuff: one-to-one mapping from dict elements to + # instance attributes. + for key in ( + 'include_dirs', + 'library_dirs', + 'libraries', + 'extra_objects', + 'extra_compile_args', + 'extra_link_args', + ): + val = build_info.get(key) + if val is not None: + setattr(ext, key, val) + + # Medium-easy stuff: same syntax/semantics, different names. + ext.runtime_library_dirs = build_info.get('rpath') + if 'def_file' in build_info: + log.warning("'def_file' element of build info dict no longer supported") + + # Non-trivial stuff: 'macros' split into 'define_macros' + # and 'undef_macros'. + macros = build_info.get('macros') + if macros: + ext.define_macros = [] + ext.undef_macros = [] + for macro in macros: + if not (isinstance(macro, tuple) and len(macro) in (1, 2)): + raise DistutilsSetupError( + "'macros' element of build info dict must be 1- or 2-tuple" + ) + if len(macro) == 1: + ext.undef_macros.append(macro[0]) + elif len(macro) == 2: + ext.define_macros.append(macro) + + extensions[i] = ext + + def get_source_files(self): + self.check_extensions_list(self.extensions) + filenames = [] + + # Wouldn't it be neat if we knew the names of header files too... + for ext in self.extensions: + filenames.extend(ext.sources) + return filenames + + def get_outputs(self): + # Sanity check the 'extensions' list -- can't assume this is being + # done in the same run as a 'build_extensions()' call (in fact, we + # can probably assume that it *isn't*!). + self.check_extensions_list(self.extensions) + + # And build the list of output (built) filenames. Note that this + # ignores the 'inplace' flag, and assumes everything goes in the + # "build" tree. + return [self.get_ext_fullpath(ext.name) for ext in self.extensions] + + def build_extensions(self) -> None: + # First, sanity-check the 'extensions' list + self.check_extensions_list(self.extensions) + if self.parallel: + self._build_extensions_parallel() + else: + self._build_extensions_serial() + + def _build_extensions_parallel(self): + workers = self.parallel + if self.parallel is True: + workers = os.cpu_count() # may return None + try: + from concurrent.futures import ThreadPoolExecutor + except ImportError: + workers = None + + if workers is None: + self._build_extensions_serial() + return + + with ThreadPoolExecutor(max_workers=workers) as executor: + futures = [ + executor.submit(self.build_extension, ext) for ext in self.extensions + ] + for ext, fut in zip(self.extensions, futures): + with self._filter_build_errors(ext): + fut.result() + + def _build_extensions_serial(self): + for ext in self.extensions: + with self._filter_build_errors(ext): + self.build_extension(ext) + + @contextlib.contextmanager + def _filter_build_errors(self, ext): + try: + yield + except (CCompilerError, DistutilsError, CompileError) as e: + if not ext.optional: + raise + self.warn(f'building extension "{ext.name}" failed: {e}') + + def build_extension(self, ext) -> None: + sources = ext.sources + if sources is None or not isinstance(sources, (list, tuple)): + raise DistutilsSetupError( + f"in 'ext_modules' option (extension '{ext.name}'), " + "'sources' must be present and must be " + "a list of source filenames" + ) + # sort to make the resulting .so file build reproducible + sources = sorted(sources) + + ext_path = self.get_ext_fullpath(ext.name) + depends = sources + ext.depends + if not (self.force or newer_group(depends, ext_path, 'newer')): + log.debug("skipping '%s' extension (up-to-date)", ext.name) + return + else: + log.info("building '%s' extension", ext.name) + + # First, scan the sources for SWIG definition files (.i), run + # SWIG on 'em to create .c files, and modify the sources list + # accordingly. + sources = self.swig_sources(sources, ext) + + # Next, compile the source code to object files. + + # XXX not honouring 'define_macros' or 'undef_macros' -- the + # CCompiler API needs to change to accommodate this, and I + # want to do one thing at a time! + + # Two possible sources for extra compiler arguments: + # - 'extra_compile_args' in Extension object + # - CFLAGS environment variable (not particularly + # elegant, but people seem to expect it and I + # guess it's useful) + # The environment variable should take precedence, and + # any sensible compiler will give precedence to later + # command line args. Hence we combine them in order: + extra_args = ext.extra_compile_args or [] + + macros = ext.define_macros[:] + for undef in ext.undef_macros: + macros.append((undef,)) + + objects = self.compiler.compile( + sources, + output_dir=self.build_temp, + macros=macros, + include_dirs=ext.include_dirs, + debug=self.debug, + extra_postargs=extra_args, + depends=ext.depends, + ) + + # XXX outdated variable, kept here in case third-part code + # needs it. + self._built_objects = objects[:] + + # Now link the object files together into a "shared object" -- + # of course, first we have to figure out all the other things + # that go into the mix. + if ext.extra_objects: + objects.extend(ext.extra_objects) + extra_args = ext.extra_link_args or [] + + # Detect target language, if not provided + language = ext.language or self.compiler.detect_language(sources) + + self.compiler.link_shared_object( + objects, + ext_path, + libraries=self.get_libraries(ext), + library_dirs=ext.library_dirs, + runtime_library_dirs=ext.runtime_library_dirs, + extra_postargs=extra_args, + export_symbols=self.get_export_symbols(ext), + debug=self.debug, + build_temp=self.build_temp, + target_lang=language, + ) + + def swig_sources(self, sources, extension): + """Walk the list of source files in 'sources', looking for SWIG + interface (.i) files. Run SWIG on all that are found, and + return a modified 'sources' list with SWIG source files replaced + by the generated C (or C++) files. + """ + new_sources = [] + swig_sources = [] + swig_targets = {} + + # XXX this drops generated C/C++ files into the source tree, which + # is fine for developers who want to distribute the generated + # source -- but there should be an option to put SWIG output in + # the temp dir. + + if self.swig_cpp: + log.warning("--swig-cpp is deprecated - use --swig-opts=-c++") + + if ( + self.swig_cpp + or ('-c++' in self.swig_opts) + or ('-c++' in extension.swig_opts) + ): + target_ext = '.cpp' + else: + target_ext = '.c' + + for source in sources: + (base, ext) = os.path.splitext(source) + if ext == ".i": # SWIG interface file + new_sources.append(base + '_wrap' + target_ext) + swig_sources.append(source) + swig_targets[source] = new_sources[-1] + else: + new_sources.append(source) + + if not swig_sources: + return new_sources + + swig = self.swig or self.find_swig() + swig_cmd = [swig, "-python"] + swig_cmd.extend(self.swig_opts) + if self.swig_cpp: + swig_cmd.append("-c++") + + # Do not override commandline arguments + if not self.swig_opts: + swig_cmd.extend(extension.swig_opts) + + for source in swig_sources: + target = swig_targets[source] + log.info("swigging %s to %s", source, target) + self.spawn(swig_cmd + ["-o", target, source]) + + return new_sources + + def find_swig(self): + """Return the name of the SWIG executable. On Unix, this is + just "swig" -- it should be in the PATH. Tries a bit harder on + Windows. + """ + if os.name == "posix": + return "swig" + elif os.name == "nt": + # Look for SWIG in its standard installation directory on + # Windows (or so I presume!). If we find it there, great; + # if not, act like Unix and assume it's in the PATH. + for vers in ("1.3", "1.2", "1.1"): + fn = os.path.join(f"c:\\swig{vers}", "swig.exe") + if os.path.isfile(fn): + return fn + else: + return "swig.exe" + else: + raise DistutilsPlatformError( + f"I don't know how to find (much less run) SWIG on platform '{os.name}'" + ) + + # -- Name generators ----------------------------------------------- + # (extension names, filenames, whatever) + def get_ext_fullpath(self, ext_name: str) -> str: + """Returns the path of the filename for a given extension. + + The file is located in `build_lib` or directly in the package + (inplace option). + """ + fullname = self.get_ext_fullname(ext_name) + modpath = fullname.split('.') + filename = self.get_ext_filename(modpath[-1]) + + if not self.inplace: + # no further work needed + # returning : + # build_dir/package/path/filename + filename = os.path.join(*modpath[:-1] + [filename]) + return os.path.join(self.build_lib, filename) + + # the inplace option requires to find the package directory + # using the build_py command for that + package = '.'.join(modpath[0:-1]) + build_py = self.get_finalized_command('build_py') + package_dir = os.path.abspath(build_py.get_package_dir(package)) + + # returning + # package_dir/filename + return os.path.join(package_dir, filename) + + def get_ext_fullname(self, ext_name: str) -> str: + """Returns the fullname of a given extension name. + + Adds the `package.` prefix""" + if self.package is None: + return ext_name + else: + return self.package + '.' + ext_name + + def get_ext_filename(self, ext_name: str) -> str: + r"""Convert the name of an extension (eg. "foo.bar") into the name + of the file from which it will be loaded (eg. "foo/bar.so", or + "foo\bar.pyd"). + """ + from ..sysconfig import get_config_var + + ext_path = ext_name.split('.') + ext_suffix = get_config_var('EXT_SUFFIX') + return os.path.join(*ext_path) + ext_suffix + + def get_export_symbols(self, ext: Extension) -> list[str]: + """Return the list of symbols that a shared extension has to + export. This either uses 'ext.export_symbols' or, if it's not + provided, "PyInit_" + module_name. Only relevant on Windows, where + the .pyd file (DLL) must export the module "PyInit_" function. + """ + name = self._get_module_name_for_symbol(ext) + try: + # Unicode module name support as defined in PEP-489 + # https://peps.python.org/pep-0489/#export-hook-name + name.encode('ascii') + except UnicodeEncodeError: + suffix = 'U_' + name.encode('punycode').replace(b'-', b'_').decode('ascii') + else: + suffix = "_" + name + + initfunc_name = "PyInit" + suffix + if initfunc_name not in ext.export_symbols: + ext.export_symbols.append(initfunc_name) + return ext.export_symbols + + def _get_module_name_for_symbol(self, ext): + # Package name should be used for `__init__` modules + # https://github.com/python/cpython/issues/80074 + # https://github.com/pypa/setuptools/issues/4826 + parts = ext.name.split(".") + if parts[-1] == "__init__" and len(parts) >= 2: + return parts[-2] + return parts[-1] + + def get_libraries(self, ext: Extension) -> list[str]: # noqa: C901 + """Return the list of libraries to link against when building a + shared extension. On most platforms, this is just 'ext.libraries'; + on Windows, we add the Python library (eg. python20.dll). + """ + # The python library is always needed on Windows. For MSVC, this + # is redundant, since the library is mentioned in a pragma in + # pyconfig.h that MSVC groks. The other Windows compilers all seem + # to need it mentioned explicitly, though, so that's what we do. + # Append '_d' to the python import library on debug builds. + if sys.platform == "win32" and not is_mingw(): + from .._msvccompiler import MSVCCompiler + + if not isinstance(self.compiler, MSVCCompiler): + template = "python%d%d" + if self.debug: + template = template + '_d' + pythonlib = template % ( + sys.hexversion >> 24, + (sys.hexversion >> 16) & 0xFF, + ) + # don't extend ext.libraries, it may be shared with other + # extensions, it is a reference to the original list + return ext.libraries + [pythonlib] + else: + # On Android only the main executable and LD_PRELOADs are considered + # to be RTLD_GLOBAL, all the dependencies of the main executable + # remain RTLD_LOCAL and so the shared libraries must be linked with + # libpython when python is built with a shared python library (issue + # bpo-21536). + # On Cygwin (and if required, other POSIX-like platforms based on + # Windows like MinGW) it is simply necessary that all symbols in + # shared libraries are resolved at link time. + from ..sysconfig import get_config_var + + link_libpython = False + if get_config_var('Py_ENABLE_SHARED'): + # A native build on an Android device or on Cygwin + if hasattr(sys, 'getandroidapilevel'): + link_libpython = True + elif sys.platform == 'cygwin' or is_mingw(): + link_libpython = True + elif '_PYTHON_HOST_PLATFORM' in os.environ: + # We are cross-compiling for one of the relevant platforms + if get_config_var('ANDROID_API_LEVEL') != 0: + link_libpython = True + elif get_config_var('MACHDEP') == 'cygwin': + link_libpython = True + + if link_libpython: + ldversion = get_config_var('LDVERSION') + return ext.libraries + ['python' + ldversion] + + return ext.libraries diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/build_py.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/build_py.py new file mode 100644 index 0000000000000000000000000000000000000000..d6ec7d10d2a807e02f1856fcacf488057ec69081 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/build_py.py @@ -0,0 +1,404 @@ +"""distutils.command.build_py + +Implements the Distutils 'build_py' command.""" + +import glob +import importlib.util +import os +import sys +from distutils._log import log +from typing import ClassVar + +from ..core import Command +from ..errors import DistutilsFileError, DistutilsOptionError +from ..util import convert_path + + +class build_py(Command): + description = "\"build\" pure Python modules (copy to build directory)" + + user_options = [ + ('build-lib=', 'd', "directory to \"build\" (copy) to"), + ('compile', 'c', "compile .py to .pyc"), + ('no-compile', None, "don't compile .py files [default]"), + ( + 'optimize=', + 'O', + "also compile with optimization: -O1 for \"python -O\", " + "-O2 for \"python -OO\", and -O0 to disable [default: -O0]", + ), + ('force', 'f', "forcibly build everything (ignore file timestamps)"), + ] + + boolean_options: ClassVar[list[str]] = ['compile', 'force'] + negative_opt: ClassVar[dict[str, str]] = {'no-compile': 'compile'} + + def initialize_options(self): + self.build_lib = None + self.py_modules = None + self.package = None + self.package_data = None + self.package_dir = None + self.compile = False + self.optimize = 0 + self.force = None + + def finalize_options(self) -> None: + self.set_undefined_options( + 'build', ('build_lib', 'build_lib'), ('force', 'force') + ) + + # Get the distribution options that are aliases for build_py + # options -- list of packages and list of modules. + self.packages = self.distribution.packages + self.py_modules = self.distribution.py_modules + self.package_data = self.distribution.package_data + self.package_dir = {} + if self.distribution.package_dir: + for name, path in self.distribution.package_dir.items(): + self.package_dir[name] = convert_path(path) + self.data_files = self.get_data_files() + + # Ick, copied straight from install_lib.py (fancy_getopt needs a + # type system! Hell, *everything* needs a type system!!!) + if not isinstance(self.optimize, int): + try: + self.optimize = int(self.optimize) + assert 0 <= self.optimize <= 2 + except (ValueError, AssertionError): + raise DistutilsOptionError("optimize must be 0, 1, or 2") + + def run(self) -> None: + # XXX copy_file by default preserves atime and mtime. IMHO this is + # the right thing to do, but perhaps it should be an option -- in + # particular, a site administrator might want installed files to + # reflect the time of installation rather than the last + # modification time before the installed release. + + # XXX copy_file by default preserves mode, which appears to be the + # wrong thing to do: if a file is read-only in the working + # directory, we want it to be installed read/write so that the next + # installation of the same module distribution can overwrite it + # without problems. (This might be a Unix-specific issue.) Thus + # we turn off 'preserve_mode' when copying to the build directory, + # since the build directory is supposed to be exactly what the + # installation will look like (ie. we preserve mode when + # installing). + + # Two options control which modules will be installed: 'packages' + # and 'py_modules'. The former lets us work with whole packages, not + # specifying individual modules at all; the latter is for + # specifying modules one-at-a-time. + + if self.py_modules: + self.build_modules() + if self.packages: + self.build_packages() + self.build_package_data() + + self.byte_compile(self.get_outputs(include_bytecode=False)) + + def get_data_files(self): + """Generate list of '(package,src_dir,build_dir,filenames)' tuples""" + data = [] + if not self.packages: + return data + for package in self.packages: + # Locate package source directory + src_dir = self.get_package_dir(package) + + # Compute package build directory + build_dir = os.path.join(*([self.build_lib] + package.split('.'))) + + # Length of path to strip from found files + plen = 0 + if src_dir: + plen = len(src_dir) + 1 + + # Strip directory from globbed filenames + filenames = [file[plen:] for file in self.find_data_files(package, src_dir)] + data.append((package, src_dir, build_dir, filenames)) + return data + + def find_data_files(self, package, src_dir): + """Return filenames for package's data files in 'src_dir'""" + globs = self.package_data.get('', []) + self.package_data.get(package, []) + files = [] + for pattern in globs: + # Each pattern has to be converted to a platform-specific path + filelist = glob.glob( + os.path.join(glob.escape(src_dir), convert_path(pattern)) + ) + # Files that match more than one pattern are only added once + files.extend([ + fn for fn in filelist if fn not in files and os.path.isfile(fn) + ]) + return files + + def build_package_data(self) -> None: + """Copy data files into build directory""" + for _package, src_dir, build_dir, filenames in self.data_files: + for filename in filenames: + target = os.path.join(build_dir, filename) + self.mkpath(os.path.dirname(target)) + self.copy_file( + os.path.join(src_dir, filename), target, preserve_mode=False + ) + + def get_package_dir(self, package): + """Return the directory, relative to the top of the source + distribution, where package 'package' should be found + (at least according to the 'package_dir' option, if any).""" + path = package.split('.') + + if not self.package_dir: + if path: + return os.path.join(*path) + else: + return '' + else: + tail = [] + while path: + try: + pdir = self.package_dir['.'.join(path)] + except KeyError: + tail.insert(0, path[-1]) + del path[-1] + else: + tail.insert(0, pdir) + return os.path.join(*tail) + else: + # Oops, got all the way through 'path' without finding a + # match in package_dir. If package_dir defines a directory + # for the root (nameless) package, then fallback on it; + # otherwise, we might as well have not consulted + # package_dir at all, as we just use the directory implied + # by 'tail' (which should be the same as the original value + # of 'path' at this point). + pdir = self.package_dir.get('') + if pdir is not None: + tail.insert(0, pdir) + + if tail: + return os.path.join(*tail) + else: + return '' + + def check_package(self, package, package_dir): + # Empty dir name means current directory, which we can probably + # assume exists. Also, os.path.exists and isdir don't know about + # my "empty string means current dir" convention, so we have to + # circumvent them. + if package_dir != "": + if not os.path.exists(package_dir): + raise DistutilsFileError( + f"package directory '{package_dir}' does not exist" + ) + if not os.path.isdir(package_dir): + raise DistutilsFileError( + f"supposed package directory '{package_dir}' exists, " + "but is not a directory" + ) + + # Directories without __init__.py are namespace packages (PEP 420). + if package: + init_py = os.path.join(package_dir, "__init__.py") + if os.path.isfile(init_py): + return init_py + + # Either not in a package at all (__init__.py not expected), or + # __init__.py doesn't exist -- so don't return the filename. + return None + + def check_module(self, module, module_file): + if not os.path.isfile(module_file): + log.warning("file %s (for module %s) not found", module_file, module) + return False + else: + return True + + def find_package_modules(self, package, package_dir): + self.check_package(package, package_dir) + module_files = glob.glob(os.path.join(glob.escape(package_dir), "*.py")) + modules = [] + setup_script = os.path.abspath(self.distribution.script_name) + + for f in module_files: + abs_f = os.path.abspath(f) + if abs_f != setup_script: + module = os.path.splitext(os.path.basename(f))[0] + modules.append((package, module, f)) + else: + self.debug_print(f"excluding {setup_script}") + return modules + + def find_modules(self): + """Finds individually-specified Python modules, ie. those listed by + module name in 'self.py_modules'. Returns a list of tuples (package, + module_base, filename): 'package' is a tuple of the path through + package-space to the module; 'module_base' is the bare (no + packages, no dots) module name, and 'filename' is the path to the + ".py" file (relative to the distribution root) that implements the + module. + """ + # Map package names to tuples of useful info about the package: + # (package_dir, checked) + # package_dir - the directory where we'll find source files for + # this package + # checked - true if we have checked that the package directory + # is valid (exists, contains __init__.py, ... ?) + packages = {} + + # List of (package, module, filename) tuples to return + modules = [] + + # We treat modules-in-packages almost the same as toplevel modules, + # just the "package" for a toplevel is empty (either an empty + # string or empty list, depending on context). Differences: + # - don't check for __init__.py in directory for empty package + for module in self.py_modules: + path = module.split('.') + package = '.'.join(path[0:-1]) + module_base = path[-1] + + try: + (package_dir, checked) = packages[package] + except KeyError: + package_dir = self.get_package_dir(package) + checked = False + + if not checked: + init_py = self.check_package(package, package_dir) + packages[package] = (package_dir, 1) + if init_py: + modules.append((package, "__init__", init_py)) + + # XXX perhaps we should also check for just .pyc files + # (so greedy closed-source bastards can distribute Python + # modules too) + module_file = os.path.join(package_dir, module_base + ".py") + if not self.check_module(module, module_file): + continue + + modules.append((package, module_base, module_file)) + + return modules + + def find_all_modules(self): + """Compute the list of all modules that will be built, whether + they are specified one-module-at-a-time ('self.py_modules') or + by whole packages ('self.packages'). Return a list of tuples + (package, module, module_file), just like 'find_modules()' and + 'find_package_modules()' do.""" + modules = [] + if self.py_modules: + modules.extend(self.find_modules()) + if self.packages: + for package in self.packages: + package_dir = self.get_package_dir(package) + m = self.find_package_modules(package, package_dir) + modules.extend(m) + return modules + + def get_source_files(self): + return [module[-1] for module in self.find_all_modules()] + + def get_module_outfile(self, build_dir, package, module): + outfile_path = [build_dir] + list(package) + [module + ".py"] + return os.path.join(*outfile_path) + + def get_outputs(self, include_bytecode: bool = True) -> list[str]: + modules = self.find_all_modules() + outputs = [] + for package, module, _module_file in modules: + package = package.split('.') + filename = self.get_module_outfile(self.build_lib, package, module) + outputs.append(filename) + if include_bytecode: + if self.compile: + outputs.append( + importlib.util.cache_from_source(filename, optimization='') + ) + if self.optimize > 0: + outputs.append( + importlib.util.cache_from_source( + filename, optimization=self.optimize + ) + ) + + outputs += [ + os.path.join(build_dir, filename) + for package, src_dir, build_dir, filenames in self.data_files + for filename in filenames + ] + + return outputs + + def build_module(self, module, module_file, package): + if isinstance(package, str): + package = package.split('.') + elif not isinstance(package, (list, tuple)): + raise TypeError( + "'package' must be a string (dot-separated), list, or tuple" + ) + + # Now put the module source file into the "build" area -- this is + # easy, we just copy it somewhere under self.build_lib (the build + # directory for Python source). + outfile = self.get_module_outfile(self.build_lib, package, module) + dir = os.path.dirname(outfile) + self.mkpath(dir) + return self.copy_file(module_file, outfile, preserve_mode=False) + + def build_modules(self) -> None: + modules = self.find_modules() + for package, module, module_file in modules: + # Now "build" the module -- ie. copy the source file to + # self.build_lib (the build directory for Python source). + # (Actually, it gets copied to the directory for this package + # under self.build_lib.) + self.build_module(module, module_file, package) + + def build_packages(self) -> None: + for package in self.packages: + # Get list of (package, module, module_file) tuples based on + # scanning the package directory. 'package' is only included + # in the tuple so that 'find_modules()' and + # 'find_package_tuples()' have a consistent interface; it's + # ignored here (apart from a sanity check). Also, 'module' is + # the *unqualified* module name (ie. no dots, no package -- we + # already know its package!), and 'module_file' is the path to + # the .py file, relative to the current directory + # (ie. including 'package_dir'). + package_dir = self.get_package_dir(package) + modules = self.find_package_modules(package, package_dir) + + # Now loop over the modules we found, "building" each one (just + # copy it to self.build_lib). + for package_, module, module_file in modules: + assert package == package_ + self.build_module(module, module_file, package) + + def byte_compile(self, files) -> None: + if sys.dont_write_bytecode: + self.warn('byte-compiling is disabled, skipping.') + return + + from ..util import byte_compile + + prefix = self.build_lib + if prefix[-1] != os.sep: + prefix = prefix + os.sep + + # XXX this code is essentially the same as the 'byte_compile() + # method of the "install_lib" command, except for the determination + # of the 'prefix' string. Hmmm. + if self.compile: + byte_compile(files, optimize=0, force=self.force, prefix=prefix) + if self.optimize > 0: + byte_compile( + files, + optimize=self.optimize, + force=self.force, + prefix=prefix, + ) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/build_scripts.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/build_scripts.py new file mode 100644 index 0000000000000000000000000000000000000000..0b551d11be0200b4e9c620d1af387ff7c2752096 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/build_scripts.py @@ -0,0 +1,150 @@ +"""distutils.command.build_scripts + +Implements the Distutils 'build_scripts' command.""" + +import os +import re +import tokenize +from distutils._log import log +from stat import ST_MODE +from typing import ClassVar + +from .._modified import newer +from ..core import Command +from ..util import convert_path + +shebang_pattern = re.compile('^#!.*python[0-9.]*([ \t].*)?$') +""" +Pattern matching a Python interpreter indicated in first line of a script. +""" + +# for Setuptools compatibility +first_line_re = shebang_pattern + + +class build_scripts(Command): + description = "\"build\" scripts (copy and fixup #! line)" + + user_options: ClassVar[list[tuple[str, str, str]]] = [ + ('build-dir=', 'd', "directory to \"build\" (copy) to"), + ('force', 'f', "forcibly build everything (ignore file timestamps"), + ('executable=', 'e', "specify final destination interpreter path"), + ] + + boolean_options: ClassVar[list[str]] = ['force'] + + def initialize_options(self): + self.build_dir = None + self.scripts = None + self.force = None + self.executable = None + + def finalize_options(self): + self.set_undefined_options( + 'build', + ('build_scripts', 'build_dir'), + ('force', 'force'), + ('executable', 'executable'), + ) + self.scripts = self.distribution.scripts + + def get_source_files(self): + return self.scripts + + def run(self): + if not self.scripts: + return + self.copy_scripts() + + def copy_scripts(self): + """ + Copy each script listed in ``self.scripts``. + + If a script is marked as a Python script (first line matches + 'shebang_pattern', i.e. starts with ``#!`` and contains + "python"), then adjust in the copy the first line to refer to + the current Python interpreter. + """ + self.mkpath(self.build_dir) + outfiles = [] + updated_files = [] + for script in self.scripts: + self._copy_script(script, outfiles, updated_files) + + self._change_modes(outfiles) + + return outfiles, updated_files + + def _copy_script(self, script, outfiles, updated_files): + shebang_match = None + script = convert_path(script) + outfile = os.path.join(self.build_dir, os.path.basename(script)) + outfiles.append(outfile) + + if not self.force and not newer(script, outfile): + log.debug("not copying %s (up-to-date)", script) + return + + # Always open the file, but ignore failures in dry-run mode + # in order to attempt to copy directly. + f = tokenize.open(script) + + first_line = f.readline() + if not first_line: + self.warn(f"{script} is an empty file (skipping)") + return + + shebang_match = shebang_pattern.match(first_line) + + updated_files.append(outfile) + if shebang_match: + log.info("copying and adjusting %s -> %s", script, self.build_dir) + post_interp = shebang_match.group(1) or '' + shebang = "#!" + self.executable + post_interp + "\n" + self._validate_shebang(shebang, f.encoding) + with open(outfile, "w", encoding=f.encoding) as outf: + outf.write(shebang) + outf.writelines(f.readlines()) + if f: + f.close() + else: + if f: + f.close() + self.copy_file(script, outfile) + + def _change_modes(self, outfiles): + if os.name != 'posix': + return + + for file in outfiles: + self._change_mode(file) + + def _change_mode(self, file): + oldmode = os.stat(file)[ST_MODE] & 0o7777 + newmode = (oldmode | 0o555) & 0o7777 + if newmode != oldmode: + log.info("changing mode of %s from %o to %o", file, oldmode, newmode) + os.chmod(file, newmode) + + @staticmethod + def _validate_shebang(shebang, encoding): + # Python parser starts to read a script using UTF-8 until + # it gets a #coding:xxx cookie. The shebang has to be the + # first line of a file, the #coding:xxx cookie cannot be + # written before. So the shebang has to be encodable to + # UTF-8. + try: + shebang.encode('utf-8') + except UnicodeEncodeError: + raise ValueError(f"The shebang ({shebang!r}) is not encodable to utf-8") + + # If the script is encoded to a custom encoding (use a + # #coding:xxx cookie), the shebang has to be encodable to + # the script encoding too. + try: + shebang.encode(encoding) + except UnicodeEncodeError: + raise ValueError( + f"The shebang ({shebang!r}) is not encodable " + f"to the script encoding ({encoding})" + ) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/check.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/check.py new file mode 100644 index 0000000000000000000000000000000000000000..58a823dd3904cf105ed432e458a45d94948fbb4c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/check.py @@ -0,0 +1,152 @@ +"""distutils.command.check + +Implements the Distutils 'check' command. +""" + +import contextlib +from typing import ClassVar + +from ..core import Command +from ..errors import DistutilsSetupError + +with contextlib.suppress(ImportError): + import docutils.frontend + import docutils.nodes + import docutils.parsers.rst + import docutils.utils + + class SilentReporter(docutils.utils.Reporter): + def __init__( + self, + source, + report_level, + halt_level, + stream=None, + debug=False, + encoding='ascii', + error_handler='replace', + ): + self.messages = [] + super().__init__( + source, report_level, halt_level, stream, debug, encoding, error_handler + ) + + def system_message(self, level, message, *children, **kwargs): + self.messages.append((level, message, children, kwargs)) + return docutils.nodes.system_message( + message, *children, level=level, type=self.levels[level], **kwargs + ) + + +class check(Command): + """This command checks the meta-data of the package.""" + + description = "perform some checks on the package" + user_options: ClassVar[list[tuple[str, str, str]]] = [ + ('metadata', 'm', 'Verify meta-data'), + ( + 'restructuredtext', + 'r', + 'Checks if long string meta-data syntax are reStructuredText-compliant', + ), + ('strict', 's', 'Will exit with an error if a check fails'), + ] + + boolean_options: ClassVar[list[str]] = ['metadata', 'restructuredtext', 'strict'] + + def initialize_options(self): + """Sets default values for options.""" + self.restructuredtext = False + self.metadata = 1 + self.strict = False + self._warnings = 0 + + def finalize_options(self): + pass + + def warn(self, msg): + """Counts the number of warnings that occurs.""" + self._warnings += 1 + return Command.warn(self, msg) + + def run(self): + """Runs the command.""" + # perform the various tests + if self.metadata: + self.check_metadata() + if self.restructuredtext: + if 'docutils' in globals(): + try: + self.check_restructuredtext() + except TypeError as exc: + raise DistutilsSetupError(str(exc)) + elif self.strict: + raise DistutilsSetupError('The docutils package is needed.') + + # let's raise an error in strict mode, if we have at least + # one warning + if self.strict and self._warnings > 0: + raise DistutilsSetupError('Please correct your package.') + + def check_metadata(self): + """Ensures that all required elements of meta-data are supplied. + + Required fields: + name, version + + Warns if any are missing. + """ + metadata = self.distribution.metadata + + missing = [ + attr for attr in ('name', 'version') if not getattr(metadata, attr, None) + ] + + if missing: + self.warn("missing required meta-data: {}".format(', '.join(missing))) + + def check_restructuredtext(self): + """Checks if the long string fields are reST-compliant.""" + data = self.distribution.get_long_description() + for warning in self._check_rst_data(data): + line = warning[-1].get('line') + if line is None: + warning = warning[1] + else: + warning = f'{warning[1]} (line {line})' + self.warn(warning) + + def _check_rst_data(self, data): + """Returns warnings when the provided data doesn't compile.""" + # the include and csv_table directives need this to be a path + source_path = self.distribution.script_name or 'setup.py' + parser = docutils.parsers.rst.Parser() + settings = docutils.frontend.OptionParser( + components=(docutils.parsers.rst.Parser,) + ).get_default_values() + settings.tab_width = 4 + settings.pep_references = None + settings.rfc_references = None + reporter = SilentReporter( + source_path, + settings.report_level, + settings.halt_level, + stream=settings.warning_stream, + debug=settings.debug, + encoding=settings.error_encoding, + error_handler=settings.error_encoding_error_handler, + ) + + document = docutils.nodes.document(settings, reporter, source=source_path) + document.note_source(source_path, -1) + try: + parser.parse(data, document) + except (AttributeError, TypeError) as e: + reporter.messages.append(( + -1, + f'Could not finish the parsing: {e}.', + '', + {}, + )) + + return reporter.messages diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/clean.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/clean.py new file mode 100644 index 0000000000000000000000000000000000000000..fc1711be8ef51e2bcd5fe2742588f95a65bcd153 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/clean.py @@ -0,0 +1,76 @@ +"""distutils.command.clean + +Implements the Distutils 'clean' command.""" + +# contributed by Bastian Kleineidam <calvin@cs.uni-sb.de>, added 2000-03-18 + +import os +from distutils._log import log +from typing import ClassVar + +from ..core import Command +from ..dir_util import remove_tree + + +class clean(Command): + description = "clean up temporary files from 'build' command" + user_options = [ + ('build-base=', 'b', "base build directory [default: 'build.build-base']"), + ( + 'build-lib=', + None, + "build directory for all modules [default: 'build.build-lib']", + ), + ('build-temp=', 't', "temporary build directory [default: 'build.build-temp']"), + ( + 'build-scripts=', + None, + "build directory for scripts [default: 'build.build-scripts']", + ), + ('bdist-base=', None, "temporary directory for built distributions"), + ('all', 'a', "remove all build output, not just temporary by-products"), + ] + + boolean_options: ClassVar[list[str]] = ['all'] + + def initialize_options(self): + self.build_base = None + self.build_lib = None + self.build_temp = None + self.build_scripts = None + self.bdist_base = None + self.all = None + + def finalize_options(self): + self.set_undefined_options( + 'build', + ('build_base', 'build_base'), + ('build_lib', 'build_lib'), + ('build_scripts', 'build_scripts'), + ('build_temp', 'build_temp'), + ) + self.set_undefined_options('bdist', ('bdist_base', 'bdist_base')) + + def run(self): + # remove the build/temp.<plat> directory (unless it's already + # gone) + if os.path.exists(self.build_temp): + remove_tree(self.build_temp) + else: + log.debug("'%s' does not exist -- can't clean it", self.build_temp) + + if self.all: + # remove build directories + for directory in (self.build_lib, self.bdist_base, self.build_scripts): + if os.path.exists(directory): + remove_tree(directory) + else: + log.warning("'%s' does not exist -- can't clean it", directory) + + # just for the heck of it, try to remove the base build directory: + # we might have emptied it right now, but if not we don't care + try: + os.rmdir(self.build_base) + log.info("removing '%s'", self.build_base) + except OSError: + pass diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/config.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/config.py new file mode 100644 index 0000000000000000000000000000000000000000..9818418f2675125631e7d9d1ad74c30487e9dd5b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/config.py @@ -0,0 +1,348 @@ +"""distutils.command.config + +Implements the Distutils 'config' command, a (mostly) empty command class +that exists mainly to be sub-classed by specific module distributions and +applications. The idea is that while every "config" command is different, +at least they're all named the same, and users always see "config" in the +list of standard commands. Also, this is a good place to put common +configure-like tasks: "try to compile this C code", or "figure out where +this header file lives". +""" + +from __future__ import annotations + +import os +import pathlib +import re +from collections.abc import Sequence +from distutils._log import log + +from ..ccompiler import CCompiler, CompileError, LinkError, new_compiler +from ..core import Command +from ..errors import DistutilsExecError +from ..sysconfig import customize_compiler + +LANG_EXT = {"c": ".c", "c++": ".cxx"} + + +class config(Command): + description = "prepare to build" + + user_options = [ + ('compiler=', None, "specify the compiler type"), + ('cc=', None, "specify the compiler executable"), + ('include-dirs=', 'I', "list of directories to search for header files"), + ('define=', 'D', "C preprocessor macros to define"), + ('undef=', 'U', "C preprocessor macros to undefine"), + ('libraries=', 'l', "external C libraries to link with"), + ('library-dirs=', 'L', "directories to search for external C libraries"), + ('noisy', None, "show every action (compile, link, run, ...) taken"), + ( + 'dump-source', + None, + "dump generated source files before attempting to compile them", + ), + ] + + # The three standard command methods: since the "config" command + # does nothing by default, these are empty. + + def initialize_options(self): + self.compiler = None + self.cc = None + self.include_dirs = None + self.libraries = None + self.library_dirs = None + + # maximal output for now + self.noisy = 1 + self.dump_source = 1 + + # list of temporary files generated along-the-way that we have + # to clean at some point + self.temp_files = [] + + def finalize_options(self): + if self.include_dirs is None: + self.include_dirs = self.distribution.include_dirs or [] + elif isinstance(self.include_dirs, str): + self.include_dirs = self.include_dirs.split(os.pathsep) + + if self.libraries is None: + self.libraries = [] + elif isinstance(self.libraries, str): + self.libraries = [self.libraries] + + if self.library_dirs is None: + self.library_dirs = [] + elif isinstance(self.library_dirs, str): + self.library_dirs = self.library_dirs.split(os.pathsep) + + def run(self): + pass + + # Utility methods for actual "config" commands. The interfaces are + # loosely based on Autoconf macros of similar names. Sub-classes + # may use these freely. + + def _check_compiler(self): + """Check that 'self.compiler' really is a CCompiler object; + if not, make it one. + """ + if not isinstance(self.compiler, CCompiler): + self.compiler = new_compiler(compiler=self.compiler, force=True) + customize_compiler(self.compiler) + if self.include_dirs: + self.compiler.set_include_dirs(self.include_dirs) + if self.libraries: + self.compiler.set_libraries(self.libraries) + if self.library_dirs: + self.compiler.set_library_dirs(self.library_dirs) + + def _gen_temp_sourcefile(self, body, headers, lang): + filename = "_configtest" + LANG_EXT[lang] + with open(filename, "w", encoding='utf-8') as file: + if headers: + for header in headers: + file.write(f"#include <{header}>\n") + file.write("\n") + file.write(body) + if body[-1] != "\n": + file.write("\n") + return filename + + def _preprocess(self, body, headers, include_dirs, lang): + src = self._gen_temp_sourcefile(body, headers, lang) + out = "_configtest.i" + self.temp_files.extend([src, out]) + self.compiler.preprocess(src, out, include_dirs=include_dirs) + return (src, out) + + def _compile(self, body, headers, include_dirs, lang): + src = self._gen_temp_sourcefile(body, headers, lang) + if self.dump_source: + dump_file(src, f"compiling '{src}':") + (obj,) = self.compiler.object_filenames([src]) + self.temp_files.extend([src, obj]) + self.compiler.compile([src], include_dirs=include_dirs) + return (src, obj) + + def _link(self, body, headers, include_dirs, libraries, library_dirs, lang): + (src, obj) = self._compile(body, headers, include_dirs, lang) + prog = os.path.splitext(os.path.basename(src))[0] + self.compiler.link_executable( + [obj], + prog, + libraries=libraries, + library_dirs=library_dirs, + target_lang=lang, + ) + + if self.compiler.exe_extension is not None: + prog = prog + self.compiler.exe_extension + self.temp_files.append(prog) + + return (src, obj, prog) + + def _clean(self, *filenames): + if not filenames: + filenames = self.temp_files + self.temp_files = [] + log.info("removing: %s", ' '.join(filenames)) + for filename in filenames: + try: + os.remove(filename) + except OSError: + pass + + # XXX need access to the header search path and maybe default macros. + + def try_cpp(self, body=None, headers=None, include_dirs=None, lang="c"): + """Construct a source file from 'body' (a string containing lines + of C/C++ code) and 'headers' (a list of header files to include) + and run it through the preprocessor. Return true if the + preprocessor succeeded, false if there were any errors. + ('body' probably isn't of much use, but what the heck.) + """ + self._check_compiler() + ok = True + try: + self._preprocess(body, headers, include_dirs, lang) + except CompileError: + ok = False + + self._clean() + return ok + + def search_cpp(self, pattern, body=None, headers=None, include_dirs=None, lang="c"): + """Construct a source file (just like 'try_cpp()'), run it through + the preprocessor, and return true if any line of the output matches + 'pattern'. 'pattern' should either be a compiled regex object or a + string containing a regex. If both 'body' and 'headers' are None, + preprocesses an empty file -- which can be useful to determine the + symbols the preprocessor and compiler set by default. + """ + self._check_compiler() + src, out = self._preprocess(body, headers, include_dirs, lang) + + if isinstance(pattern, str): + pattern = re.compile(pattern) + + with open(out, encoding='utf-8') as file: + match = any(pattern.search(line) for line in file) + + self._clean() + return match + + def try_compile(self, body, headers=None, include_dirs=None, lang="c"): + """Try to compile a source file built from 'body' and 'headers'. + Return true on success, false otherwise. + """ + self._check_compiler() + try: + self._compile(body, headers, include_dirs, lang) + ok = True + except CompileError: + ok = False + + log.info(ok and "success!" or "failure.") + self._clean() + return ok + + def try_link( + self, + body, + headers=None, + include_dirs=None, + libraries=None, + library_dirs=None, + lang="c", + ): + """Try to compile and link a source file, built from 'body' and + 'headers', to executable form. Return true on success, false + otherwise. + """ + self._check_compiler() + try: + self._link(body, headers, include_dirs, libraries, library_dirs, lang) + ok = True + except (CompileError, LinkError): + ok = False + + log.info(ok and "success!" or "failure.") + self._clean() + return ok + + def try_run( + self, + body, + headers=None, + include_dirs=None, + libraries=None, + library_dirs=None, + lang="c", + ): + """Try to compile, link to an executable, and run a program + built from 'body' and 'headers'. Return true on success, false + otherwise. + """ + self._check_compiler() + try: + src, obj, exe = self._link( + body, headers, include_dirs, libraries, library_dirs, lang + ) + self.spawn([exe]) + ok = True + except (CompileError, LinkError, DistutilsExecError): + ok = False + + log.info(ok and "success!" or "failure.") + self._clean() + return ok + + # -- High-level methods -------------------------------------------- + # (these are the ones that are actually likely to be useful + # when implementing a real-world config command!) + + def check_func( + self, + func, + headers=None, + include_dirs=None, + libraries=None, + library_dirs=None, + decl=False, + call=False, + ): + """Determine if function 'func' is available by constructing a + source file that refers to 'func', and compiles and links it. + If everything succeeds, returns true; otherwise returns false. + + The constructed source file starts out by including the header + files listed in 'headers'. If 'decl' is true, it then declares + 'func' (as "int func()"); you probably shouldn't supply 'headers' + and set 'decl' true in the same call, or you might get errors about + a conflicting declarations for 'func'. Finally, the constructed + 'main()' function either references 'func' or (if 'call' is true) + calls it. 'libraries' and 'library_dirs' are used when + linking. + """ + self._check_compiler() + body = [] + if decl: + body.append(f"int {func} ();") + body.append("int main () {") + if call: + body.append(f" {func}();") + else: + body.append(f" {func};") + body.append("}") + body = "\n".join(body) + "\n" + + return self.try_link(body, headers, include_dirs, libraries, library_dirs) + + def check_lib( + self, + library, + library_dirs=None, + headers=None, + include_dirs=None, + other_libraries: Sequence[str] = [], + ): + """Determine if 'library' is available to be linked against, + without actually checking that any particular symbols are provided + by it. 'headers' will be used in constructing the source file to + be compiled, but the only effect of this is to check if all the + header files listed are available. Any libraries listed in + 'other_libraries' will be included in the link, in case 'library' + has symbols that depend on other libraries. + """ + self._check_compiler() + return self.try_link( + "int main (void) { }", + headers, + include_dirs, + [library] + list(other_libraries), + library_dirs, + ) + + def check_header(self, header, include_dirs=None, library_dirs=None, lang="c"): + """Determine if the system header file named by 'header_file' + exists and can be found by the preprocessor; return true if so, + false otherwise. + """ + return self.try_cpp( + body="/* No body */", headers=[header], include_dirs=include_dirs + ) + + +def dump_file(filename, head=None): + """Dumps a file content into log.info. + + If head is not None, will be dumped before the file content. + """ + if head is None: + log.info('%s', filename) + else: + log.info(head) + log.info(pathlib.Path(filename).read_text(encoding='utf-8')) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install.py new file mode 100644 index 0000000000000000000000000000000000000000..dc17e56a8070b26f0e3d09c82250e006f1aed826 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install.py @@ -0,0 +1,805 @@ +"""distutils.command.install + +Implements the Distutils 'install' command.""" + +from __future__ import annotations + +import collections +import contextlib +import itertools +import os +import sys +import sysconfig +from distutils._log import log +from site import USER_BASE, USER_SITE +from typing import ClassVar + +from ..core import Command +from ..debug import DEBUG +from ..errors import DistutilsOptionError, DistutilsPlatformError +from ..file_util import write_file +from ..sysconfig import get_config_vars +from ..util import change_root, convert_path, get_platform, subst_vars +from . import _framework_compat as fw + +HAS_USER_SITE = True + +WINDOWS_SCHEME = { + 'purelib': '{base}/Lib/site-packages', + 'platlib': '{base}/Lib/site-packages', + 'headers': '{base}/Include/{dist_name}', + 'scripts': '{base}/Scripts', + 'data': '{base}', +} + +INSTALL_SCHEMES = { + 'posix_prefix': { + 'purelib': '{base}/lib/{implementation_lower}{py_version_short}/site-packages', + 'platlib': '{platbase}/{platlibdir}/{implementation_lower}' + '{py_version_short}/site-packages', + 'headers': '{base}/include/{implementation_lower}' + '{py_version_short}{abiflags}/{dist_name}', + 'scripts': '{base}/bin', + 'data': '{base}', + }, + 'posix_home': { + 'purelib': '{base}/lib/{implementation_lower}', + 'platlib': '{base}/{platlibdir}/{implementation_lower}', + 'headers': '{base}/include/{implementation_lower}/{dist_name}', + 'scripts': '{base}/bin', + 'data': '{base}', + }, + 'nt': WINDOWS_SCHEME, + 'pypy': { + 'purelib': '{base}/site-packages', + 'platlib': '{base}/site-packages', + 'headers': '{base}/include/{dist_name}', + 'scripts': '{base}/bin', + 'data': '{base}', + }, + 'pypy_nt': { + 'purelib': '{base}/site-packages', + 'platlib': '{base}/site-packages', + 'headers': '{base}/include/{dist_name}', + 'scripts': '{base}/Scripts', + 'data': '{base}', + }, +} + +# user site schemes +if HAS_USER_SITE: + INSTALL_SCHEMES['nt_user'] = { + 'purelib': '{usersite}', + 'platlib': '{usersite}', + 'headers': '{userbase}/{implementation}{py_version_nodot_plat}' + '/Include/{dist_name}', + 'scripts': '{userbase}/{implementation}{py_version_nodot_plat}/Scripts', + 'data': '{userbase}', + } + + INSTALL_SCHEMES['posix_user'] = { + 'purelib': '{usersite}', + 'platlib': '{usersite}', + 'headers': '{userbase}/include/{implementation_lower}' + '{py_version_short}{abiflags}/{dist_name}', + 'scripts': '{userbase}/bin', + 'data': '{userbase}', + } + + +INSTALL_SCHEMES.update(fw.schemes) + + +# The keys to an installation scheme; if any new types of files are to be +# installed, be sure to add an entry to every installation scheme above, +# and to SCHEME_KEYS here. +SCHEME_KEYS = ('purelib', 'platlib', 'headers', 'scripts', 'data') + + +def _load_sysconfig_schemes(): + with contextlib.suppress(AttributeError): + return { + scheme: sysconfig.get_paths(scheme, expand=False) + for scheme in sysconfig.get_scheme_names() + } + + +def _load_schemes(): + """ + Extend default schemes with schemes from sysconfig. + """ + + sysconfig_schemes = _load_sysconfig_schemes() or {} + + return { + scheme: { + **INSTALL_SCHEMES.get(scheme, {}), + **sysconfig_schemes.get(scheme, {}), + } + for scheme in set(itertools.chain(INSTALL_SCHEMES, sysconfig_schemes)) + } + + +def _get_implementation(): + if hasattr(sys, 'pypy_version_info'): + return 'PyPy' + else: + return 'Python' + + +def _select_scheme(ob, name): + scheme = _inject_headers(name, _load_scheme(_resolve_scheme(name))) + vars(ob).update(_remove_set(ob, _scheme_attrs(scheme))) + + +def _remove_set(ob, attrs): + """ + Include only attrs that are None in ob. + """ + return {key: value for key, value in attrs.items() if getattr(ob, key) is None} + + +def _resolve_scheme(name): + os_name, sep, key = name.partition('_') + try: + resolved = sysconfig.get_preferred_scheme(key) + except Exception: + resolved = fw.scheme(name) + return resolved + + +def _load_scheme(name): + return _load_schemes()[name] + + +def _inject_headers(name, scheme): + """ + Given a scheme name and the resolved scheme, + if the scheme does not include headers, resolve + the fallback scheme for the name and use headers + from it. pypa/distutils#88 + """ + # Bypass the preferred scheme, which may not + # have defined headers. + fallback = _load_scheme(name) + scheme.setdefault('headers', fallback['headers']) + return scheme + + +def _scheme_attrs(scheme): + """Resolve install directories by applying the install schemes.""" + return {f'install_{key}': scheme[key] for key in SCHEME_KEYS} + + +class install(Command): + description = "install everything from build directory" + + user_options = [ + # Select installation scheme and set base director(y|ies) + ('prefix=', None, "installation prefix"), + ('exec-prefix=', None, "(Unix only) prefix for platform-specific files"), + ('home=', None, "(Unix only) home directory to install under"), + # Or, just set the base director(y|ies) + ( + 'install-base=', + None, + "base installation directory (instead of --prefix or --home)", + ), + ( + 'install-platbase=', + None, + "base installation directory for platform-specific files (instead of --exec-prefix or --home)", + ), + ('root=', None, "install everything relative to this alternate root directory"), + # Or, explicitly set the installation scheme + ( + 'install-purelib=', + None, + "installation directory for pure Python module distributions", + ), + ( + 'install-platlib=', + None, + "installation directory for non-pure module distributions", + ), + ( + 'install-lib=', + None, + "installation directory for all module distributions (overrides --install-purelib and --install-platlib)", + ), + ('install-headers=', None, "installation directory for C/C++ headers"), + ('install-scripts=', None, "installation directory for Python scripts"), + ('install-data=', None, "installation directory for data files"), + # Byte-compilation options -- see install_lib.py for details, as + # these are duplicated from there (but only install_lib does + # anything with them). + ('compile', 'c', "compile .py to .pyc [default]"), + ('no-compile', None, "don't compile .py files"), + ( + 'optimize=', + 'O', + "also compile with optimization: -O1 for \"python -O\", " + "-O2 for \"python -OO\", and -O0 to disable [default: -O0]", + ), + # Miscellaneous control options + ('force', 'f', "force installation (overwrite any existing files)"), + ('skip-build', None, "skip rebuilding everything (for testing/debugging)"), + # Where to install documentation (eventually!) + # ('doc-format=', None, "format of documentation to generate"), + # ('install-man=', None, "directory for Unix man pages"), + # ('install-html=', None, "directory for HTML documentation"), + # ('install-info=', None, "directory for GNU info files"), + ('record=', None, "filename in which to record list of installed files"), + ] + + boolean_options: ClassVar[list[str]] = ['compile', 'force', 'skip-build'] + + if HAS_USER_SITE: + user_options.append(( + 'user', + None, + f"install in user site-package '{USER_SITE}'", + )) + boolean_options.append('user') + + negative_opt: ClassVar[dict[str, str]] = {'no-compile': 'compile'} + + def initialize_options(self) -> None: + """Initializes options.""" + # High-level options: these select both an installation base + # and scheme. + self.prefix: str | None = None + self.exec_prefix: str | None = None + self.home: str | None = None + self.user = False + + # These select only the installation base; it's up to the user to + # specify the installation scheme (currently, that means supplying + # the --install-{platlib,purelib,scripts,data} options). + self.install_base = None + self.install_platbase = None + self.root: str | None = None + + # These options are the actual installation directories; if not + # supplied by the user, they are filled in using the installation + # scheme implied by prefix/exec-prefix/home and the contents of + # that installation scheme. + self.install_purelib = None # for pure module distributions + self.install_platlib = None # non-pure (dists w/ extensions) + self.install_headers = None # for C/C++ headers + self.install_lib: str | None = None # set to either purelib or platlib + self.install_scripts = None + self.install_data = None + self.install_userbase = USER_BASE + self.install_usersite = USER_SITE + + self.compile = None + self.optimize = None + + # Deprecated + # These two are for putting non-packagized distributions into their + # own directory and creating a .pth file if it makes sense. + # 'extra_path' comes from the setup file; 'install_path_file' can + # be turned off if it makes no sense to install a .pth file. (But + # better to install it uselessly than to guess wrong and not + # install it when it's necessary and would be used!) Currently, + # 'install_path_file' is always true unless some outsider meddles + # with it. + self.extra_path = None + self.install_path_file = True + + # 'force' forces installation, even if target files are not + # out-of-date. 'skip_build' skips running the "build" command, + # handy if you know it's not necessary. 'warn_dir' (which is *not* + # a user option, it's just there so the bdist_* commands can turn + # it off) determines whether we warn about installing to a + # directory not in sys.path. + self.force = False + self.skip_build = False + self.warn_dir = True + + # These are only here as a conduit from the 'build' command to the + # 'install_*' commands that do the real work. ('build_base' isn't + # actually used anywhere, but it might be useful in future.) They + # are not user options, because if the user told the install + # command where the build directory is, that wouldn't affect the + # build command. + self.build_base = None + self.build_lib = None + + # Not defined yet because we don't know anything about + # documentation yet. + # self.install_man = None + # self.install_html = None + # self.install_info = None + + self.record = None + + # -- Option finalizing methods ------------------------------------- + # (This is rather more involved than for most commands, + # because this is where the policy for installing third- + # party Python modules on various platforms given a wide + # array of user input is decided. Yes, it's quite complex!) + + def finalize_options(self) -> None: # noqa: C901 + """Finalizes options.""" + # This method (and its helpers, like 'finalize_unix()', + # 'finalize_other()', and 'select_scheme()') is where the default + # installation directories for modules, extension modules, and + # anything else we care to install from a Python module + # distribution. Thus, this code makes a pretty important policy + # statement about how third-party stuff is added to a Python + # installation! Note that the actual work of installation is done + # by the relatively simple 'install_*' commands; they just take + # their orders from the installation directory options determined + # here. + + # Check for errors/inconsistencies in the options; first, stuff + # that's wrong on any platform. + + if (self.prefix or self.exec_prefix or self.home) and ( + self.install_base or self.install_platbase + ): + raise DistutilsOptionError( + "must supply either prefix/exec-prefix/home or install-base/install-platbase -- not both" + ) + + if self.home and (self.prefix or self.exec_prefix): + raise DistutilsOptionError( + "must supply either home or prefix/exec-prefix -- not both" + ) + + if self.user and ( + self.prefix + or self.exec_prefix + or self.home + or self.install_base + or self.install_platbase + ): + raise DistutilsOptionError( + "can't combine user with prefix, " + "exec_prefix/home, or install_(plat)base" + ) + + # Next, stuff that's wrong (or dubious) only on certain platforms. + if os.name != "posix": + if self.exec_prefix: + self.warn("exec-prefix option ignored on this platform") + self.exec_prefix = None + + # Now the interesting logic -- so interesting that we farm it out + # to other methods. The goal of these methods is to set the final + # values for the install_{lib,scripts,data,...} options, using as + # input a heady brew of prefix, exec_prefix, home, install_base, + # install_platbase, user-supplied versions of + # install_{purelib,platlib,lib,scripts,data,...}, and the + # install schemes. Phew! + + self.dump_dirs("pre-finalize_{unix,other}") + + if os.name == 'posix': + self.finalize_unix() + else: + self.finalize_other() + + self.dump_dirs("post-finalize_{unix,other}()") + + # Expand configuration variables, tilde, etc. in self.install_base + # and self.install_platbase -- that way, we can use $base or + # $platbase in the other installation directories and not worry + # about needing recursive variable expansion (shudder). + + py_version = sys.version.split()[0] + (prefix, exec_prefix) = get_config_vars('prefix', 'exec_prefix') + try: + abiflags = sys.abiflags + except AttributeError: + # sys.abiflags may not be defined on all platforms. + abiflags = '' + local_vars = { + 'dist_name': self.distribution.get_name(), + 'dist_version': self.distribution.get_version(), + 'dist_fullname': self.distribution.get_fullname(), + 'py_version': py_version, + 'py_version_short': f'{sys.version_info.major}.{sys.version_info.minor}', + 'py_version_nodot': f'{sys.version_info.major}{sys.version_info.minor}', + 'sys_prefix': prefix, + 'prefix': prefix, + 'sys_exec_prefix': exec_prefix, + 'exec_prefix': exec_prefix, + 'abiflags': abiflags, + 'platlibdir': getattr(sys, 'platlibdir', 'lib'), + 'implementation_lower': _get_implementation().lower(), + 'implementation': _get_implementation(), + } + + # vars for compatibility on older Pythons + compat_vars = dict( + # Python 3.9 and earlier + py_version_nodot_plat=getattr(sys, 'winver', '').replace('.', ''), + ) + + if HAS_USER_SITE: + local_vars['userbase'] = self.install_userbase + local_vars['usersite'] = self.install_usersite + + self.config_vars = collections.ChainMap( + local_vars, + sysconfig.get_config_vars(), + compat_vars, + fw.vars(), + ) + + self.expand_basedirs() + + self.dump_dirs("post-expand_basedirs()") + + # Now define config vars for the base directories so we can expand + # everything else. + local_vars['base'] = self.install_base + local_vars['platbase'] = self.install_platbase + + if DEBUG: + from pprint import pprint + + print("config vars:") + pprint(dict(self.config_vars)) + + # Expand "~" and configuration variables in the installation + # directories. + self.expand_dirs() + + self.dump_dirs("post-expand_dirs()") + + # Create directories in the home dir: + if self.user: + self.create_home_path() + + # Pick the actual directory to install all modules to: either + # install_purelib or install_platlib, depending on whether this + # module distribution is pure or not. Of course, if the user + # already specified install_lib, use their selection. + if self.install_lib is None: + if self.distribution.has_ext_modules(): # has extensions: non-pure + self.install_lib = self.install_platlib + else: + self.install_lib = self.install_purelib + + # Convert directories from Unix /-separated syntax to the local + # convention. + self.convert_paths( + 'lib', + 'purelib', + 'platlib', + 'scripts', + 'data', + 'headers', + 'userbase', + 'usersite', + ) + + # Deprecated + # Well, we're not actually fully completely finalized yet: we still + # have to deal with 'extra_path', which is the hack for allowing + # non-packagized module distributions (hello, Numerical Python!) to + # get their own directories. + self.handle_extra_path() + self.install_libbase = self.install_lib # needed for .pth file + self.install_lib = os.path.join(self.install_lib, self.extra_dirs) + + # If a new root directory was supplied, make all the installation + # dirs relative to it. + if self.root is not None: + self.change_roots( + 'libbase', 'lib', 'purelib', 'platlib', 'scripts', 'data', 'headers' + ) + + self.dump_dirs("after prepending root") + + # Find out the build directories, ie. where to install from. + self.set_undefined_options( + 'build', ('build_base', 'build_base'), ('build_lib', 'build_lib') + ) + + # Punt on doc directories for now -- after all, we're punting on + # documentation completely! + + def dump_dirs(self, msg) -> None: + """Dumps the list of user options.""" + if not DEBUG: + return + from ..fancy_getopt import longopt_xlate + + log.debug(msg + ":") + for opt in self.user_options: + opt_name = opt[0] + if opt_name[-1] == "=": + opt_name = opt_name[0:-1] + if opt_name in self.negative_opt: + opt_name = self.negative_opt[opt_name] + opt_name = opt_name.translate(longopt_xlate) + val = not getattr(self, opt_name) + else: + opt_name = opt_name.translate(longopt_xlate) + val = getattr(self, opt_name) + log.debug(" %s: %s", opt_name, val) + + def finalize_unix(self) -> None: + """Finalizes options for posix platforms.""" + if self.install_base is not None or self.install_platbase is not None: + incomplete_scheme = ( + ( + self.install_lib is None + and self.install_purelib is None + and self.install_platlib is None + ) + or self.install_headers is None + or self.install_scripts is None + or self.install_data is None + ) + if incomplete_scheme: + raise DistutilsOptionError( + "install-base or install-platbase supplied, but " + "installation scheme is incomplete" + ) + return + + if self.user: + if self.install_userbase is None: + raise DistutilsPlatformError("User base directory is not specified") + self.install_base = self.install_platbase = self.install_userbase + self.select_scheme("posix_user") + elif self.home is not None: + self.install_base = self.install_platbase = self.home + self.select_scheme("posix_home") + else: + if self.prefix is None: + if self.exec_prefix is not None: + raise DistutilsOptionError( + "must not supply exec-prefix without prefix" + ) + + # Allow Fedora to add components to the prefix + _prefix_addition = getattr(sysconfig, '_prefix_addition', "") + + self.prefix = os.path.normpath(sys.prefix) + _prefix_addition + self.exec_prefix = os.path.normpath(sys.exec_prefix) + _prefix_addition + + else: + if self.exec_prefix is None: + self.exec_prefix = self.prefix + + self.install_base = self.prefix + self.install_platbase = self.exec_prefix + self.select_scheme("posix_prefix") + + def finalize_other(self) -> None: + """Finalizes options for non-posix platforms""" + if self.user: + if self.install_userbase is None: + raise DistutilsPlatformError("User base directory is not specified") + self.install_base = self.install_platbase = self.install_userbase + self.select_scheme(os.name + "_user") + elif self.home is not None: + self.install_base = self.install_platbase = self.home + self.select_scheme("posix_home") + else: + if self.prefix is None: + self.prefix = os.path.normpath(sys.prefix) + + self.install_base = self.install_platbase = self.prefix + try: + self.select_scheme(os.name) + except KeyError: + raise DistutilsPlatformError( + f"I don't know how to install stuff on '{os.name}'" + ) + + def select_scheme(self, name) -> None: + _select_scheme(self, name) + + def _expand_attrs(self, attrs): + for attr in attrs: + val = getattr(self, attr) + if val is not None: + if os.name in ('posix', 'nt'): + val = os.path.expanduser(val) + val = subst_vars(val, self.config_vars) + setattr(self, attr, val) + + def expand_basedirs(self) -> None: + """Calls `os.path.expanduser` on install_base, install_platbase and + root.""" + self._expand_attrs(['install_base', 'install_platbase', 'root']) + + def expand_dirs(self) -> None: + """Calls `os.path.expanduser` on install dirs.""" + self._expand_attrs([ + 'install_purelib', + 'install_platlib', + 'install_lib', + 'install_headers', + 'install_scripts', + 'install_data', + ]) + + def convert_paths(self, *names) -> None: + """Call `convert_path` over `names`.""" + for name in names: + attr = "install_" + name + setattr(self, attr, convert_path(getattr(self, attr))) + + def handle_extra_path(self) -> None: + """Set `path_file` and `extra_dirs` using `extra_path`.""" + if self.extra_path is None: + self.extra_path = self.distribution.extra_path + + if self.extra_path is not None: + log.warning( + "Distribution option extra_path is deprecated. " + "See issue27919 for details." + ) + if isinstance(self.extra_path, str): + self.extra_path = self.extra_path.split(',') + + if len(self.extra_path) == 1: + path_file = extra_dirs = self.extra_path[0] + elif len(self.extra_path) == 2: + path_file, extra_dirs = self.extra_path + else: + raise DistutilsOptionError( + "'extra_path' option must be a list, tuple, or " + "comma-separated string with 1 or 2 elements" + ) + + # convert to local form in case Unix notation used (as it + # should be in setup scripts) + extra_dirs = convert_path(extra_dirs) + else: + path_file = None + extra_dirs = '' + + # XXX should we warn if path_file and not extra_dirs? (in which + # case the path file would be harmless but pointless) + self.path_file = path_file + self.extra_dirs = extra_dirs + + def change_roots(self, *names) -> None: + """Change the install directories pointed by name using root.""" + for name in names: + attr = "install_" + name + setattr(self, attr, change_root(self.root, getattr(self, attr))) + + def create_home_path(self) -> None: + """Create directories under ~.""" + if not self.user: + return + home = convert_path(os.path.expanduser("~")) + for path in self.config_vars.values(): + if str(path).startswith(home) and not os.path.isdir(path): + self.debug_print(f"os.makedirs('{path}', 0o700)") + os.makedirs(path, 0o700) + + # -- Command execution methods ------------------------------------- + + def run(self): + """Runs the command.""" + # Obviously have to build before we can install + if not self.skip_build: + self.run_command('build') + # If we built for any other platform, we can't install. + build_plat = self.distribution.get_command_obj('build').plat_name + # check warn_dir - it is a clue that the 'install' is happening + # internally, and not to sys.path, so we don't check the platform + # matches what we are running. + if self.warn_dir and build_plat != get_platform(): + raise DistutilsPlatformError("Can't install when cross-compiling") + + # Run all sub-commands (at least those that need to be run) + for cmd_name in self.get_sub_commands(): + self.run_command(cmd_name) + + if self.path_file: + self.create_path_file() + + # write list of installed files, if requested. + if self.record: + outputs = self.get_outputs() + if self.root: # strip any package prefix + root_len = len(self.root) + for counter in range(len(outputs)): + outputs[counter] = outputs[counter][root_len:] + self.execute( + write_file, + (self.record, outputs), + f"writing list of installed files to '{self.record}'", + ) + + sys_path = map(os.path.normpath, sys.path) + sys_path = map(os.path.normcase, sys_path) + install_lib = os.path.normcase(os.path.normpath(self.install_lib)) + if ( + self.warn_dir + and not (self.path_file and self.install_path_file) + and install_lib not in sys_path + ): + log.debug( + ( + "modules installed to '%s', which is not in " + "Python's module search path (sys.path) -- " + "you'll have to change the search path yourself" + ), + self.install_lib, + ) + + def create_path_file(self): + """Creates the .pth file""" + filename = os.path.join(self.install_libbase, self.path_file + ".pth") + if self.install_path_file: + self.execute( + write_file, (filename, [self.extra_dirs]), f"creating {filename}" + ) + else: + self.warn(f"path file '{filename}' not created") + + # -- Reporting methods --------------------------------------------- + + def get_outputs(self): + """Assembles the outputs of all the sub-commands.""" + outputs = [] + for cmd_name in self.get_sub_commands(): + cmd = self.get_finalized_command(cmd_name) + # Add the contents of cmd.get_outputs(), ensuring + # that outputs doesn't contain duplicate entries + for filename in cmd.get_outputs(): + if filename not in outputs: + outputs.append(filename) + + if self.path_file and self.install_path_file: + outputs.append(os.path.join(self.install_libbase, self.path_file + ".pth")) + + return outputs + + def get_inputs(self): + """Returns the inputs of all the sub-commands""" + # XXX gee, this looks familiar ;-( + inputs = [] + for cmd_name in self.get_sub_commands(): + cmd = self.get_finalized_command(cmd_name) + inputs.extend(cmd.get_inputs()) + + return inputs + + # -- Predicates for sub-command list ------------------------------- + + def has_lib(self): + """Returns true if the current distribution has any Python + modules to install.""" + return ( + self.distribution.has_pure_modules() or self.distribution.has_ext_modules() + ) + + def has_headers(self): + """Returns true if the current distribution has any headers to + install.""" + return self.distribution.has_headers() + + def has_scripts(self): + """Returns true if the current distribution has any scripts to. + install.""" + return self.distribution.has_scripts() + + def has_data(self): + """Returns true if the current distribution has any data to. + install.""" + return self.distribution.has_data_files() + + # 'sub_commands': a list of commands this command might have to run to + # get its work done. See cmd.py for more info. + sub_commands = [ + ('install_lib', has_lib), + ('install_headers', has_headers), + ('install_scripts', has_scripts), + ('install_data', has_data), + ('install_egg_info', lambda self: True), + ] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install_data.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install_data.py new file mode 100644 index 0000000000000000000000000000000000000000..4ad186e8ec61b92967ea1c12cdca51d00e82dd15 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install_data.py @@ -0,0 +1,94 @@ +"""distutils.command.install_data + +Implements the Distutils 'install_data' command, for installing +platform-independent data files.""" + +# contributed by Bastian Kleineidam + +from __future__ import annotations + +import functools +import os +from collections.abc import Iterable +from typing import ClassVar + +from ..core import Command +from ..util import change_root, convert_path + + +class install_data(Command): + description = "install data files" + + user_options = [ + ( + 'install-dir=', + 'd', + "base directory for installing data files [default: installation base dir]", + ), + ('root=', None, "install everything relative to this alternate root directory"), + ('force', 'f', "force installation (overwrite existing files)"), + ] + + boolean_options: ClassVar[list[str]] = ['force'] + + def initialize_options(self): + self.install_dir = None + self.outfiles = [] + self.root = None + self.force = False + self.data_files = self.distribution.data_files + self.warn_dir = True + + def finalize_options(self) -> None: + self.set_undefined_options( + 'install', + ('install_data', 'install_dir'), + ('root', 'root'), + ('force', 'force'), + ) + + def run(self) -> None: + self.mkpath(self.install_dir) + for f in self.data_files: + self._copy(f) + + @functools.singledispatchmethod + def _copy(self, f: tuple[str | os.PathLike, Iterable[str | os.PathLike]]): + # it's a tuple with path to install to and a list of files + dir = convert_path(f[0]) + if not os.path.isabs(dir): + dir = os.path.join(self.install_dir, dir) + elif self.root: + dir = change_root(self.root, dir) + self.mkpath(dir) + + if f[1] == []: + # If there are no files listed, the user must be + # trying to create an empty directory, so add the + # directory to the list of output files. + self.outfiles.append(dir) + else: + # Copy files, adding them to the list of output files. + for data in f[1]: + data = convert_path(data) + (out, _) = self.copy_file(data, dir) + self.outfiles.append(out) + + @_copy.register(str) + @_copy.register(os.PathLike) + def _(self, f: str | os.PathLike): + # it's a simple file, so copy it + f = convert_path(f) + if self.warn_dir: + self.warn( + "setup script did not provide a directory for " + f"'{f}' -- installing right in '{self.install_dir}'" + ) + (out, _) = self.copy_file(f, self.install_dir) + self.outfiles.append(out) + + def get_inputs(self): + return self.data_files or [] + + def get_outputs(self): + return self.outfiles diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install_egg_info.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install_egg_info.py new file mode 100644 index 0000000000000000000000000000000000000000..6840b34ec2b5e2a3f9514cda5e940bc6cd90c731 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install_egg_info.py @@ -0,0 +1,90 @@ +""" +distutils.command.install_egg_info + +Implements the Distutils 'install_egg_info' command, for installing +a package's PKG-INFO metadata. +""" + +import os +import re +import sys +from typing import ClassVar + +from .. import dir_util +from .._log import log +from ..cmd import Command + + +class install_egg_info(Command): + """Install an .egg-info file for the package""" + + description = "Install package's PKG-INFO metadata as an .egg-info file" + user_options: ClassVar[list[tuple[str, str, str]]] = [ + ('install-dir=', 'd', "directory to install to"), + ] + + def initialize_options(self): + self.install_dir = None + + @property + def basename(self): + """ + Allow basename to be overridden by child class. + Ref pypa/distutils#2. + """ + name = to_filename(safe_name(self.distribution.get_name())) + version = to_filename(safe_version(self.distribution.get_version())) + return f"{name}-{version}-py{sys.version_info.major}.{sys.version_info.minor}.egg-info" + + def finalize_options(self): + self.set_undefined_options('install_lib', ('install_dir', 'install_dir')) + self.target = os.path.join(self.install_dir, self.basename) + self.outputs = [self.target] + + def run(self): + target = self.target + if os.path.isdir(target) and not os.path.islink(target): + dir_util.remove_tree(target) + elif os.path.exists(target): + self.execute(os.unlink, (self.target,), "Removing " + target) + elif not os.path.isdir(self.install_dir): + self.execute( + os.makedirs, (self.install_dir,), "Creating " + self.install_dir + ) + log.info("Writing %s", target) + with open(target, 'w', encoding='UTF-8') as f: + self.distribution.metadata.write_pkg_file(f) + + def get_outputs(self): + return self.outputs + + +# The following routines are taken from setuptools' pkg_resources module and +# can be replaced by importing them from pkg_resources once it is included +# in the stdlib. + + +def safe_name(name): + """Convert an arbitrary string to a standard distribution name + + Any runs of non-alphanumeric/. characters are replaced with a single '-'. + """ + return re.sub('[^A-Za-z0-9.]+', '-', name) + + +def safe_version(version): + """Convert an arbitrary string to a standard version string + + Spaces become dots, and all other non-alphanumeric characters become + dashes, with runs of multiple dashes condensed to a single dash. + """ + version = version.replace(' ', '.') + return re.sub('[^A-Za-z0-9.]+', '-', version) + + +def to_filename(name): + """Convert a project or version name to its filename-escaped form + + Any '-' characters are currently replaced with '_'. + """ + return name.replace('-', '_') diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install_headers.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install_headers.py new file mode 100644 index 0000000000000000000000000000000000000000..97af1371efcc73423e9b91d7b3ced684ff936377 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install_headers.py @@ -0,0 +1,46 @@ +"""distutils.command.install_headers + +Implements the Distutils 'install_headers' command, to install C/C++ header +files to the Python include directory.""" + +from typing import ClassVar + +from ..core import Command + + +# XXX force is never used +class install_headers(Command): + description = "install C/C++ header files" + + user_options: ClassVar[list[tuple[str, str, str]]] = [ + ('install-dir=', 'd', "directory to install header files to"), + ('force', 'f', "force installation (overwrite existing files)"), + ] + + boolean_options: ClassVar[list[str]] = ['force'] + + def initialize_options(self): + self.install_dir = None + self.force = False + self.outfiles = [] + + def finalize_options(self): + self.set_undefined_options( + 'install', ('install_headers', 'install_dir'), ('force', 'force') + ) + + def run(self): + headers = self.distribution.headers + if not headers: + return + + self.mkpath(self.install_dir) + for header in headers: + (out, _) = self.copy_file(header, self.install_dir) + self.outfiles.append(out) + + def get_inputs(self): + return self.distribution.headers or [] + + def get_outputs(self): + return self.outfiles diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install_lib.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install_lib.py new file mode 100644 index 0000000000000000000000000000000000000000..9909a61762bd658f837057f07fa1d1200fe4e6ac --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install_lib.py @@ -0,0 +1,236 @@ +"""distutils.command.install_lib + +Implements the Distutils 'install_lib' command +(install all Python modules).""" + +from __future__ import annotations + +import importlib.util +import os +import sys +from typing import Any, ClassVar + +from ..core import Command +from ..errors import DistutilsOptionError + +# Extension for Python source files. +PYTHON_SOURCE_EXTENSION = ".py" + + +class install_lib(Command): + description = "install all Python modules (extensions and pure Python)" + + # The byte-compilation options are a tad confusing. Here are the + # possible scenarios: + # 1) no compilation at all (--no-compile --no-optimize) + # 2) compile .pyc only (--compile --no-optimize; default) + # 3) compile .pyc and "opt-1" .pyc (--compile --optimize) + # 4) compile "opt-1" .pyc only (--no-compile --optimize) + # 5) compile .pyc and "opt-2" .pyc (--compile --optimize-more) + # 6) compile "opt-2" .pyc only (--no-compile --optimize-more) + # + # The UI for this is two options, 'compile' and 'optimize'. + # 'compile' is strictly boolean, and only decides whether to + # generate .pyc files. 'optimize' is three-way (0, 1, or 2), and + # decides both whether to generate .pyc files and what level of + # optimization to use. + + user_options = [ + ('install-dir=', 'd', "directory to install to"), + ('build-dir=', 'b', "build directory (where to install from)"), + ('force', 'f', "force installation (overwrite existing files)"), + ('compile', 'c', "compile .py to .pyc [default]"), + ('no-compile', None, "don't compile .py files"), + ( + 'optimize=', + 'O', + "also compile with optimization: -O1 for \"python -O\", " + "-O2 for \"python -OO\", and -O0 to disable [default: -O0]", + ), + ('skip-build', None, "skip the build steps"), + ] + + boolean_options: ClassVar[list[str]] = ['force', 'compile', 'skip-build'] + negative_opt: ClassVar[dict[str, str]] = {'no-compile': 'compile'} + + def initialize_options(self): + # let the 'install' command dictate our installation directory + self.install_dir = None + self.build_dir = None + self.force = False + self.compile = None + self.optimize = None + self.skip_build = None + + def finalize_options(self) -> None: + # Get all the information we need to install pure Python modules + # from the umbrella 'install' command -- build (source) directory, + # install (target) directory, and whether to compile .py files. + self.set_undefined_options( + 'install', + ('build_lib', 'build_dir'), + ('install_lib', 'install_dir'), + ('force', 'force'), + ('compile', 'compile'), + ('optimize', 'optimize'), + ('skip_build', 'skip_build'), + ) + + if self.compile is None: + self.compile = True + if self.optimize is None: + self.optimize = False + + if not isinstance(self.optimize, int): + try: + self.optimize = int(self.optimize) + except ValueError: + pass + if self.optimize not in (0, 1, 2): + raise DistutilsOptionError("optimize must be 0, 1, or 2") + + def run(self) -> None: + # Make sure we have built everything we need first + self.build() + + # Install everything: simply dump the entire contents of the build + # directory to the installation directory (that's the beauty of + # having a build directory!) + outfiles = self.install() + + # (Optionally) compile .py to .pyc + if outfiles is not None and self.distribution.has_pure_modules(): + self.byte_compile(outfiles) + + # -- Top-level worker functions ------------------------------------ + # (called from 'run()') + + def build(self) -> None: + if not self.skip_build: + if self.distribution.has_pure_modules(): + self.run_command('build_py') + if self.distribution.has_ext_modules(): + self.run_command('build_ext') + + # Any: https://typing.readthedocs.io/en/latest/guides/writing_stubs.html#the-any-trick + def install(self) -> list[str] | Any: + if os.path.isdir(self.build_dir): + outfiles = self.copy_tree(self.build_dir, self.install_dir) + else: + self.warn( + f"'{self.build_dir}' does not exist -- no Python modules to install" + ) + return + return outfiles + + def byte_compile(self, files) -> None: + if sys.dont_write_bytecode: + self.warn('byte-compiling is disabled, skipping.') + return + + from ..util import byte_compile + + # Get the "--root" directory supplied to the "install" command, + # and use it as a prefix to strip off the purported filename + # encoded in bytecode files. This is far from complete, but it + # should at least generate usable bytecode in RPM distributions. + install_root = self.get_finalized_command('install').root + + if self.compile: + byte_compile( + files, + optimize=0, + force=self.force, + prefix=install_root, + ) + if self.optimize > 0: + byte_compile( + files, + optimize=self.optimize, + force=self.force, + prefix=install_root, + verbose=self.verbose, + ) + + # -- Utility methods ----------------------------------------------- + + def _mutate_outputs(self, has_any, build_cmd, cmd_option, output_dir): + if not has_any: + return [] + + build_cmd = self.get_finalized_command(build_cmd) + build_files = build_cmd.get_outputs() + build_dir = getattr(build_cmd, cmd_option) + + prefix_len = len(build_dir) + len(os.sep) + outputs = [os.path.join(output_dir, file[prefix_len:]) for file in build_files] + + return outputs + + def _bytecode_filenames(self, py_filenames): + bytecode_files = [] + for py_file in py_filenames: + # Since build_py handles package data installation, the + # list of outputs can contain more than just .py files. + # Make sure we only report bytecode for the .py files. + ext = os.path.splitext(os.path.normcase(py_file))[1] + if ext != PYTHON_SOURCE_EXTENSION: + continue + if self.compile: + bytecode_files.append( + importlib.util.cache_from_source(py_file, optimization='') + ) + if self.optimize > 0: + bytecode_files.append( + importlib.util.cache_from_source( + py_file, optimization=self.optimize + ) + ) + + return bytecode_files + + # -- External interface -------------------------------------------- + # (called by outsiders) + + def get_outputs(self): + """Return the list of files that would be installed if this command + were actually run. Not affected by the "dry-run" flag or whether + modules have actually been built yet. + """ + pure_outputs = self._mutate_outputs( + self.distribution.has_pure_modules(), + 'build_py', + 'build_lib', + self.install_dir, + ) + if self.compile: + bytecode_outputs = self._bytecode_filenames(pure_outputs) + else: + bytecode_outputs = [] + + ext_outputs = self._mutate_outputs( + self.distribution.has_ext_modules(), + 'build_ext', + 'build_lib', + self.install_dir, + ) + + return pure_outputs + bytecode_outputs + ext_outputs + + def get_inputs(self): + """Get the list of files that are input to this command, ie. the + files that get installed as they are named in the build tree. + The files in this list correspond one-to-one to the output + filenames returned by 'get_outputs()'. + """ + inputs = [] + + if self.distribution.has_pure_modules(): + build_py = self.get_finalized_command('build_py') + inputs.extend(build_py.get_outputs()) + + if self.distribution.has_ext_modules(): + build_ext = self.get_finalized_command('build_ext') + inputs.extend(build_ext.get_outputs()) + + return inputs diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install_scripts.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install_scripts.py new file mode 100644 index 0000000000000000000000000000000000000000..33d235d976e39db426aaff628b8b9bb5b832dcb6 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/install_scripts.py @@ -0,0 +1,59 @@ +"""distutils.command.install_scripts + +Implements the Distutils 'install_scripts' command, for installing +Python scripts.""" + +# contributed by Bastian Kleineidam + +import os +from distutils._log import log +from stat import ST_MODE +from typing import ClassVar + +from ..core import Command + + +class install_scripts(Command): + description = "install scripts (Python or otherwise)" + + user_options = [ + ('install-dir=', 'd', "directory to install scripts to"), + ('build-dir=', 'b', "build directory (where to install from)"), + ('force', 'f', "force installation (overwrite existing files)"), + ('skip-build', None, "skip the build steps"), + ] + + boolean_options: ClassVar[list[str]] = ['force', 'skip-build'] + + def initialize_options(self): + self.install_dir = None + self.force = False + self.build_dir = None + self.skip_build = None + + def finalize_options(self) -> None: + self.set_undefined_options('build', ('build_scripts', 'build_dir')) + self.set_undefined_options( + 'install', + ('install_scripts', 'install_dir'), + ('force', 'force'), + ('skip_build', 'skip_build'), + ) + + def run(self) -> None: + if not self.skip_build: + self.run_command('build_scripts') + self.outfiles = self.copy_tree(self.build_dir, self.install_dir) + if os.name == 'posix': + # Set the executable bits (owner, group, and world) on + # all the scripts we just installed. + for file in self.get_outputs(): + mode = ((os.stat(file)[ST_MODE]) | 0o555) & 0o7777 + log.info("changing mode of %s to %o", file, mode) + os.chmod(file, mode) + + def get_inputs(self): + return self.distribution.scripts or [] + + def get_outputs(self): + return self.outfiles or [] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/sdist.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/sdist.py new file mode 100644 index 0000000000000000000000000000000000000000..e64cc82902ac292fa391a219ff8eae117b252fe7 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/command/sdist.py @@ -0,0 +1,521 @@ +"""distutils.command.sdist + +Implements the Distutils 'sdist' command (create a source distribution).""" + +from __future__ import annotations + +import os +import sys +from collections.abc import Callable +from distutils import archive_util, dir_util, file_util +from distutils._log import log +from glob import glob +from itertools import filterfalse +from typing import ClassVar + +from ..core import Command +from ..errors import DistutilsOptionError, DistutilsTemplateError +from ..filelist import FileList +from ..text_file import TextFile +from ..util import convert_path + + +def show_formats(): + """Print all possible values for the 'formats' option (used by + the "--help-formats" command-line option). + """ + from ..archive_util import ARCHIVE_FORMATS + from ..fancy_getopt import FancyGetopt + + formats = sorted( + ("formats=" + format, None, ARCHIVE_FORMATS[format][2]) + for format in ARCHIVE_FORMATS.keys() + ) + FancyGetopt(formats).print_help("List of available source distribution formats:") + + +class sdist(Command): + description = "create a source distribution (tarball, zip file, etc.)" + + def checking_metadata(self) -> bool: + """Callable used for the check sub-command. + + Placed here so user_options can view it""" + return self.metadata_check + + user_options = [ + ('template=', 't', "name of manifest template file [default: MANIFEST.in]"), + ('manifest=', 'm', "name of manifest file [default: MANIFEST]"), + ( + 'use-defaults', + None, + "include the default file set in the manifest " + "[default; disable with --no-defaults]", + ), + ('no-defaults', None, "don't include the default file set"), + ( + 'prune', + None, + "specifically exclude files/directories that should not be " + "distributed (build tree, RCS/CVS dirs, etc.) " + "[default; disable with --no-prune]", + ), + ('no-prune', None, "don't automatically exclude anything"), + ( + 'manifest-only', + 'o', + "just regenerate the manifest and then stop (implies --force-manifest)", + ), + ( + 'force-manifest', + 'f', + "forcibly regenerate the manifest and carry on as usual. " + "Deprecated: now the manifest is always regenerated.", + ), + ('formats=', None, "formats for source distribution (comma-separated list)"), + ( + 'keep-temp', + 'k', + "keep the distribution tree around after creating " + "archive file(s)", + ), + ( + 'dist-dir=', + 'd', + "directory to put the source distribution archive(s) in [default: dist]", + ), + ( + 'metadata-check', + None, + "Ensure that all required elements of meta-data " + "are supplied. Warn if any missing. [default]", + ), + ( + 'owner=', + 'u', + "Owner name used when creating a tar file [default: current user]", + ), + ( + 'group=', + 'g', + "Group name used when creating a tar file [default: current group]", + ), + ] + + boolean_options: ClassVar[list[str]] = [ + 'use-defaults', + 'prune', + 'manifest-only', + 'force-manifest', + 'keep-temp', + 'metadata-check', + ] + + help_options: ClassVar[list[tuple[str, str | None, str, Callable[[], object]]]] = [ + ('help-formats', None, "list available distribution formats", show_formats), + ] + + negative_opt: ClassVar[dict[str, str]] = { + 'no-defaults': 'use-defaults', + 'no-prune': 'prune', + } + + sub_commands = [('check', checking_metadata)] + + READMES: ClassVar[tuple[str, ...]] = ('README', 'README.txt', 'README.rst') + + def initialize_options(self): + # 'template' and 'manifest' are, respectively, the names of + # the manifest template and manifest file. + self.template = None + self.manifest = None + + # 'use_defaults': if true, we will include the default file set + # in the manifest + self.use_defaults = True + self.prune = True + + self.manifest_only = False + self.force_manifest = False + + self.formats = ['gztar'] + self.keep_temp = False + self.dist_dir = None + + self.archive_files = None + self.metadata_check = True + self.owner = None + self.group = None + + def finalize_options(self) -> None: + if self.manifest is None: + self.manifest = "MANIFEST" + if self.template is None: + self.template = "MANIFEST.in" + + self.ensure_string_list('formats') + + bad_format = archive_util.check_archive_formats(self.formats) + if bad_format: + raise DistutilsOptionError(f"unknown archive format '{bad_format}'") + + if self.dist_dir is None: + self.dist_dir = "dist" + + def run(self) -> None: + # 'filelist' contains the list of files that will make up the + # manifest + self.filelist = FileList() + + # Run sub commands + for cmd_name in self.get_sub_commands(): + self.run_command(cmd_name) + + # Do whatever it takes to get the list of files to process + # (process the manifest template, read an existing manifest, + # whatever). File list is accumulated in 'self.filelist'. + self.get_file_list() + + # If user just wanted us to regenerate the manifest, stop now. + if self.manifest_only: + return + + # Otherwise, go ahead and create the source distribution tarball, + # or zipfile, or whatever. + self.make_distribution() + + def get_file_list(self) -> None: + """Figure out the list of files to include in the source + distribution, and put it in 'self.filelist'. This might involve + reading the manifest template (and writing the manifest), or just + reading the manifest, or just using the default file set -- it all + depends on the user's options. + """ + # new behavior when using a template: + # the file list is recalculated every time because + # even if MANIFEST.in or setup.py are not changed + # the user might have added some files in the tree that + # need to be included. + # + # This makes --force the default and only behavior with templates. + template_exists = os.path.isfile(self.template) + if not template_exists and self._manifest_is_not_generated(): + self.read_manifest() + self.filelist.sort() + self.filelist.remove_duplicates() + return + + if not template_exists: + self.warn( + ("manifest template '%s' does not exist " + "(using default file list)") + % self.template + ) + self.filelist.findall() + + if self.use_defaults: + self.add_defaults() + + if template_exists: + self.read_template() + + if self.prune: + self.prune_file_list() + + self.filelist.sort() + self.filelist.remove_duplicates() + self.write_manifest() + + def add_defaults(self) -> None: + """Add all the default files to self.filelist: + - README or README.txt + - setup.py + - tests/test*.py and test/test*.py + - all pure Python modules mentioned in setup script + - all files pointed by package_data (build_py) + - all files defined in data_files. + - all files defined as scripts. + - all C sources listed as part of extensions or C libraries + in the setup script (doesn't catch C headers!) + Warns if (README or README.txt) or setup.py are missing; everything + else is optional. + """ + self._add_defaults_standards() + self._add_defaults_optional() + self._add_defaults_python() + self._add_defaults_data_files() + self._add_defaults_ext() + self._add_defaults_c_libs() + self._add_defaults_scripts() + + @staticmethod + def _cs_path_exists(fspath): + """ + Case-sensitive path existence check + + >>> sdist._cs_path_exists(__file__) + True + >>> sdist._cs_path_exists(__file__.upper()) + False + """ + if not os.path.exists(fspath): + return False + # make absolute so we always have a directory + abspath = os.path.abspath(fspath) + directory, filename = os.path.split(abspath) + return filename in os.listdir(directory) + + def _add_defaults_standards(self): + standards = [self.READMES, self.distribution.script_name] + for fn in standards: + if isinstance(fn, tuple): + alts = fn + got_it = False + for fn in alts: + if self._cs_path_exists(fn): + got_it = True + self.filelist.append(fn) + break + + if not got_it: + self.warn( + "standard file not found: should have one of " + ', '.join(alts) + ) + else: + if self._cs_path_exists(fn): + self.filelist.append(fn) + else: + self.warn(f"standard file '{fn}' not found") + + def _add_defaults_optional(self): + optional = ['tests/test*.py', 'test/test*.py', 'setup.cfg'] + for pattern in optional: + files = filter(os.path.isfile, glob(pattern)) + self.filelist.extend(files) + + def _add_defaults_python(self): + # build_py is used to get: + # - python modules + # - files defined in package_data + build_py = self.get_finalized_command('build_py') + + # getting python files + if self.distribution.has_pure_modules(): + self.filelist.extend(build_py.get_source_files()) + + # getting package_data files + # (computed in build_py.data_files by build_py.finalize_options) + for _pkg, src_dir, _build_dir, filenames in build_py.data_files: + for filename in filenames: + self.filelist.append(os.path.join(src_dir, filename)) + + def _add_defaults_data_files(self): + # getting distribution.data_files + if self.distribution.has_data_files(): + for item in self.distribution.data_files: + if isinstance(item, str): + # plain file + item = convert_path(item) + if os.path.isfile(item): + self.filelist.append(item) + else: + # a (dirname, filenames) tuple + dirname, filenames = item + for f in filenames: + f = convert_path(f) + if os.path.isfile(f): + self.filelist.append(f) + + def _add_defaults_ext(self): + if self.distribution.has_ext_modules(): + build_ext = self.get_finalized_command('build_ext') + self.filelist.extend(build_ext.get_source_files()) + + def _add_defaults_c_libs(self): + if self.distribution.has_c_libraries(): + build_clib = self.get_finalized_command('build_clib') + self.filelist.extend(build_clib.get_source_files()) + + def _add_defaults_scripts(self): + if self.distribution.has_scripts(): + build_scripts = self.get_finalized_command('build_scripts') + self.filelist.extend(build_scripts.get_source_files()) + + def read_template(self) -> None: + """Read and parse manifest template file named by self.template. + + (usually "MANIFEST.in") The parsing and processing is done by + 'self.filelist', which updates itself accordingly. + """ + log.info("reading manifest template '%s'", self.template) + template = TextFile( + self.template, + strip_comments=True, + skip_blanks=True, + join_lines=True, + lstrip_ws=True, + rstrip_ws=True, + collapse_join=True, + ) + + try: + while True: + line = template.readline() + if line is None: # end of file + break + + try: + self.filelist.process_template_line(line) + # the call above can raise a DistutilsTemplateError for + # malformed lines, or a ValueError from the lower-level + # convert_path function + except (DistutilsTemplateError, ValueError) as msg: + self.warn( + f"{template.filename}, line {int(template.current_line)}: {msg}" + ) + finally: + template.close() + + def prune_file_list(self) -> None: + """Prune off branches that might slip into the file list as created + by 'read_template()', but really don't belong there: + * the build tree (typically "build") + * the release tree itself (only an issue if we ran "sdist" + previously with --keep-temp, or it aborted) + * any RCS, CVS, .svn, .hg, .git, .bzr, _darcs directories + """ + build = self.get_finalized_command('build') + base_dir = self.distribution.get_fullname() + + self.filelist.exclude_pattern(None, prefix=os.fspath(build.build_base)) + self.filelist.exclude_pattern(None, prefix=base_dir) + + if sys.platform == 'win32': + seps = r'/|\\' + else: + seps = '/' + + vcs_dirs = ['RCS', 'CVS', r'\.svn', r'\.hg', r'\.git', r'\.bzr', '_darcs'] + vcs_ptrn = r'(^|{})({})({}).*'.format(seps, '|'.join(vcs_dirs), seps) + self.filelist.exclude_pattern(vcs_ptrn, is_regex=True) + + def write_manifest(self) -> None: + """Write the file list in 'self.filelist' (presumably as filled in + by 'add_defaults()' and 'read_template()') to the manifest file + named by 'self.manifest'. + """ + if self._manifest_is_not_generated(): + log.info( + f"not writing to manually maintained manifest file '{self.manifest}'" + ) + return + + content = self.filelist.files[:] + content.insert(0, '# file GENERATED by distutils, do NOT edit') + self.execute( + file_util.write_file, + (self.manifest, content), + f"writing manifest file '{self.manifest}'", + ) + + def _manifest_is_not_generated(self): + # check for special comment used in 3.1.3 and higher + if not os.path.isfile(self.manifest): + return False + + with open(self.manifest, encoding='utf-8') as fp: + first_line = next(fp) + return first_line != '# file GENERATED by distutils, do NOT edit\n' + + def read_manifest(self) -> None: + """Read the manifest file (named by 'self.manifest') and use it to + fill in 'self.filelist', the list of files to include in the source + distribution. + """ + log.info("reading manifest file '%s'", self.manifest) + with open(self.manifest, encoding='utf-8') as lines: + self.filelist.extend( + # ignore comments and blank lines + filter(None, filterfalse(is_comment, map(str.strip, lines))) + ) + + def make_release_tree(self, base_dir, files) -> None: + """Create the directory tree that will become the source + distribution archive. All directories implied by the filenames in + 'files' are created under 'base_dir', and then we hard link or copy + (if hard linking is unavailable) those files into place. + Essentially, this duplicates the developer's source tree, but in a + directory named after the distribution, containing only the files + to be distributed. + """ + # Create all the directories under 'base_dir' necessary to + # put 'files' there; the 'mkpath()' is just so we don't die + # if the manifest happens to be empty. + self.mkpath(base_dir) + dir_util.create_tree(base_dir, files) + + # And walk over the list of files, either making a hard link (if + # os.link exists) to each one that doesn't already exist in its + # corresponding location under 'base_dir', or copying each file + # that's out-of-date in 'base_dir'. (Usually, all files will be + # out-of-date, because by default we blow away 'base_dir' when + # we're done making the distribution archives.) + + if hasattr(os, 'link'): # can make hard links on this system + link = 'hard' + msg = f"making hard links in {base_dir}..." + else: # nope, have to copy + link = None + msg = f"copying files to {base_dir}..." + + if not files: + log.warning("no files to distribute -- empty manifest?") + else: + log.info(msg) + for file in files: + if not os.path.isfile(file): + log.warning("'%s' not a regular file -- skipping", file) + else: + dest = os.path.join(base_dir, file) + self.copy_file(file, dest, link=link) + + self.distribution.metadata.write_pkg_info(base_dir) + + def make_distribution(self) -> None: + """Create the source distribution(s). First, we create the release + tree with 'make_release_tree()'; then, we create all required + archive files (according to 'self.formats') from the release tree. + Finally, we clean up by blowing away the release tree (unless + 'self.keep_temp' is true). The list of archive files created is + stored so it can be retrieved later by 'get_archive_files()'. + """ + # Don't warn about missing meta-data here -- should be (and is!) + # done elsewhere. + base_dir = self.distribution.get_fullname() + base_name = os.path.join(self.dist_dir, base_dir) + + self.make_release_tree(base_dir, self.filelist.files) + archive_files = [] # remember names of files we create + # tar archive must be created last to avoid overwrite and remove + if 'tar' in self.formats: + self.formats.append(self.formats.pop(self.formats.index('tar'))) + + for fmt in self.formats: + file = self.make_archive( + base_name, fmt, base_dir=base_dir, owner=self.owner, group=self.group + ) + archive_files.append(file) + self.distribution.dist_files.append(('sdist', '', file)) + + self.archive_files = archive_files + + if not self.keep_temp: + dir_util.remove_tree(base_dir) + + def get_archive_files(self): + """Return the list of archive files created when the command + was run, or None if the command hasn't run yet. + """ + return self.archive_files + + +def is_comment(line: str) -> bool: + return line.startswith('#') diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compat/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compat/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..2c43729b09ea5e5bf9d8c0708e63c69b5114a279 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compat/__init__.py @@ -0,0 +1,18 @@ +from __future__ import annotations + +from collections.abc import Iterable +from typing import TypeVar + +_IterableT = TypeVar("_IterableT", bound="Iterable[str]") + + +def consolidate_linker_args(args: _IterableT) -> _IterableT | str: + """ + Ensure the return value is a string for backward compatibility. + + Retain until at least 2025-04-31. See pypa/distutils#246 + """ + + if not all(arg.startswith('-Wl,') for arg in args): + return args + return '-Wl,' + ','.join(arg.removeprefix('-Wl,') for arg in args) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compat/numpy.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compat/numpy.py new file mode 100644 index 0000000000000000000000000000000000000000..73eca7acb103b7c7ca8e7a9f7f2d772a64aa344b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compat/numpy.py @@ -0,0 +1,2 @@ +# required for older numpy versions on Pythons prior to 3.12; see pypa/setuptools#4876 +from ..compilers.C.base import _default_compilers, compiler_class # noqa: F401 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compat/py39.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compat/py39.py new file mode 100644 index 0000000000000000000000000000000000000000..1b436d76586cbcf38164548f3fc849ce1a3ff600 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compat/py39.py @@ -0,0 +1,66 @@ +import functools +import itertools +import platform +import sys + + +def add_ext_suffix_39(vars): + """ + Ensure vars contains 'EXT_SUFFIX'. pypa/distutils#130 + """ + import _imp + + ext_suffix = _imp.extension_suffixes()[0] + vars.update( + EXT_SUFFIX=ext_suffix, + # sysconfig sets SO to match EXT_SUFFIX, so maintain + # that expectation. + # https://github.com/python/cpython/blob/785cc6770588de087d09e89a69110af2542be208/Lib/sysconfig.py#L671-L673 + SO=ext_suffix, + ) + + +needs_ext_suffix = sys.version_info < (3, 10) and platform.system() == 'Windows' +add_ext_suffix = add_ext_suffix_39 if needs_ext_suffix else lambda vars: None + + +# from more_itertools +class UnequalIterablesError(ValueError): + def __init__(self, details=None): + msg = 'Iterables have different lengths' + if details is not None: + msg += (': index 0 has length {}; index {} has length {}').format(*details) + + super().__init__(msg) + + +# from more_itertools +def _zip_equal_generator(iterables): + _marker = object() + for combo in itertools.zip_longest(*iterables, fillvalue=_marker): + for val in combo: + if val is _marker: + raise UnequalIterablesError() + yield combo + + +# from more_itertools +def _zip_equal(*iterables): + # Check whether the iterables are all the same size. + try: + first_size = len(iterables[0]) + for i, it in enumerate(iterables[1:], 1): + size = len(it) + if size != first_size: + raise UnequalIterablesError(details=(first_size, i, size)) + # All sizes are equal, we can use the built-in zip. + return zip(*iterables) + # If any one of the iterables didn't have a length, start reading + # them until one runs out. + except TypeError: + return _zip_equal_generator(iterables) + + +zip_strict = ( + _zip_equal if sys.version_info < (3, 10) else functools.partial(zip, strict=True) +) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/base.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/base.py new file mode 100644 index 0000000000000000000000000000000000000000..ea6b5458ef2b1d0c936cbfd9aaea19f5e41bbea9 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/base.py @@ -0,0 +1,1386 @@ +"""distutils.ccompiler + +Contains Compiler, an abstract base class that defines the interface +for the Distutils compiler abstraction model.""" + +from __future__ import annotations + +import os +import pathlib +import re +import sys +import warnings +from collections.abc import Callable, Iterable, MutableSequence, Sequence +from typing import ( + TYPE_CHECKING, + ClassVar, + Literal, + TypeVar, + Union, + overload, +) + +from more_itertools import always_iterable + +from ..._log import log +from ..._modified import newer_group +from ...dir_util import mkpath +from ...errors import ( + DistutilsModuleError, + DistutilsPlatformError, +) +from ...file_util import move_file +from ...spawn import spawn +from ...util import execute, is_mingw, split_quoted +from .errors import ( + CompileError, + LinkError, + UnknownFileType, +) + +if TYPE_CHECKING: + from typing_extensions import TypeAlias, TypeVarTuple, Unpack + + _Ts = TypeVarTuple("_Ts") + +_Macro: TypeAlias = Union[tuple[str], tuple[str, Union[str, None]]] +_StrPathT = TypeVar("_StrPathT", bound="str | os.PathLike[str]") +_BytesPathT = TypeVar("_BytesPathT", bound="bytes | os.PathLike[bytes]") + + +class Compiler: + """Abstract base class to define the interface that must be implemented + by real compiler classes. Also has some utility methods used by + several compiler classes. + + The basic idea behind a compiler abstraction class is that each + instance can be used for all the compile/link steps in building a + single project. Thus, attributes common to all of those compile and + link steps -- include directories, macros to define, libraries to link + against, etc. -- are attributes of the compiler instance. To allow for + variability in how individual files are treated, most of those + attributes may be varied on a per-compilation or per-link basis. + """ + + # 'compiler_type' is a class attribute that identifies this class. It + # keeps code that wants to know what kind of compiler it's dealing with + # from having to import all possible compiler classes just to do an + # 'isinstance'. In concrete CCompiler subclasses, 'compiler_type' + # should really, really be one of the keys of the 'compiler_class' + # dictionary (see below -- used by the 'new_compiler()' factory + # function) -- authors of new compiler interface classes are + # responsible for updating 'compiler_class'! + compiler_type: ClassVar[str] = None # type: ignore[assignment] + + # XXX things not handled by this compiler abstraction model: + # * client can't provide additional options for a compiler, + # e.g. warning, optimization, debugging flags. Perhaps this + # should be the domain of concrete compiler abstraction classes + # (UnixCCompiler, MSVCCompiler, etc.) -- or perhaps the base + # class should have methods for the common ones. + # * can't completely override the include or library searchg + # path, ie. no "cc -I -Idir1 -Idir2" or "cc -L -Ldir1 -Ldir2". + # I'm not sure how widely supported this is even by Unix + # compilers, much less on other platforms. And I'm even less + # sure how useful it is; maybe for cross-compiling, but + # support for that is a ways off. (And anyways, cross + # compilers probably have a dedicated binary with the + # right paths compiled in. I hope.) + # * can't do really freaky things with the library list/library + # dirs, e.g. "-Ldir1 -lfoo -Ldir2 -lfoo" to link against + # different versions of libfoo.a in different locations. I + # think this is useless without the ability to null out the + # library search path anyways. + + executables: ClassVar[dict] + + # Subclasses that rely on the standard filename generation methods + # implemented below should override these; see the comment near + # those methods ('object_filenames()' et. al.) for details: + src_extensions: ClassVar[list[str] | None] = None + obj_extension: ClassVar[str | None] = None + static_lib_extension: ClassVar[str | None] = None + shared_lib_extension: ClassVar[str | None] = None + static_lib_format: ClassVar[str | None] = None # format string + shared_lib_format: ClassVar[str | None] = None # prob. same as static_lib_format + exe_extension: ClassVar[str | None] = None + + # Default language settings. language_map is used to detect a source + # file or Extension target language, checking source filenames. + # language_order is used to detect the language precedence, when deciding + # what language to use when mixing source types. For example, if some + # extension has two files with ".c" extension, and one with ".cpp", it + # is still linked as c++. + language_map: ClassVar[dict[str, str]] = { + ".c": "c", + ".cc": "c++", + ".cpp": "c++", + ".cxx": "c++", + ".m": "objc", + } + language_order: ClassVar[list[str]] = ["c++", "objc", "c"] + + include_dirs: list[str] = [] + """ + include dirs specific to this compiler class + """ + + library_dirs: list[str] = [] + """ + library dirs specific to this compiler class + """ + + def __init__(self, verbose: bool = False, force: bool = False) -> None: + self.force = force + self.verbose = verbose + + # 'output_dir': a common output directory for object, library, + # shared object, and shared library files + self.output_dir: str | None = None + + # 'macros': a list of macro definitions (or undefinitions). A + # macro definition is a 2-tuple (name, value), where the value is + # either a string or None (no explicit value). A macro + # undefinition is a 1-tuple (name,). + self.macros: list[_Macro] = [] + + # 'include_dirs': a list of directories to search for include files + self.include_dirs = [] + + # 'libraries': a list of libraries to include in any link + # (library names, not filenames: eg. "foo" not "libfoo.a") + self.libraries: list[str] = [] + + # 'library_dirs': a list of directories to search for libraries + self.library_dirs = [] + + # 'runtime_library_dirs': a list of directories to search for + # shared libraries/objects at runtime + self.runtime_library_dirs: list[str] = [] + + # 'objects': a list of object files (or similar, such as explicitly + # named library files) to include on any link + self.objects: list[str] = [] + + for key in self.executables.keys(): + self.set_executable(key, self.executables[key]) + + def set_executables(self, **kwargs: str) -> None: + """Define the executables (and options for them) that will be run + to perform the various stages of compilation. The exact set of + executables that may be specified here depends on the compiler + class (via the 'executables' class attribute), but most will have: + compiler the C/C++ compiler + linker_so linker used to create shared objects and libraries + linker_exe linker used to create binary executables + archiver static library creator + + On platforms with a command-line (Unix, DOS/Windows), each of these + is a string that will be split into executable name and (optional) + list of arguments. (Splitting the string is done similarly to how + Unix shells operate: words are delimited by spaces, but quotes and + backslashes can override this. See + 'distutils.util.split_quoted()'.) + """ + + # Note that some CCompiler implementation classes will define class + # attributes 'cpp', 'cc', etc. with hard-coded executable names; + # this is appropriate when a compiler class is for exactly one + # compiler/OS combination (eg. MSVCCompiler). Other compiler + # classes (UnixCCompiler, in particular) are driven by information + # discovered at run-time, since there are many different ways to do + # basically the same things with Unix C compilers. + + for key in kwargs: + if key not in self.executables: + raise ValueError( + f"unknown executable '{key}' for class {self.__class__.__name__}" + ) + self.set_executable(key, kwargs[key]) + + def set_executable(self, key, value): + if isinstance(value, str): + setattr(self, key, split_quoted(value)) + else: + setattr(self, key, value) + + def _find_macro(self, name): + i = 0 + for defn in self.macros: + if defn[0] == name: + return i + i += 1 + return None + + def _check_macro_definitions(self, definitions): + """Ensure that every element of 'definitions' is valid.""" + for defn in definitions: + self._check_macro_definition(*defn) + + def _check_macro_definition(self, defn): + """ + Raise a TypeError if defn is not valid. + + A valid definition is either a (name, value) 2-tuple or a (name,) tuple. + """ + if not isinstance(defn, tuple) or not self._is_valid_macro(*defn): + raise TypeError( + f"invalid macro definition '{defn}': " + "must be tuple (string,), (string, string), or (string, None)" + ) + + @staticmethod + def _is_valid_macro(name, value=None): + """ + A valid macro is a ``name : str`` and a ``value : str | None``. + + >>> Compiler._is_valid_macro('foo', None) + True + """ + return isinstance(name, str) and isinstance(value, (str, type(None))) + + # -- Bookkeeping methods ------------------------------------------- + + def define_macro(self, name: str, value: str | None = None) -> None: + """Define a preprocessor macro for all compilations driven by this + compiler object. The optional parameter 'value' should be a + string; if it is not supplied, then the macro will be defined + without an explicit value and the exact outcome depends on the + compiler used (XXX true? does ANSI say anything about this?) + """ + # Delete from the list of macro definitions/undefinitions if + # already there (so that this one will take precedence). + i = self._find_macro(name) + if i is not None: + del self.macros[i] + + self.macros.append((name, value)) + + def undefine_macro(self, name: str) -> None: + """Undefine a preprocessor macro for all compilations driven by + this compiler object. If the same macro is defined by + 'define_macro()' and undefined by 'undefine_macro()' the last call + takes precedence (including multiple redefinitions or + undefinitions). If the macro is redefined/undefined on a + per-compilation basis (ie. in the call to 'compile()'), then that + takes precedence. + """ + # Delete from the list of macro definitions/undefinitions if + # already there (so that this one will take precedence). + i = self._find_macro(name) + if i is not None: + del self.macros[i] + + undefn = (name,) + self.macros.append(undefn) + + def add_include_dir(self, dir: str) -> None: + """Add 'dir' to the list of directories that will be searched for + header files. The compiler is instructed to search directories in + the order in which they are supplied by successive calls to + 'add_include_dir()'. + """ + self.include_dirs.append(dir) + + def set_include_dirs(self, dirs: list[str]) -> None: + """Set the list of directories that will be searched to 'dirs' (a + list of strings). Overrides any preceding calls to + 'add_include_dir()'; subsequence calls to 'add_include_dir()' add + to the list passed to 'set_include_dirs()'. This does not affect + any list of standard include directories that the compiler may + search by default. + """ + self.include_dirs = dirs[:] + + def add_library(self, libname: str) -> None: + """Add 'libname' to the list of libraries that will be included in + all links driven by this compiler object. Note that 'libname' + should *not* be the name of a file containing a library, but the + name of the library itself: the actual filename will be inferred by + the linker, the compiler, or the compiler class (depending on the + platform). + + The linker will be instructed to link against libraries in the + order they were supplied to 'add_library()' and/or + 'set_libraries()'. It is perfectly valid to duplicate library + names; the linker will be instructed to link against libraries as + many times as they are mentioned. + """ + self.libraries.append(libname) + + def set_libraries(self, libnames: list[str]) -> None: + """Set the list of libraries to be included in all links driven by + this compiler object to 'libnames' (a list of strings). This does + not affect any standard system libraries that the linker may + include by default. + """ + self.libraries = libnames[:] + + def add_library_dir(self, dir: str) -> None: + """Add 'dir' to the list of directories that will be searched for + libraries specified to 'add_library()' and 'set_libraries()'. The + linker will be instructed to search for libraries in the order they + are supplied to 'add_library_dir()' and/or 'set_library_dirs()'. + """ + self.library_dirs.append(dir) + + def set_library_dirs(self, dirs: list[str]) -> None: + """Set the list of library search directories to 'dirs' (a list of + strings). This does not affect any standard library search path + that the linker may search by default. + """ + self.library_dirs = dirs[:] + + def add_runtime_library_dir(self, dir: str) -> None: + """Add 'dir' to the list of directories that will be searched for + shared libraries at runtime. + """ + self.runtime_library_dirs.append(dir) + + def set_runtime_library_dirs(self, dirs: list[str]) -> None: + """Set the list of directories to search for shared libraries at + runtime to 'dirs' (a list of strings). This does not affect any + standard search path that the runtime linker may search by + default. + """ + self.runtime_library_dirs = dirs[:] + + def add_link_object(self, object: str) -> None: + """Add 'object' to the list of object files (or analogues, such as + explicitly named library files or the output of "resource + compilers") to be included in every link driven by this compiler + object. + """ + self.objects.append(object) + + def set_link_objects(self, objects: list[str]) -> None: + """Set the list of object files (or analogues) to be included in + every link to 'objects'. This does not affect any standard object + files that the linker may include by default (such as system + libraries). + """ + self.objects = objects[:] + + # -- Private utility methods -------------------------------------- + # (here for the convenience of subclasses) + + # Helper method to prep compiler in subclass compile() methods + + def _setup_compile( + self, + outdir: str | None, + macros: list[_Macro] | None, + incdirs: list[str] | tuple[str, ...] | None, + sources, + depends, + extra, + ): + """Process arguments and decide which source files to compile.""" + outdir, macros, incdirs = self._fix_compile_args(outdir, macros, incdirs) + + if extra is None: + extra = [] + + # Get the list of expected output (object) files + objects = self.object_filenames(sources, strip_dir=False, output_dir=outdir) + assert len(objects) == len(sources) + + pp_opts = gen_preprocess_options(macros, incdirs) + + build = {} + for i in range(len(sources)): + src = sources[i] + obj = objects[i] + ext = os.path.splitext(src)[1] + self.mkpath(os.path.dirname(obj)) + build[obj] = (src, ext) + + return macros, objects, extra, pp_opts, build + + def _get_cc_args(self, pp_opts, debug, before): + # works for unixccompiler, cygwinccompiler + cc_args = pp_opts + ['-c'] + if debug: + cc_args[:0] = ['-g'] + if before: + cc_args[:0] = before + return cc_args + + def _fix_compile_args( + self, + output_dir: str | None, + macros: list[_Macro] | None, + include_dirs: list[str] | tuple[str, ...] | None, + ) -> tuple[str, list[_Macro], list[str]]: + """Typecheck and fix-up some of the arguments to the 'compile()' + method, and return fixed-up values. Specifically: if 'output_dir' + is None, replaces it with 'self.output_dir'; ensures that 'macros' + is a list, and augments it with 'self.macros'; ensures that + 'include_dirs' is a list, and augments it with 'self.include_dirs'. + Guarantees that the returned values are of the correct type, + i.e. for 'output_dir' either string or None, and for 'macros' and + 'include_dirs' either list or None. + """ + if output_dir is None: + output_dir = self.output_dir + elif not isinstance(output_dir, str): + raise TypeError("'output_dir' must be a string or None") + + if macros is None: + macros = list(self.macros) + elif isinstance(macros, list): + macros = macros + (self.macros or []) + else: + raise TypeError("'macros' (if supplied) must be a list of tuples") + + if include_dirs is None: + include_dirs = list(self.include_dirs) + elif isinstance(include_dirs, (list, tuple)): + include_dirs = list(include_dirs) + (self.include_dirs or []) + else: + raise TypeError("'include_dirs' (if supplied) must be a list of strings") + + # add include dirs for class + include_dirs += self.__class__.include_dirs + + return output_dir, macros, include_dirs + + def _prep_compile(self, sources, output_dir, depends=None): + """Decide which source files must be recompiled. + + Determine the list of object files corresponding to 'sources', + and figure out which ones really need to be recompiled. + Return a list of all object files and a dictionary telling + which source files can be skipped. + """ + # Get the list of expected output (object) files + objects = self.object_filenames(sources, output_dir=output_dir) + assert len(objects) == len(sources) + + # Return an empty dict for the "which source files can be skipped" + # return value to preserve API compatibility. + return objects, {} + + def _fix_object_args( + self, objects: list[str] | tuple[str, ...], output_dir: str | None + ) -> tuple[list[str], str]: + """Typecheck and fix up some arguments supplied to various methods. + Specifically: ensure that 'objects' is a list; if output_dir is + None, replace with self.output_dir. Return fixed versions of + 'objects' and 'output_dir'. + """ + if not isinstance(objects, (list, tuple)): + raise TypeError("'objects' must be a list or tuple of strings") + objects = list(objects) + + if output_dir is None: + output_dir = self.output_dir + elif not isinstance(output_dir, str): + raise TypeError("'output_dir' must be a string or None") + + return (objects, output_dir) + + def _fix_lib_args( + self, + libraries: list[str] | tuple[str, ...] | None, + library_dirs: list[str] | tuple[str, ...] | None, + runtime_library_dirs: list[str] | tuple[str, ...] | None, + ) -> tuple[list[str], list[str], list[str]]: + """Typecheck and fix up some of the arguments supplied to the + 'link_*' methods. Specifically: ensure that all arguments are + lists, and augment them with their permanent versions + (eg. 'self.libraries' augments 'libraries'). Return a tuple with + fixed versions of all arguments. + """ + if libraries is None: + libraries = list(self.libraries) + elif isinstance(libraries, (list, tuple)): + libraries = list(libraries) + (self.libraries or []) + else: + raise TypeError("'libraries' (if supplied) must be a list of strings") + + if library_dirs is None: + library_dirs = list(self.library_dirs) + elif isinstance(library_dirs, (list, tuple)): + library_dirs = list(library_dirs) + (self.library_dirs or []) + else: + raise TypeError("'library_dirs' (if supplied) must be a list of strings") + + # add library dirs for class + library_dirs += self.__class__.library_dirs + + if runtime_library_dirs is None: + runtime_library_dirs = list(self.runtime_library_dirs) + elif isinstance(runtime_library_dirs, (list, tuple)): + runtime_library_dirs = list(runtime_library_dirs) + ( + self.runtime_library_dirs or [] + ) + else: + raise TypeError( + "'runtime_library_dirs' (if supplied) must be a list of strings" + ) + + return (libraries, library_dirs, runtime_library_dirs) + + def _need_link(self, objects, output_file): + """Return true if we need to relink the files listed in 'objects' + to recreate 'output_file'. + """ + if self.force: + return True + newer = newer_group(objects, output_file) + return newer + + def detect_language(self, sources: str | list[str]) -> str | None: + """Detect the language of a given file, or list of files. Uses + language_map, and language_order to do the job. + """ + if not isinstance(sources, list): + sources = [sources] + lang = None + index = len(self.language_order) + for source in sources: + base, ext = os.path.splitext(source) + extlang = self.language_map.get(ext) + try: + extindex = self.language_order.index(extlang) + if extindex < index: + lang = extlang + index = extindex + except ValueError: + pass + return lang + + # -- Worker methods ------------------------------------------------ + # (must be implemented by subclasses) + + def preprocess( + self, + source: str | os.PathLike[str], + output_file: str | os.PathLike[str] | None = None, + macros: list[_Macro] | None = None, + include_dirs: list[str] | tuple[str, ...] | None = None, + extra_preargs: list[str] | None = None, + extra_postargs: Iterable[str] | None = None, + ): + """Preprocess a single C/C++ source file, named in 'source'. + Output will be written to file named 'output_file', or stdout if + 'output_file' not supplied. 'macros' is a list of macro + definitions as for 'compile()', which will augment the macros set + with 'define_macro()' and 'undefine_macro()'. 'include_dirs' is a + list of directory names that will be added to the default list. + + Raises PreprocessError on failure. + """ + pass + + def compile( + self, + sources: Sequence[str | os.PathLike[str]], + output_dir: str | None = None, + macros: list[_Macro] | None = None, + include_dirs: list[str] | tuple[str, ...] | None = None, + debug: bool = False, + extra_preargs: list[str] | None = None, + extra_postargs: list[str] | None = None, + depends: list[str] | tuple[str, ...] | None = None, + ) -> list[str]: + """Compile one or more source files. + + 'sources' must be a list of filenames, most likely C/C++ + files, but in reality anything that can be handled by a + particular compiler and compiler class (eg. MSVCCompiler can + handle resource files in 'sources'). Return a list of object + filenames, one per source filename in 'sources'. Depending on + the implementation, not all source files will necessarily be + compiled, but all corresponding object filenames will be + returned. + + If 'output_dir' is given, object files will be put under it, while + retaining their original path component. That is, "foo/bar.c" + normally compiles to "foo/bar.o" (for a Unix implementation); if + 'output_dir' is "build", then it would compile to + "build/foo/bar.o". + + 'macros', if given, must be a list of macro definitions. A macro + definition is either a (name, value) 2-tuple or a (name,) 1-tuple. + The former defines a macro; if the value is None, the macro is + defined without an explicit value. The 1-tuple case undefines a + macro. Later definitions/redefinitions/ undefinitions take + precedence. + + 'include_dirs', if given, must be a list of strings, the + directories to add to the default include file search path for this + compilation only. + + 'debug' is a boolean; if true, the compiler will be instructed to + output debug symbols in (or alongside) the object file(s). + + 'extra_preargs' and 'extra_postargs' are implementation- dependent. + On platforms that have the notion of a command-line (e.g. Unix, + DOS/Windows), they are most likely lists of strings: extra + command-line arguments to prepend/append to the compiler command + line. On other platforms, consult the implementation class + documentation. In any event, they are intended as an escape hatch + for those occasions when the abstract compiler framework doesn't + cut the mustard. + + 'depends', if given, is a list of filenames that all targets + depend on. If a source file is older than any file in + depends, then the source file will be recompiled. This + supports dependency tracking, but only at a coarse + granularity. + + Raises CompileError on failure. + """ + # A concrete compiler class can either override this method + # entirely or implement _compile(). + macros, objects, extra_postargs, pp_opts, build = self._setup_compile( + output_dir, macros, include_dirs, sources, depends, extra_postargs + ) + cc_args = self._get_cc_args(pp_opts, debug, extra_preargs) + + for obj in objects: + try: + src, ext = build[obj] + except KeyError: + continue + self._compile(obj, src, ext, cc_args, extra_postargs, pp_opts) + + # Return *all* object filenames, not just the ones we just built. + return objects + + def _compile(self, obj, src, ext, cc_args, extra_postargs, pp_opts): + """Compile 'src' to product 'obj'.""" + # A concrete compiler class that does not override compile() + # should implement _compile(). + pass + + def create_static_lib( + self, + objects: list[str] | tuple[str, ...], + output_libname: str, + output_dir: str | None = None, + debug: bool = False, + target_lang: str | None = None, + ) -> None: + """Link a bunch of stuff together to create a static library file. + The "bunch of stuff" consists of the list of object files supplied + as 'objects', the extra object files supplied to + 'add_link_object()' and/or 'set_link_objects()', the libraries + supplied to 'add_library()' and/or 'set_libraries()', and the + libraries supplied as 'libraries' (if any). + + 'output_libname' should be a library name, not a filename; the + filename will be inferred from the library name. 'output_dir' is + the directory where the library file will be put. + + 'debug' is a boolean; if true, debugging information will be + included in the library (note that on most platforms, it is the + compile step where this matters: the 'debug' flag is included here + just for consistency). + + 'target_lang' is the target language for which the given objects + are being compiled. This allows specific linkage time treatment of + certain languages. + + Raises LibError on failure. + """ + pass + + # values for target_desc parameter in link() + SHARED_OBJECT = "shared_object" + SHARED_LIBRARY = "shared_library" + EXECUTABLE = "executable" + + def link( + self, + target_desc: str, + objects: list[str] | tuple[str, ...], + output_filename: str, + output_dir: str | None = None, + libraries: list[str] | tuple[str, ...] | None = None, + library_dirs: list[str] | tuple[str, ...] | None = None, + runtime_library_dirs: list[str] | tuple[str, ...] | None = None, + export_symbols: Iterable[str] | None = None, + debug: bool = False, + extra_preargs: list[str] | None = None, + extra_postargs: list[str] | None = None, + build_temp: str | os.PathLike[str] | None = None, + target_lang: str | None = None, + ): + """Link a bunch of stuff together to create an executable or + shared library file. + + The "bunch of stuff" consists of the list of object files supplied + as 'objects'. 'output_filename' should be a filename. If + 'output_dir' is supplied, 'output_filename' is relative to it + (i.e. 'output_filename' can provide directory components if + needed). + + 'libraries' is a list of libraries to link against. These are + library names, not filenames, since they're translated into + filenames in a platform-specific way (eg. "foo" becomes "libfoo.a" + on Unix and "foo.lib" on DOS/Windows). However, they can include a + directory component, which means the linker will look in that + specific directory rather than searching all the normal locations. + + 'library_dirs', if supplied, should be a list of directories to + search for libraries that were specified as bare library names + (ie. no directory component). These are on top of the system + default and those supplied to 'add_library_dir()' and/or + 'set_library_dirs()'. 'runtime_library_dirs' is a list of + directories that will be embedded into the shared library and used + to search for other shared libraries that *it* depends on at + run-time. (This may only be relevant on Unix.) + + 'export_symbols' is a list of symbols that the shared library will + export. (This appears to be relevant only on Windows.) + + 'debug' is as for 'compile()' and 'create_static_lib()', with the + slight distinction that it actually matters on most platforms (as + opposed to 'create_static_lib()', which includes a 'debug' flag + mostly for form's sake). + + 'extra_preargs' and 'extra_postargs' are as for 'compile()' (except + of course that they supply command-line arguments for the + particular linker being used). + + 'target_lang' is the target language for which the given objects + are being compiled. This allows specific linkage time treatment of + certain languages. + + Raises LinkError on failure. + """ + raise NotImplementedError + + # Old 'link_*()' methods, rewritten to use the new 'link()' method. + + def link_shared_lib( + self, + objects: list[str] | tuple[str, ...], + output_libname: str, + output_dir: str | None = None, + libraries: list[str] | tuple[str, ...] | None = None, + library_dirs: list[str] | tuple[str, ...] | None = None, + runtime_library_dirs: list[str] | tuple[str, ...] | None = None, + export_symbols: Iterable[str] | None = None, + debug: bool = False, + extra_preargs: list[str] | None = None, + extra_postargs: list[str] | None = None, + build_temp: str | os.PathLike[str] | None = None, + target_lang: str | None = None, + ): + self.link( + Compiler.SHARED_LIBRARY, + objects, + self.library_filename(output_libname, lib_type='shared'), + output_dir, + libraries, + library_dirs, + runtime_library_dirs, + export_symbols, + debug, + extra_preargs, + extra_postargs, + build_temp, + target_lang, + ) + + def link_shared_object( + self, + objects: list[str] | tuple[str, ...], + output_filename: str, + output_dir: str | None = None, + libraries: list[str] | tuple[str, ...] | None = None, + library_dirs: list[str] | tuple[str, ...] | None = None, + runtime_library_dirs: list[str] | tuple[str, ...] | None = None, + export_symbols: Iterable[str] | None = None, + debug: bool = False, + extra_preargs: list[str] | None = None, + extra_postargs: list[str] | None = None, + build_temp: str | os.PathLike[str] | None = None, + target_lang: str | None = None, + ): + self.link( + Compiler.SHARED_OBJECT, + objects, + output_filename, + output_dir, + libraries, + library_dirs, + runtime_library_dirs, + export_symbols, + debug, + extra_preargs, + extra_postargs, + build_temp, + target_lang, + ) + + def link_executable( + self, + objects: list[str] | tuple[str, ...], + output_progname: str, + output_dir: str | None = None, + libraries: list[str] | tuple[str, ...] | None = None, + library_dirs: list[str] | tuple[str, ...] | None = None, + runtime_library_dirs: list[str] | tuple[str, ...] | None = None, + debug: bool = False, + extra_preargs: list[str] | None = None, + extra_postargs: list[str] | None = None, + target_lang: str | None = None, + ): + self.link( + Compiler.EXECUTABLE, + objects, + self.executable_filename(output_progname), + output_dir, + libraries, + library_dirs, + runtime_library_dirs, + None, + debug, + extra_preargs, + extra_postargs, + None, + target_lang, + ) + + # -- Miscellaneous methods ----------------------------------------- + # These are all used by the 'gen_lib_options() function; there is + # no appropriate default implementation so subclasses should + # implement all of these. + + def library_dir_option(self, dir: str) -> str: + """Return the compiler option to add 'dir' to the list of + directories searched for libraries. + """ + raise NotImplementedError + + def runtime_library_dir_option(self, dir: str) -> str: + """Return the compiler option to add 'dir' to the list of + directories searched for runtime libraries. + """ + raise NotImplementedError + + def library_option(self, lib: str) -> str: + """Return the compiler option to add 'lib' to the list of libraries + linked into the shared library or executable. + """ + raise NotImplementedError + + def has_function( # noqa: C901 + self, + funcname: str, + includes: Iterable[str] | None = None, + include_dirs: list[str] | tuple[str, ...] | None = None, + libraries: list[str] | None = None, + library_dirs: list[str] | tuple[str, ...] | None = None, + ) -> bool: + """Return a boolean indicating whether funcname is provided as + a symbol on the current platform. The optional arguments can + be used to augment the compilation environment. + + The libraries argument is a list of flags to be passed to the + linker to make additional symbol definitions available for + linking. + + The includes and include_dirs arguments are deprecated. + Usually, supplying include files with function declarations + will cause function detection to fail even in cases where the + symbol is available for linking. + + """ + # this can't be included at module scope because it tries to + # import math which might not be available at that point - maybe + # the necessary logic should just be inlined? + import tempfile + + if includes is None: + includes = [] + else: + warnings.warn("includes is deprecated", DeprecationWarning) + if include_dirs is None: + include_dirs = [] + else: + warnings.warn("include_dirs is deprecated", DeprecationWarning) + if libraries is None: + libraries = [] + if library_dirs is None: + library_dirs = [] + fd, fname = tempfile.mkstemp(".c", funcname, text=True) + with os.fdopen(fd, "w", encoding='utf-8') as f: + for incl in includes: + f.write(f"""#include "{incl}"\n""") + if not includes: + # Use "char func(void);" as the prototype to follow + # what autoconf does. This prototype does not match + # any well-known function the compiler might recognize + # as a builtin, so this ends up as a true link test. + # Without a fake prototype, the test would need to + # know the exact argument types, and the has_function + # interface does not provide that level of information. + f.write( + f"""\ +#ifdef __cplusplus +extern "C" +#endif +char {funcname}(void); +""" + ) + f.write( + f"""\ +int main (int argc, char **argv) {{ + {funcname}(); + return 0; +}} +""" + ) + + try: + objects = self.compile([fname], include_dirs=include_dirs) + except CompileError: + return False + finally: + os.remove(fname) + + try: + self.link_executable( + objects, "a.out", libraries=libraries, library_dirs=library_dirs + ) + except (LinkError, TypeError): + return False + else: + os.remove( + self.executable_filename("a.out", output_dir=self.output_dir or '') + ) + finally: + for fn in objects: + os.remove(fn) + return True + + def find_library_file( + self, dirs: Iterable[str], lib: str, debug: bool = False + ) -> str | None: + """Search the specified list of directories for a static or shared + library file 'lib' and return the full path to that file. If + 'debug' true, look for a debugging version (if that makes sense on + the current platform). Return None if 'lib' wasn't found in any of + the specified directories. + """ + raise NotImplementedError + + # -- Filename generation methods ----------------------------------- + + # The default implementation of the filename generating methods are + # prejudiced towards the Unix/DOS/Windows view of the world: + # * object files are named by replacing the source file extension + # (eg. .c/.cpp -> .o/.obj) + # * library files (shared or static) are named by plugging the + # library name and extension into a format string, eg. + # "lib%s.%s" % (lib_name, ".a") for Unix static libraries + # * executables are named by appending an extension (possibly + # empty) to the program name: eg. progname + ".exe" for + # Windows + # + # To reduce redundant code, these methods expect to find + # several attributes in the current object (presumably defined + # as class attributes): + # * src_extensions - + # list of C/C++ source file extensions, eg. ['.c', '.cpp'] + # * obj_extension - + # object file extension, eg. '.o' or '.obj' + # * static_lib_extension - + # extension for static library files, eg. '.a' or '.lib' + # * shared_lib_extension - + # extension for shared library/object files, eg. '.so', '.dll' + # * static_lib_format - + # format string for generating static library filenames, + # eg. 'lib%s.%s' or '%s.%s' + # * shared_lib_format + # format string for generating shared library filenames + # (probably same as static_lib_format, since the extension + # is one of the intended parameters to the format string) + # * exe_extension - + # extension for executable files, eg. '' or '.exe' + + def object_filenames( + self, + source_filenames: Iterable[str | os.PathLike[str]], + strip_dir: bool = False, + output_dir: str | os.PathLike[str] | None = '', + ) -> list[str]: + if output_dir is None: + output_dir = '' + return list( + self._make_out_path(output_dir, strip_dir, src_name) + for src_name in source_filenames + ) + + @property + def out_extensions(self): + return dict.fromkeys(self.src_extensions, self.obj_extension) + + def _make_out_path(self, output_dir, strip_dir, src_name): + return self._make_out_path_exts( + output_dir, strip_dir, src_name, self.out_extensions + ) + + @classmethod + def _make_out_path_exts(cls, output_dir, strip_dir, src_name, extensions): + r""" + >>> exts = {'.c': '.o'} + >>> Compiler._make_out_path_exts('.', False, '/foo/bar.c', exts).replace('\\', '/') + './foo/bar.o' + >>> Compiler._make_out_path_exts('.', True, '/foo/bar.c', exts).replace('\\', '/') + './bar.o' + """ + src = pathlib.PurePath(src_name) + # Ensure base is relative to honor output_dir (python/cpython#37775). + base = cls._make_relative(src) + try: + new_ext = extensions[src.suffix] + except LookupError: + raise UnknownFileType(f"unknown file type '{src.suffix}' (from '{src}')") + if strip_dir: + base = pathlib.PurePath(base.name) + return os.path.join(output_dir, base.with_suffix(new_ext)) + + @staticmethod + def _make_relative(base: pathlib.Path): + return base.relative_to(base.anchor) + + @overload + def shared_object_filename( + self, + basename: str, + strip_dir: Literal[False] = False, + output_dir: str | os.PathLike[str] = "", + ) -> str: ... + @overload + def shared_object_filename( + self, + basename: str | os.PathLike[str], + strip_dir: Literal[True], + output_dir: str | os.PathLike[str] = "", + ) -> str: ... + def shared_object_filename( + self, + basename: str | os.PathLike[str], + strip_dir: bool = False, + output_dir: str | os.PathLike[str] = '', + ) -> str: + assert output_dir is not None + if strip_dir: + basename = os.path.basename(basename) + return os.path.join(output_dir, basename + self.shared_lib_extension) + + @overload + def executable_filename( + self, + basename: str, + strip_dir: Literal[False] = False, + output_dir: str | os.PathLike[str] = "", + ) -> str: ... + @overload + def executable_filename( + self, + basename: str | os.PathLike[str], + strip_dir: Literal[True], + output_dir: str | os.PathLike[str] = "", + ) -> str: ... + def executable_filename( + self, + basename: str | os.PathLike[str], + strip_dir: bool = False, + output_dir: str | os.PathLike[str] = '', + ) -> str: + assert output_dir is not None + if strip_dir: + basename = os.path.basename(basename) + return os.path.join(output_dir, basename + (self.exe_extension or '')) + + def library_filename( + self, + libname: str, + lib_type: str = "static", + strip_dir: bool = False, + output_dir: str | os.PathLike[str] = "", # or 'shared' + ): + assert output_dir is not None + expected = '"static", "shared", "dylib", "xcode_stub"' + if lib_type not in eval(expected): + raise ValueError(f"'lib_type' must be {expected}") + fmt = getattr(self, lib_type + "_lib_format") + ext = getattr(self, lib_type + "_lib_extension") + + dir, base = os.path.split(libname) + filename = fmt % (base, ext) + if strip_dir: + dir = '' + + return os.path.join(output_dir, dir, filename) + + # -- Utility methods ----------------------------------------------- + + def announce(self, msg: object, level: int = 1) -> None: + log.debug(msg) + + def debug_print(self, msg: object) -> None: + from distutils.debug import DEBUG + + if DEBUG: + print(msg) + + def warn(self, msg: object) -> None: + sys.stderr.write(f"warning: {msg}\n") + + def execute( + self, + func: Callable[[Unpack[_Ts]], object], + args: tuple[Unpack[_Ts]], + msg: object = None, + level: int = 1, + ) -> None: + execute(func, args, msg) + + def spawn( + self, cmd: MutableSequence[bytes | str | os.PathLike[str]], **kwargs + ) -> None: + spawn(cmd, **kwargs) + + @overload + def move_file( + self, src: str | os.PathLike[str], dst: _StrPathT + ) -> _StrPathT | str: ... + @overload + def move_file( + self, src: bytes | os.PathLike[bytes], dst: _BytesPathT + ) -> _BytesPathT | bytes: ... + def move_file( + self, + src: str | os.PathLike[str] | bytes | os.PathLike[bytes], + dst: str | os.PathLike[str] | bytes | os.PathLike[bytes], + ) -> str | os.PathLike[str] | bytes | os.PathLike[bytes]: + return move_file(src, dst) + + def mkpath(self, name, mode=0o777): + mkpath(name, mode) + + +# Map a sys.platform/os.name ('posix', 'nt') to the default compiler +# type for that platform. Keys are interpreted as re match +# patterns. Order is important; platform mappings are preferred over +# OS names. +_default_compilers = ( + # Platform string mappings + # on a cygwin built python we can use gcc like an ordinary UNIXish + # compiler + ('cygwin.*', 'unix'), + ('zos', 'zos'), + # OS name mappings + ('posix', 'unix'), + ('nt', 'msvc'), +) + + +def get_default_compiler(osname: str | None = None, platform: str | None = None) -> str: + """Determine the default compiler to use for the given platform. + + osname should be one of the standard Python OS names (i.e. the + ones returned by os.name) and platform the common value + returned by sys.platform for the platform in question. + + The default values are os.name and sys.platform in case the + parameters are not given. + """ + if osname is None: + osname = os.name + if platform is None: + platform = sys.platform + # Mingw is a special case where sys.platform is 'win32' but we + # want to use the 'mingw32' compiler, so check it first + if is_mingw(): + return 'mingw32' + for pattern, compiler in _default_compilers: + if ( + re.match(pattern, platform) is not None + or re.match(pattern, osname) is not None + ): + return compiler + # Default to Unix compiler + return 'unix' + + +# Map compiler types to (module_name, class_name) pairs -- ie. where to +# find the code that implements an interface to this compiler. (The module +# is assumed to be in the 'distutils' package.) +compiler_class = { + 'unix': ('unixccompiler', 'UnixCCompiler', "standard UNIX-style compiler"), + 'msvc': ('_msvccompiler', 'MSVCCompiler', "Microsoft Visual C++"), + 'cygwin': ( + 'cygwinccompiler', + 'CygwinCCompiler', + "Cygwin port of GNU C Compiler for Win32", + ), + 'mingw32': ( + 'cygwinccompiler', + 'Mingw32CCompiler', + "Mingw32 port of GNU C Compiler for Win32", + ), + 'bcpp': ('bcppcompiler', 'BCPPCompiler', "Borland C++ Compiler"), + 'zos': ('zosccompiler', 'zOSCCompiler', 'IBM XL C/C++ Compilers'), +} + + +def show_compilers() -> None: + """Print list of available compilers (used by the "--help-compiler" + options to "build", "build_ext", "build_clib"). + """ + # XXX this "knows" that the compiler option it's describing is + # "--compiler", which just happens to be the case for the three + # commands that use it. + from distutils.fancy_getopt import FancyGetopt + + compilers = sorted( + ("compiler=" + compiler, None, compiler_class[compiler][2]) + for compiler in compiler_class.keys() + ) + pretty_printer = FancyGetopt(compilers) + pretty_printer.print_help("List of available compilers:") + + +def new_compiler( + plat: str | None = None, + compiler: str | None = None, + verbose: bool = False, + force: bool = False, +) -> Compiler: + """Generate an instance of some CCompiler subclass for the supplied + platform/compiler combination. 'plat' defaults to 'os.name' + (eg. 'posix', 'nt'), and 'compiler' defaults to the default compiler + for that platform. Currently only 'posix' and 'nt' are supported, and + the default compilers are "traditional Unix interface" (UnixCCompiler + class) and Visual C++ (MSVCCompiler class). Note that it's perfectly + possible to ask for a Unix compiler object under Windows, and a + Microsoft compiler object under Unix -- if you supply a value for + 'compiler', 'plat' is ignored. + """ + if plat is None: + plat = os.name + + try: + if compiler is None: + compiler = get_default_compiler(plat) + + (module_name, class_name, long_description) = compiler_class[compiler] + except KeyError: + msg = f"don't know how to compile C/C++ code on platform '{plat}'" + if compiler is not None: + msg = msg + f" with '{compiler}' compiler" + raise DistutilsPlatformError(msg) + + try: + module_name = "distutils." + module_name + __import__(module_name) + module = sys.modules[module_name] + klass = vars(module)[class_name] + except ImportError: + raise DistutilsModuleError( + f"can't compile C/C++ code: unable to load module '{module_name}'" + ) + except KeyError: + raise DistutilsModuleError( + f"can't compile C/C++ code: unable to find class '{class_name}' " + f"in module '{module_name}'" + ) + + # XXX The None is necessary to preserve backwards compatibility + # with classes that expect verbose to be the first positional + # argument. + return klass(None, force=force) + + +def gen_preprocess_options( + macros: Iterable[_Macro], include_dirs: Iterable[str] +) -> list[str]: + """Generate C pre-processor options (-D, -U, -I) as used by at least + two types of compilers: the typical Unix compiler and Visual C++. + 'macros' is the usual thing, a list of 1- or 2-tuples, where (name,) + means undefine (-U) macro 'name', and (name,value) means define (-D) + macro 'name' to 'value'. 'include_dirs' is just a list of directory + names to be added to the header file search path (-I). Returns a list + of command-line options suitable for either Unix compilers or Visual + C++. + """ + # XXX it would be nice (mainly aesthetic, and so we don't generate + # stupid-looking command lines) to go over 'macros' and eliminate + # redundant definitions/undefinitions (ie. ensure that only the + # latest mention of a particular macro winds up on the command + # line). I don't think it's essential, though, since most (all?) + # Unix C compilers only pay attention to the latest -D or -U + # mention of a macro on their command line. Similar situation for + # 'include_dirs'. I'm punting on both for now. Anyways, weeding out + # redundancies like this should probably be the province of + # CCompiler, since the data structures used are inherited from it + # and therefore common to all CCompiler classes. + pp_opts = [] + for macro in macros: + if not (isinstance(macro, tuple) and 1 <= len(macro) <= 2): + raise TypeError( + f"bad macro definition '{macro}': " + "each element of 'macros' list must be a 1- or 2-tuple" + ) + + if len(macro) == 1: # undefine this macro + pp_opts.append(f"-U{macro[0]}") + elif len(macro) == 2: + if macro[1] is None: # define with no explicit value + pp_opts.append(f"-D{macro[0]}") + else: + # XXX *don't* need to be clever about quoting the + # macro value here, because we're going to avoid the + # shell at all costs when we spawn the command! + pp_opts.append("-D{}={}".format(*macro)) + + pp_opts.extend(f"-I{dir}" for dir in include_dirs) + return pp_opts + + +def gen_lib_options( + compiler: Compiler, + library_dirs: Iterable[str], + runtime_library_dirs: Iterable[str], + libraries: Iterable[str], +) -> list[str]: + """Generate linker options for searching library directories and + linking with specific libraries. 'libraries' and 'library_dirs' are, + respectively, lists of library names (not filenames!) and search + directories. Returns a list of command-line options suitable for use + with some compiler (depending on the two format strings passed in). + """ + lib_opts = [compiler.library_dir_option(dir) for dir in library_dirs] + + for dir in runtime_library_dirs: + lib_opts.extend(always_iterable(compiler.runtime_library_dir_option(dir))) + + # XXX it's important that we *not* remove redundant library mentions! + # sometimes you really do have to say "-lfoo -lbar -lfoo" in order to + # resolve all symbols. I just hope we never have to say "-lfoo obj.o + # -lbar" to get things to work -- that's certainly a possibility, but a + # pretty nasty way to arrange your C code. + + for lib in libraries: + (lib_dir, lib_name) = os.path.split(lib) + if lib_dir: + lib_file = compiler.find_library_file([lib_dir], lib_name) + if lib_file: + lib_opts.append(lib_file) + else: + compiler.warn( + f"no library file corresponding to '{lib}' found (skipping)" + ) + else: + lib_opts.append(compiler.library_option(lib)) + return lib_opts diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/cygwin.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/cygwin.py new file mode 100644 index 0000000000000000000000000000000000000000..f349e9decd083ad60a9b9d1181b57e1bbcce2c98 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/cygwin.py @@ -0,0 +1,340 @@ +"""distutils.cygwinccompiler + +Provides the CygwinCCompiler class, a subclass of UnixCCompiler that +handles the Cygwin port of the GNU C compiler to Windows. It also contains +the Mingw32CCompiler class which handles the mingw32 port of GCC (same as +cygwin in no-cygwin mode). +""" + +import copy +import os +import pathlib +import shlex +import sys +import warnings +from subprocess import check_output + +from ...errors import ( + DistutilsExecError, + DistutilsPlatformError, +) +from ...file_util import write_file +from ...sysconfig import get_config_vars +from ...version import LooseVersion, suppress_known_deprecation +from . import unix +from .errors import ( + CompileError, + Error, +) + + +def get_msvcr(): + """No longer needed, but kept for backward compatibility.""" + return [] + + +_runtime_library_dirs_msg = ( + "Unable to set runtime library search path on Windows, " + "usually indicated by `runtime_library_dirs` parameter to Extension" +) + + +class Compiler(unix.Compiler): + """Handles the Cygwin port of the GNU C compiler to Windows.""" + + compiler_type = 'cygwin' + obj_extension = ".o" + static_lib_extension = ".a" + shared_lib_extension = ".dll.a" + dylib_lib_extension = ".dll" + static_lib_format = "lib%s%s" + shared_lib_format = "lib%s%s" + dylib_lib_format = "cyg%s%s" + exe_extension = ".exe" + + def __init__(self, verbose=False, force=False): + super().__init__(verbose, force=force) + + status, details = check_config_h() + self.debug_print(f"Python's GCC status: {status} (details: {details})") + if status is not CONFIG_H_OK: + self.warn( + "Python's pyconfig.h doesn't seem to support your compiler. " + f"Reason: {details}. " + "Compiling may fail because of undefined preprocessor macros." + ) + + self.cc, self.cxx = get_config_vars('CC', 'CXX') + + # Override 'CC' and 'CXX' environment variables for + # building using MINGW compiler for MSVC python. + self.cc = os.environ.get('CC', self.cc or 'gcc') + self.cxx = os.environ.get('CXX', self.cxx or 'g++') + + self.linker_dll = self.cc + self.linker_dll_cxx = self.cxx + shared_option = "-shared" + + self.set_executables( + compiler=f'{self.cc} -mcygwin -O -Wall', + compiler_so=f'{self.cc} -mcygwin -mdll -O -Wall', + compiler_cxx=f'{self.cxx} -mcygwin -O -Wall', + compiler_so_cxx=f'{self.cxx} -mcygwin -mdll -O -Wall', + linker_exe=f'{self.cc} -mcygwin', + linker_so=f'{self.linker_dll} -mcygwin {shared_option}', + linker_exe_cxx=f'{self.cxx} -mcygwin', + linker_so_cxx=f'{self.linker_dll_cxx} -mcygwin {shared_option}', + ) + + self.dll_libraries = get_msvcr() + + @property + def gcc_version(self): + # Older numpy depended on this existing to check for ancient + # gcc versions. This doesn't make much sense with clang etc so + # just hardcode to something recent. + # https://github.com/numpy/numpy/pull/20333 + warnings.warn( + "gcc_version attribute of CygwinCCompiler is deprecated. " + "Instead of returning actual gcc version a fixed value 11.2.0 is returned.", + DeprecationWarning, + stacklevel=2, + ) + with suppress_known_deprecation(): + return LooseVersion("11.2.0") + + def _compile(self, obj, src, ext, cc_args, extra_postargs, pp_opts): + """Compiles the source by spawning GCC and windres if needed.""" + if ext in ('.rc', '.res'): + # gcc needs '.res' and '.rc' compiled to object files !!! + try: + self.spawn(["windres", "-i", src, "-o", obj]) + except DistutilsExecError as msg: + raise CompileError(msg) + else: # for other files use the C-compiler + try: + if self.detect_language(src) == 'c++': + self.spawn( + self.compiler_so_cxx + + cc_args + + [src, '-o', obj] + + extra_postargs + ) + else: + self.spawn( + self.compiler_so + cc_args + [src, '-o', obj] + extra_postargs + ) + except DistutilsExecError as msg: + raise CompileError(msg) + + def link( + self, + target_desc, + objects, + output_filename, + output_dir=None, + libraries=None, + library_dirs=None, + runtime_library_dirs=None, + export_symbols=None, + debug=False, + extra_preargs=None, + extra_postargs=None, + build_temp=None, + target_lang=None, + ): + """Link the objects.""" + # use separate copies, so we can modify the lists + extra_preargs = copy.copy(extra_preargs or []) + libraries = copy.copy(libraries or []) + objects = copy.copy(objects or []) + + if runtime_library_dirs: + self.warn(_runtime_library_dirs_msg) + + # Additional libraries + libraries.extend(self.dll_libraries) + + # handle export symbols by creating a def-file + # with executables this only works with gcc/ld as linker + if (export_symbols is not None) and ( + target_desc != self.EXECUTABLE or self.linker_dll == "gcc" + ): + # (The linker doesn't do anything if output is up-to-date. + # So it would probably better to check if we really need this, + # but for this we had to insert some unchanged parts of + # UnixCCompiler, and this is not what we want.) + + # we want to put some files in the same directory as the + # object files are, build_temp doesn't help much + # where are the object files + temp_dir = os.path.dirname(objects[0]) + # name of dll to give the helper files the same base name + (dll_name, dll_extension) = os.path.splitext( + os.path.basename(output_filename) + ) + + # generate the filenames for these files + def_file = os.path.join(temp_dir, dll_name + ".def") + + # Generate .def file + contents = [f"LIBRARY {os.path.basename(output_filename)}", "EXPORTS"] + contents.extend(export_symbols) + self.execute(write_file, (def_file, contents), f"writing {def_file}") + + # next add options for def-file + + # for gcc/ld the def-file is specified as any object files + objects.append(def_file) + + # end: if ((export_symbols is not None) and + # (target_desc != self.EXECUTABLE or self.linker_dll == "gcc")): + + # who wants symbols and a many times larger output file + # should explicitly switch the debug mode on + # otherwise we let ld strip the output file + # (On my machine: 10KiB < stripped_file < ??100KiB + # unstripped_file = stripped_file + XXX KiB + # ( XXX=254 for a typical python extension)) + if not debug: + extra_preargs.append("-s") + + super().link( + target_desc, + objects, + output_filename, + output_dir, + libraries, + library_dirs, + runtime_library_dirs, + None, # export_symbols, we do this in our def-file + debug, + extra_preargs, + extra_postargs, + build_temp, + target_lang, + ) + + def runtime_library_dir_option(self, dir): + # cygwin doesn't support rpath. While in theory we could error + # out like MSVC does, code might expect it to work like on Unix, so + # just warn and hope for the best. + self.warn(_runtime_library_dirs_msg) + return [] + + # -- Miscellaneous methods ----------------------------------------- + + def _make_out_path(self, output_dir, strip_dir, src_name): + # use normcase to make sure '.rc' is really '.rc' and not '.RC' + norm_src_name = os.path.normcase(src_name) + return super()._make_out_path(output_dir, strip_dir, norm_src_name) + + @property + def out_extensions(self): + """ + Add support for rc and res files. + """ + return { + **super().out_extensions, + **{ext: ext + self.obj_extension for ext in ('.res', '.rc')}, + } + + +# the same as cygwin plus some additional parameters +class MinGW32Compiler(Compiler): + """Handles the Mingw32 port of the GNU C compiler to Windows.""" + + compiler_type = 'mingw32' + + def __init__(self, verbose=False, force=False): + super().__init__(verbose, force) + + shared_option = "-shared" + + if is_cygwincc(self.cc): + raise Error('Cygwin gcc cannot be used with --compiler=mingw32') + + self.set_executables( + compiler=f'{self.cc} -O -Wall', + compiler_so=f'{self.cc} -shared -O -Wall', + compiler_so_cxx=f'{self.cxx} -shared -O -Wall', + compiler_cxx=f'{self.cxx} -O -Wall', + linker_exe=f'{self.cc}', + linker_so=f'{self.linker_dll} {shared_option}', + linker_exe_cxx=f'{self.cxx}', + linker_so_cxx=f'{self.linker_dll_cxx} {shared_option}', + ) + + def runtime_library_dir_option(self, dir): + raise DistutilsPlatformError(_runtime_library_dirs_msg) + + +# Because these compilers aren't configured in Python's pyconfig.h file by +# default, we should at least warn the user if he is using an unmodified +# version. + +CONFIG_H_OK = "ok" +CONFIG_H_NOTOK = "not ok" +CONFIG_H_UNCERTAIN = "uncertain" + + +def check_config_h(): + """Check if the current Python installation appears amenable to building + extensions with GCC. + + Returns a tuple (status, details), where 'status' is one of the following + constants: + + - CONFIG_H_OK: all is well, go ahead and compile + - CONFIG_H_NOTOK: doesn't look good + - CONFIG_H_UNCERTAIN: not sure -- unable to read pyconfig.h + + 'details' is a human-readable string explaining the situation. + + Note there are two ways to conclude "OK": either 'sys.version' contains + the string "GCC" (implying that this Python was built with GCC), or the + installed "pyconfig.h" contains the string "__GNUC__". + """ + + # XXX since this function also checks sys.version, it's not strictly a + # "pyconfig.h" check -- should probably be renamed... + + from distutils import sysconfig + + # if sys.version contains GCC then python was compiled with GCC, and the + # pyconfig.h file should be OK + if "GCC" in sys.version: + return CONFIG_H_OK, "sys.version mentions 'GCC'" + + # Clang would also work + if "Clang" in sys.version: + return CONFIG_H_OK, "sys.version mentions 'Clang'" + + # let's see if __GNUC__ is mentioned in python.h + fn = sysconfig.get_config_h_filename() + try: + config_h = pathlib.Path(fn).read_text(encoding='utf-8') + except OSError as exc: + return (CONFIG_H_UNCERTAIN, f"couldn't read '{fn}': {exc.strerror}") + else: + substring = '__GNUC__' + if substring in config_h: + code = CONFIG_H_OK + mention_inflected = 'mentions' + else: + code = CONFIG_H_NOTOK + mention_inflected = 'does not mention' + return code, f"{fn!r} {mention_inflected} {substring!r}" + + +def is_cygwincc(cc): + """Try to determine if the compiler that would be used is from cygwin.""" + out_string = check_output(shlex.split(cc) + ['-dumpmachine']) + return out_string.strip().endswith(b'cygwin') + + +get_versions = None +""" +A stand-in for the previous get_versions() function to prevent failures +when monkeypatched. See pypa/setuptools#2969. +""" diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/errors.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/errors.py new file mode 100644 index 0000000000000000000000000000000000000000..01328592b2dad80f4d16c55cd9db9829b3c650f1 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/errors.py @@ -0,0 +1,24 @@ +class Error(Exception): + """Some compile/link operation failed.""" + + +class PreprocessError(Error): + """Failure to preprocess one or more C/C++ files.""" + + +class CompileError(Error): + """Failure to compile one or more C/C++ source files.""" + + +class LibError(Error): + """Failure to create a static library from one or more C/C++ object + files.""" + + +class LinkError(Error): + """Failure to link one or more C/C++ object files into an executable + or shared library file.""" + + +class UnknownFileType(Error): + """Attempt to process an unknown file type.""" diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/msvc.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/msvc.py new file mode 100644 index 0000000000000000000000000000000000000000..55a7923370a5c742eafb6cdfc799303d3b708791 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/msvc.py @@ -0,0 +1,622 @@ +"""distutils._msvccompiler + +Contains MSVCCompiler, an implementation of the abstract CCompiler class +for Microsoft Visual Studio 2015. + +This module requires VS 2015 or later. +""" + +# Written by Perry Stoll +# hacked by Robin Becker and Thomas Heller to do a better job of +# finding DevStudio (through the registry) +# ported to VS 2005 and VS 2008 by Christian Heimes +# ported to VS 2015 by Steve Dower +from __future__ import annotations + +import contextlib +import os +import subprocess +import unittest.mock as mock +import warnings +from collections.abc import Iterable + +with contextlib.suppress(ImportError): + import winreg + +from itertools import count + +from ..._log import log +from ...errors import ( + DistutilsExecError, + DistutilsPlatformError, +) +from ...util import get_host_platform, get_platform +from . import base +from .base import gen_lib_options +from .errors import ( + CompileError, + LibError, + LinkError, +) + + +def _find_vc2015(): + try: + key = winreg.OpenKeyEx( + winreg.HKEY_LOCAL_MACHINE, + r"Software\Microsoft\VisualStudio\SxS\VC7", + access=winreg.KEY_READ | winreg.KEY_WOW64_32KEY, + ) + except OSError: + log.debug("Visual C++ is not registered") + return None, None + + best_version = 0 + best_dir = None + with key: + for i in count(): + try: + v, vc_dir, vt = winreg.EnumValue(key, i) + except OSError: + break + if v and vt == winreg.REG_SZ and os.path.isdir(vc_dir): + try: + version = int(float(v)) + except (ValueError, TypeError): + continue + if version >= 14 and version > best_version: + best_version, best_dir = version, vc_dir + return best_version, best_dir + + +def _find_vc2017(): + """Returns "15, path" based on the result of invoking vswhere.exe + If no install is found, returns "None, None" + + The version is returned to avoid unnecessarily changing the function + result. It may be ignored when the path is not None. + + If vswhere.exe is not available, by definition, VS 2017 is not + installed. + """ + root = os.environ.get("ProgramFiles(x86)") or os.environ.get("ProgramFiles") + if not root: + return None, None + + variant = 'arm64' if get_platform() == 'win-arm64' else 'x86.x64' + suitable_components = ( + f"Microsoft.VisualStudio.Component.VC.Tools.{variant}", + "Microsoft.VisualStudio.Workload.WDExpress", + ) + + for component in suitable_components: + # Workaround for `-requiresAny` (only available on VS 2017 > 15.6) + with contextlib.suppress( + subprocess.CalledProcessError, OSError, UnicodeDecodeError + ): + path = ( + subprocess.check_output([ + os.path.join( + root, "Microsoft Visual Studio", "Installer", "vswhere.exe" + ), + "-latest", + "-prerelease", + "-requires", + component, + "-property", + "installationPath", + "-products", + "*", + ]) + .decode(encoding="mbcs", errors="strict") + .strip() + ) + + path = os.path.join(path, "VC", "Auxiliary", "Build") + if os.path.isdir(path): + return 15, path + + return None, None # no suitable component found + + +PLAT_SPEC_TO_RUNTIME = { + 'x86': 'x86', + 'x86_amd64': 'x64', + 'x86_arm': 'arm', + 'x86_arm64': 'arm64', +} + + +def _find_vcvarsall(plat_spec): + # bpo-38597: Removed vcruntime return value + _, best_dir = _find_vc2017() + + if not best_dir: + best_version, best_dir = _find_vc2015() + + if not best_dir: + log.debug("No suitable Visual C++ version found") + return None, None + + vcvarsall = os.path.join(best_dir, "vcvarsall.bat") + if not os.path.isfile(vcvarsall): + log.debug("%s cannot be found", vcvarsall) + return None, None + + return vcvarsall, None + + +def _get_vc_env(plat_spec): + if os.getenv("DISTUTILS_USE_SDK"): + return {key.lower(): value for key, value in os.environ.items()} + + vcvarsall, _ = _find_vcvarsall(plat_spec) + if not vcvarsall: + raise DistutilsPlatformError( + 'Microsoft Visual C++ 14.0 or greater is required. ' + 'Get it with "Microsoft C++ Build Tools": ' + 'https://visualstudio.microsoft.com/visual-cpp-build-tools/' + ) + + try: + out = subprocess.check_output( + f'cmd /u /c "{vcvarsall}" {plat_spec} && set', + stderr=subprocess.STDOUT, + ).decode('utf-16le', errors='replace') + except subprocess.CalledProcessError as exc: + log.error(exc.output) + raise DistutilsPlatformError(f"Error executing {exc.cmd}") + + env = { + key.lower(): value + for key, _, value in (line.partition('=') for line in out.splitlines()) + if key and value + } + + return env + + +def _find_exe(exe, paths=None): + """Return path to an MSVC executable program. + + Tries to find the program in several places: first, one of the + MSVC program search paths from the registry; next, the directories + in the PATH environment variable. If any of those work, return an + absolute path that is known to exist. If none of them work, just + return the original program name, 'exe'. + """ + if not paths: + paths = os.getenv('path').split(os.pathsep) + for p in paths: + fn = os.path.join(os.path.abspath(p), exe) + if os.path.isfile(fn): + return fn + return exe + + +_vcvars_names = { + 'win32': 'x86', + 'win-amd64': 'amd64', + 'win-arm32': 'arm', + 'win-arm64': 'arm64', +} + + +def _get_vcvars_spec(host_platform, platform): + """ + Given a host platform and platform, determine the spec for vcvarsall. + + Uses the native MSVC host if the host platform would need expensive + emulation for x86. + + >>> _get_vcvars_spec('win-arm64', 'win32') + 'arm64_x86' + >>> _get_vcvars_spec('win-arm64', 'win-amd64') + 'arm64_amd64' + + Otherwise, always cross-compile from x86 to work with the + lighter-weight MSVC installs that do not include native 64-bit tools. + + >>> _get_vcvars_spec('win32', 'win32') + 'x86' + >>> _get_vcvars_spec('win-arm32', 'win-arm32') + 'x86_arm' + >>> _get_vcvars_spec('win-amd64', 'win-arm64') + 'x86_arm64' + """ + if host_platform != 'win-arm64': + host_platform = 'win32' + vc_hp = _vcvars_names[host_platform] + vc_plat = _vcvars_names[platform] + return vc_hp if vc_hp == vc_plat else f'{vc_hp}_{vc_plat}' + + +class Compiler(base.Compiler): + """Concrete class that implements an interface to Microsoft Visual C++, + as defined by the CCompiler abstract class.""" + + compiler_type = 'msvc' + + # Just set this so CCompiler's constructor doesn't barf. We currently + # don't use the 'set_executables()' bureaucracy provided by CCompiler, + # as it really isn't necessary for this sort of single-compiler class. + # Would be nice to have a consistent interface with UnixCCompiler, + # though, so it's worth thinking about. + executables = {} + + # Private class data (need to distinguish C from C++ source for compiler) + _c_extensions = ['.c'] + _cpp_extensions = ['.cc', '.cpp', '.cxx'] + _rc_extensions = ['.rc'] + _mc_extensions = ['.mc'] + + # Needed for the filename generation methods provided by the + # base class, CCompiler. + src_extensions = _c_extensions + _cpp_extensions + _rc_extensions + _mc_extensions + res_extension = '.res' + obj_extension = '.obj' + static_lib_extension = '.lib' + shared_lib_extension = '.dll' + static_lib_format = shared_lib_format = '%s%s' + exe_extension = '.exe' + + def __init__(self, verbose=False, force=False) -> None: + super().__init__(verbose, force=force) + # target platform (.plat_name is consistent with 'bdist') + self.plat_name = None + self.initialized = False + + @classmethod + def _configure(cls, vc_env): + """ + Set class-level include/lib dirs. + """ + cls.include_dirs = cls._parse_path(vc_env.get('include', '')) + cls.library_dirs = cls._parse_path(vc_env.get('lib', '')) + + @staticmethod + def _parse_path(val): + return [dir.rstrip(os.sep) for dir in val.split(os.pathsep) if dir] + + def initialize(self, plat_name: str | None = None) -> None: + # multi-init means we would need to check platform same each time... + assert not self.initialized, "don't init multiple times" + if plat_name is None: + plat_name = get_platform() + # sanity check for platforms to prevent obscure errors later. + if plat_name not in _vcvars_names: + raise DistutilsPlatformError( + f"--plat-name must be one of {tuple(_vcvars_names)}" + ) + + plat_spec = _get_vcvars_spec(get_host_platform(), plat_name) + + vc_env = _get_vc_env(plat_spec) + if not vc_env: + raise DistutilsPlatformError( + "Unable to find a compatible Visual Studio installation." + ) + self._configure(vc_env) + + self._paths = vc_env.get('path', '') + paths = self._paths.split(os.pathsep) + self.cc = _find_exe("cl.exe", paths) + self.linker = _find_exe("link.exe", paths) + self.lib = _find_exe("lib.exe", paths) + self.rc = _find_exe("rc.exe", paths) # resource compiler + self.mc = _find_exe("mc.exe", paths) # message compiler + self.mt = _find_exe("mt.exe", paths) # message compiler + + self.preprocess_options = None + # bpo-38597: Always compile with dynamic linking + # Future releases of Python 3.x will include all past + # versions of vcruntime*.dll for compatibility. + self.compile_options = ['/nologo', '/O2', '/W3', '/GL', '/DNDEBUG', '/MD'] + + self.compile_options_debug = [ + '/nologo', + '/Od', + '/MDd', + '/Zi', + '/W3', + '/D_DEBUG', + ] + + ldflags = ['/nologo', '/INCREMENTAL:NO', '/LTCG'] + + ldflags_debug = ['/nologo', '/INCREMENTAL:NO', '/LTCG', '/DEBUG:FULL'] + + self.ldflags_exe = [*ldflags, '/MANIFEST:EMBED,ID=1'] + self.ldflags_exe_debug = [*ldflags_debug, '/MANIFEST:EMBED,ID=1'] + self.ldflags_shared = [ + *ldflags, + '/DLL', + '/MANIFEST:EMBED,ID=2', + '/MANIFESTUAC:NO', + ] + self.ldflags_shared_debug = [ + *ldflags_debug, + '/DLL', + '/MANIFEST:EMBED,ID=2', + '/MANIFESTUAC:NO', + ] + self.ldflags_static = [*ldflags] + self.ldflags_static_debug = [*ldflags_debug] + + self._ldflags = { + (base.Compiler.EXECUTABLE, None): self.ldflags_exe, + (base.Compiler.EXECUTABLE, False): self.ldflags_exe, + (base.Compiler.EXECUTABLE, True): self.ldflags_exe_debug, + (base.Compiler.SHARED_OBJECT, None): self.ldflags_shared, + (base.Compiler.SHARED_OBJECT, False): self.ldflags_shared, + (base.Compiler.SHARED_OBJECT, True): self.ldflags_shared_debug, + (base.Compiler.SHARED_LIBRARY, None): self.ldflags_static, + (base.Compiler.SHARED_LIBRARY, False): self.ldflags_static, + (base.Compiler.SHARED_LIBRARY, True): self.ldflags_static_debug, + } + + self.initialized = True + + # -- Worker methods ------------------------------------------------ + + @property + def out_extensions(self) -> dict[str, str]: + return { + **super().out_extensions, + **{ + ext: self.res_extension + for ext in self._rc_extensions + self._mc_extensions + }, + } + + def compile( # noqa: C901 + self, + sources, + output_dir=None, + macros=None, + include_dirs=None, + debug=False, + extra_preargs=None, + extra_postargs=None, + depends=None, + ): + if not self.initialized: + self.initialize() + compile_info = self._setup_compile( + output_dir, macros, include_dirs, sources, depends, extra_postargs + ) + macros, objects, extra_postargs, pp_opts, build = compile_info + + compile_opts = extra_preargs or [] + compile_opts.append('/c') + if debug: + compile_opts.extend(self.compile_options_debug) + else: + compile_opts.extend(self.compile_options) + + add_cpp_opts = False + + for obj in objects: + try: + src, ext = build[obj] + except KeyError: + continue + if debug: + # pass the full pathname to MSVC in debug mode, + # this allows the debugger to find the source file + # without asking the user to browse for it + src = os.path.abspath(src) + + # Anaconda/conda-forge customisation, we want our pdbs to be + # relocatable: + # https://developercommunity.visualstudio.com/comments/623156/view.html + d1trimfile_opts = [] + if 'SRC_DIR' in os.environ and os.path.basename(self.cc) == "cl.exe": + d1trimfile_opts.append("/d1trimfile:" + os.environ['SRC_DIR']) + + + if ext in self._c_extensions: + input_opt = f"/Tc{src}" + elif ext in self._cpp_extensions: + input_opt = f"/Tp{src}" + add_cpp_opts = True + elif ext in self._rc_extensions: + # compile .RC to .RES file + input_opt = src + output_opt = "/fo" + obj + try: + self.spawn([self.rc] + pp_opts + [output_opt, input_opt]) + except DistutilsExecError as msg: + raise CompileError(msg) + continue + elif ext in self._mc_extensions: + # Compile .MC to .RC file to .RES file. + # * '-h dir' specifies the directory for the + # generated include file + # * '-r dir' specifies the target directory of the + # generated RC file and the binary message resource + # it includes + # + # For now (since there are no options to change this), + # we use the source-directory for the include file and + # the build directory for the RC file and message + # resources. This works at least for win32all. + h_dir = os.path.dirname(src) + rc_dir = os.path.dirname(obj) + try: + # first compile .MC to .RC and .H file + self.spawn([self.mc, '-h', h_dir, '-r', rc_dir, src]) + base, _ = os.path.splitext(os.path.basename(src)) + rc_file = os.path.join(rc_dir, base + '.rc') + # then compile .RC to .RES file + self.spawn([self.rc, "/fo" + obj, rc_file]) + + except DistutilsExecError as msg: + raise CompileError(msg) + continue + else: + # how to handle this file? + raise CompileError(f"Don't know how to compile {src} to {obj}") + + args = [self.cc] + compile_opts + pp_opts + d1trimfile_opts + if add_cpp_opts: + args.append('/EHsc') + args.extend((input_opt, "/Fo" + obj)) + args.extend(extra_postargs) + + try: + self.spawn(args) + except DistutilsExecError as msg: + raise CompileError(msg) + + return objects + + def create_static_lib( + self, + objects: list[str] | tuple[str, ...], + output_libname: str, + output_dir: str | None = None, + debug: bool = False, + target_lang: str | None = None, + ) -> None: + if not self.initialized: + self.initialize() + objects, output_dir = self._fix_object_args(objects, output_dir) + output_filename = self.library_filename(output_libname, output_dir=output_dir) + + if self._need_link(objects, output_filename): + lib_args = objects + ['/OUT:' + output_filename] + if debug: + pass # XXX what goes here? + try: + log.debug('Executing "%s" %s', self.lib, ' '.join(lib_args)) + self.spawn([self.lib] + lib_args) + except DistutilsExecError as msg: + raise LibError(msg) + else: + log.debug("skipping %s (up-to-date)", output_filename) + + def link( + self, + target_desc: str, + objects: list[str] | tuple[str, ...], + output_filename: str, + output_dir: str | None = None, + libraries: list[str] | tuple[str, ...] | None = None, + library_dirs: list[str] | tuple[str, ...] | None = None, + runtime_library_dirs: list[str] | tuple[str, ...] | None = None, + export_symbols: Iterable[str] | None = None, + debug: bool = False, + extra_preargs: list[str] | None = None, + extra_postargs: Iterable[str] | None = None, + build_temp: str | os.PathLike[str] | None = None, + target_lang: str | None = None, + ) -> None: + if not self.initialized: + self.initialize() + objects, output_dir = self._fix_object_args(objects, output_dir) + fixed_args = self._fix_lib_args(libraries, library_dirs, runtime_library_dirs) + libraries, library_dirs, runtime_library_dirs = fixed_args + + if runtime_library_dirs: + self.warn( + "I don't know what to do with 'runtime_library_dirs': " + + str(runtime_library_dirs) + ) + + lib_opts = gen_lib_options(self, library_dirs, runtime_library_dirs, libraries) + if output_dir is not None: + output_filename = os.path.join(output_dir, output_filename) + + if self._need_link(objects, output_filename): + ldflags = self._ldflags[target_desc, debug] + + export_opts = ["/EXPORT:" + sym for sym in (export_symbols or [])] + + ld_args = ( + ldflags + lib_opts + export_opts + objects + ['/OUT:' + output_filename] + ) + + # The MSVC linker generates .lib and .exp files, which cannot be + # suppressed by any linker switches. The .lib files may even be + # needed! Make sure they are generated in the temporary build + # directory. Since they have different names for debug and release + # builds, they can go into the same directory. + build_temp = os.path.dirname(objects[0]) + if export_symbols is not None: + (dll_name, dll_ext) = os.path.splitext( + os.path.basename(output_filename) + ) + implib_file = os.path.join(build_temp, self.library_filename(dll_name)) + ld_args.append('/IMPLIB:' + implib_file) + + if extra_preargs: + ld_args[:0] = extra_preargs + if extra_postargs: + ld_args.extend(extra_postargs) + + output_dir = os.path.dirname(os.path.abspath(output_filename)) + self.mkpath(output_dir) + try: + log.debug('Executing "%s" %s', self.linker, ' '.join(ld_args)) + self.spawn([self.linker] + ld_args) + except DistutilsExecError as msg: + raise LinkError(msg) + else: + log.debug("skipping %s (up-to-date)", output_filename) + + def spawn(self, cmd): + env = dict(os.environ, PATH=self._paths) + with self._fallback_spawn(cmd, env) as fallback: + return super().spawn(cmd, env=env) + return fallback.value + + @contextlib.contextmanager + def _fallback_spawn(self, cmd, env): + """ + Discovered in pypa/distutils#15, some tools monkeypatch the compiler, + so the 'env' kwarg causes a TypeError. Detect this condition and + restore the legacy, unsafe behavior. + """ + bag = type('Bag', (), {})() + try: + yield bag + except TypeError as exc: + if "unexpected keyword argument 'env'" not in str(exc): + raise + else: + return + warnings.warn("Fallback spawn triggered. Please update distutils monkeypatch.") + with mock.patch.dict('os.environ', env): + bag.value = super().spawn(cmd) + + # -- Miscellaneous methods ----------------------------------------- + # These are all used by the 'gen_lib_options() function, in + # ccompiler.py. + + def library_dir_option(self, dir): + return "/LIBPATH:" + dir + + def runtime_library_dir_option(self, dir): + raise DistutilsPlatformError( + "don't know how to set runtime library search path for MSVC" + ) + + def library_option(self, lib): + return self.library_filename(lib) + + def find_library_file(self, dirs, lib, debug=False): + # Prefer a debugging library if found (and requested), but deal + # with it if we don't have one. + if debug: + try_names = [lib + "_d", lib] + else: + try_names = [lib] + for dir in dirs: + for name in try_names: + libfile = os.path.join(dir, self.library_filename(name)) + if os.path.isfile(libfile): + return libfile + else: + # Oops, didn't find it in *any* of 'dirs' + return None diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/tests/test_base.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/tests/test_base.py new file mode 100644 index 0000000000000000000000000000000000000000..a762e2b649d7977ef42f4d35854eab26bd54e9e7 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/tests/test_base.py @@ -0,0 +1,83 @@ +import platform +import sysconfig +import textwrap + +import pytest + +from .. import base + +pytestmark = pytest.mark.usefixtures('suppress_path_mangle') + + +@pytest.fixture +def c_file(tmp_path): + c_file = tmp_path / 'foo.c' + gen_headers = ('Python.h',) + is_windows = platform.system() == "Windows" + plat_headers = ('windows.h',) * is_windows + all_headers = gen_headers + plat_headers + headers = '\n'.join(f'#include <{header}>\n' for header in all_headers) + payload = ( + textwrap.dedent( + """ + #headers + void PyInit_foo(void) {} + """ + ) + .lstrip() + .replace('#headers', headers) + ) + c_file.write_text(payload, encoding='utf-8') + return c_file + + +def test_set_include_dirs(c_file): + """ + Extensions should build even if set_include_dirs is invoked. + In particular, compiler-specific paths should not be overridden. + """ + compiler = base.new_compiler() + python = sysconfig.get_paths()['include'] + compiler.set_include_dirs([python]) + compiler.compile([c_file]) + + # do it again, setting include dirs after any initialization + compiler.set_include_dirs([python]) + compiler.compile([c_file]) + + +def test_has_function_prototype(): + # Issue https://github.com/pypa/setuptools/issues/3648 + # Test prototype-generating behavior. + + compiler = base.new_compiler() + + # Every C implementation should have these. + assert compiler.has_function('abort') + assert compiler.has_function('exit') + with pytest.deprecated_call(match='includes is deprecated'): + # abort() is a valid expression with the <stdlib.h> prototype. + assert compiler.has_function('abort', includes=['stdlib.h']) + with pytest.deprecated_call(match='includes is deprecated'): + # But exit() is not valid with the actual prototype in scope. + assert not compiler.has_function('exit', includes=['stdlib.h']) + # And setuptools_does_not_exist is not declared or defined at all. + assert not compiler.has_function('setuptools_does_not_exist') + with pytest.deprecated_call(match='includes is deprecated'): + assert not compiler.has_function( + 'setuptools_does_not_exist', includes=['stdio.h'] + ) + + +def test_include_dirs_after_multiple_compile_calls(c_file): + """ + Calling compile multiple times should not change the include dirs + (regression test for setuptools issue #3591). + """ + compiler = base.new_compiler() + python = sysconfig.get_paths()['include'] + compiler.set_include_dirs([python]) + compiler.compile([c_file]) + assert compiler.include_dirs == [python] + compiler.compile([c_file]) + assert compiler.include_dirs == [python] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/tests/test_cygwin.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/tests/test_cygwin.py new file mode 100644 index 0000000000000000000000000000000000000000..9adf6b8ebf165b4fe92a52d8a14aed21aebba539 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/tests/test_cygwin.py @@ -0,0 +1,76 @@ +"""Tests for distutils.cygwinccompiler.""" + +import os +import sys +from distutils import sysconfig +from distutils.tests import support + +import pytest + +from .. import cygwin + + +@pytest.fixture(autouse=True) +def stuff(request, monkeypatch, distutils_managed_tempdir): + self = request.instance + self.python_h = os.path.join(self.mkdtemp(), 'python.h') + monkeypatch.setattr(sysconfig, 'get_config_h_filename', self._get_config_h_filename) + monkeypatch.setattr(sys, 'version', sys.version) + + +class TestCygwinCCompiler(support.TempdirManager): + def _get_config_h_filename(self): + return self.python_h + + @pytest.mark.skipif('sys.platform != "cygwin"') + @pytest.mark.skipif('not os.path.exists("/usr/lib/libbash.dll.a")') + def test_find_library_file(self): + from distutils.cygwinccompiler import CygwinCCompiler + + compiler = CygwinCCompiler() + link_name = "bash" + linkable_file = compiler.find_library_file(["/usr/lib"], link_name) + assert linkable_file is not None + assert os.path.exists(linkable_file) + assert linkable_file == f"/usr/lib/lib{link_name:s}.dll.a" + + @pytest.mark.skipif('sys.platform != "cygwin"') + def test_runtime_library_dir_option(self): + from distutils.cygwinccompiler import CygwinCCompiler + + compiler = CygwinCCompiler() + assert compiler.runtime_library_dir_option('/foo') == [] + + def test_check_config_h(self): + # check_config_h looks for "GCC" in sys.version first + # returns CONFIG_H_OK if found + sys.version = ( + '2.6.1 (r261:67515, Dec 6 2008, 16:42:21) \n[GCC ' + '4.0.1 (Apple Computer, Inc. build 5370)]' + ) + + assert cygwin.check_config_h()[0] == cygwin.CONFIG_H_OK + + # then it tries to see if it can find "__GNUC__" in pyconfig.h + sys.version = 'something without the *CC word' + + # if the file doesn't exist it returns CONFIG_H_UNCERTAIN + assert cygwin.check_config_h()[0] == cygwin.CONFIG_H_UNCERTAIN + + # if it exists but does not contain __GNUC__, it returns CONFIG_H_NOTOK + self.write_file(self.python_h, 'xxx') + assert cygwin.check_config_h()[0] == cygwin.CONFIG_H_NOTOK + + # and CONFIG_H_OK if __GNUC__ is found + self.write_file(self.python_h, 'xxx __GNUC__ xxx') + assert cygwin.check_config_h()[0] == cygwin.CONFIG_H_OK + + def test_get_msvcr(self): + assert cygwin.get_msvcr() == [] + + @pytest.mark.skipif('sys.platform != "cygwin"') + def test_dll_libraries_not_none(self): + from distutils.cygwinccompiler import CygwinCCompiler + + compiler = CygwinCCompiler() + assert compiler.dll_libraries is not None diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/tests/test_mingw.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/tests/test_mingw.py new file mode 100644 index 0000000000000000000000000000000000000000..dc45687a917808edbf692ced18b0c99183d21e2d --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/tests/test_mingw.py @@ -0,0 +1,48 @@ +from distutils import sysconfig +from distutils.errors import DistutilsPlatformError +from distutils.util import is_mingw, split_quoted + +import pytest + +from .. import cygwin, errors + + +class TestMinGW32Compiler: + @pytest.mark.skipif(not is_mingw(), reason='not on mingw') + def test_compiler_type(self): + compiler = cygwin.MinGW32Compiler() + assert compiler.compiler_type == 'mingw32' + + @pytest.mark.skipif(not is_mingw(), reason='not on mingw') + def test_set_executables(self, monkeypatch): + monkeypatch.setenv('CC', 'cc') + monkeypatch.setenv('CXX', 'c++') + + compiler = cygwin.MinGW32Compiler() + + assert compiler.compiler == split_quoted('cc -O -Wall') + assert compiler.compiler_so == split_quoted('cc -shared -O -Wall') + assert compiler.compiler_cxx == split_quoted('c++ -O -Wall') + assert compiler.linker_exe == split_quoted('cc') + assert compiler.linker_so == split_quoted('cc -shared') + + @pytest.mark.skipif(not is_mingw(), reason='not on mingw') + def test_runtime_library_dir_option(self): + compiler = cygwin.MinGW32Compiler() + with pytest.raises(DistutilsPlatformError): + compiler.runtime_library_dir_option('/usr/lib') + + @pytest.mark.skipif(not is_mingw(), reason='not on mingw') + def test_cygwincc_error(self, monkeypatch): + monkeypatch.setattr(cygwin, 'is_cygwincc', lambda _: True) + + with pytest.raises(errors.Error): + cygwin.MinGW32Compiler() + + @pytest.mark.skipif('sys.platform == "cygwin"') + def test_customize_compiler_with_msvc_python(self): + # In case we have an MSVC Python build, but still want to use + # MinGW32Compiler, then customize_compiler() shouldn't fail at least. + # https://github.com/pypa/setuptools/issues/4456 + compiler = cygwin.MinGW32Compiler() + sysconfig.customize_compiler(compiler) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/tests/test_msvc.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/tests/test_msvc.py new file mode 100644 index 0000000000000000000000000000000000000000..eca831996adcb07f05560581fe4285cdb29392d3 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/tests/test_msvc.py @@ -0,0 +1,136 @@ +import os +import sys +import sysconfig +import threading +import unittest.mock as mock +from distutils.errors import DistutilsPlatformError +from distutils.tests import support +from distutils.util import get_platform + +import pytest + +from .. import msvc + +needs_winreg = pytest.mark.skipif('not hasattr(msvc, "winreg")') + + +class Testmsvccompiler(support.TempdirManager): + def test_no_compiler(self, monkeypatch): + # makes sure query_vcvarsall raises + # a DistutilsPlatformError if the compiler + # is not found + def _find_vcvarsall(plat_spec): + return None, None + + monkeypatch.setattr(msvc, '_find_vcvarsall', _find_vcvarsall) + + with pytest.raises(DistutilsPlatformError): + msvc._get_vc_env( + 'wont find this version', + ) + + @pytest.mark.skipif( + not sysconfig.get_platform().startswith("win"), + reason="Only run test for non-mingw Windows platforms", + ) + @pytest.mark.parametrize( + "plat_name, expected", + [ + ("win-arm64", "win-arm64"), + ("win-amd64", "win-amd64"), + (None, get_platform()), + ], + ) + def test_cross_platform_compilation_paths(self, monkeypatch, plat_name, expected): + """ + Ensure a specified target platform is passed to _get_vcvars_spec. + """ + compiler = msvc.Compiler() + + def _get_vcvars_spec(host_platform, platform): + assert platform == expected + + monkeypatch.setattr(msvc, '_get_vcvars_spec', _get_vcvars_spec) + compiler.initialize(plat_name) + + @needs_winreg + def test_get_vc_env_unicode(self): + test_var = 'ṰḖṤṪ┅ṼẨṜ' + test_value = '₃⁴₅' + + # Ensure we don't early exit from _get_vc_env + old_distutils_use_sdk = os.environ.pop('DISTUTILS_USE_SDK', None) + os.environ[test_var] = test_value + try: + env = msvc._get_vc_env('x86') + assert test_var.lower() in env + assert test_value == env[test_var.lower()] + finally: + os.environ.pop(test_var) + if old_distutils_use_sdk: + os.environ['DISTUTILS_USE_SDK'] = old_distutils_use_sdk + + @needs_winreg + @pytest.mark.parametrize('ver', (2015, 2017)) + def test_get_vc(self, ver): + # This function cannot be mocked, so pass if VC is found + # and skip otherwise. + lookup = getattr(msvc, f'_find_vc{ver}') + expected_version = {2015: 14, 2017: 15}[ver] + version, path = lookup() + if not version: + pytest.skip(f"VS {ver} is not installed") + assert version >= expected_version + assert os.path.isdir(path) + + +class CheckThread(threading.Thread): + exc_info = None + + def run(self): + try: + super().run() + except Exception: + self.exc_info = sys.exc_info() + + def __bool__(self): + return not self.exc_info + + +class TestSpawn: + def test_concurrent_safe(self): + """ + Concurrent calls to spawn should have consistent results. + """ + compiler = msvc.Compiler() + compiler._paths = "expected" + inner_cmd = 'import os; assert os.environ["PATH"] == "expected"' + command = [sys.executable, '-c', inner_cmd] + + threads = [ + CheckThread(target=compiler.spawn, args=[command]) for n in range(100) + ] + for thread in threads: + thread.start() + for thread in threads: + thread.join() + assert all(threads) + + def test_concurrent_safe_fallback(self): + """ + If CCompiler.spawn has been monkey-patched without support + for an env, it should still execute. + """ + from distutils import ccompiler + + compiler = msvc.Compiler() + compiler._paths = "expected" + + def CCompiler_spawn(self, cmd): + "A spawn without an env argument." + assert os.environ["PATH"] == "expected" + + with mock.patch.object(ccompiler.CCompiler, 'spawn', CCompiler_spawn): + compiler.spawn(["n/a"]) + + assert os.environ.get("PATH") != "expected" diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/tests/test_unix.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/tests/test_unix.py new file mode 100644 index 0000000000000000000000000000000000000000..35b6b0e050c654bd9eff711ec3b94bea9adff2af --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/tests/test_unix.py @@ -0,0 +1,413 @@ +"""Tests for distutils.unixccompiler.""" + +import os +import sys +import unittest.mock as mock +from distutils import sysconfig +from distutils.compat import consolidate_linker_args +from distutils.errors import DistutilsPlatformError +from distutils.tests import support +from distutils.tests.compat.py39 import EnvironmentVarGuard +from distutils.util import _clear_cached_macosx_ver + +import pytest + +from .. import unix + + +@pytest.fixture(autouse=True) +def save_values(monkeypatch): + monkeypatch.setattr(sys, 'platform', sys.platform) + monkeypatch.setattr(sysconfig, 'get_config_var', sysconfig.get_config_var) + monkeypatch.setattr(sysconfig, 'get_config_vars', sysconfig.get_config_vars) + + +@pytest.fixture(autouse=True) +def compiler_wrapper(request): + class CompilerWrapper(unix.Compiler): + def rpath_foo(self): + return self.runtime_library_dir_option('/foo') + + request.instance.cc = CompilerWrapper() + + +class TestUnixCCompiler(support.TempdirManager): + @pytest.mark.skipif('platform.system == "Windows"') + def test_runtime_libdir_option(self): # noqa: C901 + # Issue #5900; GitHub Issue #37 + # + # Ensure RUNPATH is added to extension modules with RPATH if + # GNU ld is used + + # darwin + sys.platform = 'darwin' + darwin_ver_var = 'MACOSX_DEPLOYMENT_TARGET' + darwin_rpath_flag = '-Wl,-rpath,/foo' + darwin_lib_flag = '-L/foo' + + # (macOS version from syscfg, macOS version from env var) -> flag + # Version value of None generates two tests: as None and as empty string + # Expected flag value of None means an mismatch exception is expected + darwin_test_cases = [ + ((None, None), darwin_lib_flag), + ((None, '11'), darwin_rpath_flag), + (('10', None), darwin_lib_flag), + (('10.3', None), darwin_lib_flag), + (('10.3.1', None), darwin_lib_flag), + (('10.5', None), darwin_rpath_flag), + (('10.5.1', None), darwin_rpath_flag), + (('10.3', '10.3'), darwin_lib_flag), + (('10.3', '10.5'), darwin_rpath_flag), + (('10.5', '10.3'), darwin_lib_flag), + (('10.5', '11'), darwin_rpath_flag), + (('10.4', '10'), None), + ] + + def make_darwin_gcv(syscfg_macosx_ver): + def gcv(var): + if var == darwin_ver_var: + return syscfg_macosx_ver + return "xxx" + + return gcv + + def do_darwin_test(syscfg_macosx_ver, env_macosx_ver, expected_flag): + env = os.environ + msg = f"macOS version = (sysconfig={syscfg_macosx_ver!r}, env={env_macosx_ver!r})" + + # Save + old_gcv = sysconfig.get_config_var + old_env_macosx_ver = env.get(darwin_ver_var) + + # Setup environment + _clear_cached_macosx_ver() + sysconfig.get_config_var = make_darwin_gcv(syscfg_macosx_ver) + if env_macosx_ver is not None: + env[darwin_ver_var] = env_macosx_ver + elif darwin_ver_var in env: + env.pop(darwin_ver_var) + + # Run the test + if expected_flag is not None: + assert self.cc.rpath_foo() == expected_flag, msg + else: + with pytest.raises( + DistutilsPlatformError, match=darwin_ver_var + r' mismatch' + ): + self.cc.rpath_foo() + + # Restore + if old_env_macosx_ver is not None: + env[darwin_ver_var] = old_env_macosx_ver + elif darwin_ver_var in env: + env.pop(darwin_ver_var) + sysconfig.get_config_var = old_gcv + _clear_cached_macosx_ver() + + for macosx_vers, expected_flag in darwin_test_cases: + syscfg_macosx_ver, env_macosx_ver = macosx_vers + do_darwin_test(syscfg_macosx_ver, env_macosx_ver, expected_flag) + # Bonus test cases with None interpreted as empty string + if syscfg_macosx_ver is None: + do_darwin_test("", env_macosx_ver, expected_flag) + if env_macosx_ver is None: + do_darwin_test(syscfg_macosx_ver, "", expected_flag) + if syscfg_macosx_ver is None and env_macosx_ver is None: + do_darwin_test("", "", expected_flag) + + old_gcv = sysconfig.get_config_var + + # hp-ux + sys.platform = 'hp-ux' + + def gcv(v): + return 'xxx' + + sysconfig.get_config_var = gcv + assert self.cc.rpath_foo() == ['+s', '-L/foo'] + + def gcv(v): + return 'gcc' + + sysconfig.get_config_var = gcv + assert self.cc.rpath_foo() == ['-Wl,+s', '-L/foo'] + + def gcv(v): + return 'g++' + + sysconfig.get_config_var = gcv + assert self.cc.rpath_foo() == ['-Wl,+s', '-L/foo'] + + sysconfig.get_config_var = old_gcv + + # GCC GNULD + sys.platform = 'bar' + + def gcv(v): + if v == 'CC': + return 'gcc' + elif v == 'GNULD': + return 'yes' + + sysconfig.get_config_var = gcv + assert self.cc.rpath_foo() == consolidate_linker_args([ + '-Wl,--enable-new-dtags', + '-Wl,-rpath,/foo', + ]) + + def gcv(v): + if v == 'CC': + return 'gcc -pthread -B /bar' + elif v == 'GNULD': + return 'yes' + + sysconfig.get_config_var = gcv + assert self.cc.rpath_foo() == consolidate_linker_args([ + '-Wl,--enable-new-dtags', + '-Wl,-rpath,/foo', + ]) + + # GCC non-GNULD + sys.platform = 'bar' + + def gcv(v): + if v == 'CC': + return 'gcc' + elif v == 'GNULD': + return 'no' + + sysconfig.get_config_var = gcv + assert self.cc.rpath_foo() == '-Wl,-R/foo' + + # GCC GNULD with fully qualified configuration prefix + # see #7617 + sys.platform = 'bar' + + def gcv(v): + if v == 'CC': + return 'x86_64-pc-linux-gnu-gcc-4.4.2' + elif v == 'GNULD': + return 'yes' + + sysconfig.get_config_var = gcv + assert self.cc.rpath_foo() == consolidate_linker_args([ + '-Wl,--enable-new-dtags', + '-Wl,-rpath,/foo', + ]) + + # non-GCC GNULD + sys.platform = 'bar' + + def gcv(v): + if v == 'CC': + return 'cc' + elif v == 'GNULD': + return 'yes' + + sysconfig.get_config_var = gcv + assert self.cc.rpath_foo() == consolidate_linker_args([ + '-Wl,--enable-new-dtags', + '-Wl,-rpath,/foo', + ]) + + # non-GCC non-GNULD + sys.platform = 'bar' + + def gcv(v): + if v == 'CC': + return 'cc' + elif v == 'GNULD': + return 'no' + + sysconfig.get_config_var = gcv + assert self.cc.rpath_foo() == '-Wl,-R/foo' + + @pytest.mark.skipif('platform.system == "Windows"') + def test_cc_overrides_ldshared(self): + # Issue #18080: + # ensure that setting CC env variable also changes default linker + def gcv(v): + if v == 'LDSHARED': + return 'gcc-4.2 -bundle -undefined dynamic_lookup ' + return 'gcc-4.2' + + def gcvs(*args, _orig=sysconfig.get_config_vars): + if args: + return list(map(sysconfig.get_config_var, args)) + return _orig() + + sysconfig.get_config_var = gcv + sysconfig.get_config_vars = gcvs + with EnvironmentVarGuard() as env: + env['CC'] = 'my_cc' + del env['LDSHARED'] + sysconfig.customize_compiler(self.cc) + assert self.cc.linker_so[0] == 'my_cc' + + @pytest.mark.skipif('platform.system == "Windows"') + def test_cxx_commands_used_are_correct(self): + def gcv(v): + if v == 'LDSHARED': + return 'ccache gcc-4.2 -bundle -undefined dynamic_lookup' + elif v == 'LDCXXSHARED': + return 'ccache g++-4.2 -bundle -undefined dynamic_lookup' + elif v == 'CXX': + return 'ccache g++-4.2' + elif v == 'CC': + return 'ccache gcc-4.2' + return '' + + def gcvs(*args, _orig=sysconfig.get_config_vars): + if args: + return list(map(sysconfig.get_config_var, args)) + return _orig() # pragma: no cover + + sysconfig.get_config_var = gcv + sysconfig.get_config_vars = gcvs + with ( + mock.patch.object(self.cc, 'spawn', return_value=None) as mock_spawn, + mock.patch.object(self.cc, '_need_link', return_value=True), + mock.patch.object(self.cc, 'mkpath', return_value=None), + EnvironmentVarGuard() as env, + ): + # override environment overrides in case they're specified by CI + del env['CXX'] + del env['LDCXXSHARED'] + + sysconfig.customize_compiler(self.cc) + assert self.cc.linker_so_cxx[0:2] == ['ccache', 'g++-4.2'] + assert self.cc.linker_exe_cxx[0:2] == ['ccache', 'g++-4.2'] + self.cc.link(None, [], 'a.out', target_lang='c++') + call_args = mock_spawn.call_args[0][0] + expected = ['ccache', 'g++-4.2', '-bundle', '-undefined', 'dynamic_lookup'] + assert call_args[:5] == expected + + self.cc.link_executable([], 'a.out', target_lang='c++') + call_args = mock_spawn.call_args[0][0] + expected = ['ccache', 'g++-4.2', '-o', self.cc.executable_filename('a.out')] + assert call_args[:4] == expected + + env['LDCXXSHARED'] = 'wrapper g++-4.2 -bundle -undefined dynamic_lookup' + env['CXX'] = 'wrapper g++-4.2' + sysconfig.customize_compiler(self.cc) + assert self.cc.linker_so_cxx[0:2] == ['wrapper', 'g++-4.2'] + assert self.cc.linker_exe_cxx[0:2] == ['wrapper', 'g++-4.2'] + self.cc.link(None, [], 'a.out', target_lang='c++') + call_args = mock_spawn.call_args[0][0] + expected = ['wrapper', 'g++-4.2', '-bundle', '-undefined', 'dynamic_lookup'] + assert call_args[:5] == expected + + self.cc.link_executable([], 'a.out', target_lang='c++') + call_args = mock_spawn.call_args[0][0] + expected = [ + 'wrapper', + 'g++-4.2', + '-o', + self.cc.executable_filename('a.out'), + ] + assert call_args[:4] == expected + + @pytest.mark.skipif('platform.system == "Windows"') + @pytest.mark.usefixtures('disable_macos_customization') + def test_cc_overrides_ldshared_for_cxx_correctly(self): + """ + Ensure that setting CC env variable also changes default linker + correctly when building C++ extensions. + + pypa/distutils#126 + """ + + def gcv(v): + if v == 'LDSHARED': + return 'gcc-4.2 -bundle -undefined dynamic_lookup ' + elif v == 'LDCXXSHARED': + return 'g++-4.2 -bundle -undefined dynamic_lookup ' + elif v == 'CXX': + return 'g++-4.2' + elif v == 'CC': + return 'gcc-4.2' + return '' + + def gcvs(*args, _orig=sysconfig.get_config_vars): + if args: + return list(map(sysconfig.get_config_var, args)) + return _orig() + + sysconfig.get_config_var = gcv + sysconfig.get_config_vars = gcvs + with ( + mock.patch.object(self.cc, 'spawn', return_value=None) as mock_spawn, + mock.patch.object(self.cc, '_need_link', return_value=True), + mock.patch.object(self.cc, 'mkpath', return_value=None), + EnvironmentVarGuard() as env, + ): + env['CC'] = 'ccache my_cc' + env['CXX'] = 'my_cxx' + del env['LDSHARED'] + sysconfig.customize_compiler(self.cc) + assert self.cc.linker_so[0:2] == ['ccache', 'my_cc'] + self.cc.link(None, [], 'a.out', target_lang='c++') + call_args = mock_spawn.call_args[0][0] + expected = ['my_cxx', '-bundle', '-undefined', 'dynamic_lookup'] + assert call_args[:4] == expected + + @pytest.mark.skipif('platform.system == "Windows"') + def test_explicit_ldshared(self): + # Issue #18080: + # ensure that setting CC env variable does not change + # explicit LDSHARED setting for linker + def gcv(v): + if v == 'LDSHARED': + return 'gcc-4.2 -bundle -undefined dynamic_lookup ' + return 'gcc-4.2' + + def gcvs(*args, _orig=sysconfig.get_config_vars): + if args: + return list(map(sysconfig.get_config_var, args)) + return _orig() + + sysconfig.get_config_var = gcv + sysconfig.get_config_vars = gcvs + with EnvironmentVarGuard() as env: + env['CC'] = 'my_cc' + env['LDSHARED'] = 'my_ld -bundle -dynamic' + sysconfig.customize_compiler(self.cc) + assert self.cc.linker_so[0] == 'my_ld' + + def test_has_function(self): + # Issue https://github.com/pypa/distutils/issues/64: + # ensure that setting output_dir does not raise + # FileNotFoundError: [Errno 2] No such file or directory: 'a.out' + self.cc.output_dir = 'scratch' + os.chdir(self.mkdtemp()) + self.cc.has_function('abort') + + def test_find_library_file(self, monkeypatch): + compiler = unix.Compiler() + compiler._library_root = lambda dir: dir + monkeypatch.setattr(os.path, 'exists', lambda d: 'existing' in d) + + libname = 'libabc.dylib' if sys.platform != 'cygwin' else 'cygabc.dll' + dirs = ('/foo/bar/missing', '/foo/bar/existing') + assert ( + compiler.find_library_file(dirs, 'abc').replace('\\', '/') + == f'/foo/bar/existing/{libname}' + ) + assert ( + compiler.find_library_file(reversed(dirs), 'abc').replace('\\', '/') + == f'/foo/bar/existing/{libname}' + ) + + monkeypatch.setattr( + os.path, + 'exists', + lambda d: 'existing' in d and '.a' in d and '.dll.a' not in d, + ) + assert ( + compiler.find_library_file(dirs, 'abc').replace('\\', '/') + == '/foo/bar/existing/libabc.a' + ) + assert ( + compiler.find_library_file(reversed(dirs), 'abc').replace('\\', '/') + == '/foo/bar/existing/libabc.a' + ) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/unix.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/unix.py new file mode 100644 index 0000000000000000000000000000000000000000..1231b32d20fc0524ea50f6a70d7e017211c69e9b --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/unix.py @@ -0,0 +1,422 @@ +"""distutils.unixccompiler + +Contains the UnixCCompiler class, a subclass of CCompiler that handles +the "typical" Unix-style command-line C compiler: + * macros defined with -Dname[=value] + * macros undefined with -Uname + * include search directories specified with -Idir + * libraries specified with -lllib + * library search directories specified with -Ldir + * compile handled by 'cc' (or similar) executable with -c option: + compiles .c to .o + * link static library handled by 'ar' command (possibly with 'ranlib') + * link shared library handled by 'cc -shared' +""" + +from __future__ import annotations + +import itertools +import os +import re +import shlex +import sys +from collections.abc import Iterable + +from ... import sysconfig +from ..._log import log +from ..._macos_compat import compiler_fixup +from ..._modified import newer +from ...compat import consolidate_linker_args +from ...errors import DistutilsExecError +from . import base +from .base import _Macro, gen_lib_options, gen_preprocess_options +from .errors import ( + CompileError, + LibError, + LinkError, +) + +# XXX Things not currently handled: +# * optimization/debug/warning flags; we just use whatever's in Python's +# Makefile and live with it. Is this adequate? If not, we might +# have to have a bunch of subclasses GNUCCompiler, SGICCompiler, +# SunCCompiler, and I suspect down that road lies madness. +# * even if we don't know a warning flag from an optimization flag, +# we need some way for outsiders to feed preprocessor/compiler/linker +# flags in to us -- eg. a sysadmin might want to mandate certain flags +# via a site config file, or a user might want to set something for +# compiling this module distribution only via the setup.py command +# line, whatever. As long as these options come from something on the +# current system, they can be as system-dependent as they like, and we +# should just happily stuff them into the preprocessor/compiler/linker +# options and carry on. + + +def _split_env(cmd): + """ + For macOS, split command into 'env' portion (if any) + and the rest of the linker command. + + >>> _split_env(['a', 'b', 'c']) + ([], ['a', 'b', 'c']) + >>> _split_env(['/usr/bin/env', 'A=3', 'gcc']) + (['/usr/bin/env', 'A=3'], ['gcc']) + """ + pivot = 0 + if os.path.basename(cmd[0]) == "env": + pivot = 1 + while '=' in cmd[pivot]: + pivot += 1 + return cmd[:pivot], cmd[pivot:] + + +def _split_aix(cmd): + """ + AIX platforms prefix the compiler with the ld_so_aix + script, so split that from the linker command. + + >>> _split_aix(['a', 'b', 'c']) + ([], ['a', 'b', 'c']) + >>> _split_aix(['/bin/foo/ld_so_aix', 'gcc']) + (['/bin/foo/ld_so_aix'], ['gcc']) + """ + pivot = os.path.basename(cmd[0]) == 'ld_so_aix' + return cmd[:pivot], cmd[pivot:] + + +def _linker_params(linker_cmd, compiler_cmd): + """ + The linker command usually begins with the compiler + command (possibly multiple elements), followed by zero or more + params for shared library building. + + If the LDSHARED env variable overrides the linker command, + however, the commands may not match. + + Return the best guess of the linker parameters by stripping + the linker command. If the compiler command does not + match the linker command, assume the linker command is + just the first element. + + >>> _linker_params('gcc foo bar'.split(), ['gcc']) + ['foo', 'bar'] + >>> _linker_params('gcc foo bar'.split(), ['other']) + ['foo', 'bar'] + >>> _linker_params('ccache gcc foo bar'.split(), 'ccache gcc'.split()) + ['foo', 'bar'] + >>> _linker_params(['gcc'], ['gcc']) + [] + """ + c_len = len(compiler_cmd) + pivot = c_len if linker_cmd[:c_len] == compiler_cmd else 1 + return linker_cmd[pivot:] + + +class Compiler(base.Compiler): + compiler_type = 'unix' + + # These are used by CCompiler in two places: the constructor sets + # instance attributes 'preprocessor', 'compiler', etc. from them, and + # 'set_executable()' allows any of these to be set. The defaults here + # are pretty generic; they will probably have to be set by an outsider + # (eg. using information discovered by the sysconfig about building + # Python extensions). + executables = { + 'preprocessor': None, + 'compiler': ["cc"], + 'compiler_so': ["cc"], + 'compiler_cxx': ["c++"], + 'compiler_so_cxx': ["c++"], + 'linker_so': ["cc", "-shared"], + 'linker_so_cxx': ["c++", "-shared"], + 'linker_exe': ["cc"], + 'linker_exe_cxx': ["c++", "-shared"], + 'archiver': ["ar", "-cr"], + 'ranlib': None, + } + + if sys.platform[:6] == "darwin": + executables['ranlib'] = ["ranlib"] + + # Needed for the filename generation methods provided by the base + # class, CCompiler. NB. whoever instantiates/uses a particular + # UnixCCompiler instance should set 'shared_lib_ext' -- we set a + # reasonable common default here, but it's not necessarily used on all + # Unices! + + src_extensions = [".c", ".C", ".cc", ".cxx", ".cpp", ".m"] + obj_extension = ".o" + static_lib_extension = ".a" + shared_lib_extension = ".so" + dylib_lib_extension = ".dylib" + xcode_stub_lib_extension = ".tbd" + static_lib_format = shared_lib_format = dylib_lib_format = "lib%s%s" + xcode_stub_lib_format = dylib_lib_format + if sys.platform == "cygwin": + exe_extension = ".exe" + shared_lib_extension = ".dll.a" + dylib_lib_extension = ".dll" + dylib_lib_format = "cyg%s%s" + + def _fix_lib_args(self, libraries, library_dirs, runtime_library_dirs): + """Remove standard library path from rpath""" + libraries, library_dirs, runtime_library_dirs = super()._fix_lib_args( + libraries, library_dirs, runtime_library_dirs + ) + libdir = sysconfig.get_config_var('LIBDIR') + if ( + runtime_library_dirs + and libdir.startswith("/usr/lib") + and (libdir in runtime_library_dirs) + ): + runtime_library_dirs.remove(libdir) + return libraries, library_dirs, runtime_library_dirs + + def preprocess( + self, + source: str | os.PathLike[str], + output_file: str | os.PathLike[str] | None = None, + macros: list[_Macro] | None = None, + include_dirs: list[str] | tuple[str, ...] | None = None, + extra_preargs: list[str] | None = None, + extra_postargs: Iterable[str] | None = None, + ): + fixed_args = self._fix_compile_args(None, macros, include_dirs) + ignore, macros, include_dirs = fixed_args + pp_opts = gen_preprocess_options(macros, include_dirs) + pp_args = self.preprocessor + pp_opts + if output_file: + pp_args.extend(['-o', output_file]) + if extra_preargs: + pp_args[:0] = extra_preargs + if extra_postargs: + pp_args.extend(extra_postargs) + pp_args.append(source) + + # reasons to preprocess: + # - force is indicated + # - output is directed to stdout + # - source file is newer than the target + preprocess = self.force or output_file is None or newer(source, output_file) + if not preprocess: + return + + if output_file: + self.mkpath(os.path.dirname(output_file)) + + try: + self.spawn(pp_args) + except DistutilsExecError as msg: + raise CompileError(msg) + + def _compile(self, obj, src, ext, cc_args, extra_postargs, pp_opts): + compiler_so = compiler_fixup(self.compiler_so, cc_args + extra_postargs) + compiler_so_cxx = compiler_fixup(self.compiler_so_cxx, cc_args + extra_postargs) + try: + if self.detect_language(src) == 'c++': + self.spawn( + compiler_so_cxx + cc_args + [src, '-o', obj] + extra_postargs + ) + else: + self.spawn(compiler_so + cc_args + [src, '-o', obj] + extra_postargs) + except DistutilsExecError as msg: + raise CompileError(msg) + + def create_static_lib( + self, objects, output_libname, output_dir=None, debug=False, target_lang=None + ): + objects, output_dir = self._fix_object_args(objects, output_dir) + + output_filename = self.library_filename(output_libname, output_dir=output_dir) + + if self._need_link(objects, output_filename): + self.mkpath(os.path.dirname(output_filename)) + self.spawn(self.archiver + [output_filename] + objects + self.objects) + + # Not many Unices required ranlib anymore -- SunOS 4.x is, I + # think the only major Unix that does. Maybe we need some + # platform intelligence here to skip ranlib if it's not + # needed -- or maybe Python's configure script took care of + # it for us, hence the check for leading colon. + if self.ranlib: + try: + self.spawn(self.ranlib + [output_filename]) + except DistutilsExecError as msg: + raise LibError(msg) + else: + log.debug("skipping %s (up-to-date)", output_filename) + + def link( + self, + target_desc, + objects: list[str] | tuple[str, ...], + output_filename, + output_dir: str | None = None, + libraries: list[str] | tuple[str, ...] | None = None, + library_dirs: list[str] | tuple[str, ...] | None = None, + runtime_library_dirs: list[str] | tuple[str, ...] | None = None, + export_symbols=None, + debug=False, + extra_preargs=None, + extra_postargs=None, + build_temp=None, + target_lang=None, + ): + objects, output_dir = self._fix_object_args(objects, output_dir) + fixed_args = self._fix_lib_args(libraries, library_dirs, runtime_library_dirs) + libraries, library_dirs, runtime_library_dirs = fixed_args + + lib_opts = gen_lib_options(self, library_dirs, runtime_library_dirs, libraries) + if not isinstance(output_dir, (str, type(None))): + raise TypeError("'output_dir' must be a string or None") + if output_dir is not None: + output_filename = os.path.join(output_dir, output_filename) + + if self._need_link(objects, output_filename): + ld_args = objects + self.objects + lib_opts + ['-o', output_filename] + if debug: + ld_args[:0] = ['-g'] + if extra_preargs: + ld_args[:0] = extra_preargs + if extra_postargs: + ld_args.extend(extra_postargs) + self.mkpath(os.path.dirname(output_filename)) + try: + # Select a linker based on context: linker_exe when + # building an executable or linker_so (with shared options) + # when building a shared library. + building_exe = target_desc == base.Compiler.EXECUTABLE + target_cxx = target_lang == "c++" + linker = ( + (self.linker_exe_cxx if target_cxx else self.linker_exe) + if building_exe + else (self.linker_so_cxx if target_cxx else self.linker_so) + )[:] + + if target_cxx and self.compiler_cxx: + env, linker_ne = _split_env(linker) + aix, linker_na = _split_aix(linker_ne) + _, compiler_cxx_ne = _split_env(self.compiler_cxx) + _, linker_exe_ne = _split_env(self.linker_exe_cxx) + + params = _linker_params(linker_na, linker_exe_ne) + linker = env + aix + compiler_cxx_ne + params + + linker = compiler_fixup(linker, ld_args) + + self.spawn(linker + ld_args) + except DistutilsExecError as msg: + raise LinkError(msg) + else: + log.debug("skipping %s (up-to-date)", output_filename) + + # -- Miscellaneous methods ----------------------------------------- + # These are all used by the 'gen_lib_options() function, in + # ccompiler.py. + + def library_dir_option(self, dir): + return "-L" + dir + + def _is_gcc(self): + cc_var = sysconfig.get_config_var("CC") + compiler = os.path.basename(shlex.split(cc_var)[0]) + return "gcc" in compiler or "g++" in compiler + + def runtime_library_dir_option(self, dir: str) -> str | list[str]: # type: ignore[override] # Fixed in pypa/distutils#339 + # XXX Hackish, at the very least. See Python bug #445902: + # https://bugs.python.org/issue445902 + # Linkers on different platforms need different options to + # specify that directories need to be added to the list of + # directories searched for dependencies when a dynamic library + # is sought. GCC on GNU systems (Linux, FreeBSD, ...) has to + # be told to pass the -R option through to the linker, whereas + # other compilers and gcc on other systems just know this. + # Other compilers may need something slightly different. At + # this time, there's no way to determine this information from + # the configuration data stored in the Python installation, so + # we use this hack. + if sys.platform[:6] == "darwin": + from distutils.util import get_macosx_target_ver, split_version + + macosx_target_ver = get_macosx_target_ver() + if macosx_target_ver and split_version(macosx_target_ver) >= [10, 5]: + return "-Wl,-rpath," + dir + else: # no support for -rpath on earlier macOS versions + return "-L" + dir + elif sys.platform[:7] == "freebsd": + return "-Wl,-rpath=" + dir + elif sys.platform[:5] == "hp-ux": + return [ + "-Wl,+s" if self._is_gcc() else "+s", + "-L" + dir, + ] + + # For all compilers, `-Wl` is the presumed way to pass a + # compiler option to the linker + if sysconfig.get_config_var("GNULD") == "yes": + return consolidate_linker_args([ + # Force RUNPATH instead of RPATH + "-Wl,--enable-new-dtags", + "-Wl,-rpath," + dir, + ]) + else: + return "-Wl,-R" + dir + + def library_option(self, lib): + return "-l" + lib + + @staticmethod + def _library_root(dir): + """ + macOS users can specify an alternate SDK using'-isysroot'. + Calculate the SDK root if it is specified. + + Note that, as of Xcode 7, Apple SDKs may contain textual stub + libraries with .tbd extensions rather than the normal .dylib + shared libraries installed in /. The Apple compiler tool + chain handles this transparently but it can cause problems + for programs that are being built with an SDK and searching + for specific libraries. Callers of find_library_file need to + keep in mind that the base filename of the returned SDK library + file might have a different extension from that of the library + file installed on the running system, for example: + /Applications/Xcode.app/Contents/Developer/Platforms/ + MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/ + usr/lib/libedit.tbd + vs + /usr/lib/libedit.dylib + """ + cflags = sysconfig.get_config_var('CFLAGS') + match = re.search(r'-isysroot\s*(\S+)', cflags) + + apply_root = ( + sys.platform == 'darwin' + and match + and ( + dir.startswith('/System/') + or (dir.startswith('/usr/') and not dir.startswith('/usr/local/')) + ) + ) + + return os.path.join(match.group(1), dir[1:]) if apply_root else dir + + def find_library_file(self, dirs, lib, debug=False): + """ + Second-guess the linker with not much hard + data to go on: GCC seems to prefer the shared library, so + assume that *all* Unix C compilers do, + ignoring even GCC's "-static" option. + """ + lib_names = ( + self.library_filename(lib, lib_type=type) + for type in 'dylib xcode_stub shared static'.split() + ) + + roots = map(self._library_root, dirs) + + searched = itertools.starmap(os.path.join, itertools.product(roots, lib_names)) + + found = filter(os.path.exists, searched) + + # Return None if it could not be found in any dir. + return next(found, None) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/zos.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/zos.py new file mode 100644 index 0000000000000000000000000000000000000000..681c63166be8dfea8ec3f621586b901220abe1c5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/compilers/C/zos.py @@ -0,0 +1,230 @@ +"""distutils.zosccompiler + +Contains the selection of the c & c++ compilers on z/OS. There are several +different c compilers on z/OS, all of them are optional, so the correct +one needs to be chosen based on the users input. This is compatible with +the following compilers: + +IBM C/C++ For Open Enterprise Languages on z/OS 2.0 +IBM Open XL C/C++ 1.1 for z/OS +IBM XL C/C++ V2.4.1 for z/OS 2.4 and 2.5 +IBM z/OS XL C/C++ +""" + +import os + +from ... import sysconfig +from ...errors import DistutilsExecError +from . import unix +from .errors import CompileError + +_cc_args = { + 'ibm-openxl': [ + '-m64', + '-fvisibility=default', + '-fzos-le-char-mode=ascii', + '-fno-short-enums', + ], + 'ibm-xlclang': [ + '-q64', + '-qexportall', + '-qascii', + '-qstrict', + '-qnocsect', + '-Wa,asa,goff', + '-Wa,xplink', + '-qgonumber', + '-qenum=int', + '-Wc,DLL', + ], + 'ibm-xlc': [ + '-q64', + '-qexportall', + '-qascii', + '-qstrict', + '-qnocsect', + '-Wa,asa,goff', + '-Wa,xplink', + '-qgonumber', + '-qenum=int', + '-Wc,DLL', + '-qlanglvl=extc99', + ], +} + +_cxx_args = { + 'ibm-openxl': [ + '-m64', + '-fvisibility=default', + '-fzos-le-char-mode=ascii', + '-fno-short-enums', + ], + 'ibm-xlclang': [ + '-q64', + '-qexportall', + '-qascii', + '-qstrict', + '-qnocsect', + '-Wa,asa,goff', + '-Wa,xplink', + '-qgonumber', + '-qenum=int', + '-Wc,DLL', + ], + 'ibm-xlc': [ + '-q64', + '-qexportall', + '-qascii', + '-qstrict', + '-qnocsect', + '-Wa,asa,goff', + '-Wa,xplink', + '-qgonumber', + '-qenum=int', + '-Wc,DLL', + '-qlanglvl=extended0x', + ], +} + +_asm_args = { + 'ibm-openxl': ['-fasm', '-fno-integrated-as', '-Wa,--ASA', '-Wa,--GOFF'], + 'ibm-xlclang': [], + 'ibm-xlc': [], +} + +_ld_args = { + 'ibm-openxl': [], + 'ibm-xlclang': ['-Wl,dll', '-q64'], + 'ibm-xlc': ['-Wl,dll', '-q64'], +} + + +# Python on z/OS is built with no compiler specific options in it's CFLAGS. +# But each compiler requires it's own specific options to build successfully, +# though some of the options are common between them +class Compiler(unix.Compiler): + src_extensions = ['.c', '.C', '.cc', '.cxx', '.cpp', '.m', '.s'] + _cpp_extensions = ['.cc', '.cpp', '.cxx', '.C'] + _asm_extensions = ['.s'] + + def _get_zos_compiler_name(self): + zos_compiler_names = [ + os.path.basename(binary) + for envvar in ('CC', 'CXX', 'LDSHARED') + if (binary := os.environ.get(envvar, None)) + ] + if len(zos_compiler_names) == 0: + return 'ibm-openxl' + + zos_compilers = {} + for compiler in ( + 'ibm-clang', + 'ibm-clang64', + 'ibm-clang++', + 'ibm-clang++64', + 'clang', + 'clang++', + 'clang-14', + ): + zos_compilers[compiler] = 'ibm-openxl' + + for compiler in ('xlclang', 'xlclang++', 'njsc', 'njsc++'): + zos_compilers[compiler] = 'ibm-xlclang' + + for compiler in ('xlc', 'xlC', 'xlc++'): + zos_compilers[compiler] = 'ibm-xlc' + + return zos_compilers.get(zos_compiler_names[0], 'ibm-openxl') + + def __init__(self, verbose=False, force=False): + super().__init__(verbose, force=force) + self.zos_compiler = self._get_zos_compiler_name() + sysconfig.customize_compiler(self) + + def _compile(self, obj, src, ext, cc_args, extra_postargs, pp_opts): + local_args = [] + if ext in self._cpp_extensions: + compiler = self.compiler_cxx + local_args.extend(_cxx_args[self.zos_compiler]) + elif ext in self._asm_extensions: + compiler = self.compiler_so + local_args.extend(_cc_args[self.zos_compiler]) + local_args.extend(_asm_args[self.zos_compiler]) + else: + compiler = self.compiler_so + local_args.extend(_cc_args[self.zos_compiler]) + local_args.extend(cc_args) + + try: + self.spawn(compiler + local_args + [src, '-o', obj] + extra_postargs) + except DistutilsExecError as msg: + raise CompileError(msg) + + def runtime_library_dir_option(self, dir): + return '-L' + dir + + def link( + self, + target_desc, + objects, + output_filename, + output_dir=None, + libraries=None, + library_dirs=None, + runtime_library_dirs=None, + export_symbols=None, + debug=False, + extra_preargs=None, + extra_postargs=None, + build_temp=None, + target_lang=None, + ): + # For a built module to use functions from cpython, it needs to use Pythons + # side deck file. The side deck is located beside the libpython3.xx.so + ldversion = sysconfig.get_config_var('LDVERSION') + if sysconfig.python_build: + side_deck_path = os.path.join( + sysconfig.get_config_var('abs_builddir'), + f'libpython{ldversion}.x', + ) + else: + side_deck_path = os.path.join( + sysconfig.get_config_var('installed_base'), + sysconfig.get_config_var('platlibdir'), + f'libpython{ldversion}.x', + ) + + if os.path.exists(side_deck_path): + if extra_postargs: + extra_postargs.append(side_deck_path) + else: + extra_postargs = [side_deck_path] + + # Check and replace libraries included side deck files + if runtime_library_dirs: + for dir in runtime_library_dirs: + for library in libraries[:]: + library_side_deck = os.path.join(dir, f'{library}.x') + if os.path.exists(library_side_deck): + libraries.remove(library) + extra_postargs.append(library_side_deck) + break + + # Any required ld args for the given compiler + extra_postargs.extend(_ld_args[self.zos_compiler]) + + super().link( + target_desc, + objects, + output_filename, + output_dir, + libraries, + library_dirs, + runtime_library_dirs, + export_symbols, + debug, + extra_preargs, + extra_postargs, + build_temp, + target_lang, + ) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..5a8ab061009f1cd87a53ce51eff3bc9e9a632273 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/__init__.py @@ -0,0 +1,42 @@ +""" +Test suite for distutils. + +Tests for the command classes in the distutils.command package are +included in distutils.tests as well, instead of using a separate +distutils.command.tests package, since command identification is done +by import rather than matching pre-defined names. +""" + +import shutil +from collections.abc import Sequence + + +def missing_compiler_executable(cmd_names: Sequence[str] = []): # pragma: no cover + """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. + + """ + from distutils import ccompiler, errors, sysconfig + + compiler = ccompiler.new_compiler() + sysconfig.customize_compiler(compiler) + if compiler.compiler_type == "msvc": + # MSVC has no executables, so check whether initialization succeeds + try: + compiler.initialize() + except errors.DistutilsPlatformError: + return "msvc" + for name in compiler.executables: + if cmd_names and name not in cmd_names: + continue + cmd = getattr(compiler, name) + if cmd_names: + assert cmd is not None, f"the '{name}' executable is not configured" + elif not cmd: + continue + if shutil.which(cmd[0]) is None: + return cmd[0] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/compat/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/compat/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/compat/py39.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/compat/py39.py new file mode 100644 index 0000000000000000000000000000000000000000..aca3939a0cea90dd0a90d7f36fcf83a5167cbfc4 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/compat/py39.py @@ -0,0 +1,40 @@ +import sys + +if sys.version_info >= (3, 10): + from test.support.import_helper import ( + CleanImport as CleanImport, + ) + from test.support.import_helper import ( + DirsOnSysPath as DirsOnSysPath, + ) + from test.support.os_helper import ( + EnvironmentVarGuard as EnvironmentVarGuard, + ) + from test.support.os_helper import ( + rmtree as rmtree, + ) + from test.support.os_helper import ( + skip_unless_symlink as skip_unless_symlink, + ) + from test.support.os_helper import ( + unlink as unlink, + ) +else: + from test.support import ( + CleanImport as CleanImport, + ) + from test.support import ( + DirsOnSysPath as DirsOnSysPath, + ) + from test.support import ( + EnvironmentVarGuard as EnvironmentVarGuard, + ) + from test.support import ( + rmtree as rmtree, + ) + from test.support import ( + skip_unless_symlink as skip_unless_symlink, + ) + from test.support import ( + unlink as unlink, + ) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/support.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/support.py new file mode 100644 index 0000000000000000000000000000000000000000..9cd2b8a9eedbb9f11a3ed793af57b3290c5febef --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/support.py @@ -0,0 +1,134 @@ +"""Support code for distutils test cases.""" + +import itertools +import os +import pathlib +import shutil +import sys +import sysconfig +import tempfile +from distutils.core import Distribution + +import pytest +from more_itertools import always_iterable + + +@pytest.mark.usefixtures('distutils_managed_tempdir') +class TempdirManager: + """ + Mix-in class that handles temporary directories for test cases. + """ + + def mkdtemp(self): + """Create a temporary directory that will be cleaned up. + + Returns the path of the directory. + """ + d = tempfile.mkdtemp() + self.tempdirs.append(d) + return d + + def write_file(self, path, content='xxx'): + """Writes a file in the given path. + + path can be a string or a sequence. + """ + pathlib.Path(*always_iterable(path)).write_text(content, encoding='utf-8') + + def create_dist(self, pkg_name='foo', **kw): + """Will generate a test environment. + + This function creates: + - a Distribution instance using keywords + - a temporary directory with a package structure + + It returns the package directory and the distribution + instance. + """ + tmp_dir = self.mkdtemp() + pkg_dir = os.path.join(tmp_dir, pkg_name) + os.mkdir(pkg_dir) + dist = Distribution(attrs=kw) + + return pkg_dir, dist + + +class DummyCommand: + """Class to store options for retrieval via set_undefined_options().""" + + def __init__(self, **kwargs): + vars(self).update(kwargs) + + def ensure_finalized(self): + pass + + +def copy_xxmodule_c(directory): + """Helper for tests that need the xxmodule.c source file. + + Example use: + + def test_compile(self): + copy_xxmodule_c(self.tmpdir) + self.assertIn('xxmodule.c', os.listdir(self.tmpdir)) + + If the source file can be found, it will be copied to *directory*. If not, + the test will be skipped. Errors during copy are not caught. + """ + shutil.copy(_get_xxmodule_path(), os.path.join(directory, 'xxmodule.c')) + + +def _get_xxmodule_path(): + source_name = 'xxmodule.c' if sys.version_info > (3, 9) else 'xxmodule-3.8.c' + return os.path.join(os.path.dirname(__file__), source_name) + + +def fixup_build_ext(cmd): + """Function needed to make build_ext tests pass. + + When Python was built with --enable-shared on Unix, -L. is not enough to + find libpython<blah>.so, because regrtest runs in a tempdir, not in the + source directory where the .so lives. + + When Python was built with in debug mode on Windows, build_ext commands + need their debug attribute set, and it is not done automatically for + some reason. + + This function handles both of these things. Example use: + + cmd = build_ext(dist) + support.fixup_build_ext(cmd) + cmd.ensure_finalized() + + Unlike most other Unix platforms, Mac OS X embeds absolute paths + to shared libraries into executables, so the fixup is not needed there. + """ + if os.name == 'nt': + cmd.debug = sys.executable.endswith('_d.exe') + elif sysconfig.get_config_var('Py_ENABLE_SHARED'): + # To further add to the shared builds fun on Unix, we can't just add + # library_dirs to the Extension() instance because that doesn't get + # plumbed through to the final compiler command. + runshared = sysconfig.get_config_var('RUNSHARED') + if runshared is None: + cmd.library_dirs = ['.'] + else: + if sys.platform == 'darwin': + cmd.library_dirs = [] + else: + name, equals, value = runshared.partition('=') + cmd.library_dirs = [d for d in value.split(os.pathsep) if d] + + +def combine_markers(cls): + """ + pytest will honor markers as found on the class, but when + markers are on multiple subclasses, only one appears. Use + this decorator to combine those markers. + """ + cls.pytestmark = [ + mark + for base in itertools.chain([cls], cls.__bases__) + for mark in getattr(base, 'pytestmark', []) + ] + return cls diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_archive_util.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_archive_util.py new file mode 100644 index 0000000000000000000000000000000000000000..a9cc5eb00968ed9d5d77cac60ef543827c669539 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_archive_util.py @@ -0,0 +1,342 @@ +"""Tests for distutils.archive_util.""" + +import functools +import operator +import os +import pathlib +import sys +import tarfile +from distutils import archive_util +from distutils.archive_util import ( + ARCHIVE_FORMATS, + check_archive_formats, + make_archive, + make_tarball, + make_zipfile, +) +from distutils.spawn import spawn +from distutils.tests import support +from os.path import splitdrive + +import path +import pytest +from test.support import patch + +from .unix_compat import UID_0_SUPPORT, grp, pwd, require_uid_0, require_unix_id + + +def can_fs_encode(filename): + """ + Return True if the filename can be saved in the file system. + """ + if os.path.supports_unicode_filenames: + return True + try: + filename.encode(sys.getfilesystemencoding()) + except UnicodeEncodeError: + return False + return True + + +def all_equal(values): + return functools.reduce(operator.eq, values) + + +def same_drive(*paths): + return all_equal(pathlib.Path(path).drive for path in paths) + + +class ArchiveUtilTestCase(support.TempdirManager): + @pytest.mark.usefixtures('needs_zlib') + def test_make_tarball(self, name='archive'): + # creating something to tar + tmpdir = self._create_files() + self._make_tarball(tmpdir, name, '.tar.gz') + # trying an uncompressed one + self._make_tarball(tmpdir, name, '.tar', compress=None) + + @pytest.mark.usefixtures('needs_zlib') + def test_make_tarball_gzip(self): + tmpdir = self._create_files() + self._make_tarball(tmpdir, 'archive', '.tar.gz', compress='gzip') + + def test_make_tarball_bzip2(self): + pytest.importorskip('bz2') + tmpdir = self._create_files() + self._make_tarball(tmpdir, 'archive', '.tar.bz2', compress='bzip2') + + def test_make_tarball_xz(self): + pytest.importorskip('lzma') + tmpdir = self._create_files() + self._make_tarball(tmpdir, 'archive', '.tar.xz', compress='xz') + + @pytest.mark.skipif("not can_fs_encode('årchiv')") + def test_make_tarball_latin1(self): + """ + Mirror test_make_tarball, except filename contains latin characters. + """ + self.test_make_tarball('årchiv') # note this isn't a real word + + @pytest.mark.skipif("not can_fs_encode('のアーカイブ')") + def test_make_tarball_extended(self): + """ + Mirror test_make_tarball, except filename contains extended + characters outside the latin charset. + """ + self.test_make_tarball('のアーカイブ') # japanese for archive + + def _make_tarball(self, tmpdir, target_name, suffix, **kwargs): + tmpdir2 = self.mkdtemp() + if same_drive(tmpdir, tmpdir2): + pytest.skip("source and target should be on same drive") + + base_name = os.path.join(tmpdir2, target_name) + + # working with relative paths to avoid tar warnings + with path.Path(tmpdir): + make_tarball(splitdrive(base_name)[1], 'dist', **kwargs) + + # check if the compressed tarball was created + tarball = base_name + suffix + assert os.path.exists(tarball) + assert self._tarinfo(tarball) == self._created_files + + def _tarinfo(self, path): + tar = tarfile.open(path) + try: + names = tar.getnames() + names.sort() + return names + finally: + tar.close() + + _zip_created_files = [ + 'dist/', + 'dist/file1', + 'dist/file2', + 'dist/sub/', + 'dist/sub/file3', + 'dist/sub2/', + ] + _created_files = [p.rstrip('/') for p in _zip_created_files] + + def _create_files(self): + # creating something to tar + tmpdir = self.mkdtemp() + dist = os.path.join(tmpdir, 'dist') + os.mkdir(dist) + self.write_file([dist, 'file1'], 'xxx') + self.write_file([dist, 'file2'], 'xxx') + os.mkdir(os.path.join(dist, 'sub')) + self.write_file([dist, 'sub', 'file3'], 'xxx') + os.mkdir(os.path.join(dist, 'sub2')) + return tmpdir + + @pytest.mark.usefixtures('needs_zlib') + @pytest.mark.skipif("not (shutil.which('tar') and shutil.which('gzip'))") + def test_tarfile_vs_tar(self): + tmpdir = self._create_files() + tmpdir2 = self.mkdtemp() + base_name = os.path.join(tmpdir2, 'archive') + old_dir = os.getcwd() + os.chdir(tmpdir) + try: + make_tarball(base_name, 'dist') + finally: + os.chdir(old_dir) + + # check if the compressed tarball was created + tarball = base_name + '.tar.gz' + assert os.path.exists(tarball) + + # now create another tarball using `tar` + tarball2 = os.path.join(tmpdir, 'archive2.tar.gz') + tar_cmd = ['tar', '-cf', 'archive2.tar', 'dist'] + gzip_cmd = ['gzip', '-f', '-9', 'archive2.tar'] + old_dir = os.getcwd() + os.chdir(tmpdir) + try: + spawn(tar_cmd) + spawn(gzip_cmd) + finally: + os.chdir(old_dir) + + assert os.path.exists(tarball2) + # let's compare both tarballs + assert self._tarinfo(tarball) == self._created_files + assert self._tarinfo(tarball2) == self._created_files + + # trying an uncompressed one + base_name = os.path.join(tmpdir2, 'archive') + old_dir = os.getcwd() + os.chdir(tmpdir) + try: + make_tarball(base_name, 'dist', compress=None) + finally: + os.chdir(old_dir) + tarball = base_name + '.tar' + assert os.path.exists(tarball) + + @pytest.mark.usefixtures('needs_zlib') + def test_make_zipfile(self): + zipfile = pytest.importorskip('zipfile') + # creating something to tar + tmpdir = self._create_files() + base_name = os.path.join(self.mkdtemp(), 'archive') + with path.Path(tmpdir): + make_zipfile(base_name, 'dist') + + # check if the compressed tarball was created + tarball = base_name + '.zip' + assert os.path.exists(tarball) + with zipfile.ZipFile(tarball) as zf: + assert sorted(zf.namelist()) == self._zip_created_files + + def test_make_zipfile_no_zlib(self): + zipfile = pytest.importorskip('zipfile') + patch(self, archive_util.zipfile, 'zlib', None) # force zlib ImportError + + called = [] + zipfile_class = zipfile.ZipFile + + def fake_zipfile(*a, **kw): + if kw.get('compression', None) == zipfile.ZIP_STORED: + called.append((a, kw)) + return zipfile_class(*a, **kw) + + patch(self, archive_util.zipfile, 'ZipFile', fake_zipfile) + + # create something to tar and compress + tmpdir = self._create_files() + base_name = os.path.join(self.mkdtemp(), 'archive') + with path.Path(tmpdir): + make_zipfile(base_name, 'dist') + + tarball = base_name + '.zip' + assert called == [((tarball, "w"), {'compression': zipfile.ZIP_STORED})] + assert os.path.exists(tarball) + with zipfile.ZipFile(tarball) as zf: + assert sorted(zf.namelist()) == self._zip_created_files + + def test_check_archive_formats(self): + assert check_archive_formats(['gztar', 'xxx', 'zip']) == 'xxx' + assert ( + check_archive_formats(['gztar', 'bztar', 'xztar', 'ztar', 'tar', 'zip']) + is None + ) + + def test_make_archive(self): + tmpdir = self.mkdtemp() + base_name = os.path.join(tmpdir, 'archive') + with pytest.raises(ValueError): + make_archive(base_name, 'xxx') + + def test_make_archive_cwd(self): + current_dir = os.getcwd() + + def _breaks(*args, **kw): + raise RuntimeError() + + ARCHIVE_FORMATS['xxx'] = (_breaks, [], 'xxx file') + try: + try: + make_archive('xxx', 'xxx', root_dir=self.mkdtemp()) + except Exception: + pass + assert os.getcwd() == current_dir + finally: + ARCHIVE_FORMATS.pop('xxx') + + def test_make_archive_tar(self): + base_dir = self._create_files() + base_name = os.path.join(self.mkdtemp(), 'archive') + res = make_archive(base_name, 'tar', base_dir, 'dist') + assert os.path.exists(res) + assert os.path.basename(res) == 'archive.tar' + assert self._tarinfo(res) == self._created_files + + @pytest.mark.usefixtures('needs_zlib') + def test_make_archive_gztar(self): + base_dir = self._create_files() + base_name = os.path.join(self.mkdtemp(), 'archive') + res = make_archive(base_name, 'gztar', base_dir, 'dist') + assert os.path.exists(res) + assert os.path.basename(res) == 'archive.tar.gz' + assert self._tarinfo(res) == self._created_files + + def test_make_archive_bztar(self): + pytest.importorskip('bz2') + base_dir = self._create_files() + base_name = os.path.join(self.mkdtemp(), 'archive') + res = make_archive(base_name, 'bztar', base_dir, 'dist') + assert os.path.exists(res) + assert os.path.basename(res) == 'archive.tar.bz2' + assert self._tarinfo(res) == self._created_files + + def test_make_archive_xztar(self): + pytest.importorskip('lzma') + base_dir = self._create_files() + base_name = os.path.join(self.mkdtemp(), 'archive') + res = make_archive(base_name, 'xztar', base_dir, 'dist') + assert os.path.exists(res) + assert os.path.basename(res) == 'archive.tar.xz' + assert self._tarinfo(res) == self._created_files + + def test_make_archive_owner_group(self): + # testing make_archive with owner and group, with various combinations + # this works even if there's not gid/uid support + if UID_0_SUPPORT: + group = grp.getgrgid(0)[0] + owner = pwd.getpwuid(0)[0] + else: + group = owner = 'root' + + base_dir = self._create_files() + root_dir = self.mkdtemp() + base_name = os.path.join(self.mkdtemp(), 'archive') + res = make_archive( + base_name, 'zip', root_dir, base_dir, owner=owner, group=group + ) + assert os.path.exists(res) + + res = make_archive(base_name, 'zip', root_dir, base_dir) + assert os.path.exists(res) + + res = make_archive( + base_name, 'tar', root_dir, base_dir, owner=owner, group=group + ) + assert os.path.exists(res) + + res = make_archive( + base_name, 'tar', root_dir, base_dir, owner='kjhkjhkjg', group='oihohoh' + ) + assert os.path.exists(res) + + @pytest.mark.usefixtures('needs_zlib') + @require_unix_id + @require_uid_0 + def test_tarfile_root_owner(self): + tmpdir = self._create_files() + base_name = os.path.join(self.mkdtemp(), 'archive') + old_dir = os.getcwd() + os.chdir(tmpdir) + group = grp.getgrgid(0)[0] + owner = pwd.getpwuid(0)[0] + try: + archive_name = make_tarball( + base_name, 'dist', compress=None, owner=owner, group=group + ) + finally: + os.chdir(old_dir) + + # check if the compressed tarball was created + assert os.path.exists(archive_name) + + # now checks the rights + archive = tarfile.open(archive_name) + try: + for member in archive.getmembers(): + assert member.uid == 0 + assert member.gid == 0 + finally: + archive.close() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_bdist.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_bdist.py new file mode 100644 index 0000000000000000000000000000000000000000..d5696fc3dcd8081335606dc92badd73a69ceac69 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_bdist.py @@ -0,0 +1,47 @@ +"""Tests for distutils.command.bdist.""" + +from distutils.command.bdist import bdist +from distutils.tests import support + + +class TestBuild(support.TempdirManager): + def test_formats(self): + # let's create a command and make sure + # we can set the format + dist = self.create_dist()[1] + cmd = bdist(dist) + cmd.formats = ['gztar'] + cmd.ensure_finalized() + assert cmd.formats == ['gztar'] + + # what formats does bdist offer? + formats = [ + 'bztar', + 'gztar', + 'rpm', + 'tar', + 'xztar', + 'zip', + 'ztar', + ] + found = sorted(cmd.format_commands) + assert found == formats + + def test_skip_build(self): + # bug #10946: bdist --skip-build should trickle down to subcommands + dist = self.create_dist()[1] + cmd = bdist(dist) + cmd.skip_build = True + cmd.ensure_finalized() + dist.command_obj['bdist'] = cmd + + names = [ + 'bdist_dumb', + ] # bdist_rpm does not support --skip-build + + for name in names: + subcmd = cmd.get_finalized_command(name) + if getattr(subcmd, '_unsupported', False): + # command is not supported on this build + continue + assert subcmd.skip_build, f'{name} should take --skip-build from bdist' diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_bdist_dumb.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_bdist_dumb.py new file mode 100644 index 0000000000000000000000000000000000000000..1fc51d244a78058329c56a618b092e466715e565 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_bdist_dumb.py @@ -0,0 +1,78 @@ +"""Tests for distutils.command.bdist_dumb.""" + +import os +import sys +import zipfile +from distutils.command.bdist_dumb import bdist_dumb +from distutils.core import Distribution +from distutils.tests import support + +import pytest + +SETUP_PY = """\ +from distutils.core import setup +import foo + +setup(name='foo', version='0.1', py_modules=['foo'], + url='xxx', author='xxx', author_email='xxx') + +""" + + +@support.combine_markers +@pytest.mark.usefixtures('save_env') +@pytest.mark.usefixtures('save_argv') +@pytest.mark.usefixtures('save_cwd') +class TestBuildDumb( + support.TempdirManager, +): + @pytest.mark.usefixtures('needs_zlib') + def test_simple_built(self): + # let's create a simple package + tmp_dir = self.mkdtemp() + pkg_dir = os.path.join(tmp_dir, 'foo') + os.mkdir(pkg_dir) + self.write_file((pkg_dir, 'setup.py'), SETUP_PY) + self.write_file((pkg_dir, 'foo.py'), '#') + self.write_file((pkg_dir, 'MANIFEST.in'), 'include foo.py') + self.write_file((pkg_dir, 'README'), '') + + dist = Distribution({ + 'name': 'foo', + 'version': '0.1', + 'py_modules': ['foo'], + 'url': 'xxx', + 'author': 'xxx', + 'author_email': 'xxx', + }) + dist.script_name = 'setup.py' + os.chdir(pkg_dir) + + sys.argv = ['setup.py'] + cmd = bdist_dumb(dist) + + # so the output is the same no matter + # what is the platform + cmd.format = 'zip' + + cmd.ensure_finalized() + cmd.run() + + # see what we have + dist_created = os.listdir(os.path.join(pkg_dir, 'dist')) + base = f"{dist.get_fullname()}.{cmd.plat_name}.zip" + + assert dist_created == [base] + + # now let's check what we have in the zip file + fp = zipfile.ZipFile(os.path.join('dist', base)) + try: + contents = fp.namelist() + finally: + fp.close() + + contents = sorted(filter(None, map(os.path.basename, contents))) + wanted = ['foo-0.1-py{}.{}.egg-info'.format(*sys.version_info[:2]), 'foo.py'] + if not sys.dont_write_bytecode: + wanted.append(f'foo.{sys.implementation.cache_tag}.pyc') + assert contents == sorted(wanted) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_bdist_rpm.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_bdist_rpm.py new file mode 100644 index 0000000000000000000000000000000000000000..75051430e224c8908e22601133a40f5f82ee455a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_bdist_rpm.py @@ -0,0 +1,127 @@ +"""Tests for distutils.command.bdist_rpm.""" + +import os +import shutil # noqa: F401 +import sys +from distutils.command.bdist_rpm import bdist_rpm +from distutils.core import Distribution +from distutils.tests import support + +import pytest +from test.support import requires_zlib + +SETUP_PY = """\ +from distutils.core import setup +import foo + +setup(name='foo', version='0.1', py_modules=['foo'], + url='xxx', author='xxx', author_email='xxx') + +""" + + +@pytest.fixture(autouse=True) +def sys_executable_encodable(): + try: + sys.executable.encode('UTF-8') + except UnicodeEncodeError: + pytest.skip("sys.executable is not encodable to UTF-8") + + +mac_woes = pytest.mark.skipif( + "not sys.platform.startswith('linux')", + reason='spurious sdtout/stderr output under macOS', +) + + +@pytest.mark.usefixtures('save_env') +@pytest.mark.usefixtures('save_argv') +@pytest.mark.usefixtures('save_cwd') +class TestBuildRpm( + support.TempdirManager, +): + @mac_woes + @requires_zlib() + @pytest.mark.skipif("not shutil.which('rpm')") + @pytest.mark.skipif("not shutil.which('rpmbuild')") + def test_quiet(self): + # let's create a package + tmp_dir = self.mkdtemp() + os.environ['HOME'] = tmp_dir # to confine dir '.rpmdb' creation + pkg_dir = os.path.join(tmp_dir, 'foo') + os.mkdir(pkg_dir) + self.write_file((pkg_dir, 'setup.py'), SETUP_PY) + self.write_file((pkg_dir, 'foo.py'), '#') + self.write_file((pkg_dir, 'MANIFEST.in'), 'include foo.py') + self.write_file((pkg_dir, 'README'), '') + + dist = Distribution({ + 'name': 'foo', + 'version': '0.1', + 'py_modules': ['foo'], + 'url': 'xxx', + 'author': 'xxx', + 'author_email': 'xxx', + }) + dist.script_name = 'setup.py' + os.chdir(pkg_dir) + + sys.argv = ['setup.py'] + cmd = bdist_rpm(dist) + cmd.fix_python = True + + # running in quiet mode + cmd.quiet = True + cmd.ensure_finalized() + cmd.run() + + dist_created = os.listdir(os.path.join(pkg_dir, 'dist')) + assert 'foo-0.1-1.noarch.rpm' in dist_created + + # bug #2945: upload ignores bdist_rpm files + assert ('bdist_rpm', 'any', 'dist/foo-0.1-1.src.rpm') in dist.dist_files + assert ('bdist_rpm', 'any', 'dist/foo-0.1-1.noarch.rpm') in dist.dist_files + + @mac_woes + @requires_zlib() + # https://bugs.python.org/issue1533164 + @pytest.mark.skipif("not shutil.which('rpm')") + @pytest.mark.skipif("not shutil.which('rpmbuild')") + def test_no_optimize_flag(self): + # let's create a package that breaks bdist_rpm + tmp_dir = self.mkdtemp() + os.environ['HOME'] = tmp_dir # to confine dir '.rpmdb' creation + pkg_dir = os.path.join(tmp_dir, 'foo') + os.mkdir(pkg_dir) + self.write_file((pkg_dir, 'setup.py'), SETUP_PY) + self.write_file((pkg_dir, 'foo.py'), '#') + self.write_file((pkg_dir, 'MANIFEST.in'), 'include foo.py') + self.write_file((pkg_dir, 'README'), '') + + dist = Distribution({ + 'name': 'foo', + 'version': '0.1', + 'py_modules': ['foo'], + 'url': 'xxx', + 'author': 'xxx', + 'author_email': 'xxx', + }) + dist.script_name = 'setup.py' + os.chdir(pkg_dir) + + sys.argv = ['setup.py'] + cmd = bdist_rpm(dist) + cmd.fix_python = True + + cmd.quiet = True + cmd.ensure_finalized() + cmd.run() + + dist_created = os.listdir(os.path.join(pkg_dir, 'dist')) + assert 'foo-0.1-1.noarch.rpm' in dist_created + + # bug #2945: upload ignores bdist_rpm files + assert ('bdist_rpm', 'any', 'dist/foo-0.1-1.src.rpm') in dist.dist_files + assert ('bdist_rpm', 'any', 'dist/foo-0.1-1.noarch.rpm') in dist.dist_files + + os.remove(os.path.join(pkg_dir, 'dist', 'foo-0.1-1.noarch.rpm')) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_build.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_build.py new file mode 100644 index 0000000000000000000000000000000000000000..f7fe69acd1ad39cf40d277afd6409648b18df146 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_build.py @@ -0,0 +1,49 @@ +"""Tests for distutils.command.build.""" + +import os +import sys +from distutils.command.build import build +from distutils.tests import support +from sysconfig import get_config_var, get_platform + + +class TestBuild(support.TempdirManager): + def test_finalize_options(self): + pkg_dir, dist = self.create_dist() + cmd = build(dist) + cmd.finalize_options() + + # if not specified, plat_name gets the current platform + assert cmd.plat_name == get_platform() + + # build_purelib is build + lib + wanted = os.path.join(cmd.build_base, 'lib') + assert cmd.build_purelib == wanted + + # build_platlib is 'build/lib.platform-cache_tag[-pydebug]' + # examples: + # build/lib.macosx-10.3-i386-cpython39 + plat_spec = f'.{cmd.plat_name}-{sys.implementation.cache_tag}' + if get_config_var('Py_GIL_DISABLED'): + plat_spec += 't' + if hasattr(sys, 'gettotalrefcount'): + assert cmd.build_platlib.endswith('-pydebug') + plat_spec += '-pydebug' + wanted = os.path.join(cmd.build_base, 'lib' + plat_spec) + assert cmd.build_platlib == wanted + + # by default, build_lib = build_purelib + assert cmd.build_lib == cmd.build_purelib + + # build_temp is build/temp.<plat> + wanted = os.path.join(cmd.build_base, 'temp' + plat_spec) + assert cmd.build_temp == wanted + + # build_scripts is build/scripts-x.x + wanted = os.path.join( + cmd.build_base, f'scripts-{sys.version_info.major}.{sys.version_info.minor}' + ) + assert cmd.build_scripts == wanted + + # executable is os.path.normpath(sys.executable) + assert cmd.executable == os.path.normpath(sys.executable) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_build_clib.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_build_clib.py new file mode 100644 index 0000000000000000000000000000000000000000..f76f26bcea04ebeaeba20d3c65881198f841c9b5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_build_clib.py @@ -0,0 +1,134 @@ +"""Tests for distutils.command.build_clib.""" + +import os +from distutils.command.build_clib import build_clib +from distutils.errors import DistutilsSetupError +from distutils.tests import missing_compiler_executable, support + +import pytest + + +class TestBuildCLib(support.TempdirManager): + def test_check_library_dist(self): + pkg_dir, dist = self.create_dist() + cmd = build_clib(dist) + + # 'libraries' option must be a list + with pytest.raises(DistutilsSetupError): + cmd.check_library_list('foo') + + # each element of 'libraries' must a 2-tuple + with pytest.raises(DistutilsSetupError): + cmd.check_library_list(['foo1', 'foo2']) + + # first element of each tuple in 'libraries' + # must be a string (the library name) + with pytest.raises(DistutilsSetupError): + cmd.check_library_list([(1, 'foo1'), ('name', 'foo2')]) + + # library name may not contain directory separators + with pytest.raises(DistutilsSetupError): + cmd.check_library_list( + [('name', 'foo1'), ('another/name', 'foo2')], + ) + + # second element of each tuple must be a dictionary (build info) + with pytest.raises(DistutilsSetupError): + cmd.check_library_list( + [('name', {}), ('another', 'foo2')], + ) + + # those work + libs = [('name', {}), ('name', {'ok': 'good'})] + cmd.check_library_list(libs) + + def test_get_source_files(self): + pkg_dir, dist = self.create_dist() + cmd = build_clib(dist) + + # "in 'libraries' option 'sources' must be present and must be + # a list of source filenames + cmd.libraries = [('name', {})] + with pytest.raises(DistutilsSetupError): + cmd.get_source_files() + + cmd.libraries = [('name', {'sources': 1})] + with pytest.raises(DistutilsSetupError): + cmd.get_source_files() + + cmd.libraries = [('name', {'sources': ['a', 'b']})] + assert cmd.get_source_files() == ['a', 'b'] + + cmd.libraries = [('name', {'sources': ('a', 'b')})] + assert cmd.get_source_files() == ['a', 'b'] + + cmd.libraries = [ + ('name', {'sources': ('a', 'b')}), + ('name2', {'sources': ['c', 'd']}), + ] + assert cmd.get_source_files() == ['a', 'b', 'c', 'd'] + + def test_build_libraries(self): + pkg_dir, dist = self.create_dist() + cmd = build_clib(dist) + + class FakeCompiler: + def compile(*args, **kw): + pass + + create_static_lib = compile + + cmd.compiler = FakeCompiler() + + # build_libraries is also doing a bit of typo checking + lib = [('name', {'sources': 'notvalid'})] + with pytest.raises(DistutilsSetupError): + cmd.build_libraries(lib) + + lib = [('name', {'sources': list()})] + cmd.build_libraries(lib) + + lib = [('name', {'sources': tuple()})] + cmd.build_libraries(lib) + + def test_finalize_options(self): + pkg_dir, dist = self.create_dist() + cmd = build_clib(dist) + + cmd.include_dirs = 'one-dir' + cmd.finalize_options() + assert cmd.include_dirs == ['one-dir'] + + cmd.include_dirs = None + cmd.finalize_options() + assert cmd.include_dirs == [] + + cmd.distribution.libraries = 'WONTWORK' + with pytest.raises(DistutilsSetupError): + cmd.finalize_options() + + @pytest.mark.skipif('platform.system() == "Windows"') + def test_run(self): + pkg_dir, dist = self.create_dist() + cmd = build_clib(dist) + + foo_c = os.path.join(pkg_dir, 'foo.c') + self.write_file(foo_c, 'int main(void) { return 1;}\n') + cmd.libraries = [('foo', {'sources': [foo_c]})] + + build_temp = os.path.join(pkg_dir, 'build') + os.mkdir(build_temp) + cmd.build_temp = build_temp + cmd.build_clib = build_temp + + # Before we run the command, we want to make sure + # all commands are present on the system. + ccmd = missing_compiler_executable() + if ccmd is not None: + self.skipTest(f'The {ccmd!r} command is not found') + + # this should work + cmd.run() + + # let's check the result + assert 'libfoo.a' in os.listdir(build_temp) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_build_ext.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_build_ext.py new file mode 100644 index 0000000000000000000000000000000000000000..dab0507f3d3ec104fb4acfe5b15f92661ff33a37 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_build_ext.py @@ -0,0 +1,628 @@ +import contextlib +import glob +import importlib +import os.path +import platform +import re +import shutil +import site +import subprocess +import sys +import tempfile +import textwrap +import time +from distutils import sysconfig +from distutils.command.build_ext import build_ext +from distutils.core import Distribution +from distutils.errors import ( + CompileError, + DistutilsPlatformError, + DistutilsSetupError, + UnknownFileError, +) +from distutils.extension import Extension +from distutils.tests import missing_compiler_executable +from distutils.tests.support import TempdirManager, copy_xxmodule_c, fixup_build_ext +from io import StringIO + +import jaraco.path +import path +import pytest +from test import support + +from .compat import py39 as import_helper + + +@pytest.fixture() +def user_site_dir(request): + self = request.instance + self.tmp_dir = self.mkdtemp() + self.tmp_path = path.Path(self.tmp_dir) + from distutils.command import build_ext + + orig_user_base = site.USER_BASE + + site.USER_BASE = self.mkdtemp() + build_ext.USER_BASE = site.USER_BASE + + # bpo-30132: On Windows, a .pdb file may be created in the current + # working directory. Create a temporary working directory to cleanup + # everything at the end of the test. + with self.tmp_path: + yield + + site.USER_BASE = orig_user_base + build_ext.USER_BASE = orig_user_base + + if sys.platform == 'cygwin': + time.sleep(1) + + +@contextlib.contextmanager +def safe_extension_import(name, path): + with import_helper.CleanImport(name): + with extension_redirect(name, path) as new_path: + with import_helper.DirsOnSysPath(new_path): + yield + + +@contextlib.contextmanager +def extension_redirect(mod, path): + """ + Tests will fail to tear down an extension module if it's been imported. + + Before importing, copy the file to a temporary directory that won't + be cleaned up. Yield the new path. + """ + if platform.system() != "Windows" and sys.platform != "cygwin": + yield path + return + with import_helper.DirsOnSysPath(path): + spec = importlib.util.find_spec(mod) + filename = os.path.basename(spec.origin) + trash_dir = tempfile.mkdtemp(prefix='deleteme') + dest = os.path.join(trash_dir, os.path.basename(filename)) + shutil.copy(spec.origin, dest) + yield trash_dir + # TODO: can the file be scheduled for deletion? + + +@pytest.mark.usefixtures('user_site_dir') +class TestBuildExt(TempdirManager): + def build_ext(self, *args, **kwargs): + return build_ext(*args, **kwargs) + + @pytest.mark.parametrize("copy_so", [False]) + def test_build_ext(self, copy_so): + missing_compiler_executable() + copy_xxmodule_c(self.tmp_dir) + xx_c = os.path.join(self.tmp_dir, 'xxmodule.c') + xx_ext = Extension('xx', [xx_c]) + if sys.platform != "win32": + if not copy_so: + xx_ext = Extension( + 'xx', + [xx_c], + library_dirs=['/usr/lib'], + libraries=['z'], + runtime_library_dirs=['/usr/lib'], + ) + elif sys.platform == 'linux': + libz_so = { + os.path.realpath(name) for name in glob.iglob('/usr/lib*/libz.so*') + } + libz_so = sorted(libz_so, key=lambda lib_path: len(lib_path)) + shutil.copyfile(libz_so[-1], '/tmp/libxx_z.so') + + xx_ext = Extension( + 'xx', + [xx_c], + library_dirs=['/tmp'], + libraries=['xx_z'], + runtime_library_dirs=['/tmp'], + ) + dist = Distribution({'name': 'xx', 'ext_modules': [xx_ext]}) + dist.package_dir = self.tmp_dir + cmd = self.build_ext(dist) + fixup_build_ext(cmd) + cmd.build_lib = self.tmp_dir + cmd.build_temp = self.tmp_dir + + old_stdout = sys.stdout + if not support.verbose: + # silence compiler output + sys.stdout = StringIO() + try: + cmd.ensure_finalized() + cmd.run() + finally: + sys.stdout = old_stdout + + with safe_extension_import('xx', self.tmp_dir): + self._test_xx(copy_so) + + if sys.platform == 'linux' and copy_so: + os.unlink('/tmp/libxx_z.so') + + @staticmethod + def _test_xx(copy_so): + import xx # type: ignore[import-not-found] # Module generated for tests + + for attr in ('error', 'foo', 'new', 'roj'): + assert hasattr(xx, attr) + + assert xx.foo(2, 5) == 7 + assert xx.foo(13, 15) == 28 + assert xx.new().demo() is None + if support.HAVE_DOCSTRINGS: + doc = 'This is a template module just for instruction.' + assert xx.__doc__ == doc + assert isinstance(xx.Null(), xx.Null) + assert isinstance(xx.Str(), xx.Str) + + if sys.platform == 'linux': + so_headers = subprocess.check_output( + ["readelf", "-d", xx.__file__], universal_newlines=True + ) + import pprint + + pprint.pprint(so_headers) + rpaths = [ + rpath + for line in so_headers.split("\n") + if "RPATH" in line or "RUNPATH" in line + for rpath in line.split()[2][1:-1].split(":") + ] + if not copy_so: + pprint.pprint(rpaths) + # Linked against a library in /usr/lib{,64} + assert "/usr/lib" not in rpaths and "/usr/lib64" not in rpaths + else: + # Linked against a library in /tmp + assert "/tmp" in rpaths + # The import is the real test here + + def test_solaris_enable_shared(self): + dist = Distribution({'name': 'xx'}) + cmd = self.build_ext(dist) + old = sys.platform + + sys.platform = 'sunos' # fooling finalize_options + from distutils.sysconfig import _config_vars + + old_var = _config_vars.get('Py_ENABLE_SHARED') + _config_vars['Py_ENABLE_SHARED'] = True + try: + cmd.ensure_finalized() + finally: + sys.platform = old + if old_var is None: + del _config_vars['Py_ENABLE_SHARED'] + else: + _config_vars['Py_ENABLE_SHARED'] = old_var + + # make sure we get some library dirs under solaris + assert len(cmd.library_dirs) > 0 + + def test_user_site(self): + import site + + dist = Distribution({'name': 'xx'}) + cmd = self.build_ext(dist) + + # making sure the user option is there + options = [name for name, short, label in cmd.user_options] + assert 'user' in options + + # setting a value + cmd.user = True + + # setting user based lib and include + lib = os.path.join(site.USER_BASE, 'lib') + incl = os.path.join(site.USER_BASE, 'include') + os.mkdir(lib) + os.mkdir(incl) + + # let's run finalize + cmd.ensure_finalized() + + # see if include_dirs and library_dirs + # were set + assert lib in cmd.library_dirs + assert lib in cmd.rpath + assert incl in cmd.include_dirs + + def test_optional_extension(self): + # this extension will fail, but let's ignore this failure + # with the optional argument. + modules = [Extension('foo', ['xxx'], optional=False)] + dist = Distribution({'name': 'xx', 'ext_modules': modules}) + cmd = self.build_ext(dist) + cmd.ensure_finalized() + with pytest.raises((UnknownFileError, CompileError)): + cmd.run() # should raise an error + + modules = [Extension('foo', ['xxx'], optional=True)] + dist = Distribution({'name': 'xx', 'ext_modules': modules}) + cmd = self.build_ext(dist) + cmd.ensure_finalized() + cmd.run() # should pass + + def test_finalize_options(self): + # Make sure Python's include directories (for Python.h, pyconfig.h, + # etc.) are in the include search path. + modules = [Extension('foo', ['xxx'], optional=False)] + dist = Distribution({'name': 'xx', 'ext_modules': modules}) + cmd = self.build_ext(dist) + cmd.finalize_options() + + py_include = sysconfig.get_python_inc() + for p in py_include.split(os.path.pathsep): + assert p in cmd.include_dirs + + plat_py_include = sysconfig.get_python_inc(plat_specific=True) + for p in plat_py_include.split(os.path.pathsep): + assert p in cmd.include_dirs + + # make sure cmd.libraries is turned into a list + # if it's a string + cmd = self.build_ext(dist) + cmd.libraries = 'my_lib, other_lib lastlib' + cmd.finalize_options() + assert cmd.libraries == ['my_lib', 'other_lib', 'lastlib'] + + # make sure cmd.library_dirs is turned into a list + # if it's a string + cmd = self.build_ext(dist) + cmd.library_dirs = f'my_lib_dir{os.pathsep}other_lib_dir' + cmd.finalize_options() + assert 'my_lib_dir' in cmd.library_dirs + assert 'other_lib_dir' in cmd.library_dirs + + # make sure rpath is turned into a list + # if it's a string + cmd = self.build_ext(dist) + cmd.rpath = f'one{os.pathsep}two' + cmd.finalize_options() + assert cmd.rpath == ['one', 'two'] + + # make sure cmd.link_objects is turned into a list + # if it's a string + cmd = build_ext(dist) + cmd.link_objects = 'one two,three' + cmd.finalize_options() + assert cmd.link_objects == ['one', 'two', 'three'] + + # XXX more tests to perform for win32 + + # make sure define is turned into 2-tuples + # strings if they are ','-separated strings + cmd = self.build_ext(dist) + cmd.define = 'one,two' + cmd.finalize_options() + assert cmd.define == [('one', '1'), ('two', '1')] + + # make sure undef is turned into a list of + # strings if they are ','-separated strings + cmd = self.build_ext(dist) + cmd.undef = 'one,two' + cmd.finalize_options() + assert cmd.undef == ['one', 'two'] + + # make sure swig_opts is turned into a list + cmd = self.build_ext(dist) + cmd.swig_opts = None + cmd.finalize_options() + assert cmd.swig_opts == [] + + cmd = self.build_ext(dist) + cmd.swig_opts = '1 2' + cmd.finalize_options() + assert cmd.swig_opts == ['1', '2'] + + def test_check_extensions_list(self): + dist = Distribution() + cmd = self.build_ext(dist) + cmd.finalize_options() + + # 'extensions' option must be a list of Extension instances + with pytest.raises(DistutilsSetupError): + cmd.check_extensions_list('foo') + + # each element of 'ext_modules' option must be an + # Extension instance or 2-tuple + exts = [('bar', 'foo', 'bar'), 'foo'] + with pytest.raises(DistutilsSetupError): + cmd.check_extensions_list(exts) + + # first element of each tuple in 'ext_modules' + # must be the extension name (a string) and match + # a python dotted-separated name + exts = [('foo-bar', '')] + with pytest.raises(DistutilsSetupError): + cmd.check_extensions_list(exts) + + # second element of each tuple in 'ext_modules' + # must be a dictionary (build info) + exts = [('foo.bar', '')] + with pytest.raises(DistutilsSetupError): + cmd.check_extensions_list(exts) + + # ok this one should pass + exts = [('foo.bar', {'sources': [''], 'libraries': 'foo', 'some': 'bar'})] + cmd.check_extensions_list(exts) + ext = exts[0] + assert isinstance(ext, Extension) + + # check_extensions_list adds in ext the values passed + # when they are in ('include_dirs', 'library_dirs', 'libraries' + # 'extra_objects', 'extra_compile_args', 'extra_link_args') + assert ext.libraries == 'foo' + assert not hasattr(ext, 'some') + + # 'macros' element of build info dict must be 1- or 2-tuple + exts = [ + ( + 'foo.bar', + { + 'sources': [''], + 'libraries': 'foo', + 'some': 'bar', + 'macros': [('1', '2', '3'), 'foo'], + }, + ) + ] + with pytest.raises(DistutilsSetupError): + cmd.check_extensions_list(exts) + + exts[0][1]['macros'] = [('1', '2'), ('3',)] + cmd.check_extensions_list(exts) + assert exts[0].undef_macros == ['3'] + assert exts[0].define_macros == [('1', '2')] + + def test_get_source_files(self): + modules = [Extension('foo', ['xxx'], optional=False)] + dist = Distribution({'name': 'xx', 'ext_modules': modules}) + cmd = self.build_ext(dist) + cmd.ensure_finalized() + assert cmd.get_source_files() == ['xxx'] + + def test_unicode_module_names(self): + modules = [ + Extension('foo', ['aaa'], optional=False), + Extension('föö', ['uuu'], optional=False), + ] + dist = Distribution({'name': 'xx', 'ext_modules': modules}) + cmd = self.build_ext(dist) + cmd.ensure_finalized() + assert re.search(r'foo(_d)?\..*', cmd.get_ext_filename(modules[0].name)) + assert re.search(r'föö(_d)?\..*', cmd.get_ext_filename(modules[1].name)) + assert cmd.get_export_symbols(modules[0]) == ['PyInit_foo'] + assert cmd.get_export_symbols(modules[1]) == ['PyInitU_f_1gaa'] + + def test_export_symbols__init__(self): + # https://github.com/python/cpython/issues/80074 + # https://github.com/pypa/setuptools/issues/4826 + modules = [ + Extension('foo.__init__', ['aaa']), + Extension('föö.__init__', ['uuu']), + ] + dist = Distribution({'name': 'xx', 'ext_modules': modules}) + cmd = self.build_ext(dist) + cmd.ensure_finalized() + assert cmd.get_export_symbols(modules[0]) == ['PyInit_foo'] + assert cmd.get_export_symbols(modules[1]) == ['PyInitU_f_1gaa'] + + def test_compiler_option(self): + # cmd.compiler is an option and + # should not be overridden by a compiler instance + # when the command is run + dist = Distribution() + cmd = self.build_ext(dist) + cmd.compiler = 'unix' + cmd.ensure_finalized() + cmd.run() + assert cmd.compiler == 'unix' + + def test_get_outputs(self): + missing_compiler_executable() + tmp_dir = self.mkdtemp() + c_file = os.path.join(tmp_dir, 'foo.c') + self.write_file(c_file, 'void PyInit_foo(void) {}\n') + ext = Extension('foo', [c_file], optional=False) + dist = Distribution({'name': 'xx', 'ext_modules': [ext]}) + cmd = self.build_ext(dist) + fixup_build_ext(cmd) + cmd.ensure_finalized() + assert len(cmd.get_outputs()) == 1 + + cmd.build_lib = os.path.join(self.tmp_dir, 'build') + cmd.build_temp = os.path.join(self.tmp_dir, 'tempt') + + # issue #5977 : distutils build_ext.get_outputs + # returns wrong result with --inplace + other_tmp_dir = os.path.realpath(self.mkdtemp()) + old_wd = os.getcwd() + os.chdir(other_tmp_dir) + try: + cmd.inplace = True + cmd.run() + so_file = cmd.get_outputs()[0] + finally: + os.chdir(old_wd) + assert os.path.exists(so_file) + ext_suffix = sysconfig.get_config_var('EXT_SUFFIX') + assert so_file.endswith(ext_suffix) + so_dir = os.path.dirname(so_file) + assert so_dir == other_tmp_dir + + cmd.inplace = False + cmd.compiler = None + cmd.run() + so_file = cmd.get_outputs()[0] + assert os.path.exists(so_file) + assert so_file.endswith(ext_suffix) + so_dir = os.path.dirname(so_file) + assert so_dir == cmd.build_lib + + # inplace = False, cmd.package = 'bar' + build_py = cmd.get_finalized_command('build_py') + build_py.package_dir = {'': 'bar'} + path = cmd.get_ext_fullpath('foo') + # checking that the last directory is the build_dir + path = os.path.split(path)[0] + assert path == cmd.build_lib + + # inplace = True, cmd.package = 'bar' + cmd.inplace = True + other_tmp_dir = os.path.realpath(self.mkdtemp()) + old_wd = os.getcwd() + os.chdir(other_tmp_dir) + try: + path = cmd.get_ext_fullpath('foo') + finally: + os.chdir(old_wd) + # checking that the last directory is bar + path = os.path.split(path)[0] + lastdir = os.path.split(path)[-1] + assert lastdir == 'bar' + + def test_ext_fullpath(self): + ext = sysconfig.get_config_var('EXT_SUFFIX') + # building lxml.etree inplace + # etree_c = os.path.join(self.tmp_dir, 'lxml.etree.c') + # etree_ext = Extension('lxml.etree', [etree_c]) + # dist = Distribution({'name': 'lxml', 'ext_modules': [etree_ext]}) + dist = Distribution() + cmd = self.build_ext(dist) + cmd.inplace = True + cmd.distribution.package_dir = {'': 'src'} + cmd.distribution.packages = ['lxml', 'lxml.html'] + curdir = os.getcwd() + wanted = os.path.join(curdir, 'src', 'lxml', 'etree' + ext) + path = cmd.get_ext_fullpath('lxml.etree') + assert wanted == path + + # building lxml.etree not inplace + cmd.inplace = False + cmd.build_lib = os.path.join(curdir, 'tmpdir') + wanted = os.path.join(curdir, 'tmpdir', 'lxml', 'etree' + ext) + path = cmd.get_ext_fullpath('lxml.etree') + assert wanted == path + + # building twisted.runner.portmap not inplace + build_py = cmd.get_finalized_command('build_py') + build_py.package_dir = {} + cmd.distribution.packages = ['twisted', 'twisted.runner.portmap'] + path = cmd.get_ext_fullpath('twisted.runner.portmap') + wanted = os.path.join(curdir, 'tmpdir', 'twisted', 'runner', 'portmap' + ext) + assert wanted == path + + # building twisted.runner.portmap inplace + cmd.inplace = True + path = cmd.get_ext_fullpath('twisted.runner.portmap') + wanted = os.path.join(curdir, 'twisted', 'runner', 'portmap' + ext) + assert wanted == path + + @pytest.mark.skipif('platform.system() != "Darwin"') + @pytest.mark.usefixtures('save_env') + def test_deployment_target_default(self): + # Issue 9516: Test that, in the absence of the environment variable, + # an extension module is compiled with the same deployment target as + # the interpreter. + self._try_compile_deployment_target('==', None) + + @pytest.mark.skipif('platform.system() != "Darwin"') + @pytest.mark.usefixtures('save_env') + def test_deployment_target_too_low(self): + # Issue 9516: Test that an extension module is not allowed to be + # compiled with a deployment target less than that of the interpreter. + with pytest.raises(DistutilsPlatformError): + self._try_compile_deployment_target('>', '10.1') + + @pytest.mark.skipif('platform.system() != "Darwin"') + @pytest.mark.usefixtures('save_env') + def test_deployment_target_higher_ok(self): # pragma: no cover + # Issue 9516: Test that an extension module can be compiled with a + # deployment target higher than that of the interpreter: the ext + # module may depend on some newer OS feature. + deptarget = sysconfig.get_config_var('MACOSX_DEPLOYMENT_TARGET') + if deptarget: + # increment the minor version number (i.e. 10.6 -> 10.7) + deptarget = [int(x) for x in deptarget.split('.')] + deptarget[-1] += 1 + deptarget = '.'.join(str(i) for i in deptarget) + self._try_compile_deployment_target('<', deptarget) + + def _try_compile_deployment_target(self, operator, target): # pragma: no cover + if target is None: + if os.environ.get('MACOSX_DEPLOYMENT_TARGET'): + del os.environ['MACOSX_DEPLOYMENT_TARGET'] + else: + os.environ['MACOSX_DEPLOYMENT_TARGET'] = target + + jaraco.path.build( + { + 'deptargetmodule.c': textwrap.dedent(f"""\ + #include <AvailabilityMacros.h> + + int dummy; + + #if TARGET {operator} MAC_OS_X_VERSION_MIN_REQUIRED + #else + #error "Unexpected target" + #endif + + """), + }, + self.tmp_path, + ) + + # get the deployment target that the interpreter was built with + target = sysconfig.get_config_var('MACOSX_DEPLOYMENT_TARGET') + target = tuple(map(int, target.split('.')[0:2])) + # format the target value as defined in the Apple + # Availability Macros. We can't use the macro names since + # at least one value we test with will not exist yet. + if target[:2] < (10, 10): + # for 10.1 through 10.9.x -> "10n0" + tmpl = '{:02}{:01}0' + else: + # for 10.10 and beyond -> "10nn00" + if len(target) >= 2: + tmpl = '{:02}{:02}00' + else: + # 11 and later can have no minor version (11 instead of 11.0) + tmpl = '{:02}0000' + target = tmpl.format(*target) + deptarget_ext = Extension( + 'deptarget', + [self.tmp_path / 'deptargetmodule.c'], + extra_compile_args=[f'-DTARGET={target}'], + ) + dist = Distribution({'name': 'deptarget', 'ext_modules': [deptarget_ext]}) + dist.package_dir = self.tmp_dir + cmd = self.build_ext(dist) + cmd.build_lib = self.tmp_dir + cmd.build_temp = self.tmp_dir + + try: + old_stdout = sys.stdout + if not support.verbose: + # silence compiler output + sys.stdout = StringIO() + try: + cmd.ensure_finalized() + cmd.run() + finally: + sys.stdout = old_stdout + + except CompileError: + self.fail("Wrong deployment target during compilation") + + +class TestParallelBuildExt(TestBuildExt): + def build_ext(self, *args, **kwargs): + build_ext = super().build_ext(*args, **kwargs) + build_ext.parallel = True + return build_ext diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_build_py.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_build_py.py new file mode 100644 index 0000000000000000000000000000000000000000..b316ed43a11836210caeb7177bd8890a1f61d1bb --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_build_py.py @@ -0,0 +1,196 @@ +"""Tests for distutils.command.build_py.""" + +import os +import sys +from distutils.command.build_py import build_py +from distutils.core import Distribution +from distutils.errors import DistutilsFileError +from distutils.tests import support + +import jaraco.path +import pytest + + +@support.combine_markers +class TestBuildPy(support.TempdirManager): + def test_package_data(self): + sources = self.mkdtemp() + jaraco.path.build( + { + '__init__.py': "# Pretend this is a package.", + 'README.txt': 'Info about this package', + }, + sources, + ) + + destination = self.mkdtemp() + + dist = Distribution({"packages": ["pkg"], "package_dir": {"pkg": sources}}) + # script_name need not exist, it just need to be initialized + dist.script_name = os.path.join(sources, "setup.py") + dist.command_obj["build"] = support.DummyCommand( + force=False, build_lib=destination + ) + dist.packages = ["pkg"] + dist.package_data = {"pkg": ["README.txt"]} + dist.package_dir = {"pkg": sources} + + cmd = build_py(dist) + cmd.compile = True + cmd.ensure_finalized() + assert cmd.package_data == dist.package_data + + cmd.run() + + # This makes sure the list of outputs includes byte-compiled + # files for Python modules but not for package data files + # (there shouldn't *be* byte-code files for those!). + assert len(cmd.get_outputs()) == 3 + pkgdest = os.path.join(destination, "pkg") + files = os.listdir(pkgdest) + pycache_dir = os.path.join(pkgdest, "__pycache__") + assert "__init__.py" in files + assert "README.txt" in files + if sys.dont_write_bytecode: + assert not os.path.exists(pycache_dir) + else: + pyc_files = os.listdir(pycache_dir) + assert f"__init__.{sys.implementation.cache_tag}.pyc" in pyc_files + + def test_empty_package_dir(self): + # See bugs #1668596/#1720897 + sources = self.mkdtemp() + jaraco.path.build({'__init__.py': '', 'doc': {'testfile': ''}}, sources) + + os.chdir(sources) + dist = Distribution({ + "packages": ["pkg"], + "package_dir": {"pkg": ""}, + "package_data": {"pkg": ["doc/*"]}, + }) + # script_name need not exist, it just need to be initialized + dist.script_name = os.path.join(sources, "setup.py") + dist.script_args = ["build"] + dist.parse_command_line() + + try: + dist.run_commands() + except DistutilsFileError: + self.fail("failed package_data test when package_dir is ''") + + @pytest.mark.skipif('sys.dont_write_bytecode') + def test_byte_compile(self): + project_dir, dist = self.create_dist(py_modules=['boiledeggs']) + os.chdir(project_dir) + self.write_file('boiledeggs.py', 'import antigravity') + cmd = build_py(dist) + cmd.compile = True + cmd.build_lib = 'here' + cmd.finalize_options() + cmd.run() + + found = os.listdir(cmd.build_lib) + assert sorted(found) == ['__pycache__', 'boiledeggs.py'] + found = os.listdir(os.path.join(cmd.build_lib, '__pycache__')) + assert found == [f'boiledeggs.{sys.implementation.cache_tag}.pyc'] + + @pytest.mark.skipif('sys.dont_write_bytecode') + def test_byte_compile_optimized(self): + project_dir, dist = self.create_dist(py_modules=['boiledeggs']) + os.chdir(project_dir) + self.write_file('boiledeggs.py', 'import antigravity') + cmd = build_py(dist) + cmd.compile = False + cmd.optimize = 1 + cmd.build_lib = 'here' + cmd.finalize_options() + cmd.run() + + found = os.listdir(cmd.build_lib) + assert sorted(found) == ['__pycache__', 'boiledeggs.py'] + found = os.listdir(os.path.join(cmd.build_lib, '__pycache__')) + expect = f'boiledeggs.{sys.implementation.cache_tag}.opt-1.pyc' + assert sorted(found) == [expect] + + def test_dir_in_package_data(self): + """ + A directory in package_data should not be added to the filelist. + """ + # See bug 19286 + sources = self.mkdtemp() + jaraco.path.build( + { + 'pkg': { + '__init__.py': '', + 'doc': { + 'testfile': '', + # create a directory that could be incorrectly detected as a file + 'otherdir': {}, + }, + } + }, + sources, + ) + + os.chdir(sources) + dist = Distribution({"packages": ["pkg"], "package_data": {"pkg": ["doc/*"]}}) + # script_name need not exist, it just need to be initialized + dist.script_name = os.path.join(sources, "setup.py") + dist.script_args = ["build"] + dist.parse_command_line() + + try: + dist.run_commands() + except DistutilsFileError: + self.fail("failed package_data when data dir includes a dir") + + def test_dont_write_bytecode(self, caplog): + # makes sure byte_compile is not used + dist = self.create_dist()[1] + cmd = build_py(dist) + cmd.compile = True + cmd.optimize = 1 + + old_dont_write_bytecode = sys.dont_write_bytecode + sys.dont_write_bytecode = True + try: + cmd.byte_compile([]) + finally: + sys.dont_write_bytecode = old_dont_write_bytecode + + assert 'byte-compiling is disabled' in caplog.records[0].message + + def test_namespace_package_does_not_warn(self, caplog): + """ + Originally distutils implementation did not account for PEP 420 + and included warns for package directories that did not contain + ``__init__.py`` files. + After the acceptance of PEP 420, these warnings don't make more sense + so we want to ensure there are not displayed to not confuse the users. + """ + # Create a fake project structure with a package namespace: + tmp = self.mkdtemp() + jaraco.path.build({'ns': {'pkg': {'module.py': ''}}}, tmp) + os.chdir(tmp) + + # Configure the package: + attrs = { + "name": "ns.pkg", + "packages": ["ns", "ns.pkg"], + "script_name": "setup.py", + } + dist = Distribution(attrs) + + # Run code paths that would trigger the trap: + cmd = dist.get_command_obj("build_py") + cmd.finalize_options() + modules = cmd.find_all_modules() + assert len(modules) == 1 + module_path = modules[0][-1] + assert module_path.replace(os.sep, "/") == "ns/pkg/module.py" + + cmd.run() + + assert not any( + "package init file" in msg and "not found" in msg for msg in caplog.messages + ) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_build_scripts.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_build_scripts.py new file mode 100644 index 0000000000000000000000000000000000000000..3582f691ef578a419555c6ffbba6a619310517a6 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_build_scripts.py @@ -0,0 +1,96 @@ +"""Tests for distutils.command.build_scripts.""" + +import os +import textwrap +from distutils import sysconfig +from distutils.command.build_scripts import build_scripts +from distutils.core import Distribution +from distutils.tests import support + +import jaraco.path + + +class TestBuildScripts(support.TempdirManager): + def test_default_settings(self): + cmd = self.get_build_scripts_cmd("/foo/bar", []) + assert not cmd.force + assert cmd.build_dir is None + + cmd.finalize_options() + + assert cmd.force + assert cmd.build_dir == "/foo/bar" + + def test_build(self): + source = self.mkdtemp() + target = self.mkdtemp() + expected = self.write_sample_scripts(source) + + cmd = self.get_build_scripts_cmd( + target, [os.path.join(source, fn) for fn in expected] + ) + cmd.finalize_options() + cmd.run() + + built = os.listdir(target) + for name in expected: + assert name in built + + def get_build_scripts_cmd(self, target, scripts): + import sys + + dist = Distribution() + dist.scripts = scripts + dist.command_obj["build"] = support.DummyCommand( + build_scripts=target, force=True, executable=sys.executable + ) + return build_scripts(dist) + + @staticmethod + def write_sample_scripts(dir): + spec = { + 'script1.py': textwrap.dedent(""" + #! /usr/bin/env python2.3 + # bogus script w/ Python sh-bang + pass + """).lstrip(), + 'script2.py': textwrap.dedent(""" + #!/usr/bin/python + # bogus script w/ Python sh-bang + pass + """).lstrip(), + 'shell.sh': textwrap.dedent(""" + #!/bin/sh + # bogus shell script w/ sh-bang + exit 0 + """).lstrip(), + } + jaraco.path.build(spec, dir) + return list(spec) + + def test_version_int(self): + source = self.mkdtemp() + target = self.mkdtemp() + expected = self.write_sample_scripts(source) + + cmd = self.get_build_scripts_cmd( + target, [os.path.join(source, fn) for fn in expected] + ) + cmd.finalize_options() + + # https://bugs.python.org/issue4524 + # + # On linux-g++-32 with command line `./configure --enable-ipv6 + # --with-suffix=3`, python is compiled okay but the build scripts + # failed when writing the name of the executable + old = sysconfig.get_config_vars().get('VERSION') + sysconfig._config_vars['VERSION'] = 4 + try: + cmd.run() + finally: + if old is not None: + sysconfig._config_vars['VERSION'] = old + + built = os.listdir(target) + for name in expected: + assert name in built diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_check.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_check.py new file mode 100644 index 0000000000000000000000000000000000000000..b672b1f972b46f399eb5b2ef263da2548d52ef89 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_check.py @@ -0,0 +1,194 @@ +"""Tests for distutils.command.check.""" + +import os +import textwrap +from distutils.command.check import check +from distutils.errors import DistutilsSetupError +from distutils.tests import support + +import pytest + +try: + import pygments +except ImportError: + pygments = None + + +HERE = os.path.dirname(__file__) + + +@support.combine_markers +class TestCheck(support.TempdirManager): + def _run(self, metadata=None, cwd=None, **options): + if metadata is None: + metadata = {} + if cwd is not None: + old_dir = os.getcwd() + os.chdir(cwd) + pkg_info, dist = self.create_dist(**metadata) + cmd = check(dist) + cmd.initialize_options() + for name, value in options.items(): + setattr(cmd, name, value) + cmd.ensure_finalized() + cmd.run() + if cwd is not None: + os.chdir(old_dir) + return cmd + + def test_check_metadata(self): + # let's run the command with no metadata at all + # by default, check is checking the metadata + # should have some warnings + cmd = self._run() + assert cmd._warnings == 1 + + # now let's add the required fields + # and run it again, to make sure we don't get + # any warning anymore + metadata = { + 'url': 'xxx', + 'author': 'xxx', + 'author_email': 'xxx', + 'name': 'xxx', + 'version': 'xxx', + } + cmd = self._run(metadata) + assert cmd._warnings == 0 + + # now with the strict mode, we should + # get an error if there are missing metadata + with pytest.raises(DistutilsSetupError): + self._run({}, **{'strict': 1}) + + # and of course, no error when all metadata are present + cmd = self._run(metadata, strict=True) + assert cmd._warnings == 0 + + # now a test with non-ASCII characters + metadata = { + 'url': 'xxx', + 'author': '\u00c9ric', + 'author_email': 'xxx', + 'name': 'xxx', + 'version': 'xxx', + 'description': 'Something about esszet \u00df', + 'long_description': 'More things about esszet \u00df', + } + cmd = self._run(metadata) + assert cmd._warnings == 0 + + def test_check_author_maintainer(self): + for kind in ("author", "maintainer"): + # ensure no warning when author_email or maintainer_email is given + # (the spec allows these fields to take the form "Name <email>") + metadata = { + 'url': 'xxx', + kind + '_email': 'Name <name@email.com>', + 'name': 'xxx', + 'version': 'xxx', + } + cmd = self._run(metadata) + assert cmd._warnings == 0 + + # the check should not warn if only email is given + metadata[kind + '_email'] = 'name@email.com' + cmd = self._run(metadata) + assert cmd._warnings == 0 + + # the check should not warn if only the name is given + metadata[kind] = "Name" + del metadata[kind + '_email'] + cmd = self._run(metadata) + assert cmd._warnings == 0 + + def test_check_document(self): + pytest.importorskip('docutils') + pkg_info, dist = self.create_dist() + cmd = check(dist) + + # let's see if it detects broken rest + broken_rest = 'title\n===\n\ntest' + msgs = cmd._check_rst_data(broken_rest) + assert len(msgs) == 1 + + # and non-broken rest + rest = 'title\n=====\n\ntest' + msgs = cmd._check_rst_data(rest) + assert len(msgs) == 0 + + def test_check_restructuredtext(self): + pytest.importorskip('docutils') + # let's see if it detects broken rest in long_description + broken_rest = 'title\n===\n\ntest' + pkg_info, dist = self.create_dist(long_description=broken_rest) + cmd = check(dist) + cmd.check_restructuredtext() + assert cmd._warnings == 1 + + # let's see if we have an error with strict=True + metadata = { + 'url': 'xxx', + 'author': 'xxx', + 'author_email': 'xxx', + 'name': 'xxx', + 'version': 'xxx', + 'long_description': broken_rest, + } + with pytest.raises(DistutilsSetupError): + self._run(metadata, **{'strict': 1, 'restructuredtext': 1}) + + # and non-broken rest, including a non-ASCII character to test #12114 + metadata['long_description'] = 'title\n=====\n\ntest \u00df' + cmd = self._run(metadata, strict=True, restructuredtext=True) + assert cmd._warnings == 0 + + # check that includes work to test #31292 + metadata['long_description'] = 'title\n=====\n\n.. include:: includetest.rst' + cmd = self._run(metadata, cwd=HERE, strict=True, restructuredtext=True) + assert cmd._warnings == 0 + + def test_check_restructuredtext_with_syntax_highlight(self): + pytest.importorskip('docutils') + # Don't fail if there is a `code` or `code-block` directive + + example_rst_docs = [ + textwrap.dedent( + """\ + Here's some code: + + .. code:: python + + def foo(): + pass + """ + ), + textwrap.dedent( + """\ + Here's some code: + + .. code-block:: python + + def foo(): + pass + """ + ), + ] + + for rest_with_code in example_rst_docs: + pkg_info, dist = self.create_dist(long_description=rest_with_code) + cmd = check(dist) + cmd.check_restructuredtext() + msgs = cmd._check_rst_data(rest_with_code) + if pygments is not None: + assert len(msgs) == 0 + else: + assert len(msgs) == 1 + assert ( + str(msgs[0][1]) + == 'Cannot analyze code. Pygments package not found.' + ) + + def test_check_all(self): + with pytest.raises(DistutilsSetupError): + self._run({}, **{'strict': 1, 'restructuredtext': 1}) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_clean.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_clean.py new file mode 100644 index 0000000000000000000000000000000000000000..cc78f30f34b323845b977b9147c2153390774bd3 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_clean.py @@ -0,0 +1,45 @@ +"""Tests for distutils.command.clean.""" + +import os +from distutils.command.clean import clean +from distutils.tests import support + + +class TestClean(support.TempdirManager): + def test_simple_run(self): + pkg_dir, dist = self.create_dist() + cmd = clean(dist) + + # let's add some elements clean should remove + dirs = [ + (d, os.path.join(pkg_dir, d)) + for d in ( + 'build_temp', + 'build_lib', + 'bdist_base', + 'build_scripts', + 'build_base', + ) + ] + + for name, path in dirs: + os.mkdir(path) + setattr(cmd, name, path) + if name == 'build_base': + continue + for f in ('one', 'two', 'three'): + self.write_file(os.path.join(path, f)) + + # let's run the command + cmd.all = 1 + cmd.ensure_finalized() + cmd.run() + + # make sure the files where removed + for _name, path in dirs: + assert not os.path.exists(path), f'{path} was not removed' + + # let's run the command again (should spit warnings but succeed) + cmd.all = 1 + cmd.ensure_finalized() + cmd.run() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_cmd.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_cmd.py new file mode 100644 index 0000000000000000000000000000000000000000..76e8f5989b3b102a32239436ff3b65f26e09e029 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_cmd.py @@ -0,0 +1,107 @@ +"""Tests for distutils.cmd.""" + +import os +from distutils import debug +from distutils.cmd import Command +from distutils.dist import Distribution +from distutils.errors import DistutilsOptionError + +import pytest + + +class MyCmd(Command): + def initialize_options(self): + pass + + +@pytest.fixture +def cmd(request): + return MyCmd(Distribution()) + + +class TestCommand: + def test_ensure_string_list(self, cmd): + cmd.not_string_list = ['one', 2, 'three'] + cmd.yes_string_list = ['one', 'two', 'three'] + cmd.not_string_list2 = object() + cmd.yes_string_list2 = 'ok' + cmd.ensure_string_list('yes_string_list') + cmd.ensure_string_list('yes_string_list2') + + with pytest.raises(DistutilsOptionError): + cmd.ensure_string_list('not_string_list') + + with pytest.raises(DistutilsOptionError): + cmd.ensure_string_list('not_string_list2') + + cmd.option1 = 'ok,dok' + cmd.ensure_string_list('option1') + assert cmd.option1 == ['ok', 'dok'] + + cmd.option2 = ['xxx', 'www'] + cmd.ensure_string_list('option2') + + cmd.option3 = ['ok', 2] + with pytest.raises(DistutilsOptionError): + cmd.ensure_string_list('option3') + + def test_make_file(self, cmd): + # making sure it raises when infiles is not a string or a list/tuple + with pytest.raises(TypeError): + cmd.make_file(infiles=True, outfile='', func='func', args=()) + + # making sure execute gets called properly + def _execute(func, args, exec_msg, level): + assert exec_msg == 'generating out from in' + + cmd.force = True + cmd.execute = _execute + cmd.make_file(infiles='in', outfile='out', func='func', args=()) + + def test_dump_options(self, cmd): + msgs = [] + + def _announce(msg, level): + msgs.append(msg) + + cmd.announce = _announce + cmd.option1 = 1 + cmd.option2 = 1 + cmd.user_options = [('option1', '', ''), ('option2', '', '')] + cmd.dump_options() + + wanted = ["command options for 'MyCmd':", ' option1 = 1', ' option2 = 1'] + assert msgs == wanted + + def test_ensure_string(self, cmd): + cmd.option1 = 'ok' + cmd.ensure_string('option1') + + cmd.option2 = None + cmd.ensure_string('option2', 'xxx') + assert hasattr(cmd, 'option2') + + cmd.option3 = 1 + with pytest.raises(DistutilsOptionError): + cmd.ensure_string('option3') + + def test_ensure_filename(self, cmd): + cmd.option1 = __file__ + cmd.ensure_filename('option1') + cmd.option2 = 'xxx' + with pytest.raises(DistutilsOptionError): + cmd.ensure_filename('option2') + + def test_ensure_dirname(self, cmd): + cmd.option1 = os.path.dirname(__file__) or os.curdir + cmd.ensure_dirname('option1') + cmd.option2 = 'xxx' + with pytest.raises(DistutilsOptionError): + cmd.ensure_dirname('option2') + + def test_debug_print(self, cmd, capsys, monkeypatch): + cmd.debug_print('xxx') + assert capsys.readouterr().out == '' + monkeypatch.setattr(debug, 'DEBUG', True) + cmd.debug_print('xxx') + assert capsys.readouterr().out == 'xxx\n' diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_config_cmd.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_config_cmd.py new file mode 100644 index 0000000000000000000000000000000000000000..ebee2ef93f0bc9d422984e2e4872665b1be3a1de --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_config_cmd.py @@ -0,0 +1,87 @@ +"""Tests for distutils.command.config.""" + +import os +import sys +from distutils._log import log +from distutils.command.config import config, dump_file +from distutils.tests import missing_compiler_executable, support + +import more_itertools +import path +import pytest + + +@pytest.fixture(autouse=True) +def info_log(request, monkeypatch): + self = request.instance + self._logs = [] + monkeypatch.setattr(log, 'info', self._info) + + +@support.combine_markers +class TestConfig(support.TempdirManager): + def _info(self, msg, *args): + for line in msg.splitlines(): + self._logs.append(line) + + def test_dump_file(self): + this_file = path.Path(__file__).with_suffix('.py') + with this_file.open(encoding='utf-8') as f: + numlines = more_itertools.ilen(f) + + dump_file(this_file, 'I am the header') + assert len(self._logs) == numlines + 1 + + @pytest.mark.skipif('platform.system() == "Windows"') + def test_search_cpp(self): + cmd = missing_compiler_executable(['preprocessor']) + if cmd is not None: + self.skipTest(f'The {cmd!r} command is not found') + pkg_dir, dist = self.create_dist() + cmd = config(dist) + cmd._check_compiler() + compiler = cmd.compiler + if sys.platform[:3] == "aix" and "xlc" in compiler.preprocessor[0].lower(): + self.skipTest( + 'xlc: The -E option overrides the -P, -o, and -qsyntaxonly options' + ) + + # simple pattern searches + match = cmd.search_cpp(pattern='xxx', body='/* xxx */') + assert match == 0 + + match = cmd.search_cpp(pattern='_configtest', body='/* xxx */') + assert match == 1 + + def test_finalize_options(self): + # finalize_options does a bit of transformation + # on options + pkg_dir, dist = self.create_dist() + cmd = config(dist) + cmd.include_dirs = f'one{os.pathsep}two' + cmd.libraries = 'one' + cmd.library_dirs = f'three{os.pathsep}four' + cmd.ensure_finalized() + + assert cmd.include_dirs == ['one', 'two'] + assert cmd.libraries == ['one'] + assert cmd.library_dirs == ['three', 'four'] + + def test_clean(self): + # _clean removes files + tmp_dir = self.mkdtemp() + f1 = os.path.join(tmp_dir, 'one') + f2 = os.path.join(tmp_dir, 'two') + + self.write_file(f1, 'xxx') + self.write_file(f2, 'xxx') + + for f in (f1, f2): + assert os.path.exists(f) + + pkg_dir, dist = self.create_dist() + cmd = config(dist) + cmd._clean(f1, f2) + + for f in (f1, f2): + assert not os.path.exists(f) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_core.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_core.py new file mode 100644 index 0000000000000000000000000000000000000000..bad3fb7e8318d3ee73ecabe20ed98c279f606a77 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_core.py @@ -0,0 +1,130 @@ +"""Tests for distutils.core.""" + +import distutils.core +import io +import os +import sys +from distutils.dist import Distribution + +import pytest + +# setup script that uses __file__ +setup_using___file__ = """\ + +__file__ + +from distutils.core import setup +setup() +""" + +setup_prints_cwd = """\ + +import os +print(os.getcwd()) + +from distutils.core import setup +setup() +""" + +setup_does_nothing = """\ +from distutils.core import setup +setup() +""" + + +setup_defines_subclass = """\ +from distutils.core import setup +from distutils.command.install import install as _install + +class install(_install): + sub_commands = _install.sub_commands + ['cmd'] + +setup(cmdclass={'install': install}) +""" + +setup_within_if_main = """\ +from distutils.core import setup + +def main(): + return setup(name="setup_within_if_main") + +if __name__ == "__main__": + main() +""" + + +@pytest.fixture(autouse=True) +def save_stdout(monkeypatch): + monkeypatch.setattr(sys, 'stdout', sys.stdout) + + +@pytest.fixture +def temp_file(tmp_path): + return tmp_path / 'file' + + +@pytest.mark.usefixtures('save_env') +@pytest.mark.usefixtures('save_argv') +class TestCore: + def test_run_setup_provides_file(self, temp_file): + # Make sure the script can use __file__; if that's missing, the test + # setup.py script will raise NameError. + temp_file.write_text(setup_using___file__, encoding='utf-8') + distutils.core.run_setup(temp_file) + + def test_run_setup_preserves_sys_argv(self, temp_file): + # Make sure run_setup does not clobber sys.argv + argv_copy = sys.argv.copy() + temp_file.write_text(setup_does_nothing, encoding='utf-8') + distutils.core.run_setup(temp_file) + assert sys.argv == argv_copy + + def test_run_setup_defines_subclass(self, temp_file): + # Make sure the script can use __file__; if that's missing, the test + # setup.py script will raise NameError. + temp_file.write_text(setup_defines_subclass, encoding='utf-8') + dist = distutils.core.run_setup(temp_file) + install = dist.get_command_obj('install') + assert 'cmd' in install.sub_commands + + def test_run_setup_uses_current_dir(self, tmp_path): + """ + Test that the setup script is run with the current directory + as its own current directory. + """ + sys.stdout = io.StringIO() + cwd = os.getcwd() + + # Create a directory and write the setup.py file there: + setup_py = tmp_path / 'setup.py' + setup_py.write_text(setup_prints_cwd, encoding='utf-8') + distutils.core.run_setup(setup_py) + + output = sys.stdout.getvalue() + if output.endswith("\n"): + output = output[:-1] + assert cwd == output + + def test_run_setup_within_if_main(self, temp_file): + temp_file.write_text(setup_within_if_main, encoding='utf-8') + dist = distutils.core.run_setup(temp_file, stop_after="config") + assert isinstance(dist, Distribution) + assert dist.get_name() == "setup_within_if_main" + + def test_run_commands(self, temp_file): + sys.argv = ['setup.py', 'build'] + temp_file.write_text(setup_within_if_main, encoding='utf-8') + dist = distutils.core.run_setup(temp_file, stop_after="commandline") + assert 'build' not in dist.have_run + distutils.core.run_commands(dist) + assert 'build' in dist.have_run + + def test_debug_mode(self, capsys, monkeypatch): + # this covers the code called when DEBUG is set + sys.argv = ['setup.py', '--name'] + distutils.core.setup(name='bar') + assert capsys.readouterr().out == 'bar\n' + monkeypatch.setattr(distutils.core, 'DEBUG', True) + distutils.core.setup(name='bar') + wanted = "options (after parsing config files):\n" + assert capsys.readouterr().out.startswith(wanted) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_dir_util.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_dir_util.py new file mode 100644 index 0000000000000000000000000000000000000000..326cb346145ec7e3a1dd0384c33d4125131feaae --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_dir_util.py @@ -0,0 +1,139 @@ +"""Tests for distutils.dir_util.""" + +import os +import pathlib +import stat +import sys +import unittest.mock as mock +from distutils import dir_util, errors +from distutils.dir_util import ( + copy_tree, + create_tree, + ensure_relative, + mkpath, + remove_tree, +) +from distutils.tests import support + +import jaraco.path +import path +import pytest + + +@pytest.fixture(autouse=True) +def stuff(request, monkeypatch, distutils_managed_tempdir): + self = request.instance + tmp_dir = self.mkdtemp() + self.root_target = os.path.join(tmp_dir, 'deep') + self.target = os.path.join(self.root_target, 'here') + self.target2 = os.path.join(tmp_dir, 'deep2') + + +class TestDirUtil(support.TempdirManager): + def test_mkpath_remove_tree_verbosity(self, caplog): + mkpath(self.target, verbose=False) + assert not caplog.records + remove_tree(self.root_target, verbose=False) + + mkpath(self.target, verbose=True) + wanted = [f'creating {self.target}'] + assert caplog.messages == wanted + caplog.clear() + + remove_tree(self.root_target, verbose=True) + wanted = [f"removing '{self.root_target}' (and everything under it)"] + assert caplog.messages == wanted + + @pytest.mark.skipif("platform.system() == 'Windows'") + def test_mkpath_with_custom_mode(self): + # Get and set the current umask value for testing mode bits. + umask = os.umask(0o002) + os.umask(umask) + mkpath(self.target, 0o700) + assert stat.S_IMODE(os.stat(self.target).st_mode) == 0o700 & ~umask + mkpath(self.target2, 0o555) + assert stat.S_IMODE(os.stat(self.target2).st_mode) == 0o555 & ~umask + + def test_create_tree_verbosity(self, caplog): + create_tree(self.root_target, ['one', 'two', 'three'], verbose=False) + assert caplog.messages == [] + remove_tree(self.root_target, verbose=False) + + wanted = [f'creating {self.root_target}'] + create_tree(self.root_target, ['one', 'two', 'three'], verbose=True) + assert caplog.messages == wanted + + remove_tree(self.root_target, verbose=False) + + def test_copy_tree_verbosity(self, caplog): + mkpath(self.target, verbose=False) + + copy_tree(self.target, self.target2, verbose=False) + assert caplog.messages == [] + + remove_tree(self.root_target, verbose=False) + + mkpath(self.target, verbose=False) + a_file = path.Path(self.target) / 'ok.txt' + jaraco.path.build({'ok.txt': 'some content'}, self.target) + + wanted = [f'copying {a_file} -> {self.target2}'] + copy_tree(self.target, self.target2, verbose=True) + assert caplog.messages == wanted + + remove_tree(self.root_target, verbose=False) + remove_tree(self.target2, verbose=False) + + def test_copy_tree_skips_nfs_temp_files(self): + mkpath(self.target, verbose=False) + + jaraco.path.build({'ok.txt': 'some content', '.nfs123abc': ''}, self.target) + + copy_tree(self.target, self.target2) + assert os.listdir(self.target2) == ['ok.txt'] + + remove_tree(self.root_target, verbose=False) + remove_tree(self.target2, verbose=False) + + def test_ensure_relative(self): + if os.sep == '/': + assert ensure_relative('/home/foo') == 'home/foo' + assert ensure_relative('some/path') == 'some/path' + else: # \\ + assert ensure_relative('c:\\home\\foo') == 'c:home\\foo' + assert ensure_relative('home\\foo') == 'home\\foo' + + def test_copy_tree_exception_in_listdir(self): + """ + An exception in listdir should raise a DistutilsFileError + """ + with ( + mock.patch("os.listdir", side_effect=OSError()), + pytest.raises(errors.DistutilsFileError), + ): + src = self.tempdirs[-1] + dir_util.copy_tree(src, None) + + def test_mkpath_exception_uncached(self, monkeypatch, tmp_path): + """ + Caching should not remember failed attempts. + + pypa/distutils#304 + """ + + class FailPath(pathlib.Path): + def mkdir(self, *args, **kwargs): + raise OSError("Failed to create directory") + + if sys.version_info < (3, 12): + _flavour = pathlib.Path()._flavour + + target = tmp_path / 'foodir' + + with pytest.raises(errors.DistutilsFileError): + mkpath(FailPath(target)) + + assert not target.exists() + + mkpath(target) + assert target.exists() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_dist.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_dist.py new file mode 100644 index 0000000000000000000000000000000000000000..2c5beebe64eb9d747088cf117082a546330b29f3 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_dist.py @@ -0,0 +1,552 @@ +"""Tests for distutils.dist.""" + +import email +import email.generator +import email.policy +import functools +import io +import os +import sys +import textwrap +import unittest.mock as mock +import warnings +from distutils.cmd import Command +from distutils.dist import Distribution, fix_help_options +from distutils.tests import support +from typing import ClassVar + +import jaraco.path +import pytest + +pydistutils_cfg = '.' * (os.name == 'posix') + 'pydistutils.cfg' + + +class test_dist(Command): + """Sample distutils extension command.""" + + user_options: ClassVar[list[tuple[str, str, str]]] = [ + ("sample-option=", "S", "help text"), + ] + + def initialize_options(self): + self.sample_option = None + + +class TestDistribution(Distribution): + """Distribution subclasses that avoids the default search for + configuration files. + + The ._config_files attribute must be set before + .parse_config_files() is called. + """ + + def find_config_files(self): + return self._config_files + + +@pytest.fixture +def clear_argv(): + del sys.argv[1:] + + +@support.combine_markers +@pytest.mark.usefixtures('save_env') +@pytest.mark.usefixtures('save_argv') +class TestDistributionBehavior(support.TempdirManager): + def create_distribution(self, configfiles=()): + d = TestDistribution() + d._config_files = configfiles + d.parse_config_files() + d.parse_command_line() + return d + + def test_command_packages_unspecified(self, clear_argv): + sys.argv.append("build") + d = self.create_distribution() + assert d.get_command_packages() == ["distutils.command"] + + def test_command_packages_cmdline(self, clear_argv): + from distutils.tests.test_dist import test_dist + + sys.argv.extend([ + "--command-packages", + "foo.bar,distutils.tests", + "test_dist", + "-Ssometext", + ]) + d = self.create_distribution() + # let's actually try to load our test command: + assert d.get_command_packages() == [ + "distutils.command", + "foo.bar", + "distutils.tests", + ] + cmd = d.get_command_obj("test_dist") + assert isinstance(cmd, test_dist) + assert cmd.sample_option == "sometext" + + @pytest.mark.skipif( + 'distutils' not in Distribution.parse_config_files.__module__, + reason='Cannot test when virtualenv has monkey-patched Distribution', + ) + def test_venv_install_options(self, tmp_path, clear_argv): + sys.argv.append("install") + file = str(tmp_path / 'file') + + fakepath = '/somedir' + + jaraco.path.build({ + file: f""" + [install] + install-base = {fakepath} + install-platbase = {fakepath} + install-lib = {fakepath} + install-platlib = {fakepath} + install-purelib = {fakepath} + install-headers = {fakepath} + install-scripts = {fakepath} + install-data = {fakepath} + prefix = {fakepath} + exec-prefix = {fakepath} + home = {fakepath} + user = {fakepath} + root = {fakepath} + """, + }) + + # Base case: Not in a Virtual Environment + with mock.patch.multiple(sys, prefix='/a', base_prefix='/a'): + d = self.create_distribution([file]) + + option_tuple = (file, fakepath) + + result_dict = { + 'install_base': option_tuple, + 'install_platbase': option_tuple, + 'install_lib': option_tuple, + 'install_platlib': option_tuple, + 'install_purelib': option_tuple, + 'install_headers': option_tuple, + 'install_scripts': option_tuple, + 'install_data': option_tuple, + 'prefix': option_tuple, + 'exec_prefix': option_tuple, + 'home': option_tuple, + 'user': option_tuple, + 'root': option_tuple, + } + + assert sorted(d.command_options.get('install').keys()) == sorted( + result_dict.keys() + ) + + for key, value in d.command_options.get('install').items(): + assert value == result_dict[key] + + # Test case: In a Virtual Environment + with mock.patch.multiple(sys, prefix='/a', base_prefix='/b'): + d = self.create_distribution([file]) + + for key in result_dict.keys(): + assert key not in d.command_options.get('install', {}) + + def test_command_packages_configfile(self, tmp_path, clear_argv): + sys.argv.append("build") + file = str(tmp_path / "file") + jaraco.path.build({ + file: """ + [global] + command_packages = foo.bar, splat + """, + }) + + d = self.create_distribution([file]) + assert d.get_command_packages() == ["distutils.command", "foo.bar", "splat"] + + # ensure command line overrides config: + sys.argv[1:] = ["--command-packages", "spork", "build"] + d = self.create_distribution([file]) + assert d.get_command_packages() == ["distutils.command", "spork"] + + # Setting --command-packages to '' should cause the default to + # be used even if a config file specified something else: + sys.argv[1:] = ["--command-packages", "", "build"] + d = self.create_distribution([file]) + assert d.get_command_packages() == ["distutils.command"] + + def test_empty_options(self, request): + # an empty options dictionary should not stay in the + # list of attributes + + # catching warnings + warns = [] + + def _warn(msg): + warns.append(msg) + + request.addfinalizer( + functools.partial(setattr, warnings, 'warn', warnings.warn) + ) + warnings.warn = _warn + dist = Distribution( + attrs={ + 'author': 'xxx', + 'name': 'xxx', + 'version': 'xxx', + 'url': 'xxxx', + 'options': {}, + } + ) + + assert len(warns) == 0 + assert 'options' not in dir(dist) + + def test_finalize_options(self): + attrs = {'keywords': 'one,two', 'platforms': 'one,two'} + + dist = Distribution(attrs=attrs) + dist.finalize_options() + + # finalize_option splits platforms and keywords + assert dist.metadata.platforms == ['one', 'two'] + assert dist.metadata.keywords == ['one', 'two'] + + attrs = {'keywords': 'foo bar', 'platforms': 'foo bar'} + dist = Distribution(attrs=attrs) + dist.finalize_options() + assert dist.metadata.platforms == ['foo bar'] + assert dist.metadata.keywords == ['foo bar'] + + def test_get_command_packages(self): + dist = Distribution() + assert dist.command_packages is None + cmds = dist.get_command_packages() + assert cmds == ['distutils.command'] + assert dist.command_packages == ['distutils.command'] + + dist.command_packages = 'one,two' + cmds = dist.get_command_packages() + assert cmds == ['distutils.command', 'one', 'two'] + + def test_announce(self): + # make sure the level is known + dist = Distribution() + with pytest.raises(TypeError): + dist.announce('ok', level='ok2') + + def test_find_config_files_disable(self, temp_home): + # Ticket #1180: Allow user to disable their home config file. + jaraco.path.build({pydistutils_cfg: '[distutils]\n'}, temp_home) + + d = Distribution() + all_files = d.find_config_files() + + d = Distribution(attrs={'script_args': ['--no-user-cfg']}) + files = d.find_config_files() + + # make sure --no-user-cfg disables the user cfg file + assert len(all_files) - 1 == len(files) + + def test_script_args_list_coercion(self): + d = Distribution(attrs={'script_args': ('build', '--no-user-cfg')}) + + # make sure script_args is a list even if it started as a different iterable + assert d.script_args == ['build', '--no-user-cfg'] + + @pytest.mark.skipif( + 'platform.system() == "Windows"', + reason='Windows does not honor chmod 000', + ) + def test_find_config_files_permission_error(self, fake_home): + """ + Finding config files should not fail when directory is inaccessible. + """ + fake_home.joinpath(pydistutils_cfg).write_text('', encoding='utf-8') + fake_home.chmod(0o000) + Distribution().find_config_files() + + +@pytest.mark.usefixtures('save_env') +@pytest.mark.usefixtures('save_argv') +class TestMetadata(support.TempdirManager): + def format_metadata(self, dist): + sio = io.StringIO() + dist.metadata.write_pkg_file(sio) + return sio.getvalue() + + def test_simple_metadata(self): + attrs = {"name": "package", "version": "1.0"} + dist = Distribution(attrs) + meta = self.format_metadata(dist) + assert "Metadata-Version: 1.0" in meta + assert "provides:" not in meta.lower() + assert "requires:" not in meta.lower() + assert "obsoletes:" not in meta.lower() + + def test_provides(self): + attrs = { + "name": "package", + "version": "1.0", + "provides": ["package", "package.sub"], + } + dist = Distribution(attrs) + assert dist.metadata.get_provides() == ["package", "package.sub"] + assert dist.get_provides() == ["package", "package.sub"] + meta = self.format_metadata(dist) + assert "Metadata-Version: 1.1" in meta + assert "requires:" not in meta.lower() + assert "obsoletes:" not in meta.lower() + + def test_provides_illegal(self): + with pytest.raises(ValueError): + Distribution( + {"name": "package", "version": "1.0", "provides": ["my.pkg (splat)"]}, + ) + + def test_requires(self): + attrs = { + "name": "package", + "version": "1.0", + "requires": ["other", "another (==1.0)"], + } + dist = Distribution(attrs) + assert dist.metadata.get_requires() == ["other", "another (==1.0)"] + assert dist.get_requires() == ["other", "another (==1.0)"] + meta = self.format_metadata(dist) + assert "Metadata-Version: 1.1" in meta + assert "provides:" not in meta.lower() + assert "Requires: other" in meta + assert "Requires: another (==1.0)" in meta + assert "obsoletes:" not in meta.lower() + + def test_requires_illegal(self): + with pytest.raises(ValueError): + Distribution( + {"name": "package", "version": "1.0", "requires": ["my.pkg (splat)"]}, + ) + + def test_requires_to_list(self): + attrs = {"name": "package", "requires": iter(["other"])} + dist = Distribution(attrs) + assert isinstance(dist.metadata.requires, list) + + def test_obsoletes(self): + attrs = { + "name": "package", + "version": "1.0", + "obsoletes": ["other", "another (<1.0)"], + } + dist = Distribution(attrs) + assert dist.metadata.get_obsoletes() == ["other", "another (<1.0)"] + assert dist.get_obsoletes() == ["other", "another (<1.0)"] + meta = self.format_metadata(dist) + assert "Metadata-Version: 1.1" in meta + assert "provides:" not in meta.lower() + assert "requires:" not in meta.lower() + assert "Obsoletes: other" in meta + assert "Obsoletes: another (<1.0)" in meta + + def test_obsoletes_illegal(self): + with pytest.raises(ValueError): + Distribution( + {"name": "package", "version": "1.0", "obsoletes": ["my.pkg (splat)"]}, + ) + + def test_obsoletes_to_list(self): + attrs = {"name": "package", "obsoletes": iter(["other"])} + dist = Distribution(attrs) + assert isinstance(dist.metadata.obsoletes, list) + + def test_classifier(self): + attrs = { + 'name': 'Boa', + 'version': '3.0', + 'classifiers': ['Programming Language :: Python :: 3'], + } + dist = Distribution(attrs) + assert dist.get_classifiers() == ['Programming Language :: Python :: 3'] + meta = self.format_metadata(dist) + assert 'Metadata-Version: 1.1' in meta + + def test_classifier_invalid_type(self, caplog): + attrs = { + 'name': 'Boa', + 'version': '3.0', + 'classifiers': ('Programming Language :: Python :: 3',), + } + d = Distribution(attrs) + # should have warning about passing a non-list + assert 'should be a list' in caplog.messages[0] + # should be converted to a list + assert isinstance(d.metadata.classifiers, list) + assert d.metadata.classifiers == list(attrs['classifiers']) + + def test_keywords(self): + attrs = { + 'name': 'Monty', + 'version': '1.0', + 'keywords': ['spam', 'eggs', 'life of brian'], + } + dist = Distribution(attrs) + assert dist.get_keywords() == ['spam', 'eggs', 'life of brian'] + + def test_keywords_invalid_type(self, caplog): + attrs = { + 'name': 'Monty', + 'version': '1.0', + 'keywords': ('spam', 'eggs', 'life of brian'), + } + d = Distribution(attrs) + # should have warning about passing a non-list + assert 'should be a list' in caplog.messages[0] + # should be converted to a list + assert isinstance(d.metadata.keywords, list) + assert d.metadata.keywords == list(attrs['keywords']) + + def test_platforms(self): + attrs = { + 'name': 'Monty', + 'version': '1.0', + 'platforms': ['GNU/Linux', 'Some Evil Platform'], + } + dist = Distribution(attrs) + assert dist.get_platforms() == ['GNU/Linux', 'Some Evil Platform'] + + def test_platforms_invalid_types(self, caplog): + attrs = { + 'name': 'Monty', + 'version': '1.0', + 'platforms': ('GNU/Linux', 'Some Evil Platform'), + } + d = Distribution(attrs) + # should have warning about passing a non-list + assert 'should be a list' in caplog.messages[0] + # should be converted to a list + assert isinstance(d.metadata.platforms, list) + assert d.metadata.platforms == list(attrs['platforms']) + + def test_download_url(self): + attrs = { + 'name': 'Boa', + 'version': '3.0', + 'download_url': 'http://example.org/boa', + } + dist = Distribution(attrs) + meta = self.format_metadata(dist) + assert 'Metadata-Version: 1.1' in meta + + def test_long_description(self): + long_desc = textwrap.dedent( + """\ + example:: + We start here + and continue here + and end here.""" + ) + attrs = {"name": "package", "version": "1.0", "long_description": long_desc} + + dist = Distribution(attrs) + meta = self.format_metadata(dist) + meta = meta.replace('\n' + 8 * ' ', '\n') + assert long_desc in meta + + def test_custom_pydistutils(self, temp_home): + """ + pydistutils.cfg is found + """ + jaraco.path.build({pydistutils_cfg: ''}, temp_home) + config_path = temp_home / pydistutils_cfg + + assert str(config_path) in Distribution().find_config_files() + + def test_extra_pydistutils(self, monkeypatch, tmp_path): + jaraco.path.build({'overrides.cfg': ''}, tmp_path) + filename = tmp_path / 'overrides.cfg' + monkeypatch.setenv('DIST_EXTRA_CONFIG', str(filename)) + assert str(filename) in Distribution().find_config_files() + + def test_fix_help_options(self): + help_tuples = [('a', 'b', 'c', 'd'), (1, 2, 3, 4)] + fancy_options = fix_help_options(help_tuples) + assert fancy_options[0] == ('a', 'b', 'c') + assert fancy_options[1] == (1, 2, 3) + + def test_show_help(self, request, capsys): + # smoke test, just makes sure some help is displayed + dist = Distribution() + sys.argv = [] + dist.help = True + dist.script_name = 'setup.py' + dist.parse_command_line() + + output = [ + line for line in capsys.readouterr().out.split('\n') if line.strip() != '' + ] + assert output + + def test_read_metadata(self): + attrs = { + "name": "package", + "version": "1.0", + "long_description": "desc", + "description": "xxx", + "download_url": "http://example.com", + "keywords": ['one', 'two'], + "requires": ['foo'], + } + + dist = Distribution(attrs) + metadata = dist.metadata + + # write it then reloads it + PKG_INFO = io.StringIO() + metadata.write_pkg_file(PKG_INFO) + PKG_INFO.seek(0) + metadata.read_pkg_file(PKG_INFO) + + assert metadata.name == "package" + assert metadata.version == "1.0" + assert metadata.description == "xxx" + assert metadata.download_url == 'http://example.com' + assert metadata.keywords == ['one', 'two'] + assert metadata.platforms is None + assert metadata.obsoletes is None + assert metadata.requires == ['foo'] + + def test_round_trip_through_email_generator(self): + """ + In pypa/setuptools#4033, it was shown that once PKG-INFO is + re-generated using ``email.generator.Generator``, some control + characters might cause problems. + """ + # Given a PKG-INFO file ... + attrs = { + "name": "package", + "version": "1.0", + "long_description": "hello\x0b\nworld\n", + } + dist = Distribution(attrs) + metadata = dist.metadata + + with io.StringIO() as buffer: + metadata.write_pkg_file(buffer) + msg = buffer.getvalue() + + # ... when it is read and re-written using stdlib's email library, + orig = email.message_from_string(msg) + policy = email.policy.EmailPolicy( + utf8=True, + mangle_from_=False, + max_line_length=0, + ) + with io.StringIO() as buffer: + email.generator.Generator(buffer, policy=policy).flatten(orig) + + buffer.seek(0) + regen = email.message_from_file(buffer) + + # ... then it should be the same as the original + # (except for the specific line break characters) + orig_desc = set(orig["Description"].splitlines()) + regen_desc = set(regen["Description"].splitlines()) + assert regen_desc == orig_desc diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_extension.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_extension.py new file mode 100644 index 0000000000000000000000000000000000000000..5e8e768223ea40d7a629111db181a946cf8ca5b0 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_extension.py @@ -0,0 +1,117 @@ +"""Tests for distutils.extension.""" + +import os +import pathlib +import warnings +from distutils.extension import Extension, read_setup_file + +import pytest +from test.support.warnings_helper import check_warnings + + +class TestExtension: + def test_read_setup_file(self): + # trying to read a Setup file + # (sample extracted from the PyGame project) + setup = os.path.join(os.path.dirname(__file__), 'Setup.sample') + + exts = read_setup_file(setup) + names = [ext.name for ext in exts] + names.sort() + + # here are the extensions read_setup_file should have created + # out of the file + wanted = [ + '_arraysurfarray', + '_camera', + '_numericsndarray', + '_numericsurfarray', + 'base', + 'bufferproxy', + 'cdrom', + 'color', + 'constants', + 'display', + 'draw', + 'event', + 'fastevent', + 'font', + 'gfxdraw', + 'image', + 'imageext', + 'joystick', + 'key', + 'mask', + 'mixer', + 'mixer_music', + 'mouse', + 'movie', + 'overlay', + 'pixelarray', + 'pypm', + 'rect', + 'rwobject', + 'scrap', + 'surface', + 'surflock', + 'time', + 'transform', + ] + + assert names == wanted + + def test_extension_init(self): + # the first argument, which is the name, must be a string + with pytest.raises(TypeError): + Extension(1, []) + ext = Extension('name', []) + assert ext.name == 'name' + + # the second argument, which is the list of files, must + # be an iterable of strings or PathLike objects, and not a string + with pytest.raises(TypeError): + Extension('name', 'file') + with pytest.raises(TypeError): + Extension('name', ['file', 1]) + ext = Extension('name', ['file1', 'file2']) + assert ext.sources == ['file1', 'file2'] + ext = Extension('name', [pathlib.Path('file1'), pathlib.Path('file2')]) + assert ext.sources == ['file1', 'file2'] + + # any non-string iterable of strings or PathLike objects should work + ext = Extension('name', ('file1', 'file2')) # tuple + assert ext.sources == ['file1', 'file2'] + ext = Extension('name', {'file1', 'file2'}) # set + assert sorted(ext.sources) == ['file1', 'file2'] + ext = Extension('name', iter(['file1', 'file2'])) # iterator + assert ext.sources == ['file1', 'file2'] + ext = Extension('name', [pathlib.Path('file1'), 'file2']) # mixed types + assert ext.sources == ['file1', 'file2'] + + # others arguments have defaults + for attr in ( + 'include_dirs', + 'define_macros', + 'undef_macros', + 'library_dirs', + 'libraries', + 'runtime_library_dirs', + 'extra_objects', + 'extra_compile_args', + 'extra_link_args', + 'export_symbols', + 'swig_opts', + 'depends', + ): + assert getattr(ext, attr) == [] + + assert ext.language is None + assert ext.optional is None + + # if there are unknown keyword options, warn about them + with check_warnings() as w: + warnings.simplefilter('always') + ext = Extension('name', ['file1', 'file2'], chic=True) + + assert len(w.warnings) == 1 + assert str(w.warnings[0].message) == "Unknown Extension options: 'chic'" diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_file_util.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_file_util.py new file mode 100644 index 0000000000000000000000000000000000000000..a75d4a0317dc717c24f67127370aa87089eeba1a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_file_util.py @@ -0,0 +1,95 @@ +"""Tests for distutils.file_util.""" + +import errno +import os +import unittest.mock as mock +from distutils.errors import DistutilsFileError +from distutils.file_util import copy_file, move_file + +import jaraco.path +import pytest + + +@pytest.fixture(autouse=True) +def stuff(request, tmp_path): + self = request.instance + self.source = tmp_path / 'f1' + self.target = tmp_path / 'f2' + self.target_dir = tmp_path / 'd1' + + +class TestFileUtil: + def test_move_file_verbosity(self, caplog): + jaraco.path.build({self.source: 'some content'}) + + move_file(self.source, self.target, verbose=False) + assert not caplog.messages + + # back to original state + move_file(self.target, self.source, verbose=False) + + move_file(self.source, self.target, verbose=True) + wanted = [f'moving {self.source} -> {self.target}'] + assert caplog.messages == wanted + + # back to original state + move_file(self.target, self.source, verbose=False) + + caplog.clear() + # now the target is a dir + os.mkdir(self.target_dir) + move_file(self.source, self.target_dir, verbose=True) + wanted = [f'moving {self.source} -> {self.target_dir}'] + assert caplog.messages == wanted + + def test_move_file_exception_unpacking_rename(self): + # see issue 22182 + with ( + mock.patch("os.rename", side_effect=OSError("wrong", 1)), + pytest.raises(DistutilsFileError), + ): + jaraco.path.build({self.source: 'spam eggs'}) + move_file(self.source, self.target, verbose=False) + + def test_move_file_exception_unpacking_unlink(self): + # see issue 22182 + with ( + mock.patch("os.rename", side_effect=OSError(errno.EXDEV, "wrong")), + mock.patch("os.unlink", side_effect=OSError("wrong", 1)), + pytest.raises(DistutilsFileError), + ): + jaraco.path.build({self.source: 'spam eggs'}) + move_file(self.source, self.target, verbose=False) + + def test_copy_file_hard_link(self): + jaraco.path.build({self.source: 'some content'}) + # Check first that copy_file() will not fall back on copying the file + # instead of creating the hard link. + try: + os.link(self.source, self.target) + except OSError as e: + self.skipTest(f'os.link: {e}') + else: + self.target.unlink() + st = os.stat(self.source) + copy_file(self.source, self.target, link='hard') + st2 = os.stat(self.source) + st3 = os.stat(self.target) + assert os.path.samestat(st, st2), (st, st2) + assert os.path.samestat(st2, st3), (st2, st3) + assert self.source.read_text(encoding='utf-8') == 'some content' + + def test_copy_file_hard_link_failure(self): + # If hard linking fails, copy_file() falls back on copying file + # (some special filesystems don't support hard linking even under + # Unix, see issue #8876). + jaraco.path.build({self.source: 'some content'}) + st = os.stat(self.source) + with mock.patch("os.link", side_effect=OSError(0, "linking unsupported")): + copy_file(self.source, self.target, link='hard') + st2 = os.stat(self.source) + st3 = os.stat(self.target) + assert os.path.samestat(st, st2), (st, st2) + assert not os.path.samestat(st2, st3), (st2, st3) + for fn in (self.source, self.target): + assert fn.read_text(encoding='utf-8') == 'some content' diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_filelist.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_filelist.py new file mode 100644 index 0000000000000000000000000000000000000000..130e6fb53b0bd9670bdcfe6d4bc7fcf8fd90416e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_filelist.py @@ -0,0 +1,336 @@ +"""Tests for distutils.filelist.""" + +import logging +import os +import re +from distutils import debug, filelist +from distutils.errors import DistutilsTemplateError +from distutils.filelist import FileList, glob_to_re, translate_pattern + +import jaraco.path +import pytest + +from .compat import py39 as os_helper + +MANIFEST_IN = """\ +include ok +include xo +exclude xo +include foo.tmp +include buildout.cfg +global-include *.x +global-include *.txt +global-exclude *.tmp +recursive-include f *.oo +recursive-exclude global *.x +graft dir +prune dir3 +""" + + +def make_local_path(s): + """Converts '/' in a string to os.sep""" + return s.replace('/', os.sep) + + +class TestFileList: + def assertNoWarnings(self, caplog): + warnings = [rec for rec in caplog.records if rec.levelno == logging.WARNING] + assert not warnings + caplog.clear() + + def assertWarnings(self, caplog): + warnings = [rec for rec in caplog.records if rec.levelno == logging.WARNING] + assert warnings + caplog.clear() + + def test_glob_to_re(self): + sep = os.sep + if os.sep == '\\': + sep = re.escape(os.sep) + + for glob, regex in ( + # simple cases + ('foo*', r'(?s:foo[^%(sep)s]*)\Z'), + ('foo?', r'(?s:foo[^%(sep)s])\Z'), + ('foo??', r'(?s:foo[^%(sep)s][^%(sep)s])\Z'), + # special cases + (r'foo\\*', r'(?s:foo\\\\[^%(sep)s]*)\Z'), + (r'foo\\\*', r'(?s:foo\\\\\\[^%(sep)s]*)\Z'), + ('foo????', r'(?s:foo[^%(sep)s][^%(sep)s][^%(sep)s][^%(sep)s])\Z'), + (r'foo\\??', r'(?s:foo\\\\[^%(sep)s][^%(sep)s])\Z'), + ): + regex = regex % {'sep': sep} + assert glob_to_re(glob) == regex + + def test_process_template_line(self): + # testing all MANIFEST.in template patterns + file_list = FileList() + mlp = make_local_path + + # simulated file list + file_list.allfiles = [ + 'foo.tmp', + 'ok', + 'xo', + 'four.txt', + 'buildout.cfg', + # filelist does not filter out VCS directories, + # it's sdist that does + mlp('.hg/last-message.txt'), + mlp('global/one.txt'), + mlp('global/two.txt'), + mlp('global/files.x'), + mlp('global/here.tmp'), + mlp('f/o/f.oo'), + mlp('dir/graft-one'), + mlp('dir/dir2/graft2'), + mlp('dir3/ok'), + mlp('dir3/sub/ok.txt'), + ] + + for line in MANIFEST_IN.split('\n'): + if line.strip() == '': + continue + file_list.process_template_line(line) + + wanted = [ + 'ok', + 'buildout.cfg', + 'four.txt', + mlp('.hg/last-message.txt'), + mlp('global/one.txt'), + mlp('global/two.txt'), + mlp('f/o/f.oo'), + mlp('dir/graft-one'), + mlp('dir/dir2/graft2'), + ] + + assert file_list.files == wanted + + def test_debug_print(self, capsys, monkeypatch): + file_list = FileList() + file_list.debug_print('xxx') + assert capsys.readouterr().out == '' + + monkeypatch.setattr(debug, 'DEBUG', True) + file_list.debug_print('xxx') + assert capsys.readouterr().out == 'xxx\n' + + def test_set_allfiles(self): + file_list = FileList() + files = ['a', 'b', 'c'] + file_list.set_allfiles(files) + assert file_list.allfiles == files + + def test_remove_duplicates(self): + file_list = FileList() + file_list.files = ['a', 'b', 'a', 'g', 'c', 'g'] + # files must be sorted beforehand (sdist does it) + file_list.sort() + file_list.remove_duplicates() + assert file_list.files == ['a', 'b', 'c', 'g'] + + def test_translate_pattern(self): + # not regex + assert hasattr(translate_pattern('a', anchor=True, is_regex=False), 'search') + + # is a regex + regex = re.compile('a') + assert translate_pattern(regex, anchor=True, is_regex=True) == regex + + # plain string flagged as regex + assert hasattr(translate_pattern('a', anchor=True, is_regex=True), 'search') + + # glob support + assert translate_pattern('*.py', anchor=True, is_regex=False).search( + 'filelist.py' + ) + + def test_exclude_pattern(self): + # return False if no match + file_list = FileList() + assert not file_list.exclude_pattern('*.py') + + # return True if files match + file_list = FileList() + file_list.files = ['a.py', 'b.py'] + assert file_list.exclude_pattern('*.py') + + # test excludes + file_list = FileList() + file_list.files = ['a.py', 'a.txt'] + file_list.exclude_pattern('*.py') + assert file_list.files == ['a.txt'] + + def test_include_pattern(self): + # return False if no match + file_list = FileList() + file_list.set_allfiles([]) + assert not file_list.include_pattern('*.py') + + # return True if files match + file_list = FileList() + file_list.set_allfiles(['a.py', 'b.txt']) + assert file_list.include_pattern('*.py') + + # test * matches all files + file_list = FileList() + assert file_list.allfiles is None + file_list.set_allfiles(['a.py', 'b.txt']) + file_list.include_pattern('*') + assert file_list.allfiles == ['a.py', 'b.txt'] + + def test_process_template(self, caplog): + mlp = make_local_path + # invalid lines + file_list = FileList() + for action in ( + 'include', + 'exclude', + 'global-include', + 'global-exclude', + 'recursive-include', + 'recursive-exclude', + 'graft', + 'prune', + 'blarg', + ): + with pytest.raises(DistutilsTemplateError): + file_list.process_template_line(action) + + # include + file_list = FileList() + file_list.set_allfiles(['a.py', 'b.txt', mlp('d/c.py')]) + + file_list.process_template_line('include *.py') + assert file_list.files == ['a.py'] + self.assertNoWarnings(caplog) + + file_list.process_template_line('include *.rb') + assert file_list.files == ['a.py'] + self.assertWarnings(caplog) + + # exclude + file_list = FileList() + file_list.files = ['a.py', 'b.txt', mlp('d/c.py')] + + file_list.process_template_line('exclude *.py') + assert file_list.files == ['b.txt', mlp('d/c.py')] + self.assertNoWarnings(caplog) + + file_list.process_template_line('exclude *.rb') + assert file_list.files == ['b.txt', mlp('d/c.py')] + self.assertWarnings(caplog) + + # global-include + file_list = FileList() + file_list.set_allfiles(['a.py', 'b.txt', mlp('d/c.py')]) + + file_list.process_template_line('global-include *.py') + assert file_list.files == ['a.py', mlp('d/c.py')] + self.assertNoWarnings(caplog) + + file_list.process_template_line('global-include *.rb') + assert file_list.files == ['a.py', mlp('d/c.py')] + self.assertWarnings(caplog) + + # global-exclude + file_list = FileList() + file_list.files = ['a.py', 'b.txt', mlp('d/c.py')] + + file_list.process_template_line('global-exclude *.py') + assert file_list.files == ['b.txt'] + self.assertNoWarnings(caplog) + + file_list.process_template_line('global-exclude *.rb') + assert file_list.files == ['b.txt'] + self.assertWarnings(caplog) + + # recursive-include + file_list = FileList() + file_list.set_allfiles(['a.py', mlp('d/b.py'), mlp('d/c.txt'), mlp('d/d/e.py')]) + + file_list.process_template_line('recursive-include d *.py') + assert file_list.files == [mlp('d/b.py'), mlp('d/d/e.py')] + self.assertNoWarnings(caplog) + + file_list.process_template_line('recursive-include e *.py') + assert file_list.files == [mlp('d/b.py'), mlp('d/d/e.py')] + self.assertWarnings(caplog) + + # recursive-exclude + file_list = FileList() + file_list.files = ['a.py', mlp('d/b.py'), mlp('d/c.txt'), mlp('d/d/e.py')] + + file_list.process_template_line('recursive-exclude d *.py') + assert file_list.files == ['a.py', mlp('d/c.txt')] + self.assertNoWarnings(caplog) + + file_list.process_template_line('recursive-exclude e *.py') + assert file_list.files == ['a.py', mlp('d/c.txt')] + self.assertWarnings(caplog) + + # graft + file_list = FileList() + file_list.set_allfiles(['a.py', mlp('d/b.py'), mlp('d/d/e.py'), mlp('f/f.py')]) + + file_list.process_template_line('graft d') + assert file_list.files == [mlp('d/b.py'), mlp('d/d/e.py')] + self.assertNoWarnings(caplog) + + file_list.process_template_line('graft e') + assert file_list.files == [mlp('d/b.py'), mlp('d/d/e.py')] + self.assertWarnings(caplog) + + # prune + file_list = FileList() + file_list.files = ['a.py', mlp('d/b.py'), mlp('d/d/e.py'), mlp('f/f.py')] + + file_list.process_template_line('prune d') + assert file_list.files == ['a.py', mlp('f/f.py')] + self.assertNoWarnings(caplog) + + file_list.process_template_line('prune e') + assert file_list.files == ['a.py', mlp('f/f.py')] + self.assertWarnings(caplog) + + +class TestFindAll: + @os_helper.skip_unless_symlink + def test_missing_symlink(self, temp_cwd): + os.symlink('foo', 'bar') + assert filelist.findall() == [] + + def test_basic_discovery(self, temp_cwd): + """ + When findall is called with no parameters or with + '.' as the parameter, the dot should be omitted from + the results. + """ + jaraco.path.build({'foo': {'file1.txt': ''}, 'bar': {'file2.txt': ''}}) + file1 = os.path.join('foo', 'file1.txt') + file2 = os.path.join('bar', 'file2.txt') + expected = [file2, file1] + assert sorted(filelist.findall()) == expected + + def test_non_local_discovery(self, tmp_path): + """ + When findall is called with another path, the full + path name should be returned. + """ + jaraco.path.build({'file1.txt': ''}, tmp_path) + expected = [str(tmp_path / 'file1.txt')] + assert filelist.findall(tmp_path) == expected + + @os_helper.skip_unless_symlink + def test_symlink_loop(self, tmp_path): + jaraco.path.build( + { + 'link-to-parent': jaraco.path.Symlink('.'), + 'somefile': '', + }, + tmp_path, + ) + files = filelist.findall(tmp_path) + assert len(files) == 1 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_install.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_install.py new file mode 100644 index 0000000000000000000000000000000000000000..b3ffb2e668ac5a042c5a2889d7b51b5755b73157 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_install.py @@ -0,0 +1,245 @@ +"""Tests for distutils.command.install.""" + +import logging +import os +import pathlib +import site +import sys +from distutils import sysconfig +from distutils.command import install as install_module +from distutils.command.build_ext import build_ext +from distutils.command.install import INSTALL_SCHEMES, install +from distutils.core import Distribution +from distutils.errors import DistutilsOptionError +from distutils.extension import Extension +from distutils.tests import missing_compiler_executable, support +from distutils.util import is_mingw + +import pytest + + +def _make_ext_name(modname): + return modname + sysconfig.get_config_var('EXT_SUFFIX') + + +@support.combine_markers +@pytest.mark.usefixtures('save_env') +class TestInstall( + support.TempdirManager, +): + @pytest.mark.xfail( + 'platform.system() == "Windows" and sys.version_info > (3, 11)', + reason="pypa/distutils#148", + ) + def test_home_installation_scheme(self): + # This ensure two things: + # - that --home generates the desired set of directory names + # - test --home is supported on all platforms + builddir = self.mkdtemp() + destination = os.path.join(builddir, "installation") + + dist = Distribution({"name": "foopkg"}) + # script_name need not exist, it just need to be initialized + dist.script_name = os.path.join(builddir, "setup.py") + dist.command_obj["build"] = support.DummyCommand( + build_base=builddir, + build_lib=os.path.join(builddir, "lib"), + ) + + cmd = install(dist) + cmd.home = destination + cmd.ensure_finalized() + + assert cmd.install_base == destination + assert cmd.install_platbase == destination + + def check_path(got, expected): + got = os.path.normpath(got) + expected = os.path.normpath(expected) + assert got == expected + + impl_name = sys.implementation.name.replace("cpython", "python") + libdir = os.path.join(destination, "lib", impl_name) + check_path(cmd.install_lib, libdir) + _platlibdir = getattr(sys, "platlibdir", "lib") + platlibdir = os.path.join(destination, _platlibdir, impl_name) + check_path(cmd.install_platlib, platlibdir) + check_path(cmd.install_purelib, libdir) + check_path( + cmd.install_headers, + os.path.join(destination, "include", impl_name, "foopkg"), + ) + check_path(cmd.install_scripts, os.path.join(destination, "bin")) + check_path(cmd.install_data, destination) + + def test_user_site(self, monkeypatch): + # test install with --user + # preparing the environment for the test + self.tmpdir = self.mkdtemp() + orig_site = site.USER_SITE + orig_base = site.USER_BASE + monkeypatch.setattr(site, 'USER_BASE', os.path.join(self.tmpdir, 'B')) + monkeypatch.setattr(site, 'USER_SITE', os.path.join(self.tmpdir, 'S')) + monkeypatch.setattr(install_module, 'USER_BASE', site.USER_BASE) + monkeypatch.setattr(install_module, 'USER_SITE', site.USER_SITE) + + def _expanduser(path): + if path.startswith('~'): + return os.path.normpath(self.tmpdir + path[1:]) + return path + + monkeypatch.setattr(os.path, 'expanduser', _expanduser) + + for key in ('nt_user', 'posix_user'): + assert key in INSTALL_SCHEMES + + dist = Distribution({'name': 'xx'}) + cmd = install(dist) + + # making sure the user option is there + options = [name for name, short, label in cmd.user_options] + assert 'user' in options + + # setting a value + cmd.user = True + + # user base and site shouldn't be created yet + assert not os.path.exists(site.USER_BASE) + assert not os.path.exists(site.USER_SITE) + + # let's run finalize + cmd.ensure_finalized() + + # now they should + assert os.path.exists(site.USER_BASE) + assert os.path.exists(site.USER_SITE) + + assert 'userbase' in cmd.config_vars + assert 'usersite' in cmd.config_vars + + actual_headers = os.path.relpath(cmd.install_headers, site.USER_BASE) + if os.name == 'nt' and not is_mingw(): + site_path = os.path.relpath(os.path.dirname(orig_site), orig_base) + include = os.path.join(site_path, 'Include') + else: + include = sysconfig.get_python_inc(0, '') + expect_headers = os.path.join(include, 'xx') + + assert os.path.normcase(actual_headers) == os.path.normcase(expect_headers) + + def test_handle_extra_path(self): + dist = Distribution({'name': 'xx', 'extra_path': 'path,dirs'}) + cmd = install(dist) + + # two elements + cmd.handle_extra_path() + assert cmd.extra_path == ['path', 'dirs'] + assert cmd.extra_dirs == 'dirs' + assert cmd.path_file == 'path' + + # one element + cmd.extra_path = ['path'] + cmd.handle_extra_path() + assert cmd.extra_path == ['path'] + assert cmd.extra_dirs == 'path' + assert cmd.path_file == 'path' + + # none + dist.extra_path = cmd.extra_path = None + cmd.handle_extra_path() + assert cmd.extra_path is None + assert cmd.extra_dirs == '' + assert cmd.path_file is None + + # three elements (no way !) + cmd.extra_path = 'path,dirs,again' + with pytest.raises(DistutilsOptionError): + cmd.handle_extra_path() + + def test_finalize_options(self): + dist = Distribution({'name': 'xx'}) + cmd = install(dist) + + # must supply either prefix/exec-prefix/home or + # install-base/install-platbase -- not both + cmd.prefix = 'prefix' + cmd.install_base = 'base' + with pytest.raises(DistutilsOptionError): + cmd.finalize_options() + + # must supply either home or prefix/exec-prefix -- not both + cmd.install_base = None + cmd.home = 'home' + with pytest.raises(DistutilsOptionError): + cmd.finalize_options() + + # can't combine user with prefix/exec_prefix/home or + # install_(plat)base + cmd.prefix = None + cmd.user = 'user' + with pytest.raises(DistutilsOptionError): + cmd.finalize_options() + + def test_record(self): + install_dir = self.mkdtemp() + project_dir, dist = self.create_dist(py_modules=['hello'], scripts=['sayhi']) + os.chdir(project_dir) + self.write_file('hello.py', "def main(): print('o hai')") + self.write_file('sayhi', 'from hello import main; main()') + + cmd = install(dist) + dist.command_obj['install'] = cmd + cmd.root = install_dir + cmd.record = os.path.join(project_dir, 'filelist') + cmd.ensure_finalized() + cmd.run() + + content = pathlib.Path(cmd.record).read_text(encoding='utf-8') + + found = [pathlib.Path(line).name for line in content.splitlines()] + expected = [ + 'hello.py', + f'hello.{sys.implementation.cache_tag}.pyc', + 'sayhi', + 'UNKNOWN-0.0.0-py{}.{}.egg-info'.format(*sys.version_info[:2]), + ] + assert found == expected + + def test_record_extensions(self): + cmd = missing_compiler_executable() + if cmd is not None: + pytest.skip(f'The {cmd!r} command is not found') + install_dir = self.mkdtemp() + project_dir, dist = self.create_dist( + ext_modules=[Extension('xx', ['xxmodule.c'])] + ) + os.chdir(project_dir) + support.copy_xxmodule_c(project_dir) + + buildextcmd = build_ext(dist) + support.fixup_build_ext(buildextcmd) + buildextcmd.ensure_finalized() + + cmd = install(dist) + dist.command_obj['install'] = cmd + dist.command_obj['build_ext'] = buildextcmd + cmd.root = install_dir + cmd.record = os.path.join(project_dir, 'filelist') + cmd.ensure_finalized() + cmd.run() + + content = pathlib.Path(cmd.record).read_text(encoding='utf-8') + + found = [pathlib.Path(line).name for line in content.splitlines()] + expected = [ + _make_ext_name('xx'), + 'UNKNOWN-0.0.0-py{}.{}.egg-info'.format(*sys.version_info[:2]), + ] + assert found == expected + + def test_debug_mode(self, caplog, monkeypatch): + # this covers the code called when DEBUG is set + monkeypatch.setattr(install_module, 'DEBUG', True) + caplog.set_level(logging.DEBUG) + self.test_record() + assert any(rec for rec in caplog.records if rec.levelno == logging.DEBUG) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_install_data.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_install_data.py new file mode 100644 index 0000000000000000000000000000000000000000..c800f86c645d86fcb11aa3bef1513325ef163132 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_install_data.py @@ -0,0 +1,74 @@ +"""Tests for distutils.command.install_data.""" + +import os +import pathlib +from distutils.command.install_data import install_data +from distutils.tests import support + +import pytest + + +@pytest.mark.usefixtures('save_env') +class TestInstallData( + support.TempdirManager, +): + def test_simple_run(self): + pkg_dir, dist = self.create_dist() + cmd = install_data(dist) + cmd.install_dir = inst = os.path.join(pkg_dir, 'inst') + + # data_files can contain + # - simple files + # - a Path object + # - a tuple with a path, and a list of file + one = os.path.join(pkg_dir, 'one') + self.write_file(one, 'xxx') + inst2 = os.path.join(pkg_dir, 'inst2') + two = os.path.join(pkg_dir, 'two') + self.write_file(two, 'xxx') + three = pathlib.Path(pkg_dir) / 'three' + self.write_file(three, 'xxx') + + cmd.data_files = [one, (inst2, [two]), three] + assert cmd.get_inputs() == [one, (inst2, [two]), three] + + # let's run the command + cmd.ensure_finalized() + cmd.run() + + # let's check the result + assert len(cmd.get_outputs()) == 3 + rthree = os.path.split(one)[-1] + assert os.path.exists(os.path.join(inst, rthree)) + rtwo = os.path.split(two)[-1] + assert os.path.exists(os.path.join(inst2, rtwo)) + rone = os.path.split(one)[-1] + assert os.path.exists(os.path.join(inst, rone)) + cmd.outfiles = [] + + # let's try with warn_dir one + cmd.warn_dir = True + cmd.ensure_finalized() + cmd.run() + + # let's check the result + assert len(cmd.get_outputs()) == 3 + assert os.path.exists(os.path.join(inst, rthree)) + assert os.path.exists(os.path.join(inst2, rtwo)) + assert os.path.exists(os.path.join(inst, rone)) + cmd.outfiles = [] + + # now using root and empty dir + cmd.root = os.path.join(pkg_dir, 'root') + inst5 = os.path.join(pkg_dir, 'inst5') + four = os.path.join(cmd.install_dir, 'four') + self.write_file(four, 'xx') + cmd.data_files = [one, (inst2, [two]), three, ('inst5', [four]), (inst5, [])] + cmd.ensure_finalized() + cmd.run() + + # let's check the result + assert len(cmd.get_outputs()) == 5 + assert os.path.exists(os.path.join(inst, rthree)) + assert os.path.exists(os.path.join(inst2, rtwo)) + assert os.path.exists(os.path.join(inst, rone)) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_install_headers.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_install_headers.py new file mode 100644 index 0000000000000000000000000000000000000000..2c74f06b976f3c3ea977667a5c16c0e7f201a558 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_install_headers.py @@ -0,0 +1,33 @@ +"""Tests for distutils.command.install_headers.""" + +import os +from distutils.command.install_headers import install_headers +from distutils.tests import support + +import pytest + + +@pytest.mark.usefixtures('save_env') +class TestInstallHeaders( + support.TempdirManager, +): + def test_simple_run(self): + # we have two headers + header_list = self.mkdtemp() + header1 = os.path.join(header_list, 'header1') + header2 = os.path.join(header_list, 'header2') + self.write_file(header1) + self.write_file(header2) + headers = [header1, header2] + + pkg_dir, dist = self.create_dist(headers=headers) + cmd = install_headers(dist) + assert cmd.get_inputs() == headers + + # let's run the command + cmd.install_dir = os.path.join(pkg_dir, 'inst') + cmd.ensure_finalized() + cmd.run() + + # let's check the results + assert len(cmd.get_outputs()) == 2 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_install_lib.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_install_lib.py new file mode 100644 index 0000000000000000000000000000000000000000..f685a579560ea70bceea221de0e54485975ce180 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_install_lib.py @@ -0,0 +1,110 @@ +"""Tests for distutils.command.install_data.""" + +import importlib.util +import os +import sys +from distutils.command.install_lib import install_lib +from distutils.errors import DistutilsOptionError +from distutils.extension import Extension +from distutils.tests import support + +import pytest + + +@support.combine_markers +@pytest.mark.usefixtures('save_env') +class TestInstallLib( + support.TempdirManager, +): + def test_finalize_options(self): + dist = self.create_dist()[1] + cmd = install_lib(dist) + + cmd.finalize_options() + assert cmd.compile == 1 + assert cmd.optimize == 0 + + # optimize must be 0, 1, or 2 + cmd.optimize = 'foo' + with pytest.raises(DistutilsOptionError): + cmd.finalize_options() + cmd.optimize = '4' + with pytest.raises(DistutilsOptionError): + cmd.finalize_options() + + cmd.optimize = '2' + cmd.finalize_options() + assert cmd.optimize == 2 + + @pytest.mark.skipif('sys.dont_write_bytecode') + def test_byte_compile(self): + project_dir, dist = self.create_dist() + os.chdir(project_dir) + cmd = install_lib(dist) + cmd.compile = cmd.optimize = 1 + + f = os.path.join(project_dir, 'foo.py') + self.write_file(f, '# python file') + cmd.byte_compile([f]) + pyc_file = importlib.util.cache_from_source('foo.py', optimization='') + pyc_opt_file = importlib.util.cache_from_source( + 'foo.py', optimization=cmd.optimize + ) + assert os.path.exists(pyc_file) + assert os.path.exists(pyc_opt_file) + + def test_get_outputs(self): + project_dir, dist = self.create_dist() + os.chdir(project_dir) + os.mkdir('spam') + cmd = install_lib(dist) + + # setting up a dist environment + cmd.compile = cmd.optimize = 1 + cmd.install_dir = self.mkdtemp() + f = os.path.join(project_dir, 'spam', '__init__.py') + self.write_file(f, '# python package') + cmd.distribution.ext_modules = [Extension('foo', ['xxx'])] + cmd.distribution.packages = ['spam'] + cmd.distribution.script_name = 'setup.py' + + # get_outputs should return 4 elements: spam/__init__.py and .pyc, + # foo.import-tag-abiflags.so / foo.pyd + outputs = cmd.get_outputs() + assert len(outputs) == 4, outputs + + def test_get_inputs(self): + project_dir, dist = self.create_dist() + os.chdir(project_dir) + os.mkdir('spam') + cmd = install_lib(dist) + + # setting up a dist environment + cmd.compile = cmd.optimize = 1 + cmd.install_dir = self.mkdtemp() + f = os.path.join(project_dir, 'spam', '__init__.py') + self.write_file(f, '# python package') + cmd.distribution.ext_modules = [Extension('foo', ['xxx'])] + cmd.distribution.packages = ['spam'] + cmd.distribution.script_name = 'setup.py' + + # get_inputs should return 2 elements: spam/__init__.py and + # foo.import-tag-abiflags.so / foo.pyd + inputs = cmd.get_inputs() + assert len(inputs) == 2, inputs + + def test_dont_write_bytecode(self, caplog): + # makes sure byte_compile is not used + dist = self.create_dist()[1] + cmd = install_lib(dist) + cmd.compile = True + cmd.optimize = 1 + + old_dont_write_bytecode = sys.dont_write_bytecode + sys.dont_write_bytecode = True + try: + cmd.byte_compile([]) + finally: + sys.dont_write_bytecode = old_dont_write_bytecode + + assert 'byte-compiling is disabled' in caplog.messages[0] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_install_scripts.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_install_scripts.py new file mode 100644 index 0000000000000000000000000000000000000000..868b1c22521f23a5dd398e4636c94330d4c238ac --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_install_scripts.py @@ -0,0 +1,52 @@ +"""Tests for distutils.command.install_scripts.""" + +import os +from distutils.command.install_scripts import install_scripts +from distutils.core import Distribution +from distutils.tests import support + +from . import test_build_scripts + + +class TestInstallScripts(support.TempdirManager): + def test_default_settings(self): + dist = Distribution() + dist.command_obj["build"] = support.DummyCommand(build_scripts="/foo/bar") + dist.command_obj["install"] = support.DummyCommand( + install_scripts="/splat/funk", + force=True, + skip_build=True, + ) + cmd = install_scripts(dist) + assert not cmd.force + assert not cmd.skip_build + assert cmd.build_dir is None + assert cmd.install_dir is None + + cmd.finalize_options() + + assert cmd.force + assert cmd.skip_build + assert cmd.build_dir == "/foo/bar" + assert cmd.install_dir == "/splat/funk" + + def test_installation(self): + source = self.mkdtemp() + + expected = test_build_scripts.TestBuildScripts.write_sample_scripts(source) + + target = self.mkdtemp() + dist = Distribution() + dist.command_obj["build"] = support.DummyCommand(build_scripts=source) + dist.command_obj["install"] = support.DummyCommand( + install_scripts=target, + force=True, + skip_build=True, + ) + cmd = install_scripts(dist) + cmd.finalize_options() + cmd.run() + + installed = os.listdir(target) + for name in expected: + assert name in installed diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_log.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_log.py new file mode 100644 index 0000000000000000000000000000000000000000..d67779fc9fa0f58a010929d5a456890c6dde3376 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_log.py @@ -0,0 +1,12 @@ +"""Tests for distutils.log""" + +import logging +from distutils._log import log + + +class TestLog: + def test_non_ascii(self, caplog): + caplog.set_level(logging.DEBUG) + log.debug('Dεbug\tMėssãge') + log.fatal('Fαtal\tÈrrōr') + assert caplog.messages == ['Dεbug\tMėssãge', 'Fαtal\tÈrrōr'] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_modified.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_modified.py new file mode 100644 index 0000000000000000000000000000000000000000..e35cec2d6f1a8d27619e33c253f0a83f0f72a75d --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_modified.py @@ -0,0 +1,126 @@ +"""Tests for distutils._modified.""" + +import os +import types +from distutils._modified import newer, newer_group, newer_pairwise, newer_pairwise_group +from distutils.errors import DistutilsFileError +from distutils.tests import support + +import pytest + + +class TestDepUtil(support.TempdirManager): + def test_newer(self): + tmpdir = self.mkdtemp() + new_file = os.path.join(tmpdir, 'new') + old_file = os.path.abspath(__file__) + + # Raise DistutilsFileError if 'new_file' does not exist. + with pytest.raises(DistutilsFileError): + newer(new_file, old_file) + + # Return true if 'new_file' exists and is more recently modified than + # 'old_file', or if 'new_file' exists and 'old_file' doesn't. + self.write_file(new_file) + assert newer(new_file, 'I_dont_exist') + assert newer(new_file, old_file) + + # Return false if both exist and 'old_file' is the same age or younger + # than 'new_file'. + assert not newer(old_file, new_file) + + def _setup_1234(self): + tmpdir = self.mkdtemp() + sources = os.path.join(tmpdir, 'sources') + targets = os.path.join(tmpdir, 'targets') + os.mkdir(sources) + os.mkdir(targets) + one = os.path.join(sources, 'one') + two = os.path.join(sources, 'two') + three = os.path.abspath(__file__) # I am the old file + four = os.path.join(targets, 'four') + self.write_file(one) + self.write_file(two) + self.write_file(four) + return one, two, three, four + + def test_newer_pairwise(self): + one, two, three, four = self._setup_1234() + + assert newer_pairwise([one, two], [three, four]) == ([one], [three]) + + def test_newer_pairwise_mismatch(self): + one, two, three, four = self._setup_1234() + + with pytest.raises(ValueError): + newer_pairwise([one], [three, four]) + + with pytest.raises(ValueError): + newer_pairwise([one, two], [three]) + + def test_newer_pairwise_empty(self): + assert newer_pairwise([], []) == ([], []) + + def test_newer_pairwise_fresh(self): + one, two, three, four = self._setup_1234() + + assert newer_pairwise([one, three], [two, four]) == ([], []) + + def test_newer_group(self): + tmpdir = self.mkdtemp() + sources = os.path.join(tmpdir, 'sources') + os.mkdir(sources) + one = os.path.join(sources, 'one') + two = os.path.join(sources, 'two') + three = os.path.join(sources, 'three') + old_file = os.path.abspath(__file__) + + # return true if 'old_file' is out-of-date with respect to any file + # listed in 'sources'. + self.write_file(one) + self.write_file(two) + self.write_file(three) + assert newer_group([one, two, three], old_file) + assert not newer_group([one, two, old_file], three) + + # missing handling + os.remove(one) + with pytest.raises(OSError): + newer_group([one, two, old_file], three) + + assert not newer_group([one, two, old_file], three, missing='ignore') + + assert newer_group([one, two, old_file], three, missing='newer') + + +@pytest.fixture +def groups_target(tmp_path): + """ + Set up some older sources, a target, and newer sources. + + Returns a simple namespace with these values. + """ + filenames = ['older.c', 'older.h', 'target.o', 'newer.c', 'newer.h'] + paths = [tmp_path / name for name in filenames] + + for mtime, path in enumerate(paths): + path.write_text('', encoding='utf-8') + + # make sure modification times are sequential + os.utime(path, (mtime, mtime)) + + return types.SimpleNamespace(older=paths[:2], target=paths[2], newer=paths[3:]) + + +def test_newer_pairwise_group(groups_target): + older = newer_pairwise_group([groups_target.older], [groups_target.target]) + newer = newer_pairwise_group([groups_target.newer], [groups_target.target]) + assert older == ([], []) + assert newer == ([groups_target.newer], [groups_target.target]) + + +def test_newer_group_no_sources_no_target(tmp_path): + """ + Consider no sources and no target "newer". + """ + assert newer_group([], str(tmp_path / 'does-not-exist')) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_sdist.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_sdist.py new file mode 100644 index 0000000000000000000000000000000000000000..6b1a376b262162aa7c8d3d989709c05b38563d6c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_sdist.py @@ -0,0 +1,470 @@ +"""Tests for distutils.command.sdist.""" + +import os +import pathlib +import shutil # noqa: F401 +import tarfile +import zipfile +from distutils.archive_util import ARCHIVE_FORMATS +from distutils.command.sdist import sdist, show_formats +from distutils.core import Distribution +from distutils.errors import DistutilsOptionError +from distutils.filelist import FileList +from os.path import join +from textwrap import dedent + +import jaraco.path +import path +import pytest +from more_itertools import ilen + +from . import support +from .unix_compat import grp, pwd, require_uid_0, require_unix_id + +SETUP_PY = """ +from distutils.core import setup +import somecode + +setup(name='fake') +""" + +MANIFEST = """\ +# file GENERATED by distutils, do NOT edit +README +buildout.cfg +inroot.txt +setup.py +data%(sep)sdata.dt +scripts%(sep)sscript.py +some%(sep)sfile.txt +some%(sep)sother_file.txt +somecode%(sep)s__init__.py +somecode%(sep)sdoc.dat +somecode%(sep)sdoc.txt +""" + + +@pytest.fixture(autouse=True) +def project_dir(request, distutils_managed_tempdir): + self = request.instance + self.tmp_dir = self.mkdtemp() + jaraco.path.build( + { + 'somecode': { + '__init__.py': '#', + }, + 'README': 'xxx', + 'setup.py': SETUP_PY, + }, + self.tmp_dir, + ) + with path.Path(self.tmp_dir): + yield + + +def clean_lines(filepath): + with pathlib.Path(filepath).open(encoding='utf-8') as f: + yield from filter(None, map(str.strip, f)) + + +class TestSDist(support.TempdirManager): + def get_cmd(self, metadata=None): + """Returns a cmd""" + if metadata is None: + metadata = { + 'name': 'ns.fake--pkg', + 'version': '1.0', + 'url': 'xxx', + 'author': 'xxx', + 'author_email': 'xxx', + } + dist = Distribution(metadata) + dist.script_name = 'setup.py' + dist.packages = ['somecode'] + dist.include_package_data = True + cmd = sdist(dist) + cmd.dist_dir = 'dist' + return dist, cmd + + @pytest.mark.usefixtures('needs_zlib') + def test_prune_file_list(self): + # this test creates a project with some VCS dirs and an NFS rename + # file, then launches sdist to check they get pruned on all systems + + # creating VCS directories with some files in them + os.mkdir(join(self.tmp_dir, 'somecode', '.svn')) + self.write_file((self.tmp_dir, 'somecode', '.svn', 'ok.py'), 'xxx') + + os.mkdir(join(self.tmp_dir, 'somecode', '.hg')) + self.write_file((self.tmp_dir, 'somecode', '.hg', 'ok'), 'xxx') + + os.mkdir(join(self.tmp_dir, 'somecode', '.git')) + self.write_file((self.tmp_dir, 'somecode', '.git', 'ok'), 'xxx') + + self.write_file((self.tmp_dir, 'somecode', '.nfs0001'), 'xxx') + + # now building a sdist + dist, cmd = self.get_cmd() + + # zip is available universally + # (tar might not be installed under win32) + cmd.formats = ['zip'] + + cmd.ensure_finalized() + cmd.run() + + # now let's check what we have + dist_folder = join(self.tmp_dir, 'dist') + files = os.listdir(dist_folder) + assert files == ['ns_fake_pkg-1.0.zip'] + + zip_file = zipfile.ZipFile(join(dist_folder, 'ns_fake_pkg-1.0.zip')) + try: + content = zip_file.namelist() + finally: + zip_file.close() + + # making sure everything has been pruned correctly + expected = [ + '', + 'PKG-INFO', + 'README', + 'setup.py', + 'somecode/', + 'somecode/__init__.py', + ] + assert sorted(content) == ['ns_fake_pkg-1.0/' + x for x in expected] + + @pytest.mark.usefixtures('needs_zlib') + @pytest.mark.skipif("not shutil.which('tar')") + @pytest.mark.skipif("not shutil.which('gzip')") + def test_make_distribution(self): + # now building a sdist + dist, cmd = self.get_cmd() + + # creating a gztar then a tar + cmd.formats = ['gztar', 'tar'] + cmd.ensure_finalized() + cmd.run() + + # making sure we have two files + dist_folder = join(self.tmp_dir, 'dist') + result = os.listdir(dist_folder) + result.sort() + assert result == ['ns_fake_pkg-1.0.tar', 'ns_fake_pkg-1.0.tar.gz'] + + os.remove(join(dist_folder, 'ns_fake_pkg-1.0.tar')) + os.remove(join(dist_folder, 'ns_fake_pkg-1.0.tar.gz')) + + # now trying a tar then a gztar + cmd.formats = ['tar', 'gztar'] + + cmd.ensure_finalized() + cmd.run() + + result = os.listdir(dist_folder) + result.sort() + assert result == ['ns_fake_pkg-1.0.tar', 'ns_fake_pkg-1.0.tar.gz'] + + @pytest.mark.usefixtures('needs_zlib') + def test_add_defaults(self): + # https://bugs.python.org/issue2279 + + # add_default should also include + # data_files and package_data + dist, cmd = self.get_cmd() + + # filling data_files by pointing files + # in package_data + dist.package_data = {'': ['*.cfg', '*.dat'], 'somecode': ['*.txt']} + self.write_file((self.tmp_dir, 'somecode', 'doc.txt'), '#') + self.write_file((self.tmp_dir, 'somecode', 'doc.dat'), '#') + + # adding some data in data_files + data_dir = join(self.tmp_dir, 'data') + os.mkdir(data_dir) + self.write_file((data_dir, 'data.dt'), '#') + some_dir = join(self.tmp_dir, 'some') + os.mkdir(some_dir) + # make sure VCS directories are pruned (#14004) + hg_dir = join(self.tmp_dir, '.hg') + os.mkdir(hg_dir) + self.write_file((hg_dir, 'last-message.txt'), '#') + # a buggy regex used to prevent this from working on windows (#6884) + self.write_file((self.tmp_dir, 'buildout.cfg'), '#') + self.write_file((self.tmp_dir, 'inroot.txt'), '#') + self.write_file((some_dir, 'file.txt'), '#') + self.write_file((some_dir, 'other_file.txt'), '#') + + dist.data_files = [ + ('data', ['data/data.dt', 'buildout.cfg', 'inroot.txt', 'notexisting']), + 'some/file.txt', + 'some/other_file.txt', + ] + + # adding a script + script_dir = join(self.tmp_dir, 'scripts') + os.mkdir(script_dir) + self.write_file((script_dir, 'script.py'), '#') + dist.scripts = [join('scripts', 'script.py')] + + cmd.formats = ['zip'] + cmd.use_defaults = True + + cmd.ensure_finalized() + cmd.run() + + # now let's check what we have + dist_folder = join(self.tmp_dir, 'dist') + files = os.listdir(dist_folder) + assert files == ['ns_fake_pkg-1.0.zip'] + + zip_file = zipfile.ZipFile(join(dist_folder, 'ns_fake_pkg-1.0.zip')) + try: + content = zip_file.namelist() + finally: + zip_file.close() + + # making sure everything was added + expected = [ + '', + 'PKG-INFO', + 'README', + 'buildout.cfg', + 'data/', + 'data/data.dt', + 'inroot.txt', + 'scripts/', + 'scripts/script.py', + 'setup.py', + 'some/', + 'some/file.txt', + 'some/other_file.txt', + 'somecode/', + 'somecode/__init__.py', + 'somecode/doc.dat', + 'somecode/doc.txt', + ] + assert sorted(content) == ['ns_fake_pkg-1.0/' + x for x in expected] + + # checking the MANIFEST + manifest = pathlib.Path(self.tmp_dir, 'MANIFEST').read_text(encoding='utf-8') + assert manifest == MANIFEST % {'sep': os.sep} + + @staticmethod + def warnings(messages, prefix='warning: '): + return [msg for msg in messages if msg.startswith(prefix)] + + @pytest.mark.usefixtures('needs_zlib') + def test_metadata_check_option(self, caplog): + # testing the `medata-check` option + dist, cmd = self.get_cmd(metadata={}) + + # this should raise some warnings ! + # with the `check` subcommand + cmd.ensure_finalized() + cmd.run() + assert len(self.warnings(caplog.messages, 'warning: check: ')) == 1 + + # trying with a complete set of metadata + caplog.clear() + dist, cmd = self.get_cmd() + cmd.ensure_finalized() + cmd.metadata_check = False + cmd.run() + assert len(self.warnings(caplog.messages, 'warning: check: ')) == 0 + + def test_show_formats(self, capsys): + show_formats() + + # the output should be a header line + one line per format + num_formats = len(ARCHIVE_FORMATS.keys()) + output = [ + line + for line in capsys.readouterr().out.split('\n') + if line.strip().startswith('--formats=') + ] + assert len(output) == num_formats + + def test_finalize_options(self): + dist, cmd = self.get_cmd() + cmd.finalize_options() + + # default options set by finalize + assert cmd.manifest == 'MANIFEST' + assert cmd.template == 'MANIFEST.in' + assert cmd.dist_dir == 'dist' + + # formats has to be a string splitable on (' ', ',') or + # a stringlist + cmd.formats = 1 + with pytest.raises(DistutilsOptionError): + cmd.finalize_options() + cmd.formats = ['zip'] + cmd.finalize_options() + + # formats has to be known + cmd.formats = 'supazipa' + with pytest.raises(DistutilsOptionError): + cmd.finalize_options() + + # the following tests make sure there is a nice error message instead + # of a traceback when parsing an invalid manifest template + + def _check_template(self, content, caplog): + dist, cmd = self.get_cmd() + os.chdir(self.tmp_dir) + self.write_file('MANIFEST.in', content) + cmd.ensure_finalized() + cmd.filelist = FileList() + cmd.read_template() + assert len(self.warnings(caplog.messages)) == 1 + + def test_invalid_template_unknown_command(self, caplog): + self._check_template('taunt knights *', caplog) + + def test_invalid_template_wrong_arguments(self, caplog): + # this manifest command takes one argument + self._check_template('prune', caplog) + + @pytest.mark.skipif("platform.system() != 'Windows'") + def test_invalid_template_wrong_path(self, caplog): + # on Windows, trailing slashes are not allowed + # this used to crash instead of raising a warning: #8286 + self._check_template('include examples/', caplog) + + @pytest.mark.usefixtures('needs_zlib') + def test_get_file_list(self): + # make sure MANIFEST is recalculated + dist, cmd = self.get_cmd() + + # filling data_files by pointing files in package_data + dist.package_data = {'somecode': ['*.txt']} + self.write_file((self.tmp_dir, 'somecode', 'doc.txt'), '#') + cmd.formats = ['gztar'] + cmd.ensure_finalized() + cmd.run() + + assert ilen(clean_lines(cmd.manifest)) == 5 + + # adding a file + self.write_file((self.tmp_dir, 'somecode', 'doc2.txt'), '#') + + # make sure build_py is reinitialized, like a fresh run + build_py = dist.get_command_obj('build_py') + build_py.finalized = False + build_py.ensure_finalized() + + cmd.run() + + manifest2 = list(clean_lines(cmd.manifest)) + + # do we have the new file in MANIFEST ? + assert len(manifest2) == 6 + assert 'doc2.txt' in manifest2[-1] + + @pytest.mark.usefixtures('needs_zlib') + def test_manifest_marker(self): + # check that autogenerated MANIFESTs have a marker + dist, cmd = self.get_cmd() + cmd.ensure_finalized() + cmd.run() + + assert ( + next(clean_lines(cmd.manifest)) + == '# file GENERATED by distutils, do NOT edit' + ) + + @pytest.mark.usefixtures('needs_zlib') + def test_manifest_comments(self): + # make sure comments don't cause exceptions or wrong includes + contents = dedent( + """\ + # bad.py + #bad.py + good.py + """ + ) + dist, cmd = self.get_cmd() + cmd.ensure_finalized() + self.write_file((self.tmp_dir, cmd.manifest), contents) + self.write_file((self.tmp_dir, 'good.py'), '# pick me!') + self.write_file((self.tmp_dir, 'bad.py'), "# don't pick me!") + self.write_file((self.tmp_dir, '#bad.py'), "# don't pick me!") + cmd.run() + assert cmd.filelist.files == ['good.py'] + + @pytest.mark.usefixtures('needs_zlib') + def test_manual_manifest(self): + # check that a MANIFEST without a marker is left alone + dist, cmd = self.get_cmd() + cmd.formats = ['gztar'] + cmd.ensure_finalized() + self.write_file((self.tmp_dir, cmd.manifest), 'README.manual') + self.write_file( + (self.tmp_dir, 'README.manual'), + 'This project maintains its MANIFEST file itself.', + ) + cmd.run() + assert cmd.filelist.files == ['README.manual'] + + assert list(clean_lines(cmd.manifest)) == ['README.manual'] + + archive_name = join(self.tmp_dir, 'dist', 'ns_fake_pkg-1.0.tar.gz') + archive = tarfile.open(archive_name) + try: + filenames = [tarinfo.name for tarinfo in archive] + finally: + archive.close() + assert sorted(filenames) == [ + 'ns_fake_pkg-1.0', + 'ns_fake_pkg-1.0/PKG-INFO', + 'ns_fake_pkg-1.0/README.manual', + ] + + @pytest.mark.usefixtures('needs_zlib') + @require_unix_id + @require_uid_0 + @pytest.mark.skipif("not shutil.which('tar')") + @pytest.mark.skipif("not shutil.which('gzip')") + def test_make_distribution_owner_group(self): + # now building a sdist + dist, cmd = self.get_cmd() + + # creating a gztar and specifying the owner+group + cmd.formats = ['gztar'] + cmd.owner = pwd.getpwuid(0)[0] + cmd.group = grp.getgrgid(0)[0] + cmd.ensure_finalized() + cmd.run() + + # making sure we have the good rights + archive_name = join(self.tmp_dir, 'dist', 'ns_fake_pkg-1.0.tar.gz') + archive = tarfile.open(archive_name) + try: + for member in archive.getmembers(): + assert member.uid == 0 + assert member.gid == 0 + finally: + archive.close() + + # building a sdist again + dist, cmd = self.get_cmd() + + # creating a gztar + cmd.formats = ['gztar'] + cmd.ensure_finalized() + cmd.run() + + # making sure we have the good rights + archive_name = join(self.tmp_dir, 'dist', 'ns_fake_pkg-1.0.tar.gz') + archive = tarfile.open(archive_name) + + # note that we are not testing the group ownership here + # because, depending on the platforms and the container + # rights (see #7408) + try: + for member in archive.getmembers(): + assert member.uid == os.getuid() + finally: + archive.close() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_spawn.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_spawn.py new file mode 100644 index 0000000000000000000000000000000000000000..3b9fc926f6ffc41673630fbf5775e6f4ad638b18 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_spawn.py @@ -0,0 +1,141 @@ +"""Tests for distutils.spawn.""" + +import os +import stat +import sys +import unittest.mock as mock +from distutils.errors import DistutilsExecError +from distutils.spawn import find_executable, spawn +from distutils.tests import support + +import path +import pytest +from test.support import unix_shell + +from .compat import py39 as os_helper + + +class TestSpawn(support.TempdirManager): + @pytest.mark.skipif("os.name not in ('nt', 'posix')") + def test_spawn(self): + tmpdir = self.mkdtemp() + + # creating something executable + # through the shell that returns 1 + if sys.platform != 'win32': + exe = os.path.join(tmpdir, 'foo.sh') + self.write_file(exe, f'#!{unix_shell}\nexit 1') + else: + exe = os.path.join(tmpdir, 'foo.bat') + self.write_file(exe, 'exit 1') + + os.chmod(exe, 0o777) + with pytest.raises(DistutilsExecError): + spawn([exe]) + + # now something that works + if sys.platform != 'win32': + exe = os.path.join(tmpdir, 'foo.sh') + self.write_file(exe, f'#!{unix_shell}\nexit 0') + else: + exe = os.path.join(tmpdir, 'foo.bat') + self.write_file(exe, 'exit 0') + + os.chmod(exe, 0o777) + spawn([exe]) # should work without any error + + def test_find_executable(self, tmp_path): + program_path = self._make_executable(tmp_path, '.exe') + program = program_path.name + program_noeext = program_path.with_suffix('').name + filename = str(program_path) + tmp_dir = path.Path(tmp_path) + + # test path parameter + rv = find_executable(program, path=tmp_dir) + assert rv == filename + + if sys.platform == 'win32': + # test without ".exe" extension + rv = find_executable(program_noeext, path=tmp_dir) + assert rv == filename + + # test find in the current directory + with tmp_dir: + rv = find_executable(program) + assert rv == program + + # test non-existent program + dont_exist_program = "dontexist_" + program + rv = find_executable(dont_exist_program, path=tmp_dir) + assert rv is None + + # PATH='': no match, except in the current directory + with os_helper.EnvironmentVarGuard() as env: + env['PATH'] = '' + with ( + mock.patch( + 'distutils.spawn.os.confstr', return_value=tmp_dir, create=True + ), + mock.patch('distutils.spawn.os.defpath', tmp_dir), + ): + rv = find_executable(program) + assert rv is None + + # look in current directory + with tmp_dir: + rv = find_executable(program) + assert rv == program + + # PATH=':': explicitly looks in the current directory + with os_helper.EnvironmentVarGuard() as env: + env['PATH'] = os.pathsep + with ( + mock.patch('distutils.spawn.os.confstr', return_value='', create=True), + mock.patch('distutils.spawn.os.defpath', ''), + ): + rv = find_executable(program) + assert rv is None + + # look in current directory + with tmp_dir: + rv = find_executable(program) + assert rv == program + + # missing PATH: test os.confstr("CS_PATH") and os.defpath + with os_helper.EnvironmentVarGuard() as env: + env.pop('PATH', None) + + # without confstr + with ( + mock.patch( + 'distutils.spawn.os.confstr', side_effect=ValueError, create=True + ), + mock.patch('distutils.spawn.os.defpath', tmp_dir), + ): + rv = find_executable(program) + assert rv == filename + + # with confstr + with ( + mock.patch( + 'distutils.spawn.os.confstr', return_value=tmp_dir, create=True + ), + mock.patch('distutils.spawn.os.defpath', ''), + ): + rv = find_executable(program) + assert rv == filename + + @staticmethod + def _make_executable(tmp_path, ext): + # Give the temporary program a suffix regardless of platform. + # It's needed on Windows and not harmful on others. + program = tmp_path.joinpath('program').with_suffix(ext) + program.write_text("", encoding='utf-8') + program.chmod(stat.S_IXUSR) + return program + + def test_spawn_missing_exe(self): + with pytest.raises(DistutilsExecError) as ctx: + spawn(['does-not-exist']) + assert "command 'does-not-exist' failed" in str(ctx.value) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_sysconfig.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_sysconfig.py new file mode 100644 index 0000000000000000000000000000000000000000..43d77c23fad426be237b9f91a6d98d7c36233d84 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_sysconfig.py @@ -0,0 +1,319 @@ +"""Tests for distutils.sysconfig.""" + +import contextlib +import distutils +import os +import pathlib +import subprocess +import sys +from distutils import sysconfig +from distutils.ccompiler import new_compiler # noqa: F401 +from distutils.unixccompiler import UnixCCompiler + +import jaraco.envs +import path +import pytest +from jaraco.text import trim +from test.support import swap_item + + +def _gen_makefile(root, contents): + jaraco.path.build({'Makefile': trim(contents)}, root) + return root / 'Makefile' + + +@pytest.mark.usefixtures('save_env') +class TestSysconfig: + def test_get_config_h_filename(self): + config_h = sysconfig.get_config_h_filename() + assert os.path.isfile(config_h) + + @pytest.mark.skipif("platform.system() == 'Windows'") + @pytest.mark.skipif("sys.implementation.name != 'cpython'") + def test_get_makefile_filename(self): + makefile = sysconfig.get_makefile_filename() + assert os.path.isfile(makefile) + + def test_get_python_lib(self, tmp_path): + assert sysconfig.get_python_lib() != sysconfig.get_python_lib(prefix=tmp_path) + + def test_get_config_vars(self): + cvars = sysconfig.get_config_vars() + assert isinstance(cvars, dict) + assert cvars + + @pytest.mark.skipif('sysconfig.IS_PYPY') + @pytest.mark.skipif('sysconfig.python_build') + @pytest.mark.xfail('platform.system() == "Windows"') + def test_srcdir_simple(self): + # See #15364. + srcdir = pathlib.Path(sysconfig.get_config_var('srcdir')) + + assert srcdir.absolute() + assert srcdir.is_dir() + + makefile = pathlib.Path(sysconfig.get_makefile_filename()) + assert makefile.parent.samefile(srcdir) + + @pytest.mark.skipif('sysconfig.IS_PYPY') + @pytest.mark.skipif('not sysconfig.python_build') + def test_srcdir_python_build(self): + # See #15364. + srcdir = pathlib.Path(sysconfig.get_config_var('srcdir')) + + # The python executable has not been installed so srcdir + # should be a full source checkout. + Python_h = srcdir.joinpath('Include', 'Python.h') + assert Python_h.is_file() + assert sysconfig._is_python_source_dir(srcdir) + assert sysconfig._is_python_source_dir(str(srcdir)) + + def test_srcdir_independent_of_cwd(self): + """ + srcdir should be independent of the current working directory + """ + # See #15364. + srcdir = sysconfig.get_config_var('srcdir') + with path.Path('..'): + srcdir2 = sysconfig.get_config_var('srcdir') + assert srcdir == srcdir2 + + def customize_compiler(self): + # make sure AR gets caught + class compiler: + compiler_type = 'unix' + executables = UnixCCompiler.executables + + def __init__(self): + self.exes = {} + + def set_executables(self, **kw): + for k, v in kw.items(): + self.exes[k] = v + + sysconfig_vars = { + 'AR': 'sc_ar', + 'CC': 'sc_cc', + 'CXX': 'sc_cxx', + 'ARFLAGS': '--sc-arflags', + 'CFLAGS': '--sc-cflags', + 'CCSHARED': '--sc-ccshared', + 'LDSHARED': 'sc_ldshared', + 'SHLIB_SUFFIX': 'sc_shutil_suffix', + } + + comp = compiler() + with contextlib.ExitStack() as cm: + for key, value in sysconfig_vars.items(): + cm.enter_context(swap_item(sysconfig._config_vars, key, value)) + sysconfig.customize_compiler(comp) + + return comp + + @pytest.mark.skipif("not isinstance(new_compiler(), UnixCCompiler)") + @pytest.mark.usefixtures('disable_macos_customization') + def test_customize_compiler(self): + # Make sure that sysconfig._config_vars is initialized + sysconfig.get_config_vars() + + os.environ['AR'] = 'env_ar' + os.environ['CC'] = 'env_cc' + os.environ['CPP'] = 'env_cpp' + os.environ['CXX'] = 'env_cxx --env-cxx-flags' + os.environ['LDSHARED'] = 'env_ldshared' + os.environ['LDFLAGS'] = '--env-ldflags' + os.environ['ARFLAGS'] = '--env-arflags' + os.environ['CFLAGS'] = '--env-cflags' + os.environ['CPPFLAGS'] = '--env-cppflags' + os.environ['RANLIB'] = 'env_ranlib' + + comp = self.customize_compiler() + assert comp.exes['archiver'] == 'env_ar --env-arflags' + assert comp.exes['preprocessor'] == 'env_cpp --env-cppflags' + assert comp.exes['compiler'] == 'env_cc --env-cflags --env-cppflags' + assert comp.exes['compiler_so'] == ( + 'env_cc --env-cflags --env-cppflags --sc-ccshared' + ) + assert ( + comp.exes['compiler_cxx'] + == 'env_cxx --env-cxx-flags --sc-cflags --env-cppflags' + ) + assert comp.exes['linker_exe'] == 'env_cc' + assert comp.exes['linker_so'] == ( + 'env_ldshared --env-ldflags --env-cflags --env-cppflags' + ) + assert comp.shared_lib_extension == 'sc_shutil_suffix' + + if sys.platform == "darwin": + assert comp.exes['ranlib'] == 'env_ranlib' + else: + assert 'ranlib' not in comp.exes + + del os.environ['AR'] + del os.environ['CC'] + del os.environ['CPP'] + del os.environ['CXX'] + del os.environ['LDSHARED'] + del os.environ['LDFLAGS'] + del os.environ['ARFLAGS'] + del os.environ['CFLAGS'] + del os.environ['CPPFLAGS'] + del os.environ['RANLIB'] + + comp = self.customize_compiler() + assert comp.exes['archiver'] == 'sc_ar --sc-arflags' + assert comp.exes['preprocessor'] == 'sc_cc -E' + assert comp.exes['compiler'] == 'sc_cc --sc-cflags' + assert comp.exes['compiler_so'] == 'sc_cc --sc-cflags --sc-ccshared' + assert comp.exes['compiler_cxx'] == 'sc_cxx --sc-cflags' + assert comp.exes['linker_exe'] == 'sc_cc' + assert comp.exes['linker_so'] == 'sc_ldshared' + assert comp.shared_lib_extension == 'sc_shutil_suffix' + assert 'ranlib' not in comp.exes + + def test_parse_makefile_base(self, tmp_path): + makefile = _gen_makefile( + tmp_path, + """ + CONFIG_ARGS= '--arg1=optarg1' 'ENV=LIB' + VAR=$OTHER + OTHER=foo + """, + ) + d = sysconfig.parse_makefile(makefile) + assert d == {'CONFIG_ARGS': "'--arg1=optarg1' 'ENV=LIB'", 'OTHER': 'foo'} + + def test_parse_makefile_literal_dollar(self, tmp_path): + makefile = _gen_makefile( + tmp_path, + """ + CONFIG_ARGS= '--arg1=optarg1' 'ENV=\\$$LIB' + VAR=$OTHER + OTHER=foo + """, + ) + d = sysconfig.parse_makefile(makefile) + assert d == {'CONFIG_ARGS': r"'--arg1=optarg1' 'ENV=\$LIB'", 'OTHER': 'foo'} + + def test_sysconfig_module(self): + import sysconfig as global_sysconfig + + assert global_sysconfig.get_config_var('CFLAGS') == sysconfig.get_config_var( + 'CFLAGS' + ) + assert global_sysconfig.get_config_var('LDFLAGS') == sysconfig.get_config_var( + 'LDFLAGS' + ) + + # On macOS, binary installers support extension module building on + # various levels of the operating system with differing Xcode + # configurations, requiring customization of some of the + # compiler configuration directives to suit the environment on + # the installed machine. Some of these customizations may require + # running external programs and are thus deferred until needed by + # the first extension module build. Only + # the Distutils version of sysconfig is used for extension module + # builds, which happens earlier in the Distutils tests. This may + # cause the following tests to fail since no tests have caused + # the global version of sysconfig to call the customization yet. + # The solution for now is to simply skip this test in this case. + # The longer-term solution is to only have one version of sysconfig. + @pytest.mark.skipif("sysconfig.get_config_var('CUSTOMIZED_OSX_COMPILER')") + def test_sysconfig_compiler_vars(self): + import sysconfig as global_sysconfig + + if sysconfig.get_config_var('CUSTOMIZED_OSX_COMPILER'): + pytest.skip('compiler flags customized') + assert global_sysconfig.get_config_var('LDSHARED') == sysconfig.get_config_var( + 'LDSHARED' + ) + assert global_sysconfig.get_config_var('CC') == sysconfig.get_config_var('CC') + + @pytest.mark.skipif("not sysconfig.get_config_var('EXT_SUFFIX')") + def test_SO_deprecation(self): + with pytest.warns(DeprecationWarning): + sysconfig.get_config_var('SO') + + def test_customize_compiler_before_get_config_vars(self, tmp_path): + # Issue #21923: test that a Distribution compiler + # instance can be called without an explicit call to + # get_config_vars(). + jaraco.path.build( + { + 'file': trim(""" + from distutils.core import Distribution + config = Distribution().get_command_obj('config') + # try_compile may pass or it may fail if no compiler + # is found but it should not raise an exception. + rc = config.try_compile('int x;') + """) + }, + tmp_path, + ) + p = subprocess.Popen( + [sys.executable, tmp_path / 'file'], + stdout=subprocess.PIPE, + stderr=subprocess.STDOUT, + universal_newlines=True, + encoding='utf-8', + ) + outs, errs = p.communicate() + assert 0 == p.returncode, "Subprocess failed: " + outs + + def test_parse_config_h(self): + config_h = sysconfig.get_config_h_filename() + input = {} + with open(config_h, encoding="utf-8") as f: + result = sysconfig.parse_config_h(f, g=input) + assert input is result + with open(config_h, encoding="utf-8") as f: + result = sysconfig.parse_config_h(f) + assert isinstance(result, dict) + + @pytest.mark.skipif("platform.system() != 'Windows'") + @pytest.mark.skipif("sys.implementation.name != 'cpython'") + def test_win_ext_suffix(self): + assert sysconfig.get_config_var("EXT_SUFFIX").endswith(".pyd") + assert sysconfig.get_config_var("EXT_SUFFIX") != ".pyd" + + @pytest.mark.skipif("platform.system() != 'Windows'") + @pytest.mark.skipif("sys.implementation.name != 'cpython'") + @pytest.mark.skipif( + '\\PCbuild\\'.casefold() not in sys.executable.casefold(), + reason='Need sys.executable to be in a source tree', + ) + def test_win_build_venv_from_source_tree(self, tmp_path): + """Ensure distutils.sysconfig detects venvs from source tree builds.""" + env = jaraco.envs.VEnv() + env.create_opts = env.clean_opts + env.root = tmp_path + env.ensure_env() + cmd = [ + env.exe(), + "-c", + "import distutils.sysconfig; print(distutils.sysconfig.python_build)", + ] + distutils_path = os.path.dirname(os.path.dirname(distutils.__file__)) + out = subprocess.check_output( + cmd, env={**os.environ, "PYTHONPATH": distutils_path} + ) + assert out == "True" + + def test_get_python_inc_missing_config_dir(self, monkeypatch): + """ + In portable Python installations, the sysconfig will be broken, + pointing to the directories where the installation was built and + not where it currently is. In this case, ensure that the missing + directory isn't used for get_python_inc. + + See pypa/distutils#178. + """ + + def override(name): + if name == 'INCLUDEPY': + return '/does-not-exist' + return sysconfig.get_config_var(name) + + monkeypatch.setattr(sysconfig, 'get_config_var', override) + + assert os.path.exists(sysconfig.get_python_inc()) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_text_file.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_text_file.py new file mode 100644 index 0000000000000000000000000000000000000000..f51115656135cd3f348a45d4a14f97eeee47fb98 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_text_file.py @@ -0,0 +1,127 @@ +"""Tests for distutils.text_file.""" + +from distutils.tests import support +from distutils.text_file import TextFile + +import jaraco.path +import path + +TEST_DATA = """# test file + +line 3 \\ +# intervening comment + continues on next line +""" + + +class TestTextFile(support.TempdirManager): + def test_class(self): + # old tests moved from text_file.__main__ + # so they are really called by the buildbots + + # result 1: no fancy options + result1 = [ + '# test file\n', + '\n', + 'line 3 \\\n', + '# intervening comment\n', + ' continues on next line\n', + ] + + # result 2: just strip comments + result2 = ["\n", "line 3 \\\n", " continues on next line\n"] + + # result 3: just strip blank lines + result3 = [ + "# test file\n", + "line 3 \\\n", + "# intervening comment\n", + " continues on next line\n", + ] + + # result 4: default, strip comments, blank lines, + # and trailing whitespace + result4 = ["line 3 \\", " continues on next line"] + + # result 5: strip comments and blanks, plus join lines (but don't + # "collapse" joined lines + result5 = ["line 3 continues on next line"] + + # result 6: strip comments and blanks, plus join lines (and + # "collapse" joined lines + result6 = ["line 3 continues on next line"] + + def test_input(count, description, file, expected_result): + result = file.readlines() + assert result == expected_result + + tmp_path = path.Path(self.mkdtemp()) + filename = tmp_path / 'test.txt' + jaraco.path.build({filename.name: TEST_DATA}, tmp_path) + + in_file = TextFile( + filename, + strip_comments=False, + skip_blanks=False, + lstrip_ws=False, + rstrip_ws=False, + ) + try: + test_input(1, "no processing", in_file, result1) + finally: + in_file.close() + + in_file = TextFile( + filename, + strip_comments=True, + skip_blanks=False, + lstrip_ws=False, + rstrip_ws=False, + ) + try: + test_input(2, "strip comments", in_file, result2) + finally: + in_file.close() + + in_file = TextFile( + filename, + strip_comments=False, + skip_blanks=True, + lstrip_ws=False, + rstrip_ws=False, + ) + try: + test_input(3, "strip blanks", in_file, result3) + finally: + in_file.close() + + in_file = TextFile(filename) + try: + test_input(4, "default processing", in_file, result4) + finally: + in_file.close() + + in_file = TextFile( + filename, + strip_comments=True, + skip_blanks=True, + join_lines=True, + rstrip_ws=True, + ) + try: + test_input(5, "join lines without collapsing", in_file, result5) + finally: + in_file.close() + + in_file = TextFile( + filename, + strip_comments=True, + skip_blanks=True, + join_lines=True, + rstrip_ws=True, + collapse_join=True, + ) + try: + test_input(6, "join lines with collapsing", in_file, result6) + finally: + in_file.close() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_util.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_util.py new file mode 100644 index 0000000000000000000000000000000000000000..00c9743ed0a2664039060ef149d30f165bf2f465 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_util.py @@ -0,0 +1,243 @@ +"""Tests for distutils.util.""" + +import email +import email.generator +import email.policy +import io +import os +import pathlib +import sys +import sysconfig as stdlib_sysconfig +import unittest.mock as mock +from copy import copy +from distutils import sysconfig, util +from distutils.errors import DistutilsByteCompileError, DistutilsPlatformError +from distutils.util import ( + byte_compile, + change_root, + check_environ, + convert_path, + get_host_platform, + get_platform, + grok_environment_error, + rfc822_escape, + split_quoted, + strtobool, +) + +import pytest + + +@pytest.fixture(autouse=True) +def environment(monkeypatch): + monkeypatch.setattr(os, 'name', os.name) + monkeypatch.setattr(sys, 'platform', sys.platform) + monkeypatch.setattr(sys, 'version', sys.version) + monkeypatch.setattr(os, 'sep', os.sep) + monkeypatch.setattr(os.path, 'join', os.path.join) + monkeypatch.setattr(os.path, 'isabs', os.path.isabs) + monkeypatch.setattr(os.path, 'splitdrive', os.path.splitdrive) + monkeypatch.setattr(sysconfig, '_config_vars', copy(sysconfig._config_vars)) + + +@pytest.mark.usefixtures('save_env') +class TestUtil: + def test_get_host_platform(self): + with mock.patch('os.name', 'nt'): + with mock.patch('sys.version', '... [... (ARM64)]'): + assert get_host_platform() == 'win-arm64' + with mock.patch('sys.version', '... [... (ARM)]'): + assert get_host_platform() == 'win-arm32' + + with mock.patch('sys.version_info', (3, 9, 0, 'final', 0)): + assert get_host_platform() == stdlib_sysconfig.get_platform() + + def test_get_platform(self): + with mock.patch('os.name', 'nt'): + with mock.patch.dict('os.environ', {'VSCMD_ARG_TGT_ARCH': 'x86'}): + assert get_platform() == 'win32' + with mock.patch.dict('os.environ', {'VSCMD_ARG_TGT_ARCH': 'x64'}): + assert get_platform() == 'win-amd64' + with mock.patch.dict('os.environ', {'VSCMD_ARG_TGT_ARCH': 'arm'}): + assert get_platform() == 'win-arm32' + with mock.patch.dict('os.environ', {'VSCMD_ARG_TGT_ARCH': 'arm64'}): + assert get_platform() == 'win-arm64' + + def test_convert_path(self): + expected = os.sep.join(('', 'home', 'to', 'my', 'stuff')) + assert convert_path('/home/to/my/stuff') == expected + assert convert_path(pathlib.Path('/home/to/my/stuff')) == expected + assert convert_path('.') == os.curdir + + def test_change_root(self): + # linux/mac + os.name = 'posix' + + def _isabs(path): + return path[0] == '/' + + os.path.isabs = _isabs + + def _join(*path): + return '/'.join(path) + + os.path.join = _join + + assert change_root('/root', '/old/its/here') == '/root/old/its/here' + assert change_root('/root', 'its/here') == '/root/its/here' + + # windows + os.name = 'nt' + os.sep = '\\' + + def _isabs(path): + return path.startswith('c:\\') + + os.path.isabs = _isabs + + def _splitdrive(path): + if path.startswith('c:'): + return ('', path.replace('c:', '')) + return ('', path) + + os.path.splitdrive = _splitdrive + + def _join(*path): + return '\\'.join(path) + + os.path.join = _join + + assert ( + change_root('c:\\root', 'c:\\old\\its\\here') == 'c:\\root\\old\\its\\here' + ) + assert change_root('c:\\root', 'its\\here') == 'c:\\root\\its\\here' + + # BugsBunny os (it's a great os) + os.name = 'BugsBunny' + with pytest.raises(DistutilsPlatformError): + change_root('c:\\root', 'its\\here') + + # XXX platforms to be covered: mac + + def test_check_environ(self): + util.check_environ.cache_clear() + os.environ.pop('HOME', None) + + check_environ() + + assert os.environ['PLAT'] == get_platform() + + @pytest.mark.skipif("os.name != 'posix'") + def test_check_environ_getpwuid(self): + util.check_environ.cache_clear() + os.environ.pop('HOME', None) + + import pwd + + # only set pw_dir field, other fields are not used + result = pwd.struct_passwd(( + None, + None, + None, + None, + None, + '/home/distutils', + None, + )) + with mock.patch.object(pwd, 'getpwuid', return_value=result): + check_environ() + assert os.environ['HOME'] == '/home/distutils' + + util.check_environ.cache_clear() + os.environ.pop('HOME', None) + + # bpo-10496: Catch pwd.getpwuid() error + with mock.patch.object(pwd, 'getpwuid', side_effect=KeyError): + check_environ() + assert 'HOME' not in os.environ + + def test_split_quoted(self): + assert split_quoted('""one"" "two" \'three\' \\four') == [ + 'one', + 'two', + 'three', + 'four', + ] + + def test_strtobool(self): + yes = ('y', 'Y', 'yes', 'True', 't', 'true', 'True', 'On', 'on', '1') + no = ('n', 'no', 'f', 'false', 'off', '0', 'Off', 'No', 'N') + + for y in yes: + assert strtobool(y) + + for n in no: + assert not strtobool(n) + + indent = 8 * ' ' + + @pytest.mark.parametrize( + "given,wanted", + [ + # 0x0b, 0x0c, ..., etc are also considered a line break by Python + ("hello\x0b\nworld\n", f"hello\x0b{indent}\n{indent}world\n{indent}"), + ("hello\x1eworld", f"hello\x1e{indent}world"), + ("", ""), + ( + "I am a\npoor\nlonesome\nheader\n", + f"I am a\n{indent}poor\n{indent}lonesome\n{indent}header\n{indent}", + ), + ], + ) + def test_rfc822_escape(self, given, wanted): + """ + We want to ensure a multi-line header parses correctly. + + For interoperability, the escaped value should also "round-trip" over + `email.generator.Generator.flatten` and `email.message_from_*` + (see pypa/setuptools#4033). + + The main issue is that internally `email.policy.EmailPolicy` uses + `splitlines` which will split on some control chars. If all the new lines + are not prefixed with spaces, the parser will interrupt reading + the current header and produce an incomplete value, while + incorrectly interpreting the rest of the headers as part of the payload. + """ + res = rfc822_escape(given) + + policy = email.policy.EmailPolicy( + utf8=True, + mangle_from_=False, + max_line_length=0, + ) + with io.StringIO() as buffer: + raw = f"header: {res}\nother-header: 42\n\npayload\n" + orig = email.message_from_string(raw) + email.generator.Generator(buffer, policy=policy).flatten(orig) + buffer.seek(0) + regen = email.message_from_file(buffer) + + for msg in (orig, regen): + assert msg.get_payload() == "payload\n" + assert msg["other-header"] == "42" + # Generator may replace control chars with `\n` + assert set(msg["header"].splitlines()) == set(res.splitlines()) + + assert res == wanted + + def test_dont_write_bytecode(self): + # makes sure byte_compile raise a DistutilsError + # if sys.dont_write_bytecode is True + old_dont_write_bytecode = sys.dont_write_bytecode + sys.dont_write_bytecode = True + try: + with pytest.raises(DistutilsByteCompileError): + byte_compile([]) + finally: + sys.dont_write_bytecode = old_dont_write_bytecode + + def test_grok_environment_error(self): + # test obsolete function to ensure backward compat (#4931) + exc = OSError("Unable to find batch file") + msg = grok_environment_error(exc) + assert msg == "error: Unable to find batch file" diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_version.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_version.py new file mode 100644 index 0000000000000000000000000000000000000000..b68f0977249aa23aafbf31cf74a0e4127f777d05 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_version.py @@ -0,0 +1,80 @@ +"""Tests for distutils.version.""" + +import distutils +from distutils.version import LooseVersion, StrictVersion + +import pytest + + +@pytest.fixture(autouse=True) +def suppress_deprecation(): + with distutils.version.suppress_known_deprecation(): + yield + + +class TestVersion: + def test_prerelease(self): + version = StrictVersion('1.2.3a1') + assert version.version == (1, 2, 3) + assert version.prerelease == ('a', 1) + assert str(version) == '1.2.3a1' + + version = StrictVersion('1.2.0') + assert str(version) == '1.2' + + def test_cmp_strict(self): + versions = ( + ('1.5.1', '1.5.2b2', -1), + ('161', '3.10a', ValueError), + ('8.02', '8.02', 0), + ('3.4j', '1996.07.12', ValueError), + ('3.2.pl0', '3.1.1.6', ValueError), + ('2g6', '11g', ValueError), + ('0.9', '2.2', -1), + ('1.2.1', '1.2', 1), + ('1.1', '1.2.2', -1), + ('1.2', '1.1', 1), + ('1.2.1', '1.2.2', -1), + ('1.2.2', '1.2', 1), + ('1.2', '1.2.2', -1), + ('0.4.0', '0.4', 0), + ('1.13++', '5.5.kw', ValueError), + ) + + for v1, v2, wanted in versions: + try: + res = StrictVersion(v1)._cmp(StrictVersion(v2)) + except ValueError: + if wanted is ValueError: + continue + else: + raise AssertionError(f"cmp({v1}, {v2}) shouldn't raise ValueError") + assert res == wanted, f'cmp({v1}, {v2}) should be {wanted}, got {res}' + res = StrictVersion(v1)._cmp(v2) + assert res == wanted, f'cmp({v1}, {v2}) should be {wanted}, got {res}' + res = StrictVersion(v1)._cmp(object()) + assert res is NotImplemented, ( + f'cmp({v1}, {v2}) should be NotImplemented, got {res}' + ) + + def test_cmp(self): + versions = ( + ('1.5.1', '1.5.2b2', -1), + ('161', '3.10a', 1), + ('8.02', '8.02', 0), + ('3.4j', '1996.07.12', -1), + ('3.2.pl0', '3.1.1.6', 1), + ('2g6', '11g', -1), + ('0.960923', '2.2beta29', -1), + ('1.13++', '5.5.kw', -1), + ) + + for v1, v2, wanted in versions: + res = LooseVersion(v1)._cmp(LooseVersion(v2)) + assert res == wanted, f'cmp({v1}, {v2}) should be {wanted}, got {res}' + res = LooseVersion(v1)._cmp(v2) + assert res == wanted, f'cmp({v1}, {v2}) should be {wanted}, got {res}' + res = LooseVersion(v1)._cmp(object()) + assert res is NotImplemented, ( + f'cmp({v1}, {v2}) should be NotImplemented, got {res}' + ) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_versionpredicate.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/test_versionpredicate.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/unix_compat.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/unix_compat.py new file mode 100644 index 0000000000000000000000000000000000000000..a5d9ee45ccc639794d29ba0a5fd24f781ee5ecf5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_distutils/tests/unix_compat.py @@ -0,0 +1,17 @@ +import sys + +try: + import grp + import pwd +except ImportError: + grp = pwd = None + +import pytest + +UNIX_ID_SUPPORT = grp and pwd +UID_0_SUPPORT = UNIX_ID_SUPPORT and sys.platform != "cygwin" + +require_unix_id = pytest.mark.skipif( + not UNIX_ID_SUPPORT, reason="Requires grp and pwd support" +) +require_uid_0 = pytest.mark.skipif(not UID_0_SUPPORT, reason="Requires UID 0 support") diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/backports/tarfile/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/backports/tarfile/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..8c16881cb3ae1ea6e729b62bb2e5d625faa3f5fe --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/backports/tarfile/__init__.py @@ -0,0 +1,2937 @@ +#------------------------------------------------------------------- +# tarfile.py +#------------------------------------------------------------------- +# Copyright (C) 2002 Lars Gustaebel <lars@gustaebel.de> +# All rights reserved. +# +# Permission is hereby granted, free of charge, to any person +# obtaining a copy of this software and associated documentation +# files (the "Software"), to deal in the Software without +# restriction, including without limitation the rights to use, +# copy, modify, merge, publish, distribute, sublicense, and/or sell +# copies of the Software, and to permit persons to whom the +# Software is furnished to do so, subject to the following +# conditions: +# +# The above copyright notice and this permission notice shall be +# included in all copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +# OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +# HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +# WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +# OTHER DEALINGS IN THE SOFTWARE. +# +"""Read from and write to tar format archives. +""" + +version = "0.9.0" +__author__ = "Lars Gust\u00e4bel (lars@gustaebel.de)" +__credits__ = "Gustavo Niemeyer, Niels Gust\u00e4bel, Richard Townsend." + +#--------- +# Imports +#--------- +from builtins import open as bltn_open +import sys +import os +import io +import shutil +import stat +import time +import struct +import copy +import re + +from .compat.py38 import removesuffix + +try: + import pwd +except ImportError: + pwd = None +try: + import grp +except ImportError: + grp = None + +# os.symlink on Windows prior to 6.0 raises NotImplementedError +# OSError (winerror=1314) will be raised if the caller does not hold the +# SeCreateSymbolicLinkPrivilege privilege +symlink_exception = (AttributeError, NotImplementedError, OSError) + +# from tarfile import * +__all__ = ["TarFile", "TarInfo", "is_tarfile", "TarError", "ReadError", + "CompressionError", "StreamError", "ExtractError", "HeaderError", + "ENCODING", "USTAR_FORMAT", "GNU_FORMAT", "PAX_FORMAT", + "DEFAULT_FORMAT", "open","fully_trusted_filter", "data_filter", + "tar_filter", "FilterError", "AbsoluteLinkError", + "OutsideDestinationError", "SpecialFileError", "AbsolutePathError", + "LinkOutsideDestinationError"] + + +#--------------------------------------------------------- +# tar constants +#--------------------------------------------------------- +NUL = b"\0" # the null character +BLOCKSIZE = 512 # length of processing blocks +RECORDSIZE = BLOCKSIZE * 20 # length of records +GNU_MAGIC = b"ustar \0" # magic gnu tar string +POSIX_MAGIC = b"ustar\x0000" # magic posix tar string + +LENGTH_NAME = 100 # maximum length of a filename +LENGTH_LINK = 100 # maximum length of a linkname +LENGTH_PREFIX = 155 # maximum length of the prefix field + +REGTYPE = b"0" # regular file +AREGTYPE = b"\0" # regular file +LNKTYPE = b"1" # link (inside tarfile) +SYMTYPE = b"2" # symbolic link +CHRTYPE = b"3" # character special device +BLKTYPE = b"4" # block special device +DIRTYPE = b"5" # directory +FIFOTYPE = b"6" # fifo special device +CONTTYPE = b"7" # contiguous file + +GNUTYPE_LONGNAME = b"L" # GNU tar longname +GNUTYPE_LONGLINK = b"K" # GNU tar longlink +GNUTYPE_SPARSE = b"S" # GNU tar sparse file + +XHDTYPE = b"x" # POSIX.1-2001 extended header +XGLTYPE = b"g" # POSIX.1-2001 global header +SOLARIS_XHDTYPE = b"X" # Solaris extended header + +USTAR_FORMAT = 0 # POSIX.1-1988 (ustar) format +GNU_FORMAT = 1 # GNU tar format +PAX_FORMAT = 2 # POSIX.1-2001 (pax) format +DEFAULT_FORMAT = PAX_FORMAT + +#--------------------------------------------------------- +# tarfile constants +#--------------------------------------------------------- +# File types that tarfile supports: +SUPPORTED_TYPES = (REGTYPE, AREGTYPE, LNKTYPE, + SYMTYPE, DIRTYPE, FIFOTYPE, + CONTTYPE, CHRTYPE, BLKTYPE, + GNUTYPE_LONGNAME, GNUTYPE_LONGLINK, + GNUTYPE_SPARSE) + +# File types that will be treated as a regular file. +REGULAR_TYPES = (REGTYPE, AREGTYPE, + CONTTYPE, GNUTYPE_SPARSE) + +# File types that are part of the GNU tar format. +GNU_TYPES = (GNUTYPE_LONGNAME, GNUTYPE_LONGLINK, + GNUTYPE_SPARSE) + +# Fields from a pax header that override a TarInfo attribute. +PAX_FIELDS = ("path", "linkpath", "size", "mtime", + "uid", "gid", "uname", "gname") + +# Fields from a pax header that are affected by hdrcharset. +PAX_NAME_FIELDS = {"path", "linkpath", "uname", "gname"} + +# Fields in a pax header that are numbers, all other fields +# are treated as strings. +PAX_NUMBER_FIELDS = { + "atime": float, + "ctime": float, + "mtime": float, + "uid": int, + "gid": int, + "size": int +} + +#--------------------------------------------------------- +# initialization +#--------------------------------------------------------- +if os.name == "nt": + ENCODING = "utf-8" +else: + ENCODING = sys.getfilesystemencoding() + +#--------------------------------------------------------- +# Some useful functions +#--------------------------------------------------------- + +def stn(s, length, encoding, errors): + """Convert a string to a null-terminated bytes object. + """ + if s is None: + raise ValueError("metadata cannot contain None") + s = s.encode(encoding, errors) + return s[:length] + (length - len(s)) * NUL + +def nts(s, encoding, errors): + """Convert a null-terminated bytes object to a string. + """ + p = s.find(b"\0") + if p != -1: + s = s[:p] + return s.decode(encoding, errors) + +def nti(s): + """Convert a number field to a python number. + """ + # There are two possible encodings for a number field, see + # itn() below. + if s[0] in (0o200, 0o377): + n = 0 + for i in range(len(s) - 1): + n <<= 8 + n += s[i + 1] + if s[0] == 0o377: + n = -(256 ** (len(s) - 1) - n) + else: + try: + s = nts(s, "ascii", "strict") + n = int(s.strip() or "0", 8) + except ValueError: + raise InvalidHeaderError("invalid header") + return n + +def itn(n, digits=8, format=DEFAULT_FORMAT): + """Convert a python number to a number field. + """ + # POSIX 1003.1-1988 requires numbers to be encoded as a string of + # octal digits followed by a null-byte, this allows values up to + # (8**(digits-1))-1. GNU tar allows storing numbers greater than + # that if necessary. A leading 0o200 or 0o377 byte indicate this + # particular encoding, the following digits-1 bytes are a big-endian + # base-256 representation. This allows values up to (256**(digits-1))-1. + # A 0o200 byte indicates a positive number, a 0o377 byte a negative + # number. + original_n = n + n = int(n) + if 0 <= n < 8 ** (digits - 1): + s = bytes("%0*o" % (digits - 1, n), "ascii") + NUL + elif format == GNU_FORMAT and -256 ** (digits - 1) <= n < 256 ** (digits - 1): + if n >= 0: + s = bytearray([0o200]) + else: + s = bytearray([0o377]) + n = 256 ** digits + n + + for i in range(digits - 1): + s.insert(1, n & 0o377) + n >>= 8 + else: + raise ValueError("overflow in number field") + + return s + +def calc_chksums(buf): + """Calculate the checksum for a member's header by summing up all + characters except for the chksum field which is treated as if + it was filled with spaces. According to the GNU tar sources, + some tars (Sun and NeXT) calculate chksum with signed char, + which will be different if there are chars in the buffer with + the high bit set. So we calculate two checksums, unsigned and + signed. + """ + unsigned_chksum = 256 + sum(struct.unpack_from("148B8x356B", buf)) + signed_chksum = 256 + sum(struct.unpack_from("148b8x356b", buf)) + return unsigned_chksum, signed_chksum + +def copyfileobj(src, dst, length=None, exception=OSError, bufsize=None): + """Copy length bytes from fileobj src to fileobj dst. + If length is None, copy the entire content. + """ + bufsize = bufsize or 16 * 1024 + if length == 0: + return + if length is None: + shutil.copyfileobj(src, dst, bufsize) + return + + blocks, remainder = divmod(length, bufsize) + for b in range(blocks): + buf = src.read(bufsize) + if len(buf) < bufsize: + raise exception("unexpected end of data") + dst.write(buf) + + if remainder != 0: + buf = src.read(remainder) + if len(buf) < remainder: + raise exception("unexpected end of data") + dst.write(buf) + return + +def _safe_print(s): + encoding = getattr(sys.stdout, 'encoding', None) + if encoding is not None: + s = s.encode(encoding, 'backslashreplace').decode(encoding) + print(s, end=' ') + + +class TarError(Exception): + """Base exception.""" + pass +class ExtractError(TarError): + """General exception for extract errors.""" + pass +class ReadError(TarError): + """Exception for unreadable tar archives.""" + pass +class CompressionError(TarError): + """Exception for unavailable compression methods.""" + pass +class StreamError(TarError): + """Exception for unsupported operations on stream-like TarFiles.""" + pass +class HeaderError(TarError): + """Base exception for header errors.""" + pass +class EmptyHeaderError(HeaderError): + """Exception for empty headers.""" + pass +class TruncatedHeaderError(HeaderError): + """Exception for truncated headers.""" + pass +class EOFHeaderError(HeaderError): + """Exception for end of file headers.""" + pass +class InvalidHeaderError(HeaderError): + """Exception for invalid headers.""" + pass +class SubsequentHeaderError(HeaderError): + """Exception for missing and invalid extended headers.""" + pass + +#--------------------------- +# internal stream interface +#--------------------------- +class _LowLevelFile: + """Low-level file object. Supports reading and writing. + It is used instead of a regular file object for streaming + access. + """ + + def __init__(self, name, mode): + mode = { + "r": os.O_RDONLY, + "w": os.O_WRONLY | os.O_CREAT | os.O_TRUNC, + }[mode] + if hasattr(os, "O_BINARY"): + mode |= os.O_BINARY + self.fd = os.open(name, mode, 0o666) + + def close(self): + os.close(self.fd) + + def read(self, size): + return os.read(self.fd, size) + + def write(self, s): + os.write(self.fd, s) + +class _Stream: + """Class that serves as an adapter between TarFile and + a stream-like object. The stream-like object only + needs to have a read() or write() method that works with bytes, + and the method is accessed blockwise. + Use of gzip or bzip2 compression is possible. + A stream-like object could be for example: sys.stdin.buffer, + sys.stdout.buffer, a socket, a tape device etc. + + _Stream is intended to be used only internally. + """ + + def __init__(self, name, mode, comptype, fileobj, bufsize, + compresslevel): + """Construct a _Stream object. + """ + self._extfileobj = True + if fileobj is None: + fileobj = _LowLevelFile(name, mode) + self._extfileobj = False + + if comptype == '*': + # Enable transparent compression detection for the + # stream interface + fileobj = _StreamProxy(fileobj) + comptype = fileobj.getcomptype() + + self.name = name or "" + self.mode = mode + self.comptype = comptype + self.fileobj = fileobj + self.bufsize = bufsize + self.buf = b"" + self.pos = 0 + self.closed = False + + try: + if comptype == "gz": + try: + import zlib + except ImportError: + raise CompressionError("zlib module is not available") from None + self.zlib = zlib + self.crc = zlib.crc32(b"") + if mode == "r": + self.exception = zlib.error + self._init_read_gz() + else: + self._init_write_gz(compresslevel) + + elif comptype == "bz2": + try: + import bz2 + except ImportError: + raise CompressionError("bz2 module is not available") from None + if mode == "r": + self.dbuf = b"" + self.cmp = bz2.BZ2Decompressor() + self.exception = OSError + else: + self.cmp = bz2.BZ2Compressor(compresslevel) + + elif comptype == "xz": + try: + import lzma + except ImportError: + raise CompressionError("lzma module is not available") from None + if mode == "r": + self.dbuf = b"" + self.cmp = lzma.LZMADecompressor() + self.exception = lzma.LZMAError + else: + self.cmp = lzma.LZMACompressor() + + elif comptype != "tar": + raise CompressionError("unknown compression type %r" % comptype) + + except: + if not self._extfileobj: + self.fileobj.close() + self.closed = True + raise + + def __del__(self): + if hasattr(self, "closed") and not self.closed: + self.close() + + def _init_write_gz(self, compresslevel): + """Initialize for writing with gzip compression. + """ + self.cmp = self.zlib.compressobj(compresslevel, + self.zlib.DEFLATED, + -self.zlib.MAX_WBITS, + self.zlib.DEF_MEM_LEVEL, + 0) + timestamp = struct.pack("<L", int(time.time())) + self.__write(b"\037\213\010\010" + timestamp + b"\002\377") + if self.name.endswith(".gz"): + self.name = self.name[:-3] + # Honor "directory components removed" from RFC1952 + self.name = os.path.basename(self.name) + # RFC1952 says we must use ISO-8859-1 for the FNAME field. + self.__write(self.name.encode("iso-8859-1", "replace") + NUL) + + def write(self, s): + """Write string s to the stream. + """ + if self.comptype == "gz": + self.crc = self.zlib.crc32(s, self.crc) + self.pos += len(s) + if self.comptype != "tar": + s = self.cmp.compress(s) + self.__write(s) + + def __write(self, s): + """Write string s to the stream if a whole new block + is ready to be written. + """ + self.buf += s + while len(self.buf) > self.bufsize: + self.fileobj.write(self.buf[:self.bufsize]) + self.buf = self.buf[self.bufsize:] + + def close(self): + """Close the _Stream object. No operation should be + done on it afterwards. + """ + if self.closed: + return + + self.closed = True + try: + if self.mode == "w" and self.comptype != "tar": + self.buf += self.cmp.flush() + + if self.mode == "w" and self.buf: + self.fileobj.write(self.buf) + self.buf = b"" + if self.comptype == "gz": + self.fileobj.write(struct.pack("<L", self.crc)) + self.fileobj.write(struct.pack("<L", self.pos & 0xffffFFFF)) + finally: + if not self._extfileobj: + self.fileobj.close() + + def _init_read_gz(self): + """Initialize for reading a gzip compressed fileobj. + """ + self.cmp = self.zlib.decompressobj(-self.zlib.MAX_WBITS) + self.dbuf = b"" + + # taken from gzip.GzipFile with some alterations + if self.__read(2) != b"\037\213": + raise ReadError("not a gzip file") + if self.__read(1) != b"\010": + raise CompressionError("unsupported compression method") + + flag = ord(self.__read(1)) + self.__read(6) + + if flag & 4: + xlen = ord(self.__read(1)) + 256 * ord(self.__read(1)) + self.read(xlen) + if flag & 8: + while True: + s = self.__read(1) + if not s or s == NUL: + break + if flag & 16: + while True: + s = self.__read(1) + if not s or s == NUL: + break + if flag & 2: + self.__read(2) + + def tell(self): + """Return the stream's file pointer position. + """ + return self.pos + + def seek(self, pos=0): + """Set the stream's file pointer to pos. Negative seeking + is forbidden. + """ + if pos - self.pos >= 0: + blocks, remainder = divmod(pos - self.pos, self.bufsize) + for i in range(blocks): + self.read(self.bufsize) + self.read(remainder) + else: + raise StreamError("seeking backwards is not allowed") + return self.pos + + def read(self, size): + """Return the next size number of bytes from the stream.""" + assert size is not None + buf = self._read(size) + self.pos += len(buf) + return buf + + def _read(self, size): + """Return size bytes from the stream. + """ + if self.comptype == "tar": + return self.__read(size) + + c = len(self.dbuf) + t = [self.dbuf] + while c < size: + # Skip underlying buffer to avoid unaligned double buffering. + if self.buf: + buf = self.buf + self.buf = b"" + else: + buf = self.fileobj.read(self.bufsize) + if not buf: + break + try: + buf = self.cmp.decompress(buf) + except self.exception as e: + raise ReadError("invalid compressed data") from e + t.append(buf) + c += len(buf) + t = b"".join(t) + self.dbuf = t[size:] + return t[:size] + + def __read(self, size): + """Return size bytes from stream. If internal buffer is empty, + read another block from the stream. + """ + c = len(self.buf) + t = [self.buf] + while c < size: + buf = self.fileobj.read(self.bufsize) + if not buf: + break + t.append(buf) + c += len(buf) + t = b"".join(t) + self.buf = t[size:] + return t[:size] +# class _Stream + +class _StreamProxy(object): + """Small proxy class that enables transparent compression + detection for the Stream interface (mode 'r|*'). + """ + + def __init__(self, fileobj): + self.fileobj = fileobj + self.buf = self.fileobj.read(BLOCKSIZE) + + def read(self, size): + self.read = self.fileobj.read + return self.buf + + def getcomptype(self): + if self.buf.startswith(b"\x1f\x8b\x08"): + return "gz" + elif self.buf[0:3] == b"BZh" and self.buf[4:10] == b"1AY&SY": + return "bz2" + elif self.buf.startswith((b"\x5d\x00\x00\x80", b"\xfd7zXZ")): + return "xz" + else: + return "tar" + + def close(self): + self.fileobj.close() +# class StreamProxy + +#------------------------ +# Extraction file object +#------------------------ +class _FileInFile(object): + """A thin wrapper around an existing file object that + provides a part of its data as an individual file + object. + """ + + def __init__(self, fileobj, offset, size, name, blockinfo=None): + self.fileobj = fileobj + self.offset = offset + self.size = size + self.position = 0 + self.name = name + self.closed = False + + if blockinfo is None: + blockinfo = [(0, size)] + + # Construct a map with data and zero blocks. + self.map_index = 0 + self.map = [] + lastpos = 0 + realpos = self.offset + for offset, size in blockinfo: + if offset > lastpos: + self.map.append((False, lastpos, offset, None)) + self.map.append((True, offset, offset + size, realpos)) + realpos += size + lastpos = offset + size + if lastpos < self.size: + self.map.append((False, lastpos, self.size, None)) + + def flush(self): + pass + + @property + def mode(self): + return 'rb' + + def readable(self): + return True + + def writable(self): + return False + + def seekable(self): + return self.fileobj.seekable() + + def tell(self): + """Return the current file position. + """ + return self.position + + def seek(self, position, whence=io.SEEK_SET): + """Seek to a position in the file. + """ + if whence == io.SEEK_SET: + self.position = min(max(position, 0), self.size) + elif whence == io.SEEK_CUR: + if position < 0: + self.position = max(self.position + position, 0) + else: + self.position = min(self.position + position, self.size) + elif whence == io.SEEK_END: + self.position = max(min(self.size + position, self.size), 0) + else: + raise ValueError("Invalid argument") + return self.position + + def read(self, size=None): + """Read data from the file. + """ + if size is None: + size = self.size - self.position + else: + size = min(size, self.size - self.position) + + buf = b"" + while size > 0: + while True: + data, start, stop, offset = self.map[self.map_index] + if start <= self.position < stop: + break + else: + self.map_index += 1 + if self.map_index == len(self.map): + self.map_index = 0 + length = min(size, stop - self.position) + if data: + self.fileobj.seek(offset + (self.position - start)) + b = self.fileobj.read(length) + if len(b) != length: + raise ReadError("unexpected end of data") + buf += b + else: + buf += NUL * length + size -= length + self.position += length + return buf + + def readinto(self, b): + buf = self.read(len(b)) + b[:len(buf)] = buf + return len(buf) + + def close(self): + self.closed = True +#class _FileInFile + +class ExFileObject(io.BufferedReader): + + def __init__(self, tarfile, tarinfo): + fileobj = _FileInFile(tarfile.fileobj, tarinfo.offset_data, + tarinfo.size, tarinfo.name, tarinfo.sparse) + super().__init__(fileobj) +#class ExFileObject + + +#----------------------------- +# extraction filters (PEP 706) +#----------------------------- + +class FilterError(TarError): + pass + +class AbsolutePathError(FilterError): + def __init__(self, tarinfo): + self.tarinfo = tarinfo + super().__init__(f'member {tarinfo.name!r} has an absolute path') + +class OutsideDestinationError(FilterError): + def __init__(self, tarinfo, path): + self.tarinfo = tarinfo + self._path = path + super().__init__(f'{tarinfo.name!r} would be extracted to {path!r}, ' + + 'which is outside the destination') + +class SpecialFileError(FilterError): + def __init__(self, tarinfo): + self.tarinfo = tarinfo + super().__init__(f'{tarinfo.name!r} is a special file') + +class AbsoluteLinkError(FilterError): + def __init__(self, tarinfo): + self.tarinfo = tarinfo + super().__init__(f'{tarinfo.name!r} is a link to an absolute path') + +class LinkOutsideDestinationError(FilterError): + def __init__(self, tarinfo, path): + self.tarinfo = tarinfo + self._path = path + super().__init__(f'{tarinfo.name!r} would link to {path!r}, ' + + 'which is outside the destination') + +def _get_filtered_attrs(member, dest_path, for_data=True): + new_attrs = {} + name = member.name + dest_path = os.path.realpath(dest_path) + # Strip leading / (tar's directory separator) from filenames. + # Include os.sep (target OS directory separator) as well. + if name.startswith(('/', os.sep)): + name = new_attrs['name'] = member.path.lstrip('/' + os.sep) + if os.path.isabs(name): + # Path is absolute even after stripping. + # For example, 'C:/foo' on Windows. + raise AbsolutePathError(member) + # Ensure we stay in the destination + target_path = os.path.realpath(os.path.join(dest_path, name)) + if os.path.commonpath([target_path, dest_path]) != dest_path: + raise OutsideDestinationError(member, target_path) + # Limit permissions (no high bits, and go-w) + mode = member.mode + if mode is not None: + # Strip high bits & group/other write bits + mode = mode & 0o755 + if for_data: + # For data, handle permissions & file types + if member.isreg() or member.islnk(): + if not mode & 0o100: + # Clear executable bits if not executable by user + mode &= ~0o111 + # Ensure owner can read & write + mode |= 0o600 + elif member.isdir() or member.issym(): + # Ignore mode for directories & symlinks + mode = None + else: + # Reject special files + raise SpecialFileError(member) + if mode != member.mode: + new_attrs['mode'] = mode + if for_data: + # Ignore ownership for 'data' + if member.uid is not None: + new_attrs['uid'] = None + if member.gid is not None: + new_attrs['gid'] = None + if member.uname is not None: + new_attrs['uname'] = None + if member.gname is not None: + new_attrs['gname'] = None + # Check link destination for 'data' + if member.islnk() or member.issym(): + if os.path.isabs(member.linkname): + raise AbsoluteLinkError(member) + if member.issym(): + target_path = os.path.join(dest_path, + os.path.dirname(name), + member.linkname) + else: + target_path = os.path.join(dest_path, + member.linkname) + target_path = os.path.realpath(target_path) + if os.path.commonpath([target_path, dest_path]) != dest_path: + raise LinkOutsideDestinationError(member, target_path) + return new_attrs + +def fully_trusted_filter(member, dest_path): + return member + +def tar_filter(member, dest_path): + new_attrs = _get_filtered_attrs(member, dest_path, False) + if new_attrs: + return member.replace(**new_attrs, deep=False) + return member + +def data_filter(member, dest_path): + new_attrs = _get_filtered_attrs(member, dest_path, True) + if new_attrs: + return member.replace(**new_attrs, deep=False) + return member + +_NAMED_FILTERS = { + "fully_trusted": fully_trusted_filter, + "tar": tar_filter, + "data": data_filter, +} + +#------------------ +# Exported Classes +#------------------ + +# Sentinel for replace() defaults, meaning "don't change the attribute" +_KEEP = object() + +class TarInfo(object): + """Informational class which holds the details about an + archive member given by a tar header block. + TarInfo objects are returned by TarFile.getmember(), + TarFile.getmembers() and TarFile.gettarinfo() and are + usually created internally. + """ + + __slots__ = dict( + name = 'Name of the archive member.', + mode = 'Permission bits.', + uid = 'User ID of the user who originally stored this member.', + gid = 'Group ID of the user who originally stored this member.', + size = 'Size in bytes.', + mtime = 'Time of last modification.', + chksum = 'Header checksum.', + type = ('File type. type is usually one of these constants: ' + 'REGTYPE, AREGTYPE, LNKTYPE, SYMTYPE, DIRTYPE, FIFOTYPE, ' + 'CONTTYPE, CHRTYPE, BLKTYPE, GNUTYPE_SPARSE.'), + linkname = ('Name of the target file name, which is only present ' + 'in TarInfo objects of type LNKTYPE and SYMTYPE.'), + uname = 'User name.', + gname = 'Group name.', + devmajor = 'Device major number.', + devminor = 'Device minor number.', + offset = 'The tar header starts here.', + offset_data = "The file's data starts here.", + pax_headers = ('A dictionary containing key-value pairs of an ' + 'associated pax extended header.'), + sparse = 'Sparse member information.', + _tarfile = None, + _sparse_structs = None, + _link_target = None, + ) + + def __init__(self, name=""): + """Construct a TarInfo object. name is the optional name + of the member. + """ + self.name = name # member name + self.mode = 0o644 # file permissions + self.uid = 0 # user id + self.gid = 0 # group id + self.size = 0 # file size + self.mtime = 0 # modification time + self.chksum = 0 # header checksum + self.type = REGTYPE # member type + self.linkname = "" # link name + self.uname = "" # user name + self.gname = "" # group name + self.devmajor = 0 # device major number + self.devminor = 0 # device minor number + + self.offset = 0 # the tar header starts here + self.offset_data = 0 # the file's data starts here + + self.sparse = None # sparse member information + self.pax_headers = {} # pax header information + + @property + def tarfile(self): + import warnings + warnings.warn( + 'The undocumented "tarfile" attribute of TarInfo objects ' + + 'is deprecated and will be removed in Python 3.16', + DeprecationWarning, stacklevel=2) + return self._tarfile + + @tarfile.setter + def tarfile(self, tarfile): + import warnings + warnings.warn( + 'The undocumented "tarfile" attribute of TarInfo objects ' + + 'is deprecated and will be removed in Python 3.16', + DeprecationWarning, stacklevel=2) + self._tarfile = tarfile + + @property + def path(self): + 'In pax headers, "name" is called "path".' + return self.name + + @path.setter + def path(self, name): + self.name = name + + @property + def linkpath(self): + 'In pax headers, "linkname" is called "linkpath".' + return self.linkname + + @linkpath.setter + def linkpath(self, linkname): + self.linkname = linkname + + def __repr__(self): + return "<%s %r at %#x>" % (self.__class__.__name__,self.name,id(self)) + + def replace(self, *, + name=_KEEP, mtime=_KEEP, mode=_KEEP, linkname=_KEEP, + uid=_KEEP, gid=_KEEP, uname=_KEEP, gname=_KEEP, + deep=True, _KEEP=_KEEP): + """Return a deep copy of self with the given attributes replaced. + """ + if deep: + result = copy.deepcopy(self) + else: + result = copy.copy(self) + if name is not _KEEP: + result.name = name + if mtime is not _KEEP: + result.mtime = mtime + if mode is not _KEEP: + result.mode = mode + if linkname is not _KEEP: + result.linkname = linkname + if uid is not _KEEP: + result.uid = uid + if gid is not _KEEP: + result.gid = gid + if uname is not _KEEP: + result.uname = uname + if gname is not _KEEP: + result.gname = gname + return result + + def get_info(self): + """Return the TarInfo's attributes as a dictionary. + """ + if self.mode is None: + mode = None + else: + mode = self.mode & 0o7777 + info = { + "name": self.name, + "mode": mode, + "uid": self.uid, + "gid": self.gid, + "size": self.size, + "mtime": self.mtime, + "chksum": self.chksum, + "type": self.type, + "linkname": self.linkname, + "uname": self.uname, + "gname": self.gname, + "devmajor": self.devmajor, + "devminor": self.devminor + } + + if info["type"] == DIRTYPE and not info["name"].endswith("/"): + info["name"] += "/" + + return info + + def tobuf(self, format=DEFAULT_FORMAT, encoding=ENCODING, errors="surrogateescape"): + """Return a tar header as a string of 512 byte blocks. + """ + info = self.get_info() + for name, value in info.items(): + if value is None: + raise ValueError("%s may not be None" % name) + + if format == USTAR_FORMAT: + return self.create_ustar_header(info, encoding, errors) + elif format == GNU_FORMAT: + return self.create_gnu_header(info, encoding, errors) + elif format == PAX_FORMAT: + return self.create_pax_header(info, encoding) + else: + raise ValueError("invalid format") + + def create_ustar_header(self, info, encoding, errors): + """Return the object as a ustar header block. + """ + info["magic"] = POSIX_MAGIC + + if len(info["linkname"].encode(encoding, errors)) > LENGTH_LINK: + raise ValueError("linkname is too long") + + if len(info["name"].encode(encoding, errors)) > LENGTH_NAME: + info["prefix"], info["name"] = self._posix_split_name(info["name"], encoding, errors) + + return self._create_header(info, USTAR_FORMAT, encoding, errors) + + def create_gnu_header(self, info, encoding, errors): + """Return the object as a GNU header block sequence. + """ + info["magic"] = GNU_MAGIC + + buf = b"" + if len(info["linkname"].encode(encoding, errors)) > LENGTH_LINK: + buf += self._create_gnu_long_header(info["linkname"], GNUTYPE_LONGLINK, encoding, errors) + + if len(info["name"].encode(encoding, errors)) > LENGTH_NAME: + buf += self._create_gnu_long_header(info["name"], GNUTYPE_LONGNAME, encoding, errors) + + return buf + self._create_header(info, GNU_FORMAT, encoding, errors) + + def create_pax_header(self, info, encoding): + """Return the object as a ustar header block. If it cannot be + represented this way, prepend a pax extended header sequence + with supplement information. + """ + info["magic"] = POSIX_MAGIC + pax_headers = self.pax_headers.copy() + + # Test string fields for values that exceed the field length or cannot + # be represented in ASCII encoding. + for name, hname, length in ( + ("name", "path", LENGTH_NAME), ("linkname", "linkpath", LENGTH_LINK), + ("uname", "uname", 32), ("gname", "gname", 32)): + + if hname in pax_headers: + # The pax header has priority. + continue + + # Try to encode the string as ASCII. + try: + info[name].encode("ascii", "strict") + except UnicodeEncodeError: + pax_headers[hname] = info[name] + continue + + if len(info[name]) > length: + pax_headers[hname] = info[name] + + # Test number fields for values that exceed the field limit or values + # that like to be stored as float. + for name, digits in (("uid", 8), ("gid", 8), ("size", 12), ("mtime", 12)): + needs_pax = False + + val = info[name] + val_is_float = isinstance(val, float) + val_int = round(val) if val_is_float else val + if not 0 <= val_int < 8 ** (digits - 1): + # Avoid overflow. + info[name] = 0 + needs_pax = True + elif val_is_float: + # Put rounded value in ustar header, and full + # precision value in pax header. + info[name] = val_int + needs_pax = True + + # The existing pax header has priority. + if needs_pax and name not in pax_headers: + pax_headers[name] = str(val) + + # Create a pax extended header if necessary. + if pax_headers: + buf = self._create_pax_generic_header(pax_headers, XHDTYPE, encoding) + else: + buf = b"" + + return buf + self._create_header(info, USTAR_FORMAT, "ascii", "replace") + + @classmethod + def create_pax_global_header(cls, pax_headers): + """Return the object as a pax global header block sequence. + """ + return cls._create_pax_generic_header(pax_headers, XGLTYPE, "utf-8") + + def _posix_split_name(self, name, encoding, errors): + """Split a name longer than 100 chars into a prefix + and a name part. + """ + components = name.split("/") + for i in range(1, len(components)): + prefix = "/".join(components[:i]) + name = "/".join(components[i:]) + if len(prefix.encode(encoding, errors)) <= LENGTH_PREFIX and \ + len(name.encode(encoding, errors)) <= LENGTH_NAME: + break + else: + raise ValueError("name is too long") + + return prefix, name + + @staticmethod + def _create_header(info, format, encoding, errors): + """Return a header block. info is a dictionary with file + information, format must be one of the *_FORMAT constants. + """ + has_device_fields = info.get("type") in (CHRTYPE, BLKTYPE) + if has_device_fields: + devmajor = itn(info.get("devmajor", 0), 8, format) + devminor = itn(info.get("devminor", 0), 8, format) + else: + devmajor = stn("", 8, encoding, errors) + devminor = stn("", 8, encoding, errors) + + # None values in metadata should cause ValueError. + # itn()/stn() do this for all fields except type. + filetype = info.get("type", REGTYPE) + if filetype is None: + raise ValueError("TarInfo.type must not be None") + + parts = [ + stn(info.get("name", ""), 100, encoding, errors), + itn(info.get("mode", 0) & 0o7777, 8, format), + itn(info.get("uid", 0), 8, format), + itn(info.get("gid", 0), 8, format), + itn(info.get("size", 0), 12, format), + itn(info.get("mtime", 0), 12, format), + b" ", # checksum field + filetype, + stn(info.get("linkname", ""), 100, encoding, errors), + info.get("magic", POSIX_MAGIC), + stn(info.get("uname", ""), 32, encoding, errors), + stn(info.get("gname", ""), 32, encoding, errors), + devmajor, + devminor, + stn(info.get("prefix", ""), 155, encoding, errors) + ] + + buf = struct.pack("%ds" % BLOCKSIZE, b"".join(parts)) + chksum = calc_chksums(buf[-BLOCKSIZE:])[0] + buf = buf[:-364] + bytes("%06o\0" % chksum, "ascii") + buf[-357:] + return buf + + @staticmethod + def _create_payload(payload): + """Return the string payload filled with zero bytes + up to the next 512 byte border. + """ + blocks, remainder = divmod(len(payload), BLOCKSIZE) + if remainder > 0: + payload += (BLOCKSIZE - remainder) * NUL + return payload + + @classmethod + def _create_gnu_long_header(cls, name, type, encoding, errors): + """Return a GNUTYPE_LONGNAME or GNUTYPE_LONGLINK sequence + for name. + """ + name = name.encode(encoding, errors) + NUL + + info = {} + info["name"] = "././@LongLink" + info["type"] = type + info["size"] = len(name) + info["magic"] = GNU_MAGIC + + # create extended header + name blocks. + return cls._create_header(info, USTAR_FORMAT, encoding, errors) + \ + cls._create_payload(name) + + @classmethod + def _create_pax_generic_header(cls, pax_headers, type, encoding): + """Return a POSIX.1-2008 extended or global header sequence + that contains a list of keyword, value pairs. The values + must be strings. + """ + # Check if one of the fields contains surrogate characters and thereby + # forces hdrcharset=BINARY, see _proc_pax() for more information. + binary = False + for keyword, value in pax_headers.items(): + try: + value.encode("utf-8", "strict") + except UnicodeEncodeError: + binary = True + break + + records = b"" + if binary: + # Put the hdrcharset field at the beginning of the header. + records += b"21 hdrcharset=BINARY\n" + + for keyword, value in pax_headers.items(): + keyword = keyword.encode("utf-8") + if binary: + # Try to restore the original byte representation of 'value'. + # Needless to say, that the encoding must match the string. + value = value.encode(encoding, "surrogateescape") + else: + value = value.encode("utf-8") + + l = len(keyword) + len(value) + 3 # ' ' + '=' + '\n' + n = p = 0 + while True: + n = l + len(str(p)) + if n == p: + break + p = n + records += bytes(str(p), "ascii") + b" " + keyword + b"=" + value + b"\n" + + # We use a hardcoded "././@PaxHeader" name like star does + # instead of the one that POSIX recommends. + info = {} + info["name"] = "././@PaxHeader" + info["type"] = type + info["size"] = len(records) + info["magic"] = POSIX_MAGIC + + # Create pax header + record blocks. + return cls._create_header(info, USTAR_FORMAT, "ascii", "replace") + \ + cls._create_payload(records) + + @classmethod + def frombuf(cls, buf, encoding, errors): + """Construct a TarInfo object from a 512 byte bytes object. + """ + if len(buf) == 0: + raise EmptyHeaderError("empty header") + if len(buf) != BLOCKSIZE: + raise TruncatedHeaderError("truncated header") + if buf.count(NUL) == BLOCKSIZE: + raise EOFHeaderError("end of file header") + + chksum = nti(buf[148:156]) + if chksum not in calc_chksums(buf): + raise InvalidHeaderError("bad checksum") + + obj = cls() + obj.name = nts(buf[0:100], encoding, errors) + obj.mode = nti(buf[100:108]) + obj.uid = nti(buf[108:116]) + obj.gid = nti(buf[116:124]) + obj.size = nti(buf[124:136]) + obj.mtime = nti(buf[136:148]) + obj.chksum = chksum + obj.type = buf[156:157] + obj.linkname = nts(buf[157:257], encoding, errors) + obj.uname = nts(buf[265:297], encoding, errors) + obj.gname = nts(buf[297:329], encoding, errors) + obj.devmajor = nti(buf[329:337]) + obj.devminor = nti(buf[337:345]) + prefix = nts(buf[345:500], encoding, errors) + + # Old V7 tar format represents a directory as a regular + # file with a trailing slash. + if obj.type == AREGTYPE and obj.name.endswith("/"): + obj.type = DIRTYPE + + # The old GNU sparse format occupies some of the unused + # space in the buffer for up to 4 sparse structures. + # Save them for later processing in _proc_sparse(). + if obj.type == GNUTYPE_SPARSE: + pos = 386 + structs = [] + for i in range(4): + try: + offset = nti(buf[pos:pos + 12]) + numbytes = nti(buf[pos + 12:pos + 24]) + except ValueError: + break + structs.append((offset, numbytes)) + pos += 24 + isextended = bool(buf[482]) + origsize = nti(buf[483:495]) + obj._sparse_structs = (structs, isextended, origsize) + + # Remove redundant slashes from directories. + if obj.isdir(): + obj.name = obj.name.rstrip("/") + + # Reconstruct a ustar longname. + if prefix and obj.type not in GNU_TYPES: + obj.name = prefix + "/" + obj.name + return obj + + @classmethod + def fromtarfile(cls, tarfile): + """Return the next TarInfo object from TarFile object + tarfile. + """ + buf = tarfile.fileobj.read(BLOCKSIZE) + obj = cls.frombuf(buf, tarfile.encoding, tarfile.errors) + obj.offset = tarfile.fileobj.tell() - BLOCKSIZE + return obj._proc_member(tarfile) + + #-------------------------------------------------------------------------- + # The following are methods that are called depending on the type of a + # member. The entry point is _proc_member() which can be overridden in a + # subclass to add custom _proc_*() methods. A _proc_*() method MUST + # implement the following + # operations: + # 1. Set self.offset_data to the position where the data blocks begin, + # if there is data that follows. + # 2. Set tarfile.offset to the position where the next member's header will + # begin. + # 3. Return self or another valid TarInfo object. + def _proc_member(self, tarfile): + """Choose the right processing method depending on + the type and call it. + """ + if self.type in (GNUTYPE_LONGNAME, GNUTYPE_LONGLINK): + return self._proc_gnulong(tarfile) + elif self.type == GNUTYPE_SPARSE: + return self._proc_sparse(tarfile) + elif self.type in (XHDTYPE, XGLTYPE, SOLARIS_XHDTYPE): + return self._proc_pax(tarfile) + else: + return self._proc_builtin(tarfile) + + def _proc_builtin(self, tarfile): + """Process a builtin type or an unknown type which + will be treated as a regular file. + """ + self.offset_data = tarfile.fileobj.tell() + offset = self.offset_data + if self.isreg() or self.type not in SUPPORTED_TYPES: + # Skip the following data blocks. + offset += self._block(self.size) + tarfile.offset = offset + + # Patch the TarInfo object with saved global + # header information. + self._apply_pax_info(tarfile.pax_headers, tarfile.encoding, tarfile.errors) + + # Remove redundant slashes from directories. This is to be consistent + # with frombuf(). + if self.isdir(): + self.name = self.name.rstrip("/") + + return self + + def _proc_gnulong(self, tarfile): + """Process the blocks that hold a GNU longname + or longlink member. + """ + buf = tarfile.fileobj.read(self._block(self.size)) + + # Fetch the next header and process it. + try: + next = self.fromtarfile(tarfile) + except HeaderError as e: + raise SubsequentHeaderError(str(e)) from None + + # Patch the TarInfo object from the next header with + # the longname information. + next.offset = self.offset + if self.type == GNUTYPE_LONGNAME: + next.name = nts(buf, tarfile.encoding, tarfile.errors) + elif self.type == GNUTYPE_LONGLINK: + next.linkname = nts(buf, tarfile.encoding, tarfile.errors) + + # Remove redundant slashes from directories. This is to be consistent + # with frombuf(). + if next.isdir(): + next.name = removesuffix(next.name, "/") + + return next + + def _proc_sparse(self, tarfile): + """Process a GNU sparse header plus extra headers. + """ + # We already collected some sparse structures in frombuf(). + structs, isextended, origsize = self._sparse_structs + del self._sparse_structs + + # Collect sparse structures from extended header blocks. + while isextended: + buf = tarfile.fileobj.read(BLOCKSIZE) + pos = 0 + for i in range(21): + try: + offset = nti(buf[pos:pos + 12]) + numbytes = nti(buf[pos + 12:pos + 24]) + except ValueError: + break + if offset and numbytes: + structs.append((offset, numbytes)) + pos += 24 + isextended = bool(buf[504]) + self.sparse = structs + + self.offset_data = tarfile.fileobj.tell() + tarfile.offset = self.offset_data + self._block(self.size) + self.size = origsize + return self + + def _proc_pax(self, tarfile): + """Process an extended or global header as described in + POSIX.1-2008. + """ + # Read the header information. + buf = tarfile.fileobj.read(self._block(self.size)) + + # A pax header stores supplemental information for either + # the following file (extended) or all following files + # (global). + if self.type == XGLTYPE: + pax_headers = tarfile.pax_headers + else: + pax_headers = tarfile.pax_headers.copy() + + # Check if the pax header contains a hdrcharset field. This tells us + # the encoding of the path, linkpath, uname and gname fields. Normally, + # these fields are UTF-8 encoded but since POSIX.1-2008 tar + # implementations are allowed to store them as raw binary strings if + # the translation to UTF-8 fails. + match = re.search(br"\d+ hdrcharset=([^\n]+)\n", buf) + if match is not None: + pax_headers["hdrcharset"] = match.group(1).decode("utf-8") + + # For the time being, we don't care about anything other than "BINARY". + # The only other value that is currently allowed by the standard is + # "ISO-IR 10646 2000 UTF-8" in other words UTF-8. + hdrcharset = pax_headers.get("hdrcharset") + if hdrcharset == "BINARY": + encoding = tarfile.encoding + else: + encoding = "utf-8" + + # Parse pax header information. A record looks like that: + # "%d %s=%s\n" % (length, keyword, value). length is the size + # of the complete record including the length field itself and + # the newline. keyword and value are both UTF-8 encoded strings. + regex = re.compile(br"(\d+) ([^=]+)=") + pos = 0 + while match := regex.match(buf, pos): + length, keyword = match.groups() + length = int(length) + if length == 0: + raise InvalidHeaderError("invalid header") + value = buf[match.end(2) + 1:match.start(1) + length - 1] + + # Normally, we could just use "utf-8" as the encoding and "strict" + # as the error handler, but we better not take the risk. For + # example, GNU tar <= 1.23 is known to store filenames it cannot + # translate to UTF-8 as raw strings (unfortunately without a + # hdrcharset=BINARY header). + # We first try the strict standard encoding, and if that fails we + # fall back on the user's encoding and error handler. + keyword = self._decode_pax_field(keyword, "utf-8", "utf-8", + tarfile.errors) + if keyword in PAX_NAME_FIELDS: + value = self._decode_pax_field(value, encoding, tarfile.encoding, + tarfile.errors) + else: + value = self._decode_pax_field(value, "utf-8", "utf-8", + tarfile.errors) + + pax_headers[keyword] = value + pos += length + + # Fetch the next header. + try: + next = self.fromtarfile(tarfile) + except HeaderError as e: + raise SubsequentHeaderError(str(e)) from None + + # Process GNU sparse information. + if "GNU.sparse.map" in pax_headers: + # GNU extended sparse format version 0.1. + self._proc_gnusparse_01(next, pax_headers) + + elif "GNU.sparse.size" in pax_headers: + # GNU extended sparse format version 0.0. + self._proc_gnusparse_00(next, pax_headers, buf) + + elif pax_headers.get("GNU.sparse.major") == "1" and pax_headers.get("GNU.sparse.minor") == "0": + # GNU extended sparse format version 1.0. + self._proc_gnusparse_10(next, pax_headers, tarfile) + + if self.type in (XHDTYPE, SOLARIS_XHDTYPE): + # Patch the TarInfo object with the extended header info. + next._apply_pax_info(pax_headers, tarfile.encoding, tarfile.errors) + next.offset = self.offset + + if "size" in pax_headers: + # If the extended header replaces the size field, + # we need to recalculate the offset where the next + # header starts. + offset = next.offset_data + if next.isreg() or next.type not in SUPPORTED_TYPES: + offset += next._block(next.size) + tarfile.offset = offset + + return next + + def _proc_gnusparse_00(self, next, pax_headers, buf): + """Process a GNU tar extended sparse header, version 0.0. + """ + offsets = [] + for match in re.finditer(br"\d+ GNU.sparse.offset=(\d+)\n", buf): + offsets.append(int(match.group(1))) + numbytes = [] + for match in re.finditer(br"\d+ GNU.sparse.numbytes=(\d+)\n", buf): + numbytes.append(int(match.group(1))) + next.sparse = list(zip(offsets, numbytes)) + + def _proc_gnusparse_01(self, next, pax_headers): + """Process a GNU tar extended sparse header, version 0.1. + """ + sparse = [int(x) for x in pax_headers["GNU.sparse.map"].split(",")] + next.sparse = list(zip(sparse[::2], sparse[1::2])) + + def _proc_gnusparse_10(self, next, pax_headers, tarfile): + """Process a GNU tar extended sparse header, version 1.0. + """ + fields = None + sparse = [] + buf = tarfile.fileobj.read(BLOCKSIZE) + fields, buf = buf.split(b"\n", 1) + fields = int(fields) + while len(sparse) < fields * 2: + if b"\n" not in buf: + buf += tarfile.fileobj.read(BLOCKSIZE) + number, buf = buf.split(b"\n", 1) + sparse.append(int(number)) + next.offset_data = tarfile.fileobj.tell() + next.sparse = list(zip(sparse[::2], sparse[1::2])) + + def _apply_pax_info(self, pax_headers, encoding, errors): + """Replace fields with supplemental information from a previous + pax extended or global header. + """ + for keyword, value in pax_headers.items(): + if keyword == "GNU.sparse.name": + setattr(self, "path", value) + elif keyword == "GNU.sparse.size": + setattr(self, "size", int(value)) + elif keyword == "GNU.sparse.realsize": + setattr(self, "size", int(value)) + elif keyword in PAX_FIELDS: + if keyword in PAX_NUMBER_FIELDS: + try: + value = PAX_NUMBER_FIELDS[keyword](value) + except ValueError: + value = 0 + if keyword == "path": + value = value.rstrip("/") + setattr(self, keyword, value) + + self.pax_headers = pax_headers.copy() + + def _decode_pax_field(self, value, encoding, fallback_encoding, fallback_errors): + """Decode a single field from a pax record. + """ + try: + return value.decode(encoding, "strict") + except UnicodeDecodeError: + return value.decode(fallback_encoding, fallback_errors) + + def _block(self, count): + """Round up a byte count by BLOCKSIZE and return it, + e.g. _block(834) => 1024. + """ + blocks, remainder = divmod(count, BLOCKSIZE) + if remainder: + blocks += 1 + return blocks * BLOCKSIZE + + def isreg(self): + 'Return True if the Tarinfo object is a regular file.' + return self.type in REGULAR_TYPES + + def isfile(self): + 'Return True if the Tarinfo object is a regular file.' + return self.isreg() + + def isdir(self): + 'Return True if it is a directory.' + return self.type == DIRTYPE + + def issym(self): + 'Return True if it is a symbolic link.' + return self.type == SYMTYPE + + def islnk(self): + 'Return True if it is a hard link.' + return self.type == LNKTYPE + + def ischr(self): + 'Return True if it is a character device.' + return self.type == CHRTYPE + + def isblk(self): + 'Return True if it is a block device.' + return self.type == BLKTYPE + + def isfifo(self): + 'Return True if it is a FIFO.' + return self.type == FIFOTYPE + + def issparse(self): + return self.sparse is not None + + def isdev(self): + 'Return True if it is one of character device, block device or FIFO.' + return self.type in (CHRTYPE, BLKTYPE, FIFOTYPE) +# class TarInfo + +class TarFile(object): + """The TarFile Class provides an interface to tar archives. + """ + + debug = 0 # May be set from 0 (no msgs) to 3 (all msgs) + + dereference = False # If true, add content of linked file to the + # tar file, else the link. + + ignore_zeros = False # If true, skips empty or invalid blocks and + # continues processing. + + errorlevel = 1 # If 0, fatal errors only appear in debug + # messages (if debug >= 0). If > 0, errors + # are passed to the caller as exceptions. + + format = DEFAULT_FORMAT # The format to use when creating an archive. + + encoding = ENCODING # Encoding for 8-bit character strings. + + errors = None # Error handler for unicode conversion. + + tarinfo = TarInfo # The default TarInfo class to use. + + fileobject = ExFileObject # The file-object for extractfile(). + + extraction_filter = None # The default filter for extraction. + + def __init__(self, name=None, mode="r", fileobj=None, format=None, + tarinfo=None, dereference=None, ignore_zeros=None, encoding=None, + errors="surrogateescape", pax_headers=None, debug=None, + errorlevel=None, copybufsize=None, stream=False): + """Open an (uncompressed) tar archive 'name'. 'mode' is either 'r' to + read from an existing archive, 'a' to append data to an existing + file or 'w' to create a new file overwriting an existing one. 'mode' + defaults to 'r'. + If 'fileobj' is given, it is used for reading or writing data. If it + can be determined, 'mode' is overridden by 'fileobj's mode. + 'fileobj' is not closed, when TarFile is closed. + """ + modes = {"r": "rb", "a": "r+b", "w": "wb", "x": "xb"} + if mode not in modes: + raise ValueError("mode must be 'r', 'a', 'w' or 'x'") + self.mode = mode + self._mode = modes[mode] + + if not fileobj: + if self.mode == "a" and not os.path.exists(name): + # Create nonexistent files in append mode. + self.mode = "w" + self._mode = "wb" + fileobj = bltn_open(name, self._mode) + self._extfileobj = False + else: + if (name is None and hasattr(fileobj, "name") and + isinstance(fileobj.name, (str, bytes))): + name = fileobj.name + if hasattr(fileobj, "mode"): + self._mode = fileobj.mode + self._extfileobj = True + self.name = os.path.abspath(name) if name else None + self.fileobj = fileobj + + self.stream = stream + + # Init attributes. + if format is not None: + self.format = format + if tarinfo is not None: + self.tarinfo = tarinfo + if dereference is not None: + self.dereference = dereference + if ignore_zeros is not None: + self.ignore_zeros = ignore_zeros + if encoding is not None: + self.encoding = encoding + self.errors = errors + + if pax_headers is not None and self.format == PAX_FORMAT: + self.pax_headers = pax_headers + else: + self.pax_headers = {} + + if debug is not None: + self.debug = debug + if errorlevel is not None: + self.errorlevel = errorlevel + + # Init datastructures. + self.copybufsize = copybufsize + self.closed = False + self.members = [] # list of members as TarInfo objects + self._loaded = False # flag if all members have been read + self.offset = self.fileobj.tell() + # current position in the archive file + self.inodes = {} # dictionary caching the inodes of + # archive members already added + + try: + if self.mode == "r": + self.firstmember = None + self.firstmember = self.next() + + if self.mode == "a": + # Move to the end of the archive, + # before the first empty block. + while True: + self.fileobj.seek(self.offset) + try: + tarinfo = self.tarinfo.fromtarfile(self) + self.members.append(tarinfo) + except EOFHeaderError: + self.fileobj.seek(self.offset) + break + except HeaderError as e: + raise ReadError(str(e)) from None + + if self.mode in ("a", "w", "x"): + self._loaded = True + + if self.pax_headers: + buf = self.tarinfo.create_pax_global_header(self.pax_headers.copy()) + self.fileobj.write(buf) + self.offset += len(buf) + except: + if not self._extfileobj: + self.fileobj.close() + self.closed = True + raise + + #-------------------------------------------------------------------------- + # Below are the classmethods which act as alternate constructors to the + # TarFile class. The open() method is the only one that is needed for + # public use; it is the "super"-constructor and is able to select an + # adequate "sub"-constructor for a particular compression using the mapping + # from OPEN_METH. + # + # This concept allows one to subclass TarFile without losing the comfort of + # the super-constructor. A sub-constructor is registered and made available + # by adding it to the mapping in OPEN_METH. + + @classmethod + def open(cls, name=None, mode="r", fileobj=None, bufsize=RECORDSIZE, **kwargs): + r"""Open a tar archive for reading, writing or appending. Return + an appropriate TarFile class. + + mode: + 'r' or 'r:\*' open for reading with transparent compression + 'r:' open for reading exclusively uncompressed + 'r:gz' open for reading with gzip compression + 'r:bz2' open for reading with bzip2 compression + 'r:xz' open for reading with lzma compression + 'a' or 'a:' open for appending, creating the file if necessary + 'w' or 'w:' open for writing without compression + 'w:gz' open for writing with gzip compression + 'w:bz2' open for writing with bzip2 compression + 'w:xz' open for writing with lzma compression + + 'x' or 'x:' create a tarfile exclusively without compression, raise + an exception if the file is already created + 'x:gz' create a gzip compressed tarfile, raise an exception + if the file is already created + 'x:bz2' create a bzip2 compressed tarfile, raise an exception + if the file is already created + 'x:xz' create an lzma compressed tarfile, raise an exception + if the file is already created + + 'r|\*' open a stream of tar blocks with transparent compression + 'r|' open an uncompressed stream of tar blocks for reading + 'r|gz' open a gzip compressed stream of tar blocks + 'r|bz2' open a bzip2 compressed stream of tar blocks + 'r|xz' open an lzma compressed stream of tar blocks + 'w|' open an uncompressed stream for writing + 'w|gz' open a gzip compressed stream for writing + 'w|bz2' open a bzip2 compressed stream for writing + 'w|xz' open an lzma compressed stream for writing + """ + + if not name and not fileobj: + raise ValueError("nothing to open") + + if mode in ("r", "r:*"): + # Find out which *open() is appropriate for opening the file. + def not_compressed(comptype): + return cls.OPEN_METH[comptype] == 'taropen' + error_msgs = [] + for comptype in sorted(cls.OPEN_METH, key=not_compressed): + func = getattr(cls, cls.OPEN_METH[comptype]) + if fileobj is not None: + saved_pos = fileobj.tell() + try: + return func(name, "r", fileobj, **kwargs) + except (ReadError, CompressionError) as e: + error_msgs.append(f'- method {comptype}: {e!r}') + if fileobj is not None: + fileobj.seek(saved_pos) + continue + error_msgs_summary = '\n'.join(error_msgs) + raise ReadError(f"file could not be opened successfully:\n{error_msgs_summary}") + + elif ":" in mode: + filemode, comptype = mode.split(":", 1) + filemode = filemode or "r" + comptype = comptype or "tar" + + # Select the *open() function according to + # given compression. + if comptype in cls.OPEN_METH: + func = getattr(cls, cls.OPEN_METH[comptype]) + else: + raise CompressionError("unknown compression type %r" % comptype) + return func(name, filemode, fileobj, **kwargs) + + elif "|" in mode: + filemode, comptype = mode.split("|", 1) + filemode = filemode or "r" + comptype = comptype or "tar" + + if filemode not in ("r", "w"): + raise ValueError("mode must be 'r' or 'w'") + + compresslevel = kwargs.pop("compresslevel", 9) + stream = _Stream(name, filemode, comptype, fileobj, bufsize, + compresslevel) + try: + t = cls(name, filemode, stream, **kwargs) + except: + stream.close() + raise + t._extfileobj = False + return t + + elif mode in ("a", "w", "x"): + return cls.taropen(name, mode, fileobj, **kwargs) + + raise ValueError("undiscernible mode") + + @classmethod + def taropen(cls, name, mode="r", fileobj=None, **kwargs): + """Open uncompressed tar archive name for reading or writing. + """ + if mode not in ("r", "a", "w", "x"): + raise ValueError("mode must be 'r', 'a', 'w' or 'x'") + return cls(name, mode, fileobj, **kwargs) + + @classmethod + def gzopen(cls, name, mode="r", fileobj=None, compresslevel=9, **kwargs): + """Open gzip compressed tar archive name for reading or writing. + Appending is not allowed. + """ + if mode not in ("r", "w", "x"): + raise ValueError("mode must be 'r', 'w' or 'x'") + + try: + from gzip import GzipFile + except ImportError: + raise CompressionError("gzip module is not available") from None + + try: + fileobj = GzipFile(name, mode + "b", compresslevel, fileobj) + except OSError as e: + if fileobj is not None and mode == 'r': + raise ReadError("not a gzip file") from e + raise + + try: + t = cls.taropen(name, mode, fileobj, **kwargs) + except OSError as e: + fileobj.close() + if mode == 'r': + raise ReadError("not a gzip file") from e + raise + except: + fileobj.close() + raise + t._extfileobj = False + return t + + @classmethod + def bz2open(cls, name, mode="r", fileobj=None, compresslevel=9, **kwargs): + """Open bzip2 compressed tar archive name for reading or writing. + Appending is not allowed. + """ + if mode not in ("r", "w", "x"): + raise ValueError("mode must be 'r', 'w' or 'x'") + + try: + from bz2 import BZ2File + except ImportError: + raise CompressionError("bz2 module is not available") from None + + fileobj = BZ2File(fileobj or name, mode, compresslevel=compresslevel) + + try: + t = cls.taropen(name, mode, fileobj, **kwargs) + except (OSError, EOFError) as e: + fileobj.close() + if mode == 'r': + raise ReadError("not a bzip2 file") from e + raise + except: + fileobj.close() + raise + t._extfileobj = False + return t + + @classmethod + def xzopen(cls, name, mode="r", fileobj=None, preset=None, **kwargs): + """Open lzma compressed tar archive name for reading or writing. + Appending is not allowed. + """ + if mode not in ("r", "w", "x"): + raise ValueError("mode must be 'r', 'w' or 'x'") + + try: + from lzma import LZMAFile, LZMAError + except ImportError: + raise CompressionError("lzma module is not available") from None + + fileobj = LZMAFile(fileobj or name, mode, preset=preset) + + try: + t = cls.taropen(name, mode, fileobj, **kwargs) + except (LZMAError, EOFError) as e: + fileobj.close() + if mode == 'r': + raise ReadError("not an lzma file") from e + raise + except: + fileobj.close() + raise + t._extfileobj = False + return t + + # All *open() methods are registered here. + OPEN_METH = { + "tar": "taropen", # uncompressed tar + "gz": "gzopen", # gzip compressed tar + "bz2": "bz2open", # bzip2 compressed tar + "xz": "xzopen" # lzma compressed tar + } + + #-------------------------------------------------------------------------- + # The public methods which TarFile provides: + + def close(self): + """Close the TarFile. In write-mode, two finishing zero blocks are + appended to the archive. + """ + if self.closed: + return + + self.closed = True + try: + if self.mode in ("a", "w", "x"): + self.fileobj.write(NUL * (BLOCKSIZE * 2)) + self.offset += (BLOCKSIZE * 2) + # fill up the end with zero-blocks + # (like option -b20 for tar does) + blocks, remainder = divmod(self.offset, RECORDSIZE) + if remainder > 0: + self.fileobj.write(NUL * (RECORDSIZE - remainder)) + finally: + if not self._extfileobj: + self.fileobj.close() + + def getmember(self, name): + """Return a TarInfo object for member 'name'. If 'name' can not be + found in the archive, KeyError is raised. If a member occurs more + than once in the archive, its last occurrence is assumed to be the + most up-to-date version. + """ + tarinfo = self._getmember(name.rstrip('/')) + if tarinfo is None: + raise KeyError("filename %r not found" % name) + return tarinfo + + def getmembers(self): + """Return the members of the archive as a list of TarInfo objects. The + list has the same order as the members in the archive. + """ + self._check() + if not self._loaded: # if we want to obtain a list of + self._load() # all members, we first have to + # scan the whole archive. + return self.members + + def getnames(self): + """Return the members of the archive as a list of their names. It has + the same order as the list returned by getmembers(). + """ + return [tarinfo.name for tarinfo in self.getmembers()] + + def gettarinfo(self, name=None, arcname=None, fileobj=None): + """Create a TarInfo object from the result of os.stat or equivalent + on an existing file. The file is either named by 'name', or + specified as a file object 'fileobj' with a file descriptor. If + given, 'arcname' specifies an alternative name for the file in the + archive, otherwise, the name is taken from the 'name' attribute of + 'fileobj', or the 'name' argument. The name should be a text + string. + """ + self._check("awx") + + # When fileobj is given, replace name by + # fileobj's real name. + if fileobj is not None: + name = fileobj.name + + # Building the name of the member in the archive. + # Backward slashes are converted to forward slashes, + # Absolute paths are turned to relative paths. + if arcname is None: + arcname = name + drv, arcname = os.path.splitdrive(arcname) + arcname = arcname.replace(os.sep, "/") + arcname = arcname.lstrip("/") + + # Now, fill the TarInfo object with + # information specific for the file. + tarinfo = self.tarinfo() + tarinfo._tarfile = self # To be removed in 3.16. + + # Use os.stat or os.lstat, depending on if symlinks shall be resolved. + if fileobj is None: + if not self.dereference: + statres = os.lstat(name) + else: + statres = os.stat(name) + else: + statres = os.fstat(fileobj.fileno()) + linkname = "" + + stmd = statres.st_mode + if stat.S_ISREG(stmd): + inode = (statres.st_ino, statres.st_dev) + if not self.dereference and statres.st_nlink > 1 and \ + inode in self.inodes and arcname != self.inodes[inode]: + # Is it a hardlink to an already + # archived file? + type = LNKTYPE + linkname = self.inodes[inode] + else: + # The inode is added only if its valid. + # For win32 it is always 0. + type = REGTYPE + if inode[0]: + self.inodes[inode] = arcname + elif stat.S_ISDIR(stmd): + type = DIRTYPE + elif stat.S_ISFIFO(stmd): + type = FIFOTYPE + elif stat.S_ISLNK(stmd): + type = SYMTYPE + linkname = os.readlink(name) + elif stat.S_ISCHR(stmd): + type = CHRTYPE + elif stat.S_ISBLK(stmd): + type = BLKTYPE + else: + return None + + # Fill the TarInfo object with all + # information we can get. + tarinfo.name = arcname + tarinfo.mode = stmd + tarinfo.uid = statres.st_uid + tarinfo.gid = statres.st_gid + if type == REGTYPE: + tarinfo.size = statres.st_size + else: + tarinfo.size = 0 + tarinfo.mtime = statres.st_mtime + tarinfo.type = type + tarinfo.linkname = linkname + if pwd: + try: + tarinfo.uname = pwd.getpwuid(tarinfo.uid)[0] + except KeyError: + pass + if grp: + try: + tarinfo.gname = grp.getgrgid(tarinfo.gid)[0] + except KeyError: + pass + + if type in (CHRTYPE, BLKTYPE): + if hasattr(os, "major") and hasattr(os, "minor"): + tarinfo.devmajor = os.major(statres.st_rdev) + tarinfo.devminor = os.minor(statres.st_rdev) + return tarinfo + + def list(self, verbose=True, *, members=None): + """Print a table of contents to sys.stdout. If 'verbose' is False, only + the names of the members are printed. If it is True, an 'ls -l'-like + output is produced. 'members' is optional and must be a subset of the + list returned by getmembers(). + """ + # Convert tarinfo type to stat type. + type2mode = {REGTYPE: stat.S_IFREG, SYMTYPE: stat.S_IFLNK, + FIFOTYPE: stat.S_IFIFO, CHRTYPE: stat.S_IFCHR, + DIRTYPE: stat.S_IFDIR, BLKTYPE: stat.S_IFBLK} + self._check() + + if members is None: + members = self + for tarinfo in members: + if verbose: + if tarinfo.mode is None: + _safe_print("??????????") + else: + modetype = type2mode.get(tarinfo.type, 0) + _safe_print(stat.filemode(modetype | tarinfo.mode)) + _safe_print("%s/%s" % (tarinfo.uname or tarinfo.uid, + tarinfo.gname or tarinfo.gid)) + if tarinfo.ischr() or tarinfo.isblk(): + _safe_print("%10s" % + ("%d,%d" % (tarinfo.devmajor, tarinfo.devminor))) + else: + _safe_print("%10d" % tarinfo.size) + if tarinfo.mtime is None: + _safe_print("????-??-?? ??:??:??") + else: + _safe_print("%d-%02d-%02d %02d:%02d:%02d" \ + % time.localtime(tarinfo.mtime)[:6]) + + _safe_print(tarinfo.name + ("/" if tarinfo.isdir() else "")) + + if verbose: + if tarinfo.issym(): + _safe_print("-> " + tarinfo.linkname) + if tarinfo.islnk(): + _safe_print("link to " + tarinfo.linkname) + print() + + def add(self, name, arcname=None, recursive=True, *, filter=None): + """Add the file 'name' to the archive. 'name' may be any type of file + (directory, fifo, symbolic link, etc.). If given, 'arcname' + specifies an alternative name for the file in the archive. + Directories are added recursively by default. This can be avoided by + setting 'recursive' to False. 'filter' is a function + that expects a TarInfo object argument and returns the changed + TarInfo object, if it returns None the TarInfo object will be + excluded from the archive. + """ + self._check("awx") + + if arcname is None: + arcname = name + + # Skip if somebody tries to archive the archive... + if self.name is not None and os.path.abspath(name) == self.name: + self._dbg(2, "tarfile: Skipped %r" % name) + return + + self._dbg(1, name) + + # Create a TarInfo object from the file. + tarinfo = self.gettarinfo(name, arcname) + + if tarinfo is None: + self._dbg(1, "tarfile: Unsupported type %r" % name) + return + + # Change or exclude the TarInfo object. + if filter is not None: + tarinfo = filter(tarinfo) + if tarinfo is None: + self._dbg(2, "tarfile: Excluded %r" % name) + return + + # Append the tar header and data to the archive. + if tarinfo.isreg(): + with bltn_open(name, "rb") as f: + self.addfile(tarinfo, f) + + elif tarinfo.isdir(): + self.addfile(tarinfo) + if recursive: + for f in sorted(os.listdir(name)): + self.add(os.path.join(name, f), os.path.join(arcname, f), + recursive, filter=filter) + + else: + self.addfile(tarinfo) + + def addfile(self, tarinfo, fileobj=None): + """Add the TarInfo object 'tarinfo' to the archive. If 'tarinfo' represents + a non zero-size regular file, the 'fileobj' argument should be a binary file, + and tarinfo.size bytes are read from it and added to the archive. + You can create TarInfo objects directly, or by using gettarinfo(). + """ + self._check("awx") + + if fileobj is None and tarinfo.isreg() and tarinfo.size != 0: + raise ValueError("fileobj not provided for non zero-size regular file") + + tarinfo = copy.copy(tarinfo) + + buf = tarinfo.tobuf(self.format, self.encoding, self.errors) + self.fileobj.write(buf) + self.offset += len(buf) + bufsize=self.copybufsize + # If there's data to follow, append it. + if fileobj is not None: + copyfileobj(fileobj, self.fileobj, tarinfo.size, bufsize=bufsize) + blocks, remainder = divmod(tarinfo.size, BLOCKSIZE) + if remainder > 0: + self.fileobj.write(NUL * (BLOCKSIZE - remainder)) + blocks += 1 + self.offset += blocks * BLOCKSIZE + + self.members.append(tarinfo) + + def _get_filter_function(self, filter): + if filter is None: + filter = self.extraction_filter + if filter is None: + import warnings + warnings.warn( + 'Python 3.14 will, by default, filter extracted tar ' + + 'archives and reject files or modify their metadata. ' + + 'Use the filter argument to control this behavior.', + DeprecationWarning, stacklevel=3) + return fully_trusted_filter + if isinstance(filter, str): + raise TypeError( + 'String names are not supported for ' + + 'TarFile.extraction_filter. Use a function such as ' + + 'tarfile.data_filter directly.') + return filter + if callable(filter): + return filter + try: + return _NAMED_FILTERS[filter] + except KeyError: + raise ValueError(f"filter {filter!r} not found") from None + + def extractall(self, path=".", members=None, *, numeric_owner=False, + filter=None): + """Extract all members from the archive to the current working + directory and set owner, modification time and permissions on + directories afterwards. 'path' specifies a different directory + to extract to. 'members' is optional and must be a subset of the + list returned by getmembers(). If 'numeric_owner' is True, only + the numbers for user/group names are used and not the names. + + The 'filter' function will be called on each member just + before extraction. + It can return a changed TarInfo or None to skip the member. + String names of common filters are accepted. + """ + directories = [] + + filter_function = self._get_filter_function(filter) + if members is None: + members = self + + for member in members: + tarinfo = self._get_extract_tarinfo(member, filter_function, path) + if tarinfo is None: + continue + if tarinfo.isdir(): + # For directories, delay setting attributes until later, + # since permissions can interfere with extraction and + # extracting contents can reset mtime. + directories.append(tarinfo) + self._extract_one(tarinfo, path, set_attrs=not tarinfo.isdir(), + numeric_owner=numeric_owner) + + # Reverse sort directories. + directories.sort(key=lambda a: a.name, reverse=True) + + # Set correct owner, mtime and filemode on directories. + for tarinfo in directories: + dirpath = os.path.join(path, tarinfo.name) + try: + self.chown(tarinfo, dirpath, numeric_owner=numeric_owner) + self.utime(tarinfo, dirpath) + self.chmod(tarinfo, dirpath) + except ExtractError as e: + self._handle_nonfatal_error(e) + + def extract(self, member, path="", set_attrs=True, *, numeric_owner=False, + filter=None): + """Extract a member from the archive to the current working directory, + using its full name. Its file information is extracted as accurately + as possible. 'member' may be a filename or a TarInfo object. You can + specify a different directory using 'path'. File attributes (owner, + mtime, mode) are set unless 'set_attrs' is False. If 'numeric_owner' + is True, only the numbers for user/group names are used and not + the names. + + The 'filter' function will be called before extraction. + It can return a changed TarInfo or None to skip the member. + String names of common filters are accepted. + """ + filter_function = self._get_filter_function(filter) + tarinfo = self._get_extract_tarinfo(member, filter_function, path) + if tarinfo is not None: + self._extract_one(tarinfo, path, set_attrs, numeric_owner) + + def _get_extract_tarinfo(self, member, filter_function, path): + """Get filtered TarInfo (or None) from member, which might be a str""" + if isinstance(member, str): + tarinfo = self.getmember(member) + else: + tarinfo = member + + unfiltered = tarinfo + try: + tarinfo = filter_function(tarinfo, path) + except (OSError, FilterError) as e: + self._handle_fatal_error(e) + except ExtractError as e: + self._handle_nonfatal_error(e) + if tarinfo is None: + self._dbg(2, "tarfile: Excluded %r" % unfiltered.name) + return None + # Prepare the link target for makelink(). + if tarinfo.islnk(): + tarinfo = copy.copy(tarinfo) + tarinfo._link_target = os.path.join(path, tarinfo.linkname) + return tarinfo + + def _extract_one(self, tarinfo, path, set_attrs, numeric_owner): + """Extract from filtered tarinfo to disk""" + self._check("r") + + try: + self._extract_member(tarinfo, os.path.join(path, tarinfo.name), + set_attrs=set_attrs, + numeric_owner=numeric_owner) + except OSError as e: + self._handle_fatal_error(e) + except ExtractError as e: + self._handle_nonfatal_error(e) + + def _handle_nonfatal_error(self, e): + """Handle non-fatal error (ExtractError) according to errorlevel""" + if self.errorlevel > 1: + raise + else: + self._dbg(1, "tarfile: %s" % e) + + def _handle_fatal_error(self, e): + """Handle "fatal" error according to self.errorlevel""" + if self.errorlevel > 0: + raise + elif isinstance(e, OSError): + if e.filename is None: + self._dbg(1, "tarfile: %s" % e.strerror) + else: + self._dbg(1, "tarfile: %s %r" % (e.strerror, e.filename)) + else: + self._dbg(1, "tarfile: %s %s" % (type(e).__name__, e)) + + def extractfile(self, member): + """Extract a member from the archive as a file object. 'member' may be + a filename or a TarInfo object. If 'member' is a regular file or + a link, an io.BufferedReader object is returned. For all other + existing members, None is returned. If 'member' does not appear + in the archive, KeyError is raised. + """ + self._check("r") + + if isinstance(member, str): + tarinfo = self.getmember(member) + else: + tarinfo = member + + if tarinfo.isreg() or tarinfo.type not in SUPPORTED_TYPES: + # Members with unknown types are treated as regular files. + return self.fileobject(self, tarinfo) + + elif tarinfo.islnk() or tarinfo.issym(): + if isinstance(self.fileobj, _Stream): + # A small but ugly workaround for the case that someone tries + # to extract a (sym)link as a file-object from a non-seekable + # stream of tar blocks. + raise StreamError("cannot extract (sym)link as file object") + else: + # A (sym)link's file object is its target's file object. + return self.extractfile(self._find_link_target(tarinfo)) + else: + # If there's no data associated with the member (directory, chrdev, + # blkdev, etc.), return None instead of a file object. + return None + + def _extract_member(self, tarinfo, targetpath, set_attrs=True, + numeric_owner=False): + """Extract the TarInfo object tarinfo to a physical + file called targetpath. + """ + # Fetch the TarInfo object for the given name + # and build the destination pathname, replacing + # forward slashes to platform specific separators. + targetpath = targetpath.rstrip("/") + targetpath = targetpath.replace("/", os.sep) + + # Create all upper directories. + upperdirs = os.path.dirname(targetpath) + if upperdirs and not os.path.exists(upperdirs): + # Create directories that are not part of the archive with + # default permissions. + os.makedirs(upperdirs, exist_ok=True) + + if tarinfo.islnk() or tarinfo.issym(): + self._dbg(1, "%s -> %s" % (tarinfo.name, tarinfo.linkname)) + else: + self._dbg(1, tarinfo.name) + + if tarinfo.isreg(): + self.makefile(tarinfo, targetpath) + elif tarinfo.isdir(): + self.makedir(tarinfo, targetpath) + elif tarinfo.isfifo(): + self.makefifo(tarinfo, targetpath) + elif tarinfo.ischr() or tarinfo.isblk(): + self.makedev(tarinfo, targetpath) + elif tarinfo.islnk() or tarinfo.issym(): + self.makelink(tarinfo, targetpath) + elif tarinfo.type not in SUPPORTED_TYPES: + self.makeunknown(tarinfo, targetpath) + else: + self.makefile(tarinfo, targetpath) + + if set_attrs: + self.chown(tarinfo, targetpath, numeric_owner) + if not tarinfo.issym(): + self.chmod(tarinfo, targetpath) + self.utime(tarinfo, targetpath) + + #-------------------------------------------------------------------------- + # Below are the different file methods. They are called via + # _extract_member() when extract() is called. They can be replaced in a + # subclass to implement other functionality. + + def makedir(self, tarinfo, targetpath): + """Make a directory called targetpath. + """ + try: + if tarinfo.mode is None: + # Use the system's default mode + os.mkdir(targetpath) + else: + # Use a safe mode for the directory, the real mode is set + # later in _extract_member(). + os.mkdir(targetpath, 0o700) + except FileExistsError: + if not os.path.isdir(targetpath): + raise + + def makefile(self, tarinfo, targetpath): + """Make a file called targetpath. + """ + source = self.fileobj + source.seek(tarinfo.offset_data) + bufsize = self.copybufsize + with bltn_open(targetpath, "wb") as target: + if tarinfo.sparse is not None: + for offset, size in tarinfo.sparse: + target.seek(offset) + copyfileobj(source, target, size, ReadError, bufsize) + target.seek(tarinfo.size) + target.truncate() + else: + copyfileobj(source, target, tarinfo.size, ReadError, bufsize) + + def makeunknown(self, tarinfo, targetpath): + """Make a file from a TarInfo object with an unknown type + at targetpath. + """ + self.makefile(tarinfo, targetpath) + self._dbg(1, "tarfile: Unknown file type %r, " \ + "extracted as regular file." % tarinfo.type) + + def makefifo(self, tarinfo, targetpath): + """Make a fifo called targetpath. + """ + if hasattr(os, "mkfifo"): + os.mkfifo(targetpath) + else: + raise ExtractError("fifo not supported by system") + + def makedev(self, tarinfo, targetpath): + """Make a character or block device called targetpath. + """ + if not hasattr(os, "mknod") or not hasattr(os, "makedev"): + raise ExtractError("special devices not supported by system") + + mode = tarinfo.mode + if mode is None: + # Use mknod's default + mode = 0o600 + if tarinfo.isblk(): + mode |= stat.S_IFBLK + else: + mode |= stat.S_IFCHR + + os.mknod(targetpath, mode, + os.makedev(tarinfo.devmajor, tarinfo.devminor)) + + def makelink(self, tarinfo, targetpath): + """Make a (symbolic) link called targetpath. If it cannot be created + (platform limitation), we try to make a copy of the referenced file + instead of a link. + """ + try: + # For systems that support symbolic and hard links. + if tarinfo.issym(): + if os.path.lexists(targetpath): + # Avoid FileExistsError on following os.symlink. + os.unlink(targetpath) + os.symlink(tarinfo.linkname, targetpath) + else: + if os.path.exists(tarinfo._link_target): + os.link(tarinfo._link_target, targetpath) + else: + self._extract_member(self._find_link_target(tarinfo), + targetpath) + except symlink_exception: + try: + self._extract_member(self._find_link_target(tarinfo), + targetpath) + except KeyError: + raise ExtractError("unable to resolve link inside archive") from None + + def chown(self, tarinfo, targetpath, numeric_owner): + """Set owner of targetpath according to tarinfo. If numeric_owner + is True, use .gid/.uid instead of .gname/.uname. If numeric_owner + is False, fall back to .gid/.uid when the search based on name + fails. + """ + if hasattr(os, "geteuid") and os.geteuid() == 0: + # We have to be root to do so. + g = tarinfo.gid + u = tarinfo.uid + if not numeric_owner: + try: + if grp and tarinfo.gname: + g = grp.getgrnam(tarinfo.gname)[2] + except KeyError: + pass + try: + if pwd and tarinfo.uname: + u = pwd.getpwnam(tarinfo.uname)[2] + except KeyError: + pass + if g is None: + g = -1 + if u is None: + u = -1 + try: + if tarinfo.issym() and hasattr(os, "lchown"): + os.lchown(targetpath, u, g) + else: + os.chown(targetpath, u, g) + except (OSError, OverflowError) as e: + # OverflowError can be raised if an ID doesn't fit in 'id_t' + raise ExtractError("could not change owner") from e + + def chmod(self, tarinfo, targetpath): + """Set file permissions of targetpath according to tarinfo. + """ + if tarinfo.mode is None: + return + try: + os.chmod(targetpath, tarinfo.mode) + except OSError as e: + raise ExtractError("could not change mode") from e + + def utime(self, tarinfo, targetpath): + """Set modification time of targetpath according to tarinfo. + """ + mtime = tarinfo.mtime + if mtime is None: + return + if not hasattr(os, 'utime'): + return + try: + os.utime(targetpath, (mtime, mtime)) + except OSError as e: + raise ExtractError("could not change modification time") from e + + #-------------------------------------------------------------------------- + def next(self): + """Return the next member of the archive as a TarInfo object, when + TarFile is opened for reading. Return None if there is no more + available. + """ + self._check("ra") + if self.firstmember is not None: + m = self.firstmember + self.firstmember = None + return m + + # Advance the file pointer. + if self.offset != self.fileobj.tell(): + if self.offset == 0: + return None + self.fileobj.seek(self.offset - 1) + if not self.fileobj.read(1): + raise ReadError("unexpected end of data") + + # Read the next block. + tarinfo = None + while True: + try: + tarinfo = self.tarinfo.fromtarfile(self) + except EOFHeaderError as e: + if self.ignore_zeros: + self._dbg(2, "0x%X: %s" % (self.offset, e)) + self.offset += BLOCKSIZE + continue + except InvalidHeaderError as e: + if self.ignore_zeros: + self._dbg(2, "0x%X: %s" % (self.offset, e)) + self.offset += BLOCKSIZE + continue + elif self.offset == 0: + raise ReadError(str(e)) from None + except EmptyHeaderError: + if self.offset == 0: + raise ReadError("empty file") from None + except TruncatedHeaderError as e: + if self.offset == 0: + raise ReadError(str(e)) from None + except SubsequentHeaderError as e: + raise ReadError(str(e)) from None + except Exception as e: + try: + import zlib + if isinstance(e, zlib.error): + raise ReadError(f'zlib error: {e}') from None + else: + raise e + except ImportError: + raise e + break + + if tarinfo is not None: + # if streaming the file we do not want to cache the tarinfo + if not self.stream: + self.members.append(tarinfo) + else: + self._loaded = True + + return tarinfo + + #-------------------------------------------------------------------------- + # Little helper methods: + + def _getmember(self, name, tarinfo=None, normalize=False): + """Find an archive member by name from bottom to top. + If tarinfo is given, it is used as the starting point. + """ + # Ensure that all members have been loaded. + members = self.getmembers() + + # Limit the member search list up to tarinfo. + skipping = False + if tarinfo is not None: + try: + index = members.index(tarinfo) + except ValueError: + # The given starting point might be a (modified) copy. + # We'll later skip members until we find an equivalent. + skipping = True + else: + # Happy fast path + members = members[:index] + + if normalize: + name = os.path.normpath(name) + + for member in reversed(members): + if skipping: + if tarinfo.offset == member.offset: + skipping = False + continue + if normalize: + member_name = os.path.normpath(member.name) + else: + member_name = member.name + + if name == member_name: + return member + + if skipping: + # Starting point was not found + raise ValueError(tarinfo) + + def _load(self): + """Read through the entire archive file and look for readable + members. This should not run if the file is set to stream. + """ + if not self.stream: + while self.next() is not None: + pass + self._loaded = True + + def _check(self, mode=None): + """Check if TarFile is still open, and if the operation's mode + corresponds to TarFile's mode. + """ + if self.closed: + raise OSError("%s is closed" % self.__class__.__name__) + if mode is not None and self.mode not in mode: + raise OSError("bad operation for mode %r" % self.mode) + + def _find_link_target(self, tarinfo): + """Find the target member of a symlink or hardlink member in the + archive. + """ + if tarinfo.issym(): + # Always search the entire archive. + linkname = "/".join(filter(None, (os.path.dirname(tarinfo.name), tarinfo.linkname))) + limit = None + else: + # Search the archive before the link, because a hard link is + # just a reference to an already archived file. + linkname = tarinfo.linkname + limit = tarinfo + + member = self._getmember(linkname, tarinfo=limit, normalize=True) + if member is None: + raise KeyError("linkname %r not found" % linkname) + return member + + def __iter__(self): + """Provide an iterator object. + """ + if self._loaded: + yield from self.members + return + + # Yield items using TarFile's next() method. + # When all members have been read, set TarFile as _loaded. + index = 0 + # Fix for SF #1100429: Under rare circumstances it can + # happen that getmembers() is called during iteration, + # which will have already exhausted the next() method. + if self.firstmember is not None: + tarinfo = self.next() + index += 1 + yield tarinfo + + while True: + if index < len(self.members): + tarinfo = self.members[index] + elif not self._loaded: + tarinfo = self.next() + if not tarinfo: + self._loaded = True + return + else: + return + index += 1 + yield tarinfo + + def _dbg(self, level, msg): + """Write debugging output to sys.stderr. + """ + if level <= self.debug: + print(msg, file=sys.stderr) + + def __enter__(self): + self._check() + return self + + def __exit__(self, type, value, traceback): + if type is None: + self.close() + else: + # An exception occurred. We must not call close() because + # it would try to write end-of-archive blocks and padding. + if not self._extfileobj: + self.fileobj.close() + self.closed = True + +#-------------------- +# exported functions +#-------------------- + +def is_tarfile(name): + """Return True if name points to a tar archive that we + are able to handle, else return False. + + 'name' should be a string, file, or file-like object. + """ + try: + if hasattr(name, "read"): + pos = name.tell() + t = open(fileobj=name) + name.seek(pos) + else: + t = open(name) + t.close() + return True + except TarError: + return False + +open = TarFile.open + + +def main(): + import argparse + + description = 'A simple command-line interface for tarfile module.' + parser = argparse.ArgumentParser(description=description) + parser.add_argument('-v', '--verbose', action='store_true', default=False, + help='Verbose output') + parser.add_argument('--filter', metavar='<filtername>', + choices=_NAMED_FILTERS, + help='Filter for extraction') + + group = parser.add_mutually_exclusive_group(required=True) + group.add_argument('-l', '--list', metavar='<tarfile>', + help='Show listing of a tarfile') + group.add_argument('-e', '--extract', nargs='+', + metavar=('<tarfile>', '<output_dir>'), + help='Extract tarfile into target dir') + group.add_argument('-c', '--create', nargs='+', + metavar=('<name>', '<file>'), + help='Create tarfile from sources') + group.add_argument('-t', '--test', metavar='<tarfile>', + help='Test if a tarfile is valid') + + args = parser.parse_args() + + if args.filter and args.extract is None: + parser.exit(1, '--filter is only valid for extraction\n') + + if args.test is not None: + src = args.test + if is_tarfile(src): + with open(src, 'r') as tar: + tar.getmembers() + print(tar.getmembers(), file=sys.stderr) + if args.verbose: + print('{!r} is a tar archive.'.format(src)) + else: + parser.exit(1, '{!r} is not a tar archive.\n'.format(src)) + + elif args.list is not None: + src = args.list + if is_tarfile(src): + with TarFile.open(src, 'r:*') as tf: + tf.list(verbose=args.verbose) + else: + parser.exit(1, '{!r} is not a tar archive.\n'.format(src)) + + elif args.extract is not None: + if len(args.extract) == 1: + src = args.extract[0] + curdir = os.curdir + elif len(args.extract) == 2: + src, curdir = args.extract + else: + parser.exit(1, parser.format_help()) + + if is_tarfile(src): + with TarFile.open(src, 'r:*') as tf: + tf.extractall(path=curdir, filter=args.filter) + if args.verbose: + if curdir == '.': + msg = '{!r} file is extracted.'.format(src) + else: + msg = ('{!r} file is extracted ' + 'into {!r} directory.').format(src, curdir) + print(msg) + else: + parser.exit(1, '{!r} is not a tar archive.\n'.format(src)) + + elif args.create is not None: + tar_name = args.create.pop(0) + _, ext = os.path.splitext(tar_name) + compressions = { + # gz + '.gz': 'gz', + '.tgz': 'gz', + # xz + '.xz': 'xz', + '.txz': 'xz', + # bz2 + '.bz2': 'bz2', + '.tbz': 'bz2', + '.tbz2': 'bz2', + '.tb2': 'bz2', + } + tar_mode = 'w:' + compressions[ext] if ext in compressions else 'w' + tar_files = args.create + + with TarFile.open(tar_name, tar_mode) as tf: + for file_name in tar_files: + tf.add(file_name) + + if args.verbose: + print('{!r} file created.'.format(tar_name)) + +if __name__ == '__main__': + main() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/backports/tarfile/__main__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/backports/tarfile/__main__.py new file mode 100644 index 0000000000000000000000000000000000000000..daf55090862ae43283b6552073549ac3ab2ad50a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/backports/tarfile/__main__.py @@ -0,0 +1,5 @@ +from . import main + + +if __name__ == '__main__': + main() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/backports/tarfile/compat/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/backports/tarfile/compat/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/backports/tarfile/compat/py38.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/backports/tarfile/compat/py38.py new file mode 100644 index 0000000000000000000000000000000000000000..20fbbfc1c095baf9f8c72902b24296b50ad3ab9d --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/backports/tarfile/compat/py38.py @@ -0,0 +1,24 @@ +import sys + + +if sys.version_info < (3, 9): + + def removesuffix(self, suffix): + # suffix='' should not call self[:-0]. + if suffix and self.endswith(suffix): + return self[: -len(suffix)] + else: + return self[:] + + def removeprefix(self, prefix): + if self.startswith(prefix): + return self[len(prefix) :] + else: + return self[:] +else: + + def removesuffix(self, suffix): + return self.removesuffix(suffix) + + def removeprefix(self, prefix): + return self.removeprefix(prefix) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/importlib_metadata-8.7.1.dist-info/licenses/LICENSE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/importlib_metadata-8.7.1.dist-info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..5c1d8bbc02a6624cf8e957c40e6f761c1575d180 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/importlib_metadata-8.7.1.dist-info/licenses/LICENSE @@ -0,0 +1,73 @@ +Apache License +Version 2.0, January 2004 +http://www.apache.org/licenses/ + +TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + +1. Definitions. + +"License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. + +"Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. + +"Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. + +"You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. + +"Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. + +"Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. + +"Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). + +"Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. + +"Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." + +"Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. + +2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. + +3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. + +4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: + + (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. + + You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. + +5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. + +6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. + +7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. + +8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. + +9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. + +END OF TERMS AND CONDITIONS + +APPENDIX: How to apply the Apache License to your work. + +To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. + +Copyright 2025 [name of copyright owner] + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + +http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/importlib_metadata/compat/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/importlib_metadata/compat/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/importlib_metadata/compat/py311.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/importlib_metadata/compat/py311.py new file mode 100644 index 0000000000000000000000000000000000000000..3a5327436f9b1d9eae371e321c491a270634b3cf --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/importlib_metadata/compat/py311.py @@ -0,0 +1,22 @@ +import os +import pathlib +import sys +import types + + +def wrap(path): # pragma: no cover + """ + Workaround for https://github.com/python/cpython/issues/84538 + to add backward compatibility for walk_up=True. + An example affected package is dask-labextension, which uses + jupyter-packaging to install JupyterLab javascript files outside + of site-packages. + """ + + def relative_to(root, *, walk_up=False): + return pathlib.Path(os.path.relpath(path, root)) + + return types.SimpleNamespace(relative_to=relative_to) + + +relative_fix = wrap if sys.version_info < (3, 12) else lambda x: x diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/importlib_metadata/compat/py39.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/importlib_metadata/compat/py39.py new file mode 100644 index 0000000000000000000000000000000000000000..3eb9c01ecbbdcdf7b79d8840ee91c2fe7a734a1c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/importlib_metadata/compat/py39.py @@ -0,0 +1,42 @@ +""" +Compatibility layer with Python 3.8/3.9 +""" + +from __future__ import annotations + +from typing import TYPE_CHECKING, Any + +if TYPE_CHECKING: # pragma: no cover + # Prevent circular imports on runtime. + from .. import Distribution, EntryPoint +else: + Distribution = EntryPoint = Any + +from .._typing import md_none + + +def normalized_name(dist: Distribution) -> str | None: + """ + Honor name normalization for distributions that don't provide ``_normalized_name``. + """ + try: + return dist._normalized_name + except AttributeError: + from .. import Prepared # -> delay to prevent circular imports. + + return Prepared.normalize( + getattr(dist, "name", None) or md_none(dist.metadata)['Name'] + ) + + +def ep_matches(ep: EntryPoint, **params) -> bool: + """ + Workaround for ``EntryPoint`` objects without the ``matches`` method. + """ + try: + return ep.matches(**params) + except AttributeError: + from .. import EntryPoint # -> delay to prevent circular imports. + + # Reconstruct the EntryPoint object to make sure it is compatible. + return EntryPoint(ep.name, ep.value, ep.group).matches(**params) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/Lorem ipsum.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/Lorem ipsum.txt new file mode 100644 index 0000000000000000000000000000000000000000..986f944b60b9900c22464a0c027d713854cc204e --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/Lorem ipsum.txt @@ -0,0 +1,2 @@ +Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. +Curabitur pretium tincidunt lacus. Nulla gravida orci a odio. Nullam varius, turpis et commodo pharetra, est eros bibendum elit, nec luctus magna felis sollicitudin mauris. Integer in mauris eu nibh euismod gravida. Duis ac tellus et risus vulputate vehicula. Donec lobortis risus a elit. Etiam tempor. Ut ullamcorper, ligula eu tempor congue, eros est euismod turpis, id tincidunt sapien risus a quam. Maecenas fermentum consequat mi. Donec fermentum. Pellentesque malesuada nulla a mi. Duis sapien sem, aliquet nec, commodo eget, consequat quis, neque. Aliquam faucibus, elit ut dictum aliquet, felis nisl adipiscing sapien, sed malesuada diam lacus eget erat. Cras mollis scelerisque nunc. Nullam arcu. Aliquam consequat. Curabitur augue lorem, dapibus quis, laoreet et, pretium ac, nisi. Aenean magna nisl, mollis quis, molestie eu, feugiat in, orci. In hac habitasse platea dictumst. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..8567200ad7fad1ea127ff5f81c5509d96d37cbd7 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/__init__.py @@ -0,0 +1,647 @@ +import functools +import itertools +import re +import textwrap + +from typing import Iterable + +try: + from importlib.resources import files # type: ignore +except ImportError: # pragma: nocover + from importlib_resources import files # type: ignore + +from jaraco.context import ExceptionTrap +from jaraco.functools import compose, method_cache + + +def substitution(old, new): + """ + Return a function that will perform a substitution on a string + """ + return lambda s: s.replace(old, new) + + +def multi_substitution(*substitutions): + """ + Take a sequence of pairs specifying substitutions, and create + a function that performs those substitutions. + + >>> multi_substitution(('foo', 'bar'), ('bar', 'baz'))('foo') + 'baz' + """ + substitutions = itertools.starmap(substitution, substitutions) + # compose function applies last function first, so reverse the + # substitutions to get the expected order. + substitutions = reversed(tuple(substitutions)) + return compose(*substitutions) + + +class FoldedCase(str): + """ + A case insensitive string class; behaves just like str + except compares equal when the only variation is case. + + >>> s = FoldedCase('hello world') + + >>> s == 'Hello World' + True + + >>> 'Hello World' == s + True + + >>> s != 'Hello World' + False + + >>> s.index('O') + 4 + + >>> s.split('O') + ['hell', ' w', 'rld'] + + >>> sorted(map(FoldedCase, ['GAMMA', 'alpha', 'Beta'])) + ['alpha', 'Beta', 'GAMMA'] + + Sequence membership is straightforward. + + >>> "Hello World" in [s] + True + >>> s in ["Hello World"] + True + + Allows testing for set inclusion, but candidate and elements + must both be folded. + + >>> FoldedCase("Hello World") in {s} + True + >>> s in {FoldedCase("Hello World")} + True + + String inclusion works as long as the FoldedCase object + is on the right. + + >>> "hello" in FoldedCase("Hello World") + True + + But not if the FoldedCase object is on the left: + + >>> FoldedCase('hello') in 'Hello World' + False + + In that case, use ``in_``: + + >>> FoldedCase('hello').in_('Hello World') + True + + >>> FoldedCase('hello') > FoldedCase('Hello') + False + + >>> FoldedCase('ß') == FoldedCase('ss') + True + """ + + def __lt__(self, other): + return self.casefold() < other.casefold() + + def __gt__(self, other): + return self.casefold() > other.casefold() + + def __eq__(self, other): + return self.casefold() == other.casefold() + + def __ne__(self, other): + return self.casefold() != other.casefold() + + def __hash__(self): + return hash(self.casefold()) + + def __contains__(self, other): + return super().casefold().__contains__(other.casefold()) + + def in_(self, other): + "Does self appear in other?" + return self in FoldedCase(other) + + # cache casefold since it's likely to be called frequently. + @method_cache + def casefold(self): + return super().casefold() + + def index(self, sub): + return self.casefold().index(sub.casefold()) + + def split(self, splitter=' ', maxsplit=0): + pattern = re.compile(re.escape(splitter), re.I) + return pattern.split(self, maxsplit) + + +# Python 3.8 compatibility +_unicode_trap = ExceptionTrap(UnicodeDecodeError) + + +@_unicode_trap.passes +def is_decodable(value): + r""" + Return True if the supplied value is decodable (using the default + encoding). + + >>> is_decodable(b'\xff') + False + >>> is_decodable(b'\x32') + True + """ + value.decode() + + +def is_binary(value): + r""" + Return True if the value appears to be binary (that is, it's a byte + string and isn't decodable). + + >>> is_binary(b'\xff') + True + >>> is_binary('\xff') + False + """ + return isinstance(value, bytes) and not is_decodable(value) + + +def trim(s): + r""" + Trim something like a docstring to remove the whitespace that + is common due to indentation and formatting. + + >>> trim("\n\tfoo = bar\n\t\tbar = baz\n") + 'foo = bar\n\tbar = baz' + """ + return textwrap.dedent(s).strip() + + +def wrap(s): + """ + Wrap lines of text, retaining existing newlines as + paragraph markers. + + >>> print(wrap(lorem_ipsum)) + Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do + eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad + minim veniam, quis nostrud exercitation ullamco laboris nisi ut + aliquip ex ea commodo consequat. Duis aute irure dolor in + reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla + pariatur. Excepteur sint occaecat cupidatat non proident, sunt in + culpa qui officia deserunt mollit anim id est laborum. + <BLANKLINE> + Curabitur pretium tincidunt lacus. Nulla gravida orci a odio. Nullam + varius, turpis et commodo pharetra, est eros bibendum elit, nec luctus + magna felis sollicitudin mauris. Integer in mauris eu nibh euismod + gravida. Duis ac tellus et risus vulputate vehicula. Donec lobortis + risus a elit. Etiam tempor. Ut ullamcorper, ligula eu tempor congue, + eros est euismod turpis, id tincidunt sapien risus a quam. Maecenas + fermentum consequat mi. Donec fermentum. Pellentesque malesuada nulla + a mi. Duis sapien sem, aliquet nec, commodo eget, consequat quis, + neque. Aliquam faucibus, elit ut dictum aliquet, felis nisl adipiscing + sapien, sed malesuada diam lacus eget erat. Cras mollis scelerisque + nunc. Nullam arcu. Aliquam consequat. Curabitur augue lorem, dapibus + quis, laoreet et, pretium ac, nisi. Aenean magna nisl, mollis quis, + molestie eu, feugiat in, orci. In hac habitasse platea dictumst. + """ + paragraphs = s.splitlines() + wrapped = ('\n'.join(textwrap.wrap(para)) for para in paragraphs) + return '\n\n'.join(wrapped) + + +def unwrap(s): + r""" + Given a multi-line string, return an unwrapped version. + + >>> wrapped = wrap(lorem_ipsum) + >>> wrapped.count('\n') + 20 + >>> unwrapped = unwrap(wrapped) + >>> unwrapped.count('\n') + 1 + >>> print(unwrapped) + Lorem ipsum dolor sit amet, consectetur adipiscing ... + Curabitur pretium tincidunt lacus. Nulla gravida orci ... + + """ + paragraphs = re.split(r'\n\n+', s) + cleaned = (para.replace('\n', ' ') for para in paragraphs) + return '\n'.join(cleaned) + + +lorem_ipsum: str = ( + files(__name__).joinpath('Lorem ipsum.txt').read_text(encoding='utf-8') +) + + +class Splitter: + """object that will split a string with the given arguments for each call + + >>> s = Splitter(',') + >>> s('hello, world, this is your, master calling') + ['hello', ' world', ' this is your', ' master calling'] + """ + + def __init__(self, *args): + self.args = args + + def __call__(self, s): + return s.split(*self.args) + + +def indent(string, prefix=' ' * 4): + """ + >>> indent('foo') + ' foo' + """ + return prefix + string + + +class WordSet(tuple): + """ + Given an identifier, return the words that identifier represents, + whether in camel case, underscore-separated, etc. + + >>> WordSet.parse("camelCase") + ('camel', 'Case') + + >>> WordSet.parse("under_sep") + ('under', 'sep') + + Acronyms should be retained + + >>> WordSet.parse("firstSNL") + ('first', 'SNL') + + >>> WordSet.parse("you_and_I") + ('you', 'and', 'I') + + >>> WordSet.parse("A simple test") + ('A', 'simple', 'test') + + Multiple caps should not interfere with the first cap of another word. + + >>> WordSet.parse("myABCClass") + ('my', 'ABC', 'Class') + + The result is a WordSet, providing access to other forms. + + >>> WordSet.parse("myABCClass").underscore_separated() + 'my_ABC_Class' + + >>> WordSet.parse('a-command').camel_case() + 'ACommand' + + >>> WordSet.parse('someIdentifier').lowered().space_separated() + 'some identifier' + + Slices of the result should return another WordSet. + + >>> WordSet.parse('taken-out-of-context')[1:].underscore_separated() + 'out_of_context' + + >>> WordSet.from_class_name(WordSet()).lowered().space_separated() + 'word set' + + >>> example = WordSet.parse('figured it out') + >>> example.headless_camel_case() + 'figuredItOut' + >>> example.dash_separated() + 'figured-it-out' + + """ + + _pattern = re.compile('([A-Z]?[a-z]+)|([A-Z]+(?![a-z]))') + + def capitalized(self): + return WordSet(word.capitalize() for word in self) + + def lowered(self): + return WordSet(word.lower() for word in self) + + def camel_case(self): + return ''.join(self.capitalized()) + + def headless_camel_case(self): + words = iter(self) + first = next(words).lower() + new_words = itertools.chain((first,), WordSet(words).camel_case()) + return ''.join(new_words) + + def underscore_separated(self): + return '_'.join(self) + + def dash_separated(self): + return '-'.join(self) + + def space_separated(self): + return ' '.join(self) + + def trim_right(self, item): + """ + Remove the item from the end of the set. + + >>> WordSet.parse('foo bar').trim_right('foo') + ('foo', 'bar') + >>> WordSet.parse('foo bar').trim_right('bar') + ('foo',) + >>> WordSet.parse('').trim_right('bar') + () + """ + return self[:-1] if self and self[-1] == item else self + + def trim_left(self, item): + """ + Remove the item from the beginning of the set. + + >>> WordSet.parse('foo bar').trim_left('foo') + ('bar',) + >>> WordSet.parse('foo bar').trim_left('bar') + ('foo', 'bar') + >>> WordSet.parse('').trim_left('bar') + () + """ + return self[1:] if self and self[0] == item else self + + def trim(self, item): + """ + >>> WordSet.parse('foo bar').trim('foo') + ('bar',) + """ + return self.trim_left(item).trim_right(item) + + def __getitem__(self, item): + result = super().__getitem__(item) + if isinstance(item, slice): + result = WordSet(result) + return result + + @classmethod + def parse(cls, identifier): + matches = cls._pattern.finditer(identifier) + return WordSet(match.group(0) for match in matches) + + @classmethod + def from_class_name(cls, subject): + return cls.parse(subject.__class__.__name__) + + +# for backward compatibility +words = WordSet.parse + + +def simple_html_strip(s): + r""" + Remove HTML from the string `s`. + + >>> str(simple_html_strip('')) + '' + + >>> print(simple_html_strip('A <bold>stormy</bold> day in paradise')) + A stormy day in paradise + + >>> print(simple_html_strip('Somebody <!-- do not --> tell the truth.')) + Somebody tell the truth. + + >>> print(simple_html_strip('What about<br/>\nmultiple lines?')) + What about + multiple lines? + """ + html_stripper = re.compile('(<!--.*?-->)|(<[^>]*>)|([^<]+)', re.DOTALL) + texts = (match.group(3) or '' for match in html_stripper.finditer(s)) + return ''.join(texts) + + +class SeparatedValues(str): + """ + A string separated by a separator. Overrides __iter__ for getting + the values. + + >>> list(SeparatedValues('a,b,c')) + ['a', 'b', 'c'] + + Whitespace is stripped and empty values are discarded. + + >>> list(SeparatedValues(' a, b , c, ')) + ['a', 'b', 'c'] + """ + + separator = ',' + + def __iter__(self): + parts = self.split(self.separator) + return filter(None, (part.strip() for part in parts)) + + +class Stripper: + r""" + Given a series of lines, find the common prefix and strip it from them. + + >>> lines = [ + ... 'abcdefg\n', + ... 'abc\n', + ... 'abcde\n', + ... ] + >>> res = Stripper.strip_prefix(lines) + >>> res.prefix + 'abc' + >>> list(res.lines) + ['defg\n', '\n', 'de\n'] + + If no prefix is common, nothing should be stripped. + + >>> lines = [ + ... 'abcd\n', + ... '1234\n', + ... ] + >>> res = Stripper.strip_prefix(lines) + >>> res.prefix = '' + >>> list(res.lines) + ['abcd\n', '1234\n'] + """ + + def __init__(self, prefix, lines): + self.prefix = prefix + self.lines = map(self, lines) + + @classmethod + def strip_prefix(cls, lines): + prefix_lines, lines = itertools.tee(lines) + prefix = functools.reduce(cls.common_prefix, prefix_lines) + return cls(prefix, lines) + + def __call__(self, line): + if not self.prefix: + return line + null, prefix, rest = line.partition(self.prefix) + return rest + + @staticmethod + def common_prefix(s1, s2): + """ + Return the common prefix of two lines. + """ + index = min(len(s1), len(s2)) + while s1[:index] != s2[:index]: + index -= 1 + return s1[:index] + + +def remove_prefix(text, prefix): + """ + Remove the prefix from the text if it exists. + + >>> remove_prefix('underwhelming performance', 'underwhelming ') + 'performance' + + >>> remove_prefix('something special', 'sample') + 'something special' + """ + null, prefix, rest = text.rpartition(prefix) + return rest + + +def remove_suffix(text, suffix): + """ + Remove the suffix from the text if it exists. + + >>> remove_suffix('name.git', '.git') + 'name' + + >>> remove_suffix('something special', 'sample') + 'something special' + """ + rest, suffix, null = text.partition(suffix) + return rest + + +def normalize_newlines(text): + r""" + Replace alternate newlines with the canonical newline. + + >>> normalize_newlines('Lorem Ipsum\u2029') + 'Lorem Ipsum\n' + >>> normalize_newlines('Lorem Ipsum\r\n') + 'Lorem Ipsum\n' + >>> normalize_newlines('Lorem Ipsum\x85') + 'Lorem Ipsum\n' + """ + newlines = ['\r\n', '\r', '\n', '\u0085', '\u2028', '\u2029'] + pattern = '|'.join(newlines) + return re.sub(pattern, '\n', text) + + +def _nonblank(str): + return str and not str.startswith('#') + + +@functools.singledispatch +def yield_lines(iterable): + r""" + Yield valid lines of a string or iterable. + + >>> list(yield_lines('')) + [] + >>> list(yield_lines(['foo', 'bar'])) + ['foo', 'bar'] + >>> list(yield_lines('foo\nbar')) + ['foo', 'bar'] + >>> list(yield_lines('\nfoo\n#bar\nbaz #comment')) + ['foo', 'baz #comment'] + >>> list(yield_lines(['foo\nbar', 'baz', 'bing\n\n\n'])) + ['foo', 'bar', 'baz', 'bing'] + """ + return itertools.chain.from_iterable(map(yield_lines, iterable)) + + +@yield_lines.register(str) +def _(text): + return clean(text.splitlines()) + + +def clean(lines: Iterable[str]): + """ + Yield non-blank, non-comment elements from lines. + """ + return filter(_nonblank, map(str.strip, lines)) + + +def drop_comment(line): + """ + Drop comments. + + >>> drop_comment('foo # bar') + 'foo' + + A hash without a space may be in a URL. + + >>> drop_comment('http://example.com/foo#bar') + 'http://example.com/foo#bar' + """ + return line.partition(' #')[0] + + +def join_continuation(lines): + r""" + Join lines continued by a trailing backslash. + + >>> list(join_continuation(['foo \\', 'bar', 'baz'])) + ['foobar', 'baz'] + >>> list(join_continuation(['foo \\', 'bar', 'baz'])) + ['foobar', 'baz'] + >>> list(join_continuation(['foo \\', 'bar \\', 'baz'])) + ['foobarbaz'] + + Not sure why, but... + The character preceding the backslash is also elided. + + >>> list(join_continuation(['goo\\', 'dly'])) + ['godly'] + + A terrible idea, but... + If no line is available to continue, suppress the lines. + + >>> list(join_continuation(['foo', 'bar\\', 'baz\\'])) + ['foo'] + """ + lines = iter(lines) + for item in lines: + while item.endswith('\\'): + try: + item = item[:-2].strip() + next(lines) + except StopIteration: + return + yield item + + +def read_newlines(filename, limit=1024): + r""" + >>> tmp_path = getfixture('tmp_path') + >>> filename = tmp_path / 'out.txt' + >>> _ = filename.write_text('foo\n', newline='', encoding='utf-8') + >>> read_newlines(filename) + '\n' + >>> _ = filename.write_text('foo\r\n', newline='', encoding='utf-8') + >>> read_newlines(filename) + '\r\n' + >>> _ = filename.write_text('foo\r\nbar\nbing\r', newline='', encoding='utf-8') + >>> read_newlines(filename) + ('\r', '\n', '\r\n') + """ + with open(filename, encoding='utf-8') as fp: + fp.read(limit) + return fp.newlines + + +def lines_from(input): + """ + Generate lines from a :class:`importlib.resources.abc.Traversable` path. + + >>> lines = lines_from(files(__name__).joinpath('Lorem ipsum.txt')) + >>> next(lines) + 'Lorem ipsum...' + >>> next(lines) + 'Curabitur pretium...' + """ + with input.open(encoding='utf-8') as stream: + yield from stream diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/show-newlines.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/show-newlines.py new file mode 100644 index 0000000000000000000000000000000000000000..ef4cc54c9e457728d63e9fb6033950fed074016c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/show-newlines.py @@ -0,0 +1,32 @@ +import autocommand +import inflect +from more_itertools import always_iterable + +import jaraco.text + + +def report_newlines(filename): + r""" + Report the newlines in the indicated file. + + >>> tmp_path = getfixture('tmp_path') + >>> filename = tmp_path / 'out.txt' + >>> _ = filename.write_text('foo\nbar\n', newline='', encoding='utf-8') + >>> report_newlines(filename) + newline is '\n' + >>> filename = tmp_path / 'out.txt' + >>> _ = filename.write_text('foo\nbar\r\n', newline='', encoding='utf-8') + >>> report_newlines(filename) + newlines are ('\n', '\r\n') + """ + newlines = jaraco.text.read_newlines(filename) + count = len(tuple(always_iterable(newlines))) + engine = inflect.engine() + print( + engine.plural_noun("newline", count), + engine.plural_verb("is", count), + repr(newlines), + ) + + +autocommand.autocommand(__name__)(report_newlines) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/strip-prefix.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/strip-prefix.py new file mode 100644 index 0000000000000000000000000000000000000000..761717a9b9e1f837eeacf0e888822f6fad881361 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/strip-prefix.py @@ -0,0 +1,21 @@ +import sys + +import autocommand + +from jaraco.text import Stripper + + +def strip_prefix(): + r""" + Strip any common prefix from stdin. + + >>> import io, pytest + >>> getfixture('monkeypatch').setattr('sys.stdin', io.StringIO('abcdef\nabc123')) + >>> strip_prefix() + def + 123 + """ + sys.stdout.writelines(Stripper.strip_prefix(sys.stdin).lines) + + +autocommand.autocommand(__name__)(strip_prefix) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/to-dvorak.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/to-dvorak.py new file mode 100644 index 0000000000000000000000000000000000000000..14c8981e441dee59afa715853c87a84796b931fc --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/to-dvorak.py @@ -0,0 +1,5 @@ +import sys + +from . import layouts + +__name__ == '__main__' and layouts._translate_stream(sys.stdin, layouts.to_dvorak) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/to-qwerty.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/to-qwerty.py new file mode 100644 index 0000000000000000000000000000000000000000..23596fda930cde864e643152ec706b6149f130f2 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/_vendor/jaraco/text/to-qwerty.py @@ -0,0 +1,5 @@ +import sys + +from . import layouts + +__name__ == '__main__' and layouts._translate_stream(sys.stdin, layouts.to_qwerty) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/NOTICE b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/NOTICE new file mode 100644 index 0000000000000000000000000000000000000000..74e8821fc84b4d62796e08b3941c1a6e2017e1e8 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/NOTICE @@ -0,0 +1,438 @@ +The code contained in this directory was automatically generated using the +following command: + + python -m validate_pyproject.pre_compile --output-dir=setuptools/config/_validate_pyproject --enable-plugins setuptools distutils --very-verbose -t distutils=setuptools/config/distutils.schema.json -t setuptools=setuptools/config/setuptools.schema.json + +Please avoid changing it manually. + + +You can report issues or suggest changes directly to `validate-pyproject` +(or to the relevant plugin repository) + +- https://github.com/abravalheri/validate-pyproject/issues + + +*** + +The following files include code from opensource projects +(either as direct copies or modified versions): + +- `fastjsonschema_exceptions.py`: + - project: `fastjsonschema` - licensed under BSD-3-Clause + (https://github.com/horejsek/python-fastjsonschema) +- `extra_validations.py` and `format.py`, `error_reporting.py`: + - project: `validate-pyproject` - licensed under MPL-2.0 + (https://github.com/abravalheri/validate-pyproject) + + +Additionally the following files are automatically generated by tools provided +by the same projects: + +- `__init__.py` +- `fastjsonschema_validations.py` + +The relevant copyright notes and licenses are included below. + + +*** + +`fastjsonschema` +================ + +Copyright (c) 2018, Michal Horejsek +All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, +are permitted provided that the following conditions are met: + + Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright notice, this + list of conditions and the following disclaimer in the documentation and/or + other materials provided with the distribution. + + Neither the name of the {organization} nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + + +*** + +`validate-pyproject` +==================== + +Mozilla Public License, version 2.0 + +1. Definitions + +1.1. "Contributor" + + means each individual or legal entity that creates, contributes to the + creation of, or owns Covered Software. + +1.2. "Contributor Version" + + means the combination of the Contributions of others (if any) used by a + Contributor and that particular Contributor's Contribution. + +1.3. "Contribution" + + means Covered Software of a particular Contributor. + +1.4. "Covered Software" + + means Source Code Form to which the initial Contributor has attached the + notice in Exhibit A, the Executable Form of such Source Code Form, and + Modifications of such Source Code Form, in each case including portions + thereof. + +1.5. "Incompatible With Secondary Licenses" + means + + a. that the initial Contributor has attached the notice described in + Exhibit B to the Covered Software; or + + b. that the Covered Software was made available under the terms of + version 1.1 or earlier of the License, but not also under the terms of + a Secondary License. + +1.6. "Executable Form" + + means any form of the work other than Source Code Form. + +1.7. "Larger Work" + + means a work that combines Covered Software with other material, in a + separate file or files, that is not Covered Software. + +1.8. "License" + + means this document. + +1.9. "Licensable" + + means having the right to grant, to the maximum extent possible, whether + at the time of the initial grant or subsequently, any and all of the + rights conveyed by this License. + +1.10. "Modifications" + + means any of the following: + + a. any file in Source Code Form that results from an addition to, + deletion from, or modification of the contents of Covered Software; or + + b. any new file in Source Code Form that contains any Covered Software. + +1.11. "Patent Claims" of a Contributor + + means any patent claim(s), including without limitation, method, + process, and apparatus claims, in any patent Licensable by such + Contributor that would be infringed, but for the grant of the License, + by the making, using, selling, offering for sale, having made, import, + or transfer of either its Contributions or its Contributor Version. + +1.12. "Secondary License" + + means either the GNU General Public License, Version 2.0, the GNU Lesser + General Public License, Version 2.1, the GNU Affero General Public + License, Version 3.0, or any later versions of those licenses. + +1.13. "Source Code Form" + + means the form of the work preferred for making modifications. + +1.14. "You" (or "Your") + + means an individual or a legal entity exercising rights under this + License. For legal entities, "You" includes any entity that controls, is + controlled by, or is under common control with You. For purposes of this + definition, "control" means (a) the power, direct or indirect, to cause + the direction or management of such entity, whether by contract or + otherwise, or (b) ownership of more than fifty percent (50%) of the + outstanding shares or beneficial ownership of such entity. + + +2. License Grants and Conditions + +2.1. Grants + + Each Contributor hereby grants You a world-wide, royalty-free, + non-exclusive license: + + a. under intellectual property rights (other than patent or trademark) + Licensable by such Contributor to use, reproduce, make available, + modify, display, perform, distribute, and otherwise exploit its + Contributions, either on an unmodified basis, with Modifications, or + as part of a Larger Work; and + + b. under Patent Claims of such Contributor to make, use, sell, offer for + sale, have made, import, and otherwise transfer either its + Contributions or its Contributor Version. + +2.2. Effective Date + + The licenses granted in Section 2.1 with respect to any Contribution + become effective for each Contribution on the date the Contributor first + distributes such Contribution. + +2.3. Limitations on Grant Scope + + The licenses granted in this Section 2 are the only rights granted under + this License. No additional rights or licenses will be implied from the + distribution or licensing of Covered Software under this License. + Notwithstanding Section 2.1(b) above, no patent license is granted by a + Contributor: + + a. for any code that a Contributor has removed from Covered Software; or + + b. for infringements caused by: (i) Your and any other third party's + modifications of Covered Software, or (ii) the combination of its + Contributions with other software (except as part of its Contributor + Version); or + + c. under Patent Claims infringed by Covered Software in the absence of + its Contributions. + + This License does not grant any rights in the trademarks, service marks, + or logos of any Contributor (except as may be necessary to comply with + the notice requirements in Section 3.4). + +2.4. Subsequent Licenses + + No Contributor makes additional grants as a result of Your choice to + distribute the Covered Software under a subsequent version of this + License (see Section 10.2) or under the terms of a Secondary License (if + permitted under the terms of Section 3.3). + +2.5. Representation + + Each Contributor represents that the Contributor believes its + Contributions are its original creation(s) or it has sufficient rights to + grant the rights to its Contributions conveyed by this License. + +2.6. Fair Use + + This License is not intended to limit any rights You have under + applicable copyright doctrines of fair use, fair dealing, or other + equivalents. + +2.7. Conditions + + Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted in + Section 2.1. + + +3. Responsibilities + +3.1. Distribution of Source Form + + All distribution of Covered Software in Source Code Form, including any + Modifications that You create or to which You contribute, must be under + the terms of this License. You must inform recipients that the Source + Code Form of the Covered Software is governed by the terms of this + License, and how they can obtain a copy of this License. You may not + attempt to alter or restrict the recipients' rights in the Source Code + Form. + +3.2. Distribution of Executable Form + + If You distribute Covered Software in Executable Form then: + + a. such Covered Software must also be made available in Source Code Form, + as described in Section 3.1, and You must inform recipients of the + Executable Form how they can obtain a copy of such Source Code Form by + reasonable means in a timely manner, at a charge no more than the cost + of distribution to the recipient; and + + b. You may distribute such Executable Form under the terms of this + License, or sublicense it under different terms, provided that the + license for the Executable Form does not attempt to limit or alter the + recipients' rights in the Source Code Form under this License. + +3.3. Distribution of a Larger Work + + You may create and distribute a Larger Work under terms of Your choice, + provided that You also comply with the requirements of this License for + the Covered Software. If the Larger Work is a combination of Covered + Software with a work governed by one or more Secondary Licenses, and the + Covered Software is not Incompatible With Secondary Licenses, this + License permits You to additionally distribute such Covered Software + under the terms of such Secondary License(s), so that the recipient of + the Larger Work may, at their option, further distribute the Covered + Software under the terms of either this License or such Secondary + License(s). + +3.4. Notices + + You may not remove or alter the substance of any license notices + (including copyright notices, patent notices, disclaimers of warranty, or + limitations of liability) contained within the Source Code Form of the + Covered Software, except that You may alter any license notices to the + extent required to remedy known factual inaccuracies. + +3.5. Application of Additional Terms + + You may choose to offer, and to charge a fee for, warranty, support, + indemnity or liability obligations to one or more recipients of Covered + Software. However, You may do so only on Your own behalf, and not on + behalf of any Contributor. You must make it absolutely clear that any + such warranty, support, indemnity, or liability obligation is offered by + You alone, and You hereby agree to indemnify every Contributor for any + liability incurred by such Contributor as a result of warranty, support, + indemnity or liability terms You offer. You may include additional + disclaimers of warranty and limitations of liability specific to any + jurisdiction. + +4. Inability to Comply Due to Statute or Regulation + + If it is impossible for You to comply with any of the terms of this License + with respect to some or all of the Covered Software due to statute, + judicial order, or regulation then You must: (a) comply with the terms of + this License to the maximum extent possible; and (b) describe the + limitations and the code they affect. Such description must be placed in a + text file included with all distributions of the Covered Software under + this License. Except to the extent prohibited by statute or regulation, + such description must be sufficiently detailed for a recipient of ordinary + skill to be able to understand it. + +5. Termination + +5.1. The rights granted under this License will terminate automatically if You + fail to comply with any of its terms. However, if You become compliant, + then the rights granted under this License from a particular Contributor + are reinstated (a) provisionally, unless and until such Contributor + explicitly and finally terminates Your grants, and (b) on an ongoing + basis, if such Contributor fails to notify You of the non-compliance by + some reasonable means prior to 60 days after You have come back into + compliance. Moreover, Your grants from a particular Contributor are + reinstated on an ongoing basis if such Contributor notifies You of the + non-compliance by some reasonable means, this is the first time You have + received notice of non-compliance with this License from such + Contributor, and You become compliant prior to 30 days after Your receipt + of the notice. + +5.2. If You initiate litigation against any entity by asserting a patent + infringement claim (excluding declaratory judgment actions, + counter-claims, and cross-claims) alleging that a Contributor Version + directly or indirectly infringes any patent, then the rights granted to + You by any and all Contributors for the Covered Software under Section + 2.1 of this License shall terminate. + +5.3. In the event of termination under Sections 5.1 or 5.2 above, all end user + license agreements (excluding distributors and resellers) which have been + validly granted by You or Your distributors under this License prior to + termination shall survive termination. + +6. Disclaimer of Warranty + + Covered Software is provided under this License on an "as is" basis, + without warranty of any kind, either expressed, implied, or statutory, + including, without limitation, warranties that the Covered Software is free + of defects, merchantable, fit for a particular purpose or non-infringing. + The entire risk as to the quality and performance of the Covered Software + is with You. Should any Covered Software prove defective in any respect, + You (not any Contributor) assume the cost of any necessary servicing, + repair, or correction. This disclaimer of warranty constitutes an essential + part of this License. No use of any Covered Software is authorized under + this License except under this disclaimer. + +7. Limitation of Liability + + Under no circumstances and under no legal theory, whether tort (including + negligence), contract, or otherwise, shall any Contributor, or anyone who + distributes Covered Software as permitted above, be liable to You for any + direct, indirect, special, incidental, or consequential damages of any + character including, without limitation, damages for lost profits, loss of + goodwill, work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses, even if such party shall have been + informed of the possibility of such damages. This limitation of liability + shall not apply to liability for death or personal injury resulting from + such party's negligence to the extent applicable law prohibits such + limitation. Some jurisdictions do not allow the exclusion or limitation of + incidental or consequential damages, so this exclusion and limitation may + not apply to You. + +8. Litigation + + Any litigation relating to this License may be brought only in the courts + of a jurisdiction where the defendant maintains its principal place of + business and such litigation shall be governed by laws of that + jurisdiction, without reference to its conflict-of-law provisions. Nothing + in this Section shall prevent a party's ability to bring cross-claims or + counter-claims. + +9. Miscellaneous + + This License represents the complete agreement concerning the subject + matter hereof. If any provision of this License is held to be + unenforceable, such provision shall be reformed only to the extent + necessary to make it enforceable. Any law or regulation which provides that + the language of a contract shall be construed against the drafter shall not + be used to construe this License against a Contributor. + + +10. Versions of the License + +10.1. New Versions + + Mozilla Foundation is the license steward. Except as provided in Section + 10.3, no one other than the license steward has the right to modify or + publish new versions of this License. Each version will be given a + distinguishing version number. + +10.2. Effect of New Versions + + You may distribute the Covered Software under the terms of the version + of the License under which You originally received the Covered Software, + or under the terms of any subsequent version published by the license + steward. + +10.3. Modified Versions + + If you create software not governed by this License, and you want to + create a new license for such software, you may create and use a + modified version of this License if you rename the license and remove + any references to the name of the license steward (except to note that + such modified license differs from this License). + +10.4. Distributing Source Code Form that is Incompatible With Secondary + Licenses If You choose to distribute Source Code Form that is + Incompatible With Secondary Licenses under the terms of this version of + the License, the notice described in Exhibit B of this License must be + attached. + +Exhibit A - Source Code Form License Notice + + This Source Code Form is subject to the + terms of the Mozilla Public License, v. + 2.0. If a copy of the MPL was not + distributed with this file, You can + obtain one at + https://mozilla.org/MPL/2.0/. + +If it is not possible or desirable to put the notice in a particular file, +then You may include the notice in a location (such as a LICENSE file in a +relevant directory) where a recipient would be likely to look for such a +notice. + +You may add additional accurate notices of copyright ownership. + +Exhibit B - "Incompatible With Secondary Licenses" Notice + + This Source Code Form is "Incompatible + With Secondary Licenses", as defined by + the Mozilla Public License, v. 2.0. diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..4f612bd51c4ac1d272318ed6fb96e4aeb57e3e27 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/__init__.py @@ -0,0 +1,34 @@ +from functools import reduce +from typing import Any, Callable, Dict + +from . import formats +from .error_reporting import detailed_errors, ValidationError +from .extra_validations import EXTRA_VALIDATIONS +from .fastjsonschema_exceptions import JsonSchemaException, JsonSchemaValueException +from .fastjsonschema_validations import validate as _validate + +__all__ = [ + "validate", + "FORMAT_FUNCTIONS", + "EXTRA_VALIDATIONS", + "ValidationError", + "JsonSchemaException", + "JsonSchemaValueException", +] + + +FORMAT_FUNCTIONS: Dict[str, Callable[[str], bool]] = { + fn.__name__.replace("_", "-"): fn + for fn in formats.__dict__.values() + if callable(fn) and not fn.__name__.startswith("_") +} + + +def validate(data: Any) -> bool: + """Validate the given ``data`` object using JSON Schema + This function raises ``ValidationError`` if ``data`` is invalid. + """ + with detailed_errors(): + _validate(data, custom_formats=FORMAT_FUNCTIONS) + reduce(lambda acc, fn: fn(acc), EXTRA_VALIDATIONS, data) + return True diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/error_reporting.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/error_reporting.py new file mode 100644 index 0000000000000000000000000000000000000000..9ebe6a335c9308a79c147ed2ae2e4085e9964013 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/error_reporting.py @@ -0,0 +1,338 @@ +from __future__ import annotations + +import io +import json +import logging +import os +import re +import typing +from contextlib import contextmanager +from textwrap import indent, wrap +from typing import Any, Generator, Iterator, Sequence + +from .fastjsonschema_exceptions import JsonSchemaValueException + +if typing.TYPE_CHECKING: + import sys + + if sys.version_info < (3, 11): + from typing_extensions import Self + else: + from typing import Self + +_logger = logging.getLogger(__name__) + +_MESSAGE_REPLACEMENTS = { + "must be named by propertyName definition": "keys must be named by", + "one of contains definition": "at least one item that matches", + " same as const definition:": "", + "only specified items": "only items matching the definition", +} + +_SKIP_DETAILS = ( + "must not be empty", + "is always invalid", + "must not be there", +) + +_NEED_DETAILS = {"anyOf", "oneOf", "allOf", "contains", "propertyNames", "not", "items"} + +_CAMEL_CASE_SPLITTER = re.compile(r"\W+|([A-Z][^A-Z\W]*)") +_IDENTIFIER = re.compile(r"^[\w_]+$", re.IGNORECASE) + +_TOML_JARGON = { + "object": "table", + "property": "key", + "properties": "keys", + "property names": "keys", +} + +_FORMATS_HELP = """ +For more details about `format` see +https://validate-pyproject.readthedocs.io/en/latest/api/validate_pyproject.formats.html +""" + + +class ValidationError(JsonSchemaValueException): + """Report violations of a given JSON schema. + + This class extends :exc:`~fastjsonschema.JsonSchemaValueException` + by adding the following properties: + + - ``summary``: an improved version of the ``JsonSchemaValueException`` error message + with only the necessary information) + + - ``details``: more contextual information about the error like the failing schema + itself and the value that violates the schema. + + Depending on the level of the verbosity of the ``logging`` configuration + the exception message will be only ``summary`` (default) or a combination of + ``summary`` and ``details`` (when the logging level is set to :obj:`logging.DEBUG`). + """ + + summary = "" + details = "" + _original_message = "" + + @classmethod + def _from_jsonschema(cls, ex: JsonSchemaValueException) -> Self: + formatter = _ErrorFormatting(ex) + obj = cls(str(formatter), ex.value, formatter.name, ex.definition, ex.rule) + debug_code = os.getenv("JSONSCHEMA_DEBUG_CODE_GENERATION", "false").lower() + if debug_code != "false": # pragma: no cover + obj.__cause__, obj.__traceback__ = ex.__cause__, ex.__traceback__ + obj._original_message = ex.message + obj.summary = formatter.summary + obj.details = formatter.details + return obj + + +@contextmanager +def detailed_errors() -> Generator[None, None, None]: + try: + yield + except JsonSchemaValueException as ex: + raise ValidationError._from_jsonschema(ex) from None + + +class _ErrorFormatting: + def __init__(self, ex: JsonSchemaValueException): + self.ex = ex + self.name = f"`{self._simplify_name(ex.name)}`" + self._original_message: str = self.ex.message.replace(ex.name, self.name) + self._summary = "" + self._details = "" + + def __str__(self) -> str: + if _logger.getEffectiveLevel() <= logging.DEBUG and self.details: + return f"{self.summary}\n\n{self.details}" + + return self.summary + + @property + def summary(self) -> str: + if not self._summary: + self._summary = self._expand_summary() + + return self._summary + + @property + def details(self) -> str: + if not self._details: + self._details = self._expand_details() + + return self._details + + @staticmethod + def _simplify_name(name: str) -> str: + x = len("data.") + return name[x:] if name.startswith("data.") else name + + def _expand_summary(self) -> str: + msg = self._original_message + + for bad, repl in _MESSAGE_REPLACEMENTS.items(): + msg = msg.replace(bad, repl) + + if any(substring in msg for substring in _SKIP_DETAILS): + return msg + + schema = self.ex.rule_definition + if self.ex.rule in _NEED_DETAILS and schema: + summary = _SummaryWriter(_TOML_JARGON) + return f"{msg}:\n\n{indent(summary(schema), ' ')}" + + return msg + + def _expand_details(self) -> str: + optional = [] + definition = self.ex.definition or {} + desc_lines = definition.pop("$$description", []) + desc = definition.pop("description", None) or " ".join(desc_lines) + if desc: + description = "\n".join( + wrap( + desc, + width=80, + initial_indent=" ", + subsequent_indent=" ", + break_long_words=False, + ) + ) + optional.append(f"DESCRIPTION:\n{description}") + schema = json.dumps(definition, indent=4) + value = json.dumps(self.ex.value, indent=4) + defaults = [ + f"GIVEN VALUE:\n{indent(value, ' ')}", + f"OFFENDING RULE: {self.ex.rule!r}", + f"DEFINITION:\n{indent(schema, ' ')}", + ] + msg = "\n\n".join(optional + defaults) + epilog = f"\n{_FORMATS_HELP}" if "format" in msg.lower() else "" + return msg + epilog + + +class _SummaryWriter: + _IGNORE = frozenset(("description", "default", "title", "examples")) + + def __init__(self, jargon: dict[str, str] | None = None): + self.jargon: dict[str, str] = jargon or {} + # Clarify confusing terms + self._terms = { + "anyOf": "at least one of the following", + "oneOf": "exactly one of the following", + "allOf": "all of the following", + "not": "(*NOT* the following)", + "prefixItems": f"{self._jargon('items')} (in order)", + "items": "items", + "contains": "contains at least one of", + "propertyNames": ( + f"non-predefined acceptable {self._jargon('property names')}" + ), + "patternProperties": f"{self._jargon('properties')} named via pattern", + "const": "predefined value", + "enum": "one of", + } + # Attributes that indicate that the definition is easy and can be done + # inline (e.g. string and number) + self._guess_inline_defs = [ + "enum", + "const", + "maxLength", + "minLength", + "pattern", + "format", + "minimum", + "maximum", + "exclusiveMinimum", + "exclusiveMaximum", + "multipleOf", + ] + + def _jargon(self, term: str | list[str]) -> str | list[str]: + if isinstance(term, list): + return [self.jargon.get(t, t) for t in term] + return self.jargon.get(term, term) + + def __call__( + self, + schema: dict | list[dict], + prefix: str = "", + *, + _path: Sequence[str] = (), + ) -> str: + if isinstance(schema, list): + return self._handle_list(schema, prefix, _path) + + filtered = self._filter_unecessary(schema, _path) + simple = self._handle_simple_dict(filtered, _path) + if simple: + return f"{prefix}{simple}" + + child_prefix = self._child_prefix(prefix, " ") + item_prefix = self._child_prefix(prefix, "- ") + indent = len(prefix) * " " + with io.StringIO() as buffer: + for i, (key, value) in enumerate(filtered.items()): + child_path = [*_path, key] + line_prefix = prefix if i == 0 else indent + buffer.write(f"{line_prefix}{self._label(child_path)}:") + # ^ just the first item should receive the complete prefix + if isinstance(value, dict): + filtered = self._filter_unecessary(value, child_path) + simple = self._handle_simple_dict(filtered, child_path) + buffer.write( + f" {simple}" + if simple + else f"\n{self(value, child_prefix, _path=child_path)}" + ) + elif isinstance(value, list) and ( + key != "type" or self._is_property(child_path) + ): + children = self._handle_list(value, item_prefix, child_path) + sep = " " if children.startswith("[") else "\n" + buffer.write(f"{sep}{children}") + else: + buffer.write(f" {self._value(value, child_path)}\n") + return buffer.getvalue() + + def _is_unecessary(self, path: Sequence[str]) -> bool: + if self._is_property(path) or not path: # empty path => instruction @ root + return False + key = path[-1] + return any(key.startswith(k) for k in "$_") or key in self._IGNORE + + def _filter_unecessary( + self, schema: dict[str, Any], path: Sequence[str] + ) -> dict[str, Any]: + return { + key: value + for key, value in schema.items() + if not self._is_unecessary([*path, key]) + } + + def _handle_simple_dict(self, value: dict, path: Sequence[str]) -> str | None: + inline = any(p in value for p in self._guess_inline_defs) + simple = not any(isinstance(v, (list, dict)) for v in value.values()) + if inline or simple: + return f"{{{', '.join(self._inline_attrs(value, path))}}}\n" + return None + + def _handle_list( + self, schemas: list, prefix: str = "", path: Sequence[str] = () + ) -> str: + if self._is_unecessary(path): + return "" + + repr_ = repr(schemas) + if all(not isinstance(e, (dict, list)) for e in schemas) and len(repr_) < 60: + return f"{repr_}\n" + + item_prefix = self._child_prefix(prefix, "- ") + return "".join( + self(v, item_prefix, _path=[*path, f"[{i}]"]) for i, v in enumerate(schemas) + ) + + def _is_property(self, path: Sequence[str]) -> bool: + """Check if the given path can correspond to an arbitrarily named property""" + counter = 0 + for key in path[-2::-1]: + if key not in {"properties", "patternProperties"}: + break + counter += 1 + + # If the counter if even, the path correspond to a JSON Schema keyword + # otherwise it can be any arbitrary string naming a property + return counter % 2 == 1 + + def _label(self, path: Sequence[str]) -> str: + *parents, key = path + if not self._is_property(path): + norm_key = _separate_terms(key) + return self._terms.get(key) or " ".join(self._jargon(norm_key)) + + if parents[-1] == "patternProperties": + return f"(regex {key!r})" + return repr(key) # property name + + def _value(self, value: Any, path: Sequence[str]) -> str: + if path[-1] == "type" and not self._is_property(path): + type_ = self._jargon(value) + return f"[{', '.join(type_)}]" if isinstance(type_, list) else type_ + return repr(value) + + def _inline_attrs(self, schema: dict, path: Sequence[str]) -> Iterator[str]: + for key, value in schema.items(): + child_path = [*path, key] + yield f"{self._label(child_path)}: {self._value(value, child_path)}" + + def _child_prefix(self, parent_prefix: str, child_prefix: str) -> str: + return len(parent_prefix) * " " + child_prefix + + +def _separate_terms(word: str) -> list[str]: + """ + >>> _separate_terms("FooBar-foo") + ['foo', 'bar', 'foo'] + """ + return [w.lower() for w in _CAMEL_CASE_SPLITTER.split(word) if w] diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/extra_validations.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/extra_validations.py new file mode 100644 index 0000000000000000000000000000000000000000..72a7132f2b564748679242facbb5ab241feffae5 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/extra_validations.py @@ -0,0 +1,151 @@ +"""The purpose of this module is implement PEP 621 validations that are +difficult to express as a JSON Schema (or that are not supported by the current +JSON Schema library). +""" + +import collections +import itertools +from inspect import cleandoc +from typing import Generator, Iterable, Mapping, TypeVar + +from .error_reporting import ValidationError + +T = TypeVar("T", bound=Mapping) + + +class RedefiningStaticFieldAsDynamic(ValidationError): + _DESC = """According to PEP 621: + + Build back-ends MUST raise an error if the metadata specifies a field + statically as well as being listed in dynamic. + """ + __doc__ = _DESC + _URL = ( + "https://packaging.python.org/en/latest/specifications/pyproject-toml/#dynamic" + ) + + +class IncludedDependencyGroupMustExist(ValidationError): + _DESC = """An included dependency group must exist and must not be cyclic. + """ + __doc__ = _DESC + _URL = "https://peps.python.org/pep-0735/" + + +class ImportNameCollision(ValidationError): + _DESC = """According to PEP 794: + + All import-names and import-namespaces items must be unique. + """ + __doc__ = _DESC + _URL = "https://peps.python.org/pep-0794/" + + +class ImportNameMissing(ValidationError): + _DESC = """According to PEP 794: + + An import name must have all parents listed. + """ + __doc__ = _DESC + _URL = "https://peps.python.org/pep-0794/" + + +def validate_project_dynamic(pyproject: T) -> T: + project_table = pyproject.get("project", {}) + dynamic = project_table.get("dynamic", []) + + for field in dynamic: + if field in project_table: + raise RedefiningStaticFieldAsDynamic( + message=f"You cannot provide a value for `project.{field}` and " + "list it under `project.dynamic` at the same time", + value={ + field: project_table[field], + "...": " # ...", + "dynamic": dynamic, + }, + name=f"data.project.{field}", + definition={ + "description": cleandoc(RedefiningStaticFieldAsDynamic._DESC), + "see": RedefiningStaticFieldAsDynamic._URL, + }, + rule="PEP 621", + ) + + return pyproject + + +def validate_include_depenency(pyproject: T) -> T: + dependency_groups = pyproject.get("dependency-groups", {}) + for key, value in dependency_groups.items(): + for each in value: + if ( + isinstance(each, dict) + and (include_group := each.get("include-group")) + and include_group not in dependency_groups + ): + raise IncludedDependencyGroupMustExist( + message=f"The included dependency group {include_group} doesn't exist", + value=each, + name=f"data.dependency_groups.{key}", + definition={ + "description": cleandoc(IncludedDependencyGroupMustExist._DESC), + "see": IncludedDependencyGroupMustExist._URL, + }, + rule="PEP 735", + ) + # TODO: check for `include-group` cycles (can be conditional to graphlib) + return pyproject + + +def _remove_private(items: Iterable[str]) -> Generator[str, None, None]: + for item in items: + yield item.partition(";")[0].rstrip() + + +def validate_import_name_issues(pyproject: T) -> T: + project = pyproject.get("project", {}) + import_names = collections.Counter(_remove_private(project.get("import-names", []))) + import_namespaces = collections.Counter( + _remove_private(project.get("import-namespaces", [])) + ) + + duplicated = [k for k, v in (import_names + import_namespaces).items() if v > 1] + + if duplicated: + raise ImportNameCollision( + message="Duplicated names are not allowed in import-names/import-namespaces", + value=duplicated, + name="data.project.importnames(paces)", + definition={ + "description": cleandoc(ImportNameCollision._DESC), + "see": ImportNameCollision._URL, + }, + rule="PEP 794", + ) + + names = frozenset(import_names + import_namespaces) + for name in names: + for parent in itertools.accumulate( + name.split(".")[:-1], lambda a, b: f"{a}.{b}" + ): + if parent not in names: + raise ImportNameMissing( + message="All parents of an import name must also be listed in import-namespace/import-names", + value=name, + name="data.project.importnames(paces)", + definition={ + "description": cleandoc(ImportNameMissing._DESC), + "see": ImportNameMissing._URL, + }, + rule="PEP 794", + ) + + return pyproject + + +EXTRA_VALIDATIONS = ( + validate_project_dynamic, + validate_include_depenency, + validate_import_name_issues, +) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/fastjsonschema_exceptions.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/fastjsonschema_exceptions.py new file mode 100644 index 0000000000000000000000000000000000000000..d2dddd6a106f021a4723c1e8f5953ccc09e55e1f --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/fastjsonschema_exceptions.py @@ -0,0 +1,51 @@ +import re + + +SPLIT_RE = re.compile(r'[\.\[\]]+') + + +class JsonSchemaException(ValueError): + """ + Base exception of ``fastjsonschema`` library. + """ + + +class JsonSchemaValueException(JsonSchemaException): + """ + Exception raised by validation function. Available properties: + + * ``message`` containing human-readable information what is wrong (e.g. ``data.property[index] must be smaller than or equal to 42``), + * invalid ``value`` (e.g. ``60``), + * ``name`` of a path in the data structure (e.g. ``data.property[index]``), + * ``path`` as an array in the data structure (e.g. ``['data', 'property', 'index']``), + * the whole ``definition`` which the ``value`` has to fulfil (e.g. ``{'type': 'number', 'maximum': 42}``), + * ``rule`` which the ``value`` is breaking (e.g. ``maximum``) + * and ``rule_definition`` (e.g. ``42``). + + .. versionchanged:: 2.14.0 + Added all extra properties. + """ + + def __init__(self, message, value=None, name=None, definition=None, rule=None): + super().__init__(message) + self.message = message + self.value = value + self.name = name + self.definition = definition + self.rule = rule + + @property + def path(self): + return [item for item in SPLIT_RE.split(self.name) if item != ''] + + @property + def rule_definition(self): + if not self.rule or not self.definition: + return None + return self.definition.get(self.rule) + + +class JsonSchemaDefinitionException(JsonSchemaException): + """ + Exception raised by generator of validation function. + """ diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/fastjsonschema_validations.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/fastjsonschema_validations.py new file mode 100644 index 0000000000000000000000000000000000000000..d8a03de9bfacf5e3401211ddb852354bb86c12f6 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/fastjsonschema_validations.py @@ -0,0 +1,1453 @@ +# noqa +# ruff: noqa +# flake8: noqa +# pylint: skip-file +# mypy: ignore-errors +# yapf: disable +# pylama:skip=1 + + +# *** PLEASE DO NOT MODIFY DIRECTLY: Automatically generated code *** + + +VERSION = "2.21.2" +from decimal import Decimal +import re +from .fastjsonschema_exceptions import JsonSchemaValueException + + +REGEX_PATTERNS = { + '^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$': re.compile('^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])\\Z'), + '^.*$': re.compile('^.*$'), + '.+': re.compile('.+'), + '^.+$': re.compile('^.+$'), + 'idn-email_re_pattern': re.compile('^[^@]+@[^@]+\\.[^@]+\\Z') +} + +NoneType = type(None) + +def validate(data, custom_formats={}, name_prefix=None): + validate_https___packaging_python_org_en_latest_specifications_declaring_build_dependencies(data, custom_formats, (name_prefix or "data") + "") + return data + +def validate_https___packaging_python_org_en_latest_specifications_declaring_build_dependencies(data, custom_formats={}, name_prefix=None): + if not isinstance(data, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be object", value=data, name="" + (name_prefix or "data") + "", definition={'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://packaging.python.org/en/latest/specifications/declaring-build-dependencies/', 'title': 'Data structure for ``pyproject.toml`` files', '$$description': ['File format containing build-time configurations for the Python ecosystem. ', ':pep:`517` initially defined a build-system independent format for source trees', 'which was complemented by :pep:`518` to provide a way of specifying dependencies ', 'for building Python projects.', 'Please notice the ``project`` table (as initially defined in :pep:`621`) is not included', 'in this schema and should be considered separately.'], 'type': 'object', 'additionalProperties': False, 'properties': {'build-system': {'type': 'object', 'description': 'Table used to store build-related data', 'additionalProperties': False, 'properties': {'requires': {'type': 'array', '$$description': ['List of dependencies in the :pep:`508` format required to execute the build', 'system. Please notice that the resulting dependency graph', '**MUST NOT contain cycles**'], 'items': {'type': 'string'}}, 'build-backend': {'type': 'string', 'description': 'Python object that will be used to perform the build according to :pep:`517`', 'format': 'pep517-backend-reference'}, 'backend-path': {'type': 'array', '$$description': ['List of directories to be prepended to ``sys.path`` when loading the', 'back-end, and running its hooks'], 'items': {'type': 'string', '$comment': 'Should be a path (TODO: enforce it with format?)'}}}, 'required': ['requires']}, 'project': {'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://packaging.python.org/en/latest/specifications/pyproject-toml/', 'title': 'Package metadata stored in the ``project`` table', '$$description': ['Data structure for the **project** table inside ``pyproject.toml``', '(as initially defined in :pep:`621`)'], 'type': 'object', 'properties': {'name': {'type': 'string', 'description': 'The name (primary identifier) of the project. MUST be statically defined.', 'format': 'pep508-identifier'}, 'version': {'type': 'string', 'description': 'The version of the project as supported by :pep:`440`.', 'format': 'pep440'}, 'description': {'type': 'string', '$$description': ['The `summary description of the project', '<https://packaging.python.org/specifications/core-metadata/#summary>`_']}, 'readme': {'$$description': ['`Full/detailed description of the project in the form of a README', '<https://peps.python.org/pep-0621/#readme>`_', "with meaning similar to the one defined in `core metadata's Description", '<https://packaging.python.org/specifications/core-metadata/#description>`_'], 'oneOf': [{'type': 'string', '$$description': ['Relative path to a text file (UTF-8) containing the full description', 'of the project. If the file path ends in case-insensitive ``.md`` or', '``.rst`` suffixes, then the content-type is respectively', '``text/markdown`` or ``text/x-rst``']}, {'type': 'object', 'allOf': [{'anyOf': [{'properties': {'file': {'type': 'string', '$$description': ['Relative path to a text file containing the full description', 'of the project.']}}, 'required': ['file']}, {'properties': {'text': {'type': 'string', 'description': 'Full text describing the project.'}}, 'required': ['text']}]}, {'properties': {'content-type': {'type': 'string', '$$description': ['Content-type (:rfc:`1341`) of the full description', '(e.g. ``text/markdown``). The ``charset`` parameter is assumed', 'UTF-8 when not present.'], '$comment': 'TODO: add regex pattern or format?'}}, 'required': ['content-type']}]}]}, 'requires-python': {'type': 'string', 'format': 'pep508-versionspec', '$$description': ['`The Python version requirements of the project', '<https://packaging.python.org/specifications/core-metadata/#requires-python>`_.']}, 'license': {'description': '`Project license <https://peps.python.org/pep-0621/#license>`_.', 'oneOf': [{'type': 'string', 'description': 'An SPDX license identifier', 'format': 'SPDX'}, {'type': 'object', 'properties': {'file': {'type': 'string', '$$description': ['Relative path to the file (UTF-8) which contains the license for the', 'project.']}}, 'required': ['file']}, {'type': 'object', 'properties': {'text': {'type': 'string', '$$description': ['The license of the project whose meaning is that of the', '`License field from the core metadata', '<https://packaging.python.org/specifications/core-metadata/#license>`_.']}}, 'required': ['text']}]}, 'license-files': {'description': 'Paths or globs to paths of license files', 'type': 'array', 'items': {'type': 'string'}}, 'authors': {'type': 'array', 'items': {'$ref': '#/definitions/author'}, '$$description': ["The people or organizations considered to be the 'authors' of the project.", 'The exact meaning is open to interpretation (e.g. original or primary authors,', 'current maintainers, or owners of the package).']}, 'maintainers': {'type': 'array', 'items': {'$ref': '#/definitions/author'}, '$$description': ["The people or organizations considered to be the 'maintainers' of the project.", 'Similarly to ``authors``, the exact meaning is open to interpretation.']}, 'keywords': {'type': 'array', 'items': {'type': 'string'}, 'description': 'List of keywords to assist searching for the distribution in a larger catalog.'}, 'classifiers': {'type': 'array', 'items': {'type': 'string', 'format': 'trove-classifier', 'description': '`PyPI classifier <https://pypi.org/classifiers/>`_.'}, '$$description': ['`Trove classifiers <https://pypi.org/classifiers/>`_', 'which apply to the project.']}, 'urls': {'type': 'object', 'description': 'URLs associated with the project in the form ``label => value``.', 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', 'format': 'url'}}}, 'scripts': {'$ref': '#/definitions/entry-point-group', '$$description': ['Instruct the installer to create command-line wrappers for the given', '`entry points <https://packaging.python.org/specifications/entry-points/>`_.']}, 'gui-scripts': {'$ref': '#/definitions/entry-point-group', '$$description': ['Instruct the installer to create GUI wrappers for the given', '`entry points <https://packaging.python.org/specifications/entry-points/>`_.', 'The difference between ``scripts`` and ``gui-scripts`` is only relevant in', 'Windows.']}, 'entry-points': {'$$description': ['Instruct the installer to expose the given modules/functions via', '``entry-point`` discovery mechanism (useful for plugins).', 'More information available in the `Python packaging guide', '<https://packaging.python.org/specifications/entry-points/>`_.'], 'propertyNames': {'format': 'python-entrypoint-group'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'$ref': '#/definitions/entry-point-group'}}}, 'dependencies': {'type': 'array', 'description': 'Project (mandatory) dependencies.', 'items': {'$ref': '#/definitions/dependency'}}, 'optional-dependencies': {'type': 'object', 'description': 'Optional dependency for the project', 'propertyNames': {'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'array', 'items': {'$ref': '#/definitions/dependency'}}}}, 'import-names': {'description': 'Lists import names which a project, when installed, would exclusively provide.', 'type': 'array', 'items': {'type': 'string', 'format': 'import-name'}}, 'import-namespaces': {'description': 'Lists import names that, when installed, would be provided by the project, but not exclusively.', 'type': 'array', 'items': {'type': 'string', 'format': 'import-name'}}, 'dynamic': {'type': 'array', '$$description': ['Specifies which fields are intentionally unspecified and expected to be', 'dynamically provided by build tools'], 'items': {'enum': ['version', 'description', 'readme', 'requires-python', 'license', 'license-files', 'authors', 'maintainers', 'keywords', 'classifiers', 'urls', 'scripts', 'gui-scripts', 'entry-points', 'dependencies', 'optional-dependencies', 'import-names', 'import-namespaces']}}}, 'required': ['name'], 'additionalProperties': False, 'allOf': [{'if': {'not': {'required': ['dynamic'], 'properties': {'dynamic': {'contains': {'const': 'version'}, '$$description': ['version is listed in ``dynamic``']}}}, '$$comment': ['According to :pep:`621`:', ' If the core metadata specification lists a field as "Required", then', ' the metadata MUST specify the field statically or list it in dynamic', 'In turn, `core metadata`_ defines:', ' The required fields are: Metadata-Version, Name, Version.', ' All the other fields are optional.', 'Since ``Metadata-Version`` is defined by the build back-end, ``name`` and', '``version`` are the only mandatory information in ``pyproject.toml``.', '.. _core metadata: https://packaging.python.org/specifications/core-metadata/']}, 'then': {'required': ['version'], '$$description': ['version should be statically defined in the ``version`` field']}}, {'if': {'required': ['license-files']}, 'then': {'properties': {'license': {'type': 'string'}}}}], 'definitions': {'author': {'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, 'entry-point-group': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}, 'dependency': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}}, 'tool': {'type': 'object', 'properties': {'distutils': {'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://setuptools.pypa.io/en/latest/deprecated/distutils/configfile.html', 'title': '``tool.distutils`` table', '$$description': ['**EXPERIMENTAL** (NOT OFFICIALLY SUPPORTED): Use ``tool.distutils``', 'subtables to configure arguments for ``distutils`` commands.', 'Originally, ``distutils`` allowed developers to configure arguments for', '``setup.py`` commands via `distutils configuration files', '<https://setuptools.pypa.io/en/latest/deprecated/distutils/configfile.html>`_.', 'See also `the old Python docs <https://docs.python.org/3.11/install/>_`.'], 'type': 'object', 'properties': {'global': {'type': 'object', 'description': 'Global options applied to all ``distutils`` commands'}}, 'patternProperties': {'.+': {'type': 'object'}}, '$comment': 'TODO: Is there a practical way of making this schema more specific?'}, 'setuptools': {'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html', 'title': '``tool.setuptools`` table', '$$description': ['``setuptools``-specific configurations that can be set by users that require', 'customization.', 'These configurations are completely optional and probably can be skipped when', 'creating simple packages. They are equivalent to some of the `Keywords', '<https://setuptools.pypa.io/en/latest/references/keywords.html>`_', 'used by the ``setup.py`` file, and can be set via the ``tool.setuptools`` table.', 'It considers only ``setuptools`` `parameters', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#setuptools-specific-configuration>`_', 'that are not covered by :pep:`621`; and intentionally excludes ``dependency_links``', 'and ``setup_requires`` (incompatible with modern workflows/standards).'], 'type': 'object', 'additionalProperties': False, 'properties': {'platforms': {'type': 'array', 'items': {'type': 'string'}}, 'provides': {'$$description': ['Package and virtual package names contained within this package', '**(not supported by pip)**'], 'type': 'array', 'items': {'type': 'string', 'format': 'pep508-identifier'}}, 'obsoletes': {'$$description': ['Packages which this package renders obsolete', '**(not supported by pip)**'], 'type': 'array', 'items': {'type': 'string', 'format': 'pep508-identifier'}}, 'zip-safe': {'$$description': ['Whether the project can be safely installed and run from a zip file.', '**OBSOLETE**: only relevant for ``pkg_resources``, ``easy_install`` and', '``setup.py install`` in the context of ``eggs`` (**DEPRECATED**).'], 'type': 'boolean'}, 'script-files': {'$$description': ['Legacy way of defining scripts (entry-points are preferred).', 'Equivalent to the ``script`` keyword in ``setup.py``', '(it was renamed to avoid confusion with entry-point based ``project.scripts``', 'defined in :pep:`621`).', '**DISCOURAGED**: generic script wrappers are tricky and may not work properly.', 'Whenever possible, please use ``project.scripts`` instead.'], 'type': 'array', 'items': {'type': 'string'}, '$comment': 'TODO: is this field deprecated/should be removed?'}, 'eager-resources': {'$$description': ['Resources that should be extracted together, if any of them is needed,', 'or if any C extensions included in the project are imported.', '**OBSOLETE**: only relevant for ``pkg_resources``, ``easy_install`` and', '``setup.py install`` in the context of ``eggs`` (**DEPRECATED**).'], 'type': 'array', 'items': {'type': 'string'}}, 'packages': {'$$description': ['Packages that should be included in the distribution.', 'It can be given either as a list of package identifiers', 'or as a ``dict``-like structure with a single key ``find``', 'which corresponds to a dynamic call to', '``setuptools.config.expand.find_packages`` function.', 'The ``find`` key is associated with a nested ``dict``-like structure that can', 'contain ``where``, ``include``, ``exclude`` and ``namespaces`` keys,', 'mimicking the keyword arguments of the associated function.'], 'oneOf': [{'title': 'Array of Python package identifiers', 'type': 'array', 'items': {'$ref': '#/definitions/package-name'}}, {'$ref': '#/definitions/find-directive'}]}, 'package-dir': {'$$description': [':class:`dict`-like structure mapping from package names to directories where their', 'code can be found.', 'The empty string (as key) means that all packages are contained inside', 'the given directory will be included in the distribution.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'const': ''}, {'$ref': '#/definitions/package-name'}]}, 'patternProperties': {'^.*$': {'type': 'string'}}}, 'package-data': {'$$description': ['Mapping from package names to lists of glob patterns.', 'Usually this option is not needed when using ``include-package-data = true``', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'$ref': '#/definitions/package-name'}, {'const': '*'}]}, 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, 'include-package-data': {'$$description': ['Automatically include any data files inside the package directories', 'that are specified by ``MANIFEST.in``', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'boolean'}, 'exclude-package-data': {'$$description': ['Mapping from package names to lists of glob patterns that should be excluded', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'$ref': '#/definitions/package-name'}, {'const': '*'}]}, 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, 'namespace-packages': {'type': 'array', 'items': {'type': 'string', 'format': 'python-module-name-relaxed'}, '$comment': 'https://setuptools.pypa.io/en/latest/userguide/package_discovery.html', 'description': '**DEPRECATED**: use implicit namespaces instead (:pep:`420`).'}, 'py-modules': {'description': 'Modules that setuptools will manipulate', 'type': 'array', 'items': {'type': 'string', 'format': 'python-module-name-relaxed'}, '$comment': 'TODO: clarify the relationship with ``packages``'}, 'ext-modules': {'description': 'Extension modules to be compiled by setuptools', 'type': 'array', 'items': {'$ref': '#/definitions/ext-module'}}, 'data-files': {'$$description': ['``dict``-like structure where each key represents a directory and', 'the value is a list of glob patterns that should be installed in them.', '**DISCOURAGED**: please notice this might not work as expected with wheels.', 'Whenever possible, consider using data files inside the package directories', '(or create a new namespace package that only contains data files).', 'See `data files support', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, 'cmdclass': {'$$description': ['Mapping of distutils-style command names to ``setuptools.Command`` subclasses', 'which in turn should be represented by strings with a qualified class name', '(i.e., "dotted" form with module), e.g.::\n\n', ' cmdclass = {mycmd = "pkg.subpkg.module.CommandClass"}\n\n', 'The command class should be a directly defined at the top-level of the', 'containing module (no class nesting).'], 'type': 'object', 'patternProperties': {'^.*$': {'type': 'string', 'format': 'python-qualified-identifier'}}}, 'license-files': {'type': 'array', 'items': {'type': 'string'}, '$$description': ['**PROVISIONAL**: list of glob patterns for all license files being distributed.', '(likely to become standard with :pep:`639`).', "By default: ``['LICEN[CS]E*', 'COPYING*', 'NOTICE*', 'AUTHORS*']``"], '$comment': 'TODO: revise if PEP 639 is accepted. Probably ``project.license-files``?'}, 'dynamic': {'type': 'object', 'description': 'Instructions for loading :pep:`621`-related metadata dynamically', 'additionalProperties': False, 'properties': {'version': {'$$description': ['A version dynamically loaded via either the ``attr:`` or ``file:``', 'directives. Please make sure the given file or attribute respects :pep:`440`.', 'Also ensure to set ``project.dynamic`` accordingly.'], 'oneOf': [{'$ref': '#/definitions/attr-directive'}, {'$ref': '#/definitions/file-directive'}]}, 'classifiers': {'$ref': '#/definitions/file-directive'}, 'description': {'$ref': '#/definitions/file-directive'}, 'entry-points': {'$ref': '#/definitions/file-directive'}, 'dependencies': {'$ref': '#/definitions/file-directive-for-dependencies'}, 'optional-dependencies': {'type': 'object', 'propertyNames': {'type': 'string', 'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'.+': {'$ref': '#/definitions/file-directive-for-dependencies'}}}, 'readme': {'type': 'object', 'anyOf': [{'$ref': '#/definitions/file-directive'}, {'type': 'object', 'properties': {'content-type': {'type': 'string'}, 'file': {'$ref': '#/definitions/file-directive/properties/file'}}, 'additionalProperties': False}], 'required': ['file']}}}}, 'definitions': {'package-name': {'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, 'ext-module': {'$id': '#/definitions/ext-module', 'title': 'Extension module', 'description': 'Parameters to construct a :class:`setuptools.Extension` object', 'type': 'object', 'required': ['name', 'sources'], 'additionalProperties': False, 'properties': {'name': {'type': 'string', 'format': 'python-module-name-relaxed'}, 'sources': {'type': 'array', 'items': {'type': 'string'}}, 'include-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'define-macros': {'type': 'array', 'items': {'type': 'array', 'items': [{'description': 'macro name', 'type': 'string'}, {'description': 'macro value', 'oneOf': [{'type': 'string'}, {'type': 'null'}]}], 'additionalItems': False}}, 'undef-macros': {'type': 'array', 'items': {'type': 'string'}}, 'library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'libraries': {'type': 'array', 'items': {'type': 'string'}}, 'runtime-library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'extra-objects': {'type': 'array', 'items': {'type': 'string'}}, 'extra-compile-args': {'type': 'array', 'items': {'type': 'string'}}, 'extra-link-args': {'type': 'array', 'items': {'type': 'string'}}, 'export-symbols': {'type': 'array', 'items': {'type': 'string'}}, 'swig-opts': {'type': 'array', 'items': {'type': 'string'}}, 'depends': {'type': 'array', 'items': {'type': 'string'}}, 'language': {'type': 'string'}, 'optional': {'type': 'boolean'}, 'py-limited-api': {'type': 'boolean'}}}, 'file-directive': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'file-directive-for-dependencies': {'title': "'file:' directive for dependencies", 'allOf': [{'$$description': ['**BETA**: subset of the ``requirements.txt`` format', 'without ``pip`` flags and options', '(one :pep:`508`-compliant string per line,', 'lines that are blank or start with ``#`` are excluded).', 'See `dynamic metadata', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata>`_.']}, {'$ref': '#/definitions/file-directive'}]}, 'attr-directive': {'title': "'attr:' directive", '$id': '#/definitions/attr-directive', '$$description': ['Value is read from a module attribute. Supports callables and iterables;', 'unsupported types are cast via ``str()``'], 'type': 'object', 'additionalProperties': False, 'properties': {'attr': {'type': 'string', 'format': 'python-qualified-identifier'}}, 'required': ['attr']}, 'find-directive': {'$id': '#/definitions/find-directive', 'title': "'find:' directive", 'type': 'object', 'additionalProperties': False, 'properties': {'find': {'type': 'object', '$$description': ['Dynamic `package discovery', '<https://setuptools.pypa.io/en/latest/userguide/package_discovery.html>`_.'], 'additionalProperties': False, 'properties': {'where': {'description': 'Directories to be searched for packages (Unix-style relative path)', 'type': 'array', 'items': {'type': 'string'}}, 'exclude': {'type': 'array', '$$description': ['Exclude packages that match the values listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'include': {'type': 'array', '$$description': ['Restrict the found packages to just the ones listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'namespaces': {'type': 'boolean', '$$description': ['When ``True``, directories without a ``__init__.py`` file will also', 'be scanned for :pep:`420`-style implicit namespaces']}}}}}}}}}, 'dependency-groups': {'type': 'object', 'description': 'Dependency groups following PEP 735', 'additionalProperties': False, 'patternProperties': {'^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$': {'type': 'array', 'items': {'oneOf': [{'type': 'string', 'description': 'Python package specifiers following PEP 508', 'format': 'pep508'}, {'type': 'object', 'additionalProperties': False, 'properties': {'include-group': {'description': 'Another dependency group to include in this one', 'type': 'string', 'pattern': '^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$'}}}]}}}}}, 'project': {'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://packaging.python.org/en/latest/specifications/pyproject-toml/', 'title': 'Package metadata stored in the ``project`` table', '$$description': ['Data structure for the **project** table inside ``pyproject.toml``', '(as initially defined in :pep:`621`)'], 'type': 'object', 'properties': {'name': {'type': 'string', 'description': 'The name (primary identifier) of the project. MUST be statically defined.', 'format': 'pep508-identifier'}, 'version': {'type': 'string', 'description': 'The version of the project as supported by :pep:`440`.', 'format': 'pep440'}, 'description': {'type': 'string', '$$description': ['The `summary description of the project', '<https://packaging.python.org/specifications/core-metadata/#summary>`_']}, 'readme': {'$$description': ['`Full/detailed description of the project in the form of a README', '<https://peps.python.org/pep-0621/#readme>`_', "with meaning similar to the one defined in `core metadata's Description", '<https://packaging.python.org/specifications/core-metadata/#description>`_'], 'oneOf': [{'type': 'string', '$$description': ['Relative path to a text file (UTF-8) containing the full description', 'of the project. If the file path ends in case-insensitive ``.md`` or', '``.rst`` suffixes, then the content-type is respectively', '``text/markdown`` or ``text/x-rst``']}, {'type': 'object', 'allOf': [{'anyOf': [{'properties': {'file': {'type': 'string', '$$description': ['Relative path to a text file containing the full description', 'of the project.']}}, 'required': ['file']}, {'properties': {'text': {'type': 'string', 'description': 'Full text describing the project.'}}, 'required': ['text']}]}, {'properties': {'content-type': {'type': 'string', '$$description': ['Content-type (:rfc:`1341`) of the full description', '(e.g. ``text/markdown``). The ``charset`` parameter is assumed', 'UTF-8 when not present.'], '$comment': 'TODO: add regex pattern or format?'}}, 'required': ['content-type']}]}]}, 'requires-python': {'type': 'string', 'format': 'pep508-versionspec', '$$description': ['`The Python version requirements of the project', '<https://packaging.python.org/specifications/core-metadata/#requires-python>`_.']}, 'license': {'description': '`Project license <https://peps.python.org/pep-0621/#license>`_.', 'oneOf': [{'type': 'string', 'description': 'An SPDX license identifier', 'format': 'SPDX'}, {'type': 'object', 'properties': {'file': {'type': 'string', '$$description': ['Relative path to the file (UTF-8) which contains the license for the', 'project.']}}, 'required': ['file']}, {'type': 'object', 'properties': {'text': {'type': 'string', '$$description': ['The license of the project whose meaning is that of the', '`License field from the core metadata', '<https://packaging.python.org/specifications/core-metadata/#license>`_.']}}, 'required': ['text']}]}, 'license-files': {'description': 'Paths or globs to paths of license files', 'type': 'array', 'items': {'type': 'string'}}, 'authors': {'type': 'array', 'items': {'$ref': '#/definitions/author'}, '$$description': ["The people or organizations considered to be the 'authors' of the project.", 'The exact meaning is open to interpretation (e.g. original or primary authors,', 'current maintainers, or owners of the package).']}, 'maintainers': {'type': 'array', 'items': {'$ref': '#/definitions/author'}, '$$description': ["The people or organizations considered to be the 'maintainers' of the project.", 'Similarly to ``authors``, the exact meaning is open to interpretation.']}, 'keywords': {'type': 'array', 'items': {'type': 'string'}, 'description': 'List of keywords to assist searching for the distribution in a larger catalog.'}, 'classifiers': {'type': 'array', 'items': {'type': 'string', 'format': 'trove-classifier', 'description': '`PyPI classifier <https://pypi.org/classifiers/>`_.'}, '$$description': ['`Trove classifiers <https://pypi.org/classifiers/>`_', 'which apply to the project.']}, 'urls': {'type': 'object', 'description': 'URLs associated with the project in the form ``label => value``.', 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', 'format': 'url'}}}, 'scripts': {'$ref': '#/definitions/entry-point-group', '$$description': ['Instruct the installer to create command-line wrappers for the given', '`entry points <https://packaging.python.org/specifications/entry-points/>`_.']}, 'gui-scripts': {'$ref': '#/definitions/entry-point-group', '$$description': ['Instruct the installer to create GUI wrappers for the given', '`entry points <https://packaging.python.org/specifications/entry-points/>`_.', 'The difference between ``scripts`` and ``gui-scripts`` is only relevant in', 'Windows.']}, 'entry-points': {'$$description': ['Instruct the installer to expose the given modules/functions via', '``entry-point`` discovery mechanism (useful for plugins).', 'More information available in the `Python packaging guide', '<https://packaging.python.org/specifications/entry-points/>`_.'], 'propertyNames': {'format': 'python-entrypoint-group'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'$ref': '#/definitions/entry-point-group'}}}, 'dependencies': {'type': 'array', 'description': 'Project (mandatory) dependencies.', 'items': {'$ref': '#/definitions/dependency'}}, 'optional-dependencies': {'type': 'object', 'description': 'Optional dependency for the project', 'propertyNames': {'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'array', 'items': {'$ref': '#/definitions/dependency'}}}}, 'import-names': {'description': 'Lists import names which a project, when installed, would exclusively provide.', 'type': 'array', 'items': {'type': 'string', 'format': 'import-name'}}, 'import-namespaces': {'description': 'Lists import names that, when installed, would be provided by the project, but not exclusively.', 'type': 'array', 'items': {'type': 'string', 'format': 'import-name'}}, 'dynamic': {'type': 'array', '$$description': ['Specifies which fields are intentionally unspecified and expected to be', 'dynamically provided by build tools'], 'items': {'enum': ['version', 'description', 'readme', 'requires-python', 'license', 'license-files', 'authors', 'maintainers', 'keywords', 'classifiers', 'urls', 'scripts', 'gui-scripts', 'entry-points', 'dependencies', 'optional-dependencies', 'import-names', 'import-namespaces']}}}, 'required': ['name'], 'additionalProperties': False, 'allOf': [{'if': {'not': {'required': ['dynamic'], 'properties': {'dynamic': {'contains': {'const': 'version'}, '$$description': ['version is listed in ``dynamic``']}}}, '$$comment': ['According to :pep:`621`:', ' If the core metadata specification lists a field as "Required", then', ' the metadata MUST specify the field statically or list it in dynamic', 'In turn, `core metadata`_ defines:', ' The required fields are: Metadata-Version, Name, Version.', ' All the other fields are optional.', 'Since ``Metadata-Version`` is defined by the build back-end, ``name`` and', '``version`` are the only mandatory information in ``pyproject.toml``.', '.. _core metadata: https://packaging.python.org/specifications/core-metadata/']}, 'then': {'required': ['version'], '$$description': ['version should be statically defined in the ``version`` field']}}, {'if': {'required': ['license-files']}, 'then': {'properties': {'license': {'type': 'string'}}}}], 'definitions': {'author': {'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, 'entry-point-group': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}, 'dependency': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}}}, rule='type') + data_is_dict = isinstance(data, dict) + if data_is_dict: + data_keys = set(data.keys()) + if "build-system" in data_keys: + data_keys.remove("build-system") + data__buildsystem = data["build-system"] + if not isinstance(data__buildsystem, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".build-system must be object", value=data__buildsystem, name="" + (name_prefix or "data") + ".build-system", definition={'type': 'object', 'description': 'Table used to store build-related data', 'additionalProperties': False, 'properties': {'requires': {'type': 'array', '$$description': ['List of dependencies in the :pep:`508` format required to execute the build', 'system. Please notice that the resulting dependency graph', '**MUST NOT contain cycles**'], 'items': {'type': 'string'}}, 'build-backend': {'type': 'string', 'description': 'Python object that will be used to perform the build according to :pep:`517`', 'format': 'pep517-backend-reference'}, 'backend-path': {'type': 'array', '$$description': ['List of directories to be prepended to ``sys.path`` when loading the', 'back-end, and running its hooks'], 'items': {'type': 'string', '$comment': 'Should be a path (TODO: enforce it with format?)'}}}, 'required': ['requires']}, rule='type') + data__buildsystem_is_dict = isinstance(data__buildsystem, dict) + if data__buildsystem_is_dict: + data__buildsystem__missing_keys = set(['requires']) - data__buildsystem.keys() + if data__buildsystem__missing_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".build-system must contain " + (str(sorted(data__buildsystem__missing_keys)) + " properties"), value=data__buildsystem, name="" + (name_prefix or "data") + ".build-system", definition={'type': 'object', 'description': 'Table used to store build-related data', 'additionalProperties': False, 'properties': {'requires': {'type': 'array', '$$description': ['List of dependencies in the :pep:`508` format required to execute the build', 'system. Please notice that the resulting dependency graph', '**MUST NOT contain cycles**'], 'items': {'type': 'string'}}, 'build-backend': {'type': 'string', 'description': 'Python object that will be used to perform the build according to :pep:`517`', 'format': 'pep517-backend-reference'}, 'backend-path': {'type': 'array', '$$description': ['List of directories to be prepended to ``sys.path`` when loading the', 'back-end, and running its hooks'], 'items': {'type': 'string', '$comment': 'Should be a path (TODO: enforce it with format?)'}}}, 'required': ['requires']}, rule='required') + data__buildsystem_keys = set(data__buildsystem.keys()) + if "requires" in data__buildsystem_keys: + data__buildsystem_keys.remove("requires") + data__buildsystem__requires = data__buildsystem["requires"] + if not isinstance(data__buildsystem__requires, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".build-system.requires must be array", value=data__buildsystem__requires, name="" + (name_prefix or "data") + ".build-system.requires", definition={'type': 'array', '$$description': ['List of dependencies in the :pep:`508` format required to execute the build', 'system. Please notice that the resulting dependency graph', '**MUST NOT contain cycles**'], 'items': {'type': 'string'}}, rule='type') + data__buildsystem__requires_is_list = isinstance(data__buildsystem__requires, (list, tuple)) + if data__buildsystem__requires_is_list: + data__buildsystem__requires_len = len(data__buildsystem__requires) + for data__buildsystem__requires_x, data__buildsystem__requires_item in enumerate(data__buildsystem__requires): + if not isinstance(data__buildsystem__requires_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".build-system.requires[{data__buildsystem__requires_x}]".format(**locals()) + " must be string", value=data__buildsystem__requires_item, name="" + (name_prefix or "data") + ".build-system.requires[{data__buildsystem__requires_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "build-backend" in data__buildsystem_keys: + data__buildsystem_keys.remove("build-backend") + data__buildsystem__buildbackend = data__buildsystem["build-backend"] + if not isinstance(data__buildsystem__buildbackend, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".build-system.build-backend must be string", value=data__buildsystem__buildbackend, name="" + (name_prefix or "data") + ".build-system.build-backend", definition={'type': 'string', 'description': 'Python object that will be used to perform the build according to :pep:`517`', 'format': 'pep517-backend-reference'}, rule='type') + if isinstance(data__buildsystem__buildbackend, str): + if not custom_formats["pep517-backend-reference"](data__buildsystem__buildbackend): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".build-system.build-backend must be pep517-backend-reference", value=data__buildsystem__buildbackend, name="" + (name_prefix or "data") + ".build-system.build-backend", definition={'type': 'string', 'description': 'Python object that will be used to perform the build according to :pep:`517`', 'format': 'pep517-backend-reference'}, rule='format') + if "backend-path" in data__buildsystem_keys: + data__buildsystem_keys.remove("backend-path") + data__buildsystem__backendpath = data__buildsystem["backend-path"] + if not isinstance(data__buildsystem__backendpath, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".build-system.backend-path must be array", value=data__buildsystem__backendpath, name="" + (name_prefix or "data") + ".build-system.backend-path", definition={'type': 'array', '$$description': ['List of directories to be prepended to ``sys.path`` when loading the', 'back-end, and running its hooks'], 'items': {'type': 'string', '$comment': 'Should be a path (TODO: enforce it with format?)'}}, rule='type') + data__buildsystem__backendpath_is_list = isinstance(data__buildsystem__backendpath, (list, tuple)) + if data__buildsystem__backendpath_is_list: + data__buildsystem__backendpath_len = len(data__buildsystem__backendpath) + for data__buildsystem__backendpath_x, data__buildsystem__backendpath_item in enumerate(data__buildsystem__backendpath): + if not isinstance(data__buildsystem__backendpath_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".build-system.backend-path[{data__buildsystem__backendpath_x}]".format(**locals()) + " must be string", value=data__buildsystem__backendpath_item, name="" + (name_prefix or "data") + ".build-system.backend-path[{data__buildsystem__backendpath_x}]".format(**locals()) + "", definition={'type': 'string', '$comment': 'Should be a path (TODO: enforce it with format?)'}, rule='type') + if data__buildsystem_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".build-system must not contain "+str(data__buildsystem_keys)+" properties", value=data__buildsystem, name="" + (name_prefix or "data") + ".build-system", definition={'type': 'object', 'description': 'Table used to store build-related data', 'additionalProperties': False, 'properties': {'requires': {'type': 'array', '$$description': ['List of dependencies in the :pep:`508` format required to execute the build', 'system. Please notice that the resulting dependency graph', '**MUST NOT contain cycles**'], 'items': {'type': 'string'}}, 'build-backend': {'type': 'string', 'description': 'Python object that will be used to perform the build according to :pep:`517`', 'format': 'pep517-backend-reference'}, 'backend-path': {'type': 'array', '$$description': ['List of directories to be prepended to ``sys.path`` when loading the', 'back-end, and running its hooks'], 'items': {'type': 'string', '$comment': 'Should be a path (TODO: enforce it with format?)'}}}, 'required': ['requires']}, rule='additionalProperties') + if "project" in data_keys: + data_keys.remove("project") + data__project = data["project"] + validate_https___packaging_python_org_en_latest_specifications_pyproject_toml(data__project, custom_formats, (name_prefix or "data") + ".project") + if "tool" in data_keys: + data_keys.remove("tool") + data__tool = data["tool"] + if not isinstance(data__tool, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".tool must be object", value=data__tool, name="" + (name_prefix or "data") + ".tool", definition={'type': 'object', 'properties': {'distutils': {'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://setuptools.pypa.io/en/latest/deprecated/distutils/configfile.html', 'title': '``tool.distutils`` table', '$$description': ['**EXPERIMENTAL** (NOT OFFICIALLY SUPPORTED): Use ``tool.distutils``', 'subtables to configure arguments for ``distutils`` commands.', 'Originally, ``distutils`` allowed developers to configure arguments for', '``setup.py`` commands via `distutils configuration files', '<https://setuptools.pypa.io/en/latest/deprecated/distutils/configfile.html>`_.', 'See also `the old Python docs <https://docs.python.org/3.11/install/>_`.'], 'type': 'object', 'properties': {'global': {'type': 'object', 'description': 'Global options applied to all ``distutils`` commands'}}, 'patternProperties': {'.+': {'type': 'object'}}, '$comment': 'TODO: Is there a practical way of making this schema more specific?'}, 'setuptools': {'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html', 'title': '``tool.setuptools`` table', '$$description': ['``setuptools``-specific configurations that can be set by users that require', 'customization.', 'These configurations are completely optional and probably can be skipped when', 'creating simple packages. They are equivalent to some of the `Keywords', '<https://setuptools.pypa.io/en/latest/references/keywords.html>`_', 'used by the ``setup.py`` file, and can be set via the ``tool.setuptools`` table.', 'It considers only ``setuptools`` `parameters', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#setuptools-specific-configuration>`_', 'that are not covered by :pep:`621`; and intentionally excludes ``dependency_links``', 'and ``setup_requires`` (incompatible with modern workflows/standards).'], 'type': 'object', 'additionalProperties': False, 'properties': {'platforms': {'type': 'array', 'items': {'type': 'string'}}, 'provides': {'$$description': ['Package and virtual package names contained within this package', '**(not supported by pip)**'], 'type': 'array', 'items': {'type': 'string', 'format': 'pep508-identifier'}}, 'obsoletes': {'$$description': ['Packages which this package renders obsolete', '**(not supported by pip)**'], 'type': 'array', 'items': {'type': 'string', 'format': 'pep508-identifier'}}, 'zip-safe': {'$$description': ['Whether the project can be safely installed and run from a zip file.', '**OBSOLETE**: only relevant for ``pkg_resources``, ``easy_install`` and', '``setup.py install`` in the context of ``eggs`` (**DEPRECATED**).'], 'type': 'boolean'}, 'script-files': {'$$description': ['Legacy way of defining scripts (entry-points are preferred).', 'Equivalent to the ``script`` keyword in ``setup.py``', '(it was renamed to avoid confusion with entry-point based ``project.scripts``', 'defined in :pep:`621`).', '**DISCOURAGED**: generic script wrappers are tricky and may not work properly.', 'Whenever possible, please use ``project.scripts`` instead.'], 'type': 'array', 'items': {'type': 'string'}, '$comment': 'TODO: is this field deprecated/should be removed?'}, 'eager-resources': {'$$description': ['Resources that should be extracted together, if any of them is needed,', 'or if any C extensions included in the project are imported.', '**OBSOLETE**: only relevant for ``pkg_resources``, ``easy_install`` and', '``setup.py install`` in the context of ``eggs`` (**DEPRECATED**).'], 'type': 'array', 'items': {'type': 'string'}}, 'packages': {'$$description': ['Packages that should be included in the distribution.', 'It can be given either as a list of package identifiers', 'or as a ``dict``-like structure with a single key ``find``', 'which corresponds to a dynamic call to', '``setuptools.config.expand.find_packages`` function.', 'The ``find`` key is associated with a nested ``dict``-like structure that can', 'contain ``where``, ``include``, ``exclude`` and ``namespaces`` keys,', 'mimicking the keyword arguments of the associated function.'], 'oneOf': [{'title': 'Array of Python package identifiers', 'type': 'array', 'items': {'$ref': '#/definitions/package-name'}}, {'$ref': '#/definitions/find-directive'}]}, 'package-dir': {'$$description': [':class:`dict`-like structure mapping from package names to directories where their', 'code can be found.', 'The empty string (as key) means that all packages are contained inside', 'the given directory will be included in the distribution.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'const': ''}, {'$ref': '#/definitions/package-name'}]}, 'patternProperties': {'^.*$': {'type': 'string'}}}, 'package-data': {'$$description': ['Mapping from package names to lists of glob patterns.', 'Usually this option is not needed when using ``include-package-data = true``', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'$ref': '#/definitions/package-name'}, {'const': '*'}]}, 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, 'include-package-data': {'$$description': ['Automatically include any data files inside the package directories', 'that are specified by ``MANIFEST.in``', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'boolean'}, 'exclude-package-data': {'$$description': ['Mapping from package names to lists of glob patterns that should be excluded', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'$ref': '#/definitions/package-name'}, {'const': '*'}]}, 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, 'namespace-packages': {'type': 'array', 'items': {'type': 'string', 'format': 'python-module-name-relaxed'}, '$comment': 'https://setuptools.pypa.io/en/latest/userguide/package_discovery.html', 'description': '**DEPRECATED**: use implicit namespaces instead (:pep:`420`).'}, 'py-modules': {'description': 'Modules that setuptools will manipulate', 'type': 'array', 'items': {'type': 'string', 'format': 'python-module-name-relaxed'}, '$comment': 'TODO: clarify the relationship with ``packages``'}, 'ext-modules': {'description': 'Extension modules to be compiled by setuptools', 'type': 'array', 'items': {'$ref': '#/definitions/ext-module'}}, 'data-files': {'$$description': ['``dict``-like structure where each key represents a directory and', 'the value is a list of glob patterns that should be installed in them.', '**DISCOURAGED**: please notice this might not work as expected with wheels.', 'Whenever possible, consider using data files inside the package directories', '(or create a new namespace package that only contains data files).', 'See `data files support', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, 'cmdclass': {'$$description': ['Mapping of distutils-style command names to ``setuptools.Command`` subclasses', 'which in turn should be represented by strings with a qualified class name', '(i.e., "dotted" form with module), e.g.::\n\n', ' cmdclass = {mycmd = "pkg.subpkg.module.CommandClass"}\n\n', 'The command class should be a directly defined at the top-level of the', 'containing module (no class nesting).'], 'type': 'object', 'patternProperties': {'^.*$': {'type': 'string', 'format': 'python-qualified-identifier'}}}, 'license-files': {'type': 'array', 'items': {'type': 'string'}, '$$description': ['**PROVISIONAL**: list of glob patterns for all license files being distributed.', '(likely to become standard with :pep:`639`).', "By default: ``['LICEN[CS]E*', 'COPYING*', 'NOTICE*', 'AUTHORS*']``"], '$comment': 'TODO: revise if PEP 639 is accepted. Probably ``project.license-files``?'}, 'dynamic': {'type': 'object', 'description': 'Instructions for loading :pep:`621`-related metadata dynamically', 'additionalProperties': False, 'properties': {'version': {'$$description': ['A version dynamically loaded via either the ``attr:`` or ``file:``', 'directives. Please make sure the given file or attribute respects :pep:`440`.', 'Also ensure to set ``project.dynamic`` accordingly.'], 'oneOf': [{'$ref': '#/definitions/attr-directive'}, {'$ref': '#/definitions/file-directive'}]}, 'classifiers': {'$ref': '#/definitions/file-directive'}, 'description': {'$ref': '#/definitions/file-directive'}, 'entry-points': {'$ref': '#/definitions/file-directive'}, 'dependencies': {'$ref': '#/definitions/file-directive-for-dependencies'}, 'optional-dependencies': {'type': 'object', 'propertyNames': {'type': 'string', 'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'.+': {'$ref': '#/definitions/file-directive-for-dependencies'}}}, 'readme': {'type': 'object', 'anyOf': [{'$ref': '#/definitions/file-directive'}, {'type': 'object', 'properties': {'content-type': {'type': 'string'}, 'file': {'$ref': '#/definitions/file-directive/properties/file'}}, 'additionalProperties': False}], 'required': ['file']}}}}, 'definitions': {'package-name': {'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, 'ext-module': {'$id': '#/definitions/ext-module', 'title': 'Extension module', 'description': 'Parameters to construct a :class:`setuptools.Extension` object', 'type': 'object', 'required': ['name', 'sources'], 'additionalProperties': False, 'properties': {'name': {'type': 'string', 'format': 'python-module-name-relaxed'}, 'sources': {'type': 'array', 'items': {'type': 'string'}}, 'include-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'define-macros': {'type': 'array', 'items': {'type': 'array', 'items': [{'description': 'macro name', 'type': 'string'}, {'description': 'macro value', 'oneOf': [{'type': 'string'}, {'type': 'null'}]}], 'additionalItems': False}}, 'undef-macros': {'type': 'array', 'items': {'type': 'string'}}, 'library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'libraries': {'type': 'array', 'items': {'type': 'string'}}, 'runtime-library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'extra-objects': {'type': 'array', 'items': {'type': 'string'}}, 'extra-compile-args': {'type': 'array', 'items': {'type': 'string'}}, 'extra-link-args': {'type': 'array', 'items': {'type': 'string'}}, 'export-symbols': {'type': 'array', 'items': {'type': 'string'}}, 'swig-opts': {'type': 'array', 'items': {'type': 'string'}}, 'depends': {'type': 'array', 'items': {'type': 'string'}}, 'language': {'type': 'string'}, 'optional': {'type': 'boolean'}, 'py-limited-api': {'type': 'boolean'}}}, 'file-directive': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'file-directive-for-dependencies': {'title': "'file:' directive for dependencies", 'allOf': [{'$$description': ['**BETA**: subset of the ``requirements.txt`` format', 'without ``pip`` flags and options', '(one :pep:`508`-compliant string per line,', 'lines that are blank or start with ``#`` are excluded).', 'See `dynamic metadata', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata>`_.']}, {'$ref': '#/definitions/file-directive'}]}, 'attr-directive': {'title': "'attr:' directive", '$id': '#/definitions/attr-directive', '$$description': ['Value is read from a module attribute. Supports callables and iterables;', 'unsupported types are cast via ``str()``'], 'type': 'object', 'additionalProperties': False, 'properties': {'attr': {'type': 'string', 'format': 'python-qualified-identifier'}}, 'required': ['attr']}, 'find-directive': {'$id': '#/definitions/find-directive', 'title': "'find:' directive", 'type': 'object', 'additionalProperties': False, 'properties': {'find': {'type': 'object', '$$description': ['Dynamic `package discovery', '<https://setuptools.pypa.io/en/latest/userguide/package_discovery.html>`_.'], 'additionalProperties': False, 'properties': {'where': {'description': 'Directories to be searched for packages (Unix-style relative path)', 'type': 'array', 'items': {'type': 'string'}}, 'exclude': {'type': 'array', '$$description': ['Exclude packages that match the values listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'include': {'type': 'array', '$$description': ['Restrict the found packages to just the ones listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'namespaces': {'type': 'boolean', '$$description': ['When ``True``, directories without a ``__init__.py`` file will also', 'be scanned for :pep:`420`-style implicit namespaces']}}}}}}}}}, rule='type') + data__tool_is_dict = isinstance(data__tool, dict) + if data__tool_is_dict: + data__tool_keys = set(data__tool.keys()) + if "distutils" in data__tool_keys: + data__tool_keys.remove("distutils") + data__tool__distutils = data__tool["distutils"] + validate_https___setuptools_pypa_io_en_latest_deprecated_distutils_configfile_html(data__tool__distutils, custom_formats, (name_prefix or "data") + ".tool.distutils") + if "setuptools" in data__tool_keys: + data__tool_keys.remove("setuptools") + data__tool__setuptools = data__tool["setuptools"] + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html(data__tool__setuptools, custom_formats, (name_prefix or "data") + ".tool.setuptools") + if "dependency-groups" in data_keys: + data_keys.remove("dependency-groups") + data__dependencygroups = data["dependency-groups"] + if not isinstance(data__dependencygroups, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dependency-groups must be object", value=data__dependencygroups, name="" + (name_prefix or "data") + ".dependency-groups", definition={'type': 'object', 'description': 'Dependency groups following PEP 735', 'additionalProperties': False, 'patternProperties': {'^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$': {'type': 'array', 'items': {'oneOf': [{'type': 'string', 'description': 'Python package specifiers following PEP 508', 'format': 'pep508'}, {'type': 'object', 'additionalProperties': False, 'properties': {'include-group': {'description': 'Another dependency group to include in this one', 'type': 'string', 'pattern': '^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$'}}}]}}}}, rule='type') + data__dependencygroups_is_dict = isinstance(data__dependencygroups, dict) + if data__dependencygroups_is_dict: + data__dependencygroups_keys = set(data__dependencygroups.keys()) + for data__dependencygroups_key, data__dependencygroups_val in data__dependencygroups.items(): + if REGEX_PATTERNS['^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$'].search(data__dependencygroups_key): + if data__dependencygroups_key in data__dependencygroups_keys: + data__dependencygroups_keys.remove(data__dependencygroups_key) + if not isinstance(data__dependencygroups_val, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dependency-groups.{data__dependencygroups_key}".format(**locals()) + " must be array", value=data__dependencygroups_val, name="" + (name_prefix or "data") + ".dependency-groups.{data__dependencygroups_key}".format(**locals()) + "", definition={'type': 'array', 'items': {'oneOf': [{'type': 'string', 'description': 'Python package specifiers following PEP 508', 'format': 'pep508'}, {'type': 'object', 'additionalProperties': False, 'properties': {'include-group': {'description': 'Another dependency group to include in this one', 'type': 'string', 'pattern': '^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$'}}}]}}, rule='type') + data__dependencygroups_val_is_list = isinstance(data__dependencygroups_val, (list, tuple)) + if data__dependencygroups_val_is_list: + data__dependencygroups_val_len = len(data__dependencygroups_val) + for data__dependencygroups_val_x, data__dependencygroups_val_item in enumerate(data__dependencygroups_val): + data__dependencygroups_val_item_one_of_count1 = 0 + if data__dependencygroups_val_item_one_of_count1 < 2: + try: + if not isinstance(data__dependencygroups_val_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dependency-groups.{data__dependencygroups_key}[{data__dependencygroups_val_x}]".format(**locals()) + " must be string", value=data__dependencygroups_val_item, name="" + (name_prefix or "data") + ".dependency-groups.{data__dependencygroups_key}[{data__dependencygroups_val_x}]".format(**locals()) + "", definition={'type': 'string', 'description': 'Python package specifiers following PEP 508', 'format': 'pep508'}, rule='type') + if isinstance(data__dependencygroups_val_item, str): + if not custom_formats["pep508"](data__dependencygroups_val_item): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dependency-groups.{data__dependencygroups_key}[{data__dependencygroups_val_x}]".format(**locals()) + " must be pep508", value=data__dependencygroups_val_item, name="" + (name_prefix or "data") + ".dependency-groups.{data__dependencygroups_key}[{data__dependencygroups_val_x}]".format(**locals()) + "", definition={'type': 'string', 'description': 'Python package specifiers following PEP 508', 'format': 'pep508'}, rule='format') + data__dependencygroups_val_item_one_of_count1 += 1 + except JsonSchemaValueException: pass + if data__dependencygroups_val_item_one_of_count1 < 2: + try: + if not isinstance(data__dependencygroups_val_item, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dependency-groups.{data__dependencygroups_key}[{data__dependencygroups_val_x}]".format(**locals()) + " must be object", value=data__dependencygroups_val_item, name="" + (name_prefix or "data") + ".dependency-groups.{data__dependencygroups_key}[{data__dependencygroups_val_x}]".format(**locals()) + "", definition={'type': 'object', 'additionalProperties': False, 'properties': {'include-group': {'description': 'Another dependency group to include in this one', 'type': 'string', 'pattern': '^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$'}}}, rule='type') + data__dependencygroups_val_item_is_dict = isinstance(data__dependencygroups_val_item, dict) + if data__dependencygroups_val_item_is_dict: + data__dependencygroups_val_item_keys = set(data__dependencygroups_val_item.keys()) + if "include-group" in data__dependencygroups_val_item_keys: + data__dependencygroups_val_item_keys.remove("include-group") + data__dependencygroups_val_item__includegroup = data__dependencygroups_val_item["include-group"] + if not isinstance(data__dependencygroups_val_item__includegroup, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dependency-groups.{data__dependencygroups_key}[{data__dependencygroups_val_x}].include-group".format(**locals()) + " must be string", value=data__dependencygroups_val_item__includegroup, name="" + (name_prefix or "data") + ".dependency-groups.{data__dependencygroups_key}[{data__dependencygroups_val_x}].include-group".format(**locals()) + "", definition={'description': 'Another dependency group to include in this one', 'type': 'string', 'pattern': '^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$'}, rule='type') + if isinstance(data__dependencygroups_val_item__includegroup, str): + if not REGEX_PATTERNS['^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$'].search(data__dependencygroups_val_item__includegroup): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dependency-groups.{data__dependencygroups_key}[{data__dependencygroups_val_x}].include-group".format(**locals()) + " must match pattern ^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$", value=data__dependencygroups_val_item__includegroup, name="" + (name_prefix or "data") + ".dependency-groups.{data__dependencygroups_key}[{data__dependencygroups_val_x}].include-group".format(**locals()) + "", definition={'description': 'Another dependency group to include in this one', 'type': 'string', 'pattern': '^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$'}, rule='pattern') + if data__dependencygroups_val_item_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dependency-groups.{data__dependencygroups_key}[{data__dependencygroups_val_x}]".format(**locals()) + " must not contain "+str(data__dependencygroups_val_item_keys)+" properties", value=data__dependencygroups_val_item, name="" + (name_prefix or "data") + ".dependency-groups.{data__dependencygroups_key}[{data__dependencygroups_val_x}]".format(**locals()) + "", definition={'type': 'object', 'additionalProperties': False, 'properties': {'include-group': {'description': 'Another dependency group to include in this one', 'type': 'string', 'pattern': '^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$'}}}, rule='additionalProperties') + data__dependencygroups_val_item_one_of_count1 += 1 + except JsonSchemaValueException: pass + if data__dependencygroups_val_item_one_of_count1 != 1: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dependency-groups.{data__dependencygroups_key}[{data__dependencygroups_val_x}]".format(**locals()) + " must be valid exactly by one definition" + (" (" + str(data__dependencygroups_val_item_one_of_count1) + " matches found)"), value=data__dependencygroups_val_item, name="" + (name_prefix or "data") + ".dependency-groups.{data__dependencygroups_key}[{data__dependencygroups_val_x}]".format(**locals()) + "", definition={'oneOf': [{'type': 'string', 'description': 'Python package specifiers following PEP 508', 'format': 'pep508'}, {'type': 'object', 'additionalProperties': False, 'properties': {'include-group': {'description': 'Another dependency group to include in this one', 'type': 'string', 'pattern': '^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$'}}}]}, rule='oneOf') + if data__dependencygroups_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dependency-groups must not contain "+str(data__dependencygroups_keys)+" properties", value=data__dependencygroups, name="" + (name_prefix or "data") + ".dependency-groups", definition={'type': 'object', 'description': 'Dependency groups following PEP 735', 'additionalProperties': False, 'patternProperties': {'^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$': {'type': 'array', 'items': {'oneOf': [{'type': 'string', 'description': 'Python package specifiers following PEP 508', 'format': 'pep508'}, {'type': 'object', 'additionalProperties': False, 'properties': {'include-group': {'description': 'Another dependency group to include in this one', 'type': 'string', 'pattern': '^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$'}}}]}}}}, rule='additionalProperties') + if data_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must not contain "+str(data_keys)+" properties", value=data, name="" + (name_prefix or "data") + "", definition={'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://packaging.python.org/en/latest/specifications/declaring-build-dependencies/', 'title': 'Data structure for ``pyproject.toml`` files', '$$description': ['File format containing build-time configurations for the Python ecosystem. ', ':pep:`517` initially defined a build-system independent format for source trees', 'which was complemented by :pep:`518` to provide a way of specifying dependencies ', 'for building Python projects.', 'Please notice the ``project`` table (as initially defined in :pep:`621`) is not included', 'in this schema and should be considered separately.'], 'type': 'object', 'additionalProperties': False, 'properties': {'build-system': {'type': 'object', 'description': 'Table used to store build-related data', 'additionalProperties': False, 'properties': {'requires': {'type': 'array', '$$description': ['List of dependencies in the :pep:`508` format required to execute the build', 'system. Please notice that the resulting dependency graph', '**MUST NOT contain cycles**'], 'items': {'type': 'string'}}, 'build-backend': {'type': 'string', 'description': 'Python object that will be used to perform the build according to :pep:`517`', 'format': 'pep517-backend-reference'}, 'backend-path': {'type': 'array', '$$description': ['List of directories to be prepended to ``sys.path`` when loading the', 'back-end, and running its hooks'], 'items': {'type': 'string', '$comment': 'Should be a path (TODO: enforce it with format?)'}}}, 'required': ['requires']}, 'project': {'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://packaging.python.org/en/latest/specifications/pyproject-toml/', 'title': 'Package metadata stored in the ``project`` table', '$$description': ['Data structure for the **project** table inside ``pyproject.toml``', '(as initially defined in :pep:`621`)'], 'type': 'object', 'properties': {'name': {'type': 'string', 'description': 'The name (primary identifier) of the project. MUST be statically defined.', 'format': 'pep508-identifier'}, 'version': {'type': 'string', 'description': 'The version of the project as supported by :pep:`440`.', 'format': 'pep440'}, 'description': {'type': 'string', '$$description': ['The `summary description of the project', '<https://packaging.python.org/specifications/core-metadata/#summary>`_']}, 'readme': {'$$description': ['`Full/detailed description of the project in the form of a README', '<https://peps.python.org/pep-0621/#readme>`_', "with meaning similar to the one defined in `core metadata's Description", '<https://packaging.python.org/specifications/core-metadata/#description>`_'], 'oneOf': [{'type': 'string', '$$description': ['Relative path to a text file (UTF-8) containing the full description', 'of the project. If the file path ends in case-insensitive ``.md`` or', '``.rst`` suffixes, then the content-type is respectively', '``text/markdown`` or ``text/x-rst``']}, {'type': 'object', 'allOf': [{'anyOf': [{'properties': {'file': {'type': 'string', '$$description': ['Relative path to a text file containing the full description', 'of the project.']}}, 'required': ['file']}, {'properties': {'text': {'type': 'string', 'description': 'Full text describing the project.'}}, 'required': ['text']}]}, {'properties': {'content-type': {'type': 'string', '$$description': ['Content-type (:rfc:`1341`) of the full description', '(e.g. ``text/markdown``). The ``charset`` parameter is assumed', 'UTF-8 when not present.'], '$comment': 'TODO: add regex pattern or format?'}}, 'required': ['content-type']}]}]}, 'requires-python': {'type': 'string', 'format': 'pep508-versionspec', '$$description': ['`The Python version requirements of the project', '<https://packaging.python.org/specifications/core-metadata/#requires-python>`_.']}, 'license': {'description': '`Project license <https://peps.python.org/pep-0621/#license>`_.', 'oneOf': [{'type': 'string', 'description': 'An SPDX license identifier', 'format': 'SPDX'}, {'type': 'object', 'properties': {'file': {'type': 'string', '$$description': ['Relative path to the file (UTF-8) which contains the license for the', 'project.']}}, 'required': ['file']}, {'type': 'object', 'properties': {'text': {'type': 'string', '$$description': ['The license of the project whose meaning is that of the', '`License field from the core metadata', '<https://packaging.python.org/specifications/core-metadata/#license>`_.']}}, 'required': ['text']}]}, 'license-files': {'description': 'Paths or globs to paths of license files', 'type': 'array', 'items': {'type': 'string'}}, 'authors': {'type': 'array', 'items': {'$ref': '#/definitions/author'}, '$$description': ["The people or organizations considered to be the 'authors' of the project.", 'The exact meaning is open to interpretation (e.g. original or primary authors,', 'current maintainers, or owners of the package).']}, 'maintainers': {'type': 'array', 'items': {'$ref': '#/definitions/author'}, '$$description': ["The people or organizations considered to be the 'maintainers' of the project.", 'Similarly to ``authors``, the exact meaning is open to interpretation.']}, 'keywords': {'type': 'array', 'items': {'type': 'string'}, 'description': 'List of keywords to assist searching for the distribution in a larger catalog.'}, 'classifiers': {'type': 'array', 'items': {'type': 'string', 'format': 'trove-classifier', 'description': '`PyPI classifier <https://pypi.org/classifiers/>`_.'}, '$$description': ['`Trove classifiers <https://pypi.org/classifiers/>`_', 'which apply to the project.']}, 'urls': {'type': 'object', 'description': 'URLs associated with the project in the form ``label => value``.', 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', 'format': 'url'}}}, 'scripts': {'$ref': '#/definitions/entry-point-group', '$$description': ['Instruct the installer to create command-line wrappers for the given', '`entry points <https://packaging.python.org/specifications/entry-points/>`_.']}, 'gui-scripts': {'$ref': '#/definitions/entry-point-group', '$$description': ['Instruct the installer to create GUI wrappers for the given', '`entry points <https://packaging.python.org/specifications/entry-points/>`_.', 'The difference between ``scripts`` and ``gui-scripts`` is only relevant in', 'Windows.']}, 'entry-points': {'$$description': ['Instruct the installer to expose the given modules/functions via', '``entry-point`` discovery mechanism (useful for plugins).', 'More information available in the `Python packaging guide', '<https://packaging.python.org/specifications/entry-points/>`_.'], 'propertyNames': {'format': 'python-entrypoint-group'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'$ref': '#/definitions/entry-point-group'}}}, 'dependencies': {'type': 'array', 'description': 'Project (mandatory) dependencies.', 'items': {'$ref': '#/definitions/dependency'}}, 'optional-dependencies': {'type': 'object', 'description': 'Optional dependency for the project', 'propertyNames': {'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'array', 'items': {'$ref': '#/definitions/dependency'}}}}, 'import-names': {'description': 'Lists import names which a project, when installed, would exclusively provide.', 'type': 'array', 'items': {'type': 'string', 'format': 'import-name'}}, 'import-namespaces': {'description': 'Lists import names that, when installed, would be provided by the project, but not exclusively.', 'type': 'array', 'items': {'type': 'string', 'format': 'import-name'}}, 'dynamic': {'type': 'array', '$$description': ['Specifies which fields are intentionally unspecified and expected to be', 'dynamically provided by build tools'], 'items': {'enum': ['version', 'description', 'readme', 'requires-python', 'license', 'license-files', 'authors', 'maintainers', 'keywords', 'classifiers', 'urls', 'scripts', 'gui-scripts', 'entry-points', 'dependencies', 'optional-dependencies', 'import-names', 'import-namespaces']}}}, 'required': ['name'], 'additionalProperties': False, 'allOf': [{'if': {'not': {'required': ['dynamic'], 'properties': {'dynamic': {'contains': {'const': 'version'}, '$$description': ['version is listed in ``dynamic``']}}}, '$$comment': ['According to :pep:`621`:', ' If the core metadata specification lists a field as "Required", then', ' the metadata MUST specify the field statically or list it in dynamic', 'In turn, `core metadata`_ defines:', ' The required fields are: Metadata-Version, Name, Version.', ' All the other fields are optional.', 'Since ``Metadata-Version`` is defined by the build back-end, ``name`` and', '``version`` are the only mandatory information in ``pyproject.toml``.', '.. _core metadata: https://packaging.python.org/specifications/core-metadata/']}, 'then': {'required': ['version'], '$$description': ['version should be statically defined in the ``version`` field']}}, {'if': {'required': ['license-files']}, 'then': {'properties': {'license': {'type': 'string'}}}}], 'definitions': {'author': {'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, 'entry-point-group': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}, 'dependency': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}}, 'tool': {'type': 'object', 'properties': {'distutils': {'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://setuptools.pypa.io/en/latest/deprecated/distutils/configfile.html', 'title': '``tool.distutils`` table', '$$description': ['**EXPERIMENTAL** (NOT OFFICIALLY SUPPORTED): Use ``tool.distutils``', 'subtables to configure arguments for ``distutils`` commands.', 'Originally, ``distutils`` allowed developers to configure arguments for', '``setup.py`` commands via `distutils configuration files', '<https://setuptools.pypa.io/en/latest/deprecated/distutils/configfile.html>`_.', 'See also `the old Python docs <https://docs.python.org/3.11/install/>_`.'], 'type': 'object', 'properties': {'global': {'type': 'object', 'description': 'Global options applied to all ``distutils`` commands'}}, 'patternProperties': {'.+': {'type': 'object'}}, '$comment': 'TODO: Is there a practical way of making this schema more specific?'}, 'setuptools': {'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html', 'title': '``tool.setuptools`` table', '$$description': ['``setuptools``-specific configurations that can be set by users that require', 'customization.', 'These configurations are completely optional and probably can be skipped when', 'creating simple packages. They are equivalent to some of the `Keywords', '<https://setuptools.pypa.io/en/latest/references/keywords.html>`_', 'used by the ``setup.py`` file, and can be set via the ``tool.setuptools`` table.', 'It considers only ``setuptools`` `parameters', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#setuptools-specific-configuration>`_', 'that are not covered by :pep:`621`; and intentionally excludes ``dependency_links``', 'and ``setup_requires`` (incompatible with modern workflows/standards).'], 'type': 'object', 'additionalProperties': False, 'properties': {'platforms': {'type': 'array', 'items': {'type': 'string'}}, 'provides': {'$$description': ['Package and virtual package names contained within this package', '**(not supported by pip)**'], 'type': 'array', 'items': {'type': 'string', 'format': 'pep508-identifier'}}, 'obsoletes': {'$$description': ['Packages which this package renders obsolete', '**(not supported by pip)**'], 'type': 'array', 'items': {'type': 'string', 'format': 'pep508-identifier'}}, 'zip-safe': {'$$description': ['Whether the project can be safely installed and run from a zip file.', '**OBSOLETE**: only relevant for ``pkg_resources``, ``easy_install`` and', '``setup.py install`` in the context of ``eggs`` (**DEPRECATED**).'], 'type': 'boolean'}, 'script-files': {'$$description': ['Legacy way of defining scripts (entry-points are preferred).', 'Equivalent to the ``script`` keyword in ``setup.py``', '(it was renamed to avoid confusion with entry-point based ``project.scripts``', 'defined in :pep:`621`).', '**DISCOURAGED**: generic script wrappers are tricky and may not work properly.', 'Whenever possible, please use ``project.scripts`` instead.'], 'type': 'array', 'items': {'type': 'string'}, '$comment': 'TODO: is this field deprecated/should be removed?'}, 'eager-resources': {'$$description': ['Resources that should be extracted together, if any of them is needed,', 'or if any C extensions included in the project are imported.', '**OBSOLETE**: only relevant for ``pkg_resources``, ``easy_install`` and', '``setup.py install`` in the context of ``eggs`` (**DEPRECATED**).'], 'type': 'array', 'items': {'type': 'string'}}, 'packages': {'$$description': ['Packages that should be included in the distribution.', 'It can be given either as a list of package identifiers', 'or as a ``dict``-like structure with a single key ``find``', 'which corresponds to a dynamic call to', '``setuptools.config.expand.find_packages`` function.', 'The ``find`` key is associated with a nested ``dict``-like structure that can', 'contain ``where``, ``include``, ``exclude`` and ``namespaces`` keys,', 'mimicking the keyword arguments of the associated function.'], 'oneOf': [{'title': 'Array of Python package identifiers', 'type': 'array', 'items': {'$ref': '#/definitions/package-name'}}, {'$ref': '#/definitions/find-directive'}]}, 'package-dir': {'$$description': [':class:`dict`-like structure mapping from package names to directories where their', 'code can be found.', 'The empty string (as key) means that all packages are contained inside', 'the given directory will be included in the distribution.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'const': ''}, {'$ref': '#/definitions/package-name'}]}, 'patternProperties': {'^.*$': {'type': 'string'}}}, 'package-data': {'$$description': ['Mapping from package names to lists of glob patterns.', 'Usually this option is not needed when using ``include-package-data = true``', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'$ref': '#/definitions/package-name'}, {'const': '*'}]}, 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, 'include-package-data': {'$$description': ['Automatically include any data files inside the package directories', 'that are specified by ``MANIFEST.in``', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'boolean'}, 'exclude-package-data': {'$$description': ['Mapping from package names to lists of glob patterns that should be excluded', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'$ref': '#/definitions/package-name'}, {'const': '*'}]}, 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, 'namespace-packages': {'type': 'array', 'items': {'type': 'string', 'format': 'python-module-name-relaxed'}, '$comment': 'https://setuptools.pypa.io/en/latest/userguide/package_discovery.html', 'description': '**DEPRECATED**: use implicit namespaces instead (:pep:`420`).'}, 'py-modules': {'description': 'Modules that setuptools will manipulate', 'type': 'array', 'items': {'type': 'string', 'format': 'python-module-name-relaxed'}, '$comment': 'TODO: clarify the relationship with ``packages``'}, 'ext-modules': {'description': 'Extension modules to be compiled by setuptools', 'type': 'array', 'items': {'$ref': '#/definitions/ext-module'}}, 'data-files': {'$$description': ['``dict``-like structure where each key represents a directory and', 'the value is a list of glob patterns that should be installed in them.', '**DISCOURAGED**: please notice this might not work as expected with wheels.', 'Whenever possible, consider using data files inside the package directories', '(or create a new namespace package that only contains data files).', 'See `data files support', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, 'cmdclass': {'$$description': ['Mapping of distutils-style command names to ``setuptools.Command`` subclasses', 'which in turn should be represented by strings with a qualified class name', '(i.e., "dotted" form with module), e.g.::\n\n', ' cmdclass = {mycmd = "pkg.subpkg.module.CommandClass"}\n\n', 'The command class should be a directly defined at the top-level of the', 'containing module (no class nesting).'], 'type': 'object', 'patternProperties': {'^.*$': {'type': 'string', 'format': 'python-qualified-identifier'}}}, 'license-files': {'type': 'array', 'items': {'type': 'string'}, '$$description': ['**PROVISIONAL**: list of glob patterns for all license files being distributed.', '(likely to become standard with :pep:`639`).', "By default: ``['LICEN[CS]E*', 'COPYING*', 'NOTICE*', 'AUTHORS*']``"], '$comment': 'TODO: revise if PEP 639 is accepted. Probably ``project.license-files``?'}, 'dynamic': {'type': 'object', 'description': 'Instructions for loading :pep:`621`-related metadata dynamically', 'additionalProperties': False, 'properties': {'version': {'$$description': ['A version dynamically loaded via either the ``attr:`` or ``file:``', 'directives. Please make sure the given file or attribute respects :pep:`440`.', 'Also ensure to set ``project.dynamic`` accordingly.'], 'oneOf': [{'$ref': '#/definitions/attr-directive'}, {'$ref': '#/definitions/file-directive'}]}, 'classifiers': {'$ref': '#/definitions/file-directive'}, 'description': {'$ref': '#/definitions/file-directive'}, 'entry-points': {'$ref': '#/definitions/file-directive'}, 'dependencies': {'$ref': '#/definitions/file-directive-for-dependencies'}, 'optional-dependencies': {'type': 'object', 'propertyNames': {'type': 'string', 'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'.+': {'$ref': '#/definitions/file-directive-for-dependencies'}}}, 'readme': {'type': 'object', 'anyOf': [{'$ref': '#/definitions/file-directive'}, {'type': 'object', 'properties': {'content-type': {'type': 'string'}, 'file': {'$ref': '#/definitions/file-directive/properties/file'}}, 'additionalProperties': False}], 'required': ['file']}}}}, 'definitions': {'package-name': {'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, 'ext-module': {'$id': '#/definitions/ext-module', 'title': 'Extension module', 'description': 'Parameters to construct a :class:`setuptools.Extension` object', 'type': 'object', 'required': ['name', 'sources'], 'additionalProperties': False, 'properties': {'name': {'type': 'string', 'format': 'python-module-name-relaxed'}, 'sources': {'type': 'array', 'items': {'type': 'string'}}, 'include-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'define-macros': {'type': 'array', 'items': {'type': 'array', 'items': [{'description': 'macro name', 'type': 'string'}, {'description': 'macro value', 'oneOf': [{'type': 'string'}, {'type': 'null'}]}], 'additionalItems': False}}, 'undef-macros': {'type': 'array', 'items': {'type': 'string'}}, 'library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'libraries': {'type': 'array', 'items': {'type': 'string'}}, 'runtime-library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'extra-objects': {'type': 'array', 'items': {'type': 'string'}}, 'extra-compile-args': {'type': 'array', 'items': {'type': 'string'}}, 'extra-link-args': {'type': 'array', 'items': {'type': 'string'}}, 'export-symbols': {'type': 'array', 'items': {'type': 'string'}}, 'swig-opts': {'type': 'array', 'items': {'type': 'string'}}, 'depends': {'type': 'array', 'items': {'type': 'string'}}, 'language': {'type': 'string'}, 'optional': {'type': 'boolean'}, 'py-limited-api': {'type': 'boolean'}}}, 'file-directive': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'file-directive-for-dependencies': {'title': "'file:' directive for dependencies", 'allOf': [{'$$description': ['**BETA**: subset of the ``requirements.txt`` format', 'without ``pip`` flags and options', '(one :pep:`508`-compliant string per line,', 'lines that are blank or start with ``#`` are excluded).', 'See `dynamic metadata', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata>`_.']}, {'$ref': '#/definitions/file-directive'}]}, 'attr-directive': {'title': "'attr:' directive", '$id': '#/definitions/attr-directive', '$$description': ['Value is read from a module attribute. Supports callables and iterables;', 'unsupported types are cast via ``str()``'], 'type': 'object', 'additionalProperties': False, 'properties': {'attr': {'type': 'string', 'format': 'python-qualified-identifier'}}, 'required': ['attr']}, 'find-directive': {'$id': '#/definitions/find-directive', 'title': "'find:' directive", 'type': 'object', 'additionalProperties': False, 'properties': {'find': {'type': 'object', '$$description': ['Dynamic `package discovery', '<https://setuptools.pypa.io/en/latest/userguide/package_discovery.html>`_.'], 'additionalProperties': False, 'properties': {'where': {'description': 'Directories to be searched for packages (Unix-style relative path)', 'type': 'array', 'items': {'type': 'string'}}, 'exclude': {'type': 'array', '$$description': ['Exclude packages that match the values listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'include': {'type': 'array', '$$description': ['Restrict the found packages to just the ones listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'namespaces': {'type': 'boolean', '$$description': ['When ``True``, directories without a ``__init__.py`` file will also', 'be scanned for :pep:`420`-style implicit namespaces']}}}}}}}}}, 'dependency-groups': {'type': 'object', 'description': 'Dependency groups following PEP 735', 'additionalProperties': False, 'patternProperties': {'^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$': {'type': 'array', 'items': {'oneOf': [{'type': 'string', 'description': 'Python package specifiers following PEP 508', 'format': 'pep508'}, {'type': 'object', 'additionalProperties': False, 'properties': {'include-group': {'description': 'Another dependency group to include in this one', 'type': 'string', 'pattern': '^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9])$'}}}]}}}}}, 'project': {'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://packaging.python.org/en/latest/specifications/pyproject-toml/', 'title': 'Package metadata stored in the ``project`` table', '$$description': ['Data structure for the **project** table inside ``pyproject.toml``', '(as initially defined in :pep:`621`)'], 'type': 'object', 'properties': {'name': {'type': 'string', 'description': 'The name (primary identifier) of the project. MUST be statically defined.', 'format': 'pep508-identifier'}, 'version': {'type': 'string', 'description': 'The version of the project as supported by :pep:`440`.', 'format': 'pep440'}, 'description': {'type': 'string', '$$description': ['The `summary description of the project', '<https://packaging.python.org/specifications/core-metadata/#summary>`_']}, 'readme': {'$$description': ['`Full/detailed description of the project in the form of a README', '<https://peps.python.org/pep-0621/#readme>`_', "with meaning similar to the one defined in `core metadata's Description", '<https://packaging.python.org/specifications/core-metadata/#description>`_'], 'oneOf': [{'type': 'string', '$$description': ['Relative path to a text file (UTF-8) containing the full description', 'of the project. If the file path ends in case-insensitive ``.md`` or', '``.rst`` suffixes, then the content-type is respectively', '``text/markdown`` or ``text/x-rst``']}, {'type': 'object', 'allOf': [{'anyOf': [{'properties': {'file': {'type': 'string', '$$description': ['Relative path to a text file containing the full description', 'of the project.']}}, 'required': ['file']}, {'properties': {'text': {'type': 'string', 'description': 'Full text describing the project.'}}, 'required': ['text']}]}, {'properties': {'content-type': {'type': 'string', '$$description': ['Content-type (:rfc:`1341`) of the full description', '(e.g. ``text/markdown``). The ``charset`` parameter is assumed', 'UTF-8 when not present.'], '$comment': 'TODO: add regex pattern or format?'}}, 'required': ['content-type']}]}]}, 'requires-python': {'type': 'string', 'format': 'pep508-versionspec', '$$description': ['`The Python version requirements of the project', '<https://packaging.python.org/specifications/core-metadata/#requires-python>`_.']}, 'license': {'description': '`Project license <https://peps.python.org/pep-0621/#license>`_.', 'oneOf': [{'type': 'string', 'description': 'An SPDX license identifier', 'format': 'SPDX'}, {'type': 'object', 'properties': {'file': {'type': 'string', '$$description': ['Relative path to the file (UTF-8) which contains the license for the', 'project.']}}, 'required': ['file']}, {'type': 'object', 'properties': {'text': {'type': 'string', '$$description': ['The license of the project whose meaning is that of the', '`License field from the core metadata', '<https://packaging.python.org/specifications/core-metadata/#license>`_.']}}, 'required': ['text']}]}, 'license-files': {'description': 'Paths or globs to paths of license files', 'type': 'array', 'items': {'type': 'string'}}, 'authors': {'type': 'array', 'items': {'$ref': '#/definitions/author'}, '$$description': ["The people or organizations considered to be the 'authors' of the project.", 'The exact meaning is open to interpretation (e.g. original or primary authors,', 'current maintainers, or owners of the package).']}, 'maintainers': {'type': 'array', 'items': {'$ref': '#/definitions/author'}, '$$description': ["The people or organizations considered to be the 'maintainers' of the project.", 'Similarly to ``authors``, the exact meaning is open to interpretation.']}, 'keywords': {'type': 'array', 'items': {'type': 'string'}, 'description': 'List of keywords to assist searching for the distribution in a larger catalog.'}, 'classifiers': {'type': 'array', 'items': {'type': 'string', 'format': 'trove-classifier', 'description': '`PyPI classifier <https://pypi.org/classifiers/>`_.'}, '$$description': ['`Trove classifiers <https://pypi.org/classifiers/>`_', 'which apply to the project.']}, 'urls': {'type': 'object', 'description': 'URLs associated with the project in the form ``label => value``.', 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', 'format': 'url'}}}, 'scripts': {'$ref': '#/definitions/entry-point-group', '$$description': ['Instruct the installer to create command-line wrappers for the given', '`entry points <https://packaging.python.org/specifications/entry-points/>`_.']}, 'gui-scripts': {'$ref': '#/definitions/entry-point-group', '$$description': ['Instruct the installer to create GUI wrappers for the given', '`entry points <https://packaging.python.org/specifications/entry-points/>`_.', 'The difference between ``scripts`` and ``gui-scripts`` is only relevant in', 'Windows.']}, 'entry-points': {'$$description': ['Instruct the installer to expose the given modules/functions via', '``entry-point`` discovery mechanism (useful for plugins).', 'More information available in the `Python packaging guide', '<https://packaging.python.org/specifications/entry-points/>`_.'], 'propertyNames': {'format': 'python-entrypoint-group'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'$ref': '#/definitions/entry-point-group'}}}, 'dependencies': {'type': 'array', 'description': 'Project (mandatory) dependencies.', 'items': {'$ref': '#/definitions/dependency'}}, 'optional-dependencies': {'type': 'object', 'description': 'Optional dependency for the project', 'propertyNames': {'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'array', 'items': {'$ref': '#/definitions/dependency'}}}}, 'import-names': {'description': 'Lists import names which a project, when installed, would exclusively provide.', 'type': 'array', 'items': {'type': 'string', 'format': 'import-name'}}, 'import-namespaces': {'description': 'Lists import names that, when installed, would be provided by the project, but not exclusively.', 'type': 'array', 'items': {'type': 'string', 'format': 'import-name'}}, 'dynamic': {'type': 'array', '$$description': ['Specifies which fields are intentionally unspecified and expected to be', 'dynamically provided by build tools'], 'items': {'enum': ['version', 'description', 'readme', 'requires-python', 'license', 'license-files', 'authors', 'maintainers', 'keywords', 'classifiers', 'urls', 'scripts', 'gui-scripts', 'entry-points', 'dependencies', 'optional-dependencies', 'import-names', 'import-namespaces']}}}, 'required': ['name'], 'additionalProperties': False, 'allOf': [{'if': {'not': {'required': ['dynamic'], 'properties': {'dynamic': {'contains': {'const': 'version'}, '$$description': ['version is listed in ``dynamic``']}}}, '$$comment': ['According to :pep:`621`:', ' If the core metadata specification lists a field as "Required", then', ' the metadata MUST specify the field statically or list it in dynamic', 'In turn, `core metadata`_ defines:', ' The required fields are: Metadata-Version, Name, Version.', ' All the other fields are optional.', 'Since ``Metadata-Version`` is defined by the build back-end, ``name`` and', '``version`` are the only mandatory information in ``pyproject.toml``.', '.. _core metadata: https://packaging.python.org/specifications/core-metadata/']}, 'then': {'required': ['version'], '$$description': ['version should be statically defined in the ``version`` field']}}, {'if': {'required': ['license-files']}, 'then': {'properties': {'license': {'type': 'string'}}}}], 'definitions': {'author': {'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, 'entry-point-group': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}, 'dependency': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}}}, rule='additionalProperties') + return data + +def validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html(data, custom_formats={}, name_prefix=None): + if not isinstance(data, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be object", value=data, name="" + (name_prefix or "data") + "", definition={'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html', 'title': '``tool.setuptools`` table', '$$description': ['``setuptools``-specific configurations that can be set by users that require', 'customization.', 'These configurations are completely optional and probably can be skipped when', 'creating simple packages. They are equivalent to some of the `Keywords', '<https://setuptools.pypa.io/en/latest/references/keywords.html>`_', 'used by the ``setup.py`` file, and can be set via the ``tool.setuptools`` table.', 'It considers only ``setuptools`` `parameters', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#setuptools-specific-configuration>`_', 'that are not covered by :pep:`621`; and intentionally excludes ``dependency_links``', 'and ``setup_requires`` (incompatible with modern workflows/standards).'], 'type': 'object', 'additionalProperties': False, 'properties': {'platforms': {'type': 'array', 'items': {'type': 'string'}}, 'provides': {'$$description': ['Package and virtual package names contained within this package', '**(not supported by pip)**'], 'type': 'array', 'items': {'type': 'string', 'format': 'pep508-identifier'}}, 'obsoletes': {'$$description': ['Packages which this package renders obsolete', '**(not supported by pip)**'], 'type': 'array', 'items': {'type': 'string', 'format': 'pep508-identifier'}}, 'zip-safe': {'$$description': ['Whether the project can be safely installed and run from a zip file.', '**OBSOLETE**: only relevant for ``pkg_resources``, ``easy_install`` and', '``setup.py install`` in the context of ``eggs`` (**DEPRECATED**).'], 'type': 'boolean'}, 'script-files': {'$$description': ['Legacy way of defining scripts (entry-points are preferred).', 'Equivalent to the ``script`` keyword in ``setup.py``', '(it was renamed to avoid confusion with entry-point based ``project.scripts``', 'defined in :pep:`621`).', '**DISCOURAGED**: generic script wrappers are tricky and may not work properly.', 'Whenever possible, please use ``project.scripts`` instead.'], 'type': 'array', 'items': {'type': 'string'}, '$comment': 'TODO: is this field deprecated/should be removed?'}, 'eager-resources': {'$$description': ['Resources that should be extracted together, if any of them is needed,', 'or if any C extensions included in the project are imported.', '**OBSOLETE**: only relevant for ``pkg_resources``, ``easy_install`` and', '``setup.py install`` in the context of ``eggs`` (**DEPRECATED**).'], 'type': 'array', 'items': {'type': 'string'}}, 'packages': {'$$description': ['Packages that should be included in the distribution.', 'It can be given either as a list of package identifiers', 'or as a ``dict``-like structure with a single key ``find``', 'which corresponds to a dynamic call to', '``setuptools.config.expand.find_packages`` function.', 'The ``find`` key is associated with a nested ``dict``-like structure that can', 'contain ``where``, ``include``, ``exclude`` and ``namespaces`` keys,', 'mimicking the keyword arguments of the associated function.'], 'oneOf': [{'title': 'Array of Python package identifiers', 'type': 'array', 'items': {'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}}, {'$id': '#/definitions/find-directive', 'title': "'find:' directive", 'type': 'object', 'additionalProperties': False, 'properties': {'find': {'type': 'object', '$$description': ['Dynamic `package discovery', '<https://setuptools.pypa.io/en/latest/userguide/package_discovery.html>`_.'], 'additionalProperties': False, 'properties': {'where': {'description': 'Directories to be searched for packages (Unix-style relative path)', 'type': 'array', 'items': {'type': 'string'}}, 'exclude': {'type': 'array', '$$description': ['Exclude packages that match the values listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'include': {'type': 'array', '$$description': ['Restrict the found packages to just the ones listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'namespaces': {'type': 'boolean', '$$description': ['When ``True``, directories without a ``__init__.py`` file will also', 'be scanned for :pep:`420`-style implicit namespaces']}}}}}]}, 'package-dir': {'$$description': [':class:`dict`-like structure mapping from package names to directories where their', 'code can be found.', 'The empty string (as key) means that all packages are contained inside', 'the given directory will be included in the distribution.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'const': ''}, {'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}]}, 'patternProperties': {'^.*$': {'type': 'string'}}}, 'package-data': {'$$description': ['Mapping from package names to lists of glob patterns.', 'Usually this option is not needed when using ``include-package-data = true``', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, {'const': '*'}]}, 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, 'include-package-data': {'$$description': ['Automatically include any data files inside the package directories', 'that are specified by ``MANIFEST.in``', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'boolean'}, 'exclude-package-data': {'$$description': ['Mapping from package names to lists of glob patterns that should be excluded', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, {'const': '*'}]}, 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, 'namespace-packages': {'type': 'array', 'items': {'type': 'string', 'format': 'python-module-name-relaxed'}, '$comment': 'https://setuptools.pypa.io/en/latest/userguide/package_discovery.html', 'description': '**DEPRECATED**: use implicit namespaces instead (:pep:`420`).'}, 'py-modules': {'description': 'Modules that setuptools will manipulate', 'type': 'array', 'items': {'type': 'string', 'format': 'python-module-name-relaxed'}, '$comment': 'TODO: clarify the relationship with ``packages``'}, 'ext-modules': {'description': 'Extension modules to be compiled by setuptools', 'type': 'array', 'items': {'$id': '#/definitions/ext-module', 'title': 'Extension module', 'description': 'Parameters to construct a :class:`setuptools.Extension` object', 'type': 'object', 'required': ['name', 'sources'], 'additionalProperties': False, 'properties': {'name': {'type': 'string', 'format': 'python-module-name-relaxed'}, 'sources': {'type': 'array', 'items': {'type': 'string'}}, 'include-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'define-macros': {'type': 'array', 'items': {'type': 'array', 'items': [{'description': 'macro name', 'type': 'string'}, {'description': 'macro value', 'oneOf': [{'type': 'string'}, {'type': 'null'}]}], 'additionalItems': False}}, 'undef-macros': {'type': 'array', 'items': {'type': 'string'}}, 'library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'libraries': {'type': 'array', 'items': {'type': 'string'}}, 'runtime-library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'extra-objects': {'type': 'array', 'items': {'type': 'string'}}, 'extra-compile-args': {'type': 'array', 'items': {'type': 'string'}}, 'extra-link-args': {'type': 'array', 'items': {'type': 'string'}}, 'export-symbols': {'type': 'array', 'items': {'type': 'string'}}, 'swig-opts': {'type': 'array', 'items': {'type': 'string'}}, 'depends': {'type': 'array', 'items': {'type': 'string'}}, 'language': {'type': 'string'}, 'optional': {'type': 'boolean'}, 'py-limited-api': {'type': 'boolean'}}}}, 'data-files': {'$$description': ['``dict``-like structure where each key represents a directory and', 'the value is a list of glob patterns that should be installed in them.', '**DISCOURAGED**: please notice this might not work as expected with wheels.', 'Whenever possible, consider using data files inside the package directories', '(or create a new namespace package that only contains data files).', 'See `data files support', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, 'cmdclass': {'$$description': ['Mapping of distutils-style command names to ``setuptools.Command`` subclasses', 'which in turn should be represented by strings with a qualified class name', '(i.e., "dotted" form with module), e.g.::\n\n', ' cmdclass = {mycmd = "pkg.subpkg.module.CommandClass"}\n\n', 'The command class should be a directly defined at the top-level of the', 'containing module (no class nesting).'], 'type': 'object', 'patternProperties': {'^.*$': {'type': 'string', 'format': 'python-qualified-identifier'}}}, 'license-files': {'type': 'array', 'items': {'type': 'string'}, '$$description': ['**PROVISIONAL**: list of glob patterns for all license files being distributed.', '(likely to become standard with :pep:`639`).', "By default: ``['LICEN[CS]E*', 'COPYING*', 'NOTICE*', 'AUTHORS*']``"], '$comment': 'TODO: revise if PEP 639 is accepted. Probably ``project.license-files``?'}, 'dynamic': {'type': 'object', 'description': 'Instructions for loading :pep:`621`-related metadata dynamically', 'additionalProperties': False, 'properties': {'version': {'$$description': ['A version dynamically loaded via either the ``attr:`` or ``file:``', 'directives. Please make sure the given file or attribute respects :pep:`440`.', 'Also ensure to set ``project.dynamic`` accordingly.'], 'oneOf': [{'title': "'attr:' directive", '$id': '#/definitions/attr-directive', '$$description': ['Value is read from a module attribute. Supports callables and iterables;', 'unsupported types are cast via ``str()``'], 'type': 'object', 'additionalProperties': False, 'properties': {'attr': {'type': 'string', 'format': 'python-qualified-identifier'}}, 'required': ['attr']}, {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}]}, 'classifiers': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'description': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'entry-points': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'dependencies': {'title': "'file:' directive for dependencies", 'allOf': [{'$$description': ['**BETA**: subset of the ``requirements.txt`` format', 'without ``pip`` flags and options', '(one :pep:`508`-compliant string per line,', 'lines that are blank or start with ``#`` are excluded).', 'See `dynamic metadata', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata>`_.']}, {'$ref': '#/definitions/file-directive'}]}, 'optional-dependencies': {'type': 'object', 'propertyNames': {'type': 'string', 'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'.+': {'title': "'file:' directive for dependencies", 'allOf': [{'$$description': ['**BETA**: subset of the ``requirements.txt`` format', 'without ``pip`` flags and options', '(one :pep:`508`-compliant string per line,', 'lines that are blank or start with ``#`` are excluded).', 'See `dynamic metadata', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata>`_.']}, {'$ref': '#/definitions/file-directive'}]}}}, 'readme': {'type': 'object', 'anyOf': [{'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, {'type': 'object', 'properties': {'content-type': {'type': 'string'}, 'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'additionalProperties': False}], 'required': ['file']}}}}, 'definitions': {'package-name': {'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, 'ext-module': {'$id': '#/definitions/ext-module', 'title': 'Extension module', 'description': 'Parameters to construct a :class:`setuptools.Extension` object', 'type': 'object', 'required': ['name', 'sources'], 'additionalProperties': False, 'properties': {'name': {'type': 'string', 'format': 'python-module-name-relaxed'}, 'sources': {'type': 'array', 'items': {'type': 'string'}}, 'include-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'define-macros': {'type': 'array', 'items': {'type': 'array', 'items': [{'description': 'macro name', 'type': 'string'}, {'description': 'macro value', 'oneOf': [{'type': 'string'}, {'type': 'null'}]}], 'additionalItems': False}}, 'undef-macros': {'type': 'array', 'items': {'type': 'string'}}, 'library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'libraries': {'type': 'array', 'items': {'type': 'string'}}, 'runtime-library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'extra-objects': {'type': 'array', 'items': {'type': 'string'}}, 'extra-compile-args': {'type': 'array', 'items': {'type': 'string'}}, 'extra-link-args': {'type': 'array', 'items': {'type': 'string'}}, 'export-symbols': {'type': 'array', 'items': {'type': 'string'}}, 'swig-opts': {'type': 'array', 'items': {'type': 'string'}}, 'depends': {'type': 'array', 'items': {'type': 'string'}}, 'language': {'type': 'string'}, 'optional': {'type': 'boolean'}, 'py-limited-api': {'type': 'boolean'}}}, 'file-directive': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'file-directive-for-dependencies': {'title': "'file:' directive for dependencies", 'allOf': [{'$$description': ['**BETA**: subset of the ``requirements.txt`` format', 'without ``pip`` flags and options', '(one :pep:`508`-compliant string per line,', 'lines that are blank or start with ``#`` are excluded).', 'See `dynamic metadata', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata>`_.']}, {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}]}, 'attr-directive': {'title': "'attr:' directive", '$id': '#/definitions/attr-directive', '$$description': ['Value is read from a module attribute. Supports callables and iterables;', 'unsupported types are cast via ``str()``'], 'type': 'object', 'additionalProperties': False, 'properties': {'attr': {'type': 'string', 'format': 'python-qualified-identifier'}}, 'required': ['attr']}, 'find-directive': {'$id': '#/definitions/find-directive', 'title': "'find:' directive", 'type': 'object', 'additionalProperties': False, 'properties': {'find': {'type': 'object', '$$description': ['Dynamic `package discovery', '<https://setuptools.pypa.io/en/latest/userguide/package_discovery.html>`_.'], 'additionalProperties': False, 'properties': {'where': {'description': 'Directories to be searched for packages (Unix-style relative path)', 'type': 'array', 'items': {'type': 'string'}}, 'exclude': {'type': 'array', '$$description': ['Exclude packages that match the values listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'include': {'type': 'array', '$$description': ['Restrict the found packages to just the ones listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'namespaces': {'type': 'boolean', '$$description': ['When ``True``, directories without a ``__init__.py`` file will also', 'be scanned for :pep:`420`-style implicit namespaces']}}}}}}}, rule='type') + data_is_dict = isinstance(data, dict) + if data_is_dict: + data_keys = set(data.keys()) + if "platforms" in data_keys: + data_keys.remove("platforms") + data__platforms = data["platforms"] + if not isinstance(data__platforms, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".platforms must be array", value=data__platforms, name="" + (name_prefix or "data") + ".platforms", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__platforms_is_list = isinstance(data__platforms, (list, tuple)) + if data__platforms_is_list: + data__platforms_len = len(data__platforms) + for data__platforms_x, data__platforms_item in enumerate(data__platforms): + if not isinstance(data__platforms_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".platforms[{data__platforms_x}]".format(**locals()) + " must be string", value=data__platforms_item, name="" + (name_prefix or "data") + ".platforms[{data__platforms_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "provides" in data_keys: + data_keys.remove("provides") + data__provides = data["provides"] + if not isinstance(data__provides, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".provides must be array", value=data__provides, name="" + (name_prefix or "data") + ".provides", definition={'$$description': ['Package and virtual package names contained within this package', '**(not supported by pip)**'], 'type': 'array', 'items': {'type': 'string', 'format': 'pep508-identifier'}}, rule='type') + data__provides_is_list = isinstance(data__provides, (list, tuple)) + if data__provides_is_list: + data__provides_len = len(data__provides) + for data__provides_x, data__provides_item in enumerate(data__provides): + if not isinstance(data__provides_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".provides[{data__provides_x}]".format(**locals()) + " must be string", value=data__provides_item, name="" + (name_prefix or "data") + ".provides[{data__provides_x}]".format(**locals()) + "", definition={'type': 'string', 'format': 'pep508-identifier'}, rule='type') + if isinstance(data__provides_item, str): + if not custom_formats["pep508-identifier"](data__provides_item): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".provides[{data__provides_x}]".format(**locals()) + " must be pep508-identifier", value=data__provides_item, name="" + (name_prefix or "data") + ".provides[{data__provides_x}]".format(**locals()) + "", definition={'type': 'string', 'format': 'pep508-identifier'}, rule='format') + if "obsoletes" in data_keys: + data_keys.remove("obsoletes") + data__obsoletes = data["obsoletes"] + if not isinstance(data__obsoletes, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".obsoletes must be array", value=data__obsoletes, name="" + (name_prefix or "data") + ".obsoletes", definition={'$$description': ['Packages which this package renders obsolete', '**(not supported by pip)**'], 'type': 'array', 'items': {'type': 'string', 'format': 'pep508-identifier'}}, rule='type') + data__obsoletes_is_list = isinstance(data__obsoletes, (list, tuple)) + if data__obsoletes_is_list: + data__obsoletes_len = len(data__obsoletes) + for data__obsoletes_x, data__obsoletes_item in enumerate(data__obsoletes): + if not isinstance(data__obsoletes_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".obsoletes[{data__obsoletes_x}]".format(**locals()) + " must be string", value=data__obsoletes_item, name="" + (name_prefix or "data") + ".obsoletes[{data__obsoletes_x}]".format(**locals()) + "", definition={'type': 'string', 'format': 'pep508-identifier'}, rule='type') + if isinstance(data__obsoletes_item, str): + if not custom_formats["pep508-identifier"](data__obsoletes_item): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".obsoletes[{data__obsoletes_x}]".format(**locals()) + " must be pep508-identifier", value=data__obsoletes_item, name="" + (name_prefix or "data") + ".obsoletes[{data__obsoletes_x}]".format(**locals()) + "", definition={'type': 'string', 'format': 'pep508-identifier'}, rule='format') + if "zip-safe" in data_keys: + data_keys.remove("zip-safe") + data__zipsafe = data["zip-safe"] + if not isinstance(data__zipsafe, (bool)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".zip-safe must be boolean", value=data__zipsafe, name="" + (name_prefix or "data") + ".zip-safe", definition={'$$description': ['Whether the project can be safely installed and run from a zip file.', '**OBSOLETE**: only relevant for ``pkg_resources``, ``easy_install`` and', '``setup.py install`` in the context of ``eggs`` (**DEPRECATED**).'], 'type': 'boolean'}, rule='type') + if "script-files" in data_keys: + data_keys.remove("script-files") + data__scriptfiles = data["script-files"] + if not isinstance(data__scriptfiles, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".script-files must be array", value=data__scriptfiles, name="" + (name_prefix or "data") + ".script-files", definition={'$$description': ['Legacy way of defining scripts (entry-points are preferred).', 'Equivalent to the ``script`` keyword in ``setup.py``', '(it was renamed to avoid confusion with entry-point based ``project.scripts``', 'defined in :pep:`621`).', '**DISCOURAGED**: generic script wrappers are tricky and may not work properly.', 'Whenever possible, please use ``project.scripts`` instead.'], 'type': 'array', 'items': {'type': 'string'}, '$comment': 'TODO: is this field deprecated/should be removed?'}, rule='type') + data__scriptfiles_is_list = isinstance(data__scriptfiles, (list, tuple)) + if data__scriptfiles_is_list: + data__scriptfiles_len = len(data__scriptfiles) + for data__scriptfiles_x, data__scriptfiles_item in enumerate(data__scriptfiles): + if not isinstance(data__scriptfiles_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".script-files[{data__scriptfiles_x}]".format(**locals()) + " must be string", value=data__scriptfiles_item, name="" + (name_prefix or "data") + ".script-files[{data__scriptfiles_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "eager-resources" in data_keys: + data_keys.remove("eager-resources") + data__eagerresources = data["eager-resources"] + if not isinstance(data__eagerresources, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".eager-resources must be array", value=data__eagerresources, name="" + (name_prefix or "data") + ".eager-resources", definition={'$$description': ['Resources that should be extracted together, if any of them is needed,', 'or if any C extensions included in the project are imported.', '**OBSOLETE**: only relevant for ``pkg_resources``, ``easy_install`` and', '``setup.py install`` in the context of ``eggs`` (**DEPRECATED**).'], 'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__eagerresources_is_list = isinstance(data__eagerresources, (list, tuple)) + if data__eagerresources_is_list: + data__eagerresources_len = len(data__eagerresources) + for data__eagerresources_x, data__eagerresources_item in enumerate(data__eagerresources): + if not isinstance(data__eagerresources_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".eager-resources[{data__eagerresources_x}]".format(**locals()) + " must be string", value=data__eagerresources_item, name="" + (name_prefix or "data") + ".eager-resources[{data__eagerresources_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "packages" in data_keys: + data_keys.remove("packages") + data__packages = data["packages"] + data__packages_one_of_count2 = 0 + if data__packages_one_of_count2 < 2: + try: + if not isinstance(data__packages, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".packages must be array", value=data__packages, name="" + (name_prefix or "data") + ".packages", definition={'title': 'Array of Python package identifiers', 'type': 'array', 'items': {'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}}, rule='type') + data__packages_is_list = isinstance(data__packages, (list, tuple)) + if data__packages_is_list: + data__packages_len = len(data__packages) + for data__packages_x, data__packages_item in enumerate(data__packages): + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_package_name(data__packages_item, custom_formats, (name_prefix or "data") + ".packages[{data__packages_x}]".format(**locals())) + data__packages_one_of_count2 += 1 + except JsonSchemaValueException: pass + if data__packages_one_of_count2 < 2: + try: + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_find_directive(data__packages, custom_formats, (name_prefix or "data") + ".packages") + data__packages_one_of_count2 += 1 + except JsonSchemaValueException: pass + if data__packages_one_of_count2 != 1: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".packages must be valid exactly by one definition" + (" (" + str(data__packages_one_of_count2) + " matches found)"), value=data__packages, name="" + (name_prefix or "data") + ".packages", definition={'$$description': ['Packages that should be included in the distribution.', 'It can be given either as a list of package identifiers', 'or as a ``dict``-like structure with a single key ``find``', 'which corresponds to a dynamic call to', '``setuptools.config.expand.find_packages`` function.', 'The ``find`` key is associated with a nested ``dict``-like structure that can', 'contain ``where``, ``include``, ``exclude`` and ``namespaces`` keys,', 'mimicking the keyword arguments of the associated function.'], 'oneOf': [{'title': 'Array of Python package identifiers', 'type': 'array', 'items': {'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}}, {'$id': '#/definitions/find-directive', 'title': "'find:' directive", 'type': 'object', 'additionalProperties': False, 'properties': {'find': {'type': 'object', '$$description': ['Dynamic `package discovery', '<https://setuptools.pypa.io/en/latest/userguide/package_discovery.html>`_.'], 'additionalProperties': False, 'properties': {'where': {'description': 'Directories to be searched for packages (Unix-style relative path)', 'type': 'array', 'items': {'type': 'string'}}, 'exclude': {'type': 'array', '$$description': ['Exclude packages that match the values listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'include': {'type': 'array', '$$description': ['Restrict the found packages to just the ones listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'namespaces': {'type': 'boolean', '$$description': ['When ``True``, directories without a ``__init__.py`` file will also', 'be scanned for :pep:`420`-style implicit namespaces']}}}}}]}, rule='oneOf') + if "package-dir" in data_keys: + data_keys.remove("package-dir") + data__packagedir = data["package-dir"] + if not isinstance(data__packagedir, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".package-dir must be object", value=data__packagedir, name="" + (name_prefix or "data") + ".package-dir", definition={'$$description': [':class:`dict`-like structure mapping from package names to directories where their', 'code can be found.', 'The empty string (as key) means that all packages are contained inside', 'the given directory will be included in the distribution.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'const': ''}, {'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}]}, 'patternProperties': {'^.*$': {'type': 'string'}}}, rule='type') + data__packagedir_is_dict = isinstance(data__packagedir, dict) + if data__packagedir_is_dict: + data__packagedir_keys = set(data__packagedir.keys()) + for data__packagedir_key, data__packagedir_val in data__packagedir.items(): + if REGEX_PATTERNS['^.*$'].search(data__packagedir_key): + if data__packagedir_key in data__packagedir_keys: + data__packagedir_keys.remove(data__packagedir_key) + if not isinstance(data__packagedir_val, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".package-dir.{data__packagedir_key}".format(**locals()) + " must be string", value=data__packagedir_val, name="" + (name_prefix or "data") + ".package-dir.{data__packagedir_key}".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if data__packagedir_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".package-dir must not contain "+str(data__packagedir_keys)+" properties", value=data__packagedir, name="" + (name_prefix or "data") + ".package-dir", definition={'$$description': [':class:`dict`-like structure mapping from package names to directories where their', 'code can be found.', 'The empty string (as key) means that all packages are contained inside', 'the given directory will be included in the distribution.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'const': ''}, {'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}]}, 'patternProperties': {'^.*$': {'type': 'string'}}}, rule='additionalProperties') + data__packagedir_len = len(data__packagedir) + if data__packagedir_len != 0: + data__packagedir_property_names = True + for data__packagedir_key in data__packagedir: + try: + data__packagedir_key_any_of_count3 = 0 + if not data__packagedir_key_any_of_count3: + try: + if data__packagedir_key != "": + raise JsonSchemaValueException("" + (name_prefix or "data") + ".package-dir must be same as const definition: ", value=data__packagedir_key, name="" + (name_prefix or "data") + ".package-dir", definition={'const': ''}, rule='const') + data__packagedir_key_any_of_count3 += 1 + except JsonSchemaValueException: pass + if not data__packagedir_key_any_of_count3: + try: + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_package_name(data__packagedir_key, custom_formats, (name_prefix or "data") + ".package-dir") + data__packagedir_key_any_of_count3 += 1 + except JsonSchemaValueException: pass + if not data__packagedir_key_any_of_count3: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".package-dir cannot be validated by any definition", value=data__packagedir_key, name="" + (name_prefix or "data") + ".package-dir", definition={'anyOf': [{'const': ''}, {'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}]}, rule='anyOf') + except JsonSchemaValueException: + data__packagedir_property_names = False + if not data__packagedir_property_names: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".package-dir must be named by propertyName definition", value=data__packagedir, name="" + (name_prefix or "data") + ".package-dir", definition={'$$description': [':class:`dict`-like structure mapping from package names to directories where their', 'code can be found.', 'The empty string (as key) means that all packages are contained inside', 'the given directory will be included in the distribution.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'const': ''}, {'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}]}, 'patternProperties': {'^.*$': {'type': 'string'}}}, rule='propertyNames') + if "package-data" in data_keys: + data_keys.remove("package-data") + data__packagedata = data["package-data"] + if not isinstance(data__packagedata, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".package-data must be object", value=data__packagedata, name="" + (name_prefix or "data") + ".package-data", definition={'$$description': ['Mapping from package names to lists of glob patterns.', 'Usually this option is not needed when using ``include-package-data = true``', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, {'const': '*'}]}, 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, rule='type') + data__packagedata_is_dict = isinstance(data__packagedata, dict) + if data__packagedata_is_dict: + data__packagedata_keys = set(data__packagedata.keys()) + for data__packagedata_key, data__packagedata_val in data__packagedata.items(): + if REGEX_PATTERNS['^.*$'].search(data__packagedata_key): + if data__packagedata_key in data__packagedata_keys: + data__packagedata_keys.remove(data__packagedata_key) + if not isinstance(data__packagedata_val, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".package-data.{data__packagedata_key}".format(**locals()) + " must be array", value=data__packagedata_val, name="" + (name_prefix or "data") + ".package-data.{data__packagedata_key}".format(**locals()) + "", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__packagedata_val_is_list = isinstance(data__packagedata_val, (list, tuple)) + if data__packagedata_val_is_list: + data__packagedata_val_len = len(data__packagedata_val) + for data__packagedata_val_x, data__packagedata_val_item in enumerate(data__packagedata_val): + if not isinstance(data__packagedata_val_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".package-data.{data__packagedata_key}[{data__packagedata_val_x}]".format(**locals()) + " must be string", value=data__packagedata_val_item, name="" + (name_prefix or "data") + ".package-data.{data__packagedata_key}[{data__packagedata_val_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if data__packagedata_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".package-data must not contain "+str(data__packagedata_keys)+" properties", value=data__packagedata, name="" + (name_prefix or "data") + ".package-data", definition={'$$description': ['Mapping from package names to lists of glob patterns.', 'Usually this option is not needed when using ``include-package-data = true``', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, {'const': '*'}]}, 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, rule='additionalProperties') + data__packagedata_len = len(data__packagedata) + if data__packagedata_len != 0: + data__packagedata_property_names = True + for data__packagedata_key in data__packagedata: + try: + data__packagedata_key_any_of_count4 = 0 + if not data__packagedata_key_any_of_count4: + try: + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_package_name(data__packagedata_key, custom_formats, (name_prefix or "data") + ".package-data") + data__packagedata_key_any_of_count4 += 1 + except JsonSchemaValueException: pass + if not data__packagedata_key_any_of_count4: + try: + if data__packagedata_key != "*": + raise JsonSchemaValueException("" + (name_prefix or "data") + ".package-data must be same as const definition: *", value=data__packagedata_key, name="" + (name_prefix or "data") + ".package-data", definition={'const': '*'}, rule='const') + data__packagedata_key_any_of_count4 += 1 + except JsonSchemaValueException: pass + if not data__packagedata_key_any_of_count4: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".package-data cannot be validated by any definition", value=data__packagedata_key, name="" + (name_prefix or "data") + ".package-data", definition={'anyOf': [{'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, {'const': '*'}]}, rule='anyOf') + except JsonSchemaValueException: + data__packagedata_property_names = False + if not data__packagedata_property_names: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".package-data must be named by propertyName definition", value=data__packagedata, name="" + (name_prefix or "data") + ".package-data", definition={'$$description': ['Mapping from package names to lists of glob patterns.', 'Usually this option is not needed when using ``include-package-data = true``', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, {'const': '*'}]}, 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, rule='propertyNames') + if "include-package-data" in data_keys: + data_keys.remove("include-package-data") + data__includepackagedata = data["include-package-data"] + if not isinstance(data__includepackagedata, (bool)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".include-package-data must be boolean", value=data__includepackagedata, name="" + (name_prefix or "data") + ".include-package-data", definition={'$$description': ['Automatically include any data files inside the package directories', 'that are specified by ``MANIFEST.in``', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'boolean'}, rule='type') + if "exclude-package-data" in data_keys: + data_keys.remove("exclude-package-data") + data__excludepackagedata = data["exclude-package-data"] + if not isinstance(data__excludepackagedata, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".exclude-package-data must be object", value=data__excludepackagedata, name="" + (name_prefix or "data") + ".exclude-package-data", definition={'$$description': ['Mapping from package names to lists of glob patterns that should be excluded', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, {'const': '*'}]}, 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, rule='type') + data__excludepackagedata_is_dict = isinstance(data__excludepackagedata, dict) + if data__excludepackagedata_is_dict: + data__excludepackagedata_keys = set(data__excludepackagedata.keys()) + for data__excludepackagedata_key, data__excludepackagedata_val in data__excludepackagedata.items(): + if REGEX_PATTERNS['^.*$'].search(data__excludepackagedata_key): + if data__excludepackagedata_key in data__excludepackagedata_keys: + data__excludepackagedata_keys.remove(data__excludepackagedata_key) + if not isinstance(data__excludepackagedata_val, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".exclude-package-data.{data__excludepackagedata_key}".format(**locals()) + " must be array", value=data__excludepackagedata_val, name="" + (name_prefix or "data") + ".exclude-package-data.{data__excludepackagedata_key}".format(**locals()) + "", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__excludepackagedata_val_is_list = isinstance(data__excludepackagedata_val, (list, tuple)) + if data__excludepackagedata_val_is_list: + data__excludepackagedata_val_len = len(data__excludepackagedata_val) + for data__excludepackagedata_val_x, data__excludepackagedata_val_item in enumerate(data__excludepackagedata_val): + if not isinstance(data__excludepackagedata_val_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".exclude-package-data.{data__excludepackagedata_key}[{data__excludepackagedata_val_x}]".format(**locals()) + " must be string", value=data__excludepackagedata_val_item, name="" + (name_prefix or "data") + ".exclude-package-data.{data__excludepackagedata_key}[{data__excludepackagedata_val_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if data__excludepackagedata_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".exclude-package-data must not contain "+str(data__excludepackagedata_keys)+" properties", value=data__excludepackagedata, name="" + (name_prefix or "data") + ".exclude-package-data", definition={'$$description': ['Mapping from package names to lists of glob patterns that should be excluded', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, {'const': '*'}]}, 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, rule='additionalProperties') + data__excludepackagedata_len = len(data__excludepackagedata) + if data__excludepackagedata_len != 0: + data__excludepackagedata_property_names = True + for data__excludepackagedata_key in data__excludepackagedata: + try: + data__excludepackagedata_key_any_of_count5 = 0 + if not data__excludepackagedata_key_any_of_count5: + try: + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_package_name(data__excludepackagedata_key, custom_formats, (name_prefix or "data") + ".exclude-package-data") + data__excludepackagedata_key_any_of_count5 += 1 + except JsonSchemaValueException: pass + if not data__excludepackagedata_key_any_of_count5: + try: + if data__excludepackagedata_key != "*": + raise JsonSchemaValueException("" + (name_prefix or "data") + ".exclude-package-data must be same as const definition: *", value=data__excludepackagedata_key, name="" + (name_prefix or "data") + ".exclude-package-data", definition={'const': '*'}, rule='const') + data__excludepackagedata_key_any_of_count5 += 1 + except JsonSchemaValueException: pass + if not data__excludepackagedata_key_any_of_count5: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".exclude-package-data cannot be validated by any definition", value=data__excludepackagedata_key, name="" + (name_prefix or "data") + ".exclude-package-data", definition={'anyOf': [{'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, {'const': '*'}]}, rule='anyOf') + except JsonSchemaValueException: + data__excludepackagedata_property_names = False + if not data__excludepackagedata_property_names: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".exclude-package-data must be named by propertyName definition", value=data__excludepackagedata, name="" + (name_prefix or "data") + ".exclude-package-data", definition={'$$description': ['Mapping from package names to lists of glob patterns that should be excluded', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, {'const': '*'}]}, 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, rule='propertyNames') + if "namespace-packages" in data_keys: + data_keys.remove("namespace-packages") + data__namespacepackages = data["namespace-packages"] + if not isinstance(data__namespacepackages, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".namespace-packages must be array", value=data__namespacepackages, name="" + (name_prefix or "data") + ".namespace-packages", definition={'type': 'array', 'items': {'type': 'string', 'format': 'python-module-name-relaxed'}, '$comment': 'https://setuptools.pypa.io/en/latest/userguide/package_discovery.html', 'description': '**DEPRECATED**: use implicit namespaces instead (:pep:`420`).'}, rule='type') + data__namespacepackages_is_list = isinstance(data__namespacepackages, (list, tuple)) + if data__namespacepackages_is_list: + data__namespacepackages_len = len(data__namespacepackages) + for data__namespacepackages_x, data__namespacepackages_item in enumerate(data__namespacepackages): + if not isinstance(data__namespacepackages_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".namespace-packages[{data__namespacepackages_x}]".format(**locals()) + " must be string", value=data__namespacepackages_item, name="" + (name_prefix or "data") + ".namespace-packages[{data__namespacepackages_x}]".format(**locals()) + "", definition={'type': 'string', 'format': 'python-module-name-relaxed'}, rule='type') + if isinstance(data__namespacepackages_item, str): + if not custom_formats["python-module-name-relaxed"](data__namespacepackages_item): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".namespace-packages[{data__namespacepackages_x}]".format(**locals()) + " must be python-module-name-relaxed", value=data__namespacepackages_item, name="" + (name_prefix or "data") + ".namespace-packages[{data__namespacepackages_x}]".format(**locals()) + "", definition={'type': 'string', 'format': 'python-module-name-relaxed'}, rule='format') + if "py-modules" in data_keys: + data_keys.remove("py-modules") + data__pymodules = data["py-modules"] + if not isinstance(data__pymodules, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".py-modules must be array", value=data__pymodules, name="" + (name_prefix or "data") + ".py-modules", definition={'description': 'Modules that setuptools will manipulate', 'type': 'array', 'items': {'type': 'string', 'format': 'python-module-name-relaxed'}, '$comment': 'TODO: clarify the relationship with ``packages``'}, rule='type') + data__pymodules_is_list = isinstance(data__pymodules, (list, tuple)) + if data__pymodules_is_list: + data__pymodules_len = len(data__pymodules) + for data__pymodules_x, data__pymodules_item in enumerate(data__pymodules): + if not isinstance(data__pymodules_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".py-modules[{data__pymodules_x}]".format(**locals()) + " must be string", value=data__pymodules_item, name="" + (name_prefix or "data") + ".py-modules[{data__pymodules_x}]".format(**locals()) + "", definition={'type': 'string', 'format': 'python-module-name-relaxed'}, rule='type') + if isinstance(data__pymodules_item, str): + if not custom_formats["python-module-name-relaxed"](data__pymodules_item): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".py-modules[{data__pymodules_x}]".format(**locals()) + " must be python-module-name-relaxed", value=data__pymodules_item, name="" + (name_prefix or "data") + ".py-modules[{data__pymodules_x}]".format(**locals()) + "", definition={'type': 'string', 'format': 'python-module-name-relaxed'}, rule='format') + if "ext-modules" in data_keys: + data_keys.remove("ext-modules") + data__extmodules = data["ext-modules"] + if not isinstance(data__extmodules, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".ext-modules must be array", value=data__extmodules, name="" + (name_prefix or "data") + ".ext-modules", definition={'description': 'Extension modules to be compiled by setuptools', 'type': 'array', 'items': {'$id': '#/definitions/ext-module', 'title': 'Extension module', 'description': 'Parameters to construct a :class:`setuptools.Extension` object', 'type': 'object', 'required': ['name', 'sources'], 'additionalProperties': False, 'properties': {'name': {'type': 'string', 'format': 'python-module-name-relaxed'}, 'sources': {'type': 'array', 'items': {'type': 'string'}}, 'include-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'define-macros': {'type': 'array', 'items': {'type': 'array', 'items': [{'description': 'macro name', 'type': 'string'}, {'description': 'macro value', 'oneOf': [{'type': 'string'}, {'type': 'null'}]}], 'additionalItems': False}}, 'undef-macros': {'type': 'array', 'items': {'type': 'string'}}, 'library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'libraries': {'type': 'array', 'items': {'type': 'string'}}, 'runtime-library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'extra-objects': {'type': 'array', 'items': {'type': 'string'}}, 'extra-compile-args': {'type': 'array', 'items': {'type': 'string'}}, 'extra-link-args': {'type': 'array', 'items': {'type': 'string'}}, 'export-symbols': {'type': 'array', 'items': {'type': 'string'}}, 'swig-opts': {'type': 'array', 'items': {'type': 'string'}}, 'depends': {'type': 'array', 'items': {'type': 'string'}}, 'language': {'type': 'string'}, 'optional': {'type': 'boolean'}, 'py-limited-api': {'type': 'boolean'}}}}, rule='type') + data__extmodules_is_list = isinstance(data__extmodules, (list, tuple)) + if data__extmodules_is_list: + data__extmodules_len = len(data__extmodules) + for data__extmodules_x, data__extmodules_item in enumerate(data__extmodules): + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_ext_module(data__extmodules_item, custom_formats, (name_prefix or "data") + ".ext-modules[{data__extmodules_x}]".format(**locals())) + if "data-files" in data_keys: + data_keys.remove("data-files") + data__datafiles = data["data-files"] + if not isinstance(data__datafiles, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".data-files must be object", value=data__datafiles, name="" + (name_prefix or "data") + ".data-files", definition={'$$description': ['``dict``-like structure where each key represents a directory and', 'the value is a list of glob patterns that should be installed in them.', '**DISCOURAGED**: please notice this might not work as expected with wheels.', 'Whenever possible, consider using data files inside the package directories', '(or create a new namespace package that only contains data files).', 'See `data files support', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, rule='type') + data__datafiles_is_dict = isinstance(data__datafiles, dict) + if data__datafiles_is_dict: + data__datafiles_keys = set(data__datafiles.keys()) + for data__datafiles_key, data__datafiles_val in data__datafiles.items(): + if REGEX_PATTERNS['^.*$'].search(data__datafiles_key): + if data__datafiles_key in data__datafiles_keys: + data__datafiles_keys.remove(data__datafiles_key) + if not isinstance(data__datafiles_val, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".data-files.{data__datafiles_key}".format(**locals()) + " must be array", value=data__datafiles_val, name="" + (name_prefix or "data") + ".data-files.{data__datafiles_key}".format(**locals()) + "", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__datafiles_val_is_list = isinstance(data__datafiles_val, (list, tuple)) + if data__datafiles_val_is_list: + data__datafiles_val_len = len(data__datafiles_val) + for data__datafiles_val_x, data__datafiles_val_item in enumerate(data__datafiles_val): + if not isinstance(data__datafiles_val_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".data-files.{data__datafiles_key}[{data__datafiles_val_x}]".format(**locals()) + " must be string", value=data__datafiles_val_item, name="" + (name_prefix or "data") + ".data-files.{data__datafiles_key}[{data__datafiles_val_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "cmdclass" in data_keys: + data_keys.remove("cmdclass") + data__cmdclass = data["cmdclass"] + if not isinstance(data__cmdclass, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".cmdclass must be object", value=data__cmdclass, name="" + (name_prefix or "data") + ".cmdclass", definition={'$$description': ['Mapping of distutils-style command names to ``setuptools.Command`` subclasses', 'which in turn should be represented by strings with a qualified class name', '(i.e., "dotted" form with module), e.g.::\n\n', ' cmdclass = {mycmd = "pkg.subpkg.module.CommandClass"}\n\n', 'The command class should be a directly defined at the top-level of the', 'containing module (no class nesting).'], 'type': 'object', 'patternProperties': {'^.*$': {'type': 'string', 'format': 'python-qualified-identifier'}}}, rule='type') + data__cmdclass_is_dict = isinstance(data__cmdclass, dict) + if data__cmdclass_is_dict: + data__cmdclass_keys = set(data__cmdclass.keys()) + for data__cmdclass_key, data__cmdclass_val in data__cmdclass.items(): + if REGEX_PATTERNS['^.*$'].search(data__cmdclass_key): + if data__cmdclass_key in data__cmdclass_keys: + data__cmdclass_keys.remove(data__cmdclass_key) + if not isinstance(data__cmdclass_val, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".cmdclass.{data__cmdclass_key}".format(**locals()) + " must be string", value=data__cmdclass_val, name="" + (name_prefix or "data") + ".cmdclass.{data__cmdclass_key}".format(**locals()) + "", definition={'type': 'string', 'format': 'python-qualified-identifier'}, rule='type') + if isinstance(data__cmdclass_val, str): + if not custom_formats["python-qualified-identifier"](data__cmdclass_val): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".cmdclass.{data__cmdclass_key}".format(**locals()) + " must be python-qualified-identifier", value=data__cmdclass_val, name="" + (name_prefix or "data") + ".cmdclass.{data__cmdclass_key}".format(**locals()) + "", definition={'type': 'string', 'format': 'python-qualified-identifier'}, rule='format') + if "license-files" in data_keys: + data_keys.remove("license-files") + data__licensefiles = data["license-files"] + if not isinstance(data__licensefiles, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".license-files must be array", value=data__licensefiles, name="" + (name_prefix or "data") + ".license-files", definition={'type': 'array', 'items': {'type': 'string'}, '$$description': ['**PROVISIONAL**: list of glob patterns for all license files being distributed.', '(likely to become standard with :pep:`639`).', "By default: ``['LICEN[CS]E*', 'COPYING*', 'NOTICE*', 'AUTHORS*']``"], '$comment': 'TODO: revise if PEP 639 is accepted. Probably ``project.license-files``?'}, rule='type') + data__licensefiles_is_list = isinstance(data__licensefiles, (list, tuple)) + if data__licensefiles_is_list: + data__licensefiles_len = len(data__licensefiles) + for data__licensefiles_x, data__licensefiles_item in enumerate(data__licensefiles): + if not isinstance(data__licensefiles_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".license-files[{data__licensefiles_x}]".format(**locals()) + " must be string", value=data__licensefiles_item, name="" + (name_prefix or "data") + ".license-files[{data__licensefiles_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "dynamic" in data_keys: + data_keys.remove("dynamic") + data__dynamic = data["dynamic"] + if not isinstance(data__dynamic, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic must be object", value=data__dynamic, name="" + (name_prefix or "data") + ".dynamic", definition={'type': 'object', 'description': 'Instructions for loading :pep:`621`-related metadata dynamically', 'additionalProperties': False, 'properties': {'version': {'$$description': ['A version dynamically loaded via either the ``attr:`` or ``file:``', 'directives. Please make sure the given file or attribute respects :pep:`440`.', 'Also ensure to set ``project.dynamic`` accordingly.'], 'oneOf': [{'title': "'attr:' directive", '$id': '#/definitions/attr-directive', '$$description': ['Value is read from a module attribute. Supports callables and iterables;', 'unsupported types are cast via ``str()``'], 'type': 'object', 'additionalProperties': False, 'properties': {'attr': {'type': 'string', 'format': 'python-qualified-identifier'}}, 'required': ['attr']}, {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}]}, 'classifiers': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'description': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'entry-points': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'dependencies': {'title': "'file:' directive for dependencies", 'allOf': [{'$$description': ['**BETA**: subset of the ``requirements.txt`` format', 'without ``pip`` flags and options', '(one :pep:`508`-compliant string per line,', 'lines that are blank or start with ``#`` are excluded).', 'See `dynamic metadata', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata>`_.']}, {'$ref': '#/definitions/file-directive'}]}, 'optional-dependencies': {'type': 'object', 'propertyNames': {'type': 'string', 'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'.+': {'title': "'file:' directive for dependencies", 'allOf': [{'$$description': ['**BETA**: subset of the ``requirements.txt`` format', 'without ``pip`` flags and options', '(one :pep:`508`-compliant string per line,', 'lines that are blank or start with ``#`` are excluded).', 'See `dynamic metadata', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata>`_.']}, {'$ref': '#/definitions/file-directive'}]}}}, 'readme': {'type': 'object', 'anyOf': [{'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, {'type': 'object', 'properties': {'content-type': {'type': 'string'}, 'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'additionalProperties': False}], 'required': ['file']}}}, rule='type') + data__dynamic_is_dict = isinstance(data__dynamic, dict) + if data__dynamic_is_dict: + data__dynamic_keys = set(data__dynamic.keys()) + if "version" in data__dynamic_keys: + data__dynamic_keys.remove("version") + data__dynamic__version = data__dynamic["version"] + data__dynamic__version_one_of_count6 = 0 + if data__dynamic__version_one_of_count6 < 2: + try: + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_attr_directive(data__dynamic__version, custom_formats, (name_prefix or "data") + ".dynamic.version") + data__dynamic__version_one_of_count6 += 1 + except JsonSchemaValueException: pass + if data__dynamic__version_one_of_count6 < 2: + try: + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_file_directive(data__dynamic__version, custom_formats, (name_prefix or "data") + ".dynamic.version") + data__dynamic__version_one_of_count6 += 1 + except JsonSchemaValueException: pass + if data__dynamic__version_one_of_count6 != 1: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic.version must be valid exactly by one definition" + (" (" + str(data__dynamic__version_one_of_count6) + " matches found)"), value=data__dynamic__version, name="" + (name_prefix or "data") + ".dynamic.version", definition={'$$description': ['A version dynamically loaded via either the ``attr:`` or ``file:``', 'directives. Please make sure the given file or attribute respects :pep:`440`.', 'Also ensure to set ``project.dynamic`` accordingly.'], 'oneOf': [{'title': "'attr:' directive", '$id': '#/definitions/attr-directive', '$$description': ['Value is read from a module attribute. Supports callables and iterables;', 'unsupported types are cast via ``str()``'], 'type': 'object', 'additionalProperties': False, 'properties': {'attr': {'type': 'string', 'format': 'python-qualified-identifier'}}, 'required': ['attr']}, {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}]}, rule='oneOf') + if "classifiers" in data__dynamic_keys: + data__dynamic_keys.remove("classifiers") + data__dynamic__classifiers = data__dynamic["classifiers"] + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_file_directive(data__dynamic__classifiers, custom_formats, (name_prefix or "data") + ".dynamic.classifiers") + if "description" in data__dynamic_keys: + data__dynamic_keys.remove("description") + data__dynamic__description = data__dynamic["description"] + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_file_directive(data__dynamic__description, custom_formats, (name_prefix or "data") + ".dynamic.description") + if "entry-points" in data__dynamic_keys: + data__dynamic_keys.remove("entry-points") + data__dynamic__entrypoints = data__dynamic["entry-points"] + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_file_directive(data__dynamic__entrypoints, custom_formats, (name_prefix or "data") + ".dynamic.entry-points") + if "dependencies" in data__dynamic_keys: + data__dynamic_keys.remove("dependencies") + data__dynamic__dependencies = data__dynamic["dependencies"] + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_file_directive_for_dependencies(data__dynamic__dependencies, custom_formats, (name_prefix or "data") + ".dynamic.dependencies") + if "optional-dependencies" in data__dynamic_keys: + data__dynamic_keys.remove("optional-dependencies") + data__dynamic__optionaldependencies = data__dynamic["optional-dependencies"] + if not isinstance(data__dynamic__optionaldependencies, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic.optional-dependencies must be object", value=data__dynamic__optionaldependencies, name="" + (name_prefix or "data") + ".dynamic.optional-dependencies", definition={'type': 'object', 'propertyNames': {'type': 'string', 'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'.+': {'title': "'file:' directive for dependencies", 'allOf': [{'$$description': ['**BETA**: subset of the ``requirements.txt`` format', 'without ``pip`` flags and options', '(one :pep:`508`-compliant string per line,', 'lines that are blank or start with ``#`` are excluded).', 'See `dynamic metadata', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata>`_.']}, {'$ref': '#/definitions/file-directive'}]}}}, rule='type') + data__dynamic__optionaldependencies_is_dict = isinstance(data__dynamic__optionaldependencies, dict) + if data__dynamic__optionaldependencies_is_dict: + data__dynamic__optionaldependencies_keys = set(data__dynamic__optionaldependencies.keys()) + for data__dynamic__optionaldependencies_key, data__dynamic__optionaldependencies_val in data__dynamic__optionaldependencies.items(): + if REGEX_PATTERNS['.+'].search(data__dynamic__optionaldependencies_key): + if data__dynamic__optionaldependencies_key in data__dynamic__optionaldependencies_keys: + data__dynamic__optionaldependencies_keys.remove(data__dynamic__optionaldependencies_key) + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_file_directive_for_dependencies(data__dynamic__optionaldependencies_val, custom_formats, (name_prefix or "data") + ".dynamic.optional-dependencies.{data__dynamic__optionaldependencies_key}".format(**locals())) + if data__dynamic__optionaldependencies_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic.optional-dependencies must not contain "+str(data__dynamic__optionaldependencies_keys)+" properties", value=data__dynamic__optionaldependencies, name="" + (name_prefix or "data") + ".dynamic.optional-dependencies", definition={'type': 'object', 'propertyNames': {'type': 'string', 'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'.+': {'title': "'file:' directive for dependencies", 'allOf': [{'$$description': ['**BETA**: subset of the ``requirements.txt`` format', 'without ``pip`` flags and options', '(one :pep:`508`-compliant string per line,', 'lines that are blank or start with ``#`` are excluded).', 'See `dynamic metadata', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata>`_.']}, {'$ref': '#/definitions/file-directive'}]}}}, rule='additionalProperties') + data__dynamic__optionaldependencies_len = len(data__dynamic__optionaldependencies) + if data__dynamic__optionaldependencies_len != 0: + data__dynamic__optionaldependencies_property_names = True + for data__dynamic__optionaldependencies_key in data__dynamic__optionaldependencies: + try: + if not isinstance(data__dynamic__optionaldependencies_key, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic.optional-dependencies must be string", value=data__dynamic__optionaldependencies_key, name="" + (name_prefix or "data") + ".dynamic.optional-dependencies", definition={'type': 'string', 'format': 'pep508-identifier'}, rule='type') + if isinstance(data__dynamic__optionaldependencies_key, str): + if not custom_formats["pep508-identifier"](data__dynamic__optionaldependencies_key): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic.optional-dependencies must be pep508-identifier", value=data__dynamic__optionaldependencies_key, name="" + (name_prefix or "data") + ".dynamic.optional-dependencies", definition={'type': 'string', 'format': 'pep508-identifier'}, rule='format') + except JsonSchemaValueException: + data__dynamic__optionaldependencies_property_names = False + if not data__dynamic__optionaldependencies_property_names: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic.optional-dependencies must be named by propertyName definition", value=data__dynamic__optionaldependencies, name="" + (name_prefix or "data") + ".dynamic.optional-dependencies", definition={'type': 'object', 'propertyNames': {'type': 'string', 'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'.+': {'title': "'file:' directive for dependencies", 'allOf': [{'$$description': ['**BETA**: subset of the ``requirements.txt`` format', 'without ``pip`` flags and options', '(one :pep:`508`-compliant string per line,', 'lines that are blank or start with ``#`` are excluded).', 'See `dynamic metadata', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata>`_.']}, {'$ref': '#/definitions/file-directive'}]}}}, rule='propertyNames') + if "readme" in data__dynamic_keys: + data__dynamic_keys.remove("readme") + data__dynamic__readme = data__dynamic["readme"] + if not isinstance(data__dynamic__readme, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic.readme must be object", value=data__dynamic__readme, name="" + (name_prefix or "data") + ".dynamic.readme", definition={'type': 'object', 'anyOf': [{'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, {'type': 'object', 'properties': {'content-type': {'type': 'string'}, 'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'additionalProperties': False}], 'required': ['file']}, rule='type') + data__dynamic__readme_any_of_count7 = 0 + if not data__dynamic__readme_any_of_count7: + try: + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_file_directive(data__dynamic__readme, custom_formats, (name_prefix or "data") + ".dynamic.readme") + data__dynamic__readme_any_of_count7 += 1 + except JsonSchemaValueException: pass + if not data__dynamic__readme_any_of_count7: + try: + if not isinstance(data__dynamic__readme, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic.readme must be object", value=data__dynamic__readme, name="" + (name_prefix or "data") + ".dynamic.readme", definition={'type': 'object', 'properties': {'content-type': {'type': 'string'}, 'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'additionalProperties': False}, rule='type') + data__dynamic__readme_is_dict = isinstance(data__dynamic__readme, dict) + if data__dynamic__readme_is_dict: + data__dynamic__readme_keys = set(data__dynamic__readme.keys()) + if "content-type" in data__dynamic__readme_keys: + data__dynamic__readme_keys.remove("content-type") + data__dynamic__readme__contenttype = data__dynamic__readme["content-type"] + if not isinstance(data__dynamic__readme__contenttype, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic.readme.content-type must be string", value=data__dynamic__readme__contenttype, name="" + (name_prefix or "data") + ".dynamic.readme.content-type", definition={'type': 'string'}, rule='type') + if "file" in data__dynamic__readme_keys: + data__dynamic__readme_keys.remove("file") + data__dynamic__readme__file = data__dynamic__readme["file"] + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_file_directive_properties_file(data__dynamic__readme__file, custom_formats, (name_prefix or "data") + ".dynamic.readme.file") + if data__dynamic__readme_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic.readme must not contain "+str(data__dynamic__readme_keys)+" properties", value=data__dynamic__readme, name="" + (name_prefix or "data") + ".dynamic.readme", definition={'type': 'object', 'properties': {'content-type': {'type': 'string'}, 'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'additionalProperties': False}, rule='additionalProperties') + data__dynamic__readme_any_of_count7 += 1 + except JsonSchemaValueException: pass + if not data__dynamic__readme_any_of_count7: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic.readme cannot be validated by any definition", value=data__dynamic__readme, name="" + (name_prefix or "data") + ".dynamic.readme", definition={'type': 'object', 'anyOf': [{'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, {'type': 'object', 'properties': {'content-type': {'type': 'string'}, 'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'additionalProperties': False}], 'required': ['file']}, rule='anyOf') + data__dynamic__readme_is_dict = isinstance(data__dynamic__readme, dict) + if data__dynamic__readme_is_dict: + data__dynamic__readme__missing_keys = set(['file']) - data__dynamic__readme.keys() + if data__dynamic__readme__missing_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic.readme must contain " + (str(sorted(data__dynamic__readme__missing_keys)) + " properties"), value=data__dynamic__readme, name="" + (name_prefix or "data") + ".dynamic.readme", definition={'type': 'object', 'anyOf': [{'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, {'type': 'object', 'properties': {'content-type': {'type': 'string'}, 'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'additionalProperties': False}], 'required': ['file']}, rule='required') + if data__dynamic_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic must not contain "+str(data__dynamic_keys)+" properties", value=data__dynamic, name="" + (name_prefix or "data") + ".dynamic", definition={'type': 'object', 'description': 'Instructions for loading :pep:`621`-related metadata dynamically', 'additionalProperties': False, 'properties': {'version': {'$$description': ['A version dynamically loaded via either the ``attr:`` or ``file:``', 'directives. Please make sure the given file or attribute respects :pep:`440`.', 'Also ensure to set ``project.dynamic`` accordingly.'], 'oneOf': [{'title': "'attr:' directive", '$id': '#/definitions/attr-directive', '$$description': ['Value is read from a module attribute. Supports callables and iterables;', 'unsupported types are cast via ``str()``'], 'type': 'object', 'additionalProperties': False, 'properties': {'attr': {'type': 'string', 'format': 'python-qualified-identifier'}}, 'required': ['attr']}, {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}]}, 'classifiers': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'description': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'entry-points': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'dependencies': {'title': "'file:' directive for dependencies", 'allOf': [{'$$description': ['**BETA**: subset of the ``requirements.txt`` format', 'without ``pip`` flags and options', '(one :pep:`508`-compliant string per line,', 'lines that are blank or start with ``#`` are excluded).', 'See `dynamic metadata', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata>`_.']}, {'$ref': '#/definitions/file-directive'}]}, 'optional-dependencies': {'type': 'object', 'propertyNames': {'type': 'string', 'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'.+': {'title': "'file:' directive for dependencies", 'allOf': [{'$$description': ['**BETA**: subset of the ``requirements.txt`` format', 'without ``pip`` flags and options', '(one :pep:`508`-compliant string per line,', 'lines that are blank or start with ``#`` are excluded).', 'See `dynamic metadata', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata>`_.']}, {'$ref': '#/definitions/file-directive'}]}}}, 'readme': {'type': 'object', 'anyOf': [{'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, {'type': 'object', 'properties': {'content-type': {'type': 'string'}, 'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'additionalProperties': False}], 'required': ['file']}}}, rule='additionalProperties') + if data_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must not contain "+str(data_keys)+" properties", value=data, name="" + (name_prefix or "data") + "", definition={'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html', 'title': '``tool.setuptools`` table', '$$description': ['``setuptools``-specific configurations that can be set by users that require', 'customization.', 'These configurations are completely optional and probably can be skipped when', 'creating simple packages. They are equivalent to some of the `Keywords', '<https://setuptools.pypa.io/en/latest/references/keywords.html>`_', 'used by the ``setup.py`` file, and can be set via the ``tool.setuptools`` table.', 'It considers only ``setuptools`` `parameters', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#setuptools-specific-configuration>`_', 'that are not covered by :pep:`621`; and intentionally excludes ``dependency_links``', 'and ``setup_requires`` (incompatible with modern workflows/standards).'], 'type': 'object', 'additionalProperties': False, 'properties': {'platforms': {'type': 'array', 'items': {'type': 'string'}}, 'provides': {'$$description': ['Package and virtual package names contained within this package', '**(not supported by pip)**'], 'type': 'array', 'items': {'type': 'string', 'format': 'pep508-identifier'}}, 'obsoletes': {'$$description': ['Packages which this package renders obsolete', '**(not supported by pip)**'], 'type': 'array', 'items': {'type': 'string', 'format': 'pep508-identifier'}}, 'zip-safe': {'$$description': ['Whether the project can be safely installed and run from a zip file.', '**OBSOLETE**: only relevant for ``pkg_resources``, ``easy_install`` and', '``setup.py install`` in the context of ``eggs`` (**DEPRECATED**).'], 'type': 'boolean'}, 'script-files': {'$$description': ['Legacy way of defining scripts (entry-points are preferred).', 'Equivalent to the ``script`` keyword in ``setup.py``', '(it was renamed to avoid confusion with entry-point based ``project.scripts``', 'defined in :pep:`621`).', '**DISCOURAGED**: generic script wrappers are tricky and may not work properly.', 'Whenever possible, please use ``project.scripts`` instead.'], 'type': 'array', 'items': {'type': 'string'}, '$comment': 'TODO: is this field deprecated/should be removed?'}, 'eager-resources': {'$$description': ['Resources that should be extracted together, if any of them is needed,', 'or if any C extensions included in the project are imported.', '**OBSOLETE**: only relevant for ``pkg_resources``, ``easy_install`` and', '``setup.py install`` in the context of ``eggs`` (**DEPRECATED**).'], 'type': 'array', 'items': {'type': 'string'}}, 'packages': {'$$description': ['Packages that should be included in the distribution.', 'It can be given either as a list of package identifiers', 'or as a ``dict``-like structure with a single key ``find``', 'which corresponds to a dynamic call to', '``setuptools.config.expand.find_packages`` function.', 'The ``find`` key is associated with a nested ``dict``-like structure that can', 'contain ``where``, ``include``, ``exclude`` and ``namespaces`` keys,', 'mimicking the keyword arguments of the associated function.'], 'oneOf': [{'title': 'Array of Python package identifiers', 'type': 'array', 'items': {'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}}, {'$id': '#/definitions/find-directive', 'title': "'find:' directive", 'type': 'object', 'additionalProperties': False, 'properties': {'find': {'type': 'object', '$$description': ['Dynamic `package discovery', '<https://setuptools.pypa.io/en/latest/userguide/package_discovery.html>`_.'], 'additionalProperties': False, 'properties': {'where': {'description': 'Directories to be searched for packages (Unix-style relative path)', 'type': 'array', 'items': {'type': 'string'}}, 'exclude': {'type': 'array', '$$description': ['Exclude packages that match the values listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'include': {'type': 'array', '$$description': ['Restrict the found packages to just the ones listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'namespaces': {'type': 'boolean', '$$description': ['When ``True``, directories without a ``__init__.py`` file will also', 'be scanned for :pep:`420`-style implicit namespaces']}}}}}]}, 'package-dir': {'$$description': [':class:`dict`-like structure mapping from package names to directories where their', 'code can be found.', 'The empty string (as key) means that all packages are contained inside', 'the given directory will be included in the distribution.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'const': ''}, {'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}]}, 'patternProperties': {'^.*$': {'type': 'string'}}}, 'package-data': {'$$description': ['Mapping from package names to lists of glob patterns.', 'Usually this option is not needed when using ``include-package-data = true``', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, {'const': '*'}]}, 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, 'include-package-data': {'$$description': ['Automatically include any data files inside the package directories', 'that are specified by ``MANIFEST.in``', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'boolean'}, 'exclude-package-data': {'$$description': ['Mapping from package names to lists of glob patterns that should be excluded', 'For more information on how to include data files, check ``setuptools`` `docs', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'additionalProperties': False, 'propertyNames': {'anyOf': [{'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, {'const': '*'}]}, 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, 'namespace-packages': {'type': 'array', 'items': {'type': 'string', 'format': 'python-module-name-relaxed'}, '$comment': 'https://setuptools.pypa.io/en/latest/userguide/package_discovery.html', 'description': '**DEPRECATED**: use implicit namespaces instead (:pep:`420`).'}, 'py-modules': {'description': 'Modules that setuptools will manipulate', 'type': 'array', 'items': {'type': 'string', 'format': 'python-module-name-relaxed'}, '$comment': 'TODO: clarify the relationship with ``packages``'}, 'ext-modules': {'description': 'Extension modules to be compiled by setuptools', 'type': 'array', 'items': {'$id': '#/definitions/ext-module', 'title': 'Extension module', 'description': 'Parameters to construct a :class:`setuptools.Extension` object', 'type': 'object', 'required': ['name', 'sources'], 'additionalProperties': False, 'properties': {'name': {'type': 'string', 'format': 'python-module-name-relaxed'}, 'sources': {'type': 'array', 'items': {'type': 'string'}}, 'include-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'define-macros': {'type': 'array', 'items': {'type': 'array', 'items': [{'description': 'macro name', 'type': 'string'}, {'description': 'macro value', 'oneOf': [{'type': 'string'}, {'type': 'null'}]}], 'additionalItems': False}}, 'undef-macros': {'type': 'array', 'items': {'type': 'string'}}, 'library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'libraries': {'type': 'array', 'items': {'type': 'string'}}, 'runtime-library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'extra-objects': {'type': 'array', 'items': {'type': 'string'}}, 'extra-compile-args': {'type': 'array', 'items': {'type': 'string'}}, 'extra-link-args': {'type': 'array', 'items': {'type': 'string'}}, 'export-symbols': {'type': 'array', 'items': {'type': 'string'}}, 'swig-opts': {'type': 'array', 'items': {'type': 'string'}}, 'depends': {'type': 'array', 'items': {'type': 'string'}}, 'language': {'type': 'string'}, 'optional': {'type': 'boolean'}, 'py-limited-api': {'type': 'boolean'}}}}, 'data-files': {'$$description': ['``dict``-like structure where each key represents a directory and', 'the value is a list of glob patterns that should be installed in them.', '**DISCOURAGED**: please notice this might not work as expected with wheels.', 'Whenever possible, consider using data files inside the package directories', '(or create a new namespace package that only contains data files).', 'See `data files support', '<https://setuptools.pypa.io/en/latest/userguide/datafiles.html>`_.'], 'type': 'object', 'patternProperties': {'^.*$': {'type': 'array', 'items': {'type': 'string'}}}}, 'cmdclass': {'$$description': ['Mapping of distutils-style command names to ``setuptools.Command`` subclasses', 'which in turn should be represented by strings with a qualified class name', '(i.e., "dotted" form with module), e.g.::\n\n', ' cmdclass = {mycmd = "pkg.subpkg.module.CommandClass"}\n\n', 'The command class should be a directly defined at the top-level of the', 'containing module (no class nesting).'], 'type': 'object', 'patternProperties': {'^.*$': {'type': 'string', 'format': 'python-qualified-identifier'}}}, 'license-files': {'type': 'array', 'items': {'type': 'string'}, '$$description': ['**PROVISIONAL**: list of glob patterns for all license files being distributed.', '(likely to become standard with :pep:`639`).', "By default: ``['LICEN[CS]E*', 'COPYING*', 'NOTICE*', 'AUTHORS*']``"], '$comment': 'TODO: revise if PEP 639 is accepted. Probably ``project.license-files``?'}, 'dynamic': {'type': 'object', 'description': 'Instructions for loading :pep:`621`-related metadata dynamically', 'additionalProperties': False, 'properties': {'version': {'$$description': ['A version dynamically loaded via either the ``attr:`` or ``file:``', 'directives. Please make sure the given file or attribute respects :pep:`440`.', 'Also ensure to set ``project.dynamic`` accordingly.'], 'oneOf': [{'title': "'attr:' directive", '$id': '#/definitions/attr-directive', '$$description': ['Value is read from a module attribute. Supports callables and iterables;', 'unsupported types are cast via ``str()``'], 'type': 'object', 'additionalProperties': False, 'properties': {'attr': {'type': 'string', 'format': 'python-qualified-identifier'}}, 'required': ['attr']}, {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}]}, 'classifiers': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'description': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'entry-points': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'dependencies': {'title': "'file:' directive for dependencies", 'allOf': [{'$$description': ['**BETA**: subset of the ``requirements.txt`` format', 'without ``pip`` flags and options', '(one :pep:`508`-compliant string per line,', 'lines that are blank or start with ``#`` are excluded).', 'See `dynamic metadata', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata>`_.']}, {'$ref': '#/definitions/file-directive'}]}, 'optional-dependencies': {'type': 'object', 'propertyNames': {'type': 'string', 'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'.+': {'title': "'file:' directive for dependencies", 'allOf': [{'$$description': ['**BETA**: subset of the ``requirements.txt`` format', 'without ``pip`` flags and options', '(one :pep:`508`-compliant string per line,', 'lines that are blank or start with ``#`` are excluded).', 'See `dynamic metadata', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata>`_.']}, {'$ref': '#/definitions/file-directive'}]}}}, 'readme': {'type': 'object', 'anyOf': [{'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, {'type': 'object', 'properties': {'content-type': {'type': 'string'}, 'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'additionalProperties': False}], 'required': ['file']}}}}, 'definitions': {'package-name': {'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, 'ext-module': {'$id': '#/definitions/ext-module', 'title': 'Extension module', 'description': 'Parameters to construct a :class:`setuptools.Extension` object', 'type': 'object', 'required': ['name', 'sources'], 'additionalProperties': False, 'properties': {'name': {'type': 'string', 'format': 'python-module-name-relaxed'}, 'sources': {'type': 'array', 'items': {'type': 'string'}}, 'include-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'define-macros': {'type': 'array', 'items': {'type': 'array', 'items': [{'description': 'macro name', 'type': 'string'}, {'description': 'macro value', 'oneOf': [{'type': 'string'}, {'type': 'null'}]}], 'additionalItems': False}}, 'undef-macros': {'type': 'array', 'items': {'type': 'string'}}, 'library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'libraries': {'type': 'array', 'items': {'type': 'string'}}, 'runtime-library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'extra-objects': {'type': 'array', 'items': {'type': 'string'}}, 'extra-compile-args': {'type': 'array', 'items': {'type': 'string'}}, 'extra-link-args': {'type': 'array', 'items': {'type': 'string'}}, 'export-symbols': {'type': 'array', 'items': {'type': 'string'}}, 'swig-opts': {'type': 'array', 'items': {'type': 'string'}}, 'depends': {'type': 'array', 'items': {'type': 'string'}}, 'language': {'type': 'string'}, 'optional': {'type': 'boolean'}, 'py-limited-api': {'type': 'boolean'}}}, 'file-directive': {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, 'file-directive-for-dependencies': {'title': "'file:' directive for dependencies", 'allOf': [{'$$description': ['**BETA**: subset of the ``requirements.txt`` format', 'without ``pip`` flags and options', '(one :pep:`508`-compliant string per line,', 'lines that are blank or start with ``#`` are excluded).', 'See `dynamic metadata', '<https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata>`_.']}, {'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}]}, 'attr-directive': {'title': "'attr:' directive", '$id': '#/definitions/attr-directive', '$$description': ['Value is read from a module attribute. Supports callables and iterables;', 'unsupported types are cast via ``str()``'], 'type': 'object', 'additionalProperties': False, 'properties': {'attr': {'type': 'string', 'format': 'python-qualified-identifier'}}, 'required': ['attr']}, 'find-directive': {'$id': '#/definitions/find-directive', 'title': "'find:' directive", 'type': 'object', 'additionalProperties': False, 'properties': {'find': {'type': 'object', '$$description': ['Dynamic `package discovery', '<https://setuptools.pypa.io/en/latest/userguide/package_discovery.html>`_.'], 'additionalProperties': False, 'properties': {'where': {'description': 'Directories to be searched for packages (Unix-style relative path)', 'type': 'array', 'items': {'type': 'string'}}, 'exclude': {'type': 'array', '$$description': ['Exclude packages that match the values listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'include': {'type': 'array', '$$description': ['Restrict the found packages to just the ones listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'namespaces': {'type': 'boolean', '$$description': ['When ``True``, directories without a ``__init__.py`` file will also', 'be scanned for :pep:`420`-style implicit namespaces']}}}}}}}, rule='additionalProperties') + return data + +def validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_file_directive_properties_file(data, custom_formats={}, name_prefix=None): + data_one_of_count8 = 0 + if data_one_of_count8 < 2: + try: + if not isinstance(data, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be string", value=data, name="" + (name_prefix or "data") + "", definition={'type': 'string'}, rule='type') + data_one_of_count8 += 1 + except JsonSchemaValueException: pass + if data_one_of_count8 < 2: + try: + if not isinstance(data, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be array", value=data, name="" + (name_prefix or "data") + "", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data_is_list = isinstance(data, (list, tuple)) + if data_is_list: + data_len = len(data) + for data_x, data_item in enumerate(data): + if not isinstance(data_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + "[{data_x}]".format(**locals()) + " must be string", value=data_item, name="" + (name_prefix or "data") + "[{data_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + data_one_of_count8 += 1 + except JsonSchemaValueException: pass + if data_one_of_count8 != 1: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be valid exactly by one definition" + (" (" + str(data_one_of_count8) + " matches found)"), value=data, name="" + (name_prefix or "data") + "", definition={'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}, rule='oneOf') + return data + +def validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_file_directive_for_dependencies(data, custom_formats={}, name_prefix=None): + validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_file_directive(data, custom_formats, (name_prefix or "data") + "") + return data + +def validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_file_directive(data, custom_formats={}, name_prefix=None): + if not isinstance(data, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be object", value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, rule='type') + data_is_dict = isinstance(data, dict) + if data_is_dict: + data__missing_keys = set(['file']) - data.keys() + if data__missing_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must contain " + (str(sorted(data__missing_keys)) + " properties"), value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, rule='required') + data_keys = set(data.keys()) + if "file" in data_keys: + data_keys.remove("file") + data__file = data["file"] + data__file_one_of_count9 = 0 + if data__file_one_of_count9 < 2: + try: + if not isinstance(data__file, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".file must be string", value=data__file, name="" + (name_prefix or "data") + ".file", definition={'type': 'string'}, rule='type') + data__file_one_of_count9 += 1 + except JsonSchemaValueException: pass + if data__file_one_of_count9 < 2: + try: + if not isinstance(data__file, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".file must be array", value=data__file, name="" + (name_prefix or "data") + ".file", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__file_is_list = isinstance(data__file, (list, tuple)) + if data__file_is_list: + data__file_len = len(data__file) + for data__file_x, data__file_item in enumerate(data__file): + if not isinstance(data__file_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".file[{data__file_x}]".format(**locals()) + " must be string", value=data__file_item, name="" + (name_prefix or "data") + ".file[{data__file_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + data__file_one_of_count9 += 1 + except JsonSchemaValueException: pass + if data__file_one_of_count9 != 1: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".file must be valid exactly by one definition" + (" (" + str(data__file_one_of_count9) + " matches found)"), value=data__file, name="" + (name_prefix or "data") + ".file", definition={'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}, rule='oneOf') + if data_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must not contain "+str(data_keys)+" properties", value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/file-directive', 'title': "'file:' directive", 'description': 'Value is read from a file (or list of files and then concatenated)', 'type': 'object', 'additionalProperties': False, 'properties': {'file': {'oneOf': [{'type': 'string'}, {'type': 'array', 'items': {'type': 'string'}}]}}, 'required': ['file']}, rule='additionalProperties') + return data + +def validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_attr_directive(data, custom_formats={}, name_prefix=None): + if not isinstance(data, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be object", value=data, name="" + (name_prefix or "data") + "", definition={'title': "'attr:' directive", '$id': '#/definitions/attr-directive', '$$description': ['Value is read from a module attribute. Supports callables and iterables;', 'unsupported types are cast via ``str()``'], 'type': 'object', 'additionalProperties': False, 'properties': {'attr': {'type': 'string', 'format': 'python-qualified-identifier'}}, 'required': ['attr']}, rule='type') + data_is_dict = isinstance(data, dict) + if data_is_dict: + data__missing_keys = set(['attr']) - data.keys() + if data__missing_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must contain " + (str(sorted(data__missing_keys)) + " properties"), value=data, name="" + (name_prefix or "data") + "", definition={'title': "'attr:' directive", '$id': '#/definitions/attr-directive', '$$description': ['Value is read from a module attribute. Supports callables and iterables;', 'unsupported types are cast via ``str()``'], 'type': 'object', 'additionalProperties': False, 'properties': {'attr': {'type': 'string', 'format': 'python-qualified-identifier'}}, 'required': ['attr']}, rule='required') + data_keys = set(data.keys()) + if "attr" in data_keys: + data_keys.remove("attr") + data__attr = data["attr"] + if not isinstance(data__attr, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".attr must be string", value=data__attr, name="" + (name_prefix or "data") + ".attr", definition={'type': 'string', 'format': 'python-qualified-identifier'}, rule='type') + if isinstance(data__attr, str): + if not custom_formats["python-qualified-identifier"](data__attr): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".attr must be python-qualified-identifier", value=data__attr, name="" + (name_prefix or "data") + ".attr", definition={'type': 'string', 'format': 'python-qualified-identifier'}, rule='format') + if data_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must not contain "+str(data_keys)+" properties", value=data, name="" + (name_prefix or "data") + "", definition={'title': "'attr:' directive", '$id': '#/definitions/attr-directive', '$$description': ['Value is read from a module attribute. Supports callables and iterables;', 'unsupported types are cast via ``str()``'], 'type': 'object', 'additionalProperties': False, 'properties': {'attr': {'type': 'string', 'format': 'python-qualified-identifier'}}, 'required': ['attr']}, rule='additionalProperties') + return data + +def validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_ext_module(data, custom_formats={}, name_prefix=None): + if not isinstance(data, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be object", value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/ext-module', 'title': 'Extension module', 'description': 'Parameters to construct a :class:`setuptools.Extension` object', 'type': 'object', 'required': ['name', 'sources'], 'additionalProperties': False, 'properties': {'name': {'type': 'string', 'format': 'python-module-name-relaxed'}, 'sources': {'type': 'array', 'items': {'type': 'string'}}, 'include-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'define-macros': {'type': 'array', 'items': {'type': 'array', 'items': [{'description': 'macro name', 'type': 'string'}, {'description': 'macro value', 'oneOf': [{'type': 'string'}, {'type': 'null'}]}], 'additionalItems': False}}, 'undef-macros': {'type': 'array', 'items': {'type': 'string'}}, 'library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'libraries': {'type': 'array', 'items': {'type': 'string'}}, 'runtime-library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'extra-objects': {'type': 'array', 'items': {'type': 'string'}}, 'extra-compile-args': {'type': 'array', 'items': {'type': 'string'}}, 'extra-link-args': {'type': 'array', 'items': {'type': 'string'}}, 'export-symbols': {'type': 'array', 'items': {'type': 'string'}}, 'swig-opts': {'type': 'array', 'items': {'type': 'string'}}, 'depends': {'type': 'array', 'items': {'type': 'string'}}, 'language': {'type': 'string'}, 'optional': {'type': 'boolean'}, 'py-limited-api': {'type': 'boolean'}}}, rule='type') + data_is_dict = isinstance(data, dict) + if data_is_dict: + data__missing_keys = set(['name', 'sources']) - data.keys() + if data__missing_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must contain " + (str(sorted(data__missing_keys)) + " properties"), value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/ext-module', 'title': 'Extension module', 'description': 'Parameters to construct a :class:`setuptools.Extension` object', 'type': 'object', 'required': ['name', 'sources'], 'additionalProperties': False, 'properties': {'name': {'type': 'string', 'format': 'python-module-name-relaxed'}, 'sources': {'type': 'array', 'items': {'type': 'string'}}, 'include-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'define-macros': {'type': 'array', 'items': {'type': 'array', 'items': [{'description': 'macro name', 'type': 'string'}, {'description': 'macro value', 'oneOf': [{'type': 'string'}, {'type': 'null'}]}], 'additionalItems': False}}, 'undef-macros': {'type': 'array', 'items': {'type': 'string'}}, 'library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'libraries': {'type': 'array', 'items': {'type': 'string'}}, 'runtime-library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'extra-objects': {'type': 'array', 'items': {'type': 'string'}}, 'extra-compile-args': {'type': 'array', 'items': {'type': 'string'}}, 'extra-link-args': {'type': 'array', 'items': {'type': 'string'}}, 'export-symbols': {'type': 'array', 'items': {'type': 'string'}}, 'swig-opts': {'type': 'array', 'items': {'type': 'string'}}, 'depends': {'type': 'array', 'items': {'type': 'string'}}, 'language': {'type': 'string'}, 'optional': {'type': 'boolean'}, 'py-limited-api': {'type': 'boolean'}}}, rule='required') + data_keys = set(data.keys()) + if "name" in data_keys: + data_keys.remove("name") + data__name = data["name"] + if not isinstance(data__name, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".name must be string", value=data__name, name="" + (name_prefix or "data") + ".name", definition={'type': 'string', 'format': 'python-module-name-relaxed'}, rule='type') + if isinstance(data__name, str): + if not custom_formats["python-module-name-relaxed"](data__name): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".name must be python-module-name-relaxed", value=data__name, name="" + (name_prefix or "data") + ".name", definition={'type': 'string', 'format': 'python-module-name-relaxed'}, rule='format') + if "sources" in data_keys: + data_keys.remove("sources") + data__sources = data["sources"] + if not isinstance(data__sources, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".sources must be array", value=data__sources, name="" + (name_prefix or "data") + ".sources", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__sources_is_list = isinstance(data__sources, (list, tuple)) + if data__sources_is_list: + data__sources_len = len(data__sources) + for data__sources_x, data__sources_item in enumerate(data__sources): + if not isinstance(data__sources_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".sources[{data__sources_x}]".format(**locals()) + " must be string", value=data__sources_item, name="" + (name_prefix or "data") + ".sources[{data__sources_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "include-dirs" in data_keys: + data_keys.remove("include-dirs") + data__includedirs = data["include-dirs"] + if not isinstance(data__includedirs, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".include-dirs must be array", value=data__includedirs, name="" + (name_prefix or "data") + ".include-dirs", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__includedirs_is_list = isinstance(data__includedirs, (list, tuple)) + if data__includedirs_is_list: + data__includedirs_len = len(data__includedirs) + for data__includedirs_x, data__includedirs_item in enumerate(data__includedirs): + if not isinstance(data__includedirs_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".include-dirs[{data__includedirs_x}]".format(**locals()) + " must be string", value=data__includedirs_item, name="" + (name_prefix or "data") + ".include-dirs[{data__includedirs_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "define-macros" in data_keys: + data_keys.remove("define-macros") + data__definemacros = data["define-macros"] + if not isinstance(data__definemacros, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".define-macros must be array", value=data__definemacros, name="" + (name_prefix or "data") + ".define-macros", definition={'type': 'array', 'items': {'type': 'array', 'items': [{'description': 'macro name', 'type': 'string'}, {'description': 'macro value', 'oneOf': [{'type': 'string'}, {'type': 'null'}]}], 'additionalItems': False}}, rule='type') + data__definemacros_is_list = isinstance(data__definemacros, (list, tuple)) + if data__definemacros_is_list: + data__definemacros_len = len(data__definemacros) + for data__definemacros_x, data__definemacros_item in enumerate(data__definemacros): + if not isinstance(data__definemacros_item, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".define-macros[{data__definemacros_x}]".format(**locals()) + " must be array", value=data__definemacros_item, name="" + (name_prefix or "data") + ".define-macros[{data__definemacros_x}]".format(**locals()) + "", definition={'type': 'array', 'items': [{'description': 'macro name', 'type': 'string'}, {'description': 'macro value', 'oneOf': [{'type': 'string'}, {'type': 'null'}]}], 'additionalItems': False}, rule='type') + data__definemacros_item_is_list = isinstance(data__definemacros_item, (list, tuple)) + if data__definemacros_item_is_list: + data__definemacros_item_len = len(data__definemacros_item) + if data__definemacros_item_len > 0: + data__definemacros_item__0 = data__definemacros_item[0] + if not isinstance(data__definemacros_item__0, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".define-macros[{data__definemacros_x}][0]".format(**locals()) + " must be string", value=data__definemacros_item__0, name="" + (name_prefix or "data") + ".define-macros[{data__definemacros_x}][0]".format(**locals()) + "", definition={'description': 'macro name', 'type': 'string'}, rule='type') + if data__definemacros_item_len > 1: + data__definemacros_item__1 = data__definemacros_item[1] + data__definemacros_item__1_one_of_count10 = 0 + if data__definemacros_item__1_one_of_count10 < 2: + try: + if not isinstance(data__definemacros_item__1, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".define-macros[{data__definemacros_x}][1]".format(**locals()) + " must be string", value=data__definemacros_item__1, name="" + (name_prefix or "data") + ".define-macros[{data__definemacros_x}][1]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + data__definemacros_item__1_one_of_count10 += 1 + except JsonSchemaValueException: pass + if data__definemacros_item__1_one_of_count10 < 2: + try: + if not isinstance(data__definemacros_item__1, (NoneType)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".define-macros[{data__definemacros_x}][1]".format(**locals()) + " must be null", value=data__definemacros_item__1, name="" + (name_prefix or "data") + ".define-macros[{data__definemacros_x}][1]".format(**locals()) + "", definition={'type': 'null'}, rule='type') + data__definemacros_item__1_one_of_count10 += 1 + except JsonSchemaValueException: pass + if data__definemacros_item__1_one_of_count10 != 1: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".define-macros[{data__definemacros_x}][1]".format(**locals()) + " must be valid exactly by one definition" + (" (" + str(data__definemacros_item__1_one_of_count10) + " matches found)"), value=data__definemacros_item__1, name="" + (name_prefix or "data") + ".define-macros[{data__definemacros_x}][1]".format(**locals()) + "", definition={'description': 'macro value', 'oneOf': [{'type': 'string'}, {'type': 'null'}]}, rule='oneOf') + if data__definemacros_item_len > 2: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".define-macros[{data__definemacros_x}]".format(**locals()) + " must contain only specified items", value=data__definemacros_item, name="" + (name_prefix or "data") + ".define-macros[{data__definemacros_x}]".format(**locals()) + "", definition={'type': 'array', 'items': [{'description': 'macro name', 'type': 'string'}, {'description': 'macro value', 'oneOf': [{'type': 'string'}, {'type': 'null'}]}], 'additionalItems': False}, rule='items') + if "undef-macros" in data_keys: + data_keys.remove("undef-macros") + data__undefmacros = data["undef-macros"] + if not isinstance(data__undefmacros, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".undef-macros must be array", value=data__undefmacros, name="" + (name_prefix or "data") + ".undef-macros", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__undefmacros_is_list = isinstance(data__undefmacros, (list, tuple)) + if data__undefmacros_is_list: + data__undefmacros_len = len(data__undefmacros) + for data__undefmacros_x, data__undefmacros_item in enumerate(data__undefmacros): + if not isinstance(data__undefmacros_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".undef-macros[{data__undefmacros_x}]".format(**locals()) + " must be string", value=data__undefmacros_item, name="" + (name_prefix or "data") + ".undef-macros[{data__undefmacros_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "library-dirs" in data_keys: + data_keys.remove("library-dirs") + data__librarydirs = data["library-dirs"] + if not isinstance(data__librarydirs, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".library-dirs must be array", value=data__librarydirs, name="" + (name_prefix or "data") + ".library-dirs", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__librarydirs_is_list = isinstance(data__librarydirs, (list, tuple)) + if data__librarydirs_is_list: + data__librarydirs_len = len(data__librarydirs) + for data__librarydirs_x, data__librarydirs_item in enumerate(data__librarydirs): + if not isinstance(data__librarydirs_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".library-dirs[{data__librarydirs_x}]".format(**locals()) + " must be string", value=data__librarydirs_item, name="" + (name_prefix or "data") + ".library-dirs[{data__librarydirs_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "libraries" in data_keys: + data_keys.remove("libraries") + data__libraries = data["libraries"] + if not isinstance(data__libraries, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".libraries must be array", value=data__libraries, name="" + (name_prefix or "data") + ".libraries", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__libraries_is_list = isinstance(data__libraries, (list, tuple)) + if data__libraries_is_list: + data__libraries_len = len(data__libraries) + for data__libraries_x, data__libraries_item in enumerate(data__libraries): + if not isinstance(data__libraries_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".libraries[{data__libraries_x}]".format(**locals()) + " must be string", value=data__libraries_item, name="" + (name_prefix or "data") + ".libraries[{data__libraries_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "runtime-library-dirs" in data_keys: + data_keys.remove("runtime-library-dirs") + data__runtimelibrarydirs = data["runtime-library-dirs"] + if not isinstance(data__runtimelibrarydirs, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".runtime-library-dirs must be array", value=data__runtimelibrarydirs, name="" + (name_prefix or "data") + ".runtime-library-dirs", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__runtimelibrarydirs_is_list = isinstance(data__runtimelibrarydirs, (list, tuple)) + if data__runtimelibrarydirs_is_list: + data__runtimelibrarydirs_len = len(data__runtimelibrarydirs) + for data__runtimelibrarydirs_x, data__runtimelibrarydirs_item in enumerate(data__runtimelibrarydirs): + if not isinstance(data__runtimelibrarydirs_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".runtime-library-dirs[{data__runtimelibrarydirs_x}]".format(**locals()) + " must be string", value=data__runtimelibrarydirs_item, name="" + (name_prefix or "data") + ".runtime-library-dirs[{data__runtimelibrarydirs_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "extra-objects" in data_keys: + data_keys.remove("extra-objects") + data__extraobjects = data["extra-objects"] + if not isinstance(data__extraobjects, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".extra-objects must be array", value=data__extraobjects, name="" + (name_prefix or "data") + ".extra-objects", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__extraobjects_is_list = isinstance(data__extraobjects, (list, tuple)) + if data__extraobjects_is_list: + data__extraobjects_len = len(data__extraobjects) + for data__extraobjects_x, data__extraobjects_item in enumerate(data__extraobjects): + if not isinstance(data__extraobjects_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".extra-objects[{data__extraobjects_x}]".format(**locals()) + " must be string", value=data__extraobjects_item, name="" + (name_prefix or "data") + ".extra-objects[{data__extraobjects_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "extra-compile-args" in data_keys: + data_keys.remove("extra-compile-args") + data__extracompileargs = data["extra-compile-args"] + if not isinstance(data__extracompileargs, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".extra-compile-args must be array", value=data__extracompileargs, name="" + (name_prefix or "data") + ".extra-compile-args", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__extracompileargs_is_list = isinstance(data__extracompileargs, (list, tuple)) + if data__extracompileargs_is_list: + data__extracompileargs_len = len(data__extracompileargs) + for data__extracompileargs_x, data__extracompileargs_item in enumerate(data__extracompileargs): + if not isinstance(data__extracompileargs_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".extra-compile-args[{data__extracompileargs_x}]".format(**locals()) + " must be string", value=data__extracompileargs_item, name="" + (name_prefix or "data") + ".extra-compile-args[{data__extracompileargs_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "extra-link-args" in data_keys: + data_keys.remove("extra-link-args") + data__extralinkargs = data["extra-link-args"] + if not isinstance(data__extralinkargs, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".extra-link-args must be array", value=data__extralinkargs, name="" + (name_prefix or "data") + ".extra-link-args", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__extralinkargs_is_list = isinstance(data__extralinkargs, (list, tuple)) + if data__extralinkargs_is_list: + data__extralinkargs_len = len(data__extralinkargs) + for data__extralinkargs_x, data__extralinkargs_item in enumerate(data__extralinkargs): + if not isinstance(data__extralinkargs_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".extra-link-args[{data__extralinkargs_x}]".format(**locals()) + " must be string", value=data__extralinkargs_item, name="" + (name_prefix or "data") + ".extra-link-args[{data__extralinkargs_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "export-symbols" in data_keys: + data_keys.remove("export-symbols") + data__exportsymbols = data["export-symbols"] + if not isinstance(data__exportsymbols, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".export-symbols must be array", value=data__exportsymbols, name="" + (name_prefix or "data") + ".export-symbols", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__exportsymbols_is_list = isinstance(data__exportsymbols, (list, tuple)) + if data__exportsymbols_is_list: + data__exportsymbols_len = len(data__exportsymbols) + for data__exportsymbols_x, data__exportsymbols_item in enumerate(data__exportsymbols): + if not isinstance(data__exportsymbols_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".export-symbols[{data__exportsymbols_x}]".format(**locals()) + " must be string", value=data__exportsymbols_item, name="" + (name_prefix or "data") + ".export-symbols[{data__exportsymbols_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "swig-opts" in data_keys: + data_keys.remove("swig-opts") + data__swigopts = data["swig-opts"] + if not isinstance(data__swigopts, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".swig-opts must be array", value=data__swigopts, name="" + (name_prefix or "data") + ".swig-opts", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__swigopts_is_list = isinstance(data__swigopts, (list, tuple)) + if data__swigopts_is_list: + data__swigopts_len = len(data__swigopts) + for data__swigopts_x, data__swigopts_item in enumerate(data__swigopts): + if not isinstance(data__swigopts_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".swig-opts[{data__swigopts_x}]".format(**locals()) + " must be string", value=data__swigopts_item, name="" + (name_prefix or "data") + ".swig-opts[{data__swigopts_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "depends" in data_keys: + data_keys.remove("depends") + data__depends = data["depends"] + if not isinstance(data__depends, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".depends must be array", value=data__depends, name="" + (name_prefix or "data") + ".depends", definition={'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__depends_is_list = isinstance(data__depends, (list, tuple)) + if data__depends_is_list: + data__depends_len = len(data__depends) + for data__depends_x, data__depends_item in enumerate(data__depends): + if not isinstance(data__depends_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".depends[{data__depends_x}]".format(**locals()) + " must be string", value=data__depends_item, name="" + (name_prefix or "data") + ".depends[{data__depends_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "language" in data_keys: + data_keys.remove("language") + data__language = data["language"] + if not isinstance(data__language, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".language must be string", value=data__language, name="" + (name_prefix or "data") + ".language", definition={'type': 'string'}, rule='type') + if "optional" in data_keys: + data_keys.remove("optional") + data__optional = data["optional"] + if not isinstance(data__optional, (bool)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".optional must be boolean", value=data__optional, name="" + (name_prefix or "data") + ".optional", definition={'type': 'boolean'}, rule='type') + if "py-limited-api" in data_keys: + data_keys.remove("py-limited-api") + data__pylimitedapi = data["py-limited-api"] + if not isinstance(data__pylimitedapi, (bool)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".py-limited-api must be boolean", value=data__pylimitedapi, name="" + (name_prefix or "data") + ".py-limited-api", definition={'type': 'boolean'}, rule='type') + if data_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must not contain "+str(data_keys)+" properties", value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/ext-module', 'title': 'Extension module', 'description': 'Parameters to construct a :class:`setuptools.Extension` object', 'type': 'object', 'required': ['name', 'sources'], 'additionalProperties': False, 'properties': {'name': {'type': 'string', 'format': 'python-module-name-relaxed'}, 'sources': {'type': 'array', 'items': {'type': 'string'}}, 'include-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'define-macros': {'type': 'array', 'items': {'type': 'array', 'items': [{'description': 'macro name', 'type': 'string'}, {'description': 'macro value', 'oneOf': [{'type': 'string'}, {'type': 'null'}]}], 'additionalItems': False}}, 'undef-macros': {'type': 'array', 'items': {'type': 'string'}}, 'library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'libraries': {'type': 'array', 'items': {'type': 'string'}}, 'runtime-library-dirs': {'type': 'array', 'items': {'type': 'string'}}, 'extra-objects': {'type': 'array', 'items': {'type': 'string'}}, 'extra-compile-args': {'type': 'array', 'items': {'type': 'string'}}, 'extra-link-args': {'type': 'array', 'items': {'type': 'string'}}, 'export-symbols': {'type': 'array', 'items': {'type': 'string'}}, 'swig-opts': {'type': 'array', 'items': {'type': 'string'}}, 'depends': {'type': 'array', 'items': {'type': 'string'}}, 'language': {'type': 'string'}, 'optional': {'type': 'boolean'}, 'py-limited-api': {'type': 'boolean'}}}, rule='additionalProperties') + return data + +def validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_find_directive(data, custom_formats={}, name_prefix=None): + if not isinstance(data, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be object", value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/find-directive', 'title': "'find:' directive", 'type': 'object', 'additionalProperties': False, 'properties': {'find': {'type': 'object', '$$description': ['Dynamic `package discovery', '<https://setuptools.pypa.io/en/latest/userguide/package_discovery.html>`_.'], 'additionalProperties': False, 'properties': {'where': {'description': 'Directories to be searched for packages (Unix-style relative path)', 'type': 'array', 'items': {'type': 'string'}}, 'exclude': {'type': 'array', '$$description': ['Exclude packages that match the values listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'include': {'type': 'array', '$$description': ['Restrict the found packages to just the ones listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'namespaces': {'type': 'boolean', '$$description': ['When ``True``, directories without a ``__init__.py`` file will also', 'be scanned for :pep:`420`-style implicit namespaces']}}}}}, rule='type') + data_is_dict = isinstance(data, dict) + if data_is_dict: + data_keys = set(data.keys()) + if "find" in data_keys: + data_keys.remove("find") + data__find = data["find"] + if not isinstance(data__find, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".find must be object", value=data__find, name="" + (name_prefix or "data") + ".find", definition={'type': 'object', '$$description': ['Dynamic `package discovery', '<https://setuptools.pypa.io/en/latest/userguide/package_discovery.html>`_.'], 'additionalProperties': False, 'properties': {'where': {'description': 'Directories to be searched for packages (Unix-style relative path)', 'type': 'array', 'items': {'type': 'string'}}, 'exclude': {'type': 'array', '$$description': ['Exclude packages that match the values listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'include': {'type': 'array', '$$description': ['Restrict the found packages to just the ones listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'namespaces': {'type': 'boolean', '$$description': ['When ``True``, directories without a ``__init__.py`` file will also', 'be scanned for :pep:`420`-style implicit namespaces']}}}, rule='type') + data__find_is_dict = isinstance(data__find, dict) + if data__find_is_dict: + data__find_keys = set(data__find.keys()) + if "where" in data__find_keys: + data__find_keys.remove("where") + data__find__where = data__find["where"] + if not isinstance(data__find__where, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".find.where must be array", value=data__find__where, name="" + (name_prefix or "data") + ".find.where", definition={'description': 'Directories to be searched for packages (Unix-style relative path)', 'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__find__where_is_list = isinstance(data__find__where, (list, tuple)) + if data__find__where_is_list: + data__find__where_len = len(data__find__where) + for data__find__where_x, data__find__where_item in enumerate(data__find__where): + if not isinstance(data__find__where_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".find.where[{data__find__where_x}]".format(**locals()) + " must be string", value=data__find__where_item, name="" + (name_prefix or "data") + ".find.where[{data__find__where_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "exclude" in data__find_keys: + data__find_keys.remove("exclude") + data__find__exclude = data__find["exclude"] + if not isinstance(data__find__exclude, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".find.exclude must be array", value=data__find__exclude, name="" + (name_prefix or "data") + ".find.exclude", definition={'type': 'array', '$$description': ['Exclude packages that match the values listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, rule='type') + data__find__exclude_is_list = isinstance(data__find__exclude, (list, tuple)) + if data__find__exclude_is_list: + data__find__exclude_len = len(data__find__exclude) + for data__find__exclude_x, data__find__exclude_item in enumerate(data__find__exclude): + if not isinstance(data__find__exclude_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".find.exclude[{data__find__exclude_x}]".format(**locals()) + " must be string", value=data__find__exclude_item, name="" + (name_prefix or "data") + ".find.exclude[{data__find__exclude_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "include" in data__find_keys: + data__find_keys.remove("include") + data__find__include = data__find["include"] + if not isinstance(data__find__include, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".find.include must be array", value=data__find__include, name="" + (name_prefix or "data") + ".find.include", definition={'type': 'array', '$$description': ['Restrict the found packages to just the ones listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, rule='type') + data__find__include_is_list = isinstance(data__find__include, (list, tuple)) + if data__find__include_is_list: + data__find__include_len = len(data__find__include) + for data__find__include_x, data__find__include_item in enumerate(data__find__include): + if not isinstance(data__find__include_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".find.include[{data__find__include_x}]".format(**locals()) + " must be string", value=data__find__include_item, name="" + (name_prefix or "data") + ".find.include[{data__find__include_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "namespaces" in data__find_keys: + data__find_keys.remove("namespaces") + data__find__namespaces = data__find["namespaces"] + if not isinstance(data__find__namespaces, (bool)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".find.namespaces must be boolean", value=data__find__namespaces, name="" + (name_prefix or "data") + ".find.namespaces", definition={'type': 'boolean', '$$description': ['When ``True``, directories without a ``__init__.py`` file will also', 'be scanned for :pep:`420`-style implicit namespaces']}, rule='type') + if data__find_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".find must not contain "+str(data__find_keys)+" properties", value=data__find, name="" + (name_prefix or "data") + ".find", definition={'type': 'object', '$$description': ['Dynamic `package discovery', '<https://setuptools.pypa.io/en/latest/userguide/package_discovery.html>`_.'], 'additionalProperties': False, 'properties': {'where': {'description': 'Directories to be searched for packages (Unix-style relative path)', 'type': 'array', 'items': {'type': 'string'}}, 'exclude': {'type': 'array', '$$description': ['Exclude packages that match the values listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'include': {'type': 'array', '$$description': ['Restrict the found packages to just the ones listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'namespaces': {'type': 'boolean', '$$description': ['When ``True``, directories without a ``__init__.py`` file will also', 'be scanned for :pep:`420`-style implicit namespaces']}}}, rule='additionalProperties') + if data_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must not contain "+str(data_keys)+" properties", value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/find-directive', 'title': "'find:' directive", 'type': 'object', 'additionalProperties': False, 'properties': {'find': {'type': 'object', '$$description': ['Dynamic `package discovery', '<https://setuptools.pypa.io/en/latest/userguide/package_discovery.html>`_.'], 'additionalProperties': False, 'properties': {'where': {'description': 'Directories to be searched for packages (Unix-style relative path)', 'type': 'array', 'items': {'type': 'string'}}, 'exclude': {'type': 'array', '$$description': ['Exclude packages that match the values listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'include': {'type': 'array', '$$description': ['Restrict the found packages to just the ones listed in this field.', "Can container shell-style wildcards (e.g. ``'pkg.*'``)"], 'items': {'type': 'string'}}, 'namespaces': {'type': 'boolean', '$$description': ['When ``True``, directories without a ``__init__.py`` file will also', 'be scanned for :pep:`420`-style implicit namespaces']}}}}}, rule='additionalProperties') + return data + +def validate_https___setuptools_pypa_io_en_latest_userguide_pyproject_config_html__definitions_package_name(data, custom_formats={}, name_prefix=None): + if not isinstance(data, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be string", value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, rule='type') + data_any_of_count11 = 0 + if not data_any_of_count11: + try: + if not isinstance(data, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be string", value=data, name="" + (name_prefix or "data") + "", definition={'type': 'string', 'format': 'python-module-name-relaxed'}, rule='type') + if isinstance(data, str): + if not custom_formats["python-module-name-relaxed"](data): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be python-module-name-relaxed", value=data, name="" + (name_prefix or "data") + "", definition={'type': 'string', 'format': 'python-module-name-relaxed'}, rule='format') + data_any_of_count11 += 1 + except JsonSchemaValueException: pass + if not data_any_of_count11: + try: + if not isinstance(data, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be string", value=data, name="" + (name_prefix or "data") + "", definition={'type': 'string', 'format': 'pep561-stub-name'}, rule='type') + if isinstance(data, str): + if not custom_formats["pep561-stub-name"](data): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be pep561-stub-name", value=data, name="" + (name_prefix or "data") + "", definition={'type': 'string', 'format': 'pep561-stub-name'}, rule='format') + data_any_of_count11 += 1 + except JsonSchemaValueException: pass + if not data_any_of_count11: + raise JsonSchemaValueException("" + (name_prefix or "data") + " cannot be validated by any definition", value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/package-name', 'title': 'Valid package name', 'description': 'Valid package name (importable or :pep:`561`).', 'type': 'string', 'anyOf': [{'type': 'string', 'format': 'python-module-name-relaxed'}, {'type': 'string', 'format': 'pep561-stub-name'}]}, rule='anyOf') + return data + +def validate_https___setuptools_pypa_io_en_latest_deprecated_distutils_configfile_html(data, custom_formats={}, name_prefix=None): + if not isinstance(data, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be object", value=data, name="" + (name_prefix or "data") + "", definition={'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://setuptools.pypa.io/en/latest/deprecated/distutils/configfile.html', 'title': '``tool.distutils`` table', '$$description': ['**EXPERIMENTAL** (NOT OFFICIALLY SUPPORTED): Use ``tool.distutils``', 'subtables to configure arguments for ``distutils`` commands.', 'Originally, ``distutils`` allowed developers to configure arguments for', '``setup.py`` commands via `distutils configuration files', '<https://setuptools.pypa.io/en/latest/deprecated/distutils/configfile.html>`_.', 'See also `the old Python docs <https://docs.python.org/3.11/install/>_`.'], 'type': 'object', 'properties': {'global': {'type': 'object', 'description': 'Global options applied to all ``distutils`` commands'}}, 'patternProperties': {'.+': {'type': 'object'}}, '$comment': 'TODO: Is there a practical way of making this schema more specific?'}, rule='type') + data_is_dict = isinstance(data, dict) + if data_is_dict: + data_keys = set(data.keys()) + if "global" in data_keys: + data_keys.remove("global") + data__global = data["global"] + if not isinstance(data__global, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".global must be object", value=data__global, name="" + (name_prefix or "data") + ".global", definition={'type': 'object', 'description': 'Global options applied to all ``distutils`` commands'}, rule='type') + for data_key, data_val in data.items(): + if REGEX_PATTERNS['.+'].search(data_key): + if data_key in data_keys: + data_keys.remove(data_key) + if not isinstance(data_val, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".{data_key}".format(**locals()) + " must be object", value=data_val, name="" + (name_prefix or "data") + ".{data_key}".format(**locals()) + "", definition={'type': 'object'}, rule='type') + return data + +def validate_https___packaging_python_org_en_latest_specifications_pyproject_toml(data, custom_formats={}, name_prefix=None): + if not isinstance(data, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be object", value=data, name="" + (name_prefix or "data") + "", definition={'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://packaging.python.org/en/latest/specifications/pyproject-toml/', 'title': 'Package metadata stored in the ``project`` table', '$$description': ['Data structure for the **project** table inside ``pyproject.toml``', '(as initially defined in :pep:`621`)'], 'type': 'object', 'properties': {'name': {'type': 'string', 'description': 'The name (primary identifier) of the project. MUST be statically defined.', 'format': 'pep508-identifier'}, 'version': {'type': 'string', 'description': 'The version of the project as supported by :pep:`440`.', 'format': 'pep440'}, 'description': {'type': 'string', '$$description': ['The `summary description of the project', '<https://packaging.python.org/specifications/core-metadata/#summary>`_']}, 'readme': {'$$description': ['`Full/detailed description of the project in the form of a README', '<https://peps.python.org/pep-0621/#readme>`_', "with meaning similar to the one defined in `core metadata's Description", '<https://packaging.python.org/specifications/core-metadata/#description>`_'], 'oneOf': [{'type': 'string', '$$description': ['Relative path to a text file (UTF-8) containing the full description', 'of the project. If the file path ends in case-insensitive ``.md`` or', '``.rst`` suffixes, then the content-type is respectively', '``text/markdown`` or ``text/x-rst``']}, {'type': 'object', 'allOf': [{'anyOf': [{'properties': {'file': {'type': 'string', '$$description': ['Relative path to a text file containing the full description', 'of the project.']}}, 'required': ['file']}, {'properties': {'text': {'type': 'string', 'description': 'Full text describing the project.'}}, 'required': ['text']}]}, {'properties': {'content-type': {'type': 'string', '$$description': ['Content-type (:rfc:`1341`) of the full description', '(e.g. ``text/markdown``). The ``charset`` parameter is assumed', 'UTF-8 when not present.'], '$comment': 'TODO: add regex pattern or format?'}}, 'required': ['content-type']}]}]}, 'requires-python': {'type': 'string', 'format': 'pep508-versionspec', '$$description': ['`The Python version requirements of the project', '<https://packaging.python.org/specifications/core-metadata/#requires-python>`_.']}, 'license': {'description': '`Project license <https://peps.python.org/pep-0621/#license>`_.', 'oneOf': [{'type': 'string', 'description': 'An SPDX license identifier', 'format': 'SPDX'}, {'type': 'object', 'properties': {'file': {'type': 'string', '$$description': ['Relative path to the file (UTF-8) which contains the license for the', 'project.']}}, 'required': ['file']}, {'type': 'object', 'properties': {'text': {'type': 'string', '$$description': ['The license of the project whose meaning is that of the', '`License field from the core metadata', '<https://packaging.python.org/specifications/core-metadata/#license>`_.']}}, 'required': ['text']}]}, 'license-files': {'description': 'Paths or globs to paths of license files', 'type': 'array', 'items': {'type': 'string'}}, 'authors': {'type': 'array', 'items': {'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, '$$description': ["The people or organizations considered to be the 'authors' of the project.", 'The exact meaning is open to interpretation (e.g. original or primary authors,', 'current maintainers, or owners of the package).']}, 'maintainers': {'type': 'array', 'items': {'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, '$$description': ["The people or organizations considered to be the 'maintainers' of the project.", 'Similarly to ``authors``, the exact meaning is open to interpretation.']}, 'keywords': {'type': 'array', 'items': {'type': 'string'}, 'description': 'List of keywords to assist searching for the distribution in a larger catalog.'}, 'classifiers': {'type': 'array', 'items': {'type': 'string', 'format': 'trove-classifier', 'description': '`PyPI classifier <https://pypi.org/classifiers/>`_.'}, '$$description': ['`Trove classifiers <https://pypi.org/classifiers/>`_', 'which apply to the project.']}, 'urls': {'type': 'object', 'description': 'URLs associated with the project in the form ``label => value``.', 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', 'format': 'url'}}}, 'scripts': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}, 'gui-scripts': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}, 'entry-points': {'$$description': ['Instruct the installer to expose the given modules/functions via', '``entry-point`` discovery mechanism (useful for plugins).', 'More information available in the `Python packaging guide', '<https://packaging.python.org/specifications/entry-points/>`_.'], 'propertyNames': {'format': 'python-entrypoint-group'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}}}, 'dependencies': {'type': 'array', 'description': 'Project (mandatory) dependencies.', 'items': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}, 'optional-dependencies': {'type': 'object', 'description': 'Optional dependency for the project', 'propertyNames': {'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'array', 'items': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}}}, 'import-names': {'description': 'Lists import names which a project, when installed, would exclusively provide.', 'type': 'array', 'items': {'type': 'string', 'format': 'import-name'}}, 'import-namespaces': {'description': 'Lists import names that, when installed, would be provided by the project, but not exclusively.', 'type': 'array', 'items': {'type': 'string', 'format': 'import-name'}}, 'dynamic': {'type': 'array', '$$description': ['Specifies which fields are intentionally unspecified and expected to be', 'dynamically provided by build tools'], 'items': {'enum': ['version', 'description', 'readme', 'requires-python', 'license', 'license-files', 'authors', 'maintainers', 'keywords', 'classifiers', 'urls', 'scripts', 'gui-scripts', 'entry-points', 'dependencies', 'optional-dependencies', 'import-names', 'import-namespaces']}}}, 'required': ['name'], 'additionalProperties': False, 'allOf': [{'if': {'not': {'required': ['dynamic'], 'properties': {'dynamic': {'contains': {'const': 'version'}, '$$description': ['version is listed in ``dynamic``']}}}, '$$comment': ['According to :pep:`621`:', ' If the core metadata specification lists a field as "Required", then', ' the metadata MUST specify the field statically or list it in dynamic', 'In turn, `core metadata`_ defines:', ' The required fields are: Metadata-Version, Name, Version.', ' All the other fields are optional.', 'Since ``Metadata-Version`` is defined by the build back-end, ``name`` and', '``version`` are the only mandatory information in ``pyproject.toml``.', '.. _core metadata: https://packaging.python.org/specifications/core-metadata/']}, 'then': {'required': ['version'], '$$description': ['version should be statically defined in the ``version`` field']}}, {'if': {'required': ['license-files']}, 'then': {'properties': {'license': {'type': 'string'}}}}], 'definitions': {'author': {'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, 'entry-point-group': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}, 'dependency': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}}, rule='type') + try: + try: + data_is_dict = isinstance(data, dict) + if data_is_dict: + data__missing_keys = set(['dynamic']) - data.keys() + if data__missing_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must contain " + (str(sorted(data__missing_keys)) + " properties"), value=data, name="" + (name_prefix or "data") + "", definition={'required': ['dynamic'], 'properties': {'dynamic': {'contains': {'const': 'version'}, '$$description': ['version is listed in ``dynamic``']}}}, rule='required') + data_keys = set(data.keys()) + if "dynamic" in data_keys: + data_keys.remove("dynamic") + data__dynamic = data["dynamic"] + data__dynamic_is_list = isinstance(data__dynamic, (list, tuple)) + if data__dynamic_is_list: + data__dynamic_contains = False + for data__dynamic_key in data__dynamic: + try: + if data__dynamic_key != "version": + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic must be same as const definition: version", value=data__dynamic_key, name="" + (name_prefix or "data") + ".dynamic", definition={'const': 'version'}, rule='const') + data__dynamic_contains = True + break + except JsonSchemaValueException: pass + if not data__dynamic_contains: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic must contain one of contains definition", value=data__dynamic, name="" + (name_prefix or "data") + ".dynamic", definition={'contains': {'const': 'version'}, '$$description': ['version is listed in ``dynamic``']}, rule='contains') + except JsonSchemaValueException: pass + else: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must NOT match a disallowed definition", value=data, name="" + (name_prefix or "data") + "", definition={'not': {'required': ['dynamic'], 'properties': {'dynamic': {'contains': {'const': 'version'}, '$$description': ['version is listed in ``dynamic``']}}}, '$$comment': ['According to :pep:`621`:', ' If the core metadata specification lists a field as "Required", then', ' the metadata MUST specify the field statically or list it in dynamic', 'In turn, `core metadata`_ defines:', ' The required fields are: Metadata-Version, Name, Version.', ' All the other fields are optional.', 'Since ``Metadata-Version`` is defined by the build back-end, ``name`` and', '``version`` are the only mandatory information in ``pyproject.toml``.', '.. _core metadata: https://packaging.python.org/specifications/core-metadata/']}, rule='not') + except JsonSchemaValueException: + pass + else: + data_is_dict = isinstance(data, dict) + if data_is_dict: + data__missing_keys = set(['version']) - data.keys() + if data__missing_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must contain " + (str(sorted(data__missing_keys)) + " properties"), value=data, name="" + (name_prefix or "data") + "", definition={'required': ['version'], '$$description': ['version should be statically defined in the ``version`` field']}, rule='required') + try: + data_is_dict = isinstance(data, dict) + if data_is_dict: + data__missing_keys = set(['license-files']) - data.keys() + if data__missing_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must contain " + (str(sorted(data__missing_keys)) + " properties"), value=data, name="" + (name_prefix or "data") + "", definition={'required': ['license-files']}, rule='required') + except JsonSchemaValueException: + pass + else: + data_is_dict = isinstance(data, dict) + if data_is_dict: + data_keys = set(data.keys()) + if "license" in data_keys: + data_keys.remove("license") + data__license = data["license"] + if not isinstance(data__license, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".license must be string", value=data__license, name="" + (name_prefix or "data") + ".license", definition={'type': 'string'}, rule='type') + data_is_dict = isinstance(data, dict) + if data_is_dict: + data__missing_keys = set(['name']) - data.keys() + if data__missing_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must contain " + (str(sorted(data__missing_keys)) + " properties"), value=data, name="" + (name_prefix or "data") + "", definition={'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://packaging.python.org/en/latest/specifications/pyproject-toml/', 'title': 'Package metadata stored in the ``project`` table', '$$description': ['Data structure for the **project** table inside ``pyproject.toml``', '(as initially defined in :pep:`621`)'], 'type': 'object', 'properties': {'name': {'type': 'string', 'description': 'The name (primary identifier) of the project. MUST be statically defined.', 'format': 'pep508-identifier'}, 'version': {'type': 'string', 'description': 'The version of the project as supported by :pep:`440`.', 'format': 'pep440'}, 'description': {'type': 'string', '$$description': ['The `summary description of the project', '<https://packaging.python.org/specifications/core-metadata/#summary>`_']}, 'readme': {'$$description': ['`Full/detailed description of the project in the form of a README', '<https://peps.python.org/pep-0621/#readme>`_', "with meaning similar to the one defined in `core metadata's Description", '<https://packaging.python.org/specifications/core-metadata/#description>`_'], 'oneOf': [{'type': 'string', '$$description': ['Relative path to a text file (UTF-8) containing the full description', 'of the project. If the file path ends in case-insensitive ``.md`` or', '``.rst`` suffixes, then the content-type is respectively', '``text/markdown`` or ``text/x-rst``']}, {'type': 'object', 'allOf': [{'anyOf': [{'properties': {'file': {'type': 'string', '$$description': ['Relative path to a text file containing the full description', 'of the project.']}}, 'required': ['file']}, {'properties': {'text': {'type': 'string', 'description': 'Full text describing the project.'}}, 'required': ['text']}]}, {'properties': {'content-type': {'type': 'string', '$$description': ['Content-type (:rfc:`1341`) of the full description', '(e.g. ``text/markdown``). The ``charset`` parameter is assumed', 'UTF-8 when not present.'], '$comment': 'TODO: add regex pattern or format?'}}, 'required': ['content-type']}]}]}, 'requires-python': {'type': 'string', 'format': 'pep508-versionspec', '$$description': ['`The Python version requirements of the project', '<https://packaging.python.org/specifications/core-metadata/#requires-python>`_.']}, 'license': {'description': '`Project license <https://peps.python.org/pep-0621/#license>`_.', 'oneOf': [{'type': 'string', 'description': 'An SPDX license identifier', 'format': 'SPDX'}, {'type': 'object', 'properties': {'file': {'type': 'string', '$$description': ['Relative path to the file (UTF-8) which contains the license for the', 'project.']}}, 'required': ['file']}, {'type': 'object', 'properties': {'text': {'type': 'string', '$$description': ['The license of the project whose meaning is that of the', '`License field from the core metadata', '<https://packaging.python.org/specifications/core-metadata/#license>`_.']}}, 'required': ['text']}]}, 'license-files': {'description': 'Paths or globs to paths of license files', 'type': 'array', 'items': {'type': 'string'}}, 'authors': {'type': 'array', 'items': {'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, '$$description': ["The people or organizations considered to be the 'authors' of the project.", 'The exact meaning is open to interpretation (e.g. original or primary authors,', 'current maintainers, or owners of the package).']}, 'maintainers': {'type': 'array', 'items': {'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, '$$description': ["The people or organizations considered to be the 'maintainers' of the project.", 'Similarly to ``authors``, the exact meaning is open to interpretation.']}, 'keywords': {'type': 'array', 'items': {'type': 'string'}, 'description': 'List of keywords to assist searching for the distribution in a larger catalog.'}, 'classifiers': {'type': 'array', 'items': {'type': 'string', 'format': 'trove-classifier', 'description': '`PyPI classifier <https://pypi.org/classifiers/>`_.'}, '$$description': ['`Trove classifiers <https://pypi.org/classifiers/>`_', 'which apply to the project.']}, 'urls': {'type': 'object', 'description': 'URLs associated with the project in the form ``label => value``.', 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', 'format': 'url'}}}, 'scripts': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}, 'gui-scripts': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}, 'entry-points': {'$$description': ['Instruct the installer to expose the given modules/functions via', '``entry-point`` discovery mechanism (useful for plugins).', 'More information available in the `Python packaging guide', '<https://packaging.python.org/specifications/entry-points/>`_.'], 'propertyNames': {'format': 'python-entrypoint-group'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}}}, 'dependencies': {'type': 'array', 'description': 'Project (mandatory) dependencies.', 'items': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}, 'optional-dependencies': {'type': 'object', 'description': 'Optional dependency for the project', 'propertyNames': {'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'array', 'items': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}}}, 'import-names': {'description': 'Lists import names which a project, when installed, would exclusively provide.', 'type': 'array', 'items': {'type': 'string', 'format': 'import-name'}}, 'import-namespaces': {'description': 'Lists import names that, when installed, would be provided by the project, but not exclusively.', 'type': 'array', 'items': {'type': 'string', 'format': 'import-name'}}, 'dynamic': {'type': 'array', '$$description': ['Specifies which fields are intentionally unspecified and expected to be', 'dynamically provided by build tools'], 'items': {'enum': ['version', 'description', 'readme', 'requires-python', 'license', 'license-files', 'authors', 'maintainers', 'keywords', 'classifiers', 'urls', 'scripts', 'gui-scripts', 'entry-points', 'dependencies', 'optional-dependencies', 'import-names', 'import-namespaces']}}}, 'required': ['name'], 'additionalProperties': False, 'allOf': [{'if': {'not': {'required': ['dynamic'], 'properties': {'dynamic': {'contains': {'const': 'version'}, '$$description': ['version is listed in ``dynamic``']}}}, '$$comment': ['According to :pep:`621`:', ' If the core metadata specification lists a field as "Required", then', ' the metadata MUST specify the field statically or list it in dynamic', 'In turn, `core metadata`_ defines:', ' The required fields are: Metadata-Version, Name, Version.', ' All the other fields are optional.', 'Since ``Metadata-Version`` is defined by the build back-end, ``name`` and', '``version`` are the only mandatory information in ``pyproject.toml``.', '.. _core metadata: https://packaging.python.org/specifications/core-metadata/']}, 'then': {'required': ['version'], '$$description': ['version should be statically defined in the ``version`` field']}}, {'if': {'required': ['license-files']}, 'then': {'properties': {'license': {'type': 'string'}}}}], 'definitions': {'author': {'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, 'entry-point-group': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}, 'dependency': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}}, rule='required') + data_keys = set(data.keys()) + if "name" in data_keys: + data_keys.remove("name") + data__name = data["name"] + if not isinstance(data__name, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".name must be string", value=data__name, name="" + (name_prefix or "data") + ".name", definition={'type': 'string', 'description': 'The name (primary identifier) of the project. MUST be statically defined.', 'format': 'pep508-identifier'}, rule='type') + if isinstance(data__name, str): + if not custom_formats["pep508-identifier"](data__name): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".name must be pep508-identifier", value=data__name, name="" + (name_prefix or "data") + ".name", definition={'type': 'string', 'description': 'The name (primary identifier) of the project. MUST be statically defined.', 'format': 'pep508-identifier'}, rule='format') + if "version" in data_keys: + data_keys.remove("version") + data__version = data["version"] + if not isinstance(data__version, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".version must be string", value=data__version, name="" + (name_prefix or "data") + ".version", definition={'type': 'string', 'description': 'The version of the project as supported by :pep:`440`.', 'format': 'pep440'}, rule='type') + if isinstance(data__version, str): + if not custom_formats["pep440"](data__version): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".version must be pep440", value=data__version, name="" + (name_prefix or "data") + ".version", definition={'type': 'string', 'description': 'The version of the project as supported by :pep:`440`.', 'format': 'pep440'}, rule='format') + if "description" in data_keys: + data_keys.remove("description") + data__description = data["description"] + if not isinstance(data__description, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".description must be string", value=data__description, name="" + (name_prefix or "data") + ".description", definition={'type': 'string', '$$description': ['The `summary description of the project', '<https://packaging.python.org/specifications/core-metadata/#summary>`_']}, rule='type') + if "readme" in data_keys: + data_keys.remove("readme") + data__readme = data["readme"] + data__readme_one_of_count12 = 0 + if data__readme_one_of_count12 < 2: + try: + if not isinstance(data__readme, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".readme must be string", value=data__readme, name="" + (name_prefix or "data") + ".readme", definition={'type': 'string', '$$description': ['Relative path to a text file (UTF-8) containing the full description', 'of the project. If the file path ends in case-insensitive ``.md`` or', '``.rst`` suffixes, then the content-type is respectively', '``text/markdown`` or ``text/x-rst``']}, rule='type') + data__readme_one_of_count12 += 1 + except JsonSchemaValueException: pass + if data__readme_one_of_count12 < 2: + try: + if not isinstance(data__readme, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".readme must be object", value=data__readme, name="" + (name_prefix or "data") + ".readme", definition={'type': 'object', 'allOf': [{'anyOf': [{'properties': {'file': {'type': 'string', '$$description': ['Relative path to a text file containing the full description', 'of the project.']}}, 'required': ['file']}, {'properties': {'text': {'type': 'string', 'description': 'Full text describing the project.'}}, 'required': ['text']}]}, {'properties': {'content-type': {'type': 'string', '$$description': ['Content-type (:rfc:`1341`) of the full description', '(e.g. ``text/markdown``). The ``charset`` parameter is assumed', 'UTF-8 when not present.'], '$comment': 'TODO: add regex pattern or format?'}}, 'required': ['content-type']}]}, rule='type') + data__readme_any_of_count13 = 0 + if not data__readme_any_of_count13: + try: + data__readme_is_dict = isinstance(data__readme, dict) + if data__readme_is_dict: + data__readme__missing_keys = set(['file']) - data__readme.keys() + if data__readme__missing_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".readme must contain " + (str(sorted(data__readme__missing_keys)) + " properties"), value=data__readme, name="" + (name_prefix or "data") + ".readme", definition={'properties': {'file': {'type': 'string', '$$description': ['Relative path to a text file containing the full description', 'of the project.']}}, 'required': ['file']}, rule='required') + data__readme_keys = set(data__readme.keys()) + if "file" in data__readme_keys: + data__readme_keys.remove("file") + data__readme__file = data__readme["file"] + if not isinstance(data__readme__file, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".readme.file must be string", value=data__readme__file, name="" + (name_prefix or "data") + ".readme.file", definition={'type': 'string', '$$description': ['Relative path to a text file containing the full description', 'of the project.']}, rule='type') + data__readme_any_of_count13 += 1 + except JsonSchemaValueException: pass + if not data__readme_any_of_count13: + try: + data__readme_is_dict = isinstance(data__readme, dict) + if data__readme_is_dict: + data__readme__missing_keys = set(['text']) - data__readme.keys() + if data__readme__missing_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".readme must contain " + (str(sorted(data__readme__missing_keys)) + " properties"), value=data__readme, name="" + (name_prefix or "data") + ".readme", definition={'properties': {'text': {'type': 'string', 'description': 'Full text describing the project.'}}, 'required': ['text']}, rule='required') + data__readme_keys = set(data__readme.keys()) + if "text" in data__readme_keys: + data__readme_keys.remove("text") + data__readme__text = data__readme["text"] + if not isinstance(data__readme__text, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".readme.text must be string", value=data__readme__text, name="" + (name_prefix or "data") + ".readme.text", definition={'type': 'string', 'description': 'Full text describing the project.'}, rule='type') + data__readme_any_of_count13 += 1 + except JsonSchemaValueException: pass + if not data__readme_any_of_count13: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".readme cannot be validated by any definition", value=data__readme, name="" + (name_prefix or "data") + ".readme", definition={'anyOf': [{'properties': {'file': {'type': 'string', '$$description': ['Relative path to a text file containing the full description', 'of the project.']}}, 'required': ['file']}, {'properties': {'text': {'type': 'string', 'description': 'Full text describing the project.'}}, 'required': ['text']}]}, rule='anyOf') + data__readme_is_dict = isinstance(data__readme, dict) + if data__readme_is_dict: + data__readme__missing_keys = set(['content-type']) - data__readme.keys() + if data__readme__missing_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".readme must contain " + (str(sorted(data__readme__missing_keys)) + " properties"), value=data__readme, name="" + (name_prefix or "data") + ".readme", definition={'properties': {'content-type': {'type': 'string', '$$description': ['Content-type (:rfc:`1341`) of the full description', '(e.g. ``text/markdown``). The ``charset`` parameter is assumed', 'UTF-8 when not present.'], '$comment': 'TODO: add regex pattern or format?'}}, 'required': ['content-type']}, rule='required') + data__readme_keys = set(data__readme.keys()) + if "content-type" in data__readme_keys: + data__readme_keys.remove("content-type") + data__readme__contenttype = data__readme["content-type"] + if not isinstance(data__readme__contenttype, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".readme.content-type must be string", value=data__readme__contenttype, name="" + (name_prefix or "data") + ".readme.content-type", definition={'type': 'string', '$$description': ['Content-type (:rfc:`1341`) of the full description', '(e.g. ``text/markdown``). The ``charset`` parameter is assumed', 'UTF-8 when not present.'], '$comment': 'TODO: add regex pattern or format?'}, rule='type') + data__readme_one_of_count12 += 1 + except JsonSchemaValueException: pass + if data__readme_one_of_count12 != 1: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".readme must be valid exactly by one definition" + (" (" + str(data__readme_one_of_count12) + " matches found)"), value=data__readme, name="" + (name_prefix or "data") + ".readme", definition={'$$description': ['`Full/detailed description of the project in the form of a README', '<https://peps.python.org/pep-0621/#readme>`_', "with meaning similar to the one defined in `core metadata's Description", '<https://packaging.python.org/specifications/core-metadata/#description>`_'], 'oneOf': [{'type': 'string', '$$description': ['Relative path to a text file (UTF-8) containing the full description', 'of the project. If the file path ends in case-insensitive ``.md`` or', '``.rst`` suffixes, then the content-type is respectively', '``text/markdown`` or ``text/x-rst``']}, {'type': 'object', 'allOf': [{'anyOf': [{'properties': {'file': {'type': 'string', '$$description': ['Relative path to a text file containing the full description', 'of the project.']}}, 'required': ['file']}, {'properties': {'text': {'type': 'string', 'description': 'Full text describing the project.'}}, 'required': ['text']}]}, {'properties': {'content-type': {'type': 'string', '$$description': ['Content-type (:rfc:`1341`) of the full description', '(e.g. ``text/markdown``). The ``charset`` parameter is assumed', 'UTF-8 when not present.'], '$comment': 'TODO: add regex pattern or format?'}}, 'required': ['content-type']}]}]}, rule='oneOf') + if "requires-python" in data_keys: + data_keys.remove("requires-python") + data__requirespython = data["requires-python"] + if not isinstance(data__requirespython, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".requires-python must be string", value=data__requirespython, name="" + (name_prefix or "data") + ".requires-python", definition={'type': 'string', 'format': 'pep508-versionspec', '$$description': ['`The Python version requirements of the project', '<https://packaging.python.org/specifications/core-metadata/#requires-python>`_.']}, rule='type') + if isinstance(data__requirespython, str): + if not custom_formats["pep508-versionspec"](data__requirespython): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".requires-python must be pep508-versionspec", value=data__requirespython, name="" + (name_prefix or "data") + ".requires-python", definition={'type': 'string', 'format': 'pep508-versionspec', '$$description': ['`The Python version requirements of the project', '<https://packaging.python.org/specifications/core-metadata/#requires-python>`_.']}, rule='format') + if "license" in data_keys: + data_keys.remove("license") + data__license = data["license"] + data__license_one_of_count14 = 0 + if data__license_one_of_count14 < 2: + try: + if not isinstance(data__license, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".license must be string", value=data__license, name="" + (name_prefix or "data") + ".license", definition={'type': 'string', 'description': 'An SPDX license identifier', 'format': 'SPDX'}, rule='type') + if isinstance(data__license, str): + if not custom_formats["SPDX"](data__license): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".license must be SPDX", value=data__license, name="" + (name_prefix or "data") + ".license", definition={'type': 'string', 'description': 'An SPDX license identifier', 'format': 'SPDX'}, rule='format') + data__license_one_of_count14 += 1 + except JsonSchemaValueException: pass + if data__license_one_of_count14 < 2: + try: + if not isinstance(data__license, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".license must be object", value=data__license, name="" + (name_prefix or "data") + ".license", definition={'type': 'object', 'properties': {'file': {'type': 'string', '$$description': ['Relative path to the file (UTF-8) which contains the license for the', 'project.']}}, 'required': ['file']}, rule='type') + data__license_is_dict = isinstance(data__license, dict) + if data__license_is_dict: + data__license__missing_keys = set(['file']) - data__license.keys() + if data__license__missing_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".license must contain " + (str(sorted(data__license__missing_keys)) + " properties"), value=data__license, name="" + (name_prefix or "data") + ".license", definition={'type': 'object', 'properties': {'file': {'type': 'string', '$$description': ['Relative path to the file (UTF-8) which contains the license for the', 'project.']}}, 'required': ['file']}, rule='required') + data__license_keys = set(data__license.keys()) + if "file" in data__license_keys: + data__license_keys.remove("file") + data__license__file = data__license["file"] + if not isinstance(data__license__file, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".license.file must be string", value=data__license__file, name="" + (name_prefix or "data") + ".license.file", definition={'type': 'string', '$$description': ['Relative path to the file (UTF-8) which contains the license for the', 'project.']}, rule='type') + data__license_one_of_count14 += 1 + except JsonSchemaValueException: pass + if data__license_one_of_count14 < 2: + try: + if not isinstance(data__license, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".license must be object", value=data__license, name="" + (name_prefix or "data") + ".license", definition={'type': 'object', 'properties': {'text': {'type': 'string', '$$description': ['The license of the project whose meaning is that of the', '`License field from the core metadata', '<https://packaging.python.org/specifications/core-metadata/#license>`_.']}}, 'required': ['text']}, rule='type') + data__license_is_dict = isinstance(data__license, dict) + if data__license_is_dict: + data__license__missing_keys = set(['text']) - data__license.keys() + if data__license__missing_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".license must contain " + (str(sorted(data__license__missing_keys)) + " properties"), value=data__license, name="" + (name_prefix or "data") + ".license", definition={'type': 'object', 'properties': {'text': {'type': 'string', '$$description': ['The license of the project whose meaning is that of the', '`License field from the core metadata', '<https://packaging.python.org/specifications/core-metadata/#license>`_.']}}, 'required': ['text']}, rule='required') + data__license_keys = set(data__license.keys()) + if "text" in data__license_keys: + data__license_keys.remove("text") + data__license__text = data__license["text"] + if not isinstance(data__license__text, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".license.text must be string", value=data__license__text, name="" + (name_prefix or "data") + ".license.text", definition={'type': 'string', '$$description': ['The license of the project whose meaning is that of the', '`License field from the core metadata', '<https://packaging.python.org/specifications/core-metadata/#license>`_.']}, rule='type') + data__license_one_of_count14 += 1 + except JsonSchemaValueException: pass + if data__license_one_of_count14 != 1: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".license must be valid exactly by one definition" + (" (" + str(data__license_one_of_count14) + " matches found)"), value=data__license, name="" + (name_prefix or "data") + ".license", definition={'description': '`Project license <https://peps.python.org/pep-0621/#license>`_.', 'oneOf': [{'type': 'string', 'description': 'An SPDX license identifier', 'format': 'SPDX'}, {'type': 'object', 'properties': {'file': {'type': 'string', '$$description': ['Relative path to the file (UTF-8) which contains the license for the', 'project.']}}, 'required': ['file']}, {'type': 'object', 'properties': {'text': {'type': 'string', '$$description': ['The license of the project whose meaning is that of the', '`License field from the core metadata', '<https://packaging.python.org/specifications/core-metadata/#license>`_.']}}, 'required': ['text']}]}, rule='oneOf') + if "license-files" in data_keys: + data_keys.remove("license-files") + data__licensefiles = data["license-files"] + if not isinstance(data__licensefiles, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".license-files must be array", value=data__licensefiles, name="" + (name_prefix or "data") + ".license-files", definition={'description': 'Paths or globs to paths of license files', 'type': 'array', 'items': {'type': 'string'}}, rule='type') + data__licensefiles_is_list = isinstance(data__licensefiles, (list, tuple)) + if data__licensefiles_is_list: + data__licensefiles_len = len(data__licensefiles) + for data__licensefiles_x, data__licensefiles_item in enumerate(data__licensefiles): + if not isinstance(data__licensefiles_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".license-files[{data__licensefiles_x}]".format(**locals()) + " must be string", value=data__licensefiles_item, name="" + (name_prefix or "data") + ".license-files[{data__licensefiles_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "authors" in data_keys: + data_keys.remove("authors") + data__authors = data["authors"] + if not isinstance(data__authors, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".authors must be array", value=data__authors, name="" + (name_prefix or "data") + ".authors", definition={'type': 'array', 'items': {'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, '$$description': ["The people or organizations considered to be the 'authors' of the project.", 'The exact meaning is open to interpretation (e.g. original or primary authors,', 'current maintainers, or owners of the package).']}, rule='type') + data__authors_is_list = isinstance(data__authors, (list, tuple)) + if data__authors_is_list: + data__authors_len = len(data__authors) + for data__authors_x, data__authors_item in enumerate(data__authors): + validate_https___packaging_python_org_en_latest_specifications_pyproject_toml___definitions_author(data__authors_item, custom_formats, (name_prefix or "data") + ".authors[{data__authors_x}]".format(**locals())) + if "maintainers" in data_keys: + data_keys.remove("maintainers") + data__maintainers = data["maintainers"] + if not isinstance(data__maintainers, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".maintainers must be array", value=data__maintainers, name="" + (name_prefix or "data") + ".maintainers", definition={'type': 'array', 'items': {'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, '$$description': ["The people or organizations considered to be the 'maintainers' of the project.", 'Similarly to ``authors``, the exact meaning is open to interpretation.']}, rule='type') + data__maintainers_is_list = isinstance(data__maintainers, (list, tuple)) + if data__maintainers_is_list: + data__maintainers_len = len(data__maintainers) + for data__maintainers_x, data__maintainers_item in enumerate(data__maintainers): + validate_https___packaging_python_org_en_latest_specifications_pyproject_toml___definitions_author(data__maintainers_item, custom_formats, (name_prefix or "data") + ".maintainers[{data__maintainers_x}]".format(**locals())) + if "keywords" in data_keys: + data_keys.remove("keywords") + data__keywords = data["keywords"] + if not isinstance(data__keywords, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".keywords must be array", value=data__keywords, name="" + (name_prefix or "data") + ".keywords", definition={'type': 'array', 'items': {'type': 'string'}, 'description': 'List of keywords to assist searching for the distribution in a larger catalog.'}, rule='type') + data__keywords_is_list = isinstance(data__keywords, (list, tuple)) + if data__keywords_is_list: + data__keywords_len = len(data__keywords) + for data__keywords_x, data__keywords_item in enumerate(data__keywords): + if not isinstance(data__keywords_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".keywords[{data__keywords_x}]".format(**locals()) + " must be string", value=data__keywords_item, name="" + (name_prefix or "data") + ".keywords[{data__keywords_x}]".format(**locals()) + "", definition={'type': 'string'}, rule='type') + if "classifiers" in data_keys: + data_keys.remove("classifiers") + data__classifiers = data["classifiers"] + if not isinstance(data__classifiers, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".classifiers must be array", value=data__classifiers, name="" + (name_prefix or "data") + ".classifiers", definition={'type': 'array', 'items': {'type': 'string', 'format': 'trove-classifier', 'description': '`PyPI classifier <https://pypi.org/classifiers/>`_.'}, '$$description': ['`Trove classifiers <https://pypi.org/classifiers/>`_', 'which apply to the project.']}, rule='type') + data__classifiers_is_list = isinstance(data__classifiers, (list, tuple)) + if data__classifiers_is_list: + data__classifiers_len = len(data__classifiers) + for data__classifiers_x, data__classifiers_item in enumerate(data__classifiers): + if not isinstance(data__classifiers_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".classifiers[{data__classifiers_x}]".format(**locals()) + " must be string", value=data__classifiers_item, name="" + (name_prefix or "data") + ".classifiers[{data__classifiers_x}]".format(**locals()) + "", definition={'type': 'string', 'format': 'trove-classifier', 'description': '`PyPI classifier <https://pypi.org/classifiers/>`_.'}, rule='type') + if isinstance(data__classifiers_item, str): + if not custom_formats["trove-classifier"](data__classifiers_item): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".classifiers[{data__classifiers_x}]".format(**locals()) + " must be trove-classifier", value=data__classifiers_item, name="" + (name_prefix or "data") + ".classifiers[{data__classifiers_x}]".format(**locals()) + "", definition={'type': 'string', 'format': 'trove-classifier', 'description': '`PyPI classifier <https://pypi.org/classifiers/>`_.'}, rule='format') + if "urls" in data_keys: + data_keys.remove("urls") + data__urls = data["urls"] + if not isinstance(data__urls, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".urls must be object", value=data__urls, name="" + (name_prefix or "data") + ".urls", definition={'type': 'object', 'description': 'URLs associated with the project in the form ``label => value``.', 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', 'format': 'url'}}}, rule='type') + data__urls_is_dict = isinstance(data__urls, dict) + if data__urls_is_dict: + data__urls_keys = set(data__urls.keys()) + for data__urls_key, data__urls_val in data__urls.items(): + if REGEX_PATTERNS['^.+$'].search(data__urls_key): + if data__urls_key in data__urls_keys: + data__urls_keys.remove(data__urls_key) + if not isinstance(data__urls_val, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".urls.{data__urls_key}".format(**locals()) + " must be string", value=data__urls_val, name="" + (name_prefix or "data") + ".urls.{data__urls_key}".format(**locals()) + "", definition={'type': 'string', 'format': 'url'}, rule='type') + if isinstance(data__urls_val, str): + if not custom_formats["url"](data__urls_val): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".urls.{data__urls_key}".format(**locals()) + " must be url", value=data__urls_val, name="" + (name_prefix or "data") + ".urls.{data__urls_key}".format(**locals()) + "", definition={'type': 'string', 'format': 'url'}, rule='format') + if data__urls_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".urls must not contain "+str(data__urls_keys)+" properties", value=data__urls, name="" + (name_prefix or "data") + ".urls", definition={'type': 'object', 'description': 'URLs associated with the project in the form ``label => value``.', 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', 'format': 'url'}}}, rule='additionalProperties') + if "scripts" in data_keys: + data_keys.remove("scripts") + data__scripts = data["scripts"] + validate_https___packaging_python_org_en_latest_specifications_pyproject_toml___definitions_entry_point_group(data__scripts, custom_formats, (name_prefix or "data") + ".scripts") + if "gui-scripts" in data_keys: + data_keys.remove("gui-scripts") + data__guiscripts = data["gui-scripts"] + validate_https___packaging_python_org_en_latest_specifications_pyproject_toml___definitions_entry_point_group(data__guiscripts, custom_formats, (name_prefix or "data") + ".gui-scripts") + if "entry-points" in data_keys: + data_keys.remove("entry-points") + data__entrypoints = data["entry-points"] + data__entrypoints_is_dict = isinstance(data__entrypoints, dict) + if data__entrypoints_is_dict: + data__entrypoints_keys = set(data__entrypoints.keys()) + for data__entrypoints_key, data__entrypoints_val in data__entrypoints.items(): + if REGEX_PATTERNS['^.+$'].search(data__entrypoints_key): + if data__entrypoints_key in data__entrypoints_keys: + data__entrypoints_keys.remove(data__entrypoints_key) + validate_https___packaging_python_org_en_latest_specifications_pyproject_toml___definitions_entry_point_group(data__entrypoints_val, custom_formats, (name_prefix or "data") + ".entry-points.{data__entrypoints_key}".format(**locals())) + if data__entrypoints_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".entry-points must not contain "+str(data__entrypoints_keys)+" properties", value=data__entrypoints, name="" + (name_prefix or "data") + ".entry-points", definition={'$$description': ['Instruct the installer to expose the given modules/functions via', '``entry-point`` discovery mechanism (useful for plugins).', 'More information available in the `Python packaging guide', '<https://packaging.python.org/specifications/entry-points/>`_.'], 'propertyNames': {'format': 'python-entrypoint-group'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}}}, rule='additionalProperties') + data__entrypoints_len = len(data__entrypoints) + if data__entrypoints_len != 0: + data__entrypoints_property_names = True + for data__entrypoints_key in data__entrypoints: + try: + if isinstance(data__entrypoints_key, str): + if not custom_formats["python-entrypoint-group"](data__entrypoints_key): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".entry-points must be python-entrypoint-group", value=data__entrypoints_key, name="" + (name_prefix or "data") + ".entry-points", definition={'format': 'python-entrypoint-group'}, rule='format') + except JsonSchemaValueException: + data__entrypoints_property_names = False + if not data__entrypoints_property_names: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".entry-points must be named by propertyName definition", value=data__entrypoints, name="" + (name_prefix or "data") + ".entry-points", definition={'$$description': ['Instruct the installer to expose the given modules/functions via', '``entry-point`` discovery mechanism (useful for plugins).', 'More information available in the `Python packaging guide', '<https://packaging.python.org/specifications/entry-points/>`_.'], 'propertyNames': {'format': 'python-entrypoint-group'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}}}, rule='propertyNames') + if "dependencies" in data_keys: + data_keys.remove("dependencies") + data__dependencies = data["dependencies"] + if not isinstance(data__dependencies, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dependencies must be array", value=data__dependencies, name="" + (name_prefix or "data") + ".dependencies", definition={'type': 'array', 'description': 'Project (mandatory) dependencies.', 'items': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}, rule='type') + data__dependencies_is_list = isinstance(data__dependencies, (list, tuple)) + if data__dependencies_is_list: + data__dependencies_len = len(data__dependencies) + for data__dependencies_x, data__dependencies_item in enumerate(data__dependencies): + validate_https___packaging_python_org_en_latest_specifications_pyproject_toml___definitions_dependency(data__dependencies_item, custom_formats, (name_prefix or "data") + ".dependencies[{data__dependencies_x}]".format(**locals())) + if "optional-dependencies" in data_keys: + data_keys.remove("optional-dependencies") + data__optionaldependencies = data["optional-dependencies"] + if not isinstance(data__optionaldependencies, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".optional-dependencies must be object", value=data__optionaldependencies, name="" + (name_prefix or "data") + ".optional-dependencies", definition={'type': 'object', 'description': 'Optional dependency for the project', 'propertyNames': {'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'array', 'items': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}}}, rule='type') + data__optionaldependencies_is_dict = isinstance(data__optionaldependencies, dict) + if data__optionaldependencies_is_dict: + data__optionaldependencies_keys = set(data__optionaldependencies.keys()) + for data__optionaldependencies_key, data__optionaldependencies_val in data__optionaldependencies.items(): + if REGEX_PATTERNS['^.+$'].search(data__optionaldependencies_key): + if data__optionaldependencies_key in data__optionaldependencies_keys: + data__optionaldependencies_keys.remove(data__optionaldependencies_key) + if not isinstance(data__optionaldependencies_val, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".optional-dependencies.{data__optionaldependencies_key}".format(**locals()) + " must be array", value=data__optionaldependencies_val, name="" + (name_prefix or "data") + ".optional-dependencies.{data__optionaldependencies_key}".format(**locals()) + "", definition={'type': 'array', 'items': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}, rule='type') + data__optionaldependencies_val_is_list = isinstance(data__optionaldependencies_val, (list, tuple)) + if data__optionaldependencies_val_is_list: + data__optionaldependencies_val_len = len(data__optionaldependencies_val) + for data__optionaldependencies_val_x, data__optionaldependencies_val_item in enumerate(data__optionaldependencies_val): + validate_https___packaging_python_org_en_latest_specifications_pyproject_toml___definitions_dependency(data__optionaldependencies_val_item, custom_formats, (name_prefix or "data") + ".optional-dependencies.{data__optionaldependencies_key}[{data__optionaldependencies_val_x}]".format(**locals())) + if data__optionaldependencies_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".optional-dependencies must not contain "+str(data__optionaldependencies_keys)+" properties", value=data__optionaldependencies, name="" + (name_prefix or "data") + ".optional-dependencies", definition={'type': 'object', 'description': 'Optional dependency for the project', 'propertyNames': {'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'array', 'items': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}}}, rule='additionalProperties') + data__optionaldependencies_len = len(data__optionaldependencies) + if data__optionaldependencies_len != 0: + data__optionaldependencies_property_names = True + for data__optionaldependencies_key in data__optionaldependencies: + try: + if isinstance(data__optionaldependencies_key, str): + if not custom_formats["pep508-identifier"](data__optionaldependencies_key): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".optional-dependencies must be pep508-identifier", value=data__optionaldependencies_key, name="" + (name_prefix or "data") + ".optional-dependencies", definition={'format': 'pep508-identifier'}, rule='format') + except JsonSchemaValueException: + data__optionaldependencies_property_names = False + if not data__optionaldependencies_property_names: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".optional-dependencies must be named by propertyName definition", value=data__optionaldependencies, name="" + (name_prefix or "data") + ".optional-dependencies", definition={'type': 'object', 'description': 'Optional dependency for the project', 'propertyNames': {'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'array', 'items': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}}}, rule='propertyNames') + if "import-names" in data_keys: + data_keys.remove("import-names") + data__importnames = data["import-names"] + if not isinstance(data__importnames, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".import-names must be array", value=data__importnames, name="" + (name_prefix or "data") + ".import-names", definition={'description': 'Lists import names which a project, when installed, would exclusively provide.', 'type': 'array', 'items': {'type': 'string', 'format': 'import-name'}}, rule='type') + data__importnames_is_list = isinstance(data__importnames, (list, tuple)) + if data__importnames_is_list: + data__importnames_len = len(data__importnames) + for data__importnames_x, data__importnames_item in enumerate(data__importnames): + if not isinstance(data__importnames_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".import-names[{data__importnames_x}]".format(**locals()) + " must be string", value=data__importnames_item, name="" + (name_prefix or "data") + ".import-names[{data__importnames_x}]".format(**locals()) + "", definition={'type': 'string', 'format': 'import-name'}, rule='type') + if isinstance(data__importnames_item, str): + if not custom_formats["import-name"](data__importnames_item): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".import-names[{data__importnames_x}]".format(**locals()) + " must be import-name", value=data__importnames_item, name="" + (name_prefix or "data") + ".import-names[{data__importnames_x}]".format(**locals()) + "", definition={'type': 'string', 'format': 'import-name'}, rule='format') + if "import-namespaces" in data_keys: + data_keys.remove("import-namespaces") + data__importnamespaces = data["import-namespaces"] + if not isinstance(data__importnamespaces, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".import-namespaces must be array", value=data__importnamespaces, name="" + (name_prefix or "data") + ".import-namespaces", definition={'description': 'Lists import names that, when installed, would be provided by the project, but not exclusively.', 'type': 'array', 'items': {'type': 'string', 'format': 'import-name'}}, rule='type') + data__importnamespaces_is_list = isinstance(data__importnamespaces, (list, tuple)) + if data__importnamespaces_is_list: + data__importnamespaces_len = len(data__importnamespaces) + for data__importnamespaces_x, data__importnamespaces_item in enumerate(data__importnamespaces): + if not isinstance(data__importnamespaces_item, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".import-namespaces[{data__importnamespaces_x}]".format(**locals()) + " must be string", value=data__importnamespaces_item, name="" + (name_prefix or "data") + ".import-namespaces[{data__importnamespaces_x}]".format(**locals()) + "", definition={'type': 'string', 'format': 'import-name'}, rule='type') + if isinstance(data__importnamespaces_item, str): + if not custom_formats["import-name"](data__importnamespaces_item): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".import-namespaces[{data__importnamespaces_x}]".format(**locals()) + " must be import-name", value=data__importnamespaces_item, name="" + (name_prefix or "data") + ".import-namespaces[{data__importnamespaces_x}]".format(**locals()) + "", definition={'type': 'string', 'format': 'import-name'}, rule='format') + if "dynamic" in data_keys: + data_keys.remove("dynamic") + data__dynamic = data["dynamic"] + if not isinstance(data__dynamic, (list, tuple)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic must be array", value=data__dynamic, name="" + (name_prefix or "data") + ".dynamic", definition={'type': 'array', '$$description': ['Specifies which fields are intentionally unspecified and expected to be', 'dynamically provided by build tools'], 'items': {'enum': ['version', 'description', 'readme', 'requires-python', 'license', 'license-files', 'authors', 'maintainers', 'keywords', 'classifiers', 'urls', 'scripts', 'gui-scripts', 'entry-points', 'dependencies', 'optional-dependencies', 'import-names', 'import-namespaces']}}, rule='type') + data__dynamic_is_list = isinstance(data__dynamic, (list, tuple)) + if data__dynamic_is_list: + data__dynamic_len = len(data__dynamic) + for data__dynamic_x, data__dynamic_item in enumerate(data__dynamic): + if data__dynamic_item not in ['version', 'description', 'readme', 'requires-python', 'license', 'license-files', 'authors', 'maintainers', 'keywords', 'classifiers', 'urls', 'scripts', 'gui-scripts', 'entry-points', 'dependencies', 'optional-dependencies', 'import-names', 'import-namespaces']: + raise JsonSchemaValueException("" + (name_prefix or "data") + ".dynamic[{data__dynamic_x}]".format(**locals()) + " must be one of ['version', 'description', 'readme', 'requires-python', 'license', 'license-files', 'authors', 'maintainers', 'keywords', 'classifiers', 'urls', 'scripts', 'gui-scripts', 'entry-points', 'dependencies', 'optional-dependencies', 'import-names', 'import-namespaces']", value=data__dynamic_item, name="" + (name_prefix or "data") + ".dynamic[{data__dynamic_x}]".format(**locals()) + "", definition={'enum': ['version', 'description', 'readme', 'requires-python', 'license', 'license-files', 'authors', 'maintainers', 'keywords', 'classifiers', 'urls', 'scripts', 'gui-scripts', 'entry-points', 'dependencies', 'optional-dependencies', 'import-names', 'import-namespaces']}, rule='enum') + if data_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must not contain "+str(data_keys)+" properties", value=data, name="" + (name_prefix or "data") + "", definition={'$schema': 'http://json-schema.org/draft-07/schema#', '$id': 'https://packaging.python.org/en/latest/specifications/pyproject-toml/', 'title': 'Package metadata stored in the ``project`` table', '$$description': ['Data structure for the **project** table inside ``pyproject.toml``', '(as initially defined in :pep:`621`)'], 'type': 'object', 'properties': {'name': {'type': 'string', 'description': 'The name (primary identifier) of the project. MUST be statically defined.', 'format': 'pep508-identifier'}, 'version': {'type': 'string', 'description': 'The version of the project as supported by :pep:`440`.', 'format': 'pep440'}, 'description': {'type': 'string', '$$description': ['The `summary description of the project', '<https://packaging.python.org/specifications/core-metadata/#summary>`_']}, 'readme': {'$$description': ['`Full/detailed description of the project in the form of a README', '<https://peps.python.org/pep-0621/#readme>`_', "with meaning similar to the one defined in `core metadata's Description", '<https://packaging.python.org/specifications/core-metadata/#description>`_'], 'oneOf': [{'type': 'string', '$$description': ['Relative path to a text file (UTF-8) containing the full description', 'of the project. If the file path ends in case-insensitive ``.md`` or', '``.rst`` suffixes, then the content-type is respectively', '``text/markdown`` or ``text/x-rst``']}, {'type': 'object', 'allOf': [{'anyOf': [{'properties': {'file': {'type': 'string', '$$description': ['Relative path to a text file containing the full description', 'of the project.']}}, 'required': ['file']}, {'properties': {'text': {'type': 'string', 'description': 'Full text describing the project.'}}, 'required': ['text']}]}, {'properties': {'content-type': {'type': 'string', '$$description': ['Content-type (:rfc:`1341`) of the full description', '(e.g. ``text/markdown``). The ``charset`` parameter is assumed', 'UTF-8 when not present.'], '$comment': 'TODO: add regex pattern or format?'}}, 'required': ['content-type']}]}]}, 'requires-python': {'type': 'string', 'format': 'pep508-versionspec', '$$description': ['`The Python version requirements of the project', '<https://packaging.python.org/specifications/core-metadata/#requires-python>`_.']}, 'license': {'description': '`Project license <https://peps.python.org/pep-0621/#license>`_.', 'oneOf': [{'type': 'string', 'description': 'An SPDX license identifier', 'format': 'SPDX'}, {'type': 'object', 'properties': {'file': {'type': 'string', '$$description': ['Relative path to the file (UTF-8) which contains the license for the', 'project.']}}, 'required': ['file']}, {'type': 'object', 'properties': {'text': {'type': 'string', '$$description': ['The license of the project whose meaning is that of the', '`License field from the core metadata', '<https://packaging.python.org/specifications/core-metadata/#license>`_.']}}, 'required': ['text']}]}, 'license-files': {'description': 'Paths or globs to paths of license files', 'type': 'array', 'items': {'type': 'string'}}, 'authors': {'type': 'array', 'items': {'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, '$$description': ["The people or organizations considered to be the 'authors' of the project.", 'The exact meaning is open to interpretation (e.g. original or primary authors,', 'current maintainers, or owners of the package).']}, 'maintainers': {'type': 'array', 'items': {'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, '$$description': ["The people or organizations considered to be the 'maintainers' of the project.", 'Similarly to ``authors``, the exact meaning is open to interpretation.']}, 'keywords': {'type': 'array', 'items': {'type': 'string'}, 'description': 'List of keywords to assist searching for the distribution in a larger catalog.'}, 'classifiers': {'type': 'array', 'items': {'type': 'string', 'format': 'trove-classifier', 'description': '`PyPI classifier <https://pypi.org/classifiers/>`_.'}, '$$description': ['`Trove classifiers <https://pypi.org/classifiers/>`_', 'which apply to the project.']}, 'urls': {'type': 'object', 'description': 'URLs associated with the project in the form ``label => value``.', 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', 'format': 'url'}}}, 'scripts': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}, 'gui-scripts': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}, 'entry-points': {'$$description': ['Instruct the installer to expose the given modules/functions via', '``entry-point`` discovery mechanism (useful for plugins).', 'More information available in the `Python packaging guide', '<https://packaging.python.org/specifications/entry-points/>`_.'], 'propertyNames': {'format': 'python-entrypoint-group'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}}}, 'dependencies': {'type': 'array', 'description': 'Project (mandatory) dependencies.', 'items': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}, 'optional-dependencies': {'type': 'object', 'description': 'Optional dependency for the project', 'propertyNames': {'format': 'pep508-identifier'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'array', 'items': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}}}, 'import-names': {'description': 'Lists import names which a project, when installed, would exclusively provide.', 'type': 'array', 'items': {'type': 'string', 'format': 'import-name'}}, 'import-namespaces': {'description': 'Lists import names that, when installed, would be provided by the project, but not exclusively.', 'type': 'array', 'items': {'type': 'string', 'format': 'import-name'}}, 'dynamic': {'type': 'array', '$$description': ['Specifies which fields are intentionally unspecified and expected to be', 'dynamically provided by build tools'], 'items': {'enum': ['version', 'description', 'readme', 'requires-python', 'license', 'license-files', 'authors', 'maintainers', 'keywords', 'classifiers', 'urls', 'scripts', 'gui-scripts', 'entry-points', 'dependencies', 'optional-dependencies', 'import-names', 'import-namespaces']}}}, 'required': ['name'], 'additionalProperties': False, 'allOf': [{'if': {'not': {'required': ['dynamic'], 'properties': {'dynamic': {'contains': {'const': 'version'}, '$$description': ['version is listed in ``dynamic``']}}}, '$$comment': ['According to :pep:`621`:', ' If the core metadata specification lists a field as "Required", then', ' the metadata MUST specify the field statically or list it in dynamic', 'In turn, `core metadata`_ defines:', ' The required fields are: Metadata-Version, Name, Version.', ' All the other fields are optional.', 'Since ``Metadata-Version`` is defined by the build back-end, ``name`` and', '``version`` are the only mandatory information in ``pyproject.toml``.', '.. _core metadata: https://packaging.python.org/specifications/core-metadata/']}, 'then': {'required': ['version'], '$$description': ['version should be statically defined in the ``version`` field']}}, {'if': {'required': ['license-files']}, 'then': {'properties': {'license': {'type': 'string'}}}}], 'definitions': {'author': {'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, 'entry-point-group': {'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}, 'dependency': {'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}}}, rule='additionalProperties') + return data + +def validate_https___packaging_python_org_en_latest_specifications_pyproject_toml___definitions_dependency(data, custom_formats={}, name_prefix=None): + if not isinstance(data, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be string", value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}, rule='type') + if isinstance(data, str): + if not custom_formats["pep508"](data): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be pep508", value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/dependency', 'title': 'Dependency', 'type': 'string', 'description': 'Project dependency specification according to PEP 508', 'format': 'pep508'}, rule='format') + return data + +def validate_https___packaging_python_org_en_latest_specifications_pyproject_toml___definitions_entry_point_group(data, custom_formats={}, name_prefix=None): + if not isinstance(data, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be object", value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}, rule='type') + data_is_dict = isinstance(data, dict) + if data_is_dict: + data_keys = set(data.keys()) + for data_key, data_val in data.items(): + if REGEX_PATTERNS['^.+$'].search(data_key): + if data_key in data_keys: + data_keys.remove(data_key) + if not isinstance(data_val, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".{data_key}".format(**locals()) + " must be string", value=data_val, name="" + (name_prefix or "data") + ".{data_key}".format(**locals()) + "", definition={'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}, rule='type') + if isinstance(data_val, str): + if not custom_formats["python-entrypoint-reference"](data_val): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".{data_key}".format(**locals()) + " must be python-entrypoint-reference", value=data_val, name="" + (name_prefix or "data") + ".{data_key}".format(**locals()) + "", definition={'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}, rule='format') + if data_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must not contain "+str(data_keys)+" properties", value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}, rule='additionalProperties') + data_len = len(data) + if data_len != 0: + data_property_names = True + for data_key in data: + try: + if isinstance(data_key, str): + if not custom_formats["python-entrypoint-name"](data_key): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be python-entrypoint-name", value=data_key, name="" + (name_prefix or "data") + "", definition={'format': 'python-entrypoint-name'}, rule='format') + except JsonSchemaValueException: + data_property_names = False + if not data_property_names: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be named by propertyName definition", value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/entry-point-group', 'title': 'Entry-points', 'type': 'object', '$$description': ['Entry-points are grouped together to indicate what sort of capabilities they', 'provide.', 'See the `packaging guides', '<https://packaging.python.org/specifications/entry-points/>`_', 'and `setuptools docs', '<https://setuptools.pypa.io/en/latest/userguide/entry_point.html>`_', 'for more information.'], 'propertyNames': {'format': 'python-entrypoint-name'}, 'additionalProperties': False, 'patternProperties': {'^.+$': {'type': 'string', '$$description': ['Reference to a Python object. It is either in the form', '``importable.module``, or ``importable.module:object.attr``.'], 'format': 'python-entrypoint-reference', '$comment': 'https://packaging.python.org/specifications/entry-points/'}}}, rule='propertyNames') + return data + +def validate_https___packaging_python_org_en_latest_specifications_pyproject_toml___definitions_author(data, custom_formats={}, name_prefix=None): + if not isinstance(data, (dict)): + raise JsonSchemaValueException("" + (name_prefix or "data") + " must be object", value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, rule='type') + data_any_of_count15 = 0 + if not data_any_of_count15: + try: + data_is_dict = isinstance(data, dict) + if data_is_dict: + data__missing_keys = set(['name']) - data.keys() + if data__missing_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must contain " + (str(sorted(data__missing_keys)) + " properties"), value=data, name="" + (name_prefix or "data") + "", definition={'required': ['name']}, rule='required') + data_any_of_count15 += 1 + except JsonSchemaValueException: pass + if not data_any_of_count15: + try: + data_is_dict = isinstance(data, dict) + if data_is_dict: + data__missing_keys = set(['email']) - data.keys() + if data__missing_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must contain " + (str(sorted(data__missing_keys)) + " properties"), value=data, name="" + (name_prefix or "data") + "", definition={'required': ['email']}, rule='required') + data_any_of_count15 += 1 + except JsonSchemaValueException: pass + if not data_any_of_count15: + raise JsonSchemaValueException("" + (name_prefix or "data") + " cannot be validated by any definition", value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, rule='anyOf') + data_is_dict = isinstance(data, dict) + if data_is_dict: + data_keys = set(data.keys()) + if "name" in data_keys: + data_keys.remove("name") + data__name = data["name"] + if not isinstance(data__name, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".name must be string", value=data__name, name="" + (name_prefix or "data") + ".name", definition={'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, rule='type') + if "email" in data_keys: + data_keys.remove("email") + data__email = data["email"] + if not isinstance(data__email, (str)): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".email must be string", value=data__email, name="" + (name_prefix or "data") + ".email", definition={'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}, rule='type') + if isinstance(data__email, str): + if not REGEX_PATTERNS["idn-email_re_pattern"].match(data__email): + raise JsonSchemaValueException("" + (name_prefix or "data") + ".email must be idn-email", value=data__email, name="" + (name_prefix or "data") + ".email", definition={'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}, rule='format') + if data_keys: + raise JsonSchemaValueException("" + (name_prefix or "data") + " must not contain "+str(data_keys)+" properties", value=data, name="" + (name_prefix or "data") + "", definition={'$id': '#/definitions/author', 'title': 'Author or Maintainer', '$comment': 'https://peps.python.org/pep-0621/#authors-maintainers', 'type': 'object', 'additionalProperties': False, 'properties': {'name': {'type': 'string', '$$description': ['MUST be a valid email name, i.e. whatever can be put as a name, before an', 'email, in :rfc:`822`.']}, 'email': {'type': 'string', 'format': 'idn-email', 'description': 'MUST be a valid email address'}}, 'anyOf': [{'required': ['name']}, {'required': ['email']}]}, rule='additionalProperties') + return data diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/formats.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/formats.py new file mode 100644 index 0000000000000000000000000000000000000000..fe958cc52a4a6477686231a6bfe4cb8c15357162 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/config/_validate_pyproject/formats.py @@ -0,0 +1,464 @@ +""" +The functions in this module are used to validate schemas with the +`format JSON Schema keyword +<https://json-schema.org/understanding-json-schema/reference/string#format>`_. + +The correspondence is given by replacing the ``_`` character in the name of the +function with a ``-`` to obtain the format name and vice versa. +""" + +from __future__ import annotations + +import keyword +import logging +import os +import re +import string +import typing +from itertools import chain as _chain + +if typing.TYPE_CHECKING: + import builtins + + from typing_extensions import Literal + +_logger = logging.getLogger(__name__) + +# ------------------------------------------------------------------------------------- +# PEP 440 + +VERSION_PATTERN = r""" + v? + (?: + (?:(?P<epoch>[0-9]+)!)? # epoch + (?P<release>[0-9]+(?:\.[0-9]+)*) # release segment + (?P<pre> # pre-release + [-_\.]? + (?P<pre_l>alpha|a|beta|b|preview|pre|c|rc) + [-_\.]? + (?P<pre_n>[0-9]+)? + )? + (?P<post> # post release + (?:-(?P<post_n1>[0-9]+)) + | + (?: + [-_\.]? + (?P<post_l>post|rev|r) + [-_\.]? + (?P<post_n2>[0-9]+)? + ) + )? + (?P<dev> # dev release + [-_\.]? + (?P<dev_l>dev) + [-_\.]? + (?P<dev_n>[0-9]+)? + )? + ) + (?:\+(?P<local>[a-z0-9]+(?:[-_\.][a-z0-9]+)*))? # local version +""" + +VERSION_REGEX = re.compile( + r"^\s*" + VERSION_PATTERN + r"\s*$", re.VERBOSE | re.IGNORECASE +) + + +def pep440(version: str) -> bool: + """See :ref:`PyPA's version specification <pypa:version-specifiers>` + (initially introduced in :pep:`440`). + """ + return VERSION_REGEX.match(version) is not None + + +# ------------------------------------------------------------------------------------- +# PEP 508 + +PEP508_IDENTIFIER_PATTERN = r"([A-Z0-9]|[A-Z0-9][A-Z0-9._-]*[A-Z0-9])" +PEP508_IDENTIFIER_REGEX = re.compile(f"^{PEP508_IDENTIFIER_PATTERN}$", re.IGNORECASE) + + +def pep508_identifier(name: str) -> bool: + """See :ref:`PyPA's name specification <pypa:name-format>` + (initially introduced in :pep:`508#names`). + """ + return PEP508_IDENTIFIER_REGEX.match(name) is not None + + +try: + try: + from packaging import requirements as _req + except ImportError: # pragma: no cover + # let's try setuptools vendored version + from setuptools._vendor.packaging import ( # type: ignore[no-redef] + requirements as _req, + ) + + def pep508(value: str) -> bool: + """See :ref:`PyPA's dependency specifiers <pypa:dependency-specifiers>` + (initially introduced in :pep:`508`). + """ + try: + _req.Requirement(value) + except _req.InvalidRequirement: + return False + return True + +except ImportError: # pragma: no cover + _logger.warning( + "Could not find an installation of `packaging`. Requirements, dependencies and " + "versions might not be validated. " + "To enforce validation, please install `packaging`." + ) + + def pep508(value: str) -> bool: # noqa: ARG001 + return True + + +def pep508_versionspec(value: str) -> bool: + """Expression that can be used to specify/lock versions (including ranges) + See ``versionspec`` in :ref:`PyPA's dependency specifiers + <pypa:dependency-specifiers>` (initially introduced in :pep:`508`). + """ + if any(c in value for c in (";", "]", "@")): + # In PEP 508: + # conditional markers, extras and URL specs are not included in the + # versionspec + return False + # Let's pretend we have a dependency called `requirement` with the given + # version spec, then we can reuse the pep508 function for validation: + return pep508(f"requirement{value}") + + +# ------------------------------------------------------------------------------------- +# PEP 517 + + +def pep517_backend_reference(value: str) -> bool: + """See PyPA's specification for defining build-backend references + introduced in :pep:`517#source-trees`. + + This is similar to an entry-point reference (e.g., ``package.module:object``). + """ + module, _, obj = value.partition(":") + identifiers = (i.strip() for i in _chain(module.split("."), obj.split("."))) + return all(python_identifier(i) for i in identifiers if i) + + +# ------------------------------------------------------------------------------------- +# Classifiers - PEP 301 + + +def _download_classifiers() -> str: + import ssl + from email.message import Message + from urllib.request import urlopen + + url = "https://pypi.org/pypi?:action=list_classifiers" + context = ssl.create_default_context() + with urlopen(url, context=context) as response: # noqa: S310 (audit URLs) + headers = Message() + headers["content_type"] = response.getheader("content-type", "text/plain") + return response.read().decode(headers.get_param("charset", "utf-8")) # type: ignore[no-any-return] + + +class _TroveClassifier: + """The ``trove_classifiers`` package is the official way of validating classifiers, + however this package might not be always available. + As a workaround we can still download a list from PyPI. + We also don't want to be over strict about it, so simply skipping silently is an + option (classifiers will be validated anyway during the upload to PyPI). + """ + + downloaded: None | Literal[False] | set[str] + """ + None => not cached yet + False => unavailable + set => cached values + """ + + def __init__(self) -> None: + self.downloaded = None + self._skip_download = False + self.__name__ = "trove_classifier" # Emulate a public function + + def _disable_download(self) -> None: + # This is a private API. Only setuptools has the consent of using it. + self._skip_download = True + + def __call__(self, value: str) -> bool: + if self.downloaded is False or self._skip_download is True: + return True + + if os.getenv("NO_NETWORK") or os.getenv("VALIDATE_PYPROJECT_NO_NETWORK"): + self.downloaded = False + msg = ( + "Install ``trove-classifiers`` to ensure proper validation. " + "Skipping download of classifiers list from PyPI (NO_NETWORK)." + ) + _logger.debug(msg) + return True + + if self.downloaded is None: + msg = ( + "Install ``trove-classifiers`` to ensure proper validation. " + "Meanwhile a list of classifiers will be downloaded from PyPI." + ) + _logger.debug(msg) + try: + self.downloaded = set(_download_classifiers().splitlines()) + except Exception: # noqa: BLE001 + self.downloaded = False + _logger.debug("Problem with download, skipping validation") + return True + + return value in self.downloaded or value.lower().startswith("private ::") + + +try: + from trove_classifiers import classifiers as _trove_classifiers + + def trove_classifier(value: str) -> bool: + """See https://pypi.org/classifiers/""" + return value in _trove_classifiers or value.lower().startswith("private ::") + +except ImportError: # pragma: no cover + trove_classifier = _TroveClassifier() + + +# ------------------------------------------------------------------------------------- +# Stub packages - PEP 561 + + +def pep561_stub_name(value: str) -> bool: + """Name of a directory containing type stubs. + It must follow the name scheme ``<package>-stubs`` as defined in + :pep:`561#stub-only-packages`. + """ + top, *children = value.split(".") + if not top.endswith("-stubs"): + return False + return python_module_name(".".join([top[: -len("-stubs")], *children])) + + +# ------------------------------------------------------------------------------------- +# Non-PEP related + + +def url(value: str) -> bool: + """Valid URL (validation uses :obj:`urllib.parse`). + For maximum compatibility please make sure to include a ``scheme`` prefix + in your URL (e.g. ``http://``). + """ + from urllib.parse import urlparse + + try: + parts = urlparse(value) + if not parts.scheme: + _logger.warning( + "For maximum compatibility please make sure to include a " + "`scheme` prefix in your URL (e.g. 'http://'). " + f"Given value: {value}" + ) + if not (value.startswith(("/", "\\")) or "@" in value): + parts = urlparse(f"http://{value}") + + return bool(parts.scheme and parts.netloc) + except Exception: # noqa: BLE001 + return False + + +# https://packaging.python.org/specifications/entry-points/ +ENTRYPOINT_PATTERN = r"[^\[\s=]([^=]*[^\s=])?" +ENTRYPOINT_REGEX = re.compile(f"^{ENTRYPOINT_PATTERN}$", re.IGNORECASE) +RECOMMEDED_ENTRYPOINT_PATTERN = r"[\w.-]+" +RECOMMEDED_ENTRYPOINT_REGEX = re.compile( + f"^{RECOMMEDED_ENTRYPOINT_PATTERN}$", re.IGNORECASE +) +ENTRYPOINT_GROUP_PATTERN = r"\w+(\.\w+)*" +ENTRYPOINT_GROUP_REGEX = re.compile(f"^{ENTRYPOINT_GROUP_PATTERN}$", re.IGNORECASE) + + +def python_identifier(value: str) -> bool: + """Can be used as identifier in Python. + (Validation uses :obj:`str.isidentifier`). + """ + return value.isidentifier() + + +def python_qualified_identifier(value: str) -> bool: + """ + Python "dotted identifier", i.e. a sequence of :obj:`python_identifier` + concatenated with ``"."`` (e.g.: ``package.module.submodule``). + """ + if value.startswith(".") or value.endswith("."): + return False + return all(python_identifier(m) for m in value.split(".")) + + +def python_module_name(value: str) -> bool: + """Module name that can be used in an ``import``-statement in Python. + See :obj:`python_qualified_identifier`. + """ + return python_qualified_identifier(value) + + +def python_module_name_relaxed(value: str) -> bool: + """Similar to :obj:`python_module_name`, but relaxed to also accept + dash characters (``-``) and cover special cases like ``pip-run``. + + It is recommended, however, that beginners avoid dash characters, + as they require advanced knowledge about Python internals. + + The following are disallowed: + + * names starting/ending in dashes, + * names ending in ``-stubs`` (potentially collide with :obj:`pep561_stub_name`). + """ + if value.startswith("-") or value.endswith("-"): + return False + if value.endswith("-stubs"): + return False # Avoid collision with PEP 561 + return python_module_name(value.replace("-", "_")) + + +def python_entrypoint_group(value: str) -> bool: + """See ``Data model > group`` in the :ref:`PyPA's entry-points specification + <pypa:entry-points>`. + """ + return ENTRYPOINT_GROUP_REGEX.match(value) is not None + + +def python_entrypoint_name(value: str) -> bool: + """See ``Data model > name`` in the :ref:`PyPA's entry-points specification + <pypa:entry-points>`. + """ + if not ENTRYPOINT_REGEX.match(value): + return False + if not RECOMMEDED_ENTRYPOINT_REGEX.match(value): + msg = f"Entry point `{value}` does not follow recommended pattern: " + msg += RECOMMEDED_ENTRYPOINT_PATTERN + _logger.warning(msg) + return True + + +def python_entrypoint_reference(value: str) -> bool: + """Reference to a Python object using in the format:: + + importable.module:object.attr + + See ``Data model >object reference`` in the :ref:`PyPA's entry-points specification + <pypa:entry-points>`. + """ + module, _, rest = value.partition(":") + if "[" in rest: + obj, _, extras_ = rest.partition("[") + if extras_.strip()[-1] != "]": + return False + extras = (x.strip() for x in extras_.strip(string.whitespace + "[]").split(",")) + if not all(pep508_identifier(e) for e in extras): + return False + _logger.warning(f"`{value}` - using extras for entry points is not recommended") + else: + obj = rest + + module_parts = module.split(".") + identifiers = _chain(module_parts, obj.split(".")) if rest else iter(module_parts) + return all(python_identifier(i.strip()) for i in identifiers) + + +def uint8(value: builtins.int) -> bool: + r"""Unsigned 8-bit integer (:math:`0 \leq x < 2^8`)""" + return 0 <= value < 2**8 + + +def uint16(value: builtins.int) -> bool: + r"""Unsigned 16-bit integer (:math:`0 \leq x < 2^{16}`)""" + return 0 <= value < 2**16 + + +def uint32(value: builtins.int) -> bool: + r"""Unsigned 32-bit integer (:math:`0 \leq x < 2^{32}`)""" + return 0 <= value < 2**32 + + +def uint64(value: builtins.int) -> bool: + r"""Unsigned 64-bit integer (:math:`0 \leq x < 2^{64}`)""" + return 0 <= value < 2**64 + + +def uint(value: builtins.int) -> bool: + r"""Signed 64-bit integer (:math:`0 \leq x < 2^{64}`)""" + return 0 <= value < 2**64 + + +def int8(value: builtins.int) -> bool: + r"""Signed 8-bit integer (:math:`-2^{7} \leq x < 2^{7}`)""" + return -(2**7) <= value < 2**7 + + +def int16(value: builtins.int) -> bool: + r"""Signed 16-bit integer (:math:`-2^{15} \leq x < 2^{15}`)""" + return -(2**15) <= value < 2**15 + + +def int32(value: builtins.int) -> bool: + r"""Signed 32-bit integer (:math:`-2^{31} \leq x < 2^{31}`)""" + return -(2**31) <= value < 2**31 + + +def int64(value: builtins.int) -> bool: + r"""Signed 64-bit integer (:math:`-2^{63} \leq x < 2^{63}`)""" + return -(2**63) <= value < 2**63 + + +def int(value: builtins.int) -> bool: + r"""Signed 64-bit integer (:math:`-2^{63} \leq x < 2^{63}`)""" + return -(2**63) <= value < 2**63 + + +try: + from packaging import licenses as _licenses + + def SPDX(value: str) -> bool: + """See :ref:`PyPA's License-Expression specification + <pypa:core-metadata-license-expression>` (added in :pep:`639`). + """ + try: + _licenses.canonicalize_license_expression(value) + except _licenses.InvalidLicenseExpression: + return False + return True + +except ImportError: # pragma: no cover + _logger.warning( + "Could not find an up-to-date installation of `packaging`. " + "License expressions might not be validated. " + "To enforce validation, please install `packaging>=24.2`." + ) + + def SPDX(value: str) -> bool: # noqa: ARG001 + return True + + +VALID_IMPORT_NAME = re.compile( + r""" + ^ # start of string + [A-Za-z_][A-Za-z_0-9]+ # a valid Python identifier + (?:\.[A-Za-z_][A-Za-z_0-9]*)* # optionally followed by .identifier's + (?:\s*;\s*private)? # optionally followed by ; private + $ # end of string + """, + re.VERBOSE, +) + + +def import_name(value: str) -> bool: + """This is a valid import name. It has to be series of python identifiers + (not keywords), separated by dots, optionally followed by a semicolon and + the keyword "private". + """ + if VALID_IMPORT_NAME.match(value) is None: + return False + + idents, _, _ = value.partition(";") + return all(not keyword.iskeyword(ident) for ident in idents.rstrip().split(".")) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/compat/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/compat/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/compat/py39.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/compat/py39.py new file mode 100644 index 0000000000000000000000000000000000000000..1fdb9dac1fa3f121a634082515d1a305fc09793c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/compat/py39.py @@ -0,0 +1,3 @@ +from jaraco.test.cpython import from_test_support, try_import + +os_helper = try_import('os_helper') or from_test_support('can_symlink') diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/downloads/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/downloads/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..00a16423f448e7773f5e6dc9b365efe80f40a778 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/downloads/__init__.py @@ -0,0 +1,59 @@ +from __future__ import annotations + +import re +import time +from pathlib import Path +from urllib.error import HTTPError +from urllib.request import urlopen + +__all__ = ["DOWNLOAD_DIR", "retrieve_file", "output_file", "urls_from_file"] + + +NAME_REMOVE = ("http://", "https://", "github.com/", "/raw/") +DOWNLOAD_DIR = Path(__file__).parent + + +# ---------------------------------------------------------------------- +# Please update ./preload.py accordingly when modifying this file +# ---------------------------------------------------------------------- + + +def output_file(url: str, download_dir: Path = DOWNLOAD_DIR) -> Path: + file_name = url.strip() + for part in NAME_REMOVE: + file_name = file_name.replace(part, '').strip().strip('/:').strip() + return Path(download_dir, re.sub(r"[^\-_\.\w\d]+", "_", file_name)) + + +def retrieve_file(url: str, download_dir: Path = DOWNLOAD_DIR, wait: float = 5) -> Path: + path = output_file(url, download_dir) + if path.exists(): + print(f"Skipping {url} (already exists: {path})") + else: + download_dir.mkdir(exist_ok=True, parents=True) + print(f"Downloading {url} to {path}") + try: + download(url, path) + except HTTPError: + time.sleep(wait) # wait a few seconds and try again. + download(url, path) + return path + + +def urls_from_file(list_file: Path) -> list[str]: + """``list_file`` should be a text file where each line corresponds to a URL to + download. + """ + print(f"file: {list_file}") + content = list_file.read_text(encoding="utf-8") + return [url for url in content.splitlines() if not url.startswith("#")] + + +def download(url: str, dest: Path): + with urlopen(url) as f: + data = f.read() + + with open(dest, "wb") as f: + f.write(data) + + assert Path(dest).exists() diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/downloads/preload.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/downloads/preload.py new file mode 100644 index 0000000000000000000000000000000000000000..8eeb5dd75d3dcb375cee5acaf11ad385084bff5a --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/downloads/preload.py @@ -0,0 +1,18 @@ +"""This file can be used to preload files needed for testing. + +For example you can use:: + + cd setuptools/tests/config + python -m downloads.preload setupcfg_examples.txt + +to make sure the `setup.cfg` examples are downloaded before starting the tests. +""" + +import sys +from pathlib import Path + +from . import retrieve_file, urls_from_file + +if __name__ == "__main__": + urls = urls_from_file(Path(sys.argv[1])) + list(map(retrieve_file, urls)) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/setupcfg_examples.txt b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/setupcfg_examples.txt new file mode 100644 index 0000000000000000000000000000000000000000..6aab887ff1fe631d97f1abea90a8448040746a12 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/setupcfg_examples.txt @@ -0,0 +1,22 @@ +# ==================================================================== +# Some popular packages that use setup.cfg (and others not so popular) +# Reference: https://hugovk.github.io/top-pypi-packages/ +# ==================================================================== +https://github.com/pypa/setuptools/raw/52c990172fec37766b3566679724aa8bf70ae06d/setup.cfg +https://github.com/pypa/wheel/raw/0acd203cd896afec7f715aa2ff5980a403459a3b/setup.cfg +https://github.com/python/importlib_metadata/raw/2f05392ca980952a6960d82b2f2d2ea10aa53239/setup.cfg +https://github.com/jaraco/skeleton/raw/d9008b5c510cd6969127a6a2ab6f832edddef296/setup.cfg +https://github.com/jaraco/zipp/raw/700d3a96390e970b6b962823bfea78b4f7e1c537/setup.cfg +https://github.com/pallets/jinja/raw/7d72eb7fefb7dce065193967f31f805180508448/setup.cfg +https://github.com/tkem/cachetools/raw/2fd87a94b8d3861d80e9e4236cd480bfdd21c90d/setup.cfg +https://github.com/aio-libs/aiohttp/raw/5e0e6b7080f2408d5f1dd544c0e1cf88378b7b10/setup.cfg +https://github.com/pallets/flask/raw/9486b6cf57bd6a8a261f67091aca8ca78eeec1e3/setup.cfg +https://github.com/pallets/click/raw/6411f425fae545f42795665af4162006b36c5e4a/setup.cfg +https://github.com/sqlalchemy/sqlalchemy/raw/533f5718904b620be8d63f2474229945d6f8ba5d/setup.cfg +https://github.com/pytest-dev/pluggy/raw/461ef63291d13589c4e21aa182cd1529257e9a0a/setup.cfg +https://github.com/pytest-dev/pytest/raw/c7be96dae487edbd2f55b561b31b68afac1dabe6/setup.cfg +https://github.com/platformdirs/platformdirs/raw/7b7852128dd6f07511b618d6edea35046bd0c6ff/setup.cfg +https://github.com/pandas-dev/pandas/raw/bc17343f934a33dc231c8c74be95d8365537c376/setup.cfg +https://github.com/django/django/raw/4e249d11a6e56ca8feb4b055b681cec457ef3a3d/setup.cfg +https://github.com/pyscaffold/pyscaffold/raw/de7aa5dc059fbd04307419c667cc4961bc9df4b8/setup.cfg +https://github.com/pypa/virtualenv/raw/f92eda6e3da26a4d28c2663ffb85c4960bdb990c/setup.cfg diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/test_apply_pyprojecttoml.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/test_apply_pyprojecttoml.py new file mode 100644 index 0000000000000000000000000000000000000000..b6b21a3e9bb176b06208a1e9d4c6424aa77d0e82 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/test_apply_pyprojecttoml.py @@ -0,0 +1,794 @@ +"""Make sure that applying the configuration from pyproject.toml is equivalent to +applying a similar configuration from setup.cfg + +To run these tests offline, please have a look on ``./downloads/preload.py`` +""" + +from __future__ import annotations + +import io +import re +import tarfile +from inspect import cleandoc +from pathlib import Path +from unittest.mock import Mock + +import pytest +from ini2toml.api import LiteTranslator +from packaging.metadata import Metadata + +import setuptools # noqa: F401 # ensure monkey patch to metadata +from setuptools._static import is_static +from setuptools.command.egg_info import write_requirements +from setuptools.config import expand, pyprojecttoml, setupcfg +from setuptools.config._apply_pyprojecttoml import _MissingDynamic, _some_attrgetter +from setuptools.dist import Distribution +from setuptools.errors import InvalidConfigError, RemovedConfigError +from setuptools.warnings import InformationOnly, SetuptoolsDeprecationWarning + +from .downloads import retrieve_file, urls_from_file + +HERE = Path(__file__).parent +EXAMPLES_FILE = "setupcfg_examples.txt" + + +def makedist(path, **attrs): + return Distribution({"src_root": path, **attrs}) + + +def _mock_expand_patterns(patterns, *_, **__): + """ + Allow comparing the given patterns for 2 dist objects. + We need to strip special chars to avoid errors when validating. + """ + return [ + re.sub("[^a-z0-9]+", "", p, flags=re.IGNORECASE) or "empty" for p in patterns + ] + + +@pytest.mark.parametrize("url", urls_from_file(HERE / EXAMPLES_FILE)) +@pytest.mark.filterwarnings("ignore") +@pytest.mark.uses_network +def test_apply_pyproject_equivalent_to_setupcfg(url, monkeypatch, tmp_path): + monkeypatch.setattr(expand, "read_attr", Mock(return_value="0.0.1")) + monkeypatch.setattr( + Distribution, "_expand_patterns", Mock(side_effect=_mock_expand_patterns) + ) + setupcfg_example = retrieve_file(url) + pyproject_example = Path(tmp_path, "pyproject.toml") + setupcfg_text = setupcfg_example.read_text(encoding="utf-8") + toml_config = LiteTranslator().translate(setupcfg_text, "setup.cfg") + pyproject_example.write_text(toml_config, encoding="utf-8") + + dist_toml = pyprojecttoml.apply_configuration(makedist(tmp_path), pyproject_example) + dist_cfg = setupcfg.apply_configuration(makedist(tmp_path), setupcfg_example) + + pkg_info_toml = core_metadata(dist_toml) + pkg_info_cfg = core_metadata(dist_cfg) + assert pkg_info_toml == pkg_info_cfg + + if any(getattr(d, "license_files", None) for d in (dist_toml, dist_cfg)): + assert set(dist_toml.license_files) == set(dist_cfg.license_files) + + if any(getattr(d, "entry_points", None) for d in (dist_toml, dist_cfg)): + print(dist_cfg.entry_points) + ep_toml = { + (k, *sorted(i.replace(" ", "") for i in v)) + for k, v in dist_toml.entry_points.items() + } + ep_cfg = { + (k, *sorted(i.replace(" ", "") for i in v)) + for k, v in dist_cfg.entry_points.items() + } + assert ep_toml == ep_cfg + + if any(getattr(d, "package_data", None) for d in (dist_toml, dist_cfg)): + pkg_data_toml = {(k, *sorted(v)) for k, v in dist_toml.package_data.items()} + pkg_data_cfg = {(k, *sorted(v)) for k, v in dist_cfg.package_data.items()} + assert pkg_data_toml == pkg_data_cfg + + if any(getattr(d, "data_files", None) for d in (dist_toml, dist_cfg)): + data_files_toml = {(k, *sorted(v)) for k, v in dist_toml.data_files} + data_files_cfg = {(k, *sorted(v)) for k, v in dist_cfg.data_files} + assert data_files_toml == data_files_cfg + + assert set(dist_toml.install_requires) == set(dist_cfg.install_requires) + if any(getattr(d, "extras_require", None) for d in (dist_toml, dist_cfg)): + extra_req_toml = {(k, *sorted(v)) for k, v in dist_toml.extras_require.items()} + extra_req_cfg = {(k, *sorted(v)) for k, v in dist_cfg.extras_require.items()} + assert extra_req_toml == extra_req_cfg + + +PEP621_EXAMPLE = """\ +[project] +name = "spam" +version = "2020.0.0" +description = "Lovely Spam! Wonderful Spam!" +readme = "README.rst" +requires-python = ">=3.8" +license-files = ["LICENSE.txt"] # Updated to be PEP 639 compliant +keywords = ["egg", "bacon", "sausage", "tomatoes", "Lobster Thermidor"] +authors = [ + {email = "hi@pradyunsg.me"}, + {name = "Tzu-Ping Chung"} +] +maintainers = [ + {name = "Brett Cannon", email = "brett@python.org"}, + {name = "John X. Ãørçeč", email = "john@utf8.org"}, + {name = "Γαμα קּ 東", email = "gama@utf8.org"}, +] +classifiers = [ + "Development Status :: 4 - Beta", + "Programming Language :: Python" +] + +dependencies = [ + "httpx", + "gidgethub[httpx]>4.0.0", + "django>2.1; os_name != 'nt'", + "django>2.0; os_name == 'nt'" +] + +[project.optional-dependencies] +test = [ + "pytest < 5.0.0", + "pytest-cov[all]" +] + +[project.urls] +homepage = "http://example.com" +documentation = "http://readthedocs.org" +repository = "http://github.com" +changelog = "http://github.com/me/spam/blob/master/CHANGELOG.md" + +[project.scripts] +spam-cli = "spam:main_cli" + +[project.gui-scripts] +spam-gui = "spam:main_gui" + +[project.entry-points."spam.magical"] +tomatoes = "spam:main_tomatoes" +""" + +PEP621_INTERNATIONAL_EMAIL_EXAMPLE = """\ +[project] +name = "spam" +version = "2020.0.0" +authors = [ + {email = "hi@pradyunsg.me"}, + {name = "Tzu-Ping Chung"} +] +maintainers = [ + {name = "अंकित अहलावत", email = "ankit@example.com"}, +] +""" + +PEP621_EXAMPLE_SCRIPT = """ +def main_cli(): pass +def main_gui(): pass +def main_tomatoes(): pass +""" + +PEP639_LICENSE_TEXT = """\ +[project] +name = "spam" +version = "2020.0.0" +authors = [ + {email = "hi@pradyunsg.me"}, + {name = "Tzu-Ping Chung"} +] +license = {text = "MIT"} +""" + +PEP639_LICENSE_EXPRESSION = """\ +[project] +name = "spam" +version = "2020.0.0" +authors = [ + {email = "hi@pradyunsg.me"}, + {name = "Tzu-Ping Chung"} +] +license = "mit or apache-2.0" # should be normalized in metadata +classifiers = [ + "Development Status :: 5 - Production/Stable", + "Programming Language :: Python", +] +""" + + +def _pep621_example_project( + tmp_path, + readme="README.rst", + pyproject_text=PEP621_EXAMPLE, +): + pyproject = tmp_path / "pyproject.toml" + text = pyproject_text + replacements = {'readme = "README.rst"': f'readme = "{readme}"'} + for orig, subst in replacements.items(): + text = text.replace(orig, subst) + pyproject.write_text(text, encoding="utf-8") + + (tmp_path / readme).write_text("hello world", encoding="utf-8") + (tmp_path / "LICENSE.txt").write_text("--- LICENSE stub ---", encoding="utf-8") + (tmp_path / "spam.py").write_text(PEP621_EXAMPLE_SCRIPT, encoding="utf-8") + return pyproject + + +def test_pep621_example(tmp_path): + """Make sure the example in PEP 621 works""" + pyproject = _pep621_example_project(tmp_path) + dist = pyprojecttoml.apply_configuration(makedist(tmp_path), pyproject) + assert set(dist.metadata.license_files) == {"LICENSE.txt"} + + +@pytest.mark.parametrize( + ("readme", "ctype"), + [ + ("Readme.txt", "text/plain"), + ("readme.md", "text/markdown"), + ("text.rst", "text/x-rst"), + ], +) +def test_readme_content_type(tmp_path, readme, ctype): + pyproject = _pep621_example_project(tmp_path, readme) + dist = pyprojecttoml.apply_configuration(makedist(tmp_path), pyproject) + assert dist.metadata.long_description_content_type == ctype + + +def test_undefined_content_type(tmp_path): + pyproject = _pep621_example_project(tmp_path, "README.tex") + with pytest.raises(ValueError, match="Undefined content type for README.tex"): + pyprojecttoml.apply_configuration(makedist(tmp_path), pyproject) + + +def test_no_explicit_content_type_for_missing_extension(tmp_path): + pyproject = _pep621_example_project(tmp_path, "README") + dist = pyprojecttoml.apply_configuration(makedist(tmp_path), pyproject) + assert dist.metadata.long_description_content_type is None + + +@pytest.mark.parametrize( + ("pyproject_text", "expected_maintainers_meta_value"), + ( + pytest.param( + PEP621_EXAMPLE, + ( + 'Brett Cannon <brett@python.org>, "John X. Ãørçeč" <john@utf8.org>, ' + 'Γαμα קּ 東 <gama@utf8.org>' + ), + id='non-international-emails', + ), + pytest.param( + PEP621_INTERNATIONAL_EMAIL_EXAMPLE, + 'Ankit Ahlawat <अंकित@उदाहरण.भारत>', + marks=pytest.mark.xfail( + reason="CPython's `email.headerregistry.Address` only supports " + 'RFC 5322, as of Oct 20, 2025 and latest Python 3.13.0', + strict=True, + ), + id='international-email', + ), + ), +) +def test_utf8_maintainer_in_metadata( # issue-3663 + expected_maintainers_meta_value, + pyproject_text, + tmp_path, +): + pyproject = _pep621_example_project( + tmp_path, + "README", + pyproject_text=pyproject_text, + ) + dist = pyprojecttoml.apply_configuration(makedist(tmp_path), pyproject) + assert dist.metadata.maintainer_email == expected_maintainers_meta_value + pkg_file = tmp_path / "PKG-FILE" + with open(pkg_file, "w", encoding="utf-8") as fh: + dist.metadata.write_pkg_file(fh) + content = pkg_file.read_text(encoding="utf-8") + assert f"Maintainer-email: {expected_maintainers_meta_value}" in content + + +@pytest.mark.parametrize( + ( + 'pyproject_text', + 'license', + 'license_expression', + 'content_str', + 'not_content_str', + ), + ( + pytest.param( + PEP639_LICENSE_TEXT, + 'MIT', + None, + 'License: MIT', + 'License-Expression: ', + id='license-text', + marks=[ + pytest.mark.filterwarnings( + "ignore:.project.license. as a TOML table is deprecated", + ) + ], + ), + pytest.param( + PEP639_LICENSE_EXPRESSION, + None, + 'MIT OR Apache-2.0', + 'License-Expression: MIT OR Apache-2.0', + 'License: ', + id='license-expression', + ), + ), +) +def test_license_in_metadata( + license, + license_expression, + content_str, + not_content_str, + pyproject_text, + tmp_path, +): + pyproject = _pep621_example_project( + tmp_path, + "README", + pyproject_text=pyproject_text, + ) + dist = pyprojecttoml.apply_configuration(makedist(tmp_path), pyproject) + assert dist.metadata.license == license + assert dist.metadata.license_expression == license_expression + pkg_file = tmp_path / "PKG-FILE" + with open(pkg_file, "w", encoding="utf-8") as fh: + dist.metadata.write_pkg_file(fh) + content = pkg_file.read_text(encoding="utf-8") + assert "Metadata-Version: 2.4" in content + assert content_str in content + assert not_content_str not in content + + +def test_license_classifier_with_license_expression(tmp_path): + text = PEP639_LICENSE_EXPRESSION.rsplit("\n", 2)[0] + pyproject = _pep621_example_project( + tmp_path, + "README", + f"{text}\n \"License :: OSI Approved :: MIT License\"\n]", + ) + msg = "License classifiers have been superseded by license expressions" + with pytest.raises(InvalidConfigError, match=msg) as exc: + pyprojecttoml.apply_configuration(makedist(tmp_path), pyproject) + + assert "License :: OSI Approved :: MIT License" in str(exc.value) + + +def test_license_classifier_without_license_expression(tmp_path): + text = """\ + [project] + name = "spam" + version = "2020.0.0" + license = {text = "mit or apache-2.0"} + classifiers = ["License :: OSI Approved :: MIT License"] + """ + pyproject = _pep621_example_project(tmp_path, "README", text) + + msg1 = "License classifiers are deprecated(?:.|\n)*MIT License" + msg2 = ".project.license. as a TOML table is deprecated" + with ( + pytest.warns(SetuptoolsDeprecationWarning, match=msg1), + pytest.warns(SetuptoolsDeprecationWarning, match=msg2), + ): + dist = pyprojecttoml.apply_configuration(makedist(tmp_path), pyproject) + + # Check license classifier is still included + assert dist.metadata.get_classifiers() == ["License :: OSI Approved :: MIT License"] + + +class TestLicenseFiles: + def base_pyproject( + self, + tmp_path, + additional_text="", + license_toml='license = {file = "LICENSE.txt"}\n', + ): + text = PEP639_LICENSE_EXPRESSION + + # Sanity-check + assert 'license = "mit or apache-2.0"' in text + assert 'license-files' not in text + assert "[tool.setuptools]" not in text + + text = re.sub( + r"(license = .*)\n", + license_toml, + text, + count=1, + ) + assert license_toml in text # sanity check + text = f"{text}\n{additional_text}\n" + pyproject = _pep621_example_project(tmp_path, "README", pyproject_text=text) + return pyproject + + def base_pyproject_license_pep639(self, tmp_path, additional_text=""): + return self.base_pyproject( + tmp_path, + additional_text=additional_text, + license_toml='license = "licenseref-Proprietary"' + '\nlicense-files = ["_FILE*"]\n', + ) + + def test_both_license_and_license_files_defined(self, tmp_path): + setuptools_config = '[tool.setuptools]\nlicense-files = ["_FILE*"]' + pyproject = self.base_pyproject(tmp_path, setuptools_config) + + (tmp_path / "_FILE.txt").touch() + (tmp_path / "_FILE.rst").touch() + + # Would normally match the `license_files` patterns, but we want to exclude it + # by being explicit. On the other hand, contents should be added to `license` + license = tmp_path / "LICENSE.txt" + license.write_text("LicenseRef-Proprietary\n", encoding="utf-8") + + msg1 = "'tool.setuptools.license-files' is deprecated in favor of 'project.license-files'" + msg2 = ".project.license. as a TOML table is deprecated" + with ( + pytest.warns(SetuptoolsDeprecationWarning, match=msg1), + pytest.warns(SetuptoolsDeprecationWarning, match=msg2), + ): + dist = pyprojecttoml.apply_configuration(makedist(tmp_path), pyproject) + assert set(dist.metadata.license_files) == {"_FILE.rst", "_FILE.txt"} + assert dist.metadata.license == "LicenseRef-Proprietary\n" + + def test_both_license_and_license_files_defined_pep639(self, tmp_path): + # Set license and license-files + pyproject = self.base_pyproject_license_pep639(tmp_path) + + (tmp_path / "_FILE.txt").touch() + (tmp_path / "_FILE.rst").touch() + + msg = "Normalizing.*LicenseRef" + with pytest.warns(InformationOnly, match=msg): + dist = pyprojecttoml.apply_configuration(makedist(tmp_path), pyproject) + + assert set(dist.metadata.license_files) == {"_FILE.rst", "_FILE.txt"} + assert dist.metadata.license is None + assert dist.metadata.license_expression == "LicenseRef-Proprietary" + + def test_license_files_defined_twice(self, tmp_path): + # Set project.license-files and tools.setuptools.license-files + setuptools_config = '[tool.setuptools]\nlicense-files = ["_FILE*"]' + pyproject = self.base_pyproject_license_pep639(tmp_path, setuptools_config) + + msg = "'project.license-files' is defined already. Remove 'tool.setuptools.license-files'" + with pytest.raises(InvalidConfigError, match=msg): + pyprojecttoml.apply_configuration(makedist(tmp_path), pyproject) + + def test_default_patterns(self, tmp_path): + setuptools_config = '[tool.setuptools]\nzip-safe = false' + # ^ used just to trigger section validation + pyproject = self.base_pyproject(tmp_path, setuptools_config, license_toml="") + + license_files = "LICENCE-a.html COPYING-abc.txt AUTHORS-xyz NOTICE,def".split() + + for fname in license_files: + (tmp_path / fname).write_text(f"{fname}\n", encoding="utf-8") + + dist = pyprojecttoml.apply_configuration(makedist(tmp_path), pyproject) + + assert (tmp_path / "LICENSE.txt").exists() # from base example + assert set(dist.metadata.license_files) == {*license_files, "LICENSE.txt"} + + def test_missing_patterns(self, tmp_path): + pyproject = self.base_pyproject_license_pep639(tmp_path) + assert list(tmp_path.glob("_FILE*")) == [] # sanity check + + msg1 = "Cannot find any files for the given pattern.*" + msg2 = "Normalizing 'licenseref-Proprietary' to 'LicenseRef-Proprietary'" + with ( + pytest.warns(SetuptoolsDeprecationWarning, match=msg1), + pytest.warns(InformationOnly, match=msg2), + ): + pyprojecttoml.apply_configuration(makedist(tmp_path), pyproject) + + def test_deprecated_file_expands_to_text(self, tmp_path): + """Make sure the old example with ``license = {text = ...}`` works""" + + assert 'license-files = ["LICENSE.txt"]' in PEP621_EXAMPLE # sanity check + text = PEP621_EXAMPLE.replace( + 'license-files = ["LICENSE.txt"]', + 'license = {file = "LICENSE.txt"}', + ) + pyproject = _pep621_example_project(tmp_path, pyproject_text=text) + + msg = ".project.license. as a TOML table is deprecated" + with pytest.warns(SetuptoolsDeprecationWarning, match=msg): + dist = pyprojecttoml.apply_configuration(makedist(tmp_path), pyproject) + + assert dist.metadata.license == "--- LICENSE stub ---" + assert set(dist.metadata.license_files) == {"LICENSE.txt"} # auto-filled + + +class TestPyModules: + # https://github.com/pypa/setuptools/issues/4316 + + def dist(self, name): + toml_config = f""" + [project] + name = "test" + version = "42.0" + [tool.setuptools] + py-modules = [{name!r}] + """ + pyproject = Path("pyproject.toml") + pyproject.write_text(cleandoc(toml_config), encoding="utf-8") + return pyprojecttoml.apply_configuration(Distribution({}), pyproject) + + @pytest.mark.parametrize("module", ["pip-run", "abc-d.λ-xyz-e"]) + def test_valid_module_name(self, tmp_path, monkeypatch, module): + monkeypatch.chdir(tmp_path) + assert module in self.dist(module).py_modules + + @pytest.mark.parametrize("module", ["pip run", "-pip-run", "pip-run-stubs"]) + def test_invalid_module_name(self, tmp_path, monkeypatch, module): + monkeypatch.chdir(tmp_path) + with pytest.raises(ValueError, match="py-modules"): + self.dist(module).py_modules + + +class TestExtModules: + def make_dist(self, toml_config): + pyproject = Path("pyproject.toml") + pyproject.write_text(cleandoc(toml_config), encoding="utf-8") + with pytest.warns(pyprojecttoml._ExperimentalConfiguration): + return pyprojecttoml.apply_configuration(Distribution({}), pyproject) + + def test_pyproject_sets_attribute(self, tmp_path, monkeypatch): + monkeypatch.chdir(tmp_path) + toml_config = """ + [project] + name = "test" + version = "42.0" + [tool.setuptools] + ext-modules = [ + {name = "my.ext", sources = ["hello.c", "world.c"]} + ] + """ + dist = self.make_dist(toml_config) + assert len(dist.ext_modules) == 1 + assert dist.ext_modules[0].name == "my.ext" + assert set(dist.ext_modules[0].sources) == {"hello.c", "world.c"} + + def test_pyproject_define_macros_as_tuples(self, tmp_path, monkeypatch): + # https://github.com/pypa/setuptools/issues/4810 + monkeypatch.chdir(tmp_path) + toml_config = """ + [project] + name = "test" + version = "42.0" + [[tool.setuptools.ext-modules]] + name = "my.ext" + sources = ["hello.c", "world.c"] + define-macros = [["FIRST_SINGLE"], ["SECOND_TWO", "1"]] + """ + dist = self.make_dist(toml_config) + assert isinstance(dist.ext_modules[0].define_macros[0], tuple) + assert dist.ext_modules[0].define_macros[0] == ("FIRST_SINGLE",) + assert dist.ext_modules[0].define_macros[1] == ("SECOND_TWO", "1") + + +class TestDeprecatedFields: + def test_namespace_packages(self, tmp_path): + pyproject = tmp_path / "pyproject.toml" + config = """ + [project] + name = "myproj" + version = "42" + [tool.setuptools] + namespace-packages = ["myproj.pkg"] + """ + pyproject.write_text(cleandoc(config), encoding="utf-8") + with pytest.raises(RemovedConfigError, match="namespace-packages"): + pyprojecttoml.apply_configuration(makedist(tmp_path), pyproject) + + +class TestPresetField: + def pyproject(self, tmp_path, dynamic, extra_content=""): + content = f"[project]\nname = 'proj'\ndynamic = {dynamic!r}\n" + if "version" not in dynamic: + content += "version = '42'\n" + file = tmp_path / "pyproject.toml" + file.write_text(content + extra_content, encoding="utf-8") + return file + + @pytest.mark.parametrize( + ("attr", "field", "value"), + [ + ("license_expression", "license", "MIT"), + pytest.param( + *("license", "license", "Not SPDX"), + marks=[pytest.mark.filterwarnings("ignore:.*license. overwritten")], + ), + ("classifiers", "classifiers", ["Private :: Classifier"]), + ("entry_points", "scripts", {"console_scripts": ["foobar=foobar:main"]}), + ("entry_points", "gui-scripts", {"gui_scripts": ["bazquux=bazquux:main"]}), + pytest.param( + *("install_requires", "dependencies", ["six"]), + marks=[ + pytest.mark.filterwarnings("ignore:.*install_requires. overwritten") + ], + ), + ], + ) + def test_not_listed_in_dynamic(self, tmp_path, attr, field, value): + """Setuptools cannot set a field if not listed in ``dynamic``""" + pyproject = self.pyproject(tmp_path, []) + dist = makedist(tmp_path, **{attr: value}) + msg = re.compile(f"defined outside of `pyproject.toml`:.*{field}", re.DOTALL) + with pytest.warns(_MissingDynamic, match=msg): + dist = pyprojecttoml.apply_configuration(dist, pyproject) + + dist_value = _some_attrgetter(f"metadata.{attr}", attr)(dist) + assert not dist_value + + @pytest.mark.parametrize( + ("attr", "field", "value"), + [ + ("license_expression", "license", "MIT"), + ("install_requires", "dependencies", []), + ("extras_require", "optional-dependencies", {}), + ("install_requires", "dependencies", ["six"]), + ("classifiers", "classifiers", ["Private :: Classifier"]), + ], + ) + def test_listed_in_dynamic(self, tmp_path, attr, field, value): + pyproject = self.pyproject(tmp_path, [field]) + dist = makedist(tmp_path, **{attr: value}) + dist = pyprojecttoml.apply_configuration(dist, pyproject) + dist_value = _some_attrgetter(f"metadata.{attr}", attr)(dist) + assert dist_value == value + + def test_license_files_exempt_from_dynamic(self, monkeypatch, tmp_path): + """ + license-file is currently not considered in the context of dynamic. + As per 2025-02-19, https://packaging.python.org/en/latest/specifications/pyproject-toml/#license-files + allows setuptools to fill-in `license-files` the way it sees fit: + + > If the license-files key is not defined, tools can decide how to handle license files. + > For example they can choose not to include any files or use their own + > logic to discover the appropriate files in the distribution. + + Using license_files from setup.py to fill-in the value is in accordance + with this rule. + """ + monkeypatch.chdir(tmp_path) + pyproject = self.pyproject(tmp_path, []) + dist = makedist(tmp_path, license_files=["LIC*"]) + (tmp_path / "LIC1").write_text("42", encoding="utf-8") + dist = pyprojecttoml.apply_configuration(dist, pyproject) + assert dist.metadata.license_files == ["LIC1"] + + def test_warning_overwritten_dependencies(self, tmp_path): + src = "[project]\nname='pkg'\nversion='0.1'\ndependencies=['click']\n" + pyproject = tmp_path / "pyproject.toml" + pyproject.write_text(src, encoding="utf-8") + dist = makedist(tmp_path, install_requires=["wheel"]) + with pytest.warns(match="`install_requires` overwritten"): + dist = pyprojecttoml.apply_configuration(dist, pyproject) + assert "wheel" not in dist.install_requires + + def test_optional_dependencies_dont_remove_env_markers(self, tmp_path): + """ + Internally setuptools converts dependencies with markers to "extras". + If ``install_requires`` is given by ``setup.py``, we have to ensure that + applying ``optional-dependencies`` does not overwrite the mandatory + dependencies with markers (see #3204). + """ + # If setuptools replace its internal mechanism that uses `requires.txt` + # this test has to be rewritten to adapt accordingly + extra = "\n[project.optional-dependencies]\nfoo = ['bar>1']\n" + pyproject = self.pyproject(tmp_path, ["dependencies"], extra) + install_req = ['importlib-resources (>=3.0.0) ; python_version < "3.7"'] + dist = makedist(tmp_path, install_requires=install_req) + dist = pyprojecttoml.apply_configuration(dist, pyproject) + assert "foo" in dist.extras_require + egg_info = dist.get_command_obj("egg_info") + write_requirements(egg_info, tmp_path, tmp_path / "requires.txt") + reqs = (tmp_path / "requires.txt").read_text(encoding="utf-8") + assert "importlib-resources" in reqs + assert "bar" in reqs + assert ':python_version < "3.7"' in reqs + + @pytest.mark.parametrize( + ("field", "group"), + [("scripts", "console_scripts"), ("gui-scripts", "gui_scripts")], + ) + @pytest.mark.filterwarnings("error") + def test_scripts_dont_require_dynamic_entry_points(self, tmp_path, field, group): + # Issue 3862 + pyproject = self.pyproject(tmp_path, [field]) + dist = makedist(tmp_path, entry_points={group: ["foobar=foobar:main"]}) + dist = pyprojecttoml.apply_configuration(dist, pyproject) + assert group in dist.entry_points + + +class TestMeta: + def test_example_file_in_sdist(self, setuptools_sdist): + """Meta test to ensure tests can run from sdist""" + with tarfile.open(setuptools_sdist) as tar: + assert any(name.endswith(EXAMPLES_FILE) for name in tar.getnames()) + + +class TestInteropCommandLineParsing: + def test_version(self, tmp_path, monkeypatch, capsys): + # See pypa/setuptools#4047 + # This test can be removed once the CLI interface of setup.py is removed + monkeypatch.chdir(tmp_path) + toml_config = """ + [project] + name = "test" + version = "42.0" + """ + pyproject = Path(tmp_path, "pyproject.toml") + pyproject.write_text(cleandoc(toml_config), encoding="utf-8") + opts = {"script_args": ["--version"]} + dist = pyprojecttoml.apply_configuration(Distribution(opts), pyproject) + dist.parse_command_line() # <-- there should be no exception here. + captured = capsys.readouterr() + assert "42.0" in captured.out + + +class TestStaticConfig: + def test_mark_static_fields(self, tmp_path, monkeypatch): + monkeypatch.chdir(tmp_path) + toml_config = """ + [project] + name = "test" + version = "42.0" + dependencies = ["hello"] + keywords = ["world"] + classifiers = ["private :: hello world"] + [tool.setuptools] + obsoletes = ["abcd"] + provides = ["abcd"] + platforms = ["abcd"] + """ + pyproject = Path(tmp_path, "pyproject.toml") + pyproject.write_text(cleandoc(toml_config), encoding="utf-8") + dist = pyprojecttoml.apply_configuration(Distribution({}), pyproject) + assert is_static(dist.install_requires) + assert is_static(dist.metadata.keywords) + assert is_static(dist.metadata.classifiers) + assert is_static(dist.metadata.obsoletes) + assert is_static(dist.metadata.provides) + assert is_static(dist.metadata.platforms) + + +# --- Auxiliary Functions --- + + +def core_metadata(dist) -> str: + with io.StringIO() as buffer: + dist.metadata.write_pkg_file(buffer) + pkg_file_txt = buffer.getvalue() + + # Make sure core metadata is valid + Metadata.from_email(pkg_file_txt, validate=True) # can raise exceptions + + skip_prefixes: tuple[str, ...] = () + skip_lines = set() + # ---- DIFF NORMALISATION ---- + # PEP 621 is very particular about author/maintainer metadata conversion, so skip + skip_prefixes += ("Author:", "Author-email:", "Maintainer:", "Maintainer-email:") + # May be redundant with Home-page + skip_prefixes += ("Project-URL: Homepage,", "Home-page:") + # May be missing in original (relying on default) but backfilled in the TOML + skip_prefixes += ("Description-Content-Type:",) + # Remove empty lines + skip_lines.add("") + + result = [] + for line in pkg_file_txt.splitlines(): + if line.startswith(skip_prefixes) or line in skip_lines: + continue + result.append(line + "\n") + + return "".join(result) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/test_expand.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/test_expand.py new file mode 100644 index 0000000000000000000000000000000000000000..c5710ec63d7d9d4ed7b709203bb2fc4b512f2093 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/test_expand.py @@ -0,0 +1,247 @@ +import os +import sys +from pathlib import Path + +import pytest + +from setuptools._static import is_static +from setuptools.config import expand +from setuptools.discovery import find_package_path + +from distutils.errors import DistutilsOptionError + + +def write_files(files, root_dir): + for file, content in files.items(): + path = root_dir / file + path.parent.mkdir(exist_ok=True, parents=True) + path.write_text(content, encoding="utf-8") + + +def test_glob_relative(tmp_path, monkeypatch): + files = { + "dir1/dir2/dir3/file1.txt", + "dir1/dir2/file2.txt", + "dir1/file3.txt", + "a.ini", + "b.ini", + "dir1/c.ini", + "dir1/dir2/a.ini", + } + + write_files({k: "" for k in files}, tmp_path) + patterns = ["**/*.txt", "[ab].*", "**/[ac].ini"] + monkeypatch.chdir(tmp_path) + assert set(expand.glob_relative(patterns)) == files + # Make sure the same APIs work outside cwd + assert set(expand.glob_relative(patterns, tmp_path)) == files + + +def test_read_files(tmp_path, monkeypatch): + dir_ = tmp_path / "dir_" + (tmp_path / "_dir").mkdir(exist_ok=True) + (tmp_path / "a.txt").touch() + files = {"a.txt": "a", "dir1/b.txt": "b", "dir1/dir2/c.txt": "c"} + write_files(files, dir_) + + secrets = Path(str(dir_) + "secrets") + secrets.mkdir(exist_ok=True) + write_files({"secrets.txt": "secret keys"}, secrets) + + with monkeypatch.context() as m: + m.chdir(dir_) + assert expand.read_files(list(files)) == "a\nb\nc" + + cannot_access_msg = r"Cannot access '.*\.\..a\.txt'" + with pytest.raises(DistutilsOptionError, match=cannot_access_msg): + expand.read_files(["../a.txt"]) + + cannot_access_secrets_msg = r"Cannot access '.*secrets\.txt'" + with pytest.raises(DistutilsOptionError, match=cannot_access_secrets_msg): + expand.read_files(["../dir_secrets/secrets.txt"]) + + # Make sure the same APIs work outside cwd + assert expand.read_files(list(files), dir_) == "a\nb\nc" + with pytest.raises(DistutilsOptionError, match=cannot_access_msg): + expand.read_files(["../a.txt"], dir_) + + +class TestReadAttr: + @pytest.mark.parametrize( + "example", + [ + # No cookie means UTF-8: + b"__version__ = '\xc3\xa9'\nraise SystemExit(1)\n", + # If a cookie is present, honor it: + b"# -*- coding: utf-8 -*-\n__version__ = '\xc3\xa9'\nraise SystemExit(1)\n", + b"# -*- coding: latin1 -*-\n__version__ = '\xe9'\nraise SystemExit(1)\n", + ], + ) + def test_read_attr_encoding_cookie(self, example, tmp_path): + (tmp_path / "mod.py").write_bytes(example) + assert expand.read_attr('mod.__version__', root_dir=tmp_path) == 'é' + + def test_read_attr(self, tmp_path, monkeypatch): + files = { + "pkg/__init__.py": "", + "pkg/sub/__init__.py": "VERSION = '0.1.1'", + "pkg/sub/mod.py": ( + "VALUES = {'a': 0, 'b': {42}, 'c': (0, 1, 1)}\nraise SystemExit(1)" + ), + } + write_files(files, tmp_path) + + with monkeypatch.context() as m: + m.chdir(tmp_path) + # Make sure it can read the attr statically without evaluating the module + version = expand.read_attr('pkg.sub.VERSION') + values = expand.read_attr('lib.mod.VALUES', {'lib': 'pkg/sub'}) + + assert version == '0.1.1' + assert is_static(values) + + assert values['a'] == 0 + assert values['b'] == {42} + assert is_static(values) + + # Make sure the same APIs work outside cwd + assert expand.read_attr('pkg.sub.VERSION', root_dir=tmp_path) == '0.1.1' + values = expand.read_attr('lib.mod.VALUES', {'lib': 'pkg/sub'}, tmp_path) + assert values['c'] == (0, 1, 1) + + @pytest.mark.parametrize( + "example", + [ + "VERSION: str\nVERSION = '0.1.1'\nraise SystemExit(1)\n", + "VERSION: str = '0.1.1'\nraise SystemExit(1)\n", + ], + ) + def test_read_annotated_attr(self, tmp_path, example): + files = { + "pkg/__init__.py": "", + "pkg/sub/__init__.py": example, + } + write_files(files, tmp_path) + # Make sure this attribute can be read statically + version = expand.read_attr('pkg.sub.VERSION', root_dir=tmp_path) + assert version == '0.1.1' + assert is_static(version) + + @pytest.mark.parametrize( + "example", + [ + "VERSION = (lambda: '0.1.1')()\n", + "def fn(): return '0.1.1'\nVERSION = fn()\n", + "VERSION: str = (lambda: '0.1.1')()\n", + ], + ) + def test_read_dynamic_attr(self, tmp_path, monkeypatch, example): + files = { + "pkg/__init__.py": "", + "pkg/sub/__init__.py": example, + } + write_files(files, tmp_path) + monkeypatch.chdir(tmp_path) + version = expand.read_attr('pkg.sub.VERSION') + assert version == '0.1.1' + assert not is_static(version) + + def test_import_order(self, tmp_path): + """ + Sometimes the import machinery will import the parent package of a nested + module, which triggers side-effects and might create problems (see issue #3176) + + ``read_attr`` should bypass these limitations by resolving modules statically + (via ast.literal_eval). + """ + files = { + "src/pkg/__init__.py": "from .main import func\nfrom .about import version", + "src/pkg/main.py": "import super_complicated_dep\ndef func(): return 42", + "src/pkg/about.py": "version = '42'", + } + write_files(files, tmp_path) + attr_desc = "pkg.about.version" + package_dir = {"": "src"} + # `import super_complicated_dep` should not run, otherwise the build fails + assert expand.read_attr(attr_desc, package_dir, tmp_path) == "42" + + +@pytest.mark.parametrize( + ("package_dir", "file", "module", "return_value"), + [ + ({"": "src"}, "src/pkg/main.py", "pkg.main", 42), + ({"pkg": "lib"}, "lib/main.py", "pkg.main", 13), + ({}, "single_module.py", "single_module", 70), + ({}, "flat_layout/pkg.py", "flat_layout.pkg", 836), + ], +) +def test_resolve_class(monkeypatch, tmp_path, package_dir, file, module, return_value): + monkeypatch.setattr(sys, "modules", {}) # reproducibility + files = {file: f"class Custom:\n def testing(self): return {return_value}"} + write_files(files, tmp_path) + cls = expand.resolve_class(f"{module}.Custom", package_dir, tmp_path) + assert cls().testing() == return_value + + +@pytest.mark.parametrize( + ("args", "pkgs"), + [ + ({"where": ["."], "namespaces": False}, {"pkg", "other"}), + ({"where": [".", "dir1"], "namespaces": False}, {"pkg", "other", "dir2"}), + ({"namespaces": True}, {"pkg", "other", "dir1", "dir1.dir2"}), + ({}, {"pkg", "other", "dir1", "dir1.dir2"}), # default value for `namespaces` + ], +) +def test_find_packages(tmp_path, args, pkgs): + files = { + "pkg/__init__.py", + "other/__init__.py", + "dir1/dir2/__init__.py", + } + write_files({k: "" for k in files}, tmp_path) + + package_dir = {} + kwargs = {"root_dir": tmp_path, "fill_package_dir": package_dir, **args} + where = kwargs.get("where", ["."]) + assert set(expand.find_packages(**kwargs)) == pkgs + for pkg in pkgs: + pkg_path = find_package_path(pkg, package_dir, tmp_path) + assert os.path.exists(pkg_path) + + # Make sure the same APIs work outside cwd + where = [ + str((tmp_path / p).resolve()).replace(os.sep, "/") # ensure posix-style paths + for p in args.pop("where", ["."]) + ] + + assert set(expand.find_packages(where=where, **args)) == pkgs + + +@pytest.mark.parametrize( + ("files", "where", "expected_package_dir"), + [ + (["pkg1/__init__.py", "pkg1/other.py"], ["."], {}), + (["pkg1/__init__.py", "pkg2/__init__.py"], ["."], {}), + (["src/pkg1/__init__.py", "src/pkg1/other.py"], ["src"], {"": "src"}), + (["src/pkg1/__init__.py", "src/pkg2/__init__.py"], ["src"], {"": "src"}), + ( + ["src1/pkg1/__init__.py", "src2/pkg2/__init__.py"], + ["src1", "src2"], + {"pkg1": "src1/pkg1", "pkg2": "src2/pkg2"}, + ), + ( + ["src/pkg1/__init__.py", "pkg2/__init__.py"], + ["src", "."], + {"pkg1": "src/pkg1"}, + ), + ], +) +def test_fill_package_dir(tmp_path, files, where, expected_package_dir): + write_files({k: "" for k in files}, tmp_path) + pkg_dir = {} + kwargs = {"root_dir": tmp_path, "fill_package_dir": pkg_dir, "namespaces": False} + pkgs = expand.find_packages(where=where, **kwargs) + assert set(pkg_dir.items()) == set(expected_package_dir.items()) + for pkg in pkgs: + pkg_path = find_package_path(pkg, pkg_dir, tmp_path) + assert os.path.exists(pkg_path) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/test_pyprojecttoml.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/test_pyprojecttoml.py new file mode 100644 index 0000000000000000000000000000000000000000..e031ea810bcac94f54e5cd4e6515470233a9189d --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/test_pyprojecttoml.py @@ -0,0 +1,421 @@ +import re +from configparser import ConfigParser +from inspect import cleandoc + +import jaraco.path +import pytest +import tomli_w +from path import Path + +import setuptools # noqa: F401 # force distutils.core to be patched +from setuptools.config.pyprojecttoml import ( + _ToolsTypoInMetadata, + apply_configuration, + expand_configuration, + read_configuration, + validate, +) +from setuptools.dist import Distribution +from setuptools.errors import OptionError + +import distutils.core + +EXAMPLE = """ +[project] +name = "myproj" +keywords = ["some", "key", "words"] +dynamic = ["version", "readme"] +requires-python = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" +dependencies = [ + 'importlib-metadata>=0.12;python_version<"3.8"', + 'importlib-resources>=1.0;python_version<"3.7"', + 'pathlib2>=2.3.3,<3;python_version < "3.4" and sys.platform != "win32"', +] + +[project.optional-dependencies] +docs = [ + "sphinx>=3", + "sphinx-argparse>=0.2.5", + "sphinx-rtd-theme>=0.4.3", +] +testing = [ + "pytest>=1", + "coverage>=3,<5", +] + +[project.scripts] +exec = "pkg.__main__:exec" + +[build-system] +requires = ["setuptools", "wheel"] +build-backend = "setuptools.build_meta" + +[tool.setuptools] +package-dir = {"" = "src"} +zip-safe = true +platforms = ["any"] + +[tool.setuptools.packages.find] +where = ["src"] + +[tool.setuptools.cmdclass] +sdist = "pkg.mod.CustomSdist" + +[tool.setuptools.dynamic.version] +attr = "pkg.__version__.VERSION" + +[tool.setuptools.dynamic.readme] +file = ["README.md"] +content-type = "text/markdown" + +[tool.setuptools.package-data] +"*" = ["*.txt"] + +[tool.setuptools.data-files] +"data" = ["_files/*.txt"] + +[tool.distutils.sdist] +formats = "gztar" + +[tool.distutils.bdist_wheel] +universal = true +""" + + +def create_example(path, pkg_root): + files = { + "pyproject.toml": EXAMPLE, + "README.md": "hello world", + "_files": { + "file.txt": "", + }, + } + packages = { + "pkg": { + "__init__.py": "", + "mod.py": "class CustomSdist: pass", + "__version__.py": "VERSION = (3, 10)", + "__main__.py": "def exec(): print('hello')", + }, + } + + assert pkg_root # Meta-test: cannot be empty string. + + if pkg_root == ".": + files = {**files, **packages} + # skip other files: flat-layout will raise error for multi-package dist + else: + # Use this opportunity to ensure namespaces are discovered + files[pkg_root] = {**packages, "other": {"nested": {"__init__.py": ""}}} + + jaraco.path.build(files, prefix=path) + + +def verify_example(config, path, pkg_root): + pyproject = path / "pyproject.toml" + pyproject.write_text(tomli_w.dumps(config), encoding="utf-8") + expanded = expand_configuration(config, path) + expanded_project = expanded["project"] + assert read_configuration(pyproject, expand=True) == expanded + assert expanded_project["version"] == "3.10" + assert expanded_project["readme"]["text"] == "hello world" + assert "packages" in expanded["tool"]["setuptools"] + if pkg_root == ".": + # Auto-discovery will raise error for multi-package dist + assert set(expanded["tool"]["setuptools"]["packages"]) == {"pkg"} + else: + assert set(expanded["tool"]["setuptools"]["packages"]) == { + "pkg", + "other", + "other.nested", + } + assert expanded["tool"]["setuptools"]["include-package-data"] is True + assert "" in expanded["tool"]["setuptools"]["package-data"] + assert "*" not in expanded["tool"]["setuptools"]["package-data"] + assert expanded["tool"]["setuptools"]["data-files"] == [ + ("data", ["_files/file.txt"]) + ] + + +def test_read_configuration(tmp_path): + create_example(tmp_path, "src") + pyproject = tmp_path / "pyproject.toml" + + config = read_configuration(pyproject, expand=False) + assert config["project"].get("version") is None + assert config["project"].get("readme") is None + + verify_example(config, tmp_path, "src") + + +@pytest.mark.parametrize( + ("pkg_root", "opts"), + [ + (".", {}), + ("src", {}), + ("lib", {"packages": {"find": {"where": ["lib"]}}}), + ], +) +def test_discovered_package_dir_with_attr_directive_in_config(tmp_path, pkg_root, opts): + create_example(tmp_path, pkg_root) + + pyproject = tmp_path / "pyproject.toml" + + config = read_configuration(pyproject, expand=False) + assert config["project"].get("version") is None + assert config["project"].get("readme") is None + config["tool"]["setuptools"].pop("packages", None) + config["tool"]["setuptools"].pop("package-dir", None) + + config["tool"]["setuptools"].update(opts) + verify_example(config, tmp_path, pkg_root) + + +ENTRY_POINTS = { + "console_scripts": {"a": "mod.a:func"}, + "gui_scripts": {"b": "mod.b:func"}, + "other": {"c": "mod.c:func [extra]"}, +} + + +class TestEntryPoints: + def write_entry_points(self, tmp_path): + entry_points = ConfigParser() + entry_points.read_dict(ENTRY_POINTS) + with open(tmp_path / "entry-points.txt", "w", encoding="utf-8") as f: + entry_points.write(f) + + def pyproject(self, dynamic=None): + project = {"dynamic": dynamic or ["scripts", "gui-scripts", "entry-points"]} + tool = {"dynamic": {"entry-points": {"file": "entry-points.txt"}}} + return {"project": project, "tool": {"setuptools": tool}} + + def test_all_listed_in_dynamic(self, tmp_path): + self.write_entry_points(tmp_path) + expanded = expand_configuration(self.pyproject(), tmp_path) + expanded_project = expanded["project"] + assert len(expanded_project["scripts"]) == 1 + assert expanded_project["scripts"]["a"] == "mod.a:func" + assert len(expanded_project["gui-scripts"]) == 1 + assert expanded_project["gui-scripts"]["b"] == "mod.b:func" + assert len(expanded_project["entry-points"]) == 1 + assert expanded_project["entry-points"]["other"]["c"] == "mod.c:func [extra]" + + @pytest.mark.parametrize("missing_dynamic", ("scripts", "gui-scripts")) + def test_scripts_not_listed_in_dynamic(self, tmp_path, missing_dynamic): + self.write_entry_points(tmp_path) + dynamic = {"scripts", "gui-scripts", "entry-points"} - {missing_dynamic} + + msg = f"defined outside of `pyproject.toml`:.*{missing_dynamic}" + with pytest.raises(OptionError, match=re.compile(msg, re.DOTALL)): + expand_configuration(self.pyproject(dynamic), tmp_path) + + +class TestClassifiers: + def test_dynamic(self, tmp_path): + # Let's create a project example that has dynamic classifiers + # coming from a txt file. + create_example(tmp_path, "src") + classifiers = cleandoc( + """ + Framework :: Flask + Programming Language :: Haskell + """ + ) + (tmp_path / "classifiers.txt").write_text(classifiers, encoding="utf-8") + + pyproject = tmp_path / "pyproject.toml" + config = read_configuration(pyproject, expand=False) + dynamic = config["project"]["dynamic"] + config["project"]["dynamic"] = list({*dynamic, "classifiers"}) + dynamic_config = config["tool"]["setuptools"]["dynamic"] + dynamic_config["classifiers"] = {"file": "classifiers.txt"} + + # When the configuration is expanded, + # each line of the file should be an different classifier. + validate(config, pyproject) + expanded = expand_configuration(config, tmp_path) + + assert set(expanded["project"]["classifiers"]) == { + "Framework :: Flask", + "Programming Language :: Haskell", + } + + def test_dynamic_without_config(self, tmp_path): + config = """ + [project] + name = "myproj" + version = '42' + dynamic = ["classifiers"] + """ + + pyproject = tmp_path / "pyproject.toml" + pyproject.write_text(cleandoc(config), encoding="utf-8") + with pytest.raises(OptionError, match="No configuration .* .classifiers."): + read_configuration(pyproject) + + def test_dynamic_readme_from_setup_script_args(self, tmp_path): + config = """ + [project] + name = "myproj" + version = '42' + dynamic = ["readme"] + """ + pyproject = tmp_path / "pyproject.toml" + pyproject.write_text(cleandoc(config), encoding="utf-8") + dist = Distribution(attrs={"long_description": "42"}) + # No error should occur because of missing `readme` + dist = apply_configuration(dist, pyproject) + assert dist.metadata.long_description == "42" + + def test_dynamic_without_file(self, tmp_path): + config = """ + [project] + name = "myproj" + version = '42' + dynamic = ["classifiers"] + + [tool.setuptools.dynamic] + classifiers = {file = ["classifiers.txt"]} + """ + + pyproject = tmp_path / "pyproject.toml" + pyproject.write_text(cleandoc(config), encoding="utf-8") + with pytest.warns(UserWarning, match="File .*classifiers.txt. cannot be found"): + expanded = read_configuration(pyproject) + assert "classifiers" not in expanded["project"] + + +class TestImportNames: + EXAMPLES = [ + 'import-names = ["hello", "world"]', + 'import-namespaces = ["hello", "world"]', + 'dynamic = ["import-names"]', + 'dynamic = ["import-namespaces"]', + ] + + @pytest.mark.parametrize("example", EXAMPLES) + def test_not_implemented(self, monkeypatch, tmp_path, example): + monkeypatch.chdir(tmp_path) + pyproject = Path("pyproject.toml") + toml_config = f""" + [project] + name = 'proj' + version = '42' + {example} + """ + pyproject.write_text(cleandoc(toml_config), encoding="utf-8") + with pytest.raises(NotImplementedError, match='import-names'): + apply_configuration(Distribution({}), pyproject) + + +@pytest.mark.parametrize( + "example", + ( + """ + [project] + name = "myproj" + version = "1.2" + + [my-tool.that-disrespect.pep518] + value = 42 + """, + ), +) +def test_ignore_unrelated_config(tmp_path, example): + pyproject = tmp_path / "pyproject.toml" + pyproject.write_text(cleandoc(example), encoding="utf-8") + + # Make sure no error is raised due to 3rd party configs in pyproject.toml + assert read_configuration(pyproject) is not None + + +@pytest.mark.parametrize( + ("example", "error_msg"), + [ + ( + """ + [project] + name = "myproj" + version = "1.2" + requires = ['pywin32; platform_system=="Windows"' ] + """, + "configuration error: .project. must not contain ..requires.. properties", + ), + ], +) +def test_invalid_example(tmp_path, example, error_msg): + pyproject = tmp_path / "pyproject.toml" + pyproject.write_text(cleandoc(example), encoding="utf-8") + + pattern = re.compile( + f"invalid pyproject.toml.*{error_msg}.*", re.MULTILINE | re.DOTALL + ) + with pytest.raises(ValueError, match=pattern): + read_configuration(pyproject) + + +@pytest.mark.parametrize("config", ("", "[tool.something]\nvalue = 42")) +def test_empty(tmp_path, config): + pyproject = tmp_path / "pyproject.toml" + pyproject.write_text(config, encoding="utf-8") + + # Make sure no error is raised + assert read_configuration(pyproject) == {} + + +@pytest.mark.parametrize("config", ("[project]\nname = 'myproj'\nversion='42'\n",)) +def test_include_package_data_by_default(tmp_path, config): + """Builds with ``pyproject.toml`` should consider ``include-package-data=True`` as + default. + """ + pyproject = tmp_path / "pyproject.toml" + pyproject.write_text(config, encoding="utf-8") + + config = read_configuration(pyproject) + assert config["tool"]["setuptools"]["include-package-data"] is True + + +def test_include_package_data_in_setuppy(tmp_path): + """Builds with ``pyproject.toml`` should consider ``include_package_data`` set in + ``setup.py``. + + See https://github.com/pypa/setuptools/issues/3197#issuecomment-1079023889 + """ + files = { + "pyproject.toml": "[project]\nname = 'myproj'\nversion='42'\n", + "setup.py": "__import__('setuptools').setup(include_package_data=False)", + } + jaraco.path.build(files, prefix=tmp_path) + + with Path(tmp_path): + dist = distutils.core.run_setup("setup.py", {}, stop_after="config") + + assert dist.get_name() == "myproj" + assert dist.get_version() == "42" + assert dist.include_package_data is False + + +def test_warn_tools_typo(tmp_path): + """Test that the common ``tools.setuptools`` typo in ``pyproject.toml`` issues a warning + + See https://github.com/pypa/setuptools/issues/4150 + """ + config = """ + [build-system] + requires = ["setuptools"] + build-backend = "setuptools.build_meta" + + [project] + name = "myproj" + version = '42' + + [tools.setuptools] + packages = ["package"] + """ + + pyproject = tmp_path / "pyproject.toml" + pyproject.write_text(cleandoc(config), encoding="utf-8") + + with pytest.warns(_ToolsTypoInMetadata): + read_configuration(pyproject) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/test_pyprojecttoml_dynamic_deps.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/test_pyprojecttoml_dynamic_deps.py new file mode 100644 index 0000000000000000000000000000000000000000..9fc8050743c4b1a8497d5ea20c571b565d074e59 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/test_pyprojecttoml_dynamic_deps.py @@ -0,0 +1,111 @@ +from inspect import cleandoc + +import pytest +from jaraco import path + +from setuptools.config.pyprojecttoml import apply_configuration +from setuptools.dist import Distribution +from setuptools.warnings import SetuptoolsWarning + + +def test_dynamic_dependencies(tmp_path): + files = { + "requirements.txt": "six\n # comment\n", + "pyproject.toml": cleandoc( + """ + [project] + name = "myproj" + version = "1.0" + dynamic = ["dependencies"] + + [build-system] + requires = ["setuptools", "wheel"] + build-backend = "setuptools.build_meta" + + [tool.setuptools.dynamic.dependencies] + file = ["requirements.txt"] + """ + ), + } + path.build(files, prefix=tmp_path) + dist = Distribution() + dist = apply_configuration(dist, tmp_path / "pyproject.toml") + assert dist.install_requires == ["six"] + + +def test_dynamic_optional_dependencies(tmp_path): + files = { + "requirements-docs.txt": "sphinx\n # comment\n", + "pyproject.toml": cleandoc( + """ + [project] + name = "myproj" + version = "1.0" + dynamic = ["optional-dependencies"] + + [tool.setuptools.dynamic.optional-dependencies.docs] + file = ["requirements-docs.txt"] + + [build-system] + requires = ["setuptools", "wheel"] + build-backend = "setuptools.build_meta" + """ + ), + } + path.build(files, prefix=tmp_path) + dist = Distribution() + dist = apply_configuration(dist, tmp_path / "pyproject.toml") + assert dist.extras_require == {"docs": ["sphinx"]} + + +def test_mixed_dynamic_optional_dependencies(tmp_path): + """ + Test that if PEP 621 was loosened to allow mixing of dynamic and static + configurations in the case of fields containing sub-fields (groups), + things would work out. + """ + files = { + "requirements-images.txt": "pillow~=42.0\n # comment\n", + "pyproject.toml": cleandoc( + """ + [project] + name = "myproj" + version = "1.0" + dynamic = ["optional-dependencies"] + + [project.optional-dependencies] + docs = ["sphinx"] + + [tool.setuptools.dynamic.optional-dependencies.images] + file = ["requirements-images.txt"] + """ + ), + } + + path.build(files, prefix=tmp_path) + pyproject = tmp_path / "pyproject.toml" + with pytest.raises(ValueError, match="project.optional-dependencies"): + apply_configuration(Distribution(), pyproject) + + +def test_mixed_extras_require_optional_dependencies(tmp_path): + files = { + "pyproject.toml": cleandoc( + """ + [project] + name = "myproj" + version = "1.0" + optional-dependencies.docs = ["sphinx"] + """ + ), + } + + path.build(files, prefix=tmp_path) + pyproject = tmp_path / "pyproject.toml" + + dist = Distribution({"extras_require": {"hello": ["world"]}}) + + with pytest.warns(SetuptoolsWarning, match=".extras_require. overwritten"): + dist = apply_configuration(dist, pyproject) + + assert dist.extras_require == {"docs": ["sphinx"]} diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/test_setupcfg.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/test_setupcfg.py new file mode 100644 index 0000000000000000000000000000000000000000..495337a9a5815e3d2a0aefa584b8ee81f5136d95 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/config/test_setupcfg.py @@ -0,0 +1,987 @@ +import configparser +import contextlib +import inspect +import re +import sys +from pathlib import Path +from unittest.mock import Mock, patch + +import pytest +from packaging.requirements import InvalidRequirement + +from setuptools.config.setupcfg import ConfigHandler, Target, read_configuration +from setuptools.dist import Distribution, _Distribution +from setuptools.warnings import SetuptoolsDeprecationWarning + +from ..textwrap import DALS + +from distutils.errors import DistutilsFileError, DistutilsOptionError + +IS_PYPY = '__pypy__' in sys.builtin_module_names + + +class ErrConfigHandler(ConfigHandler[Target]): + """Erroneous handler. Fails to implement required methods.""" + + section_prefix = "**err**" + + +def make_package_dir(name, base_dir, ns=False): + dir_package = base_dir + for dir_name in name.split('/'): + dir_package = dir_package.mkdir(dir_name) + init_file = None + if not ns: + init_file = dir_package.join('__init__.py') + init_file.write('') + return dir_package, init_file + + +def fake_env( + tmpdir, setup_cfg, setup_py=None, encoding='ascii', package_path='fake_package' +): + if setup_py is None: + setup_py = 'from setuptools import setup\nsetup()\n' + + tmpdir.join('setup.py').write(setup_py) + config = tmpdir.join('setup.cfg') + config.write(setup_cfg.encode(encoding), mode='wb') + + package_dir, init_file = make_package_dir(package_path, tmpdir) + + init_file.write( + 'VERSION = (1, 2, 3)\n' + '\n' + 'VERSION_MAJOR = 1' + '\n' + 'def get_version():\n' + ' return [3, 4, 5, "dev"]\n' + '\n' + ) + + return package_dir, config + + +@contextlib.contextmanager +def get_dist(tmpdir, kwargs_initial=None, parse=True): + kwargs_initial = kwargs_initial or {} + + with tmpdir.as_cwd(): + dist = Distribution(kwargs_initial) + dist.script_name = 'setup.py' + parse and dist.parse_config_files() + + yield dist + + +def test_parsers_implemented(): + with pytest.raises(NotImplementedError): + handler = ErrConfigHandler(None, {}, False, Mock()) + handler.parsers + + +class TestConfigurationReader: + def test_basic(self, tmpdir): + _, config = fake_env( + tmpdir, + '[metadata]\n' + 'version = 10.1.1\n' + 'keywords = one, two\n' + '\n' + '[options]\n' + 'scripts = bin/a.py, bin/b.py\n', + ) + config_dict = read_configuration(str(config)) + assert config_dict['metadata']['version'] == '10.1.1' + assert config_dict['metadata']['keywords'] == ['one', 'two'] + assert config_dict['options']['scripts'] == ['bin/a.py', 'bin/b.py'] + + def test_no_config(self, tmpdir): + with pytest.raises(DistutilsFileError): + read_configuration(str(tmpdir.join('setup.cfg'))) + + def test_ignore_errors(self, tmpdir): + _, config = fake_env( + tmpdir, + '[metadata]\nversion = attr: none.VERSION\nkeywords = one, two\n', + ) + with pytest.raises(ImportError): + read_configuration(str(config)) + + config_dict = read_configuration(str(config), ignore_option_errors=True) + + assert config_dict['metadata']['keywords'] == ['one', 'two'] + assert 'version' not in config_dict['metadata'] + + config.remove() + + +class TestMetadata: + def test_basic(self, tmpdir): + fake_env( + tmpdir, + '[metadata]\n' + 'version = 10.1.1\n' + 'description = Some description\n' + 'long_description_content_type = text/something\n' + 'long_description = file: README\n' + 'name = fake_name\n' + 'keywords = one, two\n' + 'provides = package, package.sub\n' + 'license = otherlic\n' + 'download_url = http://test.test.com/test/\n' + 'maintainer_email = test@test.com\n', + ) + + tmpdir.join('README').write('readme contents\nline2') + + meta_initial = { + # This will be used so `otherlic` won't replace it. + 'license': 'BSD 3-Clause License', + } + + with get_dist(tmpdir, meta_initial) as dist: + metadata = dist.metadata + + assert metadata.version == '10.1.1' + assert metadata.description == 'Some description' + assert metadata.long_description_content_type == 'text/something' + assert metadata.long_description == 'readme contents\nline2' + assert metadata.provides == ['package', 'package.sub'] + assert metadata.license == 'BSD 3-Clause License' + assert metadata.name == 'fake_name' + assert metadata.keywords == ['one', 'two'] + assert metadata.download_url == 'http://test.test.com/test/' + assert metadata.maintainer_email == 'test@test.com' + + def test_license_cfg(self, tmpdir): + fake_env( + tmpdir, + DALS( + """ + [metadata] + name=foo + version=0.0.1 + license=Apache 2.0 + """ + ), + ) + + with get_dist(tmpdir) as dist: + metadata = dist.metadata + + assert metadata.name == "foo" + assert metadata.version == "0.0.1" + assert metadata.license == "Apache 2.0" + + def test_file_mixed(self, tmpdir): + fake_env( + tmpdir, + '[metadata]\nlong_description = file: README.rst, CHANGES.rst\n\n', + ) + + tmpdir.join('README.rst').write('readme contents\nline2') + tmpdir.join('CHANGES.rst').write('changelog contents\nand stuff') + + with get_dist(tmpdir) as dist: + assert dist.metadata.long_description == ( + 'readme contents\nline2\nchangelog contents\nand stuff' + ) + + def test_file_sandboxed(self, tmpdir): + tmpdir.ensure("README") + project = tmpdir.join('depth1', 'depth2') + project.ensure(dir=True) + fake_env(project, '[metadata]\nlong_description = file: ../../README\n') + + with get_dist(project, parse=False) as dist: + with pytest.raises(DistutilsOptionError): + dist.parse_config_files() # file: out of sandbox + + def test_aliases(self, tmpdir): + fake_env( + tmpdir, + '[metadata]\n' + 'author_email = test@test.com\n' + 'home_page = http://test.test.com/test/\n' + 'summary = Short summary\n' + 'platform = a, b\n' + 'classifier =\n' + ' Framework :: Django\n' + ' Programming Language :: Python :: 3.5\n', + ) + + with get_dist(tmpdir) as dist: + metadata = dist.metadata + assert metadata.author_email == 'test@test.com' + assert metadata.url == 'http://test.test.com/test/' + assert metadata.description == 'Short summary' + assert metadata.platforms == ['a', 'b'] + assert metadata.classifiers == [ + 'Framework :: Django', + 'Programming Language :: Python :: 3.5', + ] + + def test_multiline(self, tmpdir): + fake_env( + tmpdir, + '[metadata]\n' + 'name = fake_name\n' + 'keywords =\n' + ' one\n' + ' two\n' + 'classifiers =\n' + ' Framework :: Django\n' + ' Programming Language :: Python :: 3.5\n', + ) + with get_dist(tmpdir) as dist: + metadata = dist.metadata + assert metadata.keywords == ['one', 'two'] + assert metadata.classifiers == [ + 'Framework :: Django', + 'Programming Language :: Python :: 3.5', + ] + + def test_dict(self, tmpdir): + fake_env( + tmpdir, + '[metadata]\n' + 'project_urls =\n' + ' Link One = https://example.com/one/\n' + ' Link Two = https://example.com/two/\n', + ) + with get_dist(tmpdir) as dist: + metadata = dist.metadata + assert metadata.project_urls == { + 'Link One': 'https://example.com/one/', + 'Link Two': 'https://example.com/two/', + } + + def test_version(self, tmpdir): + package_dir, config = fake_env( + tmpdir, '[metadata]\nversion = attr: fake_package.VERSION\n' + ) + + sub_a = package_dir.mkdir('subpkg_a') + sub_a.join('__init__.py').write('') + sub_a.join('mod.py').write('VERSION = (2016, 11, 26)') + + sub_b = package_dir.mkdir('subpkg_b') + sub_b.join('__init__.py').write('') + sub_b.join('mod.py').write( + 'import third_party_module\nVERSION = (2016, 11, 26)' + ) + + with get_dist(tmpdir) as dist: + assert dist.metadata.version == '1.2.3' + + config.write('[metadata]\nversion = attr: fake_package.get_version\n') + with get_dist(tmpdir) as dist: + assert dist.metadata.version == '3.4.5.dev' + + config.write('[metadata]\nversion = attr: fake_package.VERSION_MAJOR\n') + with get_dist(tmpdir) as dist: + assert dist.metadata.version == '1' + + config.write('[metadata]\nversion = attr: fake_package.subpkg_a.mod.VERSION\n') + with get_dist(tmpdir) as dist: + assert dist.metadata.version == '2016.11.26' + + config.write('[metadata]\nversion = attr: fake_package.subpkg_b.mod.VERSION\n') + with get_dist(tmpdir) as dist: + assert dist.metadata.version == '2016.11.26' + + def test_version_file(self, tmpdir): + fake_env(tmpdir, '[metadata]\nversion = file: fake_package/version.txt\n') + tmpdir.join('fake_package', 'version.txt').write('1.2.3\n') + + with get_dist(tmpdir) as dist: + assert dist.metadata.version == '1.2.3' + + tmpdir.join('fake_package', 'version.txt').write('1.2.3\n4.5.6\n') + with pytest.raises(DistutilsOptionError): + with get_dist(tmpdir) as dist: + dist.metadata.version + + def test_version_with_package_dir_simple(self, tmpdir): + fake_env( + tmpdir, + '[metadata]\n' + 'version = attr: fake_package_simple.VERSION\n' + '[options]\n' + 'package_dir =\n' + ' = src\n', + package_path='src/fake_package_simple', + ) + + with get_dist(tmpdir) as dist: + assert dist.metadata.version == '1.2.3' + + def test_version_with_package_dir_rename(self, tmpdir): + fake_env( + tmpdir, + '[metadata]\n' + 'version = attr: fake_package_rename.VERSION\n' + '[options]\n' + 'package_dir =\n' + ' fake_package_rename = fake_dir\n', + package_path='fake_dir', + ) + + with get_dist(tmpdir) as dist: + assert dist.metadata.version == '1.2.3' + + def test_version_with_package_dir_complex(self, tmpdir): + fake_env( + tmpdir, + '[metadata]\n' + 'version = attr: fake_package_complex.VERSION\n' + '[options]\n' + 'package_dir =\n' + ' fake_package_complex = src/fake_dir\n', + package_path='src/fake_dir', + ) + + with get_dist(tmpdir) as dist: + assert dist.metadata.version == '1.2.3' + + def test_unknown_meta_item(self, tmpdir): + fake_env(tmpdir, '[metadata]\nname = fake_name\nunknown = some\n') + with get_dist(tmpdir, parse=False) as dist: + dist.parse_config_files() # Skip unknown. + + def test_usupported_section(self, tmpdir): + fake_env(tmpdir, '[metadata.some]\nkey = val\n') + with get_dist(tmpdir, parse=False) as dist: + with pytest.raises(DistutilsOptionError): + dist.parse_config_files() + + def test_classifiers(self, tmpdir): + expected = set([ + 'Framework :: Django', + 'Programming Language :: Python :: 3', + 'Programming Language :: Python :: 3.5', + ]) + + # From file. + _, config = fake_env(tmpdir, '[metadata]\nclassifiers = file: classifiers\n') + + tmpdir.join('classifiers').write( + 'Framework :: Django\n' + 'Programming Language :: Python :: 3\n' + 'Programming Language :: Python :: 3.5\n' + ) + + with get_dist(tmpdir) as dist: + assert set(dist.metadata.classifiers) == expected + + # From list notation + config.write( + '[metadata]\n' + 'classifiers =\n' + ' Framework :: Django\n' + ' Programming Language :: Python :: 3\n' + ' Programming Language :: Python :: 3.5\n' + ) + with get_dist(tmpdir) as dist: + assert set(dist.metadata.classifiers) == expected + + def test_interpolation(self, tmpdir): + fake_env(tmpdir, '[metadata]\ndescription = %(message)s\n') + with pytest.raises(configparser.InterpolationMissingOptionError): + with get_dist(tmpdir): + pass + + def test_non_ascii_1(self, tmpdir): + fake_env(tmpdir, '[metadata]\ndescription = éàïôñ\n', encoding='utf-8') + with get_dist(tmpdir): + pass + + def test_non_ascii_3(self, tmpdir): + fake_env(tmpdir, '\n# -*- coding: invalid\n') + with get_dist(tmpdir): + pass + + def test_non_ascii_4(self, tmpdir): + fake_env( + tmpdir, + '# -*- coding: utf-8\n[metadata]\ndescription = éàïôñ\n', + encoding='utf-8', + ) + with get_dist(tmpdir) as dist: + assert dist.metadata.description == 'éàïôñ' + + def test_not_utf8(self, tmpdir): + """ + Config files encoded not in UTF-8 will fail + """ + fake_env( + tmpdir, + '# vim: set fileencoding=iso-8859-15 :\n[metadata]\ndescription = éàïôñ\n', + encoding='iso-8859-15', + ) + with pytest.raises(UnicodeDecodeError): + with get_dist(tmpdir): + pass + + @pytest.mark.parametrize( + ("error_msg", "config", "invalid"), + [ + ( + "Invalid dash-separated key 'author-email' in 'metadata' (setup.cfg)", + DALS( + """ + [metadata] + author-email = test@test.com + maintainer_email = foo@foo.com + """ + ), + {"author-email": "test@test.com"}, + ), + ( + "Invalid uppercase key 'Name' in 'metadata' (setup.cfg)", + DALS( + """ + [metadata] + Name = foo + description = Some description + """ + ), + {"Name": "foo"}, + ), + ], + ) + def test_invalid_options_previously_deprecated( + self, tmpdir, error_msg, config, invalid + ): + # This test and related methods can be removed when no longer needed. + # Deprecation postponed due to push-back from the community in + # https://github.com/pypa/setuptools/issues/4910 + fake_env(tmpdir, config) + with pytest.warns(SetuptoolsDeprecationWarning, match=re.escape(error_msg)): + dist = get_dist(tmpdir).__enter__() + + tmpdir.join('setup.cfg').remove() + + for field, value in invalid.items(): + attr = field.replace("-", "_").lower() + assert getattr(dist.metadata, attr) == value + + +class TestOptions: + def test_basic(self, tmpdir): + fake_env( + tmpdir, + '[options]\n' + 'zip_safe = True\n' + 'include_package_data = yes\n' + 'package_dir = b=c, =src\n' + 'packages = pack_a, pack_b.subpack\n' + 'namespace_packages = pack1, pack2\n' + 'scripts = bin/one.py, bin/two.py\n' + 'eager_resources = bin/one.py, bin/two.py\n' + 'install_requires = docutils>=0.3; pack ==1.1, ==1.3; hey\n' + 'setup_requires = docutils>=0.3; spack ==1.1, ==1.3; there\n' + 'dependency_links = http://some.com/here/1, ' + 'http://some.com/there/2\n' + 'python_requires = >=1.0, !=2.8\n' + 'py_modules = module1, module2\n', + ) + deprec = pytest.warns(SetuptoolsDeprecationWarning, match="namespace_packages") + with deprec, get_dist(tmpdir) as dist: + assert dist.zip_safe + assert dist.include_package_data + assert dist.package_dir == {'': 'src', 'b': 'c'} + assert dist.packages == ['pack_a', 'pack_b.subpack'] + assert dist.namespace_packages == ['pack1', 'pack2'] + assert dist.scripts == ['bin/one.py', 'bin/two.py'] + assert dist.dependency_links == ([ + 'http://some.com/here/1', + 'http://some.com/there/2', + ]) + assert dist.install_requires == ([ + 'docutils>=0.3', + 'pack==1.1,==1.3', + 'hey', + ]) + assert dist.setup_requires == ([ + 'docutils>=0.3', + 'spack ==1.1, ==1.3', + 'there', + ]) + assert dist.python_requires == '>=1.0, !=2.8' + assert dist.py_modules == ['module1', 'module2'] + + def test_multiline(self, tmpdir): + fake_env( + tmpdir, + '[options]\n' + 'package_dir = \n' + ' b=c\n' + ' =src\n' + 'packages = \n' + ' pack_a\n' + ' pack_b.subpack\n' + 'namespace_packages = \n' + ' pack1\n' + ' pack2\n' + 'scripts = \n' + ' bin/one.py\n' + ' bin/two.py\n' + 'eager_resources = \n' + ' bin/one.py\n' + ' bin/two.py\n' + 'install_requires = \n' + ' docutils>=0.3\n' + ' pack ==1.1, ==1.3\n' + ' hey\n' + 'setup_requires = \n' + ' docutils>=0.3\n' + ' spack ==1.1, ==1.3\n' + ' there\n' + 'dependency_links = \n' + ' http://some.com/here/1\n' + ' http://some.com/there/2\n', + ) + deprec = pytest.warns(SetuptoolsDeprecationWarning, match="namespace_packages") + with deprec, get_dist(tmpdir) as dist: + assert dist.package_dir == {'': 'src', 'b': 'c'} + assert dist.packages == ['pack_a', 'pack_b.subpack'] + assert dist.namespace_packages == ['pack1', 'pack2'] + assert dist.scripts == ['bin/one.py', 'bin/two.py'] + assert dist.dependency_links == ([ + 'http://some.com/here/1', + 'http://some.com/there/2', + ]) + assert dist.install_requires == ([ + 'docutils>=0.3', + 'pack==1.1,==1.3', + 'hey', + ]) + assert dist.setup_requires == ([ + 'docutils>=0.3', + 'spack ==1.1, ==1.3', + 'there', + ]) + + def test_package_dir_fail(self, tmpdir): + fake_env(tmpdir, '[options]\npackage_dir = a b\n') + with get_dist(tmpdir, parse=False) as dist: + with pytest.raises(DistutilsOptionError): + dist.parse_config_files() + + def test_package_data(self, tmpdir): + fake_env( + tmpdir, + '[options.package_data]\n' + '* = *.txt, *.rst\n' + 'hello = *.msg\n' + '\n' + '[options.exclude_package_data]\n' + '* = fake1.txt, fake2.txt\n' + 'hello = *.dat\n', + ) + + with get_dist(tmpdir) as dist: + assert dist.package_data == { + '': ['*.txt', '*.rst'], + 'hello': ['*.msg'], + } + assert dist.exclude_package_data == { + '': ['fake1.txt', 'fake2.txt'], + 'hello': ['*.dat'], + } + + def test_packages(self, tmpdir): + fake_env(tmpdir, '[options]\npackages = find:\n') + + with get_dist(tmpdir) as dist: + assert dist.packages == ['fake_package'] + + def test_find_directive(self, tmpdir): + dir_package, config = fake_env(tmpdir, '[options]\npackages = find:\n') + + make_package_dir('sub_one', dir_package) + make_package_dir('sub_two', dir_package) + + with get_dist(tmpdir) as dist: + assert set(dist.packages) == set([ + 'fake_package', + 'fake_package.sub_two', + 'fake_package.sub_one', + ]) + + config.write( + '[options]\n' + 'packages = find:\n' + '\n' + '[options.packages.find]\n' + 'where = .\n' + 'include =\n' + ' fake_package.sub_one\n' + ' two\n' + ) + with get_dist(tmpdir) as dist: + assert dist.packages == ['fake_package.sub_one'] + + config.write( + '[options]\n' + 'packages = find:\n' + '\n' + '[options.packages.find]\n' + 'exclude =\n' + ' fake_package.sub_one\n' + ) + with get_dist(tmpdir) as dist: + assert set(dist.packages) == set(['fake_package', 'fake_package.sub_two']) + + def test_find_namespace_directive(self, tmpdir): + dir_package, config = fake_env( + tmpdir, '[options]\npackages = find_namespace:\n' + ) + + make_package_dir('sub_one', dir_package) + make_package_dir('sub_two', dir_package, ns=True) + + with get_dist(tmpdir) as dist: + assert set(dist.packages) == { + 'fake_package', + 'fake_package.sub_two', + 'fake_package.sub_one', + } + + config.write( + '[options]\n' + 'packages = find_namespace:\n' + '\n' + '[options.packages.find]\n' + 'where = .\n' + 'include =\n' + ' fake_package.sub_one\n' + ' two\n' + ) + with get_dist(tmpdir) as dist: + assert dist.packages == ['fake_package.sub_one'] + + config.write( + '[options]\n' + 'packages = find_namespace:\n' + '\n' + '[options.packages.find]\n' + 'exclude =\n' + ' fake_package.sub_one\n' + ) + with get_dist(tmpdir) as dist: + assert set(dist.packages) == {'fake_package', 'fake_package.sub_two'} + + def test_extras_require(self, tmpdir): + fake_env( + tmpdir, + '[options.extras_require]\n' + 'pdf = ReportLab>=1.2; RXP\n' + 'rest = \n' + ' docutils>=0.3\n' + ' pack ==1.1, ==1.3\n', + ) + + with get_dist(tmpdir) as dist: + assert dist.extras_require == { + 'pdf': ['ReportLab>=1.2', 'RXP'], + 'rest': ['docutils>=0.3', 'pack==1.1,==1.3'], + } + assert set(dist.metadata.provides_extras) == {'pdf', 'rest'} + + @pytest.mark.parametrize( + "config", + [ + "[options.extras_require]\nfoo = bar;python_version<'3'", + "[options.extras_require]\nfoo = bar;os_name=='linux'", + "[options.extras_require]\nfoo = bar;python_version<'3'\n", + "[options.extras_require]\nfoo = bar;os_name=='linux'\n", + "[options]\ninstall_requires = bar;python_version<'3'", + "[options]\ninstall_requires = bar;os_name=='linux'", + "[options]\ninstall_requires = bar;python_version<'3'\n", + "[options]\ninstall_requires = bar;os_name=='linux'\n", + ], + ) + @pytest.mark.xfail(IS_PYPY, reason="Exceptions missing on PyPy") + # TODO: investigate PyPy problem + def test_raises_accidental_env_marker_misconfig(self, config, tmpdir): + fake_env(tmpdir, config) + match = ( + r"One of the parsed requirements in `(install_requires|extras_require.+)` " + "looks like a valid environment marker.*" + ) + with pytest.raises(InvalidRequirement, match=match): + with get_dist(tmpdir) as _: + pass + + @pytest.mark.parametrize( + "config", + [ + "[options.extras_require]\nfoo = bar;python_version<3", + "[options.extras_require]\nfoo = bar;python_version<3\n", + "[options]\ninstall_requires = bar;python_version<3", + "[options]\ninstall_requires = bar;python_version<3\n", + ], + ) + @pytest.mark.xfail(IS_PYPY, reason="Warnings missing on PyPy (minor issue)") + # TODO: investigate PyPy problem + def test_warn_accidental_env_marker_misconfig(self, config, tmpdir): + fake_env(tmpdir, config) + match = ( + r"One of the parsed requirements in `(install_requires|extras_require.+)` " + "looks like a valid environment marker.*" + ) + with pytest.warns(SetuptoolsDeprecationWarning, match=match): + with get_dist(tmpdir) as _: + pass + + @pytest.mark.parametrize( + "config", + [ + "[options.extras_require]\nfoo =\n bar;python_version<'3'", + "[options.extras_require]\nfoo = bar;baz\nboo = xxx;yyy", + "[options.extras_require]\nfoo =\n bar;python_version<'3'\n", + "[options.extras_require]\nfoo = bar;baz\nboo = xxx;yyy\n", + "[options.extras_require]\nfoo =\n bar\n python_version<3\n", + "[options]\ninstall_requires =\n bar;python_version<'3'", + "[options]\ninstall_requires = bar;baz\nboo = xxx;yyy", + "[options]\ninstall_requires =\n bar;python_version<'3'\n", + "[options]\ninstall_requires = bar;baz\nboo = xxx;yyy\n", + "[options]\ninstall_requires =\n bar\n python_version<3\n", + ], + ) + @pytest.mark.filterwarnings("error::setuptools.SetuptoolsDeprecationWarning") + def test_nowarn_accidental_env_marker_misconfig(self, config, tmpdir, recwarn): + fake_env(tmpdir, config) + num_warnings = len(recwarn) + with get_dist(tmpdir) as _: + pass + # The examples are valid, no warnings shown + assert len(recwarn) == num_warnings + + def test_dash_preserved_extras_require(self, tmpdir): + fake_env(tmpdir, '[options.extras_require]\nfoo-a = foo\nfoo_b = test\n') + + with get_dist(tmpdir) as dist: + assert dist.extras_require == {'foo-a': ['foo'], 'foo_b': ['test']} + + def test_entry_points(self, tmpdir): + _, config = fake_env( + tmpdir, + '[options.entry_points]\n' + 'group1 = point1 = pack.module:func, ' + '.point2 = pack.module2:func_rest [rest]\n' + 'group2 = point3 = pack.module:func2\n', + ) + + with get_dist(tmpdir) as dist: + assert dist.entry_points == { + 'group1': [ + 'point1 = pack.module:func', + '.point2 = pack.module2:func_rest [rest]', + ], + 'group2': ['point3 = pack.module:func2'], + } + + expected = ( + '[blogtool.parsers]\n' + '.rst = some.nested.module:SomeClass.some_classmethod[reST]\n' + ) + + tmpdir.join('entry_points').write(expected) + + # From file. + config.write('[options]\nentry_points = file: entry_points\n') + + with get_dist(tmpdir) as dist: + assert dist.entry_points == expected + + def test_case_sensitive_entry_points(self, tmpdir): + fake_env( + tmpdir, + '[options.entry_points]\n' + 'GROUP1 = point1 = pack.module:func, ' + '.point2 = pack.module2:func_rest [rest]\n' + 'group2 = point3 = pack.module:func2\n', + ) + + with get_dist(tmpdir) as dist: + assert dist.entry_points == { + 'GROUP1': [ + 'point1 = pack.module:func', + '.point2 = pack.module2:func_rest [rest]', + ], + 'group2': ['point3 = pack.module:func2'], + } + + def test_data_files(self, tmpdir): + fake_env( + tmpdir, + '[options.data_files]\n' + 'cfg =\n' + ' a/b.conf\n' + ' c/d.conf\n' + 'data = e/f.dat, g/h.dat\n', + ) + + with get_dist(tmpdir) as dist: + expected = [ + ('cfg', ['a/b.conf', 'c/d.conf']), + ('data', ['e/f.dat', 'g/h.dat']), + ] + assert sorted(dist.data_files) == sorted(expected) + + def test_data_files_globby(self, tmpdir): + fake_env( + tmpdir, + '[options.data_files]\n' + 'cfg =\n' + ' a/b.conf\n' + ' c/d.conf\n' + 'data = *.dat\n' + 'icons = \n' + ' *.ico\n' + 'audio = \n' + ' *.wav\n' + ' sounds.db\n', + ) + + # Create dummy files for glob()'s sake: + tmpdir.join('a.dat').write('') + tmpdir.join('b.dat').write('') + tmpdir.join('c.dat').write('') + tmpdir.join('a.ico').write('') + tmpdir.join('b.ico').write('') + tmpdir.join('c.ico').write('') + tmpdir.join('beep.wav').write('') + tmpdir.join('boop.wav').write('') + tmpdir.join('sounds.db').write('') + + with get_dist(tmpdir) as dist: + expected = [ + ('cfg', ['a/b.conf', 'c/d.conf']), + ('data', ['a.dat', 'b.dat', 'c.dat']), + ('icons', ['a.ico', 'b.ico', 'c.ico']), + ('audio', ['beep.wav', 'boop.wav', 'sounds.db']), + ] + assert sorted(dist.data_files) == sorted(expected) + + def test_python_requires_simple(self, tmpdir): + fake_env( + tmpdir, + DALS( + """ + [options] + python_requires=>=2.7 + """ + ), + ) + with get_dist(tmpdir) as dist: + dist.parse_config_files() + + def test_python_requires_compound(self, tmpdir): + fake_env( + tmpdir, + DALS( + """ + [options] + python_requires=>=2.7,!=3.0.* + """ + ), + ) + with get_dist(tmpdir) as dist: + dist.parse_config_files() + + def test_python_requires_invalid(self, tmpdir): + fake_env( + tmpdir, + DALS( + """ + [options] + python_requires=invalid + """ + ), + ) + with pytest.raises(Exception): + with get_dist(tmpdir) as dist: + dist.parse_config_files() + + def test_cmdclass(self, tmpdir): + module_path = Path(tmpdir, "src/custom_build.py") # auto discovery for src + module_path.parent.mkdir(parents=True, exist_ok=True) + module_path.write_text( + "from distutils.core import Command\nclass CustomCmd(Command): pass\n", + encoding="utf-8", + ) + + setup_cfg = """ + [options] + cmdclass = + customcmd = custom_build.CustomCmd + """ + fake_env(tmpdir, inspect.cleandoc(setup_cfg)) + + with get_dist(tmpdir) as dist: + cmdclass = dist.cmdclass['customcmd'] + assert cmdclass.__name__ == "CustomCmd" + assert cmdclass.__module__ == "custom_build" + assert module_path.samefile(inspect.getfile(cmdclass)) + + def test_requirements_file(self, tmpdir): + fake_env( + tmpdir, + DALS( + """ + [options] + install_requires = file:requirements.txt + [options.extras_require] + colors = file:requirements-extra.txt + """ + ), + ) + + tmpdir.join('requirements.txt').write('\ndocutils>=0.3\n\n') + tmpdir.join('requirements-extra.txt').write('colorama') + + with get_dist(tmpdir) as dist: + assert dist.install_requires == ['docutils>=0.3'] + assert dist.extras_require == {'colors': ['colorama']} + + +saved_dist_init = _Distribution.__init__ + + +class TestExternalSetters: + # During creation of the setuptools Distribution() object, we call + # the init of the parent distutils Distribution object via + # _Distribution.__init__ (). + # + # It's possible distutils calls out to various keyword + # implementations (i.e. distutils.setup_keywords entry points) + # that may set a range of variables. + # + # This wraps distutil's Distribution.__init__ and simulates + # pbr or something else setting these values. + def _fake_distribution_init(self, dist, attrs): + saved_dist_init(dist, attrs) + # see self._DISTUTILS_UNSUPPORTED_METADATA + dist.metadata.long_description_content_type = 'text/something' + # Test overwrite setup() args + dist.metadata.project_urls = { + 'Link One': 'https://example.com/one/', + 'Link Two': 'https://example.com/two/', + } + + @patch.object(_Distribution, '__init__', autospec=True) + def test_external_setters(self, mock_parent_init, tmpdir): + mock_parent_init.side_effect = self._fake_distribution_init + + dist = Distribution(attrs={'project_urls': {'will_be': 'ignored'}}) + + assert dist.metadata.long_description_content_type == 'text/something' + assert dist.metadata.project_urls == { + 'Link One': 'https://example.com/one/', + 'Link Two': 'https://example.com/two/', + } diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/indexes/test_links_priority/external.html b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/indexes/test_links_priority/external.html new file mode 100644 index 0000000000000000000000000000000000000000..92e4702f634dfb37a404bec3103b76f6afcaa917 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/indexes/test_links_priority/external.html @@ -0,0 +1,3 @@ +<html><body> +<a href="/foobar-0.1.tar.gz#md5=1__bad_md5___">bad old link</a> +</body></html> diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/indexes/test_links_priority/simple/foobar/index.html b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/indexes/test_links_priority/simple/foobar/index.html new file mode 100644 index 0000000000000000000000000000000000000000..fefb028bd3ee7d45a414d6e96a7b2a21ffd7eda7 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/indexes/test_links_priority/simple/foobar/index.html @@ -0,0 +1,4 @@ +<html><body> +<a href="/foobar-0.1.tar.gz#md5=0_correct_md5">foobar-0.1.tar.gz</a><br/> +<a href="../../external.html" rel="homepage">external homepage</a><br/> +</body></html> diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/integration/__init__.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/integration/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/integration/helpers.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/integration/helpers.py new file mode 100644 index 0000000000000000000000000000000000000000..16b13022913f62ba86df6b2480d22e3119cdb8cc --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/integration/helpers.py @@ -0,0 +1,80 @@ +"""Reusable functions and classes for different types of integration tests. + +For example ``Archive`` can be used to check the contents of distribution built +with setuptools, and ``run`` will always try to be as verbose as possible to +facilitate debugging. +""" + +from __future__ import annotations + +import os +import subprocess +import tarfile +from collections.abc import Iterator +from pathlib import Path +from zipfile import ZipFile, ZipInfo + + +def run(cmd, env=None): + r = subprocess.run( + cmd, + capture_output=True, + text=True, + encoding="utf-8", + env={**os.environ, **(env or {})}, + # ^-- allow overwriting instead of discarding the current env + ) + + out = r.stdout + "\n" + r.stderr + # pytest omits stdout/err by default, if the test fails they help debugging + print("~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~") + print(f"Command: {cmd}\nreturn code: {r.returncode}\n\n{out}") + + if r.returncode == 0: + return out + raise subprocess.CalledProcessError(r.returncode, cmd, r.stdout, r.stderr) + + +class Archive: + """Compatibility layer for ZipFile/Info and TarFile/Info""" + + def __init__(self, filename) -> None: + self._filename = filename + if filename.endswith("tar.gz"): + self._obj: tarfile.TarFile | ZipFile = tarfile.open(filename, "r:gz") + elif filename.endswith("zip"): + self._obj = ZipFile(filename) + else: + raise ValueError(f"{filename} doesn't seem to be a zip or tar.gz") + + def __iter__(self) -> Iterator[ZipInfo] | Iterator[tarfile.TarInfo]: + if hasattr(self._obj, "infolist"): + return iter(self._obj.infolist()) + return iter(self._obj) + + def get_name(self, zip_or_tar_info): + if hasattr(zip_or_tar_info, "filename"): + return zip_or_tar_info.filename + return zip_or_tar_info.name + + def get_content(self, zip_or_tar_info): + if hasattr(self._obj, "extractfile"): + content = self._obj.extractfile(zip_or_tar_info) + if content is None: + msg = f"Invalid {zip_or_tar_info.name} in {self._filename}" + raise ValueError(msg) + return str(content.read(), "utf-8") + return str(self._obj.read(zip_or_tar_info), "utf-8") + + +def get_sdist_members(sdist_path): + with tarfile.open(sdist_path, "r:gz") as tar: + files = [Path(f) for f in tar.getnames()] + # remove root folder + relative_files = ("/".join(f.parts[1:]) for f in files) + return {f for f in relative_files if f} + + +def get_wheel_members(wheel_path): + with ZipFile(wheel_path) as zipfile: + return set(zipfile.namelist()) diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/integration/test_pbr.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/integration/test_pbr.py new file mode 100644 index 0000000000000000000000000000000000000000..f89e5b8b2151430d0994836dd609f1b75490a336 --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/integration/test_pbr.py @@ -0,0 +1,20 @@ +import subprocess + +import pytest + + +@pytest.mark.uses_network +def test_pbr_integration(pbr_package, venv): + """Ensure pbr packages install.""" + cmd = [ + 'python', + '-m', + 'pip', + '-v', + 'install', + '--no-build-isolation', + pbr_package, + ] + venv.run(cmd, stderr=subprocess.STDOUT) + out = venv.run(["python", "-c", "import mypkg.hello"]) + assert "Hello world!" in out diff --git a/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/integration/test_pip_install_sdist.py b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/integration/test_pip_install_sdist.py new file mode 100644 index 0000000000000000000000000000000000000000..4e84f218323e6ad67adfbce07cea5a16e91a311c --- /dev/null +++ b/micromamba_root/pkgs/https/conda.anaconda.org/conda-forge/noarch/setuptools-82.0.1-pyh332efcf_0/site-packages/setuptools/tests/integration/test_pip_install_sdist.py @@ -0,0 +1,223 @@ +# https://github.com/python/mypy/issues/16936 +# mypy: disable-error-code="has-type" +"""Integration tests for setuptools that focus on building packages via pip. + +The idea behind these tests is not to exhaustively check all the possible +combinations of packages, operating systems, supporting libraries, etc, but +rather check a limited number of popular packages and how they interact with +the exposed public API. This way if any change in API is introduced, we hope to +identify backward compatibility problems before publishing a release. + +The number of tested packages is purposefully kept small, to minimise duration +and the associated maintenance cost (changes in the way these packages define +their build process may require changes in the tests). +""" + +import json +import os +import shutil +import sys +from enum import Enum +from glob import glob +from hashlib import md5 +from urllib.request import urlopen + +import pytest +from packaging.requirements import Requirement + +from .helpers import Archive, run + +pytestmark = pytest.mark.integration + + +(LATEST,) = Enum("v", "LATEST") # type: ignore[misc] # https://github.com/python/mypy/issues/16936 +"""Default version to be checked""" +# There are positive and negative aspects of checking the latest version of the +# packages. +# The main positive aspect is that the latest version might have already +# removed the use of APIs deprecated in previous releases of setuptools. + + +# Packages to be tested: +# (Please notice the test environment cannot support EVERY library required for +# compiling binary extensions. In Ubuntu/Debian nomenclature, we only assume +# that `build-essential`, `gfortran` and `libopenblas-dev` are installed, +# due to their relevance to the numerical/scientific programming ecosystem) +EXAMPLES = [ + ("pip", LATEST), # just in case... + ("pytest", LATEST), # uses setuptools_scm + ("mypy", LATEST), # custom build_py + ext_modules + # --- Popular packages: https://hugovk.github.io/top-pypi-packages/ --- + ("botocore", LATEST), + ("kiwisolver", LATEST), # build_ext + ("brotli", LATEST), # not in the list but used by urllib3 + ("pyyaml", LATEST), # cython + custom build_ext + custom distclass + ("charset-normalizer", LATEST), # uses mypyc, used by aiohttp + ("protobuf", LATEST), + # ("requests", LATEST), # XXX: https://github.com/psf/requests/pull/6920 + ("celery", LATEST), + # When adding packages to this list, make sure they expose a `__version__` + # attribute, or modify the tests below +] + + +# Some packages have "optional" dependencies that modify their build behaviour +# and are not listed in pyproject.toml, others still use `setup_requires` +EXTRA_BUILD_DEPS = { + "pyyaml": ("Cython<3.0",), # constraint to avoid errors + "charset-normalizer": ("mypy>=1.4.1",), # no pyproject.toml available +} + +EXTRA_ENV_VARS = { + "pyyaml": {"PYYAML_FORCE_CYTHON": "1"}, + "charset-normalizer": {"CHARSET_NORMALIZER_USE_MYPYC": "1"}, +} + +IMPORT_NAME = { + "pyyaml": "yaml", + "protobuf": "google.protobuf", +} + + +VIRTUALENV = (sys.executable, "-m", "virtualenv") + + +# By default, pip will try to build packages in isolation (PEP 517), which +# means it will download the previous stable version of setuptools. +# `pip` flags can avoid that (the version of setuptools under test +# should be the one to be used) +INSTALL_OPTIONS = ( + "--ignore-installed", + "--no-build-isolation", + # Omit "--no-binary :all:" the sdist is supplied directly. + # Allows dependencies as wheels. +) +# The downside of `--no-build-isolation` is that pip will not download build +# dependencies. The test script will have to also handle that. + + +@pytest.fixture +def venv_python(tmp_path): + run([*VIRTUALENV, str(tmp_path / ".venv")]) + possible_path = (str(p.parent) for p in tmp_path.glob(".venv/*/python*")) + return shutil.which("python", path=os.pathsep.join(possible_path)) + + +@pytest.fixture(autouse=True) +def _prepare(tmp_path, venv_python, monkeypatch): + download_path = os.getenv("DOWNLOAD_PATH", str(tmp_path)) + os.makedirs(download_path, exist_ok=True) + + # Environment vars used for building some of the packages + monkeypatch.setenv("USE_MYPYC", "1") + + yield + + # Let's provide the maximum amount of information possible in the case + # it is necessary to debug the tests directly from the CI logs. + print("~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~") + print("Temporary directory:") + map(print, tmp_path.glob("*")) + print("Virtual environment:") + run([venv_python, "-m", "pip", "freeze"]) + + +@pytest.mark.parametrize(("package", "version"), EXAMPLES) +@pytest.mark.uses_network +def test_install_sdist(package, version, tmp_path, venv_python, setuptools_wheel): + venv_pip = (venv_python, "-m", "pip") + sdist = retrieve_sdist(package, version, tmp_path) + deps = build_deps(package, sdist) + if deps: + print("~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~") + print("Dependencies:", deps) + run([*venv_pip, "install", *deps]) + + # Use a virtualenv to simulate PEP 517 isolation + # but install fresh setuptools wheel to ensure the version under development + env = EXTRA_ENV_VARS.get(package, {}) + run([*venv_pip, "install", "--force-reinstall", setuptools_wheel]) + run([*venv_pip, "install", *INSTALL_OPTIONS, sdist], env) + + # Execute a simple script to make sure the package was installed correctly + pkg = IMPORT_NAME.get(package, package).replace("-", "_") + script = f"import {pkg}; print(getattr({pkg}, '__version__', 0))" + run([venv_python, "-c", script]) + + +# ---- Helper Functions ---- + + +def retrieve_sdist(package, version, tmp_path): + """Either use cached sdist file or download it from PyPI""" + # `pip download` cannot be used due to + # https://github.com/pypa/pip/issues/1884 + # https://discuss.python.org/t/pep-625-file-name-of-a-source-distribution/4686 + # We have to find the correct distribution file and download it + download_path = os.getenv("DOWNLOAD_PATH", str(tmp_path)) + dist = retrieve_pypi_sdist_metadata(package, version) + + # Remove old files to prevent cache to grow indefinitely + for file in glob(os.path.join(download_path, f"{package}*")): + if dist["filename"] != file: + os.unlink(file) + + dist_file = os.path.join(download_path, dist["filename"]) + if not os.path.exists(dist_file): + download(dist["url"], dist_file, dist["md5_digest"]) + return dist_file + + +def retrieve_pypi_sdist_metadata(package, version): + # https://warehouse.pypa.io/api-reference/json.html + id_ = package if version is LATEST else f"{package}/{version}" + with urlopen(f"https://pypi.org/pypi/{id_}/json") as f: + metadata = json.load(f) + + if metadata["info"]["yanked"]: + raise ValueError(f"Release for {package} {version} was yanked") + + version = metadata["info"]["version"] + release = metadata["releases"][version] if version is LATEST else metadata["urls"] + (sdist,) = filter(lambda d: d["packagetype"] == "sdist", release) + return sdist + + +def download(url, dest, md5_digest): + with urlopen(url) as f: + data = f.read() + + assert md5(data).hexdigest() == md5_digest + + with open(dest, "wb") as f: + f.write(data) + + assert os.path.exists(dest) + + +def build_deps(package, sdist_file): + """Find out what are the build dependencies for a package. + + "Manually" install them, since pip will not install build + deps with `--no-build-isolation`. + """ + # delay importing, since pytest discovery phase may hit this file from a + # testenv without tomli + from setuptools.compat.py310 import tomllib + + archive = Archive(sdist_file) + info = tomllib.loads(_read_pyproject(archive)) + deps = info.get("build-system", {}).get("requires", []) + deps += EXTRA_BUILD_DEPS.get(package, []) + # Remove setuptools from requirements (and deduplicate) + requirements = {Requirement(d).name: d for d in deps} + return [v for k, v in requirements.items() if k != "setuptools"] + + +def _read_pyproject(archive): + contents = ( + archive.get_content(member) + for member in archive + if os.path.basename(archive.get_name(member)) == "pyproject.toml" + ) + return next(contents, "")

    ' : '\U0001d4ab', + '\\' : '\U0001d4ac', + '\\' : '\U0000211b', + '\\' : '\U0001d4ae', + '\\' : '\U0001d4af', + '\\' : '\U0001d4b0', + '\\' : '\U0001d4b1', + '\\' : '\U0001d4b2', + '\\' : '\U0001d4b3', + '\\' : '\U0001d4b4', + '\\' : '\U0001d4b5', + '\\' : '\U0001d5ba', + '\\' : '\U0001d5bb', + '\\' : '\U0001d5bc', + '\\' : '\U0001d5bd', + '\\' : '\U0001d5be', + '\\' : '\U0001d5bf', + '\\' : '\U0001d5c0', + '\\' : '\U0001d5c1', + '\\' : '\U0001d5c2', + '\\' : '\U0001d5c3', + '\\' : '\U0001d5c4', + '\\' : '\U0001d5c5', + '\\' : '\U0001d5c6', + '\\' : '\U0001d5c7', + '\\' : '\U0001d5c8', + '\\